Merge commit 'v2.6.32-rc7'
Eric W. Biederman [Tue, 17 Nov 2009 09:01:34 +0000 (01:01 -0800)]
Resolve the conflict between v2.6.32-rc7 where dn_def_dev_handler
gets a small bug fix and the sysctl tree where I am removing all
sysctl strategy routines.

130 files changed:
arch/arm/kernel/isa.c
arch/arm/mach-bcmring/arch.c
arch/frv/kernel/pm.c
arch/frv/kernel/sysctl.c
arch/ia64/ia32/ia32_entry.S
arch/ia64/ia32/sys_ia32.c
arch/ia64/kernel/crash.c
arch/ia64/kernel/perfmon.c
arch/mips/kernel/linux32.c
arch/mips/kernel/scall64-n32.S
arch/mips/kernel/scall64-o32.S
arch/mips/lasat/sysctl.c
arch/parisc/kernel/sys_parisc32.c
arch/parisc/kernel/syscall_table.S
arch/powerpc/kernel/idle.c
arch/powerpc/kernel/sys_ppc32.c
arch/s390/kernel/compat_linux.c
arch/s390/kernel/compat_linux.h
arch/s390/kernel/compat_wrapper.S
arch/s390/kernel/debug.c
arch/s390/mm/cmm.c
arch/sh/kernel/traps_64.c
arch/sparc/kernel/sys_sparc32.c
arch/sparc/kernel/systbls_64.S
arch/x86/ia32/ia32entry.S
arch/x86/ia32/sys_ia32.c
arch/x86/include/asm/sys_ia32.h
arch/x86/kernel/vsyscall_64.c
arch/x86/vdso/vdso32-setup.c
crypto/proc.c
drivers/cdrom/cdrom.c
drivers/char/hpet.c
drivers/char/ipmi/ipmi_poweroff.c
drivers/char/pty.c
drivers/char/random.c
drivers/char/rtc.c
drivers/macintosh/mac_hid.c
drivers/md/md.c
drivers/misc/sgi-xp/xpc_main.c
drivers/net/wireless/arlan-proc.c
drivers/parport/procfs.c
drivers/s390/char/sclp_async.c
drivers/scsi/scsi_sysctl.c
fs/coda/sysctl.c
fs/eventpoll.c
fs/lockd/svc.c
fs/nfs/sysctl.c
fs/notify/inotify/inotify_user.c
fs/ntfs/sysctl.c
fs/ocfs2/stackglue.c
fs/proc/proc_sysctl.c
fs/quota/dquot.c
fs/xfs/linux-2.6/xfs_sysctl.c
include/linux/sysctl.h
include/net/dn_dev.h
include/net/neighbour.h
init/Kconfig
ipc/ipc_sysctl.c
ipc/mq_sysctl.c
kernel/Makefile
kernel/sched.c
kernel/slow-work.c
kernel/sys_ni.c
kernel/sysctl.c
kernel/sysctl_binary.c [new file with mode: 0644]
kernel/sysctl_check.c
kernel/utsname_sysctl.c
lib/Kconfig.debug
net/802/tr.c
net/appletalk/sysctl_net_atalk.c
net/ax25/sysctl_net_ax25.c
net/bridge/br_netfilter.c
net/core/neighbour.c
net/core/sysctl_net_core.c
net/dccp/sysctl.c
net/decnet/dn_dev.c
net/decnet/sysctl_net_decnet.c
net/ipv4/arp.c
net/ipv4/devinet.c
net/ipv4/ip_fragment.c
net/ipv4/netfilter.c
net/ipv4/netfilter/ip_queue.c
net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c
net/ipv4/netfilter/nf_conntrack_proto_icmp.c
net/ipv4/route.c
net/ipv4/sysctl_net_ipv4.c
net/ipv4/xfrm4_policy.c
net/ipv6/addrconf.c
net/ipv6/icmp.c
net/ipv6/ndisc.c
net/ipv6/netfilter/ip6_queue.c
net/ipv6/netfilter/nf_conntrack_proto_icmpv6.c
net/ipv6/netfilter/nf_conntrack_reasm.c
net/ipv6/reassembly.c
net/ipv6/route.c
net/ipv6/sysctl_net_ipv6.c
net/ipv6/xfrm6_policy.c
net/ipx/sysctl_net_ipx.c
net/irda/irsysctl.c
net/llc/sysctl_net_llc.c
net/netfilter/core.c
net/netfilter/ipvs/ip_vs_ctl.c
net/netfilter/ipvs/ip_vs_lblc.c
net/netfilter/ipvs/ip_vs_lblcr.c
net/netfilter/nf_conntrack_acct.c
net/netfilter/nf_conntrack_ecache.c
net/netfilter/nf_conntrack_proto_dccp.c
net/netfilter/nf_conntrack_proto_generic.c
net/netfilter/nf_conntrack_proto_sctp.c
net/netfilter/nf_conntrack_proto_tcp.c
net/netfilter/nf_conntrack_proto_udp.c
net/netfilter/nf_conntrack_proto_udplite.c
net/netfilter/nf_conntrack_standalone.c
net/netfilter/nf_log.c
net/netrom/sysctl_net_netrom.c
net/phonet/sysctl.c
net/rds/ib_sysctl.c
net/rds/iw_sysctl.c
net/rds/sysctl.c
net/rose/sysctl_net_rose.c
net/sctp/sysctl.c
net/sunrpc/sysctl.c
net/sunrpc/xprtrdma/svc_rdma.c
net/sunrpc/xprtrdma/transport.c
net/sunrpc/xprtsock.c
net/unix/sysctl_net_unix.c
net/x25/sysctl_net_x25.c
net/xfrm/xfrm_sysctl.c
security/keys/sysctl.c
security/tomoyo/tomoyo.c

index 8ac9b84..738dfcc 100644 (file)
@@ -22,47 +22,42 @@ static unsigned int isa_membase, isa_portbase, isa_portshift;
 
 static ctl_table ctl_isa_vars[4] = {
        {
-               .ctl_name       = BUS_ISA_MEM_BASE,
                .procname       = "membase",
                .data           = &isa_membase, 
                .maxlen         = sizeof(isa_membase),
                .mode           = 0444,
                .proc_handler   = &proc_dointvec,
        }, {
-               .ctl_name       = BUS_ISA_PORT_BASE,
                .procname       = "portbase",
                .data           = &isa_portbase, 
                .maxlen         = sizeof(isa_portbase),
                .mode           = 0444,
                .proc_handler   = &proc_dointvec,
        }, {
-               .ctl_name       = BUS_ISA_PORT_SHIFT,
                .procname       = "portshift",
                .data           = &isa_portshift, 
                .maxlen         = sizeof(isa_portshift),
                .mode           = 0444,
                .proc_handler   = &proc_dointvec,
-       }, {0}
+       }, {}
 };
 
 static struct ctl_table_header *isa_sysctl_header;
 
 static ctl_table ctl_isa[2] = {
        {
-               .ctl_name       = CTL_BUS_ISA,
                .procname       = "isa",
                .mode           = 0555,
                .child          = ctl_isa_vars,
-       }, {0}
+       }, {}
 };
 
 static ctl_table ctl_bus[2] = {
        {
-               .ctl_name       = CTL_BUS,
                .procname       = "bus",
                .mode           = 0555,
                .child          = ctl_isa,
-       }, {0}
+       }, {}
 };
 
 void __init
index 0da693b..f3c1119 100644 (file)
@@ -47,10 +47,6 @@ HW_DECLARE_SPINLOCK(gpio)
     EXPORT_SYMBOL(bcmring_gpio_reg_lock);
 #endif
 
-/* FIXME: temporary solution */
-#define BCM_SYSCTL_REBOOT_WARM               1
-#define CTL_BCM_REBOOT                 112
-
 /* sysctl */
 int bcmring_arch_warm_reboot;  /* do a warm reboot on hard reset */
 
