|
@@ -155,6 +155,7 @@ struct pci_dn {
|
|
|
|
|
|
struct pci_dev *pcidev; /* back-pointer to the pci device */
|
|
struct pci_dev *pcidev; /* back-pointer to the pci device */
|
|
#ifdef CONFIG_EEH
|
|
#ifdef CONFIG_EEH
|
|
|
|
+ struct eeh_dev *edev; /* eeh device */
|
|
int class_code; /* pci device class */
|
|
int class_code; /* pci device class */
|
|
int eeh_mode; /* See eeh.h for possible EEH_MODEs */
|
|
int eeh_mode; /* See eeh.h for possible EEH_MODEs */
|
|
int eeh_config_addr;
|
|
int eeh_config_addr;
|
|
@@ -185,6 +186,13 @@ static inline int pci_device_from_OF_node(struct device_node *np,
|
|
return 0;
|
|
return 0;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+#if defined(CONFIG_EEH)
|
|
|
|
+static inline struct eeh_dev *of_node_to_eeh_dev(struct device_node *dn)
|
|
|
|
+{
|
|
|
|
+ return PCI_DN(dn)->edev;
|
|
|
|
+}
|
|
|
|
+#endif
|
|
|
|
+
|
|
/** Find the bus corresponding to the indicated device node */
|
|
/** Find the bus corresponding to the indicated device node */
|
|
extern struct pci_bus *pcibios_find_pci_bus(struct device_node *dn);
|
|
extern struct pci_bus *pcibios_find_pci_bus(struct device_node *dn);
|
|
|
|
|