aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4
diff options
context:
space:
mode:
authorBrian Haley <brian.haley@hp.com>2008-06-14 20:04:49 -0400
committerDavid S. Miller <davem@davemloft.net>2008-06-14 20:04:49 -0400
commit7d06b2e053d2d536348e3a0f6bb02982a41bea37 (patch)
treeec6a5c3f448e84cd431a0397b9e2a87ca25aec17 /net/ipv4
parent4ae127d1b6c71f9240dd4245f240e6dd8fc98014 (diff)
net: change proto destroy method to return void
Change struct proto destroy function pointer to return void. Noticed by Al Viro. Signed-off-by: Brian Haley <brian.haley@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r--net/ipv4/raw.c3
-rw-r--r--net/ipv4/tcp_ipv4.c4
-rw-r--r--net/ipv4/udp.c3
-rw-r--r--net/ipv4/udp_impl.h2
4 files changed, 4 insertions, 8 deletions
diff --git a/net/ipv4/raw.c b/net/ipv4/raw.c
index 1d0c97c8712d..36035a0c6dc2 100644
--- a/net/ipv4/raw.c
+++ b/net/ipv4/raw.c
@@ -606,12 +606,11 @@ static void raw_close(struct sock *sk, long timeout)
606 sk_common_release(sk); 606 sk_common_release(sk);
607} 607}
608 608
609static int raw_destroy(struct sock *sk) 609static void raw_destroy(struct sock *sk)
610{ 610{
611 lock_sock(sk); 611 lock_sock(sk);
612 ip_flush_pending_frames(sk); 612 ip_flush_pending_frames(sk);
613 release_sock(sk); 613 release_sock(sk);
614 return 0;
615} 614}
616 615
617/* This gets rid of all the nasties in af_inet. -DaveM */ 616/* This gets rid of all the nasties in af_inet. -DaveM */
diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c
index b219a7a7cd08..64b385f65930 100644
--- a/net/ipv4/tcp_ipv4.c
+++ b/net/ipv4/tcp_ipv4.c
@@ -1775,7 +1775,7 @@ static int tcp_v4_init_sock(struct sock *sk)
1775 return 0; 1775 return 0;
1776} 1776}
1777 1777
1778int tcp_v4_destroy_sock(struct sock *sk) 1778void tcp_v4_destroy_sock(struct sock *sk)
1779{ 1779{
1780 struct tcp_sock *tp = tcp_sk(sk); 1780 struct tcp_sock *tp = tcp_sk(sk);
1781 1781
@@ -1819,8 +1819,6 @@ int tcp_v4_destroy_sock(struct sock *sk)
1819 } 1819 }
1820 1820
1821 atomic_dec(&tcp_sockets_allocated); 1821 atomic_dec(&tcp_sockets_allocated);
1822
1823 return 0;
1824} 1822}
1825 1823
1826EXPORT_SYMBOL(tcp_v4_destroy_sock); 1824EXPORT_SYMBOL(tcp_v4_destroy_sock);
diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c
index 355e6d62d483..eba790dcd16b 100644
--- a/net/ipv4/udp.c
+++ b/net/ipv4/udp.c
@@ -1253,12 +1253,11 @@ int udp_rcv(struct sk_buff *skb)
1253 return __udp4_lib_rcv(skb, udp_hash, IPPROTO_UDP); 1253 return __udp4_lib_rcv(skb, udp_hash, IPPROTO_UDP);
1254} 1254}
1255 1255
1256int udp_destroy_sock(struct sock *sk) 1256void udp_destroy_sock(struct sock *sk)
1257{ 1257{
1258 lock_sock(sk); 1258 lock_sock(sk);
1259 udp_flush_pending_frames(sk); 1259 udp_flush_pending_frames(sk);
1260 release_sock(sk); 1260 release_sock(sk);
1261 return 0;
1262} 1261}
1263 1262
1264/* 1263/*
diff --git a/net/ipv4/udp_impl.h b/net/ipv4/udp_impl.h
index 7288bf7977fb..2e9bad2fa1bc 100644
--- a/net/ipv4/udp_impl.h
+++ b/net/ipv4/udp_impl.h
@@ -26,7 +26,7 @@ extern int udp_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
26extern int udp_sendpage(struct sock *sk, struct page *page, int offset, 26extern int udp_sendpage(struct sock *sk, struct page *page, int offset,
27 size_t size, int flags); 27 size_t size, int flags);
28extern int udp_queue_rcv_skb(struct sock * sk, struct sk_buff *skb); 28extern int udp_queue_rcv_skb(struct sock * sk, struct sk_buff *skb);
29extern int udp_destroy_sock(struct sock *sk); 29extern void udp_destroy_sock(struct sock *sk);
30 30
31#ifdef CONFIG_PROC_FS 31#ifdef CONFIG_PROC_FS
32extern int udp4_seq_show(struct seq_file *seq, void *v); 32extern int udp4_seq_show(struct seq_file *seq, void *v);