aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv6')
-rw-r--r--net/ipv6/tcp_ipv6.c12
-rw-r--r--net/ipv6/udp.c12
-rw-r--r--net/ipv6/udplite.c13
3 files changed, 28 insertions, 9 deletions
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c
index 10b2b3165a1a..36131d122a6f 100644
--- a/net/ipv6/tcp_ipv6.c
+++ b/net/ipv6/tcp_ipv6.c
@@ -2161,12 +2161,18 @@ out:
2161 return 0; 2161 return 0;
2162} 2162}
2163 2163
2164static const struct file_operations tcp6_afinfo_seq_fops = {
2165 .owner = THIS_MODULE,
2166 .open = tcp_seq_open,
2167 .read = seq_read,
2168 .llseek = seq_lseek,
2169 .release = seq_release_net
2170};
2171
2164static struct tcp_seq_afinfo tcp6_seq_afinfo = { 2172static struct tcp_seq_afinfo tcp6_seq_afinfo = {
2165 .name = "tcp6", 2173 .name = "tcp6",
2166 .family = AF_INET6, 2174 .family = AF_INET6,
2167 .seq_fops = { 2175 .seq_fops = &tcp6_afinfo_seq_fops,
2168 .owner = THIS_MODULE,
2169 },
2170 .seq_ops = { 2176 .seq_ops = {
2171 .show = tcp6_seq_show, 2177 .show = tcp6_seq_show,
2172 }, 2178 },
diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
index f4ca0a5b3457..846f4757eb8d 100644
--- a/net/ipv6/udp.c
+++ b/net/ipv6/udp.c
@@ -1424,13 +1424,19 @@ int udp6_seq_show(struct seq_file *seq, void *v)
1424 return 0; 1424 return 0;
1425} 1425}
1426 1426
1427static const struct file_operations udp6_afinfo_seq_fops = {
1428 .owner = THIS_MODULE,
1429 .open = udp_seq_open,
1430 .read = seq_read,
1431 .llseek = seq_lseek,
1432 .release = seq_release_net
1433};
1434
1427static struct udp_seq_afinfo udp6_seq_afinfo = { 1435static struct udp_seq_afinfo udp6_seq_afinfo = {
1428 .name = "udp6", 1436 .name = "udp6",
1429 .family = AF_INET6, 1437 .family = AF_INET6,
1430 .udp_table = &udp_table, 1438 .udp_table = &udp_table,
1431 .seq_fops = { 1439 .seq_fops = &udp6_afinfo_seq_fops,
1432 .owner = THIS_MODULE,
1433 },
1434 .seq_ops = { 1440 .seq_ops = {
1435 .show = udp6_seq_show, 1441 .show = udp6_seq_show,
1436 }, 1442 },
diff --git a/net/ipv6/udplite.c b/net/ipv6/udplite.c
index 986c4de5292e..8889aa22ed47 100644
--- a/net/ipv6/udplite.c
+++ b/net/ipv6/udplite.c
@@ -93,13 +93,20 @@ void udplitev6_exit(void)
93} 93}
94 94
95#ifdef CONFIG_PROC_FS 95#ifdef CONFIG_PROC_FS
96
97static const struct file_operations udplite6_afinfo_seq_fops = {
98 .owner = THIS_MODULE,
99 .open = udp_seq_open,
100 .read = seq_read,
101 .llseek = seq_lseek,
102 .release = seq_release_net
103};
104
96static struct udp_seq_afinfo udplite6_seq_afinfo = { 105static struct udp_seq_afinfo udplite6_seq_afinfo = {
97 .name = "udplite6", 106 .name = "udplite6",
98 .family = AF_INET6, 107 .family = AF_INET6,
99 .udp_table = &udplite_table, 108 .udp_table = &udplite_table,
100 .seq_fops = { 109 .seq_fops = &udplite6_afinfo_seq_fops,
101 .owner = THIS_MODULE,
102 },
103 .seq_ops = { 110 .seq_ops = {
104 .show = udp6_seq_show, 111 .show = udp6_seq_show,
105 }, 112 },