Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=1d430b913c2e6293a80a4a422406bc9489a476ad
Commit:     1d430b913c2e6293a80a4a422406bc9489a476ad
Parent:     d392e49756a99ba51577d265d6db83e3f01c6ac8
Author:     Pavel Emelyanov <[EMAIL PROTECTED]>
AuthorDate: Sat Dec 1 23:45:41 2007 +1100
Committer:  David S. Miller <[EMAIL PROTECTED]>
CommitDate: Mon Jan 28 14:55:22 2008 -0800

    [UNIX]: Use ctl paths to register unix ctl tables
    
    Unlike previous ones, this patch is useful by its own,
    as it decreases the vmlinux size :)
    
    But it will be used later, when the per-namespace sysctl
    is added.
    
    Signed-off-by: Pavel Emelyanov <[EMAIL PROTECTED]>
    Acked-by: Eric W. Biederman <[EMAIL PROTECTED]>
    Signed-off-by: Herbert Xu <[EMAIL PROTECTED]>
    Signed-off-by: David S. Miller <[EMAIL PROTECTED]>
---
 net/unix/sysctl_net_unix.c |   24 +++++-------------------
 1 files changed, 5 insertions(+), 19 deletions(-)

diff --git a/net/unix/sysctl_net_unix.c b/net/unix/sysctl_net_unix.c
index c46cec0..43dd356 100644
--- a/net/unix/sysctl_net_unix.c
+++ b/net/unix/sysctl_net_unix.c
@@ -26,31 +26,17 @@ static ctl_table unix_table[] = {
        { .ctl_name = 0 }
 };
 
-static ctl_table unix_net_table[] = {
-       {
-               .ctl_name       = NET_UNIX,
-               .procname       = "unix",
-               .mode           = 0555,
-               .child          = unix_table
-       },
-       { .ctl_name = 0 }
-};
-
-static ctl_table unix_root_table[] = {
-       {
-               .ctl_name       = CTL_NET,
-               .procname       = "net",
-               .mode           = 0555,
-               .child          = unix_net_table
-       },
-       { .ctl_name = 0 }
+static struct ctl_path unix_path[] = {
+       { .procname = "net", .ctl_name = CTL_NET, },
+       { .procname = "unix", .ctl_name = NET_UNIX, },
+       { },
 };
 
 static struct ctl_table_header * unix_sysctl_header;
 
 int unix_sysctl_register(struct net *net)
 {
-       unix_sysctl_header = register_sysctl_table(unix_root_table);
+       unix_sysctl_header = register_sysctl_paths(unix_path, unix_table);
        return unix_sysctl_header == NULL ? -ENOMEM : 0;
 }
 
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to