Skip to content

Relocate module code from init.h to module.h

Paul Gortmaker linux-arm-kernel linux-mips lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 6 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4x86: replace __init_or_module with __init in non-modular vsmp_64.carch/x86/kernel/vsmp_64.c+1 -10 replies
2/4arm: fix implicit #include <linux/init.h> in entry asm.arch/arm/kernel/entry-armv.S+2 -00 replies
3/4mips: make loongsoon serial driver explicitly modulararch/mips/loongson/common/serial.c+7 -26 replies
4/4module: relocate module_init from init.h to module.hinclude/linux/init.h include/linux/module.h+84 -780 replies

Reviews trailers per patch

1 of 4 patches has a Reviewed-by or Acked-by.

PatchRusty Russell
1/4
2/4
3/4
4/4A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/4] Relocate module code from init.h to module.h

What started as a removal of no longer required include <linux/init.h> due to the earlier __cpuinit and __devinit removal led to the observation that some module specfic support was living in init.h itself, thus preventing the full removal from introducing compile regressions.

This series of commits includes the final relocation of the modular init code from <init.h> to <module.h> -- we do this because modular users will always be users of init functionality, but users of init functionality are not necessarily always modules. Once done, the trivial one line removals can be finalized at any time, a bit at a time, through maintainer trees etc.

In order to do that, a couple of final things that this will uncover are fixed up here -- things that weren't easily categorized into any of the other previous series leading up to this final one. The previous groupings of commits that get us to this final series are:

1: [PATCH 00/11] Delete new __cpuinit users and then delete stubs
https://lkml.kernel.org/r/1430174880-27958-1-git-send-email-paul.gortmaker at windriver.com

2: [PATCH 00/11] Fix implicit includes of <module.h> that will break.
https://lkml.kernel.org/r/1430444867-22342-1-git-send-email-paul.gortmaker at windriver.com>

3: [PATCH 00/15] Replace module_init with device_initcall in non modules
https://lkml.kernel.org/r/1432860493-23831-1-git-send-email-paul.gortmaker at windriver.com

4: [PATCH 00/11] Replace module_init with an alternate initcall in non modules
https://lkml.kernel.org/r/1433120052-18281-1-git-send-email-paul.gortmaker at windriver.com

5: [PATCH 0/7] Introduce builtin_driver and use it for non-modular code
https://lkml.kernel.org/r/1431287385-1526-1-git-send-email-paul.gortmaker at windriver.com>

This group of six is factored out from what was a previously larger series[1] so that there is a common theme and lower patch count to ease review. Setting aside the trivial one line include <linux/init.h> removals for later also greatly reduces the series size and makes all six parts more manageable.

Paul.

[1] http://lkml.kernel.org/r/1390339396-3479-1-git-send-email-paul.gortmaker at windriver.com

---

Cc "H. Peter Anvin" <[email protected]>
Cc Ingo Molnar <[email protected]>
Cc Ralf Baechle <[email protected]>
Cc Russell King <[email protected]>
Cc Rusty Russell <[email protected]>
Cc Thomas Gleixner <[email protected]>
Cc linux-arm-kernel at lists.infradead.org
Cc linux-mips at linux-mips.org
Cc x86 at kernel.org

Paul Gortmaker (4):
x86: replace __init_or_module with __init in non-modular vsmp_64.c
arm: fix implicit #include <linux/init.h> in entry asm.
mips: make loongsoon serial driver explicitly modular
module: relocate module_init from init.h to module.h

 arch/arm/kernel/entry-armv.S       |  2 +
 arch/mips/loongson/common/serial.c |  9 +++-
 arch/x86/kernel/vsmp_64.c          |  2 +-
 include/linux/init.h               | 78 -----------------------------------
 include/linux/module.h             | 84 ++++++++++++++++++++++++++++++++++++++
 5 files changed, 94 insertions(+), 81 deletions(-)
Signature · 1 line
2.2.1