diff options
| author | Pavel Emelyanov <xemul@openvz.org> | 2008-01-09 03:30:05 -0500 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:01:07 -0500 |
| commit | b5ccd792fa413f9336273cb8fa3b9dd3a7ec1735 (patch) | |
| tree | 64b23972fdf667baa74a0895bf403b22eb7de86c /net/dccp | |
| parent | cb7928a528264a69b29b6001b490b64607ed0557 (diff) | |
[NET]: Simple ctl_table to ctl_path conversions.
This patch includes many places, that only required
replacing the ctl_table-s with appropriate ctl_paths
and call register_sysctl_paths().
Nothing special was done with them.
Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dccp')
| -rw-r--r-- | net/dccp/sysctl.c | 36 |
1 files changed, 7 insertions, 29 deletions
diff --git a/net/dccp/sysctl.c b/net/dccp/sysctl.c index c62c05039f69..21295993fdb8 100644 --- a/net/dccp/sysctl.c +++ b/net/dccp/sysctl.c | |||
| @@ -100,41 +100,19 @@ static struct ctl_table dccp_default_table[] = { | |||
| 100 | { .ctl_name = 0, } | 100 | { .ctl_name = 0, } |
| 101 | }; | 101 | }; |
| 102 | 102 | ||
| 103 | static struct ctl_table dccp_table[] = { | 103 | static struct ctl_path dccp_path[] = { |
| 104 | { | 104 | { .procname = "net", .ctl_name = CTL_NET, }, |
| 105 | .ctl_name = NET_DCCP_DEFAULT, | 105 | { .procname = "dccp", .ctl_name = NET_DCCP, }, |
| 106 | .procname = "default", | 106 | { .procname = "default", .ctl_name = NET_DCCP_DEFAULT, }, |
| 107 | .mode = 0555, | 107 | { } |
| 108 | .child = dccp_default_table, | ||
| 109 | }, | ||
| 110 | { .ctl_name = 0, }, | ||
| 111 | }; | ||
| 112 | |||
| 113 | static struct ctl_table dccp_dir_table[] = { | ||
| 114 | { | ||
| 115 | .ctl_name = NET_DCCP, | ||
| 116 | .procname = "dccp", | ||
| 117 | .mode = 0555, | ||
| 118 | .child = dccp_table, | ||
| 119 | }, | ||
| 120 | { .ctl_name = 0, }, | ||
| 121 | }; | ||
| 122 | |||
| 123 | static struct ctl_table dccp_root_table[] = { | ||
| 124 | { | ||
| 125 | .ctl_name = CTL_NET, | ||
| 126 | .procname = "net", | ||
| 127 | .mode = 0555, | ||
| 128 | .child = dccp_dir_table, | ||
| 129 | }, | ||
| 130 | { .ctl_name = 0, }, | ||
| 131 | }; | 108 | }; |
| 132 | 109 | ||
| 133 | static struct ctl_table_header *dccp_table_header; | 110 | static struct ctl_table_header *dccp_table_header; |
| 134 | 111 | ||
| 135 | int __init dccp_sysctl_init(void) | 112 | int __init dccp_sysctl_init(void) |
| 136 | { | 113 | { |
| 137 | dccp_table_header = register_sysctl_table(dccp_root_table); | 114 | dccp_table_header = register_sysctl_paths(dccp_path, |
| 115 | dccp_default_table); | ||
| 138 | 116 | ||
| 139 | return dccp_table_header != NULL ? 0 : -ENOMEM; | 117 | return dccp_table_header != NULL ? 0 : -ENOMEM; |
| 140 | } | 118 | } |
