Commit 758b4232 authored by Oliver O'Halloran's avatar Oliver O'Halloran Committed by Michael Ellerman

powerpc/eeh_sysfs: Remove double pci_dn lookup.

In eeh_notify_resume_show() the pci_dn for the device is looked up once in
the declaration block and then once after checking for a NULL eeh_dev.
Remove the second lookup since it's pointless.
Signed-off-by: default avatarOliver O'Halloran <oohall@gmail.com>
Reviewed-by: default avatarSam Bobroff <sbobroff@linux.ibm.com>
Tested-by: default avatarSam Bobroff <sbobroff@linux.ibm.com>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20190715085612.8802-5-oohall@gmail.com
parent 4107248c
...@@ -86,7 +86,6 @@ static ssize_t eeh_notify_resume_show(struct device *dev, ...@@ -86,7 +86,6 @@ static ssize_t eeh_notify_resume_show(struct device *dev,
if (!edev || !edev->pe) if (!edev || !edev->pe)
return -ENODEV; return -ENODEV;
pdn = pci_get_pdn(pdev);
return sprintf(buf, "%d\n", pdn->last_allow_rc); return sprintf(buf, "%d\n", pdn->last_allow_rc);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment