[PATCH 14/24] kbuild, firmware: imx: remove MODULE_LICENSE in non-modules

Nick Alcock nick.alcock at oracle.com
Fri Feb 17 06:10:49 PST 2023


Since commit 8b41fc4454e ("kbuild: create modules.builtin without
Makefile.modbuiltin or tristate.conf"), MODULE_LICENSE declarations
are used to identify modules. As a consequence, uses of the macro
in non-modules will cause modprobe to misidentify their containing
object file as a module when it is not (false positives), and modprobe
might succeed rather than failing with a suitable error message.

So remove it in the files in this commit, none of which can be built as
modules.

Signed-off-by: Nick Alcock <nick.alcock at oracle.com>
Suggested-by: Luis Chamberlain <mcgrof at kernel.org>
Cc: Luis Chamberlain <mcgrof at kernel.org>
Cc: linux-modules at vger.kernel.org
Cc: linux-kernel at vger.kernel.org
Cc: Hitomi Hasegawa <hasegawa-hitomi at fujitsu.com>
Cc: Shawn Guo <shawnguo at kernel.org>
Cc: Sascha Hauer <s.hauer at pengutronix.de>
Cc: linux-arm-kernel at lists.infradead.org
---
 drivers/bus/imx-weim.c         | 1 -
 drivers/firmware/imx/imx-scu.c | 1 -
 drivers/firmware/imx/scu-pd.c  | 1 -
 3 files changed, 3 deletions(-)

diff --git a/drivers/bus/imx-weim.c b/drivers/bus/imx-weim.c
index 828c66bbaa67..a3a99299ad15 100644
--- a/drivers/bus/imx-weim.c
+++ b/drivers/bus/imx-weim.c
@@ -405,4 +405,3 @@ module_exit(weim_exit);
 
 MODULE_AUTHOR("Freescale Semiconductor Inc.");
 MODULE_DESCRIPTION("i.MX EIM Controller Driver");
-MODULE_LICENSE("GPL");
diff --git a/drivers/firmware/imx/imx-scu.c b/drivers/firmware/imx/imx-scu.c
index dca79caccd01..886bbc81e0b4 100644
--- a/drivers/firmware/imx/imx-scu.c
+++ b/drivers/firmware/imx/imx-scu.c
@@ -358,4 +358,3 @@ builtin_platform_driver(imx_scu_driver);
 
 MODULE_AUTHOR("Dong Aisheng <aisheng.dong at nxp.com>");
 MODULE_DESCRIPTION("IMX SCU firmware protocol driver");
-MODULE_LICENSE("GPL v2");
diff --git a/drivers/firmware/imx/scu-pd.c b/drivers/firmware/imx/scu-pd.c
index 2a4f07423365..7e8810bdfe0e 100644
--- a/drivers/firmware/imx/scu-pd.c
+++ b/drivers/firmware/imx/scu-pd.c
@@ -421,4 +421,3 @@ builtin_platform_driver(imx_sc_pd_driver);
 
 MODULE_AUTHOR("Dong Aisheng <aisheng.dong at nxp.com>");
 MODULE_DESCRIPTION("IMX SCU Power Domain driver");
-MODULE_LICENSE("GPL v2");
-- 
2.39.1.268.g9de2f9a303




More information about the linux-arm-kernel mailing list