diff options
| author | Joe Perches <joe@perches.com> | 2013-06-12 02:04:25 -0400 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2013-06-13 05:36:09 -0400 |
| commit | fe2c6338fd2c6f383c4d4164262f35c8f3708e1f (patch) | |
| tree | 491431ce95f0bda453b054748e3552fa6450c21c /net/ipv6 | |
| parent | 194f4a6df2a92c3d0bc65a85facfbc2433b25d06 (diff) | |
net: Convert uses of typedef ctl_table to struct ctl_table
Reduce the uses of this unnecessary typedef.
Done via perl script:
$ git grep --name-only -w ctl_table net | \
xargs perl -p -i -e '\
sub trim { my ($local) = @_; $local =~ s/(^\s+|\s+$)//g; return $local; } \
s/\b(?<!struct\s)ctl_table\b(\s*\*\s*|\s+\w+)/"struct ctl_table " . trim($1)/ge'
Reflow the modified lines that now exceed 80 columns.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6')
| -rw-r--r-- | net/ipv6/addrconf.c | 10 | ||||
| -rw-r--r-- | net/ipv6/icmp.c | 2 | ||||
| -rw-r--r-- | net/ipv6/route.c | 4 | ||||
| -rw-r--r-- | net/ipv6/sysctl_net_ipv6.c | 4 |
4 files changed, 10 insertions, 10 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index 21010fddb203..80449121afa2 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c | |||
| @@ -4620,13 +4620,13 @@ static void ipv6_ifa_notify(int event, struct inet6_ifaddr *ifp) | |||
| 4620 | #ifdef CONFIG_SYSCTL | 4620 | #ifdef CONFIG_SYSCTL |
| 4621 | 4621 | ||
| 4622 | static | 4622 | static |
| 4623 | int addrconf_sysctl_forward(ctl_table *ctl, int write, | 4623 | int addrconf_sysctl_forward(struct ctl_table *ctl, int write, |
| 4624 | void __user *buffer, size_t *lenp, loff_t *ppos) | 4624 | void __user *buffer, size_t *lenp, loff_t *ppos) |
| 4625 | { | 4625 | { |
| 4626 | int *valp = ctl->data; | 4626 | int *valp = ctl->data; |
| 4627 | int val = *valp; | 4627 | int val = *valp; |
| 4628 | loff_t pos = *ppos; | 4628 | loff_t pos = *ppos; |
| 4629 | ctl_table lctl; | 4629 | struct ctl_table lctl; |
| 4630 | int ret; | 4630 | int ret; |
| 4631 | 4631 | ||
| 4632 | /* | 4632 | /* |
| @@ -4705,13 +4705,13 @@ static int addrconf_disable_ipv6(struct ctl_table *table, int *p, int newf) | |||
| 4705 | } | 4705 | } |
| 4706 | 4706 | ||
| 4707 | static | 4707 | static |
| 4708 | int addrconf_sysctl_disable(ctl_table *ctl, int write, | 4708 | int addrconf_sysctl_disable(struct ctl_table *ctl, int write, |
| 4709 | void __user *buffer, size_t *lenp, loff_t *ppos) | 4709 | void __user *buffer, size_t *lenp, loff_t *ppos) |
| 4710 | { | 4710 | { |
| 4711 | int *valp = ctl->data; | 4711 | int *valp = ctl->data; |
| 4712 | int val = *valp; | 4712 | int val = *valp; |
| 4713 | loff_t pos = *ppos; | 4713 | loff_t pos = *ppos; |
| 4714 | ctl_table lctl; | 4714 | struct ctl_table lctl; |
| 4715 | int ret; | 4715 | int ret; |
| 4716 | 4716 | ||
| 4717 | /* | 4717 | /* |
| @@ -4733,7 +4733,7 @@ int addrconf_sysctl_disable(ctl_table *ctl, int write, | |||
| 4733 | static struct addrconf_sysctl_table | 4733 | static struct addrconf_sysctl_table |
| 4734 | { | 4734 | { |
| 4735 | struct ctl_table_header *sysctl_header; | 4735 | struct ctl_table_header *sysctl_header; |
| 4736 | ctl_table addrconf_vars[DEVCONF_MAX+1]; | 4736 | struct ctl_table addrconf_vars[DEVCONF_MAX+1]; |
| 4737 | } addrconf_sysctl __read_mostly = { | 4737 | } addrconf_sysctl __read_mostly = { |
| 4738 | .sysctl_header = NULL, | 4738 | .sysctl_header = NULL, |
| 4739 | .addrconf_vars = { | 4739 | .addrconf_vars = { |
diff --git a/net/ipv6/icmp.c b/net/ipv6/icmp.c index 4b4890bbe16d..7cfc8d284870 100644 --- a/net/ipv6/icmp.c +++ b/net/ipv6/icmp.c | |||
| @@ -976,7 +976,7 @@ int icmpv6_err_convert(u8 type, u8 code, int *err) | |||
| 976 | EXPORT_SYMBOL(icmpv6_err_convert); | 976 | EXPORT_SYMBOL(icmpv6_err_convert); |
| 977 | 977 | ||
| 978 | #ifdef CONFIG_SYSCTL | 978 | #ifdef CONFIG_SYSCTL |
| 979 | ctl_table ipv6_icmp_table_template[] = { | 979 | struct ctl_table ipv6_icmp_table_template[] = { |
| 980 | { | 980 | { |
| 981 | .procname = "ratelimit", | 981 | .procname = "ratelimit", |
| 982 | .data = &init_net.ipv6.sysctl.icmpv6_time, | 982 | .data = &init_net.ipv6.sysctl.icmpv6_time, |
diff --git a/net/ipv6/route.c b/net/ipv6/route.c index 2b874185ebb2..7ca87b37c0ef 100644 --- a/net/ipv6/route.c +++ b/net/ipv6/route.c | |||
| @@ -2790,7 +2790,7 @@ static const struct file_operations rt6_stats_seq_fops = { | |||
| 2790 | #ifdef CONFIG_SYSCTL | 2790 | #ifdef CONFIG_SYSCTL |
| 2791 | 2791 | ||
| 2792 | static | 2792 | static |
| 2793 | int ipv6_sysctl_rtcache_flush(ctl_table *ctl, int write, | 2793 | int ipv6_sysctl_rtcache_flush(struct ctl_table *ctl, int write, |
| 2794 | void __user *buffer, size_t *lenp, loff_t *ppos) | 2794 | void __user *buffer, size_t *lenp, loff_t *ppos) |
| 2795 | { | 2795 | { |
| 2796 | struct net *net; | 2796 | struct net *net; |
| @@ -2805,7 +2805,7 @@ int ipv6_sysctl_rtcache_flush(ctl_table *ctl, int write, | |||
| 2805 | return 0; | 2805 | return 0; |
| 2806 | } | 2806 | } |
| 2807 | 2807 | ||
| 2808 | ctl_table ipv6_route_table_template[] = { | 2808 | struct ctl_table ipv6_route_table_template[] = { |
| 2809 | { | 2809 | { |
| 2810 | .procname = "flush", | 2810 | .procname = "flush", |
| 2811 | .data = &init_net.ipv6.sysctl.flush_delay, | 2811 | .data = &init_net.ipv6.sysctl.flush_delay, |
diff --git a/net/ipv6/sysctl_net_ipv6.c b/net/ipv6/sysctl_net_ipv6.c index e85c48bd404f..107b2f1d90ae 100644 --- a/net/ipv6/sysctl_net_ipv6.c +++ b/net/ipv6/sysctl_net_ipv6.c | |||
| @@ -16,7 +16,7 @@ | |||
| 16 | #include <net/addrconf.h> | 16 | #include <net/addrconf.h> |
| 17 | #include <net/inet_frag.h> | 17 | #include <net/inet_frag.h> |
| 18 | 18 | ||
| 19 | static ctl_table ipv6_table_template[] = { | 19 | static struct ctl_table ipv6_table_template[] = { |
| 20 | { | 20 | { |
| 21 | .procname = "bindv6only", | 21 | .procname = "bindv6only", |
| 22 | .data = &init_net.ipv6.sysctl.bindv6only, | 22 | .data = &init_net.ipv6.sysctl.bindv6only, |
| @@ -27,7 +27,7 @@ static ctl_table ipv6_table_template[] = { | |||
| 27 | { } | 27 | { } |
| 28 | }; | 28 | }; |
| 29 | 29 | ||
| 30 | static ctl_table ipv6_rotable[] = { | 30 | static struct ctl_table ipv6_rotable[] = { |
| 31 | { | 31 | { |
| 32 | .procname = "mld_max_msf", | 32 | .procname = "mld_max_msf", |
| 33 | .data = &sysctl_mld_max_msf, | 33 | .data = &sysctl_mld_max_msf, |
