diff options
Diffstat (limited to 'net/ipv4/proc.c')
-rw-r--r-- | net/ipv4/proc.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/net/ipv4/proc.c b/net/ipv4/proc.c index cd873da54cbe..ae68a691e8cd 100644 --- a/net/ipv4/proc.c +++ b/net/ipv4/proc.c | |||
@@ -79,7 +79,7 @@ static int sockstat_seq_open(struct inode *inode, struct file *file) | |||
79 | return single_open(file, sockstat_seq_show, NULL); | 79 | return single_open(file, sockstat_seq_show, NULL); |
80 | } | 80 | } |
81 | 81 | ||
82 | static struct file_operations sockstat_seq_fops = { | 82 | static const struct file_operations sockstat_seq_fops = { |
83 | .owner = THIS_MODULE, | 83 | .owner = THIS_MODULE, |
84 | .open = sockstat_seq_open, | 84 | .open = sockstat_seq_open, |
85 | .read = seq_read, | 85 | .read = seq_read, |
@@ -266,7 +266,7 @@ static int snmp_seq_show(struct seq_file *seq, void *v) | |||
266 | 266 | ||
267 | for (i = 0; snmp4_ipstats_list[i].name != NULL; i++) | 267 | for (i = 0; snmp4_ipstats_list[i].name != NULL; i++) |
268 | seq_printf(seq, " %lu", | 268 | seq_printf(seq, " %lu", |
269 | fold_field((void **) ip_statistics, | 269 | fold_field((void **) ip_statistics, |
270 | snmp4_ipstats_list[i].entry)); | 270 | snmp4_ipstats_list[i].entry)); |
271 | 271 | ||
272 | seq_puts(seq, "\nIcmp:"); | 272 | seq_puts(seq, "\nIcmp:"); |
@@ -276,7 +276,7 @@ static int snmp_seq_show(struct seq_file *seq, void *v) | |||
276 | seq_puts(seq, "\nIcmp:"); | 276 | seq_puts(seq, "\nIcmp:"); |
277 | for (i = 0; snmp4_icmp_list[i].name != NULL; i++) | 277 | for (i = 0; snmp4_icmp_list[i].name != NULL; i++) |
278 | seq_printf(seq, " %lu", | 278 | seq_printf(seq, " %lu", |
279 | fold_field((void **) icmp_statistics, | 279 | fold_field((void **) icmp_statistics, |
280 | snmp4_icmp_list[i].entry)); | 280 | snmp4_icmp_list[i].entry)); |
281 | 281 | ||
282 | seq_puts(seq, "\nTcp:"); | 282 | seq_puts(seq, "\nTcp:"); |
@@ -288,7 +288,7 @@ static int snmp_seq_show(struct seq_file *seq, void *v) | |||
288 | /* MaxConn field is signed, RFC 2012 */ | 288 | /* MaxConn field is signed, RFC 2012 */ |
289 | if (snmp4_tcp_list[i].entry == TCP_MIB_MAXCONN) | 289 | if (snmp4_tcp_list[i].entry == TCP_MIB_MAXCONN) |
290 | seq_printf(seq, " %ld", | 290 | seq_printf(seq, " %ld", |
291 | fold_field((void **) tcp_statistics, | 291 | fold_field((void **) tcp_statistics, |
292 | snmp4_tcp_list[i].entry)); | 292 | snmp4_tcp_list[i].entry)); |
293 | else | 293 | else |
294 | seq_printf(seq, " %lu", | 294 | seq_printf(seq, " %lu", |
@@ -303,7 +303,7 @@ static int snmp_seq_show(struct seq_file *seq, void *v) | |||
303 | seq_puts(seq, "\nUdp:"); | 303 | seq_puts(seq, "\nUdp:"); |
304 | for (i = 0; snmp4_udp_list[i].name != NULL; i++) | 304 | for (i = 0; snmp4_udp_list[i].name != NULL; i++) |
305 | seq_printf(seq, " %lu", | 305 | seq_printf(seq, " %lu", |
306 | fold_field((void **) udp_statistics, | 306 | fold_field((void **) udp_statistics, |
307 | snmp4_udp_list[i].entry)); | 307 | snmp4_udp_list[i].entry)); |
308 | 308 | ||
309 | /* the UDP and UDP-Lite MIBs are the same */ | 309 | /* the UDP and UDP-Lite MIBs are the same */ |
@@ -326,7 +326,7 @@ static int snmp_seq_open(struct inode *inode, struct file *file) | |||
326 | return single_open(file, snmp_seq_show, NULL); | 326 | return single_open(file, snmp_seq_show, NULL); |
327 | } | 327 | } |
328 | 328 | ||
329 | static struct file_operations snmp_seq_fops = { | 329 | static const struct file_operations snmp_seq_fops = { |
330 | .owner = THIS_MODULE, | 330 | .owner = THIS_MODULE, |
331 | .open = snmp_seq_open, | 331 | .open = snmp_seq_open, |
332 | .read = seq_read, | 332 | .read = seq_read, |
@@ -348,7 +348,7 @@ static int netstat_seq_show(struct seq_file *seq, void *v) | |||
348 | seq_puts(seq, "\nTcpExt:"); | 348 | seq_puts(seq, "\nTcpExt:"); |
349 | for (i = 0; snmp4_net_list[i].name != NULL; i++) | 349 | for (i = 0; snmp4_net_list[i].name != NULL; i++) |
350 | seq_printf(seq, " %lu", | 350 | seq_printf(seq, " %lu", |
351 | fold_field((void **) net_statistics, | 351 | fold_field((void **) net_statistics, |
352 | snmp4_net_list[i].entry)); | 352 | snmp4_net_list[i].entry)); |
353 | 353 | ||
354 | seq_putc(seq, '\n'); | 354 | seq_putc(seq, '\n'); |
@@ -360,7 +360,7 @@ static int netstat_seq_open(struct inode *inode, struct file *file) | |||
360 | return single_open(file, netstat_seq_show, NULL); | 360 | return single_open(file, netstat_seq_show, NULL); |
361 | } | 361 | } |
362 | 362 | ||
363 | static struct file_operations netstat_seq_fops = { | 363 | static const struct file_operations netstat_seq_fops = { |
364 | .owner = THIS_MODULE, | 364 | .owner = THIS_MODULE, |
365 | .open = netstat_seq_open, | 365 | .open = netstat_seq_open, |
366 | .read = seq_read, | 366 | .read = seq_read, |