1. 13 Apr, 2023 23 commits
    • Nick Alcock's avatar
      crypto: remove MODULE_LICENSE in non-modules · 37148780
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Herbert Xu <herbert@gondor.apana.org.au>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: linux-crypto@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      37148780
    • Nick Alcock's avatar
      clocksource: remove MODULE_LICENSE in non-modules · 5ba4b11a
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      5ba4b11a
    • Nick Alcock's avatar
      clocksource/drivers/timer-tegra186: remove MODULE_LICENSE in non-modules · 1e64f2a7
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Thierry Reding <thierry.reding@gmail.com>
      Cc: Jonathan Hunter <jonathanh@nvidia.com>
      Cc: linux-tegra@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      1e64f2a7
    • Nick Alcock's avatar
      clocksource: remove MODULE_LICENSE in non-modules · bb177282
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Maxime Coquelin <mcoquelin.stm32@gmail.com>
      Cc: Alexandre Torgue <alexandre.torgue@foss.st.com>
      Cc: linux-stm32@st-md-mailman.stormreply.com
      Cc: linux-arm-kernel@lists.infradead.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      bb177282
    • Nick Alcock's avatar
      MIPS: BCM47XX: remove MODULE_LICENSE in non-modules · e518212e
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Reviewed-by: default avatarPhilippe Mathieu-Daudé <philmd@linaro.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: "Rafał Miłecki" <zajec5@gmail.com>
      Cc: linux-mips@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      e518212e
    • Nick Alcock's avatar
      pinctrl: bcm: ns: remove MODULE_LICENSE in non-modules · c7b9975a
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Ray Jui <rjui@broadcom.com>
      Cc: Scott Branden <sbranden@broadcom.com>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linux-gpio@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      c7b9975a
    • Nick Alcock's avatar
      KEYS: remove MODULE_LICENSE in non-modules · 8a8dd17d
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Herbert Xu <herbert@gondor.apana.org.au>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: keyrings@vger.kernel.org
      Cc: linux-crypto@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      8a8dd17d
    • Nick Alcock's avatar
      video: fbdev: remove MODULE_LICENSE in non-modules · 6d398e69
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Helge Deller <deller@gmx.de>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linux-fbdev@vger.kernel.org
      Cc: dri-devel@lists.freedesktop.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      6d398e69
    • Nick Alcock's avatar
      power: reset: keystone-reset: remove MODULE_LICENSE in non-modules · 06538a04
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Santosh Shilimkar <ssantosh@kernel.org>
      Cc: Sebastian Reichel <sre@kernel.org>
      Cc: linux-pm@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      06538a04
    • Nick Alcock's avatar
      EDAC, altera: remove MODULE_LICENSE in non-modules · bb798d30
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Dinh Nguyen <dinguyen@kernel.org>
      Cc: Borislav Petkov <bp@alien8.de>
      Cc: Tony Luck <tony.luck@intel.com>
      Cc: linux-edac@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      bb798d30
    • Nick Alcock's avatar
      bus: remove MODULE_LICENSE in non-modules · e86c8a2d
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Andy Gross <agross@kernel.org>
      Cc: Bjorn Andersson <andersson@kernel.org>
      Cc: Philipp Zabel <p.zabel@pengutronix.de>
      Cc: linux-arm-msm@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      e86c8a2d
    • Nick Alcock's avatar
      bus: qcom: remove MODULE_LICENSE in non-modules · c592acf5
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Andy Gross <agross@kernel.org>
      Cc: Bjorn Andersson <andersson@kernel.org>
      Cc: linux-arm-msm@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      c592acf5
    • Nick Alcock's avatar
      pinctrl: nuvoton: npcm7xx: remove MODULE_LICENSE in non-modules · 1095ebc8
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Avi Fishman <avifishman70@gmail.com>
      Cc: Tomer Maimon <tmaimon77@gmail.com>
      Cc: Tali Perry <tali.perry1@gmail.com>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Cc: openbmc@lists.ozlabs.org
      Cc: linux-gpio@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      1095ebc8
    • Nick Alcock's avatar
      bus: ixp4xx: remove MODULE_LICENSE in non-modules · 1739e466
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Linus Walleij <linusw@kernel.org>
      Cc: Imre Kaloz <kaloz@openwrt.org>
      Cc: Krzysztof Halasa <khalasa@piap.pl>
      Cc: linux-arm-kernel@lists.infradead.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      1739e466
    • Nick Alcock's avatar
      clk: bm1880: remove MODULE_LICENSE in non-modules · f6f5f91c
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Acked-by: default avatarStephen Boyd <sboyd@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Manivannan Sadhasivam <mani@kernel.org>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linux-clk@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      f6f5f91c
    • Nick Alcock's avatar
      soc: apple: apple-pmgr-pwrstate: remove MODULE_LICENSE in non-modules · 87efd0d3
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Reviewed-by: default avatarEric Curtin <ecurtin@redhat.com>
      Acked-by: default avatarSven Peter <sven@svenpeter.dev>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Hector Martin <marcan@marcan.st>
      Cc: Sven Peter <sven@svenpeter.dev>
      Cc: Philipp Zabel <p.zabel@pengutronix.de>
      Cc: asahi@lists.linux.dev
      Cc: linux-arm-kernel@lists.infradead.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      87efd0d3
    • Nick Alcock's avatar
      pinctrl: actions: remove MODULE_LICENSE in non-modules · b9ef12ea
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: "Andreas Färber" <afaerber@suse.de>
      Cc: Manivannan Sadhasivam <mani@kernel.org>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linux-actions@lists.infradead.org
      Cc: linux-gpio@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      b9ef12ea
    • Nick Alcock's avatar
      ARM: tegra: remove MODULE_LICENSE in non-modules · 0ba3f797
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Thierry Reding <thierry.reding@gmail.com>
      Cc: Jonathan Hunter <jonathanh@nvidia.com>
      Cc: linux-tegra@vger.kernel.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      0ba3f797
    • Nick Alcock's avatar
      drivers/perf: remove MODULE_LICENSE in non-modules · 9016c09e
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Will Deacon <will@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: linux-arm-kernel@lists.infradead.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      9016c09e
    • Nick Alcock's avatar
      bus: arm-integrator-lm: remove MODULE_LICENSE in non-modules · 591396b9
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Cc: linux-arm-kernel@lists.infradead.org
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      591396b9
    • Nick Alcock's avatar
      irqchip/al-fic: remove MODULE_LICENSE in non-modules · 655cc3a6
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Talel Shenhar <talel@amazon.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Marc Zyngier <maz@kernel.org>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      655cc3a6
    • Nick Alcock's avatar
      mfd: altera-sysmgr: remove MODULE_LICENSE in non-modules · 9e0d360f
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Cc: Thor Thayer <thor.thayer@linux.intel.com>
      Cc: Lee Jones <lee@kernel.org>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      9e0d360f
    • Nick Alcock's avatar
      soc: fujitsu: remove MODULE_LICENSE in non-modules · 066ff7db
      Nick Alcock authored
      Since commit 8b41fc44 ("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: default avatarNick Alcock <nick.alcock@oracle.com>
      Suggested-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      Cc: Luis Chamberlain <mcgrof@kernel.org>
      Cc: linux-modules@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Hitomi Hasegawa <hasegawa-hitomi@fujitsu.com>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      066ff7db
  2. 24 Mar, 2023 17 commits
    • Bagas Sanjaya's avatar
      Documentation: core-api: update kernel-doc reference to kmod.c · 3edf091d
      Bagas Sanjaya authored
      Commit d6f819908f8aac ("module: fold usermode helper kmod into modules
      directory") moves kmod helper implementation (kmod.c) to kernel/module/
      directory but forgets to update its reference on kernel api doc, hence:
      
      WARNING: kernel-doc './scripts/kernel-doc -rst -enable-lineno -sphinx-version 2.4.4 -export ./kernel/kmod.c' failed with return code 2
      
      Update the reference.
      
      Fixes: d6f819908f8aac ("module: fold usermode helper kmod into modules directory")
      Reported-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
      Link: https://lore.kernel.org/linux-next/20230324154413.19cc78be@canb.auug.org.au/Signed-off-by: default avatarBagas Sanjaya <bagasdotme@gmail.com>
      Reviewed-by: default avatarLiam Beguin <liambeguin@gmail.com>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      3edf091d
    • Jim Cromie's avatar
      module: already_uses() - reduce pr_debug output volume · 33c951f6
      Jim Cromie authored
      already_uses() is unnecessarily chatty.
      
      `modprobe i915` yields 491 messages like:
      
        [   64.108744] i915 uses drm!
      
      This is a normal situation, and isn't worth all the log entries.
      
      NOTE: I've preserved the "does not use %s" messages, which happens
      less often, but does happen.  Its not clear to me what it tells a
      reader, or what info might improve the pr_debug's utility.
      
      [ 6847.584999] main:already_uses:569: amdgpu does not use ttm!
      [ 6847.585001] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585014] main:already_uses:569: amdgpu does not use drm!
      [ 6847.585016] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585024] main:already_uses:569: amdgpu does not use drm_display_helper!
      [ 6847.585025] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585084] main:already_uses:569: amdgpu does not use drm_kms_helper!
      [ 6847.585086] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585175] main:already_uses:569: amdgpu does not use drm_buddy!
      [ 6847.585176] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585202] main:already_uses:569: amdgpu does not use i2c_algo_bit!
      [ 6847.585204] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585249] main:already_uses:569: amdgpu does not use gpu_sched!
      [ 6847.585250] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585314] main:already_uses:569: amdgpu does not use video!
      [ 6847.585315] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585409] main:already_uses:569: amdgpu does not use iommu_v2!
      [ 6847.585410] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6847.585816] main:already_uses:569: amdgpu does not use drm_ttm_helper!
      [ 6847.585818] main:add_module_usage:584: Allocating new usage for amdgpu.
      [ 6848.762268] dyndbg: add-module: amdgpu.2533 sites
      
      no functional changes.
      Signed-off-by: default avatarJim Cromie <jim.cromie@gmail.com>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      33c951f6
    • Jim Cromie's avatar
      module: add section-size to move_module pr_debug · 66a2301e
      Jim Cromie authored
      move_module() pr_debug's "Final section addresses for $modname".
      Add section addresses to the message, for anyone looking at these.
      
      no functional changes.
      Signed-off-by: default avatarJim Cromie <jim.cromie@gmail.com>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      66a2301e
    • Jim Cromie's avatar
      module: add symbol-name to pr_debug Absolute symbol · b10addf3
      Jim Cromie authored
      The pr_debug("Absolute symbol" ..) reports value, (which is usually
      0), but not the name, which is more informative.  So add it.
      
      no functional changes
      Signed-off-by: default avatarJim Cromie <jim.cromie@gmail.com>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      b10addf3
    • Jim Cromie's avatar
      module: in layout_sections, move_module: add the modname · 6ed81802
      Jim Cromie authored
      layout_sections() and move_module() each issue ~50 messages for each
      module loaded.  Add mod-name into their 2 header lines, to help the
      reader find his module.
      
      no functional changes.
      Signed-off-by: default avatarJim Cromie <jim.cromie@gmail.com>
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      6ed81802
    • Luis Chamberlain's avatar
      module: fold usermode helper kmod into modules directory · 25be451a
      Luis Chamberlain authored
      The kernel/kmod.c is already only built if we enabled modules, so
      just stuff it under kernel/module/kmod.c and unify the MAINTAINERS
      file for it.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      25be451a
    • Luis Chamberlain's avatar
      module: merge remnants of setup_load_info() to elf validation · 3d40bb90
      Luis Chamberlain authored
      The setup_load_info() was actually had ELF validation checks of its
      own. To later cache useful variables as an secondary step just means
      looping again over the ELF sections we just validated. We can simply
      keep tabs of the key sections of interest as we validate the module
      ELF section in one swoop, so do that and merge the two routines
      together.
      
      Expand a bit on the documentation / intent / goals.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      3d40bb90
    • Luis Chamberlain's avatar
      module: move more elf validity checks to elf_validity_check() · 1bb49db9
      Luis Chamberlain authored
      The symbol and strings section validation currently happen in
      setup_load_info() but since they are also doing validity checks
      move this to elf_validity_check().
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      1bb49db9
    • Luis Chamberlain's avatar
      module: add stop-grap sanity check on module memcpy() · c7ee8aeb
      Luis Chamberlain authored
      The integrity of the struct module we load is important, and although
      our ELF validator already checks that the module section must match
      struct module, add a stop-gap check before we memcpy() the final minted
      module. This also makes those inspecting the code what the goal is.
      
      While at it, clarify the goal behind updating the sh_addr address.
      The current comment is pretty misleading.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      c7ee8aeb
    • Luis Chamberlain's avatar
      module: add sanity check for ELF module section · 46752820
      Luis Chamberlain authored
      The ELF ".gnu.linkonce.this_module" section is special, it is what we
      use to construct the struct module __this_module, which THIS_MODULE
      points to. When userspace loads a module we always deal first with a
      copy of the userspace buffer, and twiddle with the userspace copy's
      version of the struct module. Eventually we allocate memory to do a
      memcpy() of that struct module, under the assumption that the module
      size is right. But we have no validity checks against the size or
      the requirements for the section.
      
      Add some validity checks for the special module section early and while
      at it, cache the module section index early, so we don't have to do that
      later.
      
      While at it, just move over the assigment of the info->mod to make the
      code clearer. The validity checker also adds an explicit size check to
      ensure the module section size matches the kernel's run time size for
      sizeof(struct module). This should prevent sloppy loads of modules
      which are built today *without* actually increasing the size of
      the struct module. A developer today can for example expand the size
      of struct module, rebuild a directoroy 'make fs/xfs/' for example and
      then try to insmode the driver there. That module would in effect have
      an incorrect size. This new size check would put a stop gap against such
      mistakes.
      
      This also makes the entire goal of ".gnu.linkonce.this_module" pretty
      clear. Before this patch verification of the goal / intent required some
      Indian Jones whips, torches and cleaning up big old spider webs.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      46752820
    • Luis Chamberlain's avatar
      module: rename check_module_license_and_versions() to check_export_symbol_versions() · 419e1a20
      Luis Chamberlain authored
      This makes the routine easier to understand what the check its checking for.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      419e1a20
    • Luis Chamberlain's avatar
      module: converge taint work together · 72f08b3c
      Luis Chamberlain authored
      Converge on a compromise: so long as we have a module hit our linked
      list of modules we taint. That is, the module was about to become live.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      72f08b3c
    • Luis Chamberlain's avatar
      module: move signature taint to module_augment_kernel_taints() · c3bbf62e
      Luis Chamberlain authored
      Just move the signature taint into the helper:
      
        module_augment_kernel_taints()
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      c3bbf62e
    • Luis Chamberlain's avatar
      module: move tainting until after a module hits our linked list · a12b9451
      Luis Chamberlain authored
      It is silly to have taints spread out all over, we can just compromise
      and add them if the module ever hit our linked list. Our sanity checkers
      should just prevent crappy drivers / bogus ELF modules / etc and kconfig
      options should be enough to let you *not* load things you don't want.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      a12b9451
    • Luis Chamberlain's avatar
      module: split taint adding with info checking · 437c1f9c
      Luis Chamberlain authored
      check_modinfo() actually does two things:
      
       a) sanity checks, some of which are fatal, and so we
          prevent the user from completing trying to load a module
       b) taints the kernel
      
      The taints are pretty heavy handed because we're tainting the kernel
      *before* we ever even get to load the module into the modules linked
      list. That is, it it can fail for other reasons later as we review the
      module's structure.
      
      But this commit makes no functional changes, it just makes the intent
      clearer and splits the code up where needed to make that happen.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      437c1f9c
    • Luis Chamberlain's avatar
      module: split taint work out of check_modinfo_livepatch() · ed52cabe
      Luis Chamberlain authored
      The work to taint the kernel due to a module should be split
      up eventually. To aid with this, split up the tainting on
      check_modinfo_livepatch().
      
      This let's us bring more early checks together which do return
      a value, and makes changes easier to read later where we stuff
      all the work to do the taints in one single routine.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      ed52cabe
    • Luis Chamberlain's avatar
      module: rename set_license() to module_license_taint_check() · ad8d3a36
      Luis Chamberlain authored
      The set_license() routine would seem to a reader to do some sort of
      setting, but it does not. It just adds a taint if the license is
      not set or proprietary.
      
      This makes what the code is doing clearer, so much we can remove
      the comment about it.
      Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
      ad8d3a36