diff options
Diffstat (limited to 'arch/powerpc/platforms/pseries/msi.c')
-rw-r--r-- | arch/powerpc/platforms/pseries/msi.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/powerpc/platforms/pseries/msi.c b/arch/powerpc/platforms/pseries/msi.c index 691a154c286d..c8d24f9a6948 100644 --- a/arch/powerpc/platforms/pseries/msi.c +++ b/arch/powerpc/platforms/pseries/msi.c | |||
@@ -195,6 +195,7 @@ static struct device_node *find_pe_total_msi(struct pci_dev *dev, int *total) | |||
195 | static struct device_node *find_pe_dn(struct pci_dev *dev, int *total) | 195 | static struct device_node *find_pe_dn(struct pci_dev *dev, int *total) |
196 | { | 196 | { |
197 | struct device_node *dn; | 197 | struct device_node *dn; |
198 | struct pci_dn *pdn; | ||
198 | struct eeh_dev *edev; | 199 | struct eeh_dev *edev; |
199 | 200 | ||
200 | /* Found our PE and assume 8 at that point. */ | 201 | /* Found our PE and assume 8 at that point. */ |
@@ -204,10 +205,11 @@ static struct device_node *find_pe_dn(struct pci_dev *dev, int *total) | |||
204 | return NULL; | 205 | return NULL; |
205 | 206 | ||
206 | /* Get the top level device in the PE */ | 207 | /* Get the top level device in the PE */ |
207 | edev = of_node_to_eeh_dev(dn); | 208 | edev = pdn_to_eeh_dev(PCI_DN(dn)); |
208 | if (edev->pe) | 209 | if (edev->pe) |
209 | edev = list_first_entry(&edev->pe->edevs, struct eeh_dev, list); | 210 | edev = list_first_entry(&edev->pe->edevs, struct eeh_dev, list); |
210 | dn = eeh_dev_to_of_node(edev); | 211 | pdn = eeh_dev_to_pdn(edev); |
212 | dn = pdn ? pdn->node : NULL; | ||
211 | if (!dn) | 213 | if (!dn) |
212 | return NULL; | 214 | return NULL; |
213 | 215 | ||