netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH -next] bpf: make inode code explicitly non-modular
@ 2016-07-11 16:51 Paul Gortmaker
  2016-07-11 17:28 ` Daniel Borkmann
  2016-07-11 20:53 ` David Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Paul Gortmaker @ 2016-07-11 16:51 UTC (permalink / raw)
  To: linux-kernel; +Cc: Paul Gortmaker, Alexei Starovoitov, netdev

The Kconfig currently controlling compilation of this code is:

init/Kconfig:config BPF_SYSCALL
init/Kconfig:   bool "Enable bpf() system call"

...meaning that it currently is not being built as a module by anyone.

Lets remove the couple traces of modular infrastructure use, so that
when reading the driver there is no doubt it is builtin-only.

Note that MODULE_ALIAS is a no-op for non-modular code.

We replace module.h with init.h since the file does use __init.

Cc: Alexei Starovoitov <ast@kernel.org>
Cc: netdev@vger.kernel.org
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
---
 kernel/bpf/inode.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/kernel/bpf/inode.c b/kernel/bpf/inode.c
index 318858edb1cd..5967b870a895 100644
--- a/kernel/bpf/inode.c
+++ b/kernel/bpf/inode.c
@@ -11,7 +11,7 @@
  * version 2 as published by the Free Software Foundation.
  */
 
-#include <linux/module.h>
+#include <linux/init.h>
 #include <linux/magic.h>
 #include <linux/major.h>
 #include <linux/mount.h>
@@ -367,8 +367,6 @@ static struct file_system_type bpf_fs_type = {
 	.kill_sb	= kill_litter_super,
 };
 
-MODULE_ALIAS_FS("bpf");
-
 static int __init bpf_init(void)
 {
 	int ret;
-- 
2.8.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH -next] bpf: make inode code explicitly non-modular
  2016-07-11 16:51 [PATCH -next] bpf: make inode code explicitly non-modular Paul Gortmaker
@ 2016-07-11 17:28 ` Daniel Borkmann
  2016-07-11 20:53 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: Daniel Borkmann @ 2016-07-11 17:28 UTC (permalink / raw)
  To: Paul Gortmaker; +Cc: linux-kernel, Alexei Starovoitov, netdev

On 07/11/2016 06:51 PM, Paul Gortmaker wrote:
> The Kconfig currently controlling compilation of this code is:
>
> init/Kconfig:config BPF_SYSCALL
> init/Kconfig:   bool "Enable bpf() system call"
>
> ...meaning that it currently is not being built as a module by anyone.
>
> Lets remove the couple traces of modular infrastructure use, so that
> when reading the driver there is no doubt it is builtin-only.
>
> Note that MODULE_ALIAS is a no-op for non-modular code.
>
> We replace module.h with init.h since the file does use __init.
>
> Cc: Alexei Starovoitov <ast@kernel.org>
> Cc: netdev@vger.kernel.org
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>

(Patch is for net-next tree then.)

Acked-by: Daniel Borkmann <daniel@iogearbox.net>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH -next] bpf: make inode code explicitly non-modular
  2016-07-11 16:51 [PATCH -next] bpf: make inode code explicitly non-modular Paul Gortmaker
  2016-07-11 17:28 ` Daniel Borkmann
@ 2016-07-11 20:53 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2016-07-11 20:53 UTC (permalink / raw)
  To: paul.gortmaker; +Cc: linux-kernel, ast, netdev

From: Paul Gortmaker <paul.gortmaker@windriver.com>
Date: Mon, 11 Jul 2016 12:51:01 -0400

> The Kconfig currently controlling compilation of this code is:
> 
> init/Kconfig:config BPF_SYSCALL
> init/Kconfig:   bool "Enable bpf() system call"
> 
> ...meaning that it currently is not being built as a module by anyone.
> 
> Lets remove the couple traces of modular infrastructure use, so that
> when reading the driver there is no doubt it is builtin-only.
> 
> Note that MODULE_ALIAS is a no-op for non-modular code.
> 
> We replace module.h with init.h since the file does use __init.
> 
> Cc: Alexei Starovoitov <ast@kernel.org>
> Cc: netdev@vger.kernel.org
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>

Applied.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-07-11 20:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-11 16:51 [PATCH -next] bpf: make inode code explicitly non-modular Paul Gortmaker
2016-07-11 17:28 ` Daniel Borkmann
2016-07-11 20:53 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).