Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1708941 > unrolled thread
| Started by | "Luis R. Rodriguez" <mcgrof@kernel.org> |
|---|---|
| First post | 2017-08-10 20:10 +0200 |
| Last post | 2017-08-10 20:10 +0200 |
| Articles | 2 — 1 participant |
Back to article view | Back to linux.kernel
[PATCH 0/4] kmod: few code cleanups to split out umh code "Luis R. Rodriguez" <mcgrof@kernel.org> - 2017-08-10 20:10 +0200
[PATCH 4/4] kmod: move #ifdef CONFIG_MODULES wrapper to Makefile "Luis R. Rodriguez" <mcgrof@kernel.org> - 2017-08-10 20:10 +0200
| From | "Luis R. Rodriguez" <mcgrof@kernel.org> |
|---|---|
| Date | 2017-08-10 20:10 +0200 |
| Subject | [PATCH 0/4] kmod: few code cleanups to split out umh code |
| Message-ID | <ud049-Gi-5@gated-at.bofh.it> |
Andrew, Here are a few cleanup items I'd like queued up for v4.14-rc1. The usermode helper has a provenance from the old usb code which first required a usermode helper. Eventually this was shoved into kmod.c and the kernel's modprobe calls was converted over eventually to share the same code. Over time the list of usermode helpers in the kernel has grown -- so kmod is just but one user of the API. This series is a simple logical cleanup which acknowledges the code evolution of the usermode helper and shoves the UMH API into its own dedicated file. This way users of the API can later just include umh.h instead of kmod.h. Note despite the diff state the first patch really is just a code shove, no functional changes are done there. I did use git format-patch -M to generate the patch, but in the end the split was not enough for git to consider it a rename hence the large diffstat. These changes, along with the rest of kmod delta in line, are available on my linux-next git tree [0] on the branch 20170810-kmod-for-v4.14. This is based on linux-next tag next-20170810. I've put this through 0-day and it gives me their machine compilation blessings with all tests as OK. If there are any issues or questions please let me know. [0] https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git/log/?h=20170810-kmod-for-v4.14 Luis R. Rodriguez (4): kmod: split out umh code into its own file MAINTAINERS: clarify kmod is just a kernel module loader kmod: split off umh headers into its own file kmod: move #ifdef CONFIG_MODULES wrapper to Makefile MAINTAINERS | 9 +- include/linux/kmod.h | 60 +----- include/linux/umh.h | 69 +++++++ kernel/Makefile | 3 +- kernel/kmod.c | 563 +------------------------------------------------- kernel/umh.c | 568 +++++++++++++++++++++++++++++++++++++++++++++++++++ 6 files changed, 650 insertions(+), 622 deletions(-) create mode 100644 include/linux/umh.h create mode 100644 kernel/umh.c -- 2.14.0
[toc] | [next] | [standalone]
| From | "Luis R. Rodriguez" <mcgrof@kernel.org> |
|---|---|
| Date | 2017-08-10 20:10 +0200 |
| Subject | [PATCH 4/4] kmod: move #ifdef CONFIG_MODULES wrapper to Makefile |
| Message-ID | <ud04a-Gi-33@gated-at.bofh.it> |
| In reply to | #1708941 |
The entire file is now conditionally compiled only when CONFIG_MODULES is enabled, and this this is a bool. Just move this conditional to the Makefile as its easier to read this way. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> --- kernel/Makefile | 3 ++- kernel/kmod.c | 3 --- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/kernel/Makefile b/kernel/Makefile index 44abbb0104b6..ed470aac53da 100644 --- a/kernel/Makefile +++ b/kernel/Makefile @@ -5,12 +5,13 @@ obj-y = fork.o exec_domain.o panic.o \ cpu.o exit.o softirq.o resource.o \ sysctl.o sysctl_binary.o capability.o ptrace.o user.o \ - signal.o sys.o umh.o kmod.o workqueue.o pid.o task_work.o \ + signal.o sys.o umh.o workqueue.o pid.o task_work.o \ extable.o params.o \ kthread.o sys_ni.o nsproxy.o \ notifier.o ksysfs.o cred.o reboot.o \ async.o range.o smpboot.o ucount.o +obj-$(CONFIG_MODULES) += kmod.o obj-$(CONFIG_MULTIUSER) += groups.o ifdef CONFIG_FUNCTION_TRACER diff --git a/kernel/kmod.c b/kernel/kmod.c index cdff52974d18..bc6addd9152b 100644 --- a/kernel/kmod.c +++ b/kernel/kmod.c @@ -28,7 +28,6 @@ #include <trace/events/module.h> -#ifdef CONFIG_MODULES /* * Assuming: * @@ -177,5 +176,3 @@ int __request_module(bool wait, const char *fmt, ...) return ret; } EXPORT_SYMBOL(__request_module); - -#endif /* CONFIG_MODULES */ -- 2.14.0
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web