diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2007-02-14 00:34:09 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-14 08:09:59 -0800 |
commit | 0b4d414714f0d2f922d39424b0c5c82ad900a381 (patch) | |
tree | 5079ec59a5622c9cacfe0fce484ba2c4626c406f /fs | |
parent | ae836810263509ff7a3c2c021754ce6f66b3fab6 (diff) |
[PATCH] sysctl: remove insert_at_head from register_sysctl
The semantic effect of insert_at_head is that it would allow new registered
sysctl entries to override existing sysctl entries of the same name. Which is
pain for caching and the proc interface never implemented.
I have done an audit and discovered that none of the current users of
register_sysctl care as (excpet for directories) they do not register
duplicate sysctl entries.
So this patch simply removes the support for overriding existing entries in
the sys_sysctl interface since no one uses it or cares and it makes future
enhancments harder.
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
Acked-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: David Howells <dhowells@redhat.com>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Andi Kleen <ak@muc.de>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Corey Minyard <minyard@acm.org>
Cc: Neil Brown <neilb@suse.de>
Cc: "John W. Linville" <linville@tuxdriver.com>
Cc: James Bottomley <James.Bottomley@steeleye.com>
Cc: Jan Kara <jack@ucw.cz>
Cc: Trond Myklebust <trond.myklebust@fys.uio.no>
Cc: Mark Fasheh <mark.fasheh@oracle.com>
Cc: David Chinner <dgc@sgi.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Patrick McHardy <kaber@trash.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/coda/sysctl.c | 2 | ||||
-rw-r--r-- | fs/dquot.c | 2 | ||||
-rw-r--r-- | fs/lockd/svc.c | 2 | ||||
-rw-r--r-- | fs/nfs/sysctl.c | 2 | ||||
-rw-r--r-- | fs/ntfs/sysctl.c | 2 | ||||
-rw-r--r-- | fs/ocfs2/cluster/nodemanager.c | 2 | ||||
-rw-r--r-- | fs/xfs/linux-2.6/xfs_sysctl.c | 2 |
7 files changed, 7 insertions, 7 deletions
diff --git a/fs/coda/sysctl.c b/fs/coda/sysctl.c index 8e50642f57e8..c57a1fa7cf23 100644 --- a/fs/coda/sysctl.c +++ b/fs/coda/sysctl.c @@ -271,7 +271,7 @@ void coda_sysctl_init(void) #ifdef CONFIG_SYSCTL if ( !fs_table_header ) - fs_table_header = register_sysctl_table(fs_table, 0); + fs_table_header = register_sysctl_table(fs_table); #endif } diff --git a/fs/dquot.c b/fs/dquot.c index 9eb166f91489..b16f991662c1 100644 --- a/fs/dquot.c +++ b/fs/dquot.c @@ -1841,7 +1841,7 @@ static int __init dquot_init(void) printk(KERN_NOTICE "VFS: Disk quotas %s\n", __DQUOT_VERSION__); - register_sysctl_table(sys_table, 0); + register_sysctl_table(sys_table); dquot_cachep = kmem_cache_create("dquot", sizeof(struct dquot), sizeof(unsigned long) * 4, diff --git a/fs/lockd/svc.c b/fs/lockd/svc.c index 80fcacc1acf9..50cb8daba4e5 100644 --- a/fs/lockd/svc.c +++ b/fs/lockd/svc.c @@ -512,7 +512,7 @@ module_param(nsm_use_hostnames, bool, 0644); static int __init init_nlm(void) { - nlm_sysctl_table = register_sysctl_table(nlm_sysctl_root, 0); + nlm_sysctl_table = register_sysctl_table(nlm_sysctl_root); return nlm_sysctl_table ? 0 : -ENOMEM; } diff --git a/fs/nfs/sysctl.c b/fs/nfs/sysctl.c index 3ea50ac64820..fcdcafbb3293 100644 --- a/fs/nfs/sysctl.c +++ b/fs/nfs/sysctl.c @@ -75,7 +75,7 @@ static ctl_table nfs_cb_sysctl_root[] = { int nfs_register_sysctl(void) { - nfs_callback_sysctl_table = register_sysctl_table(nfs_cb_sysctl_root, 0); + nfs_callback_sysctl_table = register_sysctl_table(nfs_cb_sysctl_root); if (nfs_callback_sysctl_table == NULL) return -ENOMEM; return 0; diff --git a/fs/ntfs/sysctl.c b/fs/ntfs/sysctl.c index 4757f6b7a28c..1f1ee4c9eacc 100644 --- a/fs/ntfs/sysctl.c +++ b/fs/ntfs/sysctl.c @@ -70,7 +70,7 @@ int ntfs_sysctl(int add) { if (add) { BUG_ON(sysctls_root_table); - sysctls_root_table = register_sysctl_table(sysctls_root, 0); + sysctls_root_table = register_sysctl_table(sysctls_root); if (!sysctls_root_table) return -ENOMEM; #ifdef CONFIG_PROC_FS diff --git a/fs/ocfs2/cluster/nodemanager.c b/fs/ocfs2/cluster/nodemanager.c index df763c7fd083..9f5ad0f01ce0 100644 --- a/fs/ocfs2/cluster/nodemanager.c +++ b/fs/ocfs2/cluster/nodemanager.c @@ -922,7 +922,7 @@ static int __init init_o2nm(void) o2hb_init(); o2net_init(); - ocfs2_table_header = register_sysctl_table(ocfs2_root_table, 0); + ocfs2_table_header = register_sysctl_table(ocfs2_root_table); if (!ocfs2_table_header) { printk(KERN_ERR "nodemanager: unable to register sysctl\n"); ret = -ENOMEM; /* or something. */ diff --git a/fs/xfs/linux-2.6/xfs_sysctl.c b/fs/xfs/linux-2.6/xfs_sysctl.c index 5c46c35a97a5..cd6eaa44aa2b 100644 --- a/fs/xfs/linux-2.6/xfs_sysctl.c +++ b/fs/xfs/linux-2.6/xfs_sysctl.c @@ -251,7 +251,7 @@ static ctl_table xfs_root_table[] = { void xfs_sysctl_register(void) { - xfs_table_header = register_sysctl_table(xfs_root_table, 0); + xfs_table_header = register_sysctl_table(xfs_root_table); } void |