Skip to contentSkip to conversation

bus: qcom-ebi2: make it explicitly non-modular

PATCH In review Paul Gortmaker 2 participants 2 messages Sep 27, 2016 – Oct 3, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 bus: qcom-ebi2: make it explicitly non-modular

The Kconfig currently controlling compilation of this code is:

drivers/bus/Kconfig:config QCOM_EBI2
drivers/bus/Kconfig: bool "Qualcomm External Bus Interface 2 (EBI2)"

...meaning that it currently is not being built as a module by anyone.

Lets remove the couple traces of modular infrastructure use, so that when reading the driver there is no doubt it is builtin-only.

Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit.

We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments.

We don't replace module.h with init.h since the file already has that.

---
 drivers/bus/qcom-ebi2.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
drivers/bus/qcom-ebi2.c +1 -5
index a6444244c411..d34a6ef02827 100644
@@ -14,7 +14,6 @@
  * hardware.
  */
 
-#include <linux/module.h>
 #include <linux/clk.h>
 #include <linux/err.h>
 #include <linux/io.h>
@@ -402,7 +401,4 @@ static struct platform_driver qcom_ebi2_driver = {
 		.of_match_table = qcom_ebi2_of_match,
 	},
 };
-module_platform_driver(qcom_ebi2_driver);
-MODULE_AUTHOR("Linus Walleij <[email protected]>");
-MODULE_DESCRIPTION("Qualcomm EBI2 driver");
-MODULE_LICENSE("GPL");
+builtin_platform_driver(qcom_ebi2_driver);
Signature · 1 line
2.10.0
#1 lore raw
Quoted 14 lines · Paul Gortmaker

The Kconfig currently controlling compilation of this code is:

drivers/bus/Kconfig:config QCOM_EBI2
drivers/bus/Kconfig: bool "Qualcomm External Bus Interface 2 (EBI2)"

...meaning that it currently is not being built as a module by anyone.

Lets remove the couple traces of modular infrastructure use, so that when reading the driver there is no doubt it is builtin-only.

Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit.

Quoted 7 lines

We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments.

We don't replace module.h with init.h since the file already has that.

I was asked during review to make it a module, from originally being a bool.

Just missed to update Kconfig as it seems :(

So the right patch is a oneliner making it tristate.

Yours,
Linus Walleij