powerpc: Drop superfluous pci_dev_is_added() calls
authorNiklas Schnelle <schnelle@linux.ibm.com>
Fri, 10 Sep 2021 14:19:40 +0000 (16:19 +0200)
committerMichael Ellerman <mpe@ellerman.id.au>
Fri, 8 Oct 2021 13:15:58 +0000 (00:15 +1100)
commit452f145eca73945222923525a7eba59cf37909cc
tree3fa4ad2da69065fa9fdab285009c8d3b0b22a2c2
parent9d7fb0643a156a5dddd887814e1263b648501cb0
powerpc: Drop superfluous pci_dev_is_added() calls

On powerpc, pci_dev_is_added() is called as part of SR-IOV fixups
that are done under pcibios_add_device() which in turn is only called in
pci_device_add() whih is called when a PCI device is scanned.

pci_dev_assign_added() is called in pci_bus_add_device() which is only
called after scanning the device. Thus pci_dev_is_added() is always
false and can be dropped.

Signed-off-by: Niklas Schnelle <schnelle@linux.ibm.com>
Reviewed-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Oliver O'Halloran <oohall@gmail.com>
[mpe: Tweak change log slightly to reflect Oliver's comments]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20210910141940.2598035-2-schnelle@linux.ibm.com
arch/powerpc/platforms/powernv/pci-sriov.c
arch/powerpc/platforms/pseries/setup.c