diff options
author | Arnaldo Carvalho de Melo <acme@mandriva.com> | 2005-08-16 01:18:02 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2005-08-29 19:01:32 -0400 |
commit | 20380731bc2897f2952ae055420972ded4cd786e (patch) | |
tree | abd31e5ebfadcf4f9024634eec8b11855029e512 /net/ipv4 | |
parent | 9deff7f2365958c5c5aa8cb5a0dd651c4dd83f8f (diff) |
[NET]: Fix sparse warnings
Of this type, mostly:
CHECK net/ipv6/netfilter.c
net/ipv6/netfilter.c:96:12: warning: symbol 'ipv6_netfilter_init' was not declared. Should it be static?
net/ipv6/netfilter.c:101:6: warning: symbol 'ipv6_netfilter_fini' was not declared. Should it be static?
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/af_inet.c | 14 | ||||
-rw-r--r-- | net/ipv4/datagram.c | 1 | ||||
-rw-r--r-- | net/ipv4/inetpeer.c | 1 | ||||
-rw-r--r-- | net/ipv4/ip_sockglue.c | 2 | ||||
-rw-r--r-- | net/ipv4/proc.c | 3 | ||||
-rw-r--r-- | net/ipv4/syncookies.c | 2 | ||||
-rw-r--r-- | net/ipv4/sysctl_net_ipv4.c | 43 | ||||
-rw-r--r-- | net/ipv4/tcp_input.c | 2 | ||||
-rw-r--r-- | net/ipv4/tcp_ipv4.c | 2 |
9 files changed, 11 insertions, 59 deletions
diff --git a/net/ipv4/af_inet.c b/net/ipv4/af_inet.c index 20f52b5f5dea..5810f9d14914 100644 --- a/net/ipv4/af_inet.c +++ b/net/ipv4/af_inet.c | |||
@@ -859,10 +859,6 @@ static struct net_proto_family inet_family_ops = { | |||
859 | .owner = THIS_MODULE, | 859 | .owner = THIS_MODULE, |
860 | }; | 860 | }; |
861 | 861 | ||
862 | |||
863 | extern void tcp_init(void); | ||
864 | extern void tcp_v4_init(struct net_proto_family *); | ||
865 | |||
866 | /* Upon startup we insert all the elements in inetsw_array[] into | 862 | /* Upon startup we insert all the elements in inetsw_array[] into |
867 | * the linked list inetsw. | 863 | * the linked list inetsw. |
868 | */ | 864 | */ |
@@ -1132,7 +1128,6 @@ static int __init init_ipv4_mibs(void) | |||
1132 | } | 1128 | } |
1133 | 1129 | ||
1134 | static int ipv4_proc_init(void); | 1130 | static int ipv4_proc_init(void); |
1135 | extern void ipfrag_init(void); | ||
1136 | 1131 | ||
1137 | /* | 1132 | /* |
1138 | * IP protocol layer initialiser | 1133 | * IP protocol layer initialiser |
@@ -1253,19 +1248,10 @@ module_init(inet_init); | |||
1253 | /* ------------------------------------------------------------------------ */ | 1248 | /* ------------------------------------------------------------------------ */ |
1254 | 1249 | ||
1255 | #ifdef CONFIG_PROC_FS | 1250 | #ifdef CONFIG_PROC_FS |
1256 | extern int fib_proc_init(void); | ||
1257 | extern void fib_proc_exit(void); | ||
1258 | #ifdef CONFIG_IP_FIB_TRIE | 1251 | #ifdef CONFIG_IP_FIB_TRIE |
1259 | extern int fib_stat_proc_init(void); | 1252 | extern int fib_stat_proc_init(void); |
1260 | extern void fib_stat_proc_exit(void); | 1253 | extern void fib_stat_proc_exit(void); |
1261 | #endif | 1254 | #endif |
1262 | extern int ip_misc_proc_init(void); | ||
1263 | extern int raw_proc_init(void); | ||
1264 | extern void raw_proc_exit(void); | ||
1265 | extern int tcp4_proc_init(void); | ||
1266 | extern void tcp4_proc_exit(void); | ||
1267 | extern int udp4_proc_init(void); | ||
1268 | extern void udp4_proc_exit(void); | ||
1269 | 1255 | ||
1270 | static int __init ipv4_proc_init(void) | 1256 | static int __init ipv4_proc_init(void) |
1271 | { | 1257 | { |
diff --git a/net/ipv4/datagram.c b/net/ipv4/datagram.c index 3fd49f4282ac..c1b42b5257f8 100644 --- a/net/ipv4/datagram.c +++ b/net/ipv4/datagram.c | |||
@@ -16,6 +16,7 @@ | |||
16 | #include <linux/module.h> | 16 | #include <linux/module.h> |
17 | #include <linux/ip.h> | 17 | #include <linux/ip.h> |
18 | #include <linux/in.h> | 18 | #include <linux/in.h> |
19 | #include <net/ip.h> | ||
19 | #include <net/sock.h> | 20 | #include <net/sock.h> |
20 | #include <net/route.h> | 21 | #include <net/route.h> |
21 | #include <net/tcp_states.h> | 22 | #include <net/tcp_states.h> |
diff --git a/net/ipv4/inetpeer.c b/net/ipv4/inetpeer.c index 3c513ceaca76..4410b9dc03e9 100644 --- a/net/ipv4/inetpeer.c +++ b/net/ipv4/inetpeer.c | |||
@@ -20,6 +20,7 @@ | |||
20 | #include <linux/kernel.h> | 20 | #include <linux/kernel.h> |
21 | #include <linux/mm.h> | 21 | #include <linux/mm.h> |
22 | #include <linux/net.h> | 22 | #include <linux/net.h> |
23 | #include <net/ip.h> | ||
23 | #include <net/inetpeer.h> | 24 | #include <net/inetpeer.h> |
24 | 25 | ||
25 | /* | 26 | /* |
diff --git a/net/ipv4/ip_sockglue.c b/net/ipv4/ip_sockglue.c index ddb1aedbdc6d..aca088b3707a 100644 --- a/net/ipv4/ip_sockglue.c +++ b/net/ipv4/ip_sockglue.c | |||
@@ -614,7 +614,6 @@ int ip_setsockopt(struct sock *sk, int level, int optname, char __user *optval, | |||
614 | } | 614 | } |
615 | case IP_MSFILTER: | 615 | case IP_MSFILTER: |
616 | { | 616 | { |
617 | extern int sysctl_optmem_max; | ||
618 | extern int sysctl_igmp_max_msf; | 617 | extern int sysctl_igmp_max_msf; |
619 | struct ip_msfilter *msf; | 618 | struct ip_msfilter *msf; |
620 | 619 | ||
@@ -769,7 +768,6 @@ int ip_setsockopt(struct sock *sk, int level, int optname, char __user *optval, | |||
769 | } | 768 | } |
770 | case MCAST_MSFILTER: | 769 | case MCAST_MSFILTER: |
771 | { | 770 | { |
772 | extern int sysctl_optmem_max; | ||
773 | extern int sysctl_igmp_max_msf; | 771 | extern int sysctl_igmp_max_msf; |
774 | struct sockaddr_in *psin; | 772 | struct sockaddr_in *psin; |
775 | struct ip_msfilter *msf = NULL; | 773 | struct ip_msfilter *msf = NULL; |
diff --git a/net/ipv4/proc.c b/net/ipv4/proc.c index 3eadbb271871..f7943ba1f43c 100644 --- a/net/ipv4/proc.c +++ b/net/ipv4/proc.c | |||
@@ -59,9 +59,6 @@ static int fold_prot_inuse(struct proto *proto) | |||
59 | */ | 59 | */ |
60 | static int sockstat_seq_show(struct seq_file *seq, void *v) | 60 | static int sockstat_seq_show(struct seq_file *seq, void *v) |
61 | { | 61 | { |
62 | /* From net/socket.c */ | ||
63 | extern void socket_seq_show(struct seq_file *seq); | ||
64 | |||
65 | socket_seq_show(seq); | 62 | socket_seq_show(seq); |
66 | seq_printf(seq, "TCP: inuse %d orphan %d tw %d alloc %d mem %d\n", | 63 | seq_printf(seq, "TCP: inuse %d orphan %d tw %d alloc %d mem %d\n", |
67 | fold_prot_inuse(&tcp_prot), atomic_read(&tcp_orphan_count), | 64 | fold_prot_inuse(&tcp_prot), atomic_read(&tcp_orphan_count), |
diff --git a/net/ipv4/syncookies.c b/net/ipv4/syncookies.c index 8692cb9d4bdb..a34e60ea48a1 100644 --- a/net/ipv4/syncookies.c +++ b/net/ipv4/syncookies.c | |||
@@ -169,8 +169,6 @@ static inline int cookie_check(struct sk_buff *skb, __u32 cookie) | |||
169 | return mssind < NUM_MSS ? msstab[mssind] + 1 : 0; | 169 | return mssind < NUM_MSS ? msstab[mssind] + 1 : 0; |
170 | } | 170 | } |
171 | 171 | ||
172 | extern struct request_sock_ops tcp_request_sock_ops; | ||
173 | |||
174 | static inline struct sock *get_cookie_sock(struct sock *sk, struct sk_buff *skb, | 172 | static inline struct sock *get_cookie_sock(struct sock *sk, struct sk_buff *skb, |
175 | struct request_sock *req, | 173 | struct request_sock *req, |
176 | struct dst_entry *dst) | 174 | struct dst_entry *dst) |
diff --git a/net/ipv4/sysctl_net_ipv4.c b/net/ipv4/sysctl_net_ipv4.c index ce47a345ecc5..652685623519 100644 --- a/net/ipv4/sysctl_net_ipv4.c +++ b/net/ipv4/sysctl_net_ipv4.c | |||
@@ -11,7 +11,9 @@ | |||
11 | #include <linux/module.h> | 11 | #include <linux/module.h> |
12 | #include <linux/sysctl.h> | 12 | #include <linux/sysctl.h> |
13 | #include <linux/config.h> | 13 | #include <linux/config.h> |
14 | #include <linux/igmp.h> | ||
14 | #include <net/snmp.h> | 15 | #include <net/snmp.h> |
16 | #include <net/icmp.h> | ||
15 | #include <net/ip.h> | 17 | #include <net/ip.h> |
16 | #include <net/route.h> | 18 | #include <net/route.h> |
17 | #include <net/tcp.h> | 19 | #include <net/tcp.h> |
@@ -19,36 +21,6 @@ | |||
19 | /* From af_inet.c */ | 21 | /* From af_inet.c */ |
20 | extern int sysctl_ip_nonlocal_bind; | 22 | extern int sysctl_ip_nonlocal_bind; |
21 | 23 | ||
22 | /* From icmp.c */ | ||
23 | extern int sysctl_icmp_echo_ignore_all; | ||
24 | extern int sysctl_icmp_echo_ignore_broadcasts; | ||
25 | extern int sysctl_icmp_ignore_bogus_error_responses; | ||
26 | extern int sysctl_icmp_errors_use_inbound_ifaddr; | ||
27 | |||
28 | /* From ip_fragment.c */ | ||
29 | extern int sysctl_ipfrag_low_thresh; | ||
30 | extern int sysctl_ipfrag_high_thresh; | ||
31 | extern int sysctl_ipfrag_time; | ||
32 | extern int sysctl_ipfrag_secret_interval; | ||
33 | |||
34 | /* From ip_output.c */ | ||
35 | extern int sysctl_ip_dynaddr; | ||
36 | |||
37 | /* From icmp.c */ | ||
38 | extern int sysctl_icmp_ratelimit; | ||
39 | extern int sysctl_icmp_ratemask; | ||
40 | |||
41 | /* From igmp.c */ | ||
42 | extern int sysctl_igmp_max_memberships; | ||
43 | extern int sysctl_igmp_max_msf; | ||
44 | |||
45 | /* From inetpeer.c */ | ||
46 | extern int inet_peer_threshold; | ||
47 | extern int inet_peer_minttl; | ||
48 | extern int inet_peer_maxttl; | ||
49 | extern int inet_peer_gc_mintime; | ||
50 | extern int inet_peer_gc_maxtime; | ||
51 | |||
52 | #ifdef CONFIG_SYSCTL | 24 | #ifdef CONFIG_SYSCTL |
53 | static int tcp_retr1_max = 255; | 25 | static int tcp_retr1_max = 255; |
54 | static int ip_local_port_range_min[] = { 1, 1 }; | 26 | static int ip_local_port_range_min[] = { 1, 1 }; |
@@ -57,8 +29,6 @@ static int ip_local_port_range_max[] = { 65535, 65535 }; | |||
57 | 29 | ||
58 | struct ipv4_config ipv4_config; | 30 | struct ipv4_config ipv4_config; |
59 | 31 | ||
60 | extern ctl_table ipv4_route_table[]; | ||
61 | |||
62 | #ifdef CONFIG_SYSCTL | 32 | #ifdef CONFIG_SYSCTL |
63 | 33 | ||
64 | static | 34 | static |
@@ -136,10 +106,11 @@ static int proc_tcp_congestion_control(ctl_table *ctl, int write, struct file * | |||
136 | return ret; | 106 | return ret; |
137 | } | 107 | } |
138 | 108 | ||
139 | int sysctl_tcp_congestion_control(ctl_table *table, int __user *name, int nlen, | 109 | static int sysctl_tcp_congestion_control(ctl_table *table, int __user *name, |
140 | void __user *oldval, size_t __user *oldlenp, | 110 | int nlen, void __user *oldval, |
141 | void __user *newval, size_t newlen, | 111 | size_t __user *oldlenp, |
142 | void **context) | 112 | void __user *newval, size_t newlen, |
113 | void **context) | ||
143 | { | 114 | { |
144 | char val[TCP_CA_NAME_MAX]; | 115 | char val[TCP_CA_NAME_MAX]; |
145 | ctl_table tbl = { | 116 | ctl_table tbl = { |
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index ebb8654e3dee..1afb080bdf0c 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c | |||
@@ -4229,7 +4229,7 @@ int tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb, | |||
4229 | */ | 4229 | */ |
4230 | if (tp->rx_opt.saw_tstamp && tp->rx_opt.rcv_tsecr && | 4230 | if (tp->rx_opt.saw_tstamp && tp->rx_opt.rcv_tsecr && |
4231 | !tp->srtt) | 4231 | !tp->srtt) |
4232 | tcp_ack_saw_tstamp(sk, 0, 0); | 4232 | tcp_ack_saw_tstamp(sk, NULL, 0); |
4233 | 4233 | ||
4234 | if (tp->rx_opt.tstamp_ok) | 4234 | if (tp->rx_opt.tstamp_ok) |
4235 | tp->advmss -= TCPOLEN_TSTAMP_ALIGNED; | 4235 | tp->advmss -= TCPOLEN_TSTAMP_ALIGNED; |
diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c index 97bbf595230d..13dfb391cdf1 100644 --- a/net/ipv4/tcp_ipv4.c +++ b/net/ipv4/tcp_ipv4.c | |||
@@ -66,6 +66,7 @@ | |||
66 | #include <net/icmp.h> | 66 | #include <net/icmp.h> |
67 | #include <net/inet_hashtables.h> | 67 | #include <net/inet_hashtables.h> |
68 | #include <net/tcp.h> | 68 | #include <net/tcp.h> |
69 | #include <net/transp_v6.h> | ||
69 | #include <net/ipv6.h> | 70 | #include <net/ipv6.h> |
70 | #include <net/inet_common.h> | 71 | #include <net/inet_common.h> |
71 | #include <net/xfrm.h> | 72 | #include <net/xfrm.h> |
@@ -76,7 +77,6 @@ | |||
76 | #include <linux/proc_fs.h> | 77 | #include <linux/proc_fs.h> |
77 | #include <linux/seq_file.h> | 78 | #include <linux/seq_file.h> |
78 | 79 | ||
79 | extern int sysctl_ip_dynaddr; | ||
80 | int sysctl_tcp_tw_reuse; | 80 | int sysctl_tcp_tw_reuse; |
81 | int sysctl_tcp_low_latency; | 81 | int sysctl_tcp_low_latency; |
82 | 82 | ||