Skip to contentSkip to conversation

kbuild, gpio: gpio-aspeed-sgpio: remove MODULE_LICENSE in non-modules

PATCH Applied Nick Alcock 12 participants 53 messages Feb 22, 2023 – Mar 6, 2023 1 message not in the archive

Subsystems (38)
lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

PATCH 1/27 kbuild, power: reset: keystone-reset: remove MODULE_LICENSE in non-modules

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.

---
 drivers/power/reset/keystone-reset.c | 1 -
 1 file changed, 1 deletion(-)
drivers/power/reset/keystone-reset.c +0 -1
index c720112db704..83a4e1c9bf94 100644
@@ -169,5 +169,4 @@ module_platform_driver(rsctrl_driver);
 
 MODULE_AUTHOR("Ivan Khoronzhuk <[email protected]>");
 MODULE_DESCRIPTION("Texas Instruments keystone reset driver");
-MODULE_LICENSE("GPL v2");
 MODULE_ALIAS("platform:" KBUILD_MODNAME);
Signature · 1 line
2.39.1.268.g9de2f9a303
#2 lore raw

PATCH 2/27 kbuild, video: fbdev: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/video/fbdev/wm8505fb.c    | 1 -
 drivers/video/fbdev/wmt_ge_rops.c | 1 -
 2 files changed, 2 deletions(-)
drivers/video/fbdev/wm8505fb.c +0 -1
index 8f4d674fa0d0..2a2997c647f7 100644
@@ -407,5 +407,4 @@ module_platform_driver(wm8505fb_driver);
 
 MODULE_AUTHOR("Ed Spiridonov <[email protected]>");
 MODULE_DESCRIPTION("Framebuffer driver for WMT WM8505");
-MODULE_LICENSE("GPL v2");
 MODULE_DEVICE_TABLE(of, wmt_dt_ids);
drivers/video/fbdev/wmt_ge_rops.c +0 -1
index 42255d27a1db..c207fd917dce 100644
@@ -170,5 +170,4 @@ module_platform_driver(wmt_ge_rops_driver);
 MODULE_AUTHOR("Alexey Charkov <[email protected]>");
 MODULE_DESCRIPTION("Accelerators for raster operations using "
 		   "WonderMedia Graphics Engine");
-MODULE_LICENSE("GPL v2");
 MODULE_DEVICE_TABLE(of, wmt_dt_ids);
Signature · 7 lines
2.39.1.268.g9de2f9a303


_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
#3 lore raw

PATCH 3/27 kbuild, KEYS: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 crypto/asymmetric_keys/asymmetric_type.c | 1 -
 1 file changed, 1 deletion(-)
crypto/asymmetric_keys/asymmetric_type.c +0 -1
index 41a2f0eb4ce4..a5da8ccd353e 100644
@@ -17,7 +17,6 @@
 #include <keys/user-type.h>
 #include "asymmetric_keys.h"
 
-MODULE_LICENSE("GPL");
 
 const char *const key_being_used_for[NR__KEY_BEING_USED_FOR] = {
 	[VERIFYING_MODULE_SIGNATURE]		= "mod sig",
Signature · 1 line
2.39.1.268.g9de2f9a303
#4 lore raw

PATCH 4/27 kbuild, soc: bcm: raspberrypi-power: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/soc/bcm/raspberrypi-power.c | 1 -
 1 file changed, 1 deletion(-)
drivers/soc/bcm/raspberrypi-power.c +0 -1
index 068715d6e66d..58175af982a0 100644
@@ -243,4 +243,3 @@ builtin_platform_driver(rpi_power_driver);
 MODULE_AUTHOR("Alexander Aring <[email protected]>");
 MODULE_AUTHOR("Eric Anholt <[email protected]>");
 MODULE_DESCRIPTION("Raspberry Pi power domain driver");
-MODULE_LICENSE("GPL v2");
Signature · 1 line
2.39.1.268.g9de2f9a303
#5 lore raw

Re: [PATCH 04/27] kbuild, soc: bcm: raspberrypi-power: remove MODULE_LICENSE in non-modules

Quoted 10 lines · Nick Alcock

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.

Quoted 9 lines

Applied to drivers/next (cannot push right now due to some firewall issue). Thanks!

Signature · 1 line
Florian
#6 lore raw

PATCH 5/27 kbuild, soc: bcm: bcm2835-power: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/soc/bcm/bcm2835-power.c | 1 -
 1 file changed, 1 deletion(-)
drivers/soc/bcm/bcm2835-power.c +0 -1
index 5bcd047768b6..831bea6ce5e9 100644
@@ -717,4 +717,3 @@ module_platform_driver(bcm2835_power_driver);
 
 MODULE_AUTHOR("Eric Anholt <[email protected]>");
 MODULE_DESCRIPTION("Driver for Broadcom BCM2835 PM power domains and reset");
-MODULE_LICENSE("GPL");
Signature · 7 lines
2.39.1.268.g9de2f9a303


_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
#7 lore raw

Re: [PATCH 05/27] kbuild, soc: bcm: bcm2835-power: remove MODULE_LICENSE in non-modules

Quoted 10 lines · Nick Alcock

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.

Quoted 12 lines

Applied to drivers/next (cannot push right now due to some firewall issue). Thanks!

Signature · 1 line
Florian
#8 lore raw

PATCH 6/27 kbuild, pinctrl: bcm: ns: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/pinctrl/bcm/pinctrl-ns.c | 1 -
 1 file changed, 1 deletion(-)
drivers/pinctrl/bcm/pinctrl-ns.c +0 -1
index 465cc96814a1..f80630a74d34 100644
@@ -299,5 +299,4 @@ static struct platform_driver ns_pinctrl_driver = {
 module_platform_driver(ns_pinctrl_driver);
 
 MODULE_AUTHOR("Rafał Miłecki");
-MODULE_LICENSE("GPL v2");
 MODULE_DEVICE_TABLE(of, ns_pinctrl_of_match_table);
Signature · 1 line
2.39.1.268.g9de2f9a303
#9 lore raw

PATCH 7/27 kbuild, MIPS: BCM47XX: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/firmware/broadcom/bcm47xx_nvram.c | 1 -
 1 file changed, 1 deletion(-)
drivers/firmware/broadcom/bcm47xx_nvram.c +0 -1
index 5f47dbf4889a..0ea5206be4c9 100644
@@ -255,4 +255,3 @@ char *bcm47xx_nvram_get_contents(size_t *nvram_size)
 }
 EXPORT_SYMBOL(bcm47xx_nvram_get_contents);
 
-MODULE_LICENSE("GPL v2");
Signature · 1 line
2.39.1.268.g9de2f9a303
Reviewed-by on v1 7/27
#10 lore raw

Re: [PATCH 07/27] kbuild, MIPS: BCM47XX: remove MODULE_LICENSE in non-modules

Quoted 18 lines · Nick Alcock

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.

Quoted 3 lines
---
  drivers/firmware/broadcom/bcm47xx_nvram.c | 1 -
  1 file changed, 1 deletion(-)
#11 lore raw

PATCH 8/27 kbuild, clocksource: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

Cc Luis Chamberlain <[email protected]>
Cc Hitomi Hasegawa <[email protected]>
Cc Daniel Lezcano <[email protected]>
Cc Thomas Gleixner <[email protected]>
Cc Maxime Coquelin <[email protected]>
Cc Alexandre Torgue <[email protected]>
---
 drivers/clocksource/timer-stm32-lp.c | 1 -
 1 file changed, 1 deletion(-)
drivers/clocksource/timer-stm32-lp.c +0 -1
index db2841d0beb8..4a10fb940de5 100644
@@ -218,4 +218,3 @@ module_platform_driver(stm32_clkevent_lp_driver);
 
 MODULE_ALIAS("platform:stm32-lptimer-timer");
 MODULE_DESCRIPTION("STMicroelectronics STM32 clockevent low power driver");
-MODULE_LICENSE("GPL v2");
Signature · 1 line
2.39.1.268.g9de2f9a303
#12 lore raw

PATCH 9/27 kbuild, clocksource/drivers/timer-tegra186: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

Cc Luis Chamberlain <[email protected]>
Cc Hitomi Hasegawa <[email protected]>
Cc Daniel Lezcano <[email protected]>
Cc Thomas Gleixner <[email protected]>
Cc Thierry Reding <[email protected]>
Cc Jonathan Hunter <[email protected]>
---
 drivers/clocksource/timer-tegra186.c | 1 -
 1 file changed, 1 deletion(-)
drivers/clocksource/timer-tegra186.c +0 -1
index ea742889ee06..0c52c0a21830 100644
@@ -511,4 +511,3 @@ module_platform_driver(tegra186_wdt_driver);
 
 MODULE_AUTHOR("Thierry Reding <[email protected]>");
 MODULE_DESCRIPTION("NVIDIA Tegra186 timers driver");
-MODULE_LICENSE("GPL v2");
Signature · 1 line
2.39.1.268.g9de2f9a303
#13 lore raw

PATCH 10/27 kbuild, clocksource: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/clocksource/em_sti.c      | 1 -
 drivers/clocksource/sh_cmt.c      | 1 -
 drivers/clocksource/sh_mtu2.c     | 1 -
 drivers/clocksource/sh_tmu.c      | 1 -
 drivers/clocksource/timer-ti-dm.c | 1 -
 5 files changed, 5 deletions(-)
drivers/clocksource/em_sti.c +0 -1
index ab190dffb1ed..728bfca11d65 100644
@@ -368,4 +368,3 @@ module_exit(em_sti_exit);
 
 MODULE_AUTHOR("Magnus Damm");
 MODULE_DESCRIPTION("Renesas Emma Mobile STI Timer Driver");
-MODULE_LICENSE("GPL v2");
drivers/clocksource/sh_cmt.c +0 -1
index 7b952aa52c0b..81a9f35d5744 100644
@@ -1179,4 +1179,3 @@ module_exit(sh_cmt_exit);
 
 MODULE_AUTHOR("Magnus Damm");
 MODULE_DESCRIPTION("SuperH CMT Timer Driver");
-MODULE_LICENSE("GPL v2");
drivers/clocksource/sh_mtu2.c +0 -1
index 169a1fccc497..dd19553ef0b9 100644
@@ -530,4 +530,3 @@ module_exit(sh_mtu2_exit);
 
 MODULE_AUTHOR("Magnus Damm");
 MODULE_DESCRIPTION("SuperH MTU2 Timer Driver");
-MODULE_LICENSE("GPL v2");
drivers/clocksource/sh_tmu.c +0 -1
index b00dec0655cb..0641b5bca75b 100644
@@ -679,4 +679,3 @@ module_exit(sh_tmu_exit);
 
 MODULE_AUTHOR("Magnus Damm");
 MODULE_DESCRIPTION("SuperH TMU Timer Driver");
-MODULE_LICENSE("GPL v2");
drivers/clocksource/timer-ti-dm.c +0 -1
index b24b903a8822..1eb39834bad4 100644
@@ -1283,5 +1283,4 @@ static struct platform_driver omap_dm_timer_driver = {
 module_platform_driver(omap_dm_timer_driver);
 
 MODULE_DESCRIPTION("OMAP Dual-Mode Timer Driver");
-MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Texas Instruments Inc");
Signature · 1 line
2.39.1.268.g9de2f9a303
#14 lore raw

PATCH 11/27 kbuild, clk: bcm2835: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/clk/bcm/clk-bcm2835-aux.c | 1 -
 drivers/clk/bcm/clk-bcm2835.c     | 1 -
 2 files changed, 2 deletions(-)
drivers/clk/bcm/clk-bcm2835-aux.c +0 -1
index 290a2846a86b..0fafa5cba442 100644
@@ -69,4 +69,3 @@ builtin_platform_driver(bcm2835_aux_clk_driver);
 
 MODULE_AUTHOR("Eric Anholt <[email protected]>");
 MODULE_DESCRIPTION("BCM2835 auxiliary peripheral clock driver");
-MODULE_LICENSE("GPL");
drivers/clk/bcm/clk-bcm2835.c +0 -1
index e74fe6219d14..8dc476ef5bf9 100644
@@ -2350,4 +2350,3 @@ builtin_platform_driver(bcm2835_clk_driver);
 
 MODULE_AUTHOR("Eric Anholt <[email protected]>");
 MODULE_DESCRIPTION("BCM2835 clock driver");
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
maintainer Acked-by on v1 11/27
#15 lore raw

Re: [PATCH 11/27] kbuild, clk: bcm2835: remove MODULE_LICENSE in non-modules

Quoting Nick Alcock (2023-02-22 04:14:37)

Quoted 24 lines

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.

Quoted 1 line

---

Unless you want me to pick this up?

#16 lore raw

Re: [PATCH 11/27] kbuild, clk: bcm2835: remove MODULE_LICENSE in non-modules

Quoted 27 lines · Stephen Boyd

Quoting Nick Alcock (2023-02-22 04:14:37)

Quoted 24 lines

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.

Quoted 1 line

---

Quoted 3 lines

Unless you want me to pick this up?

Up to you, you can pick it up, and by rc3 of the next kernel I pick up the last stragglers that no one picks up as reflected on linux-next.

Luis

maintainer Applied
#17 lore raw

Re: [PATCH 11/27] kbuild, clk: bcm2835: remove MODULE_LICENSE in non-modules

In reply to Nick Alcock

Quoting Nick Alcock (2023-02-22 04:14:37)

Quoted 24 lines

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.

Quoted 1 line

---

Applied to clk-fixes

#18 lore raw

PATCH 12/27 kbuild, clk: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/clk/clk-fixed-mmio.c         | 1 -
 drivers/clk/clk-fsl-sai.c            | 1 -
 drivers/clk/hisilicon/clk-hi3559a.c  | 1 -
 drivers/clk/microchip/clk-mpfs-ccc.c | 1 -
 4 files changed, 4 deletions(-)
drivers/clk/clk-fixed-mmio.c +0 -1
index 5225d17d6b3f..8609fca29cc4 100644
@@ -99,4 +99,3 @@ module_platform_driver(of_fixed_mmio_clk_driver);
 
 MODULE_AUTHOR("Jan Kotas <[email protected]>");
 MODULE_DESCRIPTION("Memory Mapped IO Fixed clock driver");
-MODULE_LICENSE("GPL v2");
drivers/clk/clk-fsl-sai.c +0 -1
index 6238fcea0467..ee5baf993ff2 100644
@@ -88,5 +88,4 @@ module_platform_driver(fsl_sai_clk_driver);
 
 MODULE_DESCRIPTION("Freescale SAI bitclock-as-a-clock driver");
 MODULE_AUTHOR("Michael Walle <[email protected]>");
-MODULE_LICENSE("GPL");
 MODULE_ALIAS("platform:fsl-sai-clk");
drivers/clk/hisilicon/clk-hi3559a.c +0 -1
index 9ea1a80acbe8..8036bd8cbb0a 100644
@@ -841,5 +841,4 @@ static void __exit hi3559av100_crg_exit(void)
 module_exit(hi3559av100_crg_exit);
 
 
-MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("HiSilicon Hi3559AV100 CRG Driver");
drivers/clk/microchip/clk-mpfs-ccc.c +0 -1
index 32aae880a14f..6ee92c7925d7 100644
@@ -293,4 +293,3 @@ module_exit(clk_ccc_exit);
 
 MODULE_DESCRIPTION("Microchip PolarFire SoC Clock Conditioning Circuitry Driver");
 MODULE_AUTHOR("Conor Dooley <[email protected]>");
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
maintainer Reviewed-by Acked-by on v1 12/27
#19 lore raw

Re: [PATCH 12/27] kbuild, clk: remove MODULE_LICENSE in non-modules

Quoted 20 lines · Nick Alcock

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.

Quoted 1 line
 drivers/clk/microchip/clk-mpfs-ccc.c | 1 -

And since there's no reason to have this split via the at91 tree:

Clearly there's a hole in my maintainers entry for this driver, I'll go fix that.

maintainer Acked-by on v1 12/27
#20 lore raw

In reply to Nick Alcock

Quoting Nick Alcock (2023-02-22 04:14:38)

Quoted 19 lines

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.

Quoted 1 line

---

maintainer Applied
#21 lore raw

Re: [PATCH 12/27] kbuild, clk: remove MODULE_LICENSE in non-modules

In reply to Nick Alcock

Quoting Nick Alcock (2023-02-22 04:14:38)

Quoted 19 lines

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.

Quoted 1 line

---

Applied to clk-fixes

#22 lore raw

PATCH 13/27 kbuild, vgacon: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/video/console/vgacon.c | 1 -
 1 file changed, 1 deletion(-)
drivers/video/console/vgacon.c +0 -1
index fcdf017e2665..8e13af1f9042 100644
@@ -1204,4 +1204,3 @@ const struct consw vga_con = {
 };
 EXPORT_SYMBOL(vga_con);
 
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
#23 lore raw

PATCH 14/27 kbuild, cpufreq: tegra124: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

Cc Luis Chamberlain <[email protected]>
Cc Hitomi Hasegawa <[email protected]>
Cc "Rafael J. Wysocki" <[email protected]>
Cc Viresh Kumar <[email protected]>
Cc Thierry Reding <[email protected]>
Cc Jonathan Hunter <[email protected]>
---
 drivers/cpufreq/tegra124-cpufreq.c | 1 -
 1 file changed, 1 deletion(-)
drivers/cpufreq/tegra124-cpufreq.c +0 -1
index 7a1ea6fdcab6..788672c0c834 100644
@@ -221,4 +221,3 @@ module_init(tegra_cpufreq_init);
 
 MODULE_AUTHOR("Tuomas Tynkkynen <[email protected]>");
 MODULE_DESCRIPTION("cpufreq driver for NVIDIA Tegra124");
-MODULE_LICENSE("GPL v2");
Signature · 1 line
2.39.1.268.g9de2f9a303
maintainer Applied
#24 lore raw

Re: [PATCH 14/27] kbuild, cpufreq: tegra124: remove MODULE_LICENSE in non-modules

Quoted 22 lines · Nick Alcock

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.

Cc Luis Chamberlain <[email protected]>
Cc Hitomi Hasegawa <[email protected]>
Cc "Rafael J. Wysocki" <[email protected]>
Cc Viresh Kumar <[email protected]>
Cc Thierry Reding <[email protected]>
Cc Jonathan Hunter <[email protected]>
Quoted 3 lines
---
 drivers/cpufreq/tegra124-cpufreq.c | 1 -
 1 file changed, 1 deletion(-)

Applied. Thanks.

Signature · 1 line
viresh
#25 lore raw

PATCH 15/27 kbuild, cpufreq: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/cpufreq/freq_table.c | 1 -
 1 file changed, 1 deletion(-)
drivers/cpufreq/freq_table.c +0 -1
index 67e56cf638ef..90bfc27ed1ba 100644
@@ -367,4 +367,3 @@ int cpufreq_table_validate_and_sort(struct cpufreq_policy *policy)
 
 MODULE_AUTHOR("Dominik Brodowski <[email protected]>");
 MODULE_DESCRIPTION("CPUfreq frequency table helpers");
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
maintainer Applied
#26 lore raw

Re: [PATCH 15/27] kbuild, cpufreq: remove MODULE_LICENSE in non-modules

Quoted 19 lines · Nick Alcock

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.

Quoted 3 lines
---
 drivers/cpufreq/freq_table.c | 1 -
 1 file changed, 1 deletion(-)

Applied. Thanks.

Signature · 1 line
viresh
#27 lore raw

PATCH 16/27 kbuild, crypto: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 lib/crypto/blake2s-generic.c | 1 -
 lib/crypto/blake2s.c         | 1 -
 2 files changed, 2 deletions(-)
lib/crypto/blake2s-generic.c +0 -1
index 75ccb3e633e6..4ffe3d927920 100644
@@ -110,6 +110,5 @@ void blake2s_compress_generic(struct blake2s_state *state, const u8 *block,
 
 EXPORT_SYMBOL(blake2s_compress_generic);
 
-MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("BLAKE2s hash function");
 MODULE_AUTHOR("Jason A. Donenfeld <[email protected]>");
lib/crypto/blake2s.c +0 -1
index 98e688c6d891..71a316552cc5 100644
@@ -67,6 +67,5 @@ static int __init blake2s_mod_init(void)
 }
 
 module_init(blake2s_mod_init);
-MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("BLAKE2s hash function");
 MODULE_AUTHOR("Jason A. Donenfeld <[email protected]>");
Signature · 1 line
2.39.1.268.g9de2f9a303
maintainer
#28 lore raw

Re: [PATCH 16/27] kbuild, crypto: remove MODULE_LICENSE in non-modules

lib/crypto/blake2s-generic.c void blake2s_compress_generic(struct blake2s_state *state, const u8 *block, · line 114

Quoted 12 lines · Nick Alcock
lib/crypto/blake2s-generic.c +0 -1
index 75ccb3e633e6..4ffe3d927920 100644
@@ -110,6 +110,5 @@ void blake2s_compress_generic(struct blake2s_state *state, const u8 *block,
 
 EXPORT_SYMBOL(blake2s_compress_generic);
 
-MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("BLAKE2s hash function");
 MODULE_AUTHOR("Jason A. Donenfeld <[email protected]>");

Please remove all module-related code and the inclusion of module.h.

Thanks,

Signature · 3 lines
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
#29 lore raw

PATCH 17/27 kbuild, crypto: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

Cc Luis Chamberlain <[email protected]>
Cc Hitomi Hasegawa <[email protected]>
Cc Herbert Xu <[email protected]>
Cc "David S. Miller" <[email protected]>
Cc Thomas Gleixner <[email protected]>
Cc Ingo Molnar <[email protected]>
Cc Borislav Petkov <[email protected]>
Cc Dave Hansen <[email protected]>
---
 arch/x86/crypto/blake2s-glue.c | 1 -
 1 file changed, 1 deletion(-)
arch/x86/crypto/blake2s-glue.c +0 -1
index aaba21230528..0df9ec15643a 100644
@@ -74,4 +74,3 @@ static int __init blake2s_mod_init(void)
 
 module_init(blake2s_mod_init);
 
-MODULE_LICENSE("GPL v2");
Signature · 1 line
2.39.1.268.g9de2f9a303
maintainer
#30 lore raw

Re: [PATCH 17/27] kbuild, crypto: remove MODULE_LICENSE in non-modules

arch/x86/crypto/blake2s-glue.c static int __init blake2s_mod_init(void) · line 77

Quoted 10 lines · Nick Alcock
arch/x86/crypto/blake2s-glue.c +0 -1
index aaba21230528..0df9ec15643a 100644
@@ -74,4 +74,3 @@ static int __init blake2s_mod_init(void)
 
 module_init(blake2s_mod_init);
 
-MODULE_LICENSE("GPL v2");

Please change the module_init as well and remove module.h from this file.

Thanks,

Signature · 3 lines
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
#31 lore raw

PATCH 18/27 kbuild, mfd: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/mfd/da903x.c      | 1 -
 drivers/mfd/da9052-core.c | 1 -
 drivers/mfd/da9052-i2c.c  | 1 -
 drivers/mfd/da9052-spi.c  | 1 -
 drivers/mfd/da9055-core.c | 1 -
 drivers/mfd/da9055-i2c.c  | 1 -
 6 files changed, 6 deletions(-)
drivers/mfd/da903x.c +0 -1
index 44a25d642ce9..6570b33a5a77 100644
@@ -563,4 +563,3 @@ module_exit(da903x_exit);
 MODULE_DESCRIPTION("PMIC Driver for Dialog Semiconductor DA9034");
 MODULE_AUTHOR("Eric Miao <[email protected]>");
 MODULE_AUTHOR("Mike Rapoport <[email protected]>");
-MODULE_LICENSE("GPL v2");
drivers/mfd/da9052-core.c +0 -1
index 8b42d2f7024f..150448cd2eb0 100644
@@ -653,4 +653,3 @@ void da9052_device_exit(struct da9052 *da9052)
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("DA9052 MFD Core");
-MODULE_LICENSE("GPL");
drivers/mfd/da9052-i2c.c +0 -1
index ecb8077cdaaf..03db7a2ccf7a 100644
@@ -209,4 +209,3 @@ module_exit(da9052_i2c_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("I2C driver for Dialog DA9052 PMIC");
-MODULE_LICENSE("GPL");
drivers/mfd/da9052-spi.c +0 -1
index b79a57b45c1e..be5f2b34e18a 100644
@@ -102,4 +102,3 @@ module_exit(da9052_spi_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("SPI driver for Dialog DA9052 PMIC");
-MODULE_LICENSE("GPL");
drivers/mfd/da9055-core.c +0 -1
index c3bcbd8905c6..768302e05baa 100644
@@ -398,5 +398,4 @@ void da9055_device_exit(struct da9055 *da9055)
 }
 
 MODULE_DESCRIPTION("Core support for the DA9055 PMIC");
-MODULE_LICENSE("GPL");
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
drivers/mfd/da9055-i2c.c +0 -1
index 702abff506a1..537fd5de3e6d 100644
@@ -97,4 +97,3 @@ module_exit(da9055_i2c_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("I2C driver for Dialog DA9055 PMIC");
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
Reviewed-by on v1 18/27
#32 lore raw

RE: [PATCH 18/27] kbuild, mfd: remove MODULE_LICENSE in non-modules

Quoted 3 lines · Nick Alcock

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.

Makes sense - but if you need to do a V2, would you mind removing the erroneous claim on DA9055 at the same time?
https://elixir.bootlin.com/linux/latest/source/drivers/mfd/Kconfig#L364
Strangely, seems it was always there, yet always bool...

maintainer
#33 lore raw

Re: [PATCH 18/27] kbuild, mfd: remove MODULE_LICENSE in non-modules

Quoted 6 lines · DLG Adam Ward
Quoted 3 lines · Nick Alcock

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.

Makes sense - but if you need to do a V2, would you mind removing the erroneous claim on DA9055 at the same time?

Could you do this anyway please. While you're at it, please remove the 'kbuild' reference from the subject line, thanks.

Quoted 4 lines

https://elixir.bootlin.com/linux/latest/source/drivers/mfd/Kconfig#L364
Strangely, seems it was always there, yet always bool...

Thanks Adam.

Signature · 1 line
Lee Jones [李琼斯]
#34 lore raw

Re: [PATCH 18/27] kbuild, mfd: remove MODULE_LICENSE in non-modules

On 23 Feb 2023, Lee Jones stated:

Quoted 8 lines · DLG Adam Ward
Quoted 7 lines · Nick Alcock
Quoted 3 lines

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.

Makes sense - but if you need to do a V2, would you mind removing the erroneous claim on DA9055 at the same time?

I don't know what this means. There are two references to DA9055 in this patch, both in context (not in modified lines), one in drivers/mfd/da9055-core.c, the other in rivers/mfd/da9055-i2c.c. To me these both seem likely to be DA9055-related. Are you saying that one of them isn't?

Quoted 2 lines

Could you do this anyway please. While you're at it, please remove the 'kbuild' reference from the subject line, thanks.

I was going to say that it seems to be in active use, but I just checked and a total of zero files touched by this series have ever used 'kbuild' in their log prefixes anywhere. So... dropped, series-wide. (By the overdesigned approach of using a kbuild: prefix if and only if at least one file in the files touched in that commit has used that prefix somewhere in its history.)

Signature · 1 line
NULL && (void)
#35 lore raw

RE: [PATCH 18/27] kbuild, mfd: remove MODULE_LICENSE in non-modules

Quoted 3 lines · Nick Alcock
Quoted 1 line

Makes sense - but if you need to do a V2, would you mind removing the erroneous claim on DA9055 at the same time?

I don't know what this means. There are two references to DA9055 in this patch, both in context (not in modified lines), one in drivers/mfd/da9055-core.c, the other in rivers/mfd/da9055-i2c.c. To me these both seem likely to be DA9055-related. Are you saying that one of them isn't?

The comment was followed by this link - https://elixir.bootlin.com/linux/latest/source/drivers/mfd/Kconfig#L36
This files talks about the driver being a module, but, as you correctly point out, it is not. And never has been.
So it is worth removing.

#36 lore raw

Re: [PATCH 18/27] kbuild, mfd: remove MODULE_LICENSE in non-modules

On 24 Feb 2023, DLG Adam Ward told this:

Quoted 10 lines · Nick Alcock
Quoted 4 lines
Quoted 2 lines

Makes sense - but if you need to do a V2, would you mind removing the erroneous claim on DA9055 at the same time?

I don't know what this means. There are two references to DA9055 in this patch, both in context (not in modified lines), one in drivers/mfd/da9055-core.c, the other in rivers/mfd/da9055-i2c.c. To me these both seem likely to be DA9055-related. Are you saying that one of them isn't?

The comment was followed by this link - https://elixir.bootlin.com/linux/latest/source/drivers/mfd/Kconfig#L36
This files talks about the driver being a module, but, as you correctly point out, it is not. And never has been.
So it is worth removing.

Ah! I never even thought of auditing the Kconfigs for erroneous statements of modularity: that's a much harder-to-automate job.

I'm not planning to do this in general any time soon (because I'd have to soup up Kconfig parsers and maybe write my own just for this), but here's a reroll of this one patch that drops the erroneous Kconfig help text:

-- >8 --

From 06d491176513f9fcd699871cb6815534068b664a Mon Sep 17 00:00:00 2001
From: Nick Alcock <[email protected]>
Date: Thu, 23 Feb 2023 19:10:03 +0000
Subject: [PATCH v2 18/27] mfd: remove MODULE_LICENSE in non-modules

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.

---
 drivers/mfd/Kconfig       | 3 ---
 drivers/mfd/da903x.c      | 1 -
 drivers/mfd/da9052-core.c | 1 -
 drivers/mfd/da9052-i2c.c  | 1 -
 drivers/mfd/da9052-spi.c  | 1 -
 drivers/mfd/da9055-core.c | 1 -
 drivers/mfd/da9055-i2c.c  | 1 -
 7 files changed, 9 deletions(-)
drivers/mfd/Kconfig +0 -3
index 30db49f318668..751d38b30bb1f 100644
@@ -361,9 +361,6 @@ config MFD_DA9055
 	  Additional drivers must be enabled in order to use the functionality
 	  of the device.
 
-	  This driver can be built as a module. If built as a module it will be
-	  called "da9055"
-
 config MFD_DA9062
 	tristate "Dialog Semiconductor DA9062/61 PMIC Support"
 	select MFD_CORE
drivers/mfd/da903x.c +0 -1
index 44a25d642ce94..6570b33a5a77b 100644
@@ -563,4 +563,3 @@ module_exit(da903x_exit);
 MODULE_DESCRIPTION("PMIC Driver for Dialog Semiconductor DA9034");
 MODULE_AUTHOR("Eric Miao <[email protected]>");
 MODULE_AUTHOR("Mike Rapoport <[email protected]>");
-MODULE_LICENSE("GPL v2");
drivers/mfd/da9052-core.c +0 -1
index 8b42d2f7024f5..150448cd2eb08 100644
@@ -653,4 +653,3 @@ void da9052_device_exit(struct da9052 *da9052)
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("DA9052 MFD Core");
-MODULE_LICENSE("GPL");
drivers/mfd/da9052-i2c.c +0 -1
index ecb8077cdaaf9..03db7a2ccf7a0 100644
@@ -209,4 +209,3 @@ module_exit(da9052_i2c_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("I2C driver for Dialog DA9052 PMIC");
-MODULE_LICENSE("GPL");
drivers/mfd/da9052-spi.c +0 -1
index b79a57b45c1e8..be5f2b34e18ae 100644
@@ -102,4 +102,3 @@ module_exit(da9052_spi_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("SPI driver for Dialog DA9052 PMIC");
-MODULE_LICENSE("GPL");
drivers/mfd/da9055-core.c +0 -1
index c3bcbd8905c6c..768302e05baa1 100644
@@ -398,5 +398,4 @@ void da9055_device_exit(struct da9055 *da9055)
 }
 
 MODULE_DESCRIPTION("Core support for the DA9055 PMIC");
-MODULE_LICENSE("GPL");
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
drivers/mfd/da9055-i2c.c +0 -1
index 702abff506a1a..537fd5de3e6d4 100644
@@ -97,4 +97,3 @@ module_exit(da9055_i2c_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("I2C driver for Dialog DA9055 PMIC");
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
maintainer
#37 lore raw

Re: [PATCH 18/27] kbuild, mfd: remove MODULE_LICENSE in non-modules

Quoted 16 lines · Nick Alcock

On 24 Feb 2023, DLG Adam Ward told this:

Quoted 10 lines · Nick Alcock
Quoted 4 lines
Quoted 2 lines

Makes sense - but if you need to do a V2, would you mind removing the erroneous claim on DA9055 at the same time?

I don't know what this means. There are two references to DA9055 in this patch, both in context (not in modified lines), one in drivers/mfd/da9055-core.c, the other in rivers/mfd/da9055-i2c.c. To me these both seem likely to be DA9055-related. Are you saying that one of them isn't?

The comment was followed by this link - https://elixir.bootlin.com/linux/latest/source/drivers/mfd/Kconfig#L36
This files talks about the driver being a module, but, as you correctly point out, it is not. And never has been.
So it is worth removing.

Ah! I never even thought of auditing the Kconfigs for erroneous statements of modularity: that's a much harder-to-automate job.

Quoted 6 lines

I'm not planning to do this in general any time soon (because I'd have to soup up Kconfig parsers and maybe write my own just for this), but here's a reroll of this one patch that drops the erroneous Kconfig help text:

-- >8 --

Can you submit this as an orthogonal v2 please?

Quoted 104 lines

From 06d491176513f9fcd699871cb6815534068b664a Mon Sep 17 00:00:00 2001
From: Nick Alcock <[email protected]>
Date: Thu, 23 Feb 2023 19:10:03 +0000
Subject: [PATCH v2 18/27] mfd: remove MODULE_LICENSE in non-modules

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.

---
 drivers/mfd/Kconfig       | 3 ---
 drivers/mfd/da903x.c      | 1 -
 drivers/mfd/da9052-core.c | 1 -
 drivers/mfd/da9052-i2c.c  | 1 -
 drivers/mfd/da9052-spi.c  | 1 -
 drivers/mfd/da9055-core.c | 1 -
 drivers/mfd/da9055-i2c.c  | 1 -
 7 files changed, 9 deletions(-)
drivers/mfd/Kconfig +0 -3
index 30db49f318668..751d38b30bb1f 100644
@@ -361,9 +361,6 @@ config MFD_DA9055
 	  Additional drivers must be enabled in order to use the functionality
 	  of the device.
 
-	  This driver can be built as a module. If built as a module it will be
-	  called "da9055"
-
 config MFD_DA9062
 	tristate "Dialog Semiconductor DA9062/61 PMIC Support"
 	select MFD_CORE
drivers/mfd/da903x.c +0 -1
index 44a25d642ce94..6570b33a5a77b 100644
@@ -563,4 +563,3 @@ module_exit(da903x_exit);
 MODULE_DESCRIPTION("PMIC Driver for Dialog Semiconductor DA9034");
 MODULE_AUTHOR("Eric Miao <[email protected]>");
 MODULE_AUTHOR("Mike Rapoport <[email protected]>");
-MODULE_LICENSE("GPL v2");
drivers/mfd/da9052-core.c +0 -1
index 8b42d2f7024f5..150448cd2eb08 100644
@@ -653,4 +653,3 @@ void da9052_device_exit(struct da9052 *da9052)
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("DA9052 MFD Core");
-MODULE_LICENSE("GPL");
drivers/mfd/da9052-i2c.c +0 -1
index ecb8077cdaaf9..03db7a2ccf7a0 100644
@@ -209,4 +209,3 @@ module_exit(da9052_i2c_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("I2C driver for Dialog DA9052 PMIC");
-MODULE_LICENSE("GPL");
drivers/mfd/da9052-spi.c +0 -1
index b79a57b45c1e8..be5f2b34e18ae 100644
@@ -102,4 +102,3 @@ module_exit(da9052_spi_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("SPI driver for Dialog DA9052 PMIC");
-MODULE_LICENSE("GPL");
drivers/mfd/da9055-core.c +0 -1
index c3bcbd8905c6c..768302e05baa1 100644
@@ -398,5 +398,4 @@ void da9055_device_exit(struct da9055 *da9055)
 }
 
 MODULE_DESCRIPTION("Core support for the DA9055 PMIC");
-MODULE_LICENSE("GPL");
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
drivers/mfd/da9055-i2c.c +0 -1
index 702abff506a1a..537fd5de3e6d4 100644
@@ -97,4 +97,3 @@ module_exit(da9055_i2c_exit);
 
 MODULE_AUTHOR("David Dajun Chen <[email protected]>");
 MODULE_DESCRIPTION("I2C driver for Dialog DA9055 PMIC");
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
Signature · 1 line
Lee Jones [李琼斯]
#38 lore raw

PATCH 19/27 kbuild, dmaengine: stm32-mdma: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/dma/stm32-dmamux.c | 1 -
 drivers/dma/stm32-mdma.c   | 1 -
 2 files changed, 2 deletions(-)
drivers/dma/stm32-dmamux.c +0 -1
index ee3cbbf51006..8d8bb6770cc2 100644
@@ -400,4 +400,3 @@ arch_initcall(stm32_dmamux_init);
 MODULE_DESCRIPTION("DMA Router driver for STM32 DMA MUX");
 MODULE_AUTHOR("M'boumba Cedric Madianga <[email protected]>");
 MODULE_AUTHOR("Pierre-Yves Mordret <[email protected]>");
-MODULE_LICENSE("GPL v2");
drivers/dma/stm32-mdma.c +0 -1
index b9d4c843635f..3f2e7a55cd03 100644
@@ -1816,4 +1816,3 @@ subsys_initcall(stm32_mdma_init);
 MODULE_DESCRIPTION("Driver for STM32 MDMA controller");
 MODULE_AUTHOR("M'boumba Cedric Madianga <[email protected]>");
 MODULE_AUTHOR("Pierre-Yves Mordret <[email protected]>");
-MODULE_LICENSE("GPL v2");
Signature · 7 lines
2.39.1.268.g9de2f9a303


_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
#39 lore raw

PATCH 20/27 kbuild, dmaengine: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/dma/ep93xx_dma.c    | 1 -
 drivers/dma/ipu/ipu_idmac.c | 1 -
 drivers/dma/mv_xor_v2.c     | 1 -
 drivers/dma/sh/shdma-base.c | 1 -
 4 files changed, 4 deletions(-)
drivers/dma/ep93xx_dma.c +0 -1
index d19ea885c63e..5338a94f1a69 100644
@@ -1431,4 +1431,3 @@ subsys_initcall(ep93xx_dma_module_init);
 
 MODULE_AUTHOR("Mika Westerberg <[email protected]>");
 MODULE_DESCRIPTION("EP93xx DMA driver");
-MODULE_LICENSE("GPL");
drivers/dma/ipu/ipu_idmac.c +0 -1
index baab1ca9f621..d799b99c18bd 100644
@@ -1797,6 +1797,5 @@ static int __init ipu_init(void)
 subsys_initcall(ipu_init);
 
 MODULE_DESCRIPTION("IPU core driver");
-MODULE_LICENSE("GPL v2");
 MODULE_AUTHOR("Guennadi Liakhovetski <[email protected]>");
 MODULE_ALIAS("platform:ipu-core");
drivers/dma/mv_xor_v2.c +0 -1
index 113834e1167b..22f485465951 100644
@@ -920,4 +920,3 @@ static struct platform_driver mv_xor_v2_driver = {
 module_platform_driver(mv_xor_v2_driver);
 
 MODULE_DESCRIPTION("DMA engine driver for Marvell's Version 2 of XOR engine");
-MODULE_LICENSE("GPL");
drivers/dma/sh/shdma-base.c +0 -1
index 158e5e7defae..588c5f409a80 100644
@@ -1047,6 +1047,5 @@ static void __exit shdma_exit(void)
 }
 module_exit(shdma_exit);
 
-MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("SH-DMA driver base library");
 MODULE_AUTHOR("Guennadi Liakhovetski <[email protected]>");
Signature · 1 line
2.39.1.268.g9de2f9a303
#40 lore raw

PATCH 21/27 kbuild, dma-mapping: benchmark: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 kernel/dma/map_benchmark.c | 1 -
 1 file changed, 1 deletion(-)
kernel/dma/map_benchmark.c +0 -1
index 0520a8f4fb1d..02205ab53b7e 100644
@@ -356,4 +356,3 @@ module_exit(map_benchmark_cleanup);
 
 MODULE_AUTHOR("Barry Song <[email protected]>");
 MODULE_DESCRIPTION("dma_map benchmark driver");
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
Reviewed-by on v1 21/27
#41 lore raw

Re: [PATCH 21/27] kbuild, dma-mapping: benchmark: remove MODULE_LICENSE in non-modules

Looks good:

Quoted 3 lines · Nick Alcock

Since commit 8b41fc4454e ("kbuild: create modules.builtin without Makefile.modbuiltin or tristate.conf"), MODULE_LICENSE declarations are used to identify modules.

.. but this seems like a really odd design. How is this going to continue working once we can autogenerate the module license section from the SPDX tags, which we eventually really should?

#42 lore raw

Re: [PATCH 21/27] kbuild, dma-mapping: benchmark: remove MODULE_LICENSE in non-modules

Quoted 4 lines · Christoph Hellwig

Looks good:

Quoted 8 lines
Quoted 3 lines · Nick Alcock

Since commit 8b41fc4454e ("kbuild: create modules.builtin without Makefile.modbuiltin or tristate.conf"), MODULE_LICENSE declarations are used to identify modules.

.. but this seems like a really odd design. How is this going to continue working once we can autogenerate the module license section from the SPDX tags, which we eventually really should?

Yes I totally agree we should. But I think we should take this by steps. First, we ensure we have only MODULE_LICENSE() macros upstream on things which are really possible modules, ie we remove the false positives. We then put a stop-gap script which can complain if it finds new usecases which are buggy.

Then we look for an optimal way to address the final step:

* remove all MODULE_LICENSE() and autogenerate them from SPDX

The difficulty in this will be that we want to upkeep existing build heuristics and avoid to have to traverse the tree twice (see details on commit 8b41fc4454e). I can't think of an easy way to do this that does not involve using kconfig tristate somehow. This is a bit of tricky homework we have. Perhaps Masahiro can come up with something clever.

Luis

#43 lore raw

Re: [PATCH 21/27] kbuild, dma-mapping: benchmark: remove MODULE_LICENSE in non-modules

On 22 Feb 2023, Luis Chamberlain spake thusly:

Quoted 10 lines · Christoph Hellwig
Quoted 9 lines

Looks good:

Quoted 3 lines · Nick Alcock

Since commit 8b41fc4454e ("kbuild: create modules.builtin without Makefile.modbuiltin or tristate.conf"), MODULE_LICENSE declarations are used to identify modules.

Quoted 8 lines
Quoted 3 lines

.. but this seems like a really odd design. How is this going to continue working once we can autogenerate the module license section from the SPDX tags, which we eventually really should?

Yes I totally agree we should. But I think we should take this by steps. First, we ensure we have only MODULE_LICENSE() macros upstream on things which are really possible modules, ie we remove the false positives. We then put a stop-gap script which can complain if it finds new usecases which are buggy.

(and we have such a script already, though it's not in-tree: I used it to generate the list of affected files that make up this series. I'll keep running it at least once per release cycle to identify regressions in this area, and fix them as they come up.)

Quoted 3 lines

Then we look for an optimal way to address the final step:

* remove all MODULE_LICENSE() and autogenerate them from SPDX

Ooh that would be nice!

Quoted 4 lines

The difficulty in this will be that we want to upkeep existing build heuristics and avoid to have to traverse the tree twice (see details on commit 8b41fc4454e). I can't think of an easy way to do this that does not involve using kconfig tristate somehow.

Nor can I -- and more generally I can't figure out a way to get from the Kconfig symbols to the source files that constitute them without retraversing the tree, since the only place the relationship is recorded is in makefiles, and those makefiles use a lot of make functionality (including more or less arbitrary make functions).

(restating the underlying difficulty here in case, like me, you lost
track of it over the last few months)

Of course the build process is doing that traversal anyway -- the problem is that the only approach we have to get from tristate to a list of modules-or-builtins involves emitting *different values* for CONFIG_ symbols (uppercase rather than lowercase) and then triggering on those to do things -- and if you do that you can't simultaneously use those CONFIG_ variables for their normal purpose.

We can't rename those variables for this purpose because we're depending on makefiles all across the tree expanding them. I tried to arrange for their expansion to have side effects (so that evaluating $(CONFIG_FOO) produced both 'y' or 'm' and *also* did... *something* that produced an object file list for our consumption) but that also doesn't work because unfortunately the tristate determination code needs a *mapping* from CONFIG_ variable value to the result of the variable expansion, and a line like

foo-$(CONFIG_FOO) := x y z

doesn't let the expansion of CONFIG_FOO have any sort of access to the result of the assignment to foo-y / foo-m, and after the assignment's happened there's no way to tell that the $(foo-m) -> x y z mapping was generated by the expansion of CONFIG_FOO in particlar. So multiple evaluations (which means, in effect, multiple make invocations) seems to be the only way.

I do hope Masahiro has some brilliant idea here. Mind you I'm not sure I'm clever enough to have come up with the original Makefile.modbuiltin scheme either...

#44 lore raw

Re: [PATCH 21/27] kbuild, dma-mapping: benchmark: remove MODULE_LICENSE in non-modules

Quoted 12 lines · Nick Alcock

On 22 Feb 2023, Luis Chamberlain spake thusly:

Quoted 3 lines

Then we look for an optimal way to address the final step:

* remove all MODULE_LICENSE() and autogenerate them from SPDX

Ooh that would be nice!

Quoted 4 lines

The difficulty in this will be that we want to upkeep existing build heuristics and avoid to have to traverse the tree twice (see details on commit 8b41fc4454e). I can't think of an easy way to do this that does not involve using kconfig tristate somehow.

Quoted 5 lines

Nor can I -- and more generally I can't figure out a way to get from the Kconfig symbols to the source files that constitute them without retraversing the tree, since the only place the relationship is recorded is in makefiles, and those makefiles use a lot of make functionality (including more or less arbitrary make functions).

$ grep "_MODULE 1" ./include/generated/autoconf.h| wc -l
560
$ grep "_MODULE 1" ./include/generated/autoconf.h| grep XFS
#define CONFIG_XFS_FS_MODULE 1

I *think* the trick will likely be to have new a possibilities.h or just agument autoconf.h with POSSIBLE_MODULE for each module.

The next complexity lies in inferring the license and doing the license output given a combination. I *think* you already figured out the objs from the module, and in fact your new kallsyms extension I think prints these out right (which I find highly useful)? If so then we use these as input source for an SPDX license lookup. Instead of having this relationship grep'd after at build time, I wonder if might be good to just collect all license associates to all files in a header file similar to _MODULE prefix so maybe SPDX_$(file_path)_LICENSE_$license which creates a header file 1-1 mapping.

Not sure if that's too much noise.

Just a thought, to get the wheels spinning.

Luis

#45 lore raw

Re: [PATCH 21/27] kbuild, dma-mapping: benchmark: remove MODULE_LICENSE in non-modules

On 23 Feb 2023, Luis Chamberlain outgrape:

Quoted 13 lines · Nick Alcock
Quoted 5 lines

Nor can I -- and more generally I can't figure out a way to get from the Kconfig symbols to the source files that constitute them without retraversing the tree, since the only place the relationship is recorded is in makefiles, and those makefiles use a lot of make functionality (including more or less arbitrary make functions).

$ grep "_MODULE 1" ./include/generated/autoconf.h| wc -l
560
$ grep "_MODULE 1" ./include/generated/autoconf.h| grep XFS
#define CONFIG_XFS_FS_MODULE 1
Quoted 7 lines

I *think* the trick will likely be to have new a possibilities.h or just agument autoconf.h with POSSIBLE_MODULE for each module.

The next complexity lies in inferring the license and doing the license output given a combination. I *think* you already figured out the objs from the module, and in fact your new kallsyms extension I think prints these out right (which I find highly useful)?

Oh, of course, I forgot about that (how stupid of me). Of course the double-traversal is only necessary if we're trying to *compare* the results of tristate in Kconfig with the result of the modinfo objs=: if we assume the modinfo objs= is right (which it should be in the end), we can just rely on it and then we don't need to double-traverse after all, except when verifying that (which is a rare intermittent maintenance task).

(Of course, kallmodsyms elides all objnames that aren't necessary for symbol disambiguation and reduces the length of what it keeps as far as it can, but I'm open to an option that just stores the lot, unelided: it would eat ~750KiB in the kernel image for all but very small kernels, but for debugging that's fine. Saving more space than that requires storing the things in a per-path-component tree or something, and would likely still eat >500K because the leaves are extremely numerous.)

Quoted 10 lines

If so then we use these as
input source for an SPDX license lookup. Instead of having this relationship grep'd after at build time, I wonder if might be good to just collect all license associates to all files in a header file similar to _MODULE prefix so maybe SPDX_$(file_path)_LICENSE_$license which creates a header file 1-1 mapping.

Not sure if that's too much noise.

Just a thought, to get the wheels spinning.

The only problem that I can see with that is that this stops us using MODULE_LICENSE for modinfo construction, since right now things like the objs= and the module name are dependent on per-module #defines passed in via -D, which obviously can only have one value while compiling a single file. But it would be perfectly doable to rename MODULE_LICENSE() to something like a zero-arg MODULE_INFO() and relieve it of the responsibility for setting the license, so we could put the license info into a single file as you suggest. Non-builtin modules could just stuff a single MODULE_LICENSE line in the mod.c.

Signature · 1 line
NULL && (void)
#46 lore raw

Re: [PATCH 21/27] kbuild, dma-mapping: benchmark: remove MODULE_LICENSE in non-modules

Quoted 2 lines · Nick Alcock

The only problem that I can see with that is that this stops us using MODULE_LICENSE for modinfo construction,

Yes, the requirement shifts to having us *write* the module license from the combination computation of files from SPDX, so although not present anymore what changes is a new target / goal in ordering which has us construct that define for the file.

Easier said than done of course.

Luis

#47 lore raw

PATCH 22/27 kbuild, dma-buf: heaps: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/dma-buf/heaps/cma_heap.c    | 1 -
 drivers/dma-buf/heaps/system_heap.c | 1 -
 2 files changed, 2 deletions(-)
drivers/dma-buf/heaps/cma_heap.c +0 -1
index 1131fb943992..a7f048048864 100644
@@ -407,4 +407,3 @@ static int add_default_cma_heap(void)
 }
 module_init(add_default_cma_heap);
 MODULE_DESCRIPTION("DMA-BUF CMA Heap");
-MODULE_LICENSE("GPL v2");
drivers/dma-buf/heaps/system_heap.c +0 -1
index e8bd10e60998..79c03f5b4e28 100644
@@ -440,4 +440,3 @@ static int system_heap_create(void)
 	return 0;
 }
 module_init(system_heap_create);
-MODULE_LICENSE("GPL v2");
Signature · 1 line
2.39.1.268.g9de2f9a303
#48 lore raw

PATCH 23/27 kbuild, drm/dsi: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

Cc Luis Chamberlain <[email protected]>
Cc Hitomi Hasegawa <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>
Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
---
 drivers/gpu/drm/drm_mipi_dsi.c | 1 -
 1 file changed, 1 deletion(-)
drivers/gpu/drm/drm_mipi_dsi.c +0 -1
index 497ef4b6a90a..4101d9780059 100644
@@ -1294,4 +1294,3 @@ postcore_initcall(mipi_dsi_bus_init);
 
 MODULE_AUTHOR("Andrzej Hajda <[email protected]>");
 MODULE_DESCRIPTION("MIPI DSI Bus");
-MODULE_LICENSE("GPL and additional rights");
Signature · 1 line
2.39.1.268.g9de2f9a303
#49 lore raw

PATCH 24/27 kbuild, binfmt_elf: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 fs/binfmt_elf.c | 1 -
 1 file changed, 1 deletion(-)
fs/binfmt_elf.c +0 -1
index 9a780fafc539..40e87c0eaf15 100644
@@ -2169,7 +2169,6 @@ static void __exit exit_elf_binfmt(void)
 
 core_initcall(init_elf_binfmt);
 module_exit(exit_elf_binfmt);
-MODULE_LICENSE("GPL");
 
 #ifdef CONFIG_BINFMT_ELF_KUNIT_TEST
 #include "binfmt_elf_test.c"
Signature · 1 line
2.39.1.268.g9de2f9a303
#50 lore raw

PATCH 25/27 kbuild, video: fbdev: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

---
 drivers/video/fbdev/asiliantfb.c                | 1 -
 drivers/video/fbdev/gbefb.c                     | 1 -
 drivers/video/fbdev/mmp/hw/mmp_ctrl.c           | 1 -
 drivers/video/fbdev/mmp/panel/tpo_tj032md01bw.c | 1 -
 drivers/video/fbdev/vesafb.c                    | 1 -
 5 files changed, 5 deletions(-)
drivers/video/fbdev/asiliantfb.c +0 -1
index 8383468f5577..0d33c75afc48 100644
@@ -632,4 +632,3 @@ static void __exit asiliantfb_exit(void)
 	pci_unregister_driver(&asiliantfb_driver);
 }
 
-MODULE_LICENSE("GPL");
drivers/video/fbdev/gbefb.c +0 -1
index 000b4aa44241..39e89b9f8dca 100644
@@ -1285,4 +1285,3 @@ static void __exit gbefb_exit(void)
 module_init(gbefb_init);
 module_exit(gbefb_exit);
 
-MODULE_LICENSE("GPL");
drivers/video/fbdev/mmp/hw/mmp_ctrl.c +0 -1
index a9df8ee79810..8b2838a67b76 100644
@@ -576,4 +576,3 @@ module_init(mmphw_init);
 
 MODULE_AUTHOR("Li Guoqing<[email protected]>");
 MODULE_DESCRIPTION("Framebuffer driver for mmp");
-MODULE_LICENSE("GPL");
drivers/video/fbdev/mmp/panel/tpo_tj032md01bw.c +0 -1
index 34fae588e202..84ed83ee2366 100644
@@ -169,4 +169,3 @@ module_spi_driver(panel_tpohvga_driver);
 
 MODULE_AUTHOR("Lisa Du<[email protected]>");
 MODULE_DESCRIPTION("Panel driver for tpohvga");
-MODULE_LICENSE("GPL");
drivers/video/fbdev/vesafb.c +0 -1
index 929d4775cb4b..73b35fc67d8b 100644
@@ -508,4 +508,3 @@ static struct platform_driver vesafb_driver = {
 };
 
 module_platform_driver(vesafb_driver);
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
#51 lore raw

PATCH 26/27 kbuild, phy: intel: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

Cc Luis Chamberlain <[email protected]>
Cc Hitomi Hasegawa <[email protected]>
Cc Vinod Koul <[email protected]>
Cc Kishon Vijay Abraham I <[email protected]>
Cc Philipp Zabel <[email protected]>
---
 drivers/phy/intel/phy-intel-lgm-combo.c | 1 -
 1 file changed, 1 deletion(-)
drivers/phy/intel/phy-intel-lgm-combo.c +0 -1
index 6010e246d52e..8c764c457c1c 100644
@@ -616,4 +616,3 @@ static struct platform_driver intel_cbphy_driver = {
 module_platform_driver(intel_cbphy_driver);
 
 MODULE_DESCRIPTION("Intel Combo-phy driver");
-MODULE_LICENSE("GPL v2");
Signature · 7 lines
2.39.1.268.g9de2f9a303


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
#52 lore raw

PATCH 27/27 kbuild, gpio: gpio-aspeed-sgpio: remove MODULE_LICENSE in non-modules

In reply to a message not in the archive

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.

Cc Luis Chamberlain <[email protected]>
Cc linux-modules at vger.kernel.org
Cc linux-kernel at vger.kernel.org
Cc Hitomi Hasegawa <[email protected]>
Cc Linus Walleij <[email protected]>
Cc Bartosz Golaszewski <[email protected]>
Cc Joel Stanley <[email protected]>
Cc linux-gpio at vger.kernel.org
Cc linux-arm-kernel at lists.infradead.org
Cc linux-aspeed at lists.ozlabs.org
---
 drivers/gpio/gpio-aspeed-sgpio.c | 1 -
 1 file changed, 1 deletion(-)
drivers/gpio/gpio-aspeed-sgpio.c +0 -1
index 454cefbeecf0..ecc94bfded86 100644
@@ -609,4 +609,3 @@ static struct platform_driver aspeed_sgpio_driver = {
 
 module_platform_driver_probe(aspeed_sgpio_driver, aspeed_sgpio_probe);
 MODULE_DESCRIPTION("Aspeed Serial GPIO Driver");
-MODULE_LICENSE("GPL");
Signature · 1 line
2.39.1.268.g9de2f9a303
#53 lore raw
Quoted 11 lines · On Wed, Feb 22, 2023 at 1:17?PM Nick Alcock <[email protected]> wrote:

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.

Applied, thanks!

Bart