aboutsummaryrefslogtreecommitdiffstats
path: root/include/net
diff options
context:
space:
mode:
authorDaniel Lezcano <dlezcano@fr.ibm.com>2007-12-11 05:25:35 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 17:57:13 -0500
commit7f4e4868f3ce0e946f116c28fa4fe033be5e4ba9 (patch)
tree144add1d4c94a145f7e048a17d91b563f5e6e265 /include/net
parent87c3efbfdd1f98af14a1f60ff19f73d9a8d8da98 (diff)
[IPV6]: make the protocol initialization to return an error code
This patchset makes the different protocols to return an error code, so the af_inet6 module can check the initialization was correct or not. The raw6 was taken into account to be consistent with the rest of the protocols, but the registration is at the same place. Because the raw6 has its own init function, the proto and the ops structure can be moved inside the raw6.c file. Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net')
-rw-r--r--include/net/ipv6.h2
-rw-r--r--include/net/transp_v6.h12
2 files changed, 9 insertions, 5 deletions
diff --git a/include/net/ipv6.h b/include/net/ipv6.h
index 4d9106580950..f2adedff927f 100644
--- a/include/net/ipv6.h
+++ b/include/net/ipv6.h
@@ -545,7 +545,7 @@ extern int compat_ipv6_getsockopt(struct sock *sk,
545 char __user *optval, 545 char __user *optval,
546 int __user *optlen); 546 int __user *optlen);
547 547
548extern void ipv6_packet_init(void); 548extern int ipv6_packet_init(void);
549 549
550extern void ipv6_packet_cleanup(void); 550extern void ipv6_packet_cleanup(void);
551 551
diff --git a/include/net/transp_v6.h b/include/net/transp_v6.h
index aa9a4a6b99df..27394e0447d8 100644
--- a/include/net/transp_v6.h
+++ b/include/net/transp_v6.h
@@ -23,10 +23,14 @@ extern int ipv6_frag_init(void);
23extern void ipv6_frag_exit(void); 23extern void ipv6_frag_exit(void);
24 24
25/* transport protocols */ 25/* transport protocols */
26extern void rawv6_init(void); 26extern int rawv6_init(void);
27extern void udpv6_init(void); 27extern void rawv6_exit(void);
28extern void udplitev6_init(void); 28extern int udpv6_init(void);
29extern void tcpv6_init(void); 29extern void udpv6_exit(void);
30extern int udplitev6_init(void);
31extern void udplitev6_exit(void);
32extern int tcpv6_init(void);
33extern void tcpv6_exit(void);
30 34
31extern int udpv6_connect(struct sock *sk, 35extern int udpv6_connect(struct sock *sk,
32 struct sockaddr *uaddr, 36 struct sockaddr *uaddr,