Skip to contentSkip to conversation

drivers/ide: make ide-scan-pci.c driver explicitly non-modular

PATCH Applied Paul Gortmaker 2 participants 2 messages Dec 9, 2015 – Jan 18, 2016 libata

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drivers/ide: make ide-scan-pci.c driver explicitly non-modular

The Kconfig for this support is currently:

config IDEPCI_PCIBUS_ORDER
bool "Probe IDE PCI devices in the PCI bus order (DEPRECATED)"

...meaning that it currently is not being built as a module by anyone. Lets change the initcall to be the equivalent device_initcall, so that when reading the driver code, there is no doubt it is builtin-only.

Unlike other similar changes, we leave the module.h header to be included since this code interacts with other drivers and needs to know what a struct module is.

drivers/ide/ide-scan-pci.c +1 -2
index c3da53e7bb2b..86aa88aeb3a6 100644
@@ -107,5 +107,4 @@ static int __init ide_scan_pcibus(void)
 
 	return 0;
 }
-
-module_init(ide_scan_pcibus);
+device_initcall(ide_scan_pcibus);
Signature · 1 line
2.2.1
Applied
#1 lore raw

From: Paul Gortmaker <[email protected]>
Date: Wed, 9 Dec 2015 16:45:51 -0500

Quoted 9 lines

The Kconfig for this support is currently:

config IDEPCI_PCIBUS_ORDER
bool "Probe IDE PCI devices in the PCI bus order (DEPRECATED)"

...meaning that it currently is not being built as a module by anyone. Lets change the initcall to be the equivalent device_initcall, so that when reading the driver code, there is no doubt it is builtin-only.

Quoted 7 lines

Unlike other similar changes, we leave the module.h header to be included since this code interacts with other drivers and needs to know what a struct module is.

Applied.