@@ -58,7 +54,6 @@ static struct ctl_table_header *bcmring_sysctl_header;
 
 static struct ctl_table bcmring_sysctl_warm_reboot[] = {
        {
-        .ctl_name = BCM_SYSCTL_REBOOT_WARM,
         .procname = "warm",
         .data = &bcmring_arch_warm_reboot,
         .maxlen = sizeof(int),
@@ -69,7 +64,6 @@ static struct ctl_table bcmring_sysctl_warm_reboot[] = {
 
 static struct ctl_table bcmring_sysctl_reboot[] = {
        {
-        .ctl_name = CTL_BCM_REBOOT,
         .procname = "reboot",
         .mode = 0555,
         .child = bcmring_sysctl_warm_reboot},
index 0d4d3e3..940d8bb 100644 (file)
@@ -211,37 +211,6 @@ static int cmode_procctl(ctl_table *ctl, int write,
        return try_set_cmode(new_cmode)?:*lenp;
 }
 
-static int cmode_sysctl(ctl_table *table,
-                       void __user *oldval, size_t __user *oldlenp,
-                       void __user *newval, size_t newlen)
-{
-       if (oldval && oldlenp) {
-               size_t oldlen;
-
-               if (get_user(oldlen, oldlenp))
-                       return -EFAULT;
-
-               if (oldlen != sizeof(int))
-                       return -EINVAL;
-
-               if (put_user(clock_cmode_current, (unsigned __user *)oldval) ||
-                   put_user(sizeof(int), oldlenp))
-                       return -EFAULT;
-       }
-       if (newval && newlen) {
-               int new_cmode;
-
-               if (newlen != sizeof(int))
-                       return -EINVAL;
-
-               if (get_user(new_cmode, (int __user *)newval))
-                       return -EFAULT;
-
-               return try_set_cmode(new_cmode)?:1;
-       }
-       return 1;
-}
-
 static int try_set_p0(int new_p0)
 {
        unsigned long flags, clkc;
@@ -314,37 +283,6 @@ static int p0_procctl(ctl_table *ctl, int write,
        return try_set_p0(new_p0)?:*lenp;
 }
 
-static int p0_sysctl(ctl_table *table,
-                    void __user *oldval, size_t __user *oldlenp,
-                    void __user *newval, size_t newlen)
-{
-       if (oldval && oldlenp) {
-               size_t oldlen;
-
-               if (get_user(oldlen, oldlenp))
-                       return -EFAULT;
-
-               if (oldlen != sizeof(int))
-                       return -EINVAL;
-
-               if (put_user(clock_p0_current, (unsigned __user *)oldval) ||
-                   put_user(sizeof(int), oldlenp))
-                       return -EFAULT;
-       }
-       if (newval && newlen) {
-               int new_p0;
-
-               if (newlen != sizeof(int))
-                       return -EINVAL;
-
-               if (get_user(new_p0, (int __user *)newval))
-                       return -EFAULT;
-
-               return try_set_p0(new_p0)?:1;
-       }
-       return 1;
-}
-
 static int cm_procctl(ctl_table *ctl, int write,
                      void __user *buffer, size_t *lenp, loff_t *fpos)
 {
@@ -358,42 +296,9 @@ static int cm_procctl(ctl_table *ctl, int write,
        return try_set_cm(new_cm)?:*lenp;
 }
 
-static int cm_sysctl(ctl_table *table,
-                    void __user *oldval, size_t __user *oldlenp,
-                    void __user *newval, size_t newlen)
-{
-       if (oldval && oldlenp) {
-               size_t oldlen;
-
-               if (get_user(oldlen, oldlenp))
-                       return -EFAULT;
-
-               if (oldlen != sizeof(int))
-                       return -EINVAL;
-
-               if (put_user(clock_cm_current, (unsigned __user *)oldval) ||
-                   put_user(sizeof(int), oldlenp))
-                       return -EFAULT;
-       }
-       if (newval && newlen) {
-               int new_cm;
-
-               if (newlen != sizeof(int))
-                       return -EINVAL;
-
-               if (get_user(new_cm, (int __user *)newval))
-                       return -EFAULT;
-
-               return try_set_cm(new_cm)?:1;
-       }
-       return 1;
-}
-
-
 static struct ctl_table pm_table[] =
 {
        {
-               .ctl_name       = CTL_PM_SUSPEND,
                .procname       = "suspend",
                .data           = NULL,
                .maxlen         = 0,
@@ -401,44 +306,37 @@ static struct ctl_table pm_table[] =
                .proc_handler   = &sysctl_pm_do_suspend,
        },
        {
-               .ctl_name       = CTL_PM_CMODE,
                .procname       = "cmode",
                .data           = &clock_cmode_current,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &cmode_procctl,
-               .strategy       = &cmode_sysctl,
        },
        {
-               .ctl_name       = CTL_PM_P0,
                .procname       = "p0",
                .data           = &clock_p0_current,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &p0_procctl,
-               .strategy       = &p0_sysctl,
        },
        {
-               .ctl_name       = CTL_PM_CM,
                .procname       = "cm",
                .data           = &clock_cm_current,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &cm_procctl,
-               .strategy       = &cm_sysctl,
        },
-       { .ctl_name = 0}
+       { }
 };
 
 static struct ctl_table pm_dir_table[] =
 {
        {
-               .ctl_name       = CTL_PM,
                .procname       = "pm",
                .mode           = 0555,
                .child          = pm_table,
        },
-       { .ctl_name = 0}
+       { }
 };
 
 /*
index 3e9d7e0..b30a4f2 100644 (file)
@@ -176,7 +176,6 @@ static int procctl_frv_pin_cxnr(ctl_table *table, int write, struct file *filp,
 static struct ctl_table frv_table[] =
 {
        {
-               .ctl_name       = 1,
                .procname       = "cache-mode",
                .data           = NULL,
                .maxlen         = 0,
@@ -185,7 +184,6 @@ static struct ctl_table frv_table[] =
        },
 #ifdef CONFIG_MMU
        {
-               .ctl_name       = 2,
                .procname       = "pin-cxnr",
                .data           = NULL,
                .maxlen         = 0,
@@ -203,7 +201,6 @@ static struct ctl_table frv_table[] =
 static struct ctl_table frv_dir_table[] =
 {
        {
-               .ctl_name       = CTL_FRV,
                .procname       = "frv",
                .mode           = 0555,
                .child          = frv_table
index af9405c..10c3751 100644 (file)
@@ -327,7 +327,7 @@ ia32_syscall_table:
        data8 compat_sys_writev
        data8 sys_getsid
        data8 sys_fdatasync
-       data8 sys32_sysctl
+       data8 compat_sys_sysctl
        data8 sys_mlock           /* 150 */
        data8 sys_munlock
        data8 sys_mlockall
index 625ed8f..429ec96 100644 (file)
@@ -1628,61 +1628,6 @@ sys32_msync (unsigned int start, unsigned int len, int flags)
        return sys_msync(addr, len + (start - addr), flags);
 }
 
-struct sysctl32 {
-       unsigned int    name;
-       int             nlen;
-       unsigned int    oldval;
-       unsigned int    oldlenp;
-       unsigned int    newval;
-       unsigned int    newlen;
-       unsigned int    __unused[4];
-};
-
-#ifdef CONFIG_SYSCTL_SYSCALL
-asmlinkage long
-sys32_sysctl (struct sysctl32 __user *args)
-{
-       struct sysctl32 a32;
-       mm_segment_t old_fs = get_fs ();
-       void __user *oldvalp, *newvalp;
-       size_t oldlen;
-       int __user *namep;
-       long ret;
-
-       if (copy_from_user(&a32, args, sizeof(a32)))
-               return -EFAULT;
-
-       /*
-        * We need to pre-validate these because we have to disable address checking
-        * before calling do_sysctl() because of OLDLEN but we can't run the risk of the
-        * user specifying bad addresses here.  Well, since we're dealing with 32 bit
-        * addresses, we KNOW that access_ok() will always succeed, so this is an
-        * expensive NOP, but so what...
-        */
-       namep = (int __user *) compat_ptr(a32.name);
-       oldvalp = compat_ptr(a32.oldval);
-       newvalp = compat_ptr(a32.newval);
-
-       if ((oldvalp && get_user(oldlen, (int __user *) compat_ptr(a32.oldlenp)))
-           || !access_ok(VERIFY_WRITE, namep, 0)
-           || !access_ok(VERIFY_WRITE, oldvalp, 0)
-           || !access_ok(VERIFY_WRITE, newvalp, 0))
-               return -EFAULT;
-
-       set_fs(KERNEL_DS);
-       lock_kernel();
-       ret = do_sysctl(namep, a32.nlen, oldvalp, (size_t __user *) &oldlen,
-                       newvalp, (size_t) a32.newlen);
-       unlock_kernel();
-       set_fs(old_fs);
-
-       if (oldvalp && put_user (oldlen, (int __user *) compat_ptr(a32.oldlenp)))
-               return -EFAULT;
-
-       return ret;
-}
-#endif
-
 asmlinkage long
 sys32_newuname (struct new_utsname __user *name)
 {
index 6631a9d..7c7d6a6 100644 (file)
@@ -239,7 +239,6 @@ kdump_init_notifier(struct notifier_block *self, unsigned long val, void *data)
 #ifdef CONFIG_SYSCTL
 static ctl_table kdump_ctl_table[] = {
        {
-               .ctl_name = CTL_UNNUMBERED,
                .procname = "kdump_on_init",
                .data = &kdump_on_init,
                .maxlen = sizeof(int),
@@ -247,24 +246,22 @@ static ctl_table kdump_ctl_table[] = {
                .proc_handler = &proc_dointvec,
        },
        {
-               .ctl_name = CTL_UNNUMBERED,
                .procname = "kdump_on_fatal_mca",
                .data = &kdump_on_fatal_mca,
                .maxlen = sizeof(int),
                .mode = 0644,
                .proc_handler = &proc_dointvec,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table sys_table[] = {
        {
-         .ctl_name = CTL_KERN,
          .procname = "kernel",
          .mode = 0555,
          .child = kdump_ctl_table,
        },
-       { .ctl_name = 0 }
+       { }
 };
 #endif
 
index f178270..ca30b36 100644 (file)
@@ -522,7 +522,6 @@ EXPORT_SYMBOL(pfm_sysctl);
 
 static ctl_table pfm_ctl_table[]={
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "debug",
                .data           = &pfm_sysctl.debug,
                .maxlen         = sizeof(int),
@@ -530,7 +529,6 @@ static ctl_table pfm_ctl_table[]={
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "debug_ovfl",
                .data           = &pfm_sysctl.debug_ovfl,
                .maxlen         = sizeof(int),
@@ -538,7 +536,6 @@ static ctl_table pfm_ctl_table[]={
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "fastctxsw",
                .data           = &pfm_sysctl.fastctxsw,
                .maxlen         = sizeof(int),
@@ -546,7 +543,6 @@ static ctl_table pfm_ctl_table[]={
                .proc_handler   =  &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "expert_mode",
                .data           = &pfm_sysctl.expert_mode,
                .maxlen         = sizeof(int),
@@ -557,7 +553,6 @@ static ctl_table pfm_ctl_table[]={
 };
 static ctl_table pfm_sysctl_dir[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "perfmon",
                .mode           = 0555,
                .child          = pfm_ctl_table,
@@ -566,7 +561,6 @@ static ctl_table pfm_sysctl_dir[] = {
 };
 static ctl_table pfm_sysctl_root[] = {
        {
-               .ctl_name       = CTL_KERN,
                .procname       = "kernel",
                .mode           = 0555,
                .child          = pfm_sysctl_dir,
index b77fefa..1a2793e 100644 (file)
@@ -265,67 +265,6 @@ SYSCALL_DEFINE5(n32_msgrcv, int, msqid, u32, msgp, size_t, msgsz,
 }
 #endif
 
-struct sysctl_args32
-{
-       compat_caddr_t name;
-       int nlen;
-       compat_caddr_t oldval;
-       compat_caddr_t oldlenp;
-       compat_caddr_t newval;
-       compat_size_t newlen;
-       unsigned int __unused[4];
-};
-
-#ifdef CONFIG_SYSCTL_SYSCALL
-
-SYSCALL_DEFINE1(32_sysctl, struct sysctl_args32 __user *, args)
-{
-       struct sysctl_args32 tmp;
-       int error;
-       size_t oldlen;
-       size_t __user *oldlenp = NULL;
-       unsigned long addr = (((unsigned long)&args->__unused[0]) + 7) & ~7;
-
-       if (copy_from_user(&tmp, args, sizeof(tmp)))
-               return -EFAULT;
-
-       if (tmp.oldval && tmp.oldlenp) {
-               /* Duh, this is ugly and might not work if sysctl_args
-                  is in read-only memory, but do_sysctl does indirectly
-                  a lot of uaccess in both directions and we'd have to
-                  basically copy the whole sysctl.c here, and
-                  glibc's __sysctl uses rw memory for the structure
-                  anyway.  */
-               if (get_user(oldlen, (u32 __user *)A(tmp.oldlenp)) ||
-                   put_user(oldlen, (size_t __user *)addr))
-                       return -EFAULT;
-               oldlenp = (size_t __user *)addr;
-       }
-
-       lock_kernel();
-       error = do_sysctl((int __user *)A(tmp.name), tmp.nlen, (void __user *)A(tmp.oldval),
-                         oldlenp, (void __user *)A(tmp.newval), tmp.newlen);
-       unlock_kernel();
-       if (oldlenp) {
-               if (!error) {
-                       if (get_user(oldlen, (size_t __user *)addr) ||
-                           put_user(oldlen, (u32 __user *)A(tmp.oldlenp)))
-                               error = -EFAULT;
-               }
-               copy_to_user(args->__unused, tmp.__unused, sizeof(tmp.__unused));
-       }
-       return error;
-}
-
-#else
-
-SYSCALL_DEFINE1(32_sysctl, struct sysctl_args32 __user *, args)
-{
-       return -ENOSYS;
-}
-
-#endif /* CONFIG_SYSCTL_SYSCALL */
-
 SYSCALL_DEFINE1(32_newuname, struct new_utsname __user *, name)
 {
        int ret = 0;
index 6ebc079..8a0be0b 100644 (file)
@@ -272,7 +272,7 @@ EXPORT(sysn32_call_table)
        PTR     sys_munlockall
        PTR     sys_vhangup                     /* 6150 */
        PTR     sys_pivot_root
-       PTR     sys_32_sysctl
+       PTR     compat_sys_sysctl
        PTR     sys_prctl
        PTR     compat_sys_adjtimex
        PTR     compat_sys_setrlimit            /* 6155 */
index 14dde4c..41dbdb7 100644 (file)
@@ -356,7 +356,7 @@ sys_call_table:
        PTR     sys_ni_syscall                  /* 4150 */
        PTR     sys_getsid
        PTR     sys_fdatasync
-       PTR     sys_32_sysctl
+       PTR     compat_sys_sysctl
        PTR     sys_mlock
        PTR     sys_munlock                     /* 4155 */
        PTR     sys_mlockall
index b3deed8..1dbdd76 100644 (file)
 #include "ds1603.h"
 #endif
 
-/* Strategy function to write EEPROM after changing string entry */
-int sysctl_lasatstring(ctl_table *table,
-               void *oldval, size_t *oldlenp,
-               void *newval, size_t newlen)
-{
-       int r;
-
-       r = sysctl_string(table, oldval, oldlenp, newval, newlen);
-       if (r < 0)
-               return r;
-
-       if (newval && newlen)
-               lasat_write_eeprom_info();
-
-       return 0;
-}
-
 
 /* And the same for proc */
 int proc_dolasatstring(ctl_table *table, int write,
@@ -113,46 +96,6 @@ int proc_dolasatrtc(ctl_table *table, int write,
 }
 #endif
 
-/* Sysctl for setting the IP addresses */
-int sysctl_lasat_intvec(ctl_table *table,
-                   void *oldval, size_t *oldlenp,
-                   void *newval, size_t newlen)
-{
-       int r;
-
-       r = sysctl_intvec(table, oldval, oldlenp, newval, newlen);
-       if (r < 0)
-               return r;
-
-       if (newval && newlen)
-               lasat_write_eeprom_info();
-
-       return 0;
-}
-
-#ifdef CONFIG_DS1603
-/* Same for RTC */
-int sysctl_lasat_rtc(ctl_table *table,
-                   void *oldval, size_t *oldlenp,
-                   void *newval, size_t newlen)
-{
-       struct timespec ts;
-       int r;
-
-       read_persistent_clock(&ts);
-       rtctmp = ts.tv_sec;
-       if (rtctmp < 0)
-               rtctmp = 0;
-       r = sysctl_intvec(table, oldval, oldlenp, newval, newlen);
-       if (r < 0)
-               return r;
-       if (newval && newlen)
-               rtc_mips_set_mmss(rtctmp);
-
-       return r;
-}
-#endif
-
 #ifdef CONFIG_INET
 int proc_lasat_ip(ctl_table *table, int write,
                       void *buffer, size_t *lenp, loff_t *ppos)
@@ -214,23 +157,6 @@ int proc_lasat_ip(ctl_table *table, int write,
 }
 #endif
 
-static int sysctl_lasat_prid(ctl_table *table,
-                                    void *oldval, size_t *oldlenp,
-                                    void *newval, size_t newlen)
-{
-       int r;
-
-       r = sysctl_intvec(table, oldval, oldlenp, newval, newlen);
-       if (r < 0)
-               return r;
-       if (newval && newlen) {
-               lasat_board_info.li_eeprom_info.prid = *(int *)newval;
-               lasat_write_eeprom_info();
-               lasat_init_board_info();
-       }
-       return 0;
-}
-
 int proc_lasat_prid(ctl_table *table, int write,
                       void *buffer, size_t *lenp, loff_t *ppos)
 {
@@ -252,115 +178,92 @@ extern int lasat_boot_to_service;
 
 static ctl_table lasat_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "cpu-hz",
                .data           = &lasat_board_info.li_cpu_hz,
                .maxlen         = sizeof(int),
                .mode           = 0444,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "bus-hz",
                .data           = &lasat_board_info.li_bus_hz,
                .maxlen         = sizeof(int),
                .mode           = 0444,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "bmid",
                .data           = &lasat_board_info.li_bmid,
                .maxlen         = sizeof(int),
                .mode           = 0444,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "prid",
                .data           = &lasat_board_info.li_prid,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_lasat_prid,
-               .strategy       = &sysctl_lasat_prid
-       },
+.      },
 #ifdef CONFIG_INET
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "ipaddr",
                .data           = &lasat_board_info.li_eeprom_info.ipaddr,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_lasat_ip,
-               .strategy       = &sysctl_lasat_intvec
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "netmask",
                .data           = &lasat_board_info.li_eeprom_info.netmask,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_lasat_ip,
-               .strategy       = &sysctl_lasat_intvec
        },
 #endif
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "passwd_hash",
                .data           = &lasat_board_info.li_eeprom_info.passwd_hash,
                .maxlen         =
                        sizeof(lasat_board_info.li_eeprom_info.passwd_hash),
                .mode           = 0600,
                .proc_handler   = &proc_dolasatstring,
-               .strategy       = &sysctl_lasatstring
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "boot-service",
                .data           = &lasat_boot_to_service,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec
        },
 #ifdef CONFIG_DS1603
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "rtc",
                .data           = &rtctmp,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dolasatrtc,
-               .strategy       = &sysctl_lasat_rtc
        },
 #endif
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "namestr",
                .data           = &lasat_board_info.li_namestr,
                .maxlen         = sizeof(lasat_board_info.li_namestr),
                .mode           = 0444,
                .proc_handler   = &proc_dostring,
-               .strategy       = &sysctl_string
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "typestr",
                .data           = &lasat_board_info.li_typestr,
                .maxlen         = sizeof(lasat_board_info.li_typestr),
                .mode           = 0444,
                .proc_handler   = &proc_dostring,
-               .strategy       = &sysctl_string
        },
        {}
 };
 
 static ctl_table lasat_root_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "lasat",
                .mode           =  0555,
                .child          = lasat_table
index 561388b..76d23ec 100644 (file)
@@ -90,77 +90,6 @@ asmlinkage long sys32_unimplemented(int r26, int r25, int r24, int r23,
     return -ENOSYS;
 }
 
-#ifdef CONFIG_SYSCTL
-
-struct __sysctl_args32 {
-       u32 name;
-       int nlen;
-       u32 oldval;
-       u32 oldlenp;
-       u32 newval;
-       u32 newlen;
-       u32 __unused[4];
-};
-
-asmlinkage long sys32_sysctl(struct __sysctl_args32 __user *args)
-{
-#ifndef CONFIG_SYSCTL_SYSCALL
-       return -ENOSYS;
-#else
-       struct __sysctl_args32 tmp;
-       int error;
-       unsigned int oldlen32;
-       size_t oldlen, __user *oldlenp = NULL;
-       unsigned long addr = (((long __force)&args->__unused[0]) + 7) & ~7;
-
-       DBG(("sysctl32(%p)\n", args));
-
-       if (copy_from_user(&tmp, args, sizeof(tmp)))
-               return -EFAULT;
-
-       if (tmp.oldval && tmp.oldlenp) {
-               /* Duh, this is ugly and might not work if sysctl_args
-                  is in read-only memory, but do_sysctl does indirectly
-                  a lot of uaccess in both directions and we'd have to
-                  basically copy the whole sysctl.c here, and
-                  glibc's __sysctl uses rw memory for the structure
-                  anyway.  */
-               /* a possibly better hack than this, which will avoid the
-                * problem if the struct is read only, is to push the
-                * 'oldlen' value out to the user's stack instead. -PB
-                */
-               if (get_user(oldlen32, (u32 *)(u64)tmp.oldlenp))
-                       return -EFAULT;
-               oldlen = oldlen32;
-               if (put_user(oldlen, (size_t *)addr))
-                       return -EFAULT;
-               oldlenp = (size_t *)addr;
-       }
-
-       lock_kernel();
-       error = do_sysctl((int __user *)(u64)tmp.name, tmp.nlen,
-                         (void __user *)(u64)tmp.oldval, oldlenp,
-                         (void __user *)(u64)tmp.newval, tmp.newlen);
-       unlock_kernel();
-       if (oldlenp) {
-               if (!error) {
-                       if (get_user(oldlen, (size_t *)addr)) {
-                               error = -EFAULT;
-                       } else {
-                               oldlen32 = oldlen;
-                               if (put_user(oldlen32, (u32 *)(u64)tmp.oldlenp))
-                                       error = -EFAULT;
-                       }
-               }
-               if (copy_to_user(args->__unused, tmp.__unused, sizeof(tmp.__unused)))
-                       error = -EFAULT;
-       }
-       return error;
-#endif
-}
-
-#endif /* CONFIG_SYSCTL */
-
 asmlinkage long sys32_sched_rr_get_interval(pid_t pid,
        struct compat_timespec __user *interval)
 {
index 843f423..01c4fcf 100644 (file)
        ENTRY_SAME(getsid)
        ENTRY_SAME(fdatasync)
        /* struct __sysctl_args is a mess */
-       ENTRY_DIFF(sysctl)
+       ENTRY_COMP(sysctl)
        ENTRY_SAME(mlock)               /* 150 */
        ENTRY_SAME(munlock)
        ENTRY_SAME(mlockall)
index 88d9c1d..cece9e2 100644 (file)
@@ -110,7 +110,6 @@ int powersave_nap;
  */
 static ctl_table powersave_nap_ctl_table[]={
        {
-               .ctl_name       = KERN_PPC_POWERSAVE_NAP,
                .procname       = "powersave-nap",
                .data           = &powersave_nap,
                .maxlen         = sizeof(int),
@@ -121,7 +120,6 @@ static ctl_table powersave_nap_ctl_table[]={
 };
 static ctl_table powersave_nap_sysctl_root[] = {
        {
-               .ctl_name       = CTL_KERN,
                .procname       = "kernel",
                .mode           = 0555,
                .child          = powersave_nap_ctl_table,
index b97c2d6..c5a4732 100644 (file)
@@ -520,58 +520,6 @@ asmlinkage long compat_sys_umask(u32 mask)
        return sys_umask((int)mask);
 }
 
-#ifdef CONFIG_SYSCTL_SYSCALL
-struct __sysctl_args32 {
-       u32 name;
-       int nlen;
-       u32 oldval;
-       u32 oldlenp;
-       u32 newval;
-       u32 newlen;
-       u32 __unused[4];
-};
-
-asmlinkage long compat_sys_sysctl(struct __sysctl_args32 __user *args)
-{
-       struct __sysctl_args32 tmp;
-       int error;
-       size_t oldlen;
-       size_t __user *oldlenp = NULL;
-       unsigned long addr = (((unsigned long)&args->__unused[0]) + 7) & ~7;
-
-       if (copy_from_user(&tmp, args, sizeof(tmp)))
-               return -EFAULT;
-
-       if (tmp.oldval && tmp.oldlenp) {
-               /* Duh, this is ugly and might not work if sysctl_args
-                  is in read-only memory, but do_sysctl does indirectly
-                  a lot of uaccess in both directions and we'd have to
-                  basically copy the whole sysctl.c here, and
-                  glibc's __sysctl uses rw memory for the structure
-                  anyway.  */
-               oldlenp = (size_t __user *)addr;
-               if (get_user(oldlen, (compat_size_t __user *)compat_ptr(tmp.oldlenp)) ||
-                   put_user(oldlen, oldlenp))
-                       return -EFAULT;
-       }
-
-       lock_kernel();
-       error = do_sysctl(compat_ptr(tmp.name), tmp.nlen,
-                         compat_ptr(tmp.oldval), oldlenp,
-                         compat_ptr(tmp.newval), tmp.newlen);
-       unlock_kernel();
-       if (oldlenp) {
-               if (!error) {
-                       if (get_user(oldlen, oldlenp) ||
-                           put_user(oldlen, (compat_size_t __user *)compat_ptr(tmp.oldlenp)))
-                               error = -EFAULT;
-               }
-               copy_to_user(args->__unused, tmp.__unused, sizeof(tmp.__unused));
-       }
-       return error;
-}
-#endif
-
 unsigned long compat_sys_mmap2(unsigned long addr, size_t len,
                          unsigned long prot, unsigned long flags,
                          unsigned long fd, unsigned long pgoff)
index 0debcec..fda1a81 100644 (file)
@@ -527,59 +527,6 @@ asmlinkage long sys32_sendfile64(int out_fd, int in_fd,
        return ret;
 }
 
-#ifdef CONFIG_SYSCTL_SYSCALL
-struct __sysctl_args32 {
-       u32 name;
-       int nlen;
-       u32 oldval;
-       u32 oldlenp;
-       u32 newval;
-       u32 newlen;
-       u32 __unused[4];
-};
-
-asmlinkage long sys32_sysctl(struct __sysctl_args32 __user *args)
-{
-       struct __sysctl_args32 tmp;
-       int error;
-       size_t oldlen;
-       size_t __user *oldlenp = NULL;
-       unsigned long addr = (((unsigned long)&args->__unused[0]) + 7) & ~7;
-
-       if (copy_from_user(&tmp, args, sizeof(tmp)))
-               return -EFAULT;
-
-       if (tmp.oldval && tmp.oldlenp) {
-               /* Duh, this is ugly and might not work if sysctl_args
-                  is in read-only memory, but do_sysctl does indirectly
-                  a lot of uaccess in both directions and we'd have to
-                  basically copy the whole sysctl.c here, and
-                  glibc's __sysctl uses rw memory for the structure
-                  anyway.  */
-               if (get_user(oldlen, (u32 __user *)compat_ptr(tmp.oldlenp)) ||
-                   put_user(oldlen, (size_t __user *)addr))
-                       return -EFAULT;
-               oldlenp = (size_t __user *)addr;
-       }
-
-       lock_kernel();
-       error = do_sysctl(compat_ptr(tmp.name), tmp.nlen, compat_ptr(tmp.oldval),
-                         oldlenp, compat_ptr(tmp.newval), tmp.newlen);
-       unlock_kernel();
-       if (oldlenp) {
-               if (!error) {
-                       if (get_user(oldlen, (size_t __user *)addr) ||
-                           put_user(oldlen, (u32 __user *)compat_ptr(tmp.oldlenp)))
-                               error = -EFAULT;
-               }
-               if (copy_to_user(args->__unused, tmp.__unused,
-                                sizeof(tmp.__unused)))
-                       error = -EFAULT;
-       }
-       return error;
-}
-#endif
-
 struct stat64_emu31 {
        unsigned long long  st_dev;
        unsigned int    __pad1;
index c07f9ca..45e9092 100644 (file)
@@ -162,7 +162,6 @@ struct ucontext32 {
        compat_sigset_t         uc_sigmask;     /* mask last for extensibility */
 };
 
-struct __sysctl_args32;
 struct stat64_emu31;
 struct mmap_arg_struct_emu31;
 struct fadvise64_64_args;
@@ -212,7 +211,6 @@ long sys32_sendfile(int out_fd, int in_fd, compat_off_t __user *offset,
                    size_t count);
 long sys32_sendfile64(int out_fd, int in_fd, compat_loff_t __user *offset,
                      s32 count);
-long sys32_sysctl(struct __sysctl_args32 __user *args);
 long sys32_stat64(char __user * filename, struct stat64_emu31 __user * statbuf);
 long sys32_lstat64(char __user * filename,
                   struct stat64_emu31 __user * statbuf);
index cbd9901..30de2d0 100644 (file)
@@ -689,8 +689,6 @@ sys32_fdatasync_wrapper:
        llgfr   %r2,%r2                 # unsigned int
        jg      sys_fdatasync           # branch to system call
 
-#sys32_sysctl_wrapper                  # tbd
-
        .globl  sys32_mlock_wrapper
 sys32_mlock_wrapper:
        llgfr   %r2,%r2                 # unsigned long
@@ -1087,8 +1085,8 @@ sys32_stime_wrapper:
 
        .globl  sys32_sysctl_wrapper
 sys32_sysctl_wrapper:
-       llgtr   %r2,%r2                 # struct __sysctl_args32 *
-       jg      sys32_sysctl
+       llgtr   %r2,%r2                 # struct compat_sysctl_args *
+       jg      compat_sys_sysctl
 
        .globl  sys32_fstat64_wrapper
 sys32_fstat64_wrapper:
index 20f282c..adf1126 100644 (file)
@@ -893,35 +893,30 @@ s390dbf_procactive(ctl_table *table, int write,
 
 static struct ctl_table s390dbf_table[] = {
        {
-               .ctl_name       = CTL_S390DBF_STOPPABLE,
                .procname       = "debug_stoppable",
                .data           = &debug_stoppable,
                .maxlen         = sizeof(int),
                .mode           = S_IRUGO | S_IWUSR,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec,
        },
         {
-               .ctl_name       = CTL_S390DBF_ACTIVE,
                .procname       = "debug_active",
                .data           = &debug_active,
                .maxlen         = sizeof(int),
                .mode           = S_IRUGO | S_IWUSR,
                .proc_handler   = &s390dbf_procactive,
-               .strategy       = &sysctl_intvec,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table s390dbf_dir_table[] = {
        {
-               .ctl_name       = CTL_S390DBF,
                .procname       = "s390dbf",
                .maxlen         = 0,
                .mode           = S_IRUGO | S_IXUGO,
                .child          = s390dbf_table,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table_header *s390dbf_sysctl_header;
index b201135..dab3e4a 100644 (file)
@@ -355,18 +355,17 @@ static struct ctl_table cmm_table[] = {
                .mode           = 0644,
                .proc_handler   = &cmm_timeout_handler,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table cmm_dir_table[] = {
        {
-               .ctl_name       = CTL_VM,
                .procname       = "vm",
                .maxlen         = 0,
                .mode           = 0555,
                .child          = cmm_table,
        },
-       { .ctl_name = 0 }
+       { }
 };
 #endif
 
index 267e5eb..080c8ee 100644 (file)
@@ -877,7 +877,6 @@ static int misaligned_fixup(struct pt_regs *regs)
 
 static ctl_table unaligned_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "kernel_reports",
                .data           = &kernel_mode_unaligned_fixup_count,
                .maxlen         = sizeof(int),
@@ -885,7 +884,6 @@ static ctl_table unaligned_table[] = {
                .proc_handler   = &proc_dointvec
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "user_reports",
                .data           = &user_mode_unaligned_fixup_count,
                .maxlen         = sizeof(int),
@@ -893,7 +891,6 @@ static ctl_table unaligned_table[] = {
                .proc_handler   = &proc_dointvec
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "user_enable",
                .data           = &user_mode_unaligned_fixup_enable,
                .maxlen         = sizeof(int),
@@ -904,17 +901,15 @@ static ctl_table unaligned_table[] = {
 
 static ctl_table unaligned_root[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "unaligned_fixup",
                .mode           = 0555,
-               unaligned_table
+               .child          = unaligned_table
        },
        {}
 };
 
 static ctl_table sh64_root[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sh64",
                .mode           = 0555,
                .child          = unaligned_root
index 04e28b2..f862372 100644 (file)
@@ -591,63 +591,6 @@ out:
        return ret;       
 }
 
-struct __sysctl_args32 {
-       u32 name;
-       int nlen;
-       u32 oldval;
-       u32 oldlenp;
-       u32 newval;
-       u32 newlen;
-       u32 __unused[4];
-};
-
-asmlinkage long sys32_sysctl(struct __sysctl_args32 __user *args)
-{
-#ifndef CONFIG_SYSCTL_SYSCALL
-       return -ENOSYS;
-#else
-       struct __sysctl_args32 tmp;
-       int error;
-       size_t oldlen, __user *oldlenp = NULL;
-       unsigned long addr = (((unsigned long)&args->__unused[0]) + 7UL) & ~7UL;
-
-       if (copy_from_user(&tmp, args, sizeof(tmp)))
-               return -EFAULT;
-
-       if (tmp.oldval && tmp.oldlenp) {
-               /* Duh, this is ugly and might not work if sysctl_args
-                  is in read-only memory, but do_sysctl does indirectly
-                  a lot of uaccess in both directions and we'd have to
-                  basically copy the whole sysctl.c here, and
-                  glibc's __sysctl uses rw memory for the structure
-                  anyway.  */
-               if (get_user(oldlen, (u32 __user *)(unsigned long)tmp.oldlenp) ||
-                   put_user(oldlen, (size_t __user *)addr))
-                       return -EFAULT;
-               oldlenp = (size_t __user *)addr;
-       }
-
-       lock_kernel();
-       error = do_sysctl((int __user *)(unsigned long) tmp.name,
-                         tmp.nlen,
-                         (void __user *)(unsigned long) tmp.oldval,
-                         oldlenp,
-                         (void __user *)(unsigned long) tmp.newval,
-                         tmp.newlen);
-       unlock_kernel();
-       if (oldlenp) {
-               if (!error) {
-                       if (get_user(oldlen, (size_t __user *)addr) ||
-                           put_user(oldlen, (u32 __user *)(unsigned long) tmp.oldlenp))
-                               error = -EFAULT;
-               }
-               if (copy_to_user(args->__unused, tmp.__unused, sizeof(tmp.__unused)))
-                       error = -EFAULT;
-       }
-       return error;
-#endif
-}
-
 long sys32_lookup_dcookie(unsigned long cookie_high,
                          unsigned long cookie_low,
                          char __user *buf, size_t len)
index 009825f..034b10e 100644 (file)
@@ -68,7 +68,7 @@ sys_call_table32:
        .word compat_sys_fstatfs64, sys_llseek, sys_mlock, sys_munlock, sys32_mlockall
 /*240*/        .word sys_munlockall, sys32_sched_setparam, sys32_sched_getparam, sys32_sched_setscheduler, sys32_sched_getscheduler
        .word sys_sched_yield, sys32_sched_get_priority_max, sys32_sched_get_priority_min, sys32_sched_rr_get_interval, compat_sys_nanosleep
-/*250*/        .word sys32_mremap, sys32_sysctl, sys32_getsid, sys_fdatasync, sys32_nfsservctl
+/*250*/        .word sys32_mremap, compat_sys_sysctl, sys32_getsid, sys_fdatasync, sys32_nfsservctl
        .word sys32_sync_file_range, compat_sys_clock_settime, compat_sys_clock_gettime, compat_sys_clock_getres, sys32_clock_nanosleep
 /*260*/        .word compat_sys_sched_getaffinity, compat_sys_sched_setaffinity, sys32_timer_settime, compat_sys_timer_gettime, sys_timer_getoverrun
        .word sys_timer_delete, compat_sys_timer_create, sys_ni_syscall, compat_sys_io_setup, sys_io_destroy
index 581b056..5d25848 100644 (file)
@@ -653,7 +653,7 @@ ia32_sys_call_table:
        .quad compat_sys_writev
        .quad sys_getsid
        .quad sys_fdatasync
-       .quad sys32_sysctl      /* sysctl */
+       .quad compat_sys_sysctl /* sysctl */
        .quad sys_mlock         /* 150 */
        .quad sys_munlock
        .quad sys_mlockall
index 9f55271..df82c0e 100644 (file)
@@ -434,62 +434,6 @@ asmlinkage long sys32_rt_sigqueueinfo(int pid, int sig,
        return ret;
 }
 
-#ifdef CONFIG_SYSCTL_SYSCALL
-struct sysctl_ia32 {
-       unsigned int    name;
-       int             nlen;
-       unsigned int    oldval;
-       unsigned int    oldlenp;
-       unsigned int    newval;
-       unsigned int    newlen;
-       unsigned int    __unused[4];
-};
-
-
-asmlinkage long sys32_sysctl(struct sysctl_ia32 __user *args32)
-{
-       struct sysctl_ia32 a32;
-       mm_segment_t old_fs = get_fs();
-       void __user *oldvalp, *newvalp;
-       size_t oldlen;
-       int __user *namep;
-       long ret;
-
-       if (copy_from_user(&a32, args32, sizeof(a32)))
-               return -EFAULT;
-
-       /*
-        * We need to pre-validate these because we have to disable
-        * address checking before calling do_sysctl() because of
-        * OLDLEN but we can't run the risk of the user specifying bad
-        * addresses here.  Well, since we're dealing with 32 bit
-        * addresses, we KNOW that access_ok() will always succeed, so
-        * this is an expensive NOP, but so what...
-        */
-       namep = compat_ptr(a32.name);
-       oldvalp = compat_ptr(a32.oldval);
-       newvalp =  compat_ptr(a32.newval);
-
-       if ((oldvalp && get_user(oldlen, (int __user *)compat_ptr(a32.oldlenp)))
-           || !access_ok(VERIFY_WRITE, namep, 0)
-           || !access_ok(VERIFY_WRITE, oldvalp, 0)
-           || !access_ok(VERIFY_WRITE, newvalp, 0))
-               return -EFAULT;
-
-       set_fs(KERNEL_DS);
-       lock_kernel();
-       ret = do_sysctl(namep, a32.nlen, oldvalp, (size_t __user *)&oldlen,
-                       newvalp, (size_t) a32.newlen);
-       unlock_kernel();
-       set_fs(old_fs);
-
-       if (oldvalp && put_user(oldlen, (int __user *)compat_ptr(a32.oldlenp)))
-               return -EFAULT;
-
-       return ret;
-}
-#endif
-
 /* warning: next two assume little endian */
 asmlinkage long sys32_pread(unsigned int fd, char __user *ubuf, u32 count,
                            u32 poslo, u32 poshi)
index 72a6dcd..9af9dec 100644 (file)
@@ -51,11 +51,6 @@ asmlinkage long sys32_sched_rr_get_interval(compat_pid_t,
 asmlinkage long sys32_rt_sigpending(compat_sigset_t __user *, compat_size_t);
 asmlinkage long sys32_rt_sigqueueinfo(int, int, compat_siginfo_t __user *);
 
-#ifdef CONFIG_SYSCTL_SYSCALL
-struct sysctl_ia32;
-asmlinkage long sys32_sysctl(struct sysctl_ia32 __user *);
-#endif
-
 asmlinkage long sys32_pread(unsigned int, char __user *, u32, u32, u32);
 asmlinkage long sys32_pwrite(unsigned int, char __user *, u32, u32, u32);
 
index 8cb4974..e02d92d 100644 (file)
@@ -237,7 +237,7 @@ static ctl_table kernel_table2[] = {
 };
 
 static ctl_table kernel_root_table2[] = {
-       { .ctl_name = CTL_KERN, .procname = "kernel", .mode = 0555,
+       { .procname = "kernel", .mode = 0555,
          .child = kernel_table2 },
        {}
 };
index 58bc00f..02b442e 100644 (file)
@@ -393,7 +393,6 @@ static ctl_table abi_table2[] = {
 
 static ctl_table abi_root_table2[] = {
        {
-               .ctl_name = CTL_ABI,
                .procname = "abi",
                .mode = 0555,
                .child = abi_table2
index 5dc07e4..fe95975 100644 (file)
 #ifdef CONFIG_CRYPTO_FIPS
 static struct ctl_table crypto_sysctl_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "fips_enabled",
                .data           = &fips_enabled,
                .maxlen         = sizeof(int),
                .mode           = 0444,
                .proc_handler   = &proc_dointvec
        },
-       {
-               .ctl_name = 0,
-       },
+       {}
 };
 
 static struct ctl_table crypto_dir_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "crypto",
                .mode           = 0555,
                .child          = crypto_sysctl_table
        },
-       {
-               .ctl_name = 0,
-       },
+       {}
 };
 
 static struct ctl_table_header *crypto_sysctls;
index 614da5b..1872b6d 100644 (file)
@@ -3594,30 +3594,28 @@ static ctl_table cdrom_table[] = {
                .mode           = 0644,
                .proc_handler   = &cdrom_sysctl_handler
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table cdrom_cdrom_table[] = {
        {
-               .ctl_name       = DEV_CDROM,
                .procname       = "cdrom",
                .maxlen         = 0,
                .mode           = 0555,
                .child          = cdrom_table,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 /* Make sure that /proc/sys/dev is there */
 static ctl_table cdrom_root_table[] = {
        {
-               .ctl_name       = CTL_DEV,
                .procname       = "dev",
                .maxlen         = 0,
                .mode           = 0555,
                .child          = cdrom_cdrom_table,
        },
-       { .ctl_name = 0 }
+       { }
 };
 static struct ctl_table_header *cdrom_sysctl_header;
 
index 70a770a..a05a611 100644 (file)
@@ -675,36 +675,33 @@ static int hpet_is_known(struct hpet_data *hdp)
 
 static ctl_table hpet_table[] = {
        {
-        .ctl_name = CTL_UNNUMBERED,
         .procname = "max-user-freq",
         .data = &hpet_max_freq,
         .maxlen = sizeof(int),
         .mode = 0644,
         .proc_handler = &proc_dointvec,
         },
-       {.ctl_name = 0}
+       {}
 };
 
 static ctl_table hpet_root[] = {
        {
-        .ctl_name = CTL_UNNUMBERED,
         .procname = "hpet",
         .maxlen = 0,
         .mode = 0555,
         .child = hpet_table,
         },
-       {.ctl_name = 0}
+       {}
 };
 
 static ctl_table dev_root[] = {
        {
-        .ctl_name = CTL_DEV,
         .procname = "dev",
         .maxlen = 0,
         .mode = 0555,
         .child = hpet_root,
         },
-       {.ctl_name = 0}
+       {}
 };
 
 static struct ctl_table_header *sysctl_header;
index 2e66b5f..aa39722 100644 (file)
@@ -660,8 +660,7 @@ static struct ipmi_smi_watcher smi_watcher = {
 #include <linux/sysctl.h>
 
 static ctl_table ipmi_table[] = {
-       { .ctl_name     = DEV_IPMI_POWEROFF_POWERCYCLE,
-         .procname     = "poweroff_powercycle",
+       { .procname     = "poweroff_powercycle",
          .data         = &poweroff_powercycle,
          .maxlen       = sizeof(poweroff_powercycle),
          .mode         = 0644,
@@ -670,16 +669,14 @@ static ctl_table ipmi_table[] = {
 };
 
 static ctl_table ipmi_dir_table[] = {
-       { .ctl_name     = DEV_IPMI,
-         .procname     = "ipmi",
+       { .procname     = "ipmi",
          .mode         = 0555,
          .child        = ipmi_table },
        { }
 };
 
 static ctl_table ipmi_root_table[] = {
-       { .ctl_name     = CTL_DEV,
-         .procname     = "dev",
+       { .procname     = "dev",
          .mode         = 0555,
          .child        = ipmi_dir_table },
        { }
index 62f282e..d516e9c 100644 (file)
@@ -431,30 +431,25 @@ static struct cdev ptmx_cdev;
 
 static struct ctl_table pty_table[] = {
        {
-               .ctl_name       = PTY_MAX,
                .procname       = "max",
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .data           = &pty_limit,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &pty_limit_min,
                .extra2         = &pty_limit_max,
        }, {
-               .ctl_name       = PTY_NR,
                .procname       = "nr",
                .maxlen         = sizeof(int),
                .mode           = 0444,
                .data           = &pty_count,
                .proc_handler   = &proc_dointvec,
-       }, {
-               .ctl_name       = 0
-       }
+       }, 
+       {}
 };
 
 static struct ctl_table pty_kern_table[] = {
        {
-               .ctl_name       = KERN_PTY,
                .procname       = "pty",
                .mode           = 0555,
                .child          = pty_table,
@@ -464,7 +459,6 @@ static struct ctl_table pty_kern_table[] = {
 
 static struct ctl_table pty_root_table[] = {
        {
-               .ctl_name       = CTL_KERN,
                .procname       = "kernel",
                .mode           = 0555,
                .child          = pty_kern_table,
index 04b505e..bcf680f 100644 (file)
@@ -1257,40 +1257,9 @@ static int proc_do_uuid(ctl_table *table, int write,
        return proc_dostring(&fake_table, write, buffer, lenp, ppos);
 }
 
-static int uuid_strategy(ctl_table *table,
-                        void __user *oldval, size_t __user *oldlenp,
-                        void __user *newval, size_t newlen)
-{
-       unsigned char tmp_uuid[16], *uuid;
-       unsigned int len;
-
-       if (!oldval || !oldlenp)
-               return 1;
-
-       uuid = table->data;
-       if (!uuid) {
-               uuid = tmp_uuid;
-               uuid[8] = 0;
-       }
-       if (uuid[8] == 0)
-               generate_random_uuid(uuid);
-
-       if (get_user(len, oldlenp))
-               return -EFAULT;
-       if (len) {
-               if (len > 16)
-                       len = 16;
-               if (copy_to_user(oldval, uuid, len) ||
-                   put_user(len, oldlenp))
-                       return -EFAULT;
-       }
-       return 1;
-}
-
 static int sysctl_poolsize = INPUT_POOL_WORDS * 32;
 ctl_table random_table[] = {
        {
-               .ctl_name       = RANDOM_POOLSIZE,
                .procname       = "poolsize",
                .data           = &sysctl_poolsize,
                .maxlen         = sizeof(int),
@@ -1298,7 +1267,6 @@ ctl_table random_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = RANDOM_ENTROPY_COUNT,
                .procname       = "entropy_avail",
                .maxlen         = sizeof(int),
                .mode           = 0444,
@@ -1306,45 +1274,37 @@ ctl_table random_table[] = {
                .data           = &input_pool.entropy_count,
        },
        {
-               .ctl_name       = RANDOM_READ_THRESH,
                .procname       = "read_wakeup_threshold",
                .data           = &random_read_wakeup_thresh,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &min_read_thresh,
                .extra2         = &max_read_thresh,
        },
        {
-               .ctl_name       = RANDOM_WRITE_THRESH,
                .procname       = "write_wakeup_threshold",
                .data           = &random_write_wakeup_thresh,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &min_write_thresh,
                .extra2         = &max_write_thresh,
        },
        {
-               .ctl_name       = RANDOM_BOOT_ID,
                .procname       = "boot_id",
                .data           = &sysctl_bootid,
                .maxlen         = 16,
                .mode           = 0444,
                .proc_handler   = &proc_do_uuid,
-               .strategy       = &uuid_strategy,
        },
        {
-               .ctl_name       = RANDOM_UUID,
                .procname       = "uuid",
                .maxlen         = 16,
                .mode           = 0444,
                .proc_handler   = &proc_do_uuid,
-               .strategy       = &uuid_strategy,
        },
-       { .ctl_name = 0 }
+       { }
 };
 #endif         /* CONFIG_SYSCTL */
 
index bc4ab3e..37bfe23 100644 (file)
@@ -282,34 +282,31 @@ static irqreturn_t rtc_interrupt(int irq, void *dev_id)
  */
 static ctl_table rtc_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "max-user-freq",
                .data           = &rtc_max_user_freq,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table rtc_root[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "rtc",
                .mode           = 0555,
                .child          = rtc_table,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table dev_root[] = {
        {
-               .ctl_name       = CTL_DEV,
                .procname       = "dev",
                .mode           = 0555,
                .child          = rtc_root,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table_header *sysctl_header;
index cc9f275..2dd29b4 100644 (file)
@@ -27,7 +27,6 @@ static int mouse_last_keycode;
 /* file(s) in /proc/sys/dev/mac_hid */
 static ctl_table mac_hid_files[] = {
        {
-               .ctl_name       = DEV_MAC_HID_MOUSE_BUTTON_EMULATION,
                .procname       = "mouse_button_emulation",
                .data           = &mouse_emulate_buttons,
                .maxlen         = sizeof(int),
@@ -35,7 +34,6 @@ static ctl_table mac_hid_files[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = DEV_MAC_HID_MOUSE_BUTTON2_KEYCODE,
                .procname       = "mouse_button2_keycode",
                .data           = &mouse_button2_keycode,
                .maxlen         = sizeof(int),
@@ -43,38 +41,35 @@ static ctl_table mac_hid_files[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = DEV_MAC_HID_MOUSE_BUTTON3_KEYCODE,
                .procname       = "mouse_button3_keycode",
                .data           = &mouse_button3_keycode,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 /* dir in /proc/sys/dev */
 static ctl_table mac_hid_dir[] = {
        {
-               .ctl_name       = DEV_MAC_HID,
                .procname       = "mac_hid",
                .maxlen         = 0,
                .mode           = 0555,
                .child          = mac_hid_files,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 /* /proc/sys/dev itself, in case that is not there yet */
 static ctl_table mac_hid_root_dir[] = {
        {
-               .ctl_name       = CTL_DEV,
                .procname       = "dev",
                .maxlen         = 0,
                .mode           = 0555,
                .child          = mac_hid_dir,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table_header *mac_hid_sysctl_header;
index e64c971..1d52955 100644 (file)
@@ -98,7 +98,6 @@ static struct ctl_table_header *raid_table_header;
 
 static ctl_table raid_table[] = {
        {
-               .ctl_name       = DEV_RAID_SPEED_LIMIT_MIN,
                .procname       = "speed_limit_min",
                .data           = &sysctl_speed_limit_min,
                .maxlen         = sizeof(int),
@@ -106,36 +105,33 @@ static ctl_table raid_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = DEV_RAID_SPEED_LIMIT_MAX,
                .procname       = "speed_limit_max",
                .data           = &sysctl_speed_limit_max,
                .maxlen         = sizeof(int),
                .mode           = S_IRUGO|S_IWUSR,
                .proc_handler   = &proc_dointvec,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table raid_dir_table[] = {
        {
-               .ctl_name       = DEV_RAID,
                .procname       = "raid",
                .maxlen         = 0,
                .mode           = S_IRUGO|S_IXUGO,
                .child          = raid_table,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table raid_root_table[] = {
        {
-               .ctl_name       = CTL_DEV,
                .procname       = "dev",
                .maxlen         = 0,
                .mode           = 0555,
                .child          = raid_dir_table,
        },
-       { .ctl_name = 0 }
+       {  }
 };
 
 static const struct block_device_operations md_fops;
index fd3688a..ce98b93 100644 (file)
@@ -89,48 +89,40 @@ static int xpc_disengage_max_timelimit = 120;
 
 static ctl_table xpc_sys_xpc_hb_dir[] = {
        {
-        .ctl_name = CTL_UNNUMBERED,
         .procname = "hb_interval",
         .data = &xpc_hb_interval,
         .maxlen = sizeof(int),
         .mode = 0644,
         .proc_handler = &proc_dointvec_minmax,
-        .strategy = &sysctl_intvec,
         .extra1 = &xpc_hb_min_interval,
         .extra2 = &xpc_hb_max_interval},
        {
-        .ctl_name = CTL_UNNUMBERED,
         .procname = "hb_check_interval",
         .data = &xpc_hb_check_interval,
         .maxlen = sizeof(int),
         .mode = 0644,
         .proc_handler = &proc_dointvec_minmax,
-        .strategy = &sysctl_intvec,
         .extra1 = &xpc_hb_check_min_interval,
         .extra2 = &xpc_hb_check_max_interval},
        {}
 };
 static ctl_table xpc_sys_xpc_dir[] = {
        {
-        .ctl_name = CTL_UNNUMBERED,
         .procname = "hb",
         .mode = 0555,
         .child = xpc_sys_xpc_hb_dir},
        {
-        .ctl_name = CTL_UNNUMBERED,
         .procname = "disengage_timelimit",
         .data = &xpc_disengage_timelimit,
         .maxlen = sizeof(int),
         .mode = 0644,
         .proc_handler = &proc_dointvec_minmax,
-        .strategy = &sysctl_intvec,
         .extra1 = &xpc_disengage_min_timelimit,
         .extra2 = &xpc_disengage_max_timelimit},
        {}
 };
 static ctl_table xpc_sys_dir[] = {
        {
-        .ctl_name = CTL_UNNUMBERED,
         .procname = "xpc",
         .mode = 0555,
         .child = xpc_sys_xpc_dir},
index a8b6896..66a0b33 100644 (file)
@@ -816,84 +816,83 @@ static int arlan_sysctl_reset(ctl_table * ctl, int write,
 
 
 /* Place files in /proc/sys/dev/arlan */
-#define CTBLN(num,card,nam) \
-        { .ctl_name = num,\
-          .procname = #nam,\
+#define CTBLN(card,nam) \
+        { .procname = #nam,\
           .data = &(arlan_conf[card].nam),\
           .maxlen = sizeof(int), .mode = 0600, .proc_handler = &proc_dointvec}
 #ifdef ARLAN_DEBUGGING
 
 #define ARLAN_PROC_DEBUG_ENTRIES \
-        { .ctl_name = 48, .procname = "entry_exit_debug",\
+        { .procname = "entry_exit_debug",\
           .data = &arlan_entry_and_exit_debug,\
           .maxlen = sizeof(int), .mode = 0600, .proc_handler = &proc_dointvec},\
-       { .ctl_name = 49, .procname = "debug", .data = &arlan_debug,\
+       { .procname = "debug", .data = &arlan_debug,\
           .maxlen = sizeof(int), .mode = 0600, .proc_handler = &proc_dointvec},
 #else 
 #define ARLAN_PROC_DEBUG_ENTRIES
 #endif
 
 #define ARLAN_SYSCTL_TABLE_TOTAL(cardNo)\
-       CTBLN(1,cardNo,spreadingCode),\
-       CTBLN(2,cardNo, channelNumber),\
-       CTBLN(3,cardNo, scramblingDisable),\
-       CTBLN(4,cardNo, txAttenuation),\
-       CTBLN(5,cardNo, systemId), \
-       CTBLN(6,cardNo, maxDatagramSize),\
-       CTBLN(7,cardNo, maxFrameSize),\
-       CTBLN(8,cardNo, maxRetries),\
-       CTBLN(9,cardNo, receiveMode),\
-       CTBLN(10,cardNo, priority),\
-       CTBLN(11,cardNo, rootOrRepeater),\
-       CTBLN(12,cardNo, SID),\
-       CTBLN(13,cardNo, registrationMode),\
-       CTBLN(14,cardNo, registrationFill),\
-       CTBLN(15,cardNo, localTalkAddress),\
-       CTBLN(16,cardNo, codeFormat),\
-       CTBLN(17,cardNo, numChannels),\
-       CTBLN(18,cardNo, channel1),\
-       CTBLN(19,cardNo, channel2),\
-       CTBLN(20,cardNo, channel3),\
-       CTBLN(21,cardNo, channel4),\
-       CTBLN(22,cardNo, txClear),\
-       CTBLN(23,cardNo, txRetries),\
-       CTBLN(24,cardNo, txRouting),\
-       CTBLN(25,cardNo, txScrambled),\
-       CTBLN(26,cardNo, rxParameter),\
-       CTBLN(27,cardNo, txTimeoutMs),\
-       CTBLN(28,cardNo, waitCardTimeout),\
-       CTBLN(29,cardNo, channelSet), \
-       {.ctl_name = 30, .procname = "name",\
+       CTBLN(cardNo,spreadingCode),\
+       CTBLN(cardNo, channelNumber),\
+       CTBLN(cardNo, scramblingDisable),\
+       CTBLN(cardNo, txAttenuation),\
+       CTBLN(cardNo, systemId), \
+       CTBLN(cardNo, maxDatagramSize),\
+       CTBLN(cardNo, maxFrameSize),\
+       CTBLN(cardNo, maxRetries),\
+       CTBLN(cardNo, receiveMode),\
+       CTBLN(cardNo, priority),\
+       CTBLN(cardNo, rootOrRepeater),\
+       CTBLN(cardNo, SID),\
+       CTBLN(cardNo, registrationMode),\
+       CTBLN(cardNo, registrationFill),\
+       CTBLN(cardNo, localTalkAddress),\
+       CTBLN(cardNo, codeFormat),\
+       CTBLN(cardNo, numChannels),\
+       CTBLN(cardNo, channel1),\
+       CTBLN(cardNo, channel2),\
+       CTBLN(cardNo, channel3),\
+       CTBLN(cardNo, channel4),\
+       CTBLN(cardNo, txClear),\
+       CTBLN(cardNo, txRetries),\
+       CTBLN(cardNo, txRouting),\
+       CTBLN(cardNo, txScrambled),\
+       CTBLN(cardNo, rxParameter),\
+       CTBLN(cardNo, txTimeoutMs),\
+       CTBLN(cardNo, waitCardTimeout),\
+       CTBLN(cardNo, channelSet), \
+       { .procname = "name",\
         .data = arlan_conf[cardNo].siteName,\
         .maxlen = 16, .mode = 0600, .proc_handler = &proc_dostring},\
-       CTBLN(31,cardNo,waitTime),\
-       CTBLN(32,cardNo,lParameter),\
-       CTBLN(33,cardNo,_15),\
-       CTBLN(34,cardNo,headerSize),\
-       CTBLN(36,cardNo,tx_delay_ms),\
-       CTBLN(37,cardNo,retries),\
-       CTBLN(38,cardNo,ReTransmitPacketMaxSize),\
-       CTBLN(39,cardNo,waitReTransmitPacketMaxSize),\
-       CTBLN(40,cardNo,fastReTransCount),\
-       CTBLN(41,cardNo,driverRetransmissions),\
-       CTBLN(42,cardNo,txAckTimeoutMs),\
-       CTBLN(43,cardNo,registrationInterrupts),\
-       CTBLN(44,cardNo,hardwareType),\
-       CTBLN(45,cardNo,radioType),\
-       CTBLN(46,cardNo,writeEEPROM),\
-       CTBLN(47,cardNo,writeRadioType),\
+       CTBLN(cardNo,waitTime),\
+       CTBLN(cardNo,lParameter),\
+       CTBLN(cardNo,_15),\
+       CTBLN(cardNo,headerSize),\
+       CTBLN(cardNo,tx_delay_ms),\
+       CTBLN(cardNo,retries),\
+       CTBLN(cardNo,ReTransmitPacketMaxSize),\
+       CTBLN(cardNo,waitReTransmitPacketMaxSize),\
+       CTBLN(cardNo,fastReTransCount),\
+       CTBLN(cardNo,driverRetransmissions),\
+       CTBLN(cardNo,txAckTimeoutMs),\
+       CTBLN(cardNo,registrationInterrupts),\
+       CTBLN(cardNo,hardwareType),\
+       CTBLN(cardNo,radioType),\
+       CTBLN(cardNo,writeEEPROM),\
+       CTBLN(cardNo,writeRadioType),\
        ARLAN_PROC_DEBUG_ENTRIES\
-       CTBLN(50,cardNo,in_speed),\
-       CTBLN(51,cardNo,out_speed),\
-       CTBLN(52,cardNo,in_speed10),\
-       CTBLN(53,cardNo,out_speed10),\
-       CTBLN(54,cardNo,in_speed_max),\
-       CTBLN(55,cardNo,out_speed_max),\
-       CTBLN(56,cardNo,measure_rate),\
-       CTBLN(57,cardNo,pre_Command_Wait),\
-       CTBLN(58,cardNo,rx_tweak1),\
-       CTBLN(59,cardNo,rx_tweak2),\
-       CTBLN(60,cardNo,tx_queue_len),\
+       CTBLN(cardNo,in_speed),\
+       CTBLN(cardNo,out_speed),\
+       CTBLN(cardNo,in_speed10),\
+       CTBLN(cardNo,out_speed10),\
+       CTBLN(cardNo,in_speed_max),\
+       CTBLN(cardNo,out_speed_max),\
+       CTBLN(cardNo,measure_rate),\
+       CTBLN(cardNo,pre_Command_Wait),\
+       CTBLN(cardNo,rx_tweak1),\
+       CTBLN(cardNo,rx_tweak2),\
+       CTBLN(cardNo,tx_queue_len),\
 
 
 
@@ -903,7 +902,6 @@ static ctl_table arlan_conf_table0[] =
 
 #ifdef ARLAN_PROC_SHM_DUMP
        {
-               .ctl_name       = 150,
                .procname       = "arlan0-txRing",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -911,7 +909,6 @@ static ctl_table arlan_conf_table0[] =
                .proc_handler   = &arlan_sysctl_infotxRing,
        },
        {
-               .ctl_name       = 151,
                .procname       = "arlan0-rxRing",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -919,7 +916,6 @@ static ctl_table arlan_conf_table0[] =
                .proc_handler   = &arlan_sysctl_inforxRing,
        },
        {
-               .ctl_name       = 152,
                .procname       = "arlan0-18",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -927,7 +923,6 @@ static ctl_table arlan_conf_table0[] =
                .proc_handler   = &arlan_sysctl_info18,
        },
        {
-               .ctl_name       = 153,
                .procname       = "arlan0-ring",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -935,7 +930,6 @@ static ctl_table arlan_conf_table0[] =
                .proc_handler   = &arlan_sysctl_info161719,
        },
        {
-               .ctl_name       = 154,
                .procname       = "arlan0-shm-cpy",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -944,7 +938,6 @@ static ctl_table arlan_conf_table0[] =
        },
 #endif
        {
-               .ctl_name       = 155,
                .procname       = "config0",
                .data           = &conf_reset_result,
                .maxlen         = 100,
@@ -952,14 +945,13 @@ static ctl_table arlan_conf_table0[] =
                .proc_handler   = &arlan_configure
        },
        {
-               .ctl_name       = 156,
                .procname       = "reset0",
                .data           = &conf_reset_result,
                .maxlen         = 100,
                .mode           = 0400,
                .proc_handler   = &arlan_sysctl_reset,
        },
-       { .ctl_name = 0 }
+       {  }
 };
 
 static ctl_table arlan_conf_table1[] =
@@ -969,7 +961,6 @@ static ctl_table arlan_conf_table1[] =
 
 #ifdef ARLAN_PROC_SHM_DUMP
        {
-               .ctl_name       = 150,
                .procname       = "arlan1-txRing",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -977,7 +968,6 @@ static ctl_table arlan_conf_table1[] =
                .proc_handler   = &arlan_sysctl_infotxRing,
        },
        {
-               .ctl_name       = 151,
                .procname       = "arlan1-rxRing",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -985,7 +975,6 @@ static ctl_table arlan_conf_table1[] =
                .proc_handler   = &arlan_sysctl_inforxRing,
        },
        {
-               .ctl_name       = 152,
                .procname       = "arlan1-18",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -993,7 +982,6 @@ static ctl_table arlan_conf_table1[] =
                .proc_handler   = &arlan_sysctl_info18,
        },
        {
-               .ctl_name       = 153,
                .procname       = "arlan1-ring",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1001,7 +989,6 @@ static ctl_table arlan_conf_table1[] =
                .proc_handler   = &arlan_sysctl_info161719,
        },
        {
-               .ctl_name       = 154,
                .procname       = "arlan1-shm-cpy",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1010,7 +997,6 @@ static ctl_table arlan_conf_table1[] =
        },
 #endif
        {
-               .ctl_name       = 155,
                .procname       = "config1",
                .data           = &conf_reset_result,
                .maxlen         = 100,
@@ -1018,14 +1004,13 @@ static ctl_table arlan_conf_table1[] =
                .proc_handler   = &arlan_configure,
        },
        {
-               .ctl_name       = 156,
                .procname       = "reset1",
                .data           = &conf_reset_result,
                .maxlen         = 100,
                .mode           = 0400,
                .proc_handler   = &arlan_sysctl_reset,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table arlan_conf_table2[] =
@@ -1035,7 +1020,6 @@ static ctl_table arlan_conf_table2[] =
 
 #ifdef ARLAN_PROC_SHM_DUMP
        {
-               .ctl_name       = 150,
                .procname       = "arlan2-txRing",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1043,7 +1027,6 @@ static ctl_table arlan_conf_table2[] =
                .proc_handler   = &arlan_sysctl_infotxRing,
        },
        {
-               .ctl_name       = 151,
                .procname       = "arlan2-rxRing",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1051,7 +1034,6 @@ static ctl_table arlan_conf_table2[] =
                .proc_handler   = &arlan_sysctl_inforxRing,
        },
        {
-               .ctl_name       = 152,
                .procname       = "arlan2-18",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1059,7 +1041,6 @@ static ctl_table arlan_conf_table2[] =
                .proc_handler   = &arlan_sysctl_info18,
        },
        {
-               .ctl_name       = 153,
                .procname       = "arlan2-ring",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1067,7 +1048,6 @@ static ctl_table arlan_conf_table2[] =
                .proc_handler   = &arlan_sysctl_info161719,
        },
        {
-               .ctl_name       = 154,
                .procname       = "arlan2-shm-cpy",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1076,7 +1056,6 @@ static ctl_table arlan_conf_table2[] =
        },
 #endif
        {
-               .ctl_name       = 155,
                .procname       = "config2",
                .data           = &conf_reset_result,
                .maxlen         = 100,
@@ -1084,14 +1063,13 @@ static ctl_table arlan_conf_table2[] =
                .proc_handler   = &arlan_configure,
        },
        {
-               .ctl_name       = 156,
                .procname       = "reset2",
                .data           = &conf_reset_result,
                .maxlen         = 100,
                .mode           = 0400,
                .proc_handler   = &arlan_sysctl_reset,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table arlan_conf_table3[] =
@@ -1101,7 +1079,6 @@ static ctl_table arlan_conf_table3[] =
 
 #ifdef ARLAN_PROC_SHM_DUMP
        {
-               .ctl_name       = 150,
                .procname       = "arlan3-txRing",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1109,7 +1086,6 @@ static ctl_table arlan_conf_table3[] =
                .proc_handler   = &arlan_sysctl_infotxRing,
        },
        {
-               .ctl_name       = 151,
                .procname       = "arlan3-rxRing",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1117,7 +1093,6 @@ static ctl_table arlan_conf_table3[] =
                .proc_handler   = &arlan_sysctl_inforxRing,
        },
        {
-               .ctl_name       = 152,
                .procname       = "arlan3-18",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1125,7 +1100,6 @@ static ctl_table arlan_conf_table3[] =
                .proc_handler   = &arlan_sysctl_info18,
        },
        {
-               .ctl_name       = 153,
                .procname       = "arlan3-ring",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1133,7 +1107,6 @@ static ctl_table arlan_conf_table3[] =
                .proc_handler   = &arlan_sysctl_info161719,
        },
        {
-               .ctl_name       = 154,
                .procname       = "arlan3-shm-cpy",
                .data           = &arlan_drive_info,
                .maxlen         = ARLAN_STR_SIZE,
@@ -1142,7 +1115,6 @@ static ctl_table arlan_conf_table3[] =
        },
 #endif
        {
-               .ctl_name       = 155,
                .procname       = "config3",
                .data           = &conf_reset_result,
                .maxlen         = 100,
@@ -1150,14 +1122,13 @@ static ctl_table arlan_conf_table3[] =
                .proc_handler   = &arlan_configure,
        },
        {
-               .ctl_name       = 156,
                .procname       = "reset3",
                .data           = &conf_reset_result,
                .maxlen         = 100,
                .mode           = 0400,
                .proc_handler   = &arlan_sysctl_reset,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 
@@ -1165,41 +1136,37 @@ static ctl_table arlan_conf_table3[] =
 static ctl_table arlan_table[] =
 {
        {
-               .ctl_name       = 0,
                .procname       = "arlan0",
                .maxlen         = 0,
                .mode           = 0600,
                .child          = arlan_conf_table0,
        },
        {
-               .ctl_name       = 0,
                .procname       = "arlan1",
                .maxlen         = 0,
                .mode           = 0600,
                .child          = arlan_conf_table1,
        },
        {
-               .ctl_name       = 0,
                .procname       = "arlan2",
                .maxlen         = 0,
                .mode           = 0600,
                .child          = arlan_conf_table2,
        },
        {
-               .ctl_name       = 0,
                .procname       = "arlan3",
                .maxlen         = 0,
                .mode           = 0600,
                .child          = arlan_conf_table3,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 #else
 
-static ctl_table arlan_table[MAX_ARLANS + 1] =
+static ctl_table arlan_table[] =
 {
-       { .ctl_name = 0 }
+       { }
 };
 #endif
 
@@ -1209,22 +1176,14 @@ static ctl_table arlan_table[MAX_ARLANS + 1] =
 static ctl_table arlan_root_table[] =
 {
        {
-               .ctl_name       = CTL_ARLAN,
                .procname       = "arlan",
                .maxlen         = 0,
                .mode           = 0555,
                .child          = arlan_table,
        },
-       { .ctl_name = 0 }
+       {  }
 };
 
-/* Make sure that /proc/sys/dev is there */
-//static ctl_table arlan_device_root_table[] =
-//{
-//     {CTL_DEV, "dev", NULL, 0, 0555, arlan_root_table},
-//     {0}
-//};
-
 
 static struct ctl_table_header *arlan_device_sysctl_header;
 
@@ -1234,8 +1193,6 @@ int __init init_arlan_proc(void)
        int i = 0;
        if (arlan_device_sysctl_header)
                return 0;
-       for (i = 0; i < MAX_ARLANS && arlan_device[i]; i++)
-               arlan_table[i].ctl_name = i + 1;
        arlan_device_sysctl_header = register_sysctl_table(arlan_root_table);
        if (!arlan_device_sysctl_header)
                return -1;
index 8eefe56..f808bdb 100644 (file)
@@ -233,10 +233,10 @@ static int do_hardware_modes (ctl_table *table, int write,
        return copy_to_user(result, buffer, len) ? -EFAULT : 0;
 }
 
-#define PARPORT_PORT_DIR(CHILD) { .ctl_name = 0, .procname = NULL, .mode = 0555, .child = CHILD }
-#define PARPORT_PARPORT_DIR(CHILD) { .ctl_name = DEV_PARPORT, .procname = "parport", \
+#define PARPORT_PORT_DIR(CHILD) { .procname = NULL, .mode = 0555, .child = CHILD }
+#define PARPORT_PARPORT_DIR(CHILD) { .procname = "parport", \
                                      .mode = 0555, .child = CHILD }
-#define PARPORT_DEV_DIR(CHILD) { .ctl_name = CTL_DEV, .procname = "dev", .mode = 0555, .child = CHILD }
+#define PARPORT_DEV_DIR(CHILD) { .procname = "dev", .mode = 0555, .child = CHILD }
 #define PARPORT_DEVICES_ROOT_DIR  {  .procname = "devices", \
                                     .mode = 0555, .child = NULL }
 
@@ -393,7 +393,6 @@ parport_device_sysctl_template = {
        },
        {
                {
-                       .ctl_name       = 0,
                        .procname       = NULL,
                        .data           = NULL,
                        .maxlen         = 0,
@@ -455,7 +454,6 @@ parport_default_sysctl_table = {
        },
        {
                {
-                       .ctl_name       = DEV_PARPORT_DEFAULT,
                        .procname       = "default",
                        .mode           = 0555,
                        .child          = parport_default_sysctl_table.vars
@@ -495,7 +493,6 @@ int parport_proc_register(struct parport *port)
                t->vars[6 + i].extra2 = &port->probe_info[i];
 
        t->port_dir[0].procname = port->name;
-       t->port_dir[0].ctl_name = 0;
 
        t->port_dir[0].child = t->vars;
        t->parport_dir[0].child = t->port_dir;
@@ -534,11 +531,9 @@ int parport_device_proc_register(struct pardevice *device)
        t->dev_dir[0].child = t->parport_dir;
        t->parport_dir[0].child = t->port_dir;
        t->port_dir[0].procname = port->name;
-       t->port_dir[0].ctl_name = 0;
        t->port_dir[0].child = t->devices_root_dir;
        t->devices_root_dir[0].child = t->device_dir;
 
-       t->device_dir[0].ctl_name = 0;
        t->device_dir[0].procname = device->name;
        t->device_dir[0].child = t->vars;
        t->vars[0].data = &device->timeslice;
index b44462a..740fe40 100644 (file)
@@ -101,18 +101,17 @@ static struct ctl_table callhome_table[] = {
                .mode           = 0644,
                .proc_handler   = proc_handler_callhome,
        },
-       { .ctl_name = 0 }
+       {}
 };
 
 static struct ctl_table kern_dir_table[] = {
        {
-               .ctl_name       = CTL_KERN,
                .procname       = "kernel",
                .maxlen         = 0,
                .mode           = 0555,
                .child          = callhome_table,
        },
-       { .ctl_name = 0 }
+       {}
 };
 
 /*
index 63a30f5..42c31be 100644 (file)
@@ -13,8 +13,7 @@
 
 
 static ctl_table scsi_table[] = {
-       { .ctl_name     = DEV_SCSI_LOGGING_LEVEL,
-         .procname     = "logging_level",
+       { .procname     = "logging_level",
          .data         = &scsi_logging_level,
          .maxlen       = sizeof(scsi_logging_level),
          .mode         = 0644,
@@ -23,16 +22,14 @@ static ctl_table scsi_table[] = {
 };
 
 static ctl_table scsi_dir_table[] = {
-       { .ctl_name     = DEV_SCSI,
-         .procname     = "scsi",
+       { .procname     = "scsi",
          .mode         = 0555,
          .child        = scsi_table },
        { }
 };
 
 static ctl_table scsi_root_table[] = {
-       { .ctl_name     = CTL_DEV,
-         .procname     = "dev",
+       { .procname     = "dev",
          .mode         = 0555,
          .child        = scsi_dir_table },
        { }
index 43c96ce..354c050 100644 (file)
@@ -17,7 +17,6 @@ static struct ctl_table_header *fs_table_header;
 
 static ctl_table coda_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "timeout",
                .data           = &coda_timeout,
                .maxlen         = sizeof(int),
@@ -25,7 +24,6 @@ static ctl_table coda_table[] = {
                .proc_handler   = &proc_dointvec
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "hard",
                .data           = &coda_hard,
                .maxlen         = sizeof(int),
@@ -33,7 +31,6 @@ static ctl_table coda_table[] = {
                .proc_handler   = &proc_dointvec
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "fake_statfs",
                .data           = &coda_fake_statfs,
                .maxlen         = sizeof(int),
@@ -46,7 +43,6 @@ static ctl_table coda_table[] = {
 #ifdef CONFIG_SYSCTL
 static ctl_table fs_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "coda",
                .mode           = 0555,
                .child          = coda_table
index 085c5c0..70aa66c 100644 (file)
@@ -254,7 +254,7 @@ ctl_table epoll_table[] = {
                .proc_handler   = &proc_dointvec_minmax,
                .extra1         = &zero,
        },
-       { .ctl_name = 0 }
+       { }
 };
 #endif /* CONFIG_SYSCTL */
 
index 1a54ae1..307ed4c 100644 (file)
@@ -371,7 +371,6 @@ EXPORT_SYMBOL_GPL(lockd_down);
 
 static ctl_table nlm_sysctls[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nlm_grace_period",
                .data           = &nlm_grace_period,
                .maxlen         = sizeof(unsigned long),
@@ -381,7 +380,6 @@ static ctl_table nlm_sysctls[] = {
                .extra2         = (unsigned long *) &nlm_grace_period_max,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nlm_timeout",
                .data           = &nlm_timeout,
                .maxlen         = sizeof(unsigned long),
@@ -391,7 +389,6 @@ static ctl_table nlm_sysctls[] = {
                .extra2         = (unsigned long *) &nlm_timeout_max,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nlm_udpport",
                .data           = &nlm_udpport,
                .maxlen         = sizeof(int),
@@ -401,7 +398,6 @@ static ctl_table nlm_sysctls[] = {
                .extra2         = (int *) &nlm_port_max,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nlm_tcpport",
                .data           = &nlm_tcpport,
                .maxlen         = sizeof(int),
@@ -411,7 +407,6 @@ static ctl_table nlm_sysctls[] = {
                .extra2         = (int *) &nlm_port_max,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nsm_use_hostnames",
                .data           = &nsm_use_hostnames,
                .maxlen         = sizeof(int),
@@ -419,34 +414,31 @@ static ctl_table nlm_sysctls[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nsm_local_state",
                .data           = &nsm_local_state,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table nlm_sysctl_dir[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nfs",
                .mode           = 0555,
                .child          = nlm_sysctls,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table nlm_sysctl_root[] = {
        {
-               .ctl_name       = CTL_FS,
                .procname       = "fs",
                .mode           = 0555,
                .child          = nlm_sysctl_dir,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 #endif /* CONFIG_SYSCTL */
index b62481d..af51e6a 100644 (file)
@@ -22,7 +22,6 @@ static struct ctl_table_header *nfs_callback_sysctl_table;
 static ctl_table nfs_cb_sysctls[] = {
 #ifdef CONFIG_NFS_V4
        {
-               .ctl_name = CTL_UNNUMBERED,
                .procname = "nfs_callback_tcpport",
                .data = &nfs_callback_set_tcpport,
                .maxlen = sizeof(int),
@@ -32,53 +31,46 @@ static ctl_table nfs_cb_sysctls[] = {
                .extra2 = (int *)&nfs_set_port_max,
        },
        {
-               .ctl_name = CTL_UNNUMBERED,
                .procname = "idmap_cache_timeout",
                .data = &nfs_idmap_cache_timeout,
                .maxlen = sizeof(int),
                .mode = 0644,
                .proc_handler = &proc_dointvec_jiffies,
-               .strategy = &sysctl_jiffies,
        },
 #endif
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nfs_mountpoint_timeout",
                .data           = &nfs_mountpoint_expiry_timeout,
                .maxlen         = sizeof(nfs_mountpoint_expiry_timeout),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_jiffies,
-               .strategy       = &sysctl_jiffies,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nfs_congestion_kb",
                .data           = &nfs_congestion_kb,
                .maxlen         = sizeof(nfs_congestion_kb),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table nfs_cb_sysctl_dir[] = {
        {
-               .ctl_name = CTL_UNNUMBERED,
                .procname = "nfs",
                .mode = 0555,
                .child = nfs_cb_sysctls,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table nfs_cb_sysctl_root[] = {
        {
-               .ctl_name = CTL_FS,
                .procname = "fs",
                .mode = 0555,
                .child = nfs_cb_sysctl_dir,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 int nfs_register_sysctl(void)
index dcd2040..5275921 100644 (file)
@@ -69,36 +69,30 @@ static int zero;
 
 ctl_table inotify_table[] = {
        {
-               .ctl_name       = INOTIFY_MAX_USER_INSTANCES,
                .procname       = "max_user_instances",
                .data           = &inotify_max_user_instances,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
        {
-               .ctl_name       = INOTIFY_MAX_USER_WATCHES,
                .procname       = "max_user_watches",
                .data           = &inotify_max_user_watches,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
        {
-               .ctl_name       = INOTIFY_MAX_QUEUED_EVENTS,
                .procname       = "max_queued_events",
                .data           = &inotify_max_queued_events,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero
        },
-       { .ctl_name = 0 }
+       { }
 };
 #endif /* CONFIG_SYSCTL */
 
index 9ef85e6..99612ea 100644 (file)
@@ -36,7 +36,6 @@
 /* Definition of the ntfs sysctl. */
 static ctl_table ntfs_sysctls[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,       /* Binary and text IDs. */
                .procname       = "ntfs-debug",
                .data           = &debug_msgs,          /* Data pointer and size. */
                .maxlen         = sizeof(debug_msgs),
@@ -49,7 +48,6 @@ static ctl_table ntfs_sysctls[] = {
 /* Define the parent directory /proc/sys/fs. */
 static ctl_table sysctls_root[] = {
        {
-               .ctl_name       = CTL_FS,
                .procname       = "fs",
                .mode           = 0555,
                .child          = ntfs_sysctls
index 3f2f1c4..ed12c11 100644 (file)
@@ -620,51 +620,46 @@ error:
 
 static ctl_table ocfs2_nm_table[] = {
        {
-               .ctl_name       = 1,
                .procname       = "hb_ctl_path",
                .data           = ocfs2_hb_ctl_path,
                .maxlen         = OCFS2_MAX_HB_CTL_PATH,
                .mode           = 0644,
                .proc_handler   = &proc_dostring,
-               .strategy       = &sysctl_string,
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static ctl_table ocfs2_mod_table[] = {
        {
-               .ctl_name       = FS_OCFS2_NM,
                .procname       = "nm",
                .data           = NULL,
                .maxlen         = 0,
                .mode           = 0555,
                .child          = ocfs2_nm_table
        },
-       { .ctl_name = 0}
+       { }
 };
 
 static ctl_table ocfs2_kern_table[] = {
        {
-               .ctl_name       = FS_OCFS2,
                .procname       = "ocfs2",
                .data           = NULL,
                .maxlen         = 0,
                .mode           = 0555,
                .child          = ocfs2_mod_table
        },
-       { .ctl_name = 0}
+       { }
 };
 
 static ctl_table ocfs2_root_table[] = {
        {
-               .ctl_name       = CTL_FS,
                .procname       = "fs",
                .data           = NULL,
                .maxlen         = 0,
                .mode           = 0555,
                .child          = ocfs2_kern_table
        },
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table_header *ocfs2_table_header = NULL;
index f667e8a..6ff9981 100644 (file)
@@ -48,7 +48,7 @@ out:
 static struct ctl_table *find_in_table(struct ctl_table *p, struct qstr *name)
 {
        int len;
-       for ( ; p->ctl_name || p->procname; p++) {
+       for ( ; p->procname; p++) {
 
                if (!p->procname)
                        continue;
@@ -218,7 +218,7 @@ static int scan(struct ctl_table_header *head, ctl_table *table,
                void *dirent, filldir_t filldir)
 {
 
-       for (; table->ctl_name || table->procname; table++, (*pos)++) {
+       for (; table->procname; table++, (*pos)++) {
                int res;
 
                /* Can't do anything without a proc name */
index 39b49c4..60940f8 100644 (file)
@@ -2473,7 +2473,6 @@ const struct quotactl_ops vfs_quotactl_ops = {
 
 static ctl_table fs_dqstats_table[] = {
        {
-               .ctl_name       = FS_DQ_LOOKUPS,
                .procname       = "lookups",
                .data           = &dqstats.lookups,
                .maxlen         = sizeof(int),
@@ -2481,7 +2480,6 @@ static ctl_table fs_dqstats_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_DQ_DROPS,
                .procname       = "drops",
                .data           = &dqstats.drops,
                .maxlen         = sizeof(int),
@@ -2489,7 +2487,6 @@ static ctl_table fs_dqstats_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_DQ_READS,
                .procname       = "reads",
                .data           = &dqstats.reads,
                .maxlen         = sizeof(int),
@@ -2497,7 +2494,6 @@ static ctl_table fs_dqstats_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_DQ_WRITES,
                .procname       = "writes",
                .data           = &dqstats.writes,
                .maxlen         = sizeof(int),
@@ -2505,7 +2501,6 @@ static ctl_table fs_dqstats_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_DQ_CACHE_HITS,
                .procname       = "cache_hits",
                .data           = &dqstats.cache_hits,
                .maxlen         = sizeof(int),
@@ -2513,7 +2508,6 @@ static ctl_table fs_dqstats_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_DQ_ALLOCATED,
                .procname       = "allocated_dquots",
                .data           = &dqstats.allocated_dquots,
                .maxlen         = sizeof(int),
@@ -2521,7 +2515,6 @@ static ctl_table fs_dqstats_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_DQ_FREE,
                .procname       = "free_dquots",
                .data           = &dqstats.free_dquots,
                .maxlen         = sizeof(int),
@@ -2529,7 +2522,6 @@ static ctl_table fs_dqstats_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_DQ_SYNCS,
                .procname       = "syncs",
                .data           = &dqstats.syncs,
                .maxlen         = sizeof(int),
@@ -2538,7 +2530,6 @@ static ctl_table fs_dqstats_table[] = {
        },
 #ifdef CONFIG_PRINT_QUOTA_WARNING
        {
-               .ctl_name       = FS_DQ_WARNINGS,
                .procname       = "warnings",
                .data           = &flag_print_warnings,
                .maxlen         = sizeof(int),
@@ -2546,27 +2537,25 @@ static ctl_table fs_dqstats_table[] = {
                .proc_handler   = &proc_dointvec,
        },
 #endif
-       { .ctl_name = 0 },
+       { },
 };
 
 static ctl_table fs_table[] = {
        {
-               .ctl_name       = FS_DQSTATS,
                .procname       = "quota",
                .mode           = 0555,
                .child          = fs_dqstats_table,
        },
-       { .ctl_name = 0 },
+       { },
 };
 
 static ctl_table sys_table[] = {
        {
-               .ctl_name       = CTL_FS,
                .procname       = "fs",
                .mode           = 0555,
                .child          = fs_table,
        },
-       { .ctl_name = 0 },
+       { },
 };
 
 static int __init dquot_init(void)
index c5bc67c..6880147 100644 (file)
@@ -55,170 +55,140 @@ xfs_stats_clear_proc_handler(
 
 static ctl_table xfs_table[] = {
        {
-               .ctl_name       = XFS_SGID_INHERIT,
                .procname       = "irix_sgid_inherit",
                .data           = &xfs_params.sgid_inherit.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.sgid_inherit.min,
                .extra2         = &xfs_params.sgid_inherit.max
        },
        {
-               .ctl_name       = XFS_SYMLINK_MODE,
                .procname       = "irix_symlink_mode",
                .data           = &xfs_params.symlink_mode.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.symlink_mode.min,
                .extra2         = &xfs_params.symlink_mode.max
        },
        {
-               .ctl_name       = XFS_PANIC_MASK,
                .procname       = "panic_mask",
                .data           = &xfs_params.panic_mask.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.panic_mask.min,
                .extra2         = &xfs_params.panic_mask.max
        },
 
        {
-               .ctl_name       = XFS_ERRLEVEL,
                .procname       = "error_level",
                .data           = &xfs_params.error_level.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.error_level.min,
                .extra2         = &xfs_params.error_level.max
        },
        {
-               .ctl_name       = XFS_SYNCD_TIMER,
                .procname       = "xfssyncd_centisecs",
                .data           = &xfs_params.syncd_timer.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.syncd_timer.min,
                .extra2         = &xfs_params.syncd_timer.max
        },
        {
-               .ctl_name       = XFS_INHERIT_SYNC,
                .procname       = "inherit_sync",
                .data           = &xfs_params.inherit_sync.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.inherit_sync.min,
                .extra2         = &xfs_params.inherit_sync.max
        },
        {
-               .ctl_name       = XFS_INHERIT_NODUMP,
                .procname       = "inherit_nodump",
                .data           = &xfs_params.inherit_nodump.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.inherit_nodump.min,
                .extra2         = &xfs_params.inherit_nodump.max
        },
        {
-               .ctl_name       = XFS_INHERIT_NOATIME,
                .procname       = "inherit_noatime",
                .data           = &xfs_params.inherit_noatim.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.inherit_noatim.min,
                .extra2         = &xfs_params.inherit_noatim.max
        },
        {
-               .ctl_name       = XFS_BUF_TIMER,
                .procname       = "xfsbufd_centisecs",
                .data           = &xfs_params.xfs_buf_timer.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.xfs_buf_timer.min,
                .extra2         = &xfs_params.xfs_buf_timer.max
        },
        {
-               .ctl_name       = XFS_BUF_AGE,
                .procname       = "age_buffer_centisecs",
                .data           = &xfs_params.xfs_buf_age.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.xfs_buf_age.min,
                .extra2         = &xfs_params.xfs_buf_age.max
        },
        {
-               .ctl_name       = XFS_INHERIT_NOSYM,
                .procname       = "inherit_nosymlinks",
                .data           = &xfs_params.inherit_nosym.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.inherit_nosym.min,
                .extra2         = &xfs_params.inherit_nosym.max
        },
        {
-               .ctl_name       = XFS_ROTORSTEP,
                .procname       = "rotorstep",
                .data           = &xfs_params.rotorstep.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.rotorstep.min,
                .extra2         = &xfs_params.rotorstep.max
        },
        {
-               .ctl_name       = XFS_INHERIT_NODFRG,
                .procname       = "inherit_nodefrag",
                .data           = &xfs_params.inherit_nodfrg.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.inherit_nodfrg.min,
                .extra2         = &xfs_params.inherit_nodfrg.max
        },
        {
-               .ctl_name       = XFS_FILESTREAM_TIMER,
                .procname       = "filestream_centisecs",
                .data           = &xfs_params.fstrm_timer.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.fstrm_timer.min,
                .extra2         = &xfs_params.fstrm_timer.max,
        },
        /* please keep this the last entry */
 #ifdef CONFIG_PROC_FS
        {
-               .ctl_name       = XFS_STATS_CLEAR,
                .procname       = "stats_clear",
                .data           = &xfs_params.stats_clear.val,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &xfs_stats_clear_proc_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &xfs_params.stats_clear.min,
                .extra2         = &xfs_params.stats_clear.max
        },
@@ -229,7 +199,6 @@ static ctl_table xfs_table[] = {
 
 static ctl_table xfs_dir_table[] = {
        {
-               .ctl_name       = FS_XFS,
                .procname       = "xfs",
                .mode           = 0555,
                .child          = xfs_table
@@ -239,7 +208,6 @@ static ctl_table xfs_dir_table[] = {
 
 static ctl_table xfs_root_table[] = {
        {
-               .ctl_name       = CTL_FS,
                .procname       = "fs",
                .mode           = 0555,
                .child          = xfs_dir_table
index 1e4743e..4e40442 100644 (file)
@@ -996,10 +996,6 @@ extern int proc_doulongvec_minmax(struct ctl_table *, int,
 extern int proc_doulongvec_ms_jiffies_minmax(struct ctl_table *table, int,
                                      void __user *, size_t *, loff_t *);
 
-extern int do_sysctl (int __user *name, int nlen,
-                     void __user *oldval, size_t __user *oldlenp,
-                     void __user *newval, size_t newlen);
-
 extern ctl_handler sysctl_data;
 extern ctl_handler sysctl_string;
 extern ctl_handler sysctl_intvec;
@@ -1009,8 +1005,8 @@ extern ctl_handler sysctl_ms_jiffies;
 
 /*
  * Register a set of sysctl names by calling register_sysctl_table
- * with an initialised array of struct ctl_table's.  An entry with zero
- * ctl_name and NULL procname terminates the table.  table->de will be
+ * with an initialised array of struct ctl_table's.  An entry with 
+ * NULL procname terminates the table.  table->de will be
  * set up by the registration and need not be initialised in advance.
  *
  * sysctl names can be mirrored automatically under /proc/sys.  The
@@ -1023,24 +1019,11 @@ extern ctl_handler sysctl_ms_jiffies;
  * under /proc; non-leaf nodes will be represented by directories.  A
  * null procname disables /proc mirroring at this node.
  *
- * sysctl entries with a zero ctl_name will not be available through
- * the binary sysctl interface.
- *
  * sysctl(2) can automatically manage read and write requests through
  * the sysctl table.  The data and maxlen fields of the ctl_table
  * struct enable minimal validation of the values being written to be
  * performed, and the mode field allows minimal authentication.
  * 
- * More sophisticated management can be enabled by the provision of a
- * strategy routine with the table entry.  This will be called before
- * any automatic read or write of the data is performed.
- * 
- * The strategy routine may return:
- * <0: Error occurred (error is passed to user process)
- * 0:  OK - proceed with automatic read or write.
- * >0: OK - read or write has been done by the strategy routine, so 
- *     return immediately.
- * 
  * There must be a proc_handler routine for any terminal nodes
  * mirrored under /proc/sys (non-terminals are handled by a built-in
  * directory handler).  Several default handlers are available to
@@ -1050,7 +1033,6 @@ extern ctl_handler sysctl_ms_jiffies;
 /* A sysctl table is an array of struct ctl_table: */
 struct ctl_table 
 {
-       int ctl_name;                   /* Binary ID */
        const char *procname;           /* Text ID for /proc/sys, or zero */
        void *data;
        int maxlen;
@@ -1058,7 +1040,6 @@ struct ctl_table
        struct ctl_table *child;
        struct ctl_table *parent;       /* Automatically set */
        proc_handler *proc_handler;     /* Callback for text formatting */
-       ctl_handler *strategy;          /* Callback function for all r/w */
        void *extra1;
        void *extra2;
 };
@@ -1092,7 +1073,6 @@ struct ctl_table_header
 /* struct ctl_path describes where in the hierarchy a table is added */
 struct ctl_path {
        const char *procname;
-       int ctl_name;
 };
 
 void register_sysctl_root(struct ctl_table_root *root);
index cee4682..3f781a4 100644 (file)
@@ -75,7 +75,6 @@ struct dn_dev_parms {
        unsigned long t3;         /* Default value of t3                */
        int priority;             /* Priority to be a router            */
        char *name;               /* Name for sysctl                    */
-       int ctl_name;             /* Index for sysctl                   */
        int  (*up)(struct net_device *);
        void (*down)(struct net_device *);
        void (*timer3)(struct net_device *, struct dn_ifaddr *ifa);
index 3817fda..da99fdd 100644 (file)
@@ -264,8 +264,7 @@ extern int                  neigh_sysctl_register(struct net_device *dev,
                                                      struct neigh_parms *p,
                                                      int p_id, int pdev_id,
                                                      char *p_name,
-                                                     proc_handler *proc_handler,
-                                                     ctl_handler *strategy);
+                                                     proc_handler *proc_handler);
 extern void                    neigh_sysctl_unregister(struct neigh_parms *p);
 
 static inline void __neigh_parms_put(struct neigh_parms *parms)
index 9e03ef8..e50c63f 100644 (file)
@@ -754,6 +754,7 @@ config UID16
 
 config SYSCTL_SYSCALL
        bool "Sysctl syscall support" if EMBEDDED
+       depends on PROC_SYSCTL
        default y
        select SYSCTL
        ---help---
index 7d37047..56410fa 100644 (file)
@@ -129,136 +129,60 @@ static int proc_ipcauto_dointvec_minmax(ctl_table *table, int write,
 #define proc_ipcauto_dointvec_minmax NULL
 #endif
 
-#ifdef CONFIG_SYSCTL_SYSCALL
-/* The generic sysctl ipc data routine. */
-static int sysctl_ipc_data(ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-       size_t len;
-       void *data;
-
-       /* Get out of I don't have a variable */
-       if (!table->data || !table->maxlen)
-               return -ENOTDIR;
-
-       data = get_ipc(table);
-       if (!data)
-               return -ENOTDIR;
-
-       if (oldval && oldlenp) {
-               if (get_user(len, oldlenp))
-                       return -EFAULT;
-               if (len) {
-                       if (len > table->maxlen)
-                               len = table->maxlen;
-                       if (copy_to_user(oldval, data, len))
-                               return -EFAULT;
-                       if (put_user(len, oldlenp))
-                               return -EFAULT;
-               }
-       }
-
-       if (newval && newlen) {
-               if (newlen > table->maxlen)
-                       newlen = table->maxlen;
-
-               if (copy_from_user(data, newval, newlen))
-                       return -EFAULT;
-       }
-       return 1;
-}
-
-static int sysctl_ipc_registered_data(ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-       int rc;
-
-       rc = sysctl_ipc_data(table, oldval, oldlenp, newval, newlen);
-
-       if (newval && newlen && rc > 0)
-               /*
-                * Tunable has successfully been changed from userland
-                */
-               unregister_ipcns_notifier(current->nsproxy->ipc_ns);
-
-       return rc;
-}
-#else
-#define sysctl_ipc_data NULL
-#define sysctl_ipc_registered_data NULL
-#endif
-
 static int zero;
 static int one = 1;
 
 static struct ctl_table ipc_kern_table[] = {
        {
-               .ctl_name       = KERN_SHMMAX,
                .procname       = "shmmax",
                .data           = &init_ipc_ns.shm_ctlmax,
                .maxlen         = sizeof (init_ipc_ns.shm_ctlmax),
                .mode           = 0644,
                .proc_handler   = proc_ipc_doulongvec_minmax,
-               .strategy       = sysctl_ipc_data,
        },
        {
-               .ctl_name       = KERN_SHMALL,
                .procname       = "shmall",
                .data           = &init_ipc_ns.shm_ctlall,
                .maxlen         = sizeof (init_ipc_ns.shm_ctlall),
                .mode           = 0644,
                .proc_handler   = proc_ipc_doulongvec_minmax,
-               .strategy       = sysctl_ipc_data,
        },
        {
-               .ctl_name       = KERN_SHMMNI,
                .procname       = "shmmni",
                .data           = &init_ipc_ns.shm_ctlmni,
                .maxlen         = sizeof (init_ipc_ns.shm_ctlmni),
                .mode           = 0644,
                .proc_handler   = proc_ipc_dointvec,
-               .strategy       = sysctl_ipc_data,
        },
        {
-               .ctl_name       = KERN_MSGMAX,
                .procname       = "msgmax",
                .data           = &init_ipc_ns.msg_ctlmax,
                .maxlen         = sizeof (init_ipc_ns.msg_ctlmax),
                .mode           = 0644,
                .proc_handler   = proc_ipc_dointvec,
-               .strategy       = sysctl_ipc_data,
        },
        {
-               .ctl_name       = KERN_MSGMNI,
                .procname       = "msgmni",
                .data           = &init_ipc_ns.msg_ctlmni,
                .maxlen         = sizeof (init_ipc_ns.msg_ctlmni),
                .mode           = 0644,
                .proc_handler   = proc_ipc_callback_dointvec,
-               .strategy       = sysctl_ipc_registered_data,
        },
        {
-               .ctl_name       = KERN_MSGMNB,
                .procname       =  "msgmnb",
                .data           = &init_ipc_ns.msg_ctlmnb,
                .maxlen         = sizeof (init_ipc_ns.msg_ctlmnb),
                .mode           = 0644,
                .proc_handler   = proc_ipc_dointvec,
-               .strategy       = sysctl_ipc_data,
        },
        {
-               .ctl_name       = KERN_SEM,
                .procname       = "sem",
                .data           = &init_ipc_ns.sem_ctls,
                .maxlen         = 4*sizeof (int),
                .mode           = 0644,
                .proc_handler   = proc_ipc_dointvec,
-               .strategy       = sysctl_ipc_data,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "auto_msgmni",
                .data           = &init_ipc_ns.auto_msgmni,
                .maxlen         = sizeof(int),
@@ -272,7 +196,6 @@ static struct ctl_table ipc_kern_table[] = {
 
 static struct ctl_table ipc_root_table[] = {
        {
-               .ctl_name       = CTL_KERN,
                .procname       = "kernel",
                .mode           = 0555,
                .child          = ipc_kern_table,
index 8a05871..0c09366 100644 (file)
@@ -88,7 +88,7 @@ static ctl_table mq_sysctls[] = {
                .extra1         = &msg_maxsize_limit_min,
                .extra2         = &msg_maxsize_limit_max,
        },
-       { .ctl_name = 0 }
+       {}
 };
 
 static ctl_table mq_sysctl_dir[] = {
@@ -97,17 +97,16 @@ static ctl_table mq_sysctl_dir[] = {
                .mode           = 0555,
                .child          = mq_sysctls,
        },
-       { .ctl_name = 0 }
+       {}
 };
 
 static ctl_table mq_sysctl_root[] = {
        {
-               .ctl_name       = CTL_FS,
                .procname       = "fs",
                .mode           = 0555,
                .child          = mq_sysctl_dir,
        },
-       { .ctl_name = 0 }
+       {}
 };
 
 struct ctl_table_header *mq_register_sysctl_table(void)
index b8d4cd8..986a5c1 100644 (file)
@@ -4,7 +4,7 @@
 
 obj-y     = sched.o fork.o exec_domain.o panic.o printk.o \
            cpu.o exit.o itimer.o time.o softirq.o resource.o \
-           sysctl.o capability.o ptrace.o timer.o user.o \
+           sysctl.o sysctl_binary.o capability.o ptrace.o timer.o user.o \
            signal.o sys.o kmod.o workqueue.o pid.o \
            rcupdate.o extable.o params.o posix-timers.o \
            kthread.o wait.o kfifo.o sys_ni.o posix-cpu-timers.o mutex.o \
index 3c11ae0..b60ba74 100644 (file)
@@ -7406,17 +7406,16 @@ static struct ctl_table sd_ctl_dir[] = {
                .procname       = "sched_domain",
                .mode           = 0555,
        },
-       {0, },
+       {}
 };
 
 static struct ctl_table sd_ctl_root[] = {
        {
-               .ctl_name       = CTL_KERN,
                .procname       = "kernel",
                .mode           = 0555,
                .child          = sd_ctl_dir,
        },
-       {0, },
+       {}
 };
 
 static struct ctl_table *sd_alloc_ctl_entry(int n)
index 0d31135..0134b15 100644 (file)
@@ -52,7 +52,6 @@ static const int slow_work_max_vslow = 99;
 
 ctl_table slow_work_sysctls[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "min-threads",
                .data           = &slow_work_min_threads,
                .maxlen         = sizeof(unsigned),
@@ -62,7 +61,6 @@ ctl_table slow_work_sysctls[] = {
                .extra2         = &slow_work_max_threads,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "max-threads",
                .data           = &slow_work_max_threads,
                .maxlen         = sizeof(unsigned),
@@ -72,7 +70,6 @@ ctl_table slow_work_sysctls[] = {
                .extra2         = (void *) &slow_work_max_max_threads,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "vslow-percentage",
                .data           = &vslow_work_proportion,
                .maxlen         = sizeof(unsigned),
@@ -81,7 +78,7 @@ ctl_table slow_work_sysctls[] = {
                .extra1         = (void *) &slow_work_min_vslow,
                .extra2         = (void *) &slow_work_max_vslow,
        },
-       { .ctl_name = 0 }
+       {}
 };
 #endif
 
index e06d0b8..de5bf14 100644 (file)
@@ -139,7 +139,6 @@ cond_syscall(sys_pciconfig_read);
 cond_syscall(sys_pciconfig_write);
 cond_syscall(sys_pciconfig_iobase);
 cond_syscall(sys32_ipc);
-cond_syscall(sys32_sysctl);
 cond_syscall(ppc_rtas);
 cond_syscall(sys_spu_run);
 cond_syscall(sys_spu_create);
index 0d949c5..b4a5763 100644 (file)
@@ -27,7 +27,6 @@
 #include <linux/security.h>
 #include <linux/ctype.h>
 #include <linux/kmemcheck.h>
-#include <linux/smp_lock.h>
 #include <linux/fs.h>
 #include <linux/init.h>
 #include <linux/kernel.h>
@@ -60,7 +59,6 @@
 #include <asm/io.h>
 #endif
 
-static int deprecated_sysctl_warning(struct __sysctl_args *args);
 
 #if defined(CONFIG_SYSCTL)
 
@@ -207,31 +205,26 @@ extern int lock_stat;
 
 static struct ctl_table root_table[] = {
        {
-               .ctl_name       = CTL_KERN,
                .procname       = "kernel",
                .mode           = 0555,
                .child          = kern_table,
        },
        {
-               .ctl_name       = CTL_VM,
                .procname       = "vm",
                .mode           = 0555,
                .child          = vm_table,
        },
        {
-               .ctl_name       = CTL_FS,
                .procname       = "fs",
                .mode           = 0555,
                .child          = fs_table,
        },
        {
-               .ctl_name       = CTL_DEBUG,
                .procname       = "debug",
                .mode           = 0555,
                .child          = debug_table,
        },
        {
-               .ctl_name       = CTL_DEV,
                .procname       = "dev",
                .mode           = 0555,
                .child          = dev_table,
@@ -240,7 +233,7 @@ static struct ctl_table root_table[] = {
  * NOTE: do not add new entries to this table unless you have read
  * Documentation/sysctl/ctl_unnumbered.txt
  */
-       { .ctl_name = 0 }
+       { }
 };
 
 #ifdef CONFIG_SCHED_DEBUG
@@ -252,7 +245,6 @@ static int max_wakeup_granularity_ns = NSEC_PER_SEC;        /* 1 second */
 
 static struct ctl_table kern_table[] = {
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_child_runs_first",
                .data           = &sysctl_sched_child_runs_first,
                .maxlen         = sizeof(unsigned int),
@@ -261,40 +253,33 @@ static struct ctl_table kern_table[] = {
        },
 #ifdef CONFIG_SCHED_DEBUG
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_min_granularity_ns",
                .data           = &sysctl_sched_min_granularity,
                .maxlen         = sizeof(unsigned int),
                .mode           = 0644,
                .proc_handler   = &sched_nr_latency_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &min_sched_granularity_ns,
                .extra2         = &max_sched_granularity_ns,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_latency_ns",
                .data           = &sysctl_sched_latency,
                .maxlen         = sizeof(unsigned int),
                .mode           = 0644,
                .proc_handler   = &sched_nr_latency_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &min_sched_granularity_ns,
                .extra2         = &max_sched_granularity_ns,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_wakeup_granularity_ns",
                .data           = &sysctl_sched_wakeup_granularity,
                .maxlen         = sizeof(unsigned int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &min_wakeup_granularity_ns,
                .extra2         = &max_wakeup_granularity_ns,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_shares_ratelimit",
                .data           = &sysctl_sched_shares_ratelimit,
                .maxlen         = sizeof(unsigned int),
@@ -302,17 +287,14 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_shares_thresh",
                .data           = &sysctl_sched_shares_thresh,
                .maxlen         = sizeof(unsigned int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_features",
                .data           = &sysctl_sched_features,
                .maxlen         = sizeof(unsigned int),
@@ -320,7 +302,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_migration_cost",
                .data           = &sysctl_sched_migration_cost,
                .maxlen         = sizeof(unsigned int),
@@ -328,7 +309,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_nr_migrate",
                .data           = &sysctl_sched_nr_migrate,
                .maxlen         = sizeof(unsigned int),
@@ -336,7 +316,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_time_avg",
                .data           = &sysctl_sched_time_avg,
                .maxlen         = sizeof(unsigned int),
@@ -344,19 +323,16 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "timer_migration",
                .data           = &sysctl_timer_migration,
                .maxlen         = sizeof(unsigned int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one,
        },
 #endif
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_rt_period_us",
                .data           = &sysctl_sched_rt_period,
                .maxlen         = sizeof(unsigned int),
@@ -364,7 +340,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &sched_rt_handler,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_rt_runtime_us",
                .data           = &sysctl_sched_rt_runtime,
                .maxlen         = sizeof(int),
@@ -372,7 +347,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &sched_rt_handler,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "sched_compat_yield",
                .data           = &sysctl_sched_compat_yield,
                .maxlen         = sizeof(unsigned int),
@@ -381,7 +355,6 @@ static struct ctl_table kern_table[] = {
        },
 #ifdef CONFIG_PROVE_LOCKING
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "prove_locking",
                .data           = &prove_locking,
                .maxlen         = sizeof(int),
@@ -391,7 +364,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_LOCK_STAT
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "lock_stat",
                .data           = &lock_stat,
                .maxlen         = sizeof(int),
@@ -400,7 +372,6 @@ static struct ctl_table kern_table[] = {
        },
 #endif
        {
-               .ctl_name       = KERN_PANIC,
                .procname       = "panic",
                .data           = &panic_timeout,
                .maxlen         = sizeof(int),
@@ -408,7 +379,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = KERN_CORE_USES_PID,
                .procname       = "core_uses_pid",
                .data           = &core_uses_pid,
                .maxlen         = sizeof(int),
@@ -416,16 +386,13 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = KERN_CORE_PATTERN,
                .procname       = "core_pattern",
                .data           = core_pattern,
                .maxlen         = CORENAME_MAX_SIZE,
                .mode           = 0644,
                .proc_handler   = &proc_dostring,
-               .strategy       = &sysctl_string,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "core_pipe_limit",
                .data           = &core_pipe_limit,
                .maxlen         = sizeof(unsigned int),
@@ -451,7 +418,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_BLK_DEV_INITRD
        {
-               .ctl_name       = KERN_REALROOTDEV,
                .procname       = "real-root-dev",
                .data           = &real_root_dev,
                .maxlen         = sizeof(int),
@@ -460,7 +426,6 @@ static struct ctl_table kern_table[] = {
        },
 #endif
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "print-fatal-signals",
                .data           = &print_fatal_signals,
                .maxlen         = sizeof(int),
@@ -469,16 +434,13 @@ static struct ctl_table kern_table[] = {
        },
 #ifdef CONFIG_SPARC
        {
-               .ctl_name       = KERN_SPARC_REBOOT,
                .procname       = "reboot-cmd",
                .data           = reboot_command,
                .maxlen         = 256,
                .mode           = 0644,
                .proc_handler   = &proc_dostring,
-               .strategy       = &sysctl_string,
        },
        {
-               .ctl_name       = KERN_SPARC_STOP_A,
                .procname       = "stop-a",
                .data           = &stop_a_enabled,
                .maxlen         = sizeof (int),
@@ -486,7 +448,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = KERN_SPARC_SCONS_PWROFF,
                .procname       = "scons-poweroff",
                .data           = &scons_pwroff,
                .maxlen         = sizeof (int),
@@ -496,7 +457,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_SPARC64
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "tsb-ratio",
                .data           = &sysctl_tsb_ratio,
                .maxlen         = sizeof (int),
@@ -506,7 +466,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef __hppa__
        {
-               .ctl_name       = KERN_HPPA_PWRSW,
                .procname       = "soft-power",
                .data           = &pwrsw_enabled,
                .maxlen         = sizeof (int),
@@ -514,7 +473,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = KERN_HPPA_UNALIGNED,
                .procname       = "unaligned-trap",
                .data           = &unaligned_enabled,
                .maxlen         = sizeof (int),
@@ -523,7 +481,6 @@ static struct ctl_table kern_table[] = {
        },
 #endif
        {
-               .ctl_name       = KERN_CTLALTDEL,
                .procname       = "ctrl-alt-del",
                .data           = &C_A_D,
                .maxlen         = sizeof(int),
@@ -532,7 +489,6 @@ static struct ctl_table kern_table[] = {
        },
 #ifdef CONFIG_FUNCTION_TRACER
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "ftrace_enabled",
                .data           = &ftrace_enabled,
                .maxlen         = sizeof(int),
@@ -542,7 +498,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_STACK_TRACER
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "stack_tracer_enabled",
                .data           = &stack_tracer_enabled,
                .maxlen         = sizeof(int),
@@ -552,7 +507,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_TRACING
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "ftrace_dump_on_oops",
                .data           = &ftrace_dump_on_oops,
                .maxlen         = sizeof(int),
@@ -562,16 +516,13 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_MODULES
        {
-               .ctl_name       = KERN_MODPROBE,
                .procname       = "modprobe",
                .data           = &modprobe_path,
                .maxlen         = KMOD_PATH_LEN,
                .mode           = 0644,
                .proc_handler   = &proc_dostring,
-               .strategy       = &sysctl_string,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "modules_disabled",
                .data           = &modules_disabled,
                .maxlen         = sizeof(int),
@@ -584,18 +535,15 @@ static struct ctl_table kern_table[] = {
 #endif
 #if defined(CONFIG_HOTPLUG) && defined(CONFIG_NET)
        {
-               .ctl_name       = KERN_HOTPLUG,
                .procname       = "hotplug",
                .data           = &uevent_helper,
                .maxlen         = UEVENT_HELPER_PATH_LEN,
                .mode           = 0644,
                .proc_handler   = &proc_dostring,
-               .strategy       = &sysctl_string,
        },
 #endif
 #ifdef CONFIG_CHR_DEV_SG
        {
-               .ctl_name       = KERN_SG_BIG_BUFF,
                .procname       = "sg-big-buff",
                .data           = &sg_big_buff,
                .maxlen         = sizeof (int),
@@ -605,7 +553,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_BSD_PROCESS_ACCT
        {
-               .ctl_name       = KERN_ACCT,
                .procname       = "acct",
                .data           = &acct_parm,
                .maxlen         = 3*sizeof(int),
@@ -615,7 +562,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_MAGIC_SYSRQ
        {
-               .ctl_name       = KERN_SYSRQ,
                .procname       = "sysrq",
                .data           = &__sysrq_enabled,
                .maxlen         = sizeof (int),
@@ -633,7 +579,6 @@ static struct ctl_table kern_table[] = {
        },
 #endif
        {
-               .ctl_name       = KERN_MAX_THREADS,
                .procname       = "threads-max",
                .data           = &max_threads,
                .maxlen         = sizeof(int),
@@ -641,37 +586,31 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = KERN_RANDOM,
                .procname       = "random",
                .mode           = 0555,
                .child          = random_table,
        },
        {
-               .ctl_name       = KERN_OVERFLOWUID,
                .procname       = "overflowuid",
                .data           = &overflowuid,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &minolduid,
                .extra2         = &maxolduid,
        },
        {
-               .ctl_name       = KERN_OVERFLOWGID,
                .procname       = "overflowgid",
                .data           = &overflowgid,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &minolduid,
                .extra2         = &maxolduid,
        },
 #ifdef CONFIG_S390
 #ifdef CONFIG_MATHEMU
        {
-               .ctl_name       = KERN_IEEE_EMULATION_WARNINGS,
                .procname       = "ieee_emulation_warnings",
                .data           = &sysctl_ieee_emulation_warnings,
                .maxlen         = sizeof(int),
@@ -680,7 +619,6 @@ static struct ctl_table kern_table[] = {
        },
 #endif
        {
-               .ctl_name       = KERN_S390_USER_DEBUG_LOGGING,
                .procname       = "userprocess_debug",
                .data           = &sysctl_userprocess_debug,
                .maxlen         = sizeof(int),
@@ -689,18 +627,15 @@ static struct ctl_table kern_table[] = {
        },
 #endif
        {
-               .ctl_name       = KERN_PIDMAX,
                .procname       = "pid_max",
                .data           = &pid_max,
                .maxlen         = sizeof (int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = sysctl_intvec,
                .extra1         = &pid_max_min,
                .extra2         = &pid_max_max,
        },
        {
-               .ctl_name       = KERN_PANIC_ON_OOPS,
                .procname       = "panic_on_oops",
                .data           = &panic_on_oops,
                .maxlen         = sizeof(int),
@@ -709,7 +644,6 @@ static struct ctl_table kern_table[] = {
        },
 #if defined CONFIG_PRINTK
        {
-               .ctl_name       = KERN_PRINTK,
                .procname       = "printk",
                .data           = &console_loglevel,
                .maxlen         = 4*sizeof(int),
@@ -717,16 +651,13 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = KERN_PRINTK_RATELIMIT,
                .procname       = "printk_ratelimit",
                .data           = &printk_ratelimit_state.interval,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_jiffies,
-               .strategy       = &sysctl_jiffies,
        },
        {
-               .ctl_name       = KERN_PRINTK_RATELIMIT_BURST,
                .procname       = "printk_ratelimit_burst",
                .data           = &printk_ratelimit_state.burst,
                .maxlen         = sizeof(int),
@@ -734,19 +665,16 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "printk_delay",
                .data           = &printk_delay_msec,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &ten_thousand,
        },
 #endif
        {
-               .ctl_name       = KERN_NGROUPS_MAX,
                .procname       = "ngroups_max",
                .data           = &ngroups_max,
                .maxlen         = sizeof (int),
@@ -755,7 +683,6 @@ static struct ctl_table kern_table[] = {
        },
 #if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86)
        {
-               .ctl_name       = KERN_UNKNOWN_NMI_PANIC,
                .procname       = "unknown_nmi_panic",
                .data           = &unknown_nmi_panic,
                .maxlen         = sizeof (int),
@@ -772,7 +699,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #if defined(CONFIG_X86)
        {
-               .ctl_name       = KERN_PANIC_ON_NMI,
                .procname       = "panic_on_unrecovered_nmi",
                .data           = &panic_on_unrecovered_nmi,
                .maxlen         = sizeof(int),
@@ -780,7 +706,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "panic_on_io_nmi",
                .data           = &panic_on_io_nmi,
                .maxlen         = sizeof(int),
@@ -788,7 +713,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = KERN_BOOTLOADER_TYPE,
                .procname       = "bootloader_type",
                .data           = &bootloader_type,
                .maxlen         = sizeof (int),
@@ -796,7 +720,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "bootloader_version",
                .data           = &bootloader_version,
                .maxlen         = sizeof (int),
@@ -804,7 +727,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "kstack_depth_to_print",
                .data           = &kstack_depth_to_print,
                .maxlen         = sizeof(int),
@@ -812,7 +734,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "io_delay_type",
                .data           = &io_delay_type,
                .maxlen         = sizeof(int),
@@ -822,7 +743,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #if defined(CONFIG_MMU)
        {
-               .ctl_name       = KERN_RANDOMIZE,
                .procname       = "randomize_va_space",
                .data           = &randomize_va_space,
                .maxlen         = sizeof(int),
@@ -832,7 +752,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #if defined(CONFIG_S390) && defined(CONFIG_SMP)
        {
-               .ctl_name       = KERN_SPIN_RETRY,
                .procname       = "spin_retry",
                .data           = &spin_retry,
                .maxlen         = sizeof (int),
@@ -851,7 +770,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_IA64
        {
-               .ctl_name       = KERN_IA64_UNALIGNED,
                .procname       = "ignore-unaligned-usertrap",
                .data           = &no_unaligned_warning,
                .maxlen         = sizeof (int),
@@ -859,7 +777,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "unaligned-dump-stack",
                .data           = &unaligned_dump_stack,
                .maxlen         = sizeof (int),
@@ -869,71 +786,58 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_DETECT_SOFTLOCKUP
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "softlockup_panic",
                .data           = &softlockup_panic,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "softlockup_thresh",
                .data           = &softlockup_thresh,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dosoftlockup_thresh,
-               .strategy       = &sysctl_intvec,
                .extra1         = &neg_one,
                .extra2         = &sixty,
        },
 #endif
 #ifdef CONFIG_DETECT_HUNG_TASK
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "hung_task_panic",
                .data           = &sysctl_hung_task_panic,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "hung_task_check_count",
                .data           = &sysctl_hung_task_check_count,
                .maxlen         = sizeof(unsigned long),
                .mode           = 0644,
                .proc_handler   = &proc_doulongvec_minmax,
-               .strategy       = &sysctl_intvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "hung_task_timeout_secs",
                .data           = &sysctl_hung_task_timeout_secs,
                .maxlen         = sizeof(unsigned long),
                .mode           = 0644,
                .proc_handler   = &proc_dohung_task_timeout_secs,
-               .strategy       = &sysctl_intvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "hung_task_warnings",
                .data           = &sysctl_hung_task_warnings,
                .maxlen         = sizeof(unsigned long),
                .mode           = 0644,
                .proc_handler   = &proc_doulongvec_minmax,
-               .strategy       = &sysctl_intvec,
        },
 #endif
 #ifdef CONFIG_COMPAT
        {
-               .ctl_name       = KERN_COMPAT_LOG,
                .procname       = "compat-log",
                .data           = &compat_log,
                .maxlen         = sizeof (int),
@@ -943,7 +847,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_RT_MUTEXES
        {
-               .ctl_name       = KERN_MAX_LOCK_DEPTH,
                .procname       = "max_lock_depth",
                .data           = &max_lock_depth,
                .maxlen         = sizeof(int),
@@ -952,17 +855,14 @@ static struct ctl_table kern_table[] = {
        },
 #endif
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "poweroff_cmd",
                .data           = &poweroff_cmd,
                .maxlen         = POWEROFF_CMD_PATH_LEN,
                .mode           = 0644,
                .proc_handler   = &proc_dostring,
-               .strategy       = &sysctl_string,
        },
 #ifdef CONFIG_KEYS
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "keys",
                .mode           = 0555,
                .child          = key_sysctls,
@@ -970,7 +870,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_RCU_TORTURE_TEST
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "rcutorture_runnable",
                .data           = &rcutorture_runnable,
                .maxlen         = sizeof(int),
@@ -980,7 +879,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_SLOW_WORK
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "slow-work",
                .mode           = 0555,
                .child          = slow_work_sysctls,
@@ -988,7 +886,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_PERF_EVENTS
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "perf_event_paranoid",
                .data           = &sysctl_perf_event_paranoid,
                .maxlen         = sizeof(sysctl_perf_event_paranoid),
@@ -996,7 +893,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "perf_event_mlock_kb",
                .data           = &sysctl_perf_event_mlock,
                .maxlen         = sizeof(sysctl_perf_event_mlock),
@@ -1004,7 +900,6 @@ static struct ctl_table kern_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "perf_event_max_sample_rate",
                .data           = &sysctl_perf_event_sample_rate,
                .maxlen         = sizeof(sysctl_perf_event_sample_rate),
@@ -1014,7 +909,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_KMEMCHECK
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "kmemcheck",
                .data           = &kmemcheck_enabled,
                .maxlen         = sizeof(int),
@@ -1024,7 +918,6 @@ static struct ctl_table kern_table[] = {
 #endif
 #ifdef CONFIG_BLOCK
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "blk_iopoll",
                .data           = &blk_iopoll_enabled,
                .maxlen         = sizeof(int),
@@ -1036,12 +929,11 @@ static struct ctl_table kern_table[] = {
  * NOTE: do not add new entries to this table unless you have read
  * Documentation/sysctl/ctl_unnumbered.txt
  */
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table vm_table[] = {
        {
-               .ctl_name       = VM_OVERCOMMIT_MEMORY,
                .procname       = "overcommit_memory",
                .data           = &sysctl_overcommit_memory,
                .maxlen         = sizeof(sysctl_overcommit_memory),
@@ -1049,7 +941,6 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = VM_PANIC_ON_OOM,
                .procname       = "panic_on_oom",
                .data           = &sysctl_panic_on_oom,
                .maxlen         = sizeof(sysctl_panic_on_oom),
@@ -1057,7 +948,6 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "oom_kill_allocating_task",
                .data           = &sysctl_oom_kill_allocating_task,
                .maxlen         = sizeof(sysctl_oom_kill_allocating_task),
@@ -1065,7 +955,6 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "oom_dump_tasks",
                .data           = &sysctl_oom_dump_tasks,
                .maxlen         = sizeof(sysctl_oom_dump_tasks),
@@ -1073,7 +962,6 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = VM_OVERCOMMIT_RATIO,
                .procname       = "overcommit_ratio",
                .data           = &sysctl_overcommit_ratio,
                .maxlen         = sizeof(sysctl_overcommit_ratio),
@@ -1081,7 +969,6 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = VM_PAGE_CLUSTER,
                .procname       = "page-cluster", 
                .data           = &page_cluster,
                .maxlen         = sizeof(int),
@@ -1089,45 +976,37 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = VM_DIRTY_BACKGROUND,
                .procname       = "dirty_background_ratio",
                .data           = &dirty_background_ratio,
                .maxlen         = sizeof(dirty_background_ratio),
                .mode           = 0644,
                .proc_handler   = &dirty_background_ratio_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one_hundred,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "dirty_background_bytes",
                .data           = &dirty_background_bytes,
                .maxlen         = sizeof(dirty_background_bytes),
                .mode           = 0644,
                .proc_handler   = &dirty_background_bytes_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &one_ul,
        },
        {
-               .ctl_name       = VM_DIRTY_RATIO,
                .procname       = "dirty_ratio",
                .data           = &vm_dirty_ratio,
                .maxlen         = sizeof(vm_dirty_ratio),
                .mode           = 0644,
                .proc_handler   = &dirty_ratio_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one_hundred,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "dirty_bytes",
                .data           = &vm_dirty_bytes,
                .maxlen         = sizeof(vm_dirty_bytes),
                .mode           = 0644,
                .proc_handler   = &dirty_bytes_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &dirty_bytes_min,
        },
        {
@@ -1145,7 +1024,6 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = VM_NR_PDFLUSH_THREADS,
                .procname       = "nr_pdflush_threads",
                .data           = &nr_pdflush_threads,
                .maxlen         = sizeof nr_pdflush_threads,
@@ -1153,13 +1031,11 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = VM_SWAPPINESS,
                .procname       = "swappiness",
                .data           = &vm_swappiness,
                .maxlen         = sizeof(vm_swappiness),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one_hundred,
        },
@@ -1174,7 +1050,6 @@ static struct ctl_table vm_table[] = {
                .extra2         = (void *)&hugetlb_infinity,
         },
         {
-               .ctl_name       = VM_HUGETLB_GROUP,
                .procname       = "hugetlb_shm_group",
                .data           = &sysctl_hugetlb_shm_group,
                .maxlen         = sizeof(gid_t),
@@ -1182,7 +1057,6 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &proc_dointvec,
         },
         {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "hugepages_treat_as_movable",
                .data           = &hugepages_treat_as_movable,
                .maxlen         = sizeof(int),
@@ -1190,7 +1064,6 @@ static struct ctl_table vm_table[] = {
                .proc_handler   = &hugetlb_treat_movable_handler,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nr_overcommit_hugepages",
                .data           = NULL,
                .maxlen         = sizeof(unsigned long),
@@ -1201,46 +1074,37 @@ static struct ctl_table vm_table[] = {
        },
 #endif
        {
-               .ctl_name       = VM_LOWMEM_RESERVE_RATIO,
                .procname       = "lowmem_reserve_ratio",
                .data           = &sysctl_lowmem_reserve_ratio,
                .maxlen         = sizeof(sysctl_lowmem_reserve_ratio),
                .mode           = 0644,
                .proc_handler   = &lowmem_reserve_ratio_sysctl_handler,
-               .strategy       = &sysctl_intvec,
        },
        {
-               .ctl_name       = VM_DROP_PAGECACHE,
                .procname       = "drop_caches",
                .data           = &sysctl_drop_caches,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = drop_caches_sysctl_handler,
-               .strategy       = &sysctl_intvec,
        },
        {
-               .ctl_name       = VM_MIN_FREE_KBYTES,
                .procname       = "min_free_kbytes",
                .data           = &min_free_kbytes,
                .maxlen         = sizeof(min_free_kbytes),
                .mode           = 0644,
                .proc_handler   = &min_free_kbytes_sysctl_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
        {
-               .ctl_name       = VM_PERCPU_PAGELIST_FRACTION,
                .procname       = "percpu_pagelist_fraction",
                .data           = &percpu_pagelist_fraction,
                .maxlen         = sizeof(percpu_pagelist_fraction),
                .mode           = 0644,
                .proc_handler   = &percpu_pagelist_fraction_sysctl_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &min_percpu_pagelist_fract,
        },
 #ifdef CONFIG_MMU
        {
-               .ctl_name       = VM_MAX_MAP_COUNT,
                .procname       = "max_map_count",
                .data           = &sysctl_max_map_count,
                .maxlen         = sizeof(sysctl_max_map_count),
@@ -1249,104 +1113,85 @@ static struct ctl_table vm_table[] = {
        },
 #else
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nr_trim_pages",
                .data           = &sysctl_nr_trim_pages,
                .maxlen         = sizeof(sysctl_nr_trim_pages),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
 #endif
        {
-               .ctl_name       = VM_LAPTOP_MODE,
                .procname       = "laptop_mode",
                .data           = &laptop_mode,
                .maxlen         = sizeof(laptop_mode),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_jiffies,
-               .strategy       = &sysctl_jiffies,
        },
        {
-               .ctl_name       = VM_BLOCK_DUMP,
                .procname       = "block_dump",
                .data           = &block_dump,
                .maxlen         = sizeof(block_dump),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
        {
-               .ctl_name       = VM_VFS_CACHE_PRESSURE,
                .procname       = "vfs_cache_pressure",
                .data           = &sysctl_vfs_cache_pressure,
                .maxlen         = sizeof(sysctl_vfs_cache_pressure),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
 #ifdef HAVE_ARCH_PICK_MMAP_LAYOUT
        {
-               .ctl_name       = VM_LEGACY_VA_LAYOUT,
                .procname       = "legacy_va_layout",
                .data           = &sysctl_legacy_va_layout,
                .maxlen         = sizeof(sysctl_legacy_va_layout),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
 #endif
 #ifdef CONFIG_NUMA
        {
-               .ctl_name       = VM_ZONE_RECLAIM_MODE,
                .procname       = "zone_reclaim_mode",
                .data           = &zone_reclaim_mode,
                .maxlen         = sizeof(zone_reclaim_mode),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
        {
-               .ctl_name       = VM_MIN_UNMAPPED,
                .procname       = "min_unmapped_ratio",
                .data           = &sysctl_min_unmapped_ratio,
                .maxlen         = sizeof(sysctl_min_unmapped_ratio),
                .mode           = 0644,
                .proc_handler   = &sysctl_min_unmapped_ratio_sysctl_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one_hundred,
        },
        {
-               .ctl_name       = VM_MIN_SLAB,
                .procname       = "min_slab_ratio",
                .data           = &sysctl_min_slab_ratio,
                .maxlen         = sizeof(sysctl_min_slab_ratio),
                .mode           = 0644,
                .proc_handler   = &sysctl_min_slab_ratio_sysctl_handler,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one_hundred,
        },
 #endif
 #ifdef CONFIG_SMP
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "stat_interval",
                .data           = &sysctl_stat_interval,
                .maxlen         = sizeof(sysctl_stat_interval),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_jiffies,
-               .strategy       = &sysctl_jiffies,
        },
 #endif
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "mmap_min_addr",
                .data           = &dac_mmap_min_addr,
                .maxlen         = sizeof(unsigned long),
@@ -1355,43 +1200,36 @@ static struct ctl_table vm_table[] = {
        },
 #ifdef CONFIG_NUMA
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "numa_zonelist_order",
                .data           = &numa_zonelist_order,
                .maxlen         = NUMA_ZONELIST_ORDER_LEN,
                .mode           = 0644,
                .proc_handler   = &numa_zonelist_order_handler,
-               .strategy       = &sysctl_string,
        },
 #endif
 #if (defined(CONFIG_X86_32) && !defined(CONFIG_UML))|| \
    (defined(CONFIG_SUPERH) && defined(CONFIG_VSYSCALL))
        {
-               .ctl_name       = VM_VDSO_ENABLED,
                .procname       = "vdso_enabled",
                .data           = &vdso_enabled,
                .maxlen         = sizeof(vdso_enabled),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
        },
 #endif
 #ifdef CONFIG_HIGHMEM
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "highmem_is_dirtyable",
                .data           = &vm_highmem_is_dirtyable,
                .maxlen         = sizeof(vm_highmem_is_dirtyable),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one,
        },
 #endif
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "scan_unevictable_pages",
                .data           = &scan_unevictable_pages,
                .maxlen         = sizeof(scan_unevictable_pages),
@@ -1400,24 +1238,20 @@ static struct ctl_table vm_table[] = {
        },
 #ifdef CONFIG_MEMORY_FAILURE
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "memory_failure_early_kill",
                .data           = &sysctl_memory_failure_early_kill,
                .maxlen         = sizeof(sysctl_memory_failure_early_kill),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "memory_failure_recovery",
                .data           = &sysctl_memory_failure_recovery,
                .maxlen         = sizeof(sysctl_memory_failure_recovery),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &one,
        },
@@ -1427,18 +1261,17 @@ static struct ctl_table vm_table[] = {
  * NOTE: do not add new entries to this table unless you have read
  * Documentation/sysctl/ctl_unnumbered.txt
  */
-       { .ctl_name = 0 }
+       { }
 };
 
 #if defined(CONFIG_BINFMT_MISC) || defined(CONFIG_BINFMT_MISC_MODULE)
 static struct ctl_table binfmt_misc_table[] = {
-       { .ctl_name = 0 }
+       { }
 };
 #endif
 
 static struct ctl_table fs_table[] = {
        {
-               .ctl_name       = FS_NRINODE,
                .procname       = "inode-nr",
                .data           = &inodes_stat,
                .maxlen         = 2*sizeof(int),
@@ -1446,7 +1279,6 @@ static struct ctl_table fs_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_STATINODE,
                .procname       = "inode-state",
                .data           = &inodes_stat,
                .maxlen         = 7*sizeof(int),
@@ -1461,7 +1293,6 @@ static struct ctl_table fs_table[] = {
                .proc_handler   = &proc_nr_files,
        },
        {
-               .ctl_name       = FS_MAXFILE,
                .procname       = "file-max",
                .data           = &files_stat.max_files,
                .maxlen         = sizeof(int),
@@ -1469,7 +1300,6 @@ static struct ctl_table fs_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "nr_open",
                .data           = &sysctl_nr_open,
                .maxlen         = sizeof(int),
@@ -1479,7 +1309,6 @@ static struct ctl_table fs_table[] = {
                .extra2         = &sysctl_nr_open_max,
        },
        {
-               .ctl_name       = FS_DENTRY,
                .procname       = "dentry-state",
                .data           = &dentry_stat,
                .maxlen         = 6*sizeof(int),
@@ -1487,30 +1316,25 @@ static struct ctl_table fs_table[] = {
                .proc_handler   = &proc_dointvec,
        },
        {
-               .ctl_name       = FS_OVERFLOWUID,
                .procname       = "overflowuid",
                .data           = &fs_overflowuid,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &minolduid,
                .extra2         = &maxolduid,
        },
        {
-               .ctl_name       = FS_OVERFLOWGID,
                .procname       = "overflowgid",
                .data           = &fs_overflowgid,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &minolduid,
                .extra2         = &maxolduid,
        },
 #ifdef CONFIG_FILE_LOCKING
        {
-               .ctl_name       = FS_LEASES,
                .procname       = "leases-enable",
                .data           = &leases_enable,
                .maxlen         = sizeof(int),
@@ -1520,7 +1344,6 @@ static struct ctl_table fs_table[] = {
 #endif
 #ifdef CONFIG_DNOTIFY
        {
-               .ctl_name       = FS_DIR_NOTIFY,
                .procname       = "dir-notify-enable",
                .data           = &dir_notify_enable,
                .maxlen         = sizeof(int),
@@ -1531,7 +1354,6 @@ static struct ctl_table fs_table[] = {
 #ifdef CONFIG_MMU
 #ifdef CONFIG_FILE_LOCKING
        {
-               .ctl_name       = FS_LEASE_TIME,
                .procname       = "lease-break-time",
                .data           = &lease_break_time,
                .maxlen         = sizeof(int),
@@ -1557,7 +1379,6 @@ static struct ctl_table fs_table[] = {
 #endif /* CONFIG_AIO */
 #ifdef CONFIG_INOTIFY_USER
        {
-               .ctl_name       = FS_INOTIFY,
                .procname       = "inotify",
                .mode           = 0555,
                .child          = inotify_table,
@@ -1572,19 +1393,16 @@ static struct ctl_table fs_table[] = {
 #endif
 #endif
        {
-               .ctl_name       = KERN_SETUID_DUMPABLE,
                .procname       = "suid_dumpable",
                .data           = &suid_dumpable,
                .maxlen         = sizeof(int),
                .mode           = 0644,
                .proc_handler   = &proc_dointvec_minmax,
-               .strategy       = &sysctl_intvec,
                .extra1         = &zero,
                .extra2         = &two,
        },
 #if defined(CONFIG_BINFMT_MISC) || defined(CONFIG_BINFMT_MISC_MODULE)
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "binfmt_misc",
                .mode           = 0555,
                .child          = binfmt_misc_table,
@@ -1594,13 +1412,12 @@ static struct ctl_table fs_table[] = {
  * NOTE: do not add new entries to this table unless you have read
  * Documentation/sysctl/ctl_unnumbered.txt
  */
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table debug_table[] = {
 #if defined(CONFIG_X86) || defined(CONFIG_PPC)
        {
-               .ctl_name       = CTL_UNNUMBERED,
                .procname       = "exception-trace",
                .data           = &show_unhandled_signals,
                .maxlen         = sizeof(int),
@@ -1608,11 +1425,11 @@ static struct ctl_table debug_table[] = {
                .proc_handler   = proc_dointvec
        },
 #endif
-       { .ctl_name = 0 }
+       { }
 };
 
 static struct ctl_table dev_table[] = {
-       { .ctl_name = 0 }
+       { }
 };
 
 static DEFINE_SPINLOCK(sysctl_lock);
@@ -1766,122 +1583,6 @@ void register_sysctl_root(struct ctl_table_root *root)
        spin_unlock(&sysctl_lock);
 }
 
-#ifdef CONFIG_SYSCTL_SYSCALL
-/* Perform the actual read/write of a sysctl table entry. */
-static int do_sysctl_strategy(struct ctl_table_root *root,
-                       struct ctl_table *table,
-                       void __user *oldval, size_t __user *oldlenp,
-                       void __user *newval, size_t newlen)
-{
-       int op = 0, rc;
-
-       if (oldval)
-               op |= MAY_READ;
-       if (newval)
-               op |= MAY_WRITE;
-       if (sysctl_perm(root, table, op))
-               return -EPERM;
-
-       if (table->strategy) {
-               rc = table->strategy(table, oldval, oldlenp, newval, newlen);
-               if (rc < 0)
-                       return rc;
-               if (rc > 0)
-                       return 0;
-       }
-
-       /* If there is no strategy routine, or if the strategy returns
-        * zero, proceed with automatic r/w */
-       if (table->data && table->maxlen) {
-               rc = sysctl_data(table, oldval, oldlenp, newval, newlen);
-               if (rc < 0)
-                       return rc;
-       }
-       return 0;
-}
-
-static int parse_table(int __user *name, int nlen,
-                      void __user *oldval, size_t __user *oldlenp,
-                      void __user *newval, size_t newlen,
-                      struct ctl_table_root *root,
-                      struct ctl_table *table)
-{
-       int n;
-repeat:
-       if (!nlen)
-               return -ENOTDIR;
-       if (get_user(n, name))
-               return -EFAULT;
-       for ( ; table->ctl_name || table->procname; table++) {
-               if (!table->ctl_name)
-                       continue;
-               if (n == table->ctl_name) {
-                       int error;
-                       if (table->child) {
-                               if (sysctl_perm(root, table, MAY_EXEC))
-                                       return -EPERM;
-                               name++;
-                               nlen--;
-                               table = table->child;
-                               goto repeat;
-                       }
-                       error = do_sysctl_strategy(root, table,
-                                                  oldval, oldlenp,
-                                                  newval, newlen);
-                       return error;
-               }
-       }
-       return -ENOTDIR;
-}
-
-int do_sysctl(int __user *name, int nlen, void __user *oldval, size_t __user *oldlenp,
-              void __user *newval, size_t newlen)
-{
-       struct ctl_table_header *head;
-       int error = -ENOTDIR;
-
-       if (nlen <= 0 || nlen >= CTL_MAXNAME)
-               return -ENOTDIR;
-       if (oldval) {
-               int old_len;
-               if (!oldlenp || get_user(old_len, oldlenp))
-                       return -EFAULT;
-       }
-
-       for (head = sysctl_head_next(NULL); head;
-                       head = sysctl_head_next(head)) {
-               error = parse_table(name, nlen, oldval, oldlenp, 
-                                       newval, newlen,
-                                       head->root, head->ctl_table);
-               if (error != -ENOTDIR) {
-                       sysctl_head_finish(head);
-                       break;
-               }
-       }
-       return error;
-}
-
-SYSCALL_DEFINE1(sysctl, struct __sysctl_args __user *, args)
-{
-       struct __sysctl_args tmp;
-       int error;
-
-       if (copy_from_user(&tmp, args, sizeof(tmp)))
-               return -EFAULT;
-
-       error = deprecated_sysctl_warning(&tmp);
-       if (error)
-               goto out;
-
-       lock_kernel();
-       error = do_sysctl(tmp.name, tmp.nlen, tmp.oldval, tmp.oldlenp,
-                         tmp.newval, tmp.newlen);
-       unlock_kernel();
-out:
-       return error;
-}
-#endif /* CONFIG_SYSCTL_SYSCALL */
-
 /*
  * sysctl_perm does NOT grant the superuser all rights automatically, because
  * some sysctl variables are readonly even to root.
@@ -1917,7 +1618,7 @@ int sysctl_perm(struct ctl_table_root *root, struct ctl_table *table, int op)
 
 static void sysctl_set_parent(struct ctl_table *parent, struct ctl_table *table)
 {
-       for (; table->ctl_name || table->procname; table++) {
+       for (; table->procname; table++) {
                table->parent = parent;
                if (table->child)
                        sysctl_set_parent(table, table->child);
@@ -1949,11 +1650,11 @@ static struct ctl_table *is_branch_in(struct ctl_table *branch,
                return NULL;
 
        /* ... and nothing else */
-       if (branch[1].procname || branch[1].ctl_name)
+       if (branch[1].procname)
                return NULL;
 
        /* table should contain subdirectory with the same name */
-       for (p = table; p->procname || p->ctl_name; p++) {
+       for (p = table; p->procname; p++) {
                if (!p->child)
                        continue;
                if (p->procname && strcmp(p->procname, s) == 0)
@@ -1998,9 +1699,6 @@ static void try_attach(struct ctl_table_header *p, struct ctl_table_header *q)
  *
  * The members of the &struct ctl_table structure are used as follows:
  *
- * ctl_name - This is the numeric sysctl value used by sysctl(2). The number
- *            must be unique within that level of sysctl
- *
  * procname - the name of the sysctl file under /proc/sys. Set to %NULL to not
  *            enter a sysctl file
  *
@@ -2015,8 +1713,6 @@ static void try_attach(struct ctl_table_header *p, struct ctl_table_header *q)
  *
  * proc_handler - the text handler routine (described below)
  *
- * strategy - the strategy routine (described below)
- *
  * de - for internal use by the sysctl routines
  *
  * extra1, extra2 - extra pointers usable by the proc handler routines
@@ -2029,19 +1725,6 @@ static void try_attach(struct ctl_table_header *p, struct ctl_table_header *q)
  * struct enable minimal validation of the values being written to be
  * performed, and the mode field allows minimal authentication.
  *
- * More sophisticated management can be enabled by the provision of a
- * strategy routine with the table entry.  This will be called before
- * any automatic read or write of the data is performed.
- *
- * The strategy routine may return
- *
- * < 0 - Error occurred (error is passed to user process)
- *
- * 0   - OK - proceed with automatic read or write.
- *
- * > 0 - OK - read or write has been done by the strategy routine, so
- *       return immediately.
- *
  * There must be a proc_handler routine for any terminal nodes
  * mirrored under /proc/sys (non-terminals are handled by a built-in
  * directory handler).  Several default handlers are available to
@@ -2068,13 +1751,13 @@ struct ctl_table_header *__register_sysctl_paths(
        struct ctl_table_set *set;
 
        /* Count the path components */
-       for (npath = 0; path[npath].ctl_name || path[npath].procname; ++npath)
+       for (npath = 0; path[npath].procname; ++npath)
                ;
 
        /*
         * For each path component, allocate a 2-element ctl_table array.
         * The first array element will be filled with the sysctl entry
-        * for this, the second will be the sentinel (ctl_name == 0).
+        * for this, the second will be the sentinel (procname == 0).
         *
         * We allocate everything in one go so that we don't have to
         * worry about freeing additional memory in unregister_sysctl_table.
@@ -2091,7 +1774,6 @@ struct ctl_table_header *__register_sysctl_paths(
        for (n = 0; n < npath; ++n, ++path) {
                /* Copy the procname */
                new->procname = path->procname;
-               new->ctl_name = path->ctl_name;
                new->mode     = 0555;
 
                *prevp = new;
@@ -2953,286 +2635,6 @@ int proc_doulongvec_ms_jiffies_minmax(struct ctl_table *table, int write,
 
 #endif /* CONFIG_PROC_FS */
 
-
-#ifdef CONFIG_SYSCTL_SYSCALL
-/*
- * General sysctl support routines 
- */
-
-/* The generic sysctl data routine (used if no strategy routine supplied) */
-int sysctl_data(struct ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-       size_t len;
-
-       /* Get out of I don't have a variable */
-       if (!table->data || !table->maxlen)
-               return -ENOTDIR;
-
-       if (oldval && oldlenp) {
-               if (get_user(len, oldlenp))
-                       return -EFAULT;
-               if (len) {
-                       if (len > table->maxlen)
-                               len = table->maxlen;
-                       if (copy_to_user(oldval, table->data, len))
-                               return -EFAULT;
-                       if (put_user(len, oldlenp))
-                               return -EFAULT;
-               }
-       }
-
-       if (newval && newlen) {
-               if (newlen > table->maxlen)
-                       newlen = table->maxlen;
-
-               if (copy_from_user(table->data, newval, newlen))
-                       return -EFAULT;
-       }
-       return 1;
-}
-
-/* The generic string strategy routine: */
-int sysctl_string(struct ctl_table *table,
-                 void __user *oldval, size_t __user *oldlenp,
-                 void __user *newval, size_t newlen)
-{
-       if (!table->data || !table->maxlen) 
-               return -ENOTDIR;
-       
-       if (oldval && oldlenp) {
-               size_t bufsize;
-               if (get_user(bufsize, oldlenp))
-                       return -EFAULT;
-               if (bufsize) {
-                       size_t len = strlen(table->data), copied;
-
-                       /* This shouldn't trigger for a well-formed sysctl */
-                       if (len > table->maxlen)
-                               len = table->maxlen;
-
-                       /* Copy up to a max of bufsize-1 bytes of the string */
-                       copied = (len >= bufsize) ? bufsize - 1 : len;
-
-                       if (copy_to_user(oldval, table->data, copied) ||
-                           put_user(0, (char __user *)(oldval + copied)))
-                               return -EFAULT;
-                       if (put_user(len, oldlenp))
-                               return -EFAULT;
-               }
-       }
-       if (newval && newlen) {
-               size_t len = newlen;
-               if (len > table->maxlen)
-                       len = table->maxlen;
-               if(copy_from_user(table->data, newval, len))
-                       return -EFAULT;
-               if (len == table->maxlen)
-                       len--;
-               ((char *) table->data)[len] = 0;
-       }
-       return 1;
-}
-
-/*
- * This function makes sure that all of the integers in the vector
- * are between the minimum and maximum values given in the arrays
- * table->extra1 and table->extra2, respectively.
- */
-int sysctl_intvec(struct ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-
-       if (newval && newlen) {
-               int __user *vec = (int __user *) newval;
-               int *min = (int *) table->extra1;
-               int *max = (int *) table->extra2;
-               size_t length;
-               int i;
-
-               if (newlen % sizeof(int) != 0)
-                       return -EINVAL;
-
-               if (!table->extra1 && !table->extra2)
-                       return 0;
-
-               if (newlen > table->maxlen)
-                       newlen = table->maxlen;
-               length = newlen / sizeof(int);
-
-               for (i = 0; i < length; i++) {
-                       int value;
-                       if (get_user(value, vec + i))
-                               return -EFAULT;
-                       if (min && value < min[i])
-                               return -EINVAL;
-                       if (max && value > max[i])
-                               return -EINVAL;
-               }
-       }
-       return 0;
-}
-
-/* Strategy function to convert jiffies to seconds */ 
-int sysctl_jiffies(struct ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-       if (oldval && oldlenp) {
-               size_t olen;
-
-               if (get_user(olen, oldlenp))
-                       return -EFAULT;
-               if (olen) {
-                       int val;
-
-                       if (olen < sizeof(int))
-                               return -EINVAL;
-
-                       val = *(int *)(table->data) / HZ;
-                       if (put_user(val, (int __user *)oldval))
-                               return -EFAULT;
-                       if (put_user(sizeof(int), oldlenp))
-                               return -EFAULT;
-               }
-       }
-       if (newval && newlen) { 
-               int new;
-               if (newlen != sizeof(int))
-                       return -EINVAL; 
-               if (get_user(new, (int __user *)newval))
-                       return -EFAULT;
-               *(int *)(table->data) = new*HZ; 
-       }
-       return 1;
-}
-
-/* Strategy function to convert jiffies to seconds */ 
-int sysctl_ms_jiffies(struct ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-       if (oldval && oldlenp) {
-               size_t olen;
-
-               if (get_user(olen, oldlenp))
-                       return -EFAULT;
-               if (olen) {
-                       int val;
-
-                       if (olen < sizeof(int))
-                               return -EINVAL;
-
-                       val = jiffies_to_msecs(*(int *)(table->data));
-                       if (put_user(val, (int __user *)oldval))
-                               return -EFAULT;
-                       if (put_user(sizeof(int), oldlenp))
-                               return -EFAULT;
-               }
-       }
-       if (newval && newlen) { 
-               int new;
-               if (newlen != sizeof(int))
-                       return -EINVAL; 
-               if (get_user(new, (int __user *)newval))
-                       return -EFAULT;
-               *(int *)(table->data) = msecs_to_jiffies(new);
-       }
-       return 1;
-}
-
-
-
-#else /* CONFIG_SYSCTL_SYSCALL */
-
-
-SYSCALL_DEFINE1(sysctl, struct __sysctl_args __user *, args)
-{
-       struct __sysctl_args tmp;
-       int error;
-
-       if (copy_from_user(&tmp, args, sizeof(tmp)))
-               return -EFAULT;
-
-       error = deprecated_sysctl_warning(&tmp);
-
-       /* If no error reading the parameters then just -ENOSYS ... */
-       if (!error)
-               error = -ENOSYS;
-
-       return error;
-}
-
-int sysctl_data(struct ctl_table *table,
-                 void __user *oldval, size_t __user *oldlenp,
-                 void __user *newval, size_t newlen)
-{
-       return -ENOSYS;
-}
-
-int sysctl_string(struct ctl_table *table,
-                 void __user *oldval, size_t __user *oldlenp,
-                 void __user *newval, size_t newlen)
-{
-       return -ENOSYS;
-}
-
-int sysctl_intvec(struct ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-       return -ENOSYS;
-}
-
-int sysctl_jiffies(struct ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-       return -ENOSYS;
-}
-
-int sysctl_ms_jiffies(struct ctl_table *table,
-               void __user *oldval, size_t __user *oldlenp,
-               void __user *newval, size_t newlen)
-{
-       return -ENOSYS;
-}
-
-#endif /* CONFIG_SYSCTL_SYSCALL */
-
-static int deprecated_sysctl_warning(struct __sysctl_args *args)
-{
-       static int msg_count;
-       int name[CTL_MAXNAME];
-       int i;
-
-       /* Check args->nlen. */
-       if (args->nlen < 0 || args->nlen > CTL_MAXNAME)
-               return -ENOTDIR;
-
-       /* Read in the sysctl name for better debug message logging */
-       for (i = 0; i < args->nlen; i++)
-               if (get_user(name[i], args->name + i))
-                       return -EFAULT;
-
-       /* Ignore accesses to kernel.version */
-       if ((args->nlen == 2) && (name[0] == CTL_KERN) && (name[1] == KERN_VERSION))
-               return 0;
-
-       if (msg_count < 5) {
-               msg_count++;
-               printk(KERN_INFO
-                       "warning: process `%s' used the deprecated sysctl "
-                       "system call with ", current->comm);
-               for (i = 0; i < args->nlen; i++)
-                       printk("%d.", name[i]);
-               printk("\n");
-       }
-       return 0;
-}
-
 /*
  * No sense putting this after each symbol definition, twice,
  * exception granted :-)
@@ -3247,9 +2649,4 @@ EXPORT_SYMBOL(proc_doulongvec_minmax);
 EXPORT_SYMBOL(proc_doulongvec_ms_jiffies_minmax);
 EXPORT_SYMBOL(register_sysctl_table);
 EXPORT_SYMBOL(register_sysctl_paths);
-EXPORT_SYMBOL(sysctl_intvec);
-EXPORT_SYMBOL(sysctl_jiffies);
-EXPORT_SYMBOL(sysctl_ms_jiffies);
-EXPORT_SYMBOL(sysctl_string);
-EXPORT_SYMBOL(sysctl_data);
 EXPORT_SYMBOL(unregister_sysctl_table);
diff --git a/kernel/sysctl_binary.c b/kernel/sysctl_binary.c
new file mode 100644 (file)
index 0000000..b75dbf4
--- /dev/null
@@ -0,0 +1,1507 @@
+#include <linux/stat.h>
+#include <linux/sysctl.h>
+#include "../fs/xfs/linux-2.6/xfs_sysctl.h"
+#include <linux/sunrpc/debug.h>
+#include <linux/string.h>
+#include <net/ip_vs.h>
+#include <linux/syscalls.h>
+#include <linux/namei.h>
+#include <linux/mount.h>
+#include <linux/fs.h>
+#include <linux/nsproxy.h>
+#include <linux/pid_namespace.h>
+#include <linux/file.h>
+#include <linux/ctype.h>
+#include <linux/netdevice.h>
+
+#ifdef CONFIG_SYSCTL_SYSCALL
+
+struct bin_table;
+typedef ssize_t bin_convert_t(struct file *file,
+       void __user *oldval, size_t oldlen, void __user *newval, size_t newlen);
+
+static bin_convert_t bin_dir;
+static bin_convert_t bin_string;
+static bin_convert_t bin_intvec;
+static bin_convert_t bin_ulongvec;
+static bin_convert_t bin_uuid;
+static bin_convert_t bin_dn_node_address;
+
+#define CTL_DIR   bin_dir
+#define CTL_STR   bin_string
+#define CTL_INT   bin_intvec
+#define CTL_ULONG bin_ulongvec
+#define CTL_UUID  bin_uuid
+#define CTL_DNADR bin_dn_node_address
+
+#define BUFSZ 256
+
+struct bin_table {
+       bin_convert_t           *convert;
+       int                     ctl_name;
+       const char              *procname;
+       const struct bin_table  *child;
+};
+
+static const struct bin_table bin_random_table[] = {
+       { CTL_INT,      RANDOM_POOLSIZE,        "poolsize" },
+       { CTL_INT,      RANDOM_ENTROPY_COUNT,   "entropy_avail" },
+       { CTL_INT,      RANDOM_READ_THRESH,     "read_wakeup_threshold" },
+       { CTL_INT,      RANDOM_WRITE_THRESH,    "write_wakeup_threshold" },
+       { CTL_UUID,     RANDOM_BOOT_ID,         "boot_id" },
+       { CTL_UUID,     RANDOM_UUID,            "uuid" },
+       {}
+};
+
+static const struct bin_table bin_pty_table[] = {
+       { CTL_INT,      PTY_MAX,        "max" },
+       { CTL_INT,      PTY_NR,         "nr" },
+       {}
+};
+
+static const struct bin_table bin_kern_table[] = {
+       { CTL_STR,      KERN_OSTYPE,                    "ostype" },
+       { CTL_STR,      KERN_OSRELEASE,                 "osrelease" },
+       /* KERN_OSREV not used */
+       { CTL_STR,      KERN_VERSION,                   "version" },
+       /* KERN_SECUREMASK not used */
+       /* KERN_PROF not used */
+       { CTL_STR,      KERN_NODENAME,                  "hostname" },
+       { CTL_STR,      KERN_DOMAINNAME,                "domainname" },
+
+       { CTL_INT,      KERN_PANIC,                     "panic" },
+       { CTL_INT,      KERN_REALROOTDEV,               "real-root-dev" },
+
+       { CTL_STR,      KERN_SPARC_REBOOT,              "reboot-cmd" },
+       { CTL_INT,      KERN_CTLALTDEL,                 "ctrl-alt-del" },
+       { CTL_INT,      KERN_PRINTK,                    "printk" },
+
+       /* KERN_NAMETRANS not used */
+       /* KERN_PPC_HTABRECLAIM not used */
+       /* KERN_PPC_ZEROPAGED not used */
+       { CTL_INT,      KERN_PPC_POWERSAVE_NAP,         "powersave-nap" },
+
+       { CTL_STR,      KERN_MODPROBE,                  "modprobe" },
+       { CTL_INT,      KERN_SG_BIG_BUFF,               "sg-big-buff" },
+       { CTL_INT,      KERN_ACCT,                      "acct" },
+       /* KERN_PPC_L2CR "l2cr" no longer used */
+
+       /* KERN_RTSIGNR not used */
+       /* KERN_RTSIGMAX not used */
+
+       { CTL_ULONG,    KERN_SHMMAX,                    "shmmax" },
+       { CTL_INT,      KERN_MSGMAX,                    "msgmax" },
+       { CTL_INT,      KERN_MSGMNB,                    "msgmnb" },
+       /* KERN_MSGPOOL not used*/
+       { CTL_INT,      KERN_SYSRQ,                     "sysrq" },
+       { CTL_INT,      KERN_MAX_THREADS,               "threads-max" },
+       { CTL_DIR,      KERN_RANDOM,                    "random",       bin_random_table },
+       { CTL_ULONG,    KERN_SHMALL,                    "shmall" },
+       { CTL_INT,      KERN_MSGMNI,                    "msgmni" },
+       { CTL_INT,      KERN_SEM,                       "sem" },
+       { CTL_INT,      KERN_SPARC_STOP_A,              "stop-a" },
+       { CTL_INT,      KERN_SHMMNI,                    "shmmni" },
+
+       { CTL_INT,      KERN_OVERFLOWUID,               "overflowuid" },
+       { CTL_INT,      KERN_OVERFLOWGID,               "overflowgid" },
+
+       { CTL_STR,      KERN_HOTPLUG,                   "hotplug", },
+       { CTL_INT,      KERN_IEEE_EMULATION_WARNINGS,   "ieee_emulation_warnings" },
+
+       { CTL_INT,      KERN_S390_USER_DEBUG_LOGGING,   "userprocess_debug" },
+       { CTL_INT,      KERN_CORE_USES_PID,             "core_uses_pid" },
+       /* KERN_TAINTED "tainted" no longer used */
+       { CTL_INT,      KERN_CADPID,                    "cad_pid" },
+       { CTL_INT,      KERN_PIDMAX,                    "pid_max" },
+       { CTL_STR,      KERN_CORE_PATTERN,              "core_pattern" },
+       { CTL_INT,      KERN_PANIC_ON_OOPS,             "panic_on_oops" },
+       { CTL_INT,      KERN_HPPA_PWRSW,                "soft-power" },
+       { CTL_INT,      KERN_HPPA_UNALIGNED,            "unaligned-trap" },
+
+       { CTL_INT,      KERN_PRINTK_RATELIMIT,          "printk_ratelimit" },
+       { CTL_INT,      KERN_PRINTK_RATELIMIT_BURST,    "printk_ratelimit_burst" },
+
+       { CTL_DIR,      KERN_PTY,                       "pty",          bin_pty_table },
+       { CTL_INT,      KERN_NGROUPS_MAX,               "ngroups_max" },
+       { CTL_INT,      KERN_SPARC_SCONS_PWROFF,        "scons-poweroff" },
+       /* KERN_HZ_TIMER "hz_timer" no longer used */
+       { CTL_INT,      KERN_UNKNOWN_NMI_PANIC,         "unknown_nmi_panic" },
+       { CTL_INT,      KERN_BOOTLOADER_TYPE,           "bootloader_type" },
+       { CTL_INT,      KERN_RANDOMIZE,                 "randomize_va_space" },
+
+       { CTL_INT,      KERN_SPIN_RETRY,                "spin_retry" },
+       /* KERN_ACPI_VIDEO_FLAGS "acpi_video_flags" no longer used */
+       { CTL_INT,      KERN_IA64_UNALIGNED,            "ignore-unaligned-usertrap" },
+       { CTL_INT,      KERN_COMPAT_LOG,                "compat-log" },
+       { CTL_INT,      KERN_MAX_LOCK_DEPTH,            "max_lock_depth" },
+       { CTL_INT,      KERN_NMI_WATCHDOG,              "nmi_watchdog" },
+       { CTL_INT,      KERN_PANIC_ON_NMI,              "panic_on_unrecovered_nmi" },
+       {}
+};
+
+static const struct bin_table bin_vm_table[] = {
+       { CTL_INT,      VM_OVERCOMMIT_MEMORY,           "overcommit_memory" },
+       { CTL_INT,      VM_PAGE_CLUSTER,                "page-cluster" },
+       { CTL_INT,      VM_DIRTY_BACKGROUND,            "dirty_background_ratio" },
+       { CTL_INT,      VM_DIRTY_RATIO,                 "dirty_ratio" },
+       /* VM_DIRTY_WB_CS "dirty_writeback_centisecs" no longer used */
+       /* VM_DIRTY_EXPIRE_CS "dirty_expire_centisecs" no longer used */
+       { CTL_INT,      VM_NR_PDFLUSH_THREADS,          "nr_pdflush_threads" },
+       { CTL_INT,      VM_OVERCOMMIT_RATIO,            "overcommit_ratio" },
+       /* VM_PAGEBUF unused */
+       /* VM_HUGETLB_PAGES "nr_hugepages" no longer used */
+       { CTL_INT,      VM_SWAPPINESS,                  "swappiness" },
+       { CTL_INT,      VM_LOWMEM_RESERVE_RATIO,        "lowmem_reserve_ratio" },
+       { CTL_INT,      VM_MIN_FREE_KBYTES,             "min_free_kbytes" },
+       { CTL_INT,      VM_MAX_MAP_COUNT,               "max_map_count" },
+       { CTL_INT,      VM_LAPTOP_MODE,                 "laptop_mode" },
+       { CTL_INT,      VM_BLOCK_DUMP,                  "block_dump" },
+       { CTL_INT,      VM_HUGETLB_GROUP,               "hugetlb_shm_group" },
+       { CTL_INT,      VM_VFS_CACHE_PRESSURE,  "vfs_cache_pressure" },
+       { CTL_INT,      VM_LEGACY_VA_LAYOUT,            "legacy_va_layout" },
+       /* VM_SWAP_TOKEN_TIMEOUT unused */
+       { CTL_INT,      VM_DROP_PAGECACHE,              "drop_caches" },
+       { CTL_INT,      VM_PERCPU_PAGELIST_FRACTION,    "percpu_pagelist_fraction" },
+       { CTL_INT,      VM_ZONE_RECLAIM_MODE,           "zone_reclaim_mode" },
+       { CTL_INT,      VM_MIN_UNMAPPED,                "min_unmapped_ratio" },
+       { CTL_INT,      VM_PANIC_ON_OOM,                "panic_on_oom" },
+       { CTL_INT,      VM_VDSO_ENABLED,                "vdso_enabled" },
+       { CTL_INT,      VM_MIN_SLAB,                    "min_slab_ratio" },
+
+       {}
+};
+
+static const struct bin_table bin_net_core_table[] = {
+       { CTL_INT,      NET_CORE_WMEM_MAX,      "wmem_max" },
+       { CTL_INT,      NET_CORE_RMEM_MAX,      "rmem_max" },
+       { CTL_INT,      NET_CORE_WMEM_DEFAULT,  "wmem_default" },
+       { CTL_INT,      NET_CORE_RMEM_DEFAULT,  "rmem_default" },
+       /* NET_CORE_DESTROY_DELAY unused */
+       { CTL_INT,      NET_CORE_MAX_BACKLOG,   "netdev_max_backlog" },
+       /* NET_CORE_FASTROUTE unused */
+       { CTL_INT,      NET_CORE_MSG_COST,      "message_cost" },
+       { CTL_INT,      NET_CORE_MSG_BURST,     "message_burst" },
+       { CTL_INT,      NET_CORE_OPTMEM_MAX,    "optmem_max" },
+       /* NET_CORE_HOT_LIST_LENGTH unused */
+       /* NET_CORE_DIVERT_VERSION unused */
+       /* NET_CORE_NO_CONG_THRESH unused */
+       /* NET_CORE_NO_CONG unused */
+       /* NET_CORE_LO_CONG unused */
+       /* NET_CORE_MOD_CONG unused */
+       { CTL_INT,      NET_CORE_DEV_WEIGHT,    "dev_weight" },
+       { CTL_INT,      NET_CORE_SOMAXCONN,     "somaxconn" },
+       { CTL_INT,      NET_CORE_BUDGET,        "netdev_budget" },
+       { CTL_INT,      NET_CORE_AEVENT_ETIME,  "xfrm_aevent_etime" },
+       { CTL_INT,      NET_CORE_AEVENT_RSEQTH, "xfrm_aevent_rseqth" },
+       { CTL_INT,      NET_CORE_WARNINGS,      "warnings" },
+       {},
+};
+
+static const struct bin_table bin_net_unix_table[] = {
+       /* NET_UNIX_DESTROY_DELAY unused */
+       /* NET_UNIX_DELETE_DELAY unused */
+       { CTL_INT,      NET_UNIX_MAX_DGRAM_QLEN,        "max_dgram_qlen" },
+       {}
+};
+
+static const struct bin_table bin_net_ipv4_route_table[] = {
+       { CTL_INT,      NET_IPV4_ROUTE_FLUSH,                   "flush" },
+       /* NET_IPV4_ROUTE_MIN_DELAY "min_delay" no longer used */
+       /* NET_IPV4_ROUTE_MAX_DELAY "max_delay" no longer used */
+       { CTL_INT,      NET_IPV4_ROUTE_GC_THRESH,               "gc_thresh" },
+       { CTL_INT,      NET_IPV4_ROUTE_MAX_SIZE,                "max_size" },
+       { CTL_INT,      NET_IPV4_ROUTE_GC_MIN_INTERVAL,         "gc_min_interval" },
+       { CTL_INT,      NET_IPV4_ROUTE_GC_MIN_INTERVAL_MS,      "gc_min_interval_ms" },
+       { CTL_INT,      NET_IPV4_ROUTE_GC_TIMEOUT,              "gc_timeout" },
+       { CTL_INT,      NET_IPV4_ROUTE_GC_INTERVAL,             "gc_interval" },
+       { CTL_INT,      NET_IPV4_ROUTE_REDIRECT_LOAD,           "redirect_load" },
+       { CTL_INT,      NET_IPV4_ROUTE_REDIRECT_NUMBER,         "redirect_number" },
+       { CTL_INT,      NET_IPV4_ROUTE_REDIRECT_SILENCE,        "redirect_silence" },
+       { CTL_INT,      NET_IPV4_ROUTE_ERROR_COST,              "error_cost" },
+       { CTL_INT,      NET_IPV4_ROUTE_ERROR_BURST,             "error_burst" },
+       { CTL_INT,      NET_IPV4_ROUTE_GC_ELASTICITY,           "gc_elasticity" },
+       { CTL_INT,      NET_IPV4_ROUTE_MTU_EXPIRES,             "mtu_expires" },
+       { CTL_INT,      NET_IPV4_ROUTE_MIN_PMTU,                "min_pmtu" },
+       { CTL_INT,      NET_IPV4_ROUTE_MIN_ADVMSS,              "min_adv_mss" },
+       { CTL_INT,      NET_IPV4_ROUTE_SECRET_INTERVAL,         "secret_interval" },
+       {}
+};
+
+static const struct bin_table bin_net_ipv4_conf_vars_table[] = {
+       { CTL_INT,      NET_IPV4_CONF_FORWARDING,               "forwarding" },
+       { CTL_INT,      NET_IPV4_CONF_MC_FORWARDING,            "mc_forwarding" },
+
+       { CTL_INT,      NET_IPV4_CONF_ACCEPT_REDIRECTS,         "accept_redirects" },
+       { CTL_INT,      NET_IPV4_CONF_SECURE_REDIRECTS,         "secure_redirects" },
+       { CTL_INT,      NET_IPV4_CONF_SEND_REDIRECTS,           "send_redirects" },
+       { CTL_INT,      NET_IPV4_CONF_SHARED_MEDIA,             "shared_media" },
+       { CTL_INT,      NET_IPV4_CONF_RP_FILTER,                "rp_filter" },
+       { CTL_INT,      NET_IPV4_CONF_ACCEPT_SOURCE_ROUTE,      "accept_source_route" },
+       { CTL_INT,      NET_IPV4_CONF_PROXY_ARP,                "proxy_arp" },
+       { CTL_INT,      NET_IPV4_CONF_MEDIUM_ID,                "medium_id" },
+       { CTL_INT,      NET_IPV4_CONF_BOOTP_RELAY,              "bootp_relay" },
+       { CTL_INT,      NET_IPV4_CONF_LOG_MARTIANS,             "log_martians" },
+       { CTL_INT,      NET_IPV4_CONF_TAG,                      "tag" },
+       { CTL_INT,      NET_IPV4_CONF_ARPFILTER,                "arp_filter" },
+       { CTL_INT,      NET_IPV4_CONF_ARP_ANNOUNCE,             "arp_announce" },
+       { CTL_INT,      NET_IPV4_CONF_ARP_IGNORE,               "arp_ignore" },
+       { CTL_INT,      NET_IPV4_CONF_ARP_ACCEPT,               "arp_accept" },
+       { CTL_INT,      NET_IPV4_CONF_ARP_NOTIFY,               "arp_notify" },
+
+       { CTL_INT,      NET_IPV4_CONF_NOXFRM,                   "disable_xfrm" },
+       { CTL_INT,      NET_IPV4_CONF_NOPOLICY,                 "disable_policy" },
+       { CTL_INT,      NET_IPV4_CONF_FORCE_IGMP_VERSION,       "force_igmp_version" },
+       { CTL_INT,      NET_IPV4_CONF_PROMOTE_SECONDARIES,      "promote_secondaries" },
+       {}
+};
+
+static const struct bin_table bin_net_ipv4_conf_table[] = {
+       { CTL_DIR,      NET_PROTO_CONF_ALL,     "all",          bin_net_ipv4_conf_vars_table },
+       { CTL_DIR,      NET_PROTO_CONF_DEFAULT, "default",      bin_net_ipv4_conf_vars_table },
+       { CTL_DIR,      0, NULL, bin_net_ipv4_conf_vars_table },
+       {}
+};
+
+static const struct bin_table bin_net_neigh_vars_table[] = {
+       { CTL_INT,      NET_NEIGH_MCAST_SOLICIT,        "mcast_solicit" },
+       { CTL_INT,      NET_NEIGH_UCAST_SOLICIT,        "ucast_solicit" },
+       { CTL_INT,      NET_NEIGH_APP_SOLICIT,          "app_solicit" },
+       /* NET_NEIGH_RETRANS_TIME "retrans_time" no longer used */
+       { CTL_INT,      NET_NEIGH_REACHABLE_TIME,       "base_reachable_time" },
+       { CTL_INT,      NET_NEIGH_DELAY_PROBE_TIME,     "delay_first_probe_time" },
+       { CTL_INT,      NET_NEIGH_GC_STALE_TIME,        "gc_stale_time" },
+       { CTL_INT,      NET_NEIGH_UNRES_QLEN,           "unres_qlen" },
+       { CTL_INT,      NET_NEIGH_PROXY_QLEN,           "proxy_qlen" },
+       /* NET_NEIGH_ANYCAST_DELAY "anycast_delay" no longer used */
+       /* NET_NEIGH_PROXY_DELAY "proxy_delay" no longer used */
+       /* NET_NEIGH_LOCKTIME "locktime" no longer used */
+       { CTL_INT,      NET_NEIGH_GC_INTERVAL,          "gc_interval" },
+       { CTL_INT,      NET_NEIGH_GC_THRESH1,           "gc_thresh1" },
+       { CTL_INT,      NET_NEIGH_GC_THRESH2,           "gc_thresh2" },
+       { CTL_INT,      NET_NEIGH_GC_THRESH3,           "gc_thresh3" },
+       { CTL_INT,      NET_NEIGH_RETRANS_TIME_MS,      "retrans_time_ms" },
+       { CTL_INT,      NET_NEIGH_REACHABLE_TIME_MS,    "base_reachable_time_ms" },
+       {}
+};
+
+static const struct bin_table bin_net_neigh_table[] = {
+       { CTL_DIR,      NET_PROTO_CONF_DEFAULT, "default", bin_net_neigh_vars_table },
+       { CTL_DIR,      0, NULL, bin_net_neigh_vars_table },
+       {}
+};
+
+static const struct bin_table bin_net_ipv4_netfilter_table[] = {
+       { CTL_INT,      NET_IPV4_NF_CONNTRACK_MAX,              "ip_conntrack_max" },
+
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_SYN_SENT "ip_conntrack_tcp_timeout_syn_sent" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_SYN_RECV "ip_conntrack_tcp_timeout_syn_recv" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_ESTABLISHED "ip_conntrack_tcp_timeout_established" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_FIN_WAIT "ip_conntrack_tcp_timeout_fin_wait" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_CLOSE_WAIT "ip_conntrack_tcp_timeout_close_wait" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_LAST_ACK "ip_conntrack_tcp_timeout_last_ack" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_TIME_WAIT "ip_conntrack_tcp_timeout_time_wait" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_CLOSE "ip_conntrack_tcp_timeout_close" no longer used */
+
+       /* NET_IPV4_NF_CONNTRACK_UDP_TIMEOUT "ip_conntrack_udp_timeout" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_UDP_TIMEOUT_STREAM "ip_conntrack_udp_timeout_stream" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_ICMP_TIMEOUT "ip_conntrack_icmp_timeout" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_GENERIC_TIMEOUT "ip_conntrack_generic_timeout" no longer used */
+
+       { CTL_INT,      NET_IPV4_NF_CONNTRACK_BUCKETS,          "ip_conntrack_buckets" },
+       { CTL_INT,      NET_IPV4_NF_CONNTRACK_LOG_INVALID,      "ip_conntrack_log_invalid" },
+       /* NET_IPV4_NF_CONNTRACK_TCP_TIMEOUT_MAX_RETRANS "ip_conntrack_tcp_timeout_max_retrans" no longer used */
+       { CTL_INT,      NET_IPV4_NF_CONNTRACK_TCP_LOOSE,        "ip_conntrack_tcp_loose" },
+       { CTL_INT,      NET_IPV4_NF_CONNTRACK_TCP_BE_LIBERAL,   "ip_conntrack_tcp_be_liberal" },
+       { CTL_INT,      NET_IPV4_NF_CONNTRACK_TCP_MAX_RETRANS,  "ip_conntrack_tcp_max_retrans" },
+
+       /* NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_CLOSED "ip_conntrack_sctp_timeout_closed" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_COOKIE_WAIT "ip_conntrack_sctp_timeout_cookie_wait" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_COOKIE_ECHOED "ip_conntrack_sctp_timeout_cookie_echoed" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_ESTABLISHED "ip_conntrack_sctp_timeout_established" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_SHUTDOWN_SENT "ip_conntrack_sctp_timeout_shutdown_sent" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_SHUTDOWN_RECD "ip_conntrack_sctp_timeout_shutdown_recd" no longer used */
+       /* NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_SHUTDOWN_ACK_SENT "ip_conntrack_sctp_timeout_shutdown_ack_sent" no longer used */
+
+       { CTL_INT,      NET_IPV4_NF_CONNTRACK_COUNT,            "ip_conntrack_count" },
+       { CTL_INT,      NET_IPV4_NF_CONNTRACK_CHECKSUM,         "ip_conntrack_checksum" },
+       {}
+};
+
+static const struct bin_table bin_net_ipv4_table[] = {
+       {CTL_INT,       NET_IPV4_FORWARD,                       "ip_forward" },
+
+       { CTL_DIR,      NET_IPV4_CONF,          "conf",         bin_net_ipv4_conf_table },
+       { CTL_DIR,      NET_IPV4_NEIGH,         "neigh",        bin_net_neigh_table },
+       { CTL_DIR,      NET_IPV4_ROUTE,         "route",        bin_net_ipv4_route_table },
+       /* NET_IPV4_FIB_HASH unused */
+       { CTL_DIR,      NET_IPV4_NETFILTER,     "netfilter",    bin_net_ipv4_netfilter_table },
+
+       { CTL_INT,      NET_IPV4_TCP_TIMESTAMPS,                "tcp_timestamps" },
+       { CTL_INT,      NET_IPV4_TCP_WINDOW_SCALING,            "tcp_window_scaling" },
+       { CTL_INT,      NET_IPV4_TCP_SACK,                      "tcp_sack" },
+       { CTL_INT,      NET_IPV4_TCP_RETRANS_COLLAPSE,          "tcp_retrans_collapse" },
+       { CTL_INT,      NET_IPV4_DEFAULT_TTL,                   "ip_default_ttl" },
+       /* NET_IPV4_AUTOCONFIG unused */
+       { CTL_INT,      NET_IPV4_NO_PMTU_DISC,                  "ip_no_pmtu_disc" },
+       { CTL_INT,      NET_IPV4_NONLOCAL_BIND,                 "ip_nonlocal_bind" },
+       { CTL_INT,      NET_IPV4_TCP_SYN_RETRIES,               "tcp_syn_retries" },
+       { CTL_INT,      NET_TCP_SYNACK_RETRIES,                 "tcp_synack_retries" },
+       { CTL_INT,      NET_TCP_MAX_ORPHANS,                    "tcp_max_orphans" },
+       { CTL_INT,      NET_TCP_MAX_TW_BUCKETS,                 "tcp_max_tw_buckets" },
+       { CTL_INT,      NET_IPV4_DYNADDR,                       "ip_dynaddr" },
+       { CTL_INT,      NET_IPV4_TCP_KEEPALIVE_TIME,            "tcp_keepalive_time" },
+       { CTL_INT,      NET_IPV4_TCP_KEEPALIVE_PROBES,          "tcp_keepalive_probes" },
+       { CTL_INT,      NET_IPV4_TCP_KEEPALIVE_INTVL,           "tcp_keepalive_intvl" },
+       { CTL_INT,      NET_IPV4_TCP_RETRIES1,                  "tcp_retries1" },
+       { CTL_INT,      NET_IPV4_TCP_RETRIES2,                  "tcp_retries2" },
+       { CTL_INT,      NET_IPV4_TCP_FIN_TIMEOUT,               "tcp_fin_timeout" },
+       { CTL_INT,      NET_TCP_SYNCOOKIES,                     "tcp_syncookies" },
+       { CTL_INT,      NET_TCP_TW_RECYCLE,                     "tcp_tw_recycle" },
+       { CTL_INT,      NET_TCP_ABORT_ON_OVERFLOW,              "tcp_abort_on_overflow" },
+       { CTL_INT,      NET_TCP_STDURG,                         "tcp_stdurg" },
+       { CTL_INT,      NET_TCP_RFC1337,                        "tcp_rfc1337" },
+       { CTL_INT,      NET_TCP_MAX_SYN_BACKLOG,                "tcp_max_syn_backlog" },
+       { CTL_INT,      NET_IPV4_LOCAL_PORT_RANGE,              "ip_local_port_range" },
+       { CTL_INT,      NET_IPV4_IGMP_MAX_MEMBERSHIPS,          "igmp_max_memberships" },
+       { CTL_INT,      NET_IPV4_IGMP_MAX_MSF,                  "igmp_max_msf" },
+       { CTL_INT,      NET_IPV4_INET_PEER_THRESHOLD,           "inet_peer_threshold" },
+       { CTL_INT,      NET_IPV4_INET_PEER_MINTTL,              "inet_peer_minttl" },
+       { CTL_INT,      NET_IPV4_INET_PEER_MAXTTL,              "inet_peer_maxttl" },
+       { CTL_INT,      NET_IPV4_INET_PEER_GC_MINTIME,          "inet_peer_gc_mintime" },
+       { CTL_INT,      NET_IPV4_INET_PEER_GC_MAXTIME,          "inet_peer_gc_maxtime" },
+       { CTL_INT,      NET_TCP_ORPHAN_RETRIES,                 "tcp_orphan_retries" },
+       { CTL_INT,      NET_TCP_FACK,                           "tcp_fack" },
+       { CTL_INT,      NET_TCP_REORDERING,                     "tcp_reordering" },
+       { CTL_INT,      NET_TCP_ECN,                            "tcp_ecn" },
+       { CTL_INT,      NET_TCP_DSACK,                          "tcp_dsack" },
+       { CTL_INT,      NET_TCP_MEM,                            "tcp_mem" },
+       { CTL_INT,      NET_TCP_WMEM,                           "tcp_wmem" },
+       { CTL_INT,      NET_TCP_RMEM,                           "tcp_rmem" },
+       { CTL_INT,      NET_TCP_APP_WIN,                        "tcp_app_win" },
+       { CTL_INT,      NET_TCP_ADV_WIN_SCALE,                  "tcp_adv_win_scale" },
+       { CTL_INT,      NET_TCP_TW_REUSE,                       "tcp_tw_reuse" },
+       { CTL_INT,      NET_TCP_FRTO,                           "tcp_frto" },
+       { CTL_INT,      NET_TCP_FRTO_RESPONSE,                  "tcp_frto_response" },
+       { CTL_INT,      NET_TCP_LOW_LATENCY,                    "tcp_low_latency" },
+       { CTL_INT,      NET_TCP_NO_METRICS_SAVE,                "tcp_no_metrics_save" },
+       { CTL_INT,      NET_TCP_MODERATE_RCVBUF,                "tcp_moderate_rcvbuf" },
+       { CTL_INT,      NET_TCP_TSO_WIN_DIVISOR,                "tcp_tso_win_divisor" },
+       { CTL_STR,      NET_TCP_CONG_CONTROL,                   "tcp_congestion_control" },
+       { CTL_INT,      NET_TCP_ABC,                            "tcp_abc" },
+       { CTL_INT,      NET_TCP_MTU_PROBING,                    "tcp_mtu_probing" },
+       { CTL_INT,      NET_TCP_BASE_MSS,                       "tcp_base_mss" },
+       { CTL_INT,      NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS, "tcp_workaround_signed_windows" },
+       { CTL_INT,      NET_TCP_DMA_COPYBREAK,                  "tcp_dma_copybreak" },
+       { CTL_INT,      NET_TCP_SLOW_START_AFTER_IDLE,          "tcp_slow_start_after_idle" },
+       { CTL_INT,      NET_CIPSOV4_CACHE_ENABLE,               "cipso_cache_enable" },
+       { CTL_INT,      NET_CIPSOV4_CACHE_BUCKET_SIZE,          "cipso_cache_bucket_size" },
+       { CTL_INT,      NET_CIPSOV4_RBM_OPTFMT,                 "cipso_rbm_optfmt" },
+       { CTL_INT,      NET_CIPSOV4_RBM_STRICTVALID,            "cipso_rbm_strictvalid" },
+       /* NET_TCP_AVAIL_CONG_CONTROL "tcp_available_congestion_control" no longer used */
+       { CTL_STR,      NET_TCP_ALLOWED_CONG_CONTROL,           "tcp_allowed_congestion_control" },
+       { CTL_INT,      NET_TCP_MAX_SSTHRESH,                   "tcp_max_ssthresh" },
+
+       { CTL_INT,      NET_IPV4_ICMP_ECHO_IGNORE_ALL,          "icmp_echo_ignore_all" },
+       { CTL_INT,      NET_IPV4_ICMP_ECHO_IGNORE_BROADCASTS,   "icmp_echo_ignore_broadcasts" },
+       { CTL_INT,      NET_IPV4_ICMP_IGNORE_BOGUS_ERROR_RESPONSES,     "icmp_ignore_bogus_error_responses" },
+       { CTL_INT,      NET_IPV4_ICMP_ERRORS_USE_INBOUND_IFADDR,        "icmp_errors_use_inbound_ifaddr" },
+       { CTL_INT,      NET_IPV4_ICMP_RATELIMIT,                "icmp_ratelimit" },
+       { CTL_INT,      NET_IPV4_ICMP_RATEMASK,                 "icmp_ratemask" },
+
+       { CTL_INT,      NET_IPV4_IPFRAG_HIGH_THRESH,            "ipfrag_high_thresh" },
+       { CTL_INT,      NET_IPV4_IPFRAG_LOW_THRESH,             "ipfrag_low_thresh" },
+       { CTL_INT,      NET_IPV4_IPFRAG_TIME,                   "ipfrag_time" },
+
+       { CTL_INT,      NET_IPV4_IPFRAG_SECRET_INTERVAL,        "ipfrag_secret_interval" },
+       /* NET_IPV4_IPFRAG_MAX_DIST "ipfrag_max_dist" no longer used */
+
+       { CTL_INT,      2088 /* NET_IPQ_QMAX */,                "ip_queue_maxlen" },
+
+       /* NET_TCP_DEFAULT_WIN_SCALE unused */
+       /* NET_TCP_BIC_BETA unused */
+       /* NET_IPV4_TCP_MAX_KA_PROBES unused */
+       /* NET_IPV4_IP_MASQ_DEBUG unused */
+       /* NET_TCP_SYN_TAILDROP unused */
+       /* NET_IPV4_ICMP_SOURCEQUENCH_RATE unused */
+       /* NET_IPV4_ICMP_DESTUNREACH_RATE unused */
+       /* NET_IPV4_ICMP_TIMEEXCEED_RATE unused */
+       /* NET_IPV4_ICMP_PARAMPROB_RATE unused */
+       /* NET_IPV4_ICMP_ECHOREPLY_RATE unused */
+       /* NET_IPV4_ALWAYS_DEFRAG unused */
+       {}
+};
+
+static const struct bin_table bin_net_ipx_table[] = {
+       { CTL_INT,      NET_IPX_PPROP_BROADCASTING,     "ipx_pprop_broadcasting" },
+       /* NET_IPX_FORWARDING unused */
+       {}
+};
+
+static const struct bin_table bin_net_atalk_table[] = {
+       { CTL_INT,      NET_ATALK_AARP_EXPIRY_TIME,             "aarp-expiry-time" },
+       { CTL_INT,      NET_ATALK_AARP_TICK_TIME,               "aarp-tick-time" },
+       { CTL_INT,      NET_ATALK_AARP_RETRANSMIT_LIMIT,        "aarp-retransmit-limit" },
+       { CTL_INT,      NET_ATALK_AARP_RESOLVE_TIME,            "aarp-resolve-time" },
+       {},
+};
+
+static const struct bin_table bin_net_netrom_table[] = {
+       { CTL_INT,      NET_NETROM_DEFAULT_PATH_QUALITY,                "default_path_quality" },
+       { CTL_INT,      NET_NETROM_OBSOLESCENCE_COUNT_INITIALISER,      "obsolescence_count_initialiser" },
+       { CTL_INT,      NET_NETROM_NETWORK_TTL_INITIALISER,             "network_ttl_initialiser" },
+       { CTL_INT,      NET_NETROM_TRANSPORT_TIMEOUT,                   "transport_timeout" },
+       { CTL_INT,      NET_NETROM_TRANSPORT_MAXIMUM_TRIES,             "transport_maximum_tries" },
+       { CTL_INT,      NET_NETROM_TRANSPORT_ACKNOWLEDGE_DELAY,         "transport_acknowledge_delay" },
+       { CTL_INT,      NET_NETROM_TRANSPORT_BUSY_DELAY,                "transport_busy_delay" },
+       { CTL_INT,      NET_NETROM_TRANSPORT_REQUESTED_WINDOW_SIZE,     "transport_requested_window_size" },
+       { CTL_INT,      NET_NETROM_TRANSPORT_NO_ACTIVITY_TIMEOUT,       "transport_no_activity_timeout" },
+       { CTL_INT,      NET_NETROM_ROUTING_CONTROL,                     "routing_control" },
+       { CTL_INT,      NET_NETROM_LINK_FAILS_COUNT,                    "link_fails_count" },
+       { CTL_INT,      NET_NETROM_RESET,                               "reset" },
+       {}
+};
+
+static const struct bin_table bin_net_ax25_param_table[] = {
+       { CTL_INT,      NET_AX25_IP_DEFAULT_MODE,       "ip_default_mode" },
+       { CTL_INT,      NET_AX25_DEFAULT_MODE,          "ax25_default_mode" },
+       { CTL_INT,      NET_AX25_BACKOFF_TYPE,          "backoff_type" },
+       { CTL_INT,      NET_AX25_CONNECT_MODE,       &nbs