From faf29a4d93a98b4ccd8a10297353a9d0779d231f Mon Sep 17 00:00:00 2001 From: Niklas Schnelle Date: Thu, 11 Feb 2021 14:20:03 +0100 Subject: s390/pci: introduce zpci_bus_scan_device() To match zpci_bus_scan_device() and the PCI common code terminology and to remove some code duplication, we pull the multiple uses of pci_scan_single_device() into a function. For now this has the side effect of adding each device to the PCI bus separately and locking and unlocking the rescan/remove lock for each instead of just once per bus. This is clearly less efficient but provides a correct intermediate behavior until a follow on change does both the adding and scanning only once per bus. Reviewed-by: Matthew Rosato Acked-by: Pierre Morel Signed-off-by: Niklas Schnelle Signed-off-by: Heiko Carstens --- arch/s390/pci/pci_bus.h | 1 + 1 file changed, 1 insertion(+) (limited to 'arch/s390/pci/pci_bus.h') diff --git a/arch/s390/pci/pci_bus.h b/arch/s390/pci/pci_bus.h index e04ca06a71b6..2649238f6cde 100644 --- a/arch/s390/pci/pci_bus.h +++ b/arch/s390/pci/pci_bus.h @@ -10,6 +10,7 @@ int zpci_bus_device_register(struct zpci_dev *zdev, struct pci_ops *ops); void zpci_bus_device_unregister(struct zpci_dev *zdev); +int zpci_bus_scan_device(struct zpci_dev *zdev); void zpci_bus_remove_device(struct zpci_dev *zdev, bool set_error); void zpci_release_device(struct kref *kref); -- cgit v1.2.3