From: Uwe Kleine-König Date: Tue, 2 Dec 2025 15:13:50 +0000 (+0100) Subject: PCI/portdrv: Drop empty shutdown callback X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=15fff3b799ffa38970c6d58dc8dd0aaf3317fab7;p=thirdparty%2Fkernel%2Flinux.git PCI/portdrv: Drop empty shutdown callback .shutdown() is an optional callback and the core only calls it if the pointer in struct device_driver is non-NULL. So make nothing in a bit shorter time and remove the empty function. Signed-off-by: Uwe Kleine-König Signed-off-by: Uwe Kleine-König Signed-off-by: Bjorn Helgaas Reviewed-by: Jonathan Cameron Reviewed-by: Ilpo Järvinen Link: https://patch.msgid.link/283fef06ac51efbb7df25f347d6f3a2967f96429.1764688034.git.u.kleine-koenig@baylibre.com --- diff --git a/drivers/pci/pcie/portdrv.c b/drivers/pci/pcie/portdrv.c index a0991da48213..348d90315570 100644 --- a/drivers/pci/pcie/portdrv.c +++ b/drivers/pci/pcie/portdrv.c @@ -564,17 +564,6 @@ static int pcie_port_remove_service(struct device *dev) return 0; } -/** - * pcie_port_shutdown_service - shut down given PCI Express port service - * @dev: PCI Express port service device to handle - * - * If PCI Express port service driver is registered with - * pcie_port_service_register(), this function will be called by the driver core - * when device_shutdown() is called for the port service device associated - * with the driver. - */ -static void pcie_port_shutdown_service(struct device *dev) {} - /** * pcie_port_service_register - register PCI Express port service driver * @new: PCI Express port service driver to register @@ -588,7 +577,6 @@ int pcie_port_service_register(struct pcie_port_service_driver *new) new->driver.bus = &pcie_port_bus_type; new->driver.probe = pcie_port_probe_service; new->driver.remove = pcie_port_remove_service; - new->driver.shutdown = pcie_port_shutdown_service; return driver_register(&new->driver); }