aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2007-12-18 01:42:27 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 17:59:05 -0500
commit1e796fda00f06bac584f0e4ad8750ab9430d79d3 (patch)
treec397d3c84060a0a3dcc83f4bdbb3a470cfd8db06 /include
parent90a9ba8dd90bcffe279d3272545bccba6dcc8d7c (diff)
[NETFILTER]: constify nf_afinfo
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r--include/linux/netfilter.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/linux/netfilter.h b/include/linux/netfilter.h
index bd4a2dd54233..0947424d01d6 100644
--- a/include/linux/netfilter.h
+++ b/include/linux/netfilter.h
@@ -226,8 +226,8 @@ struct nf_afinfo {
226 int route_key_size; 226 int route_key_size;
227}; 227};
228 228
229extern struct nf_afinfo *nf_afinfo[]; 229extern const struct nf_afinfo *nf_afinfo[NPROTO];
230static inline struct nf_afinfo *nf_get_afinfo(unsigned short family) 230static inline const struct nf_afinfo *nf_get_afinfo(unsigned short family)
231{ 231{
232 return rcu_dereference(nf_afinfo[family]); 232 return rcu_dereference(nf_afinfo[family]);
233} 233}
@@ -236,7 +236,7 @@ static inline __sum16
236nf_checksum(struct sk_buff *skb, unsigned int hook, unsigned int dataoff, 236nf_checksum(struct sk_buff *skb, unsigned int hook, unsigned int dataoff,
237 u_int8_t protocol, unsigned short family) 237 u_int8_t protocol, unsigned short family)
238{ 238{
239 struct nf_afinfo *afinfo; 239 const struct nf_afinfo *afinfo;
240 __sum16 csum = 0; 240 __sum16 csum = 0;
241 241
242 rcu_read_lock(); 242 rcu_read_lock();
@@ -247,8 +247,8 @@ nf_checksum(struct sk_buff *skb, unsigned int hook, unsigned int dataoff,
247 return csum; 247 return csum;
248} 248}
249 249
250extern int nf_register_afinfo(struct nf_afinfo *afinfo); 250extern int nf_register_afinfo(const struct nf_afinfo *afinfo);
251extern void nf_unregister_afinfo(struct nf_afinfo *afinfo); 251extern void nf_unregister_afinfo(const struct nf_afinfo *afinfo);
252 252
253#include <net/flow.h> 253#include <net/flow.h>
254extern void (*ip_nat_decode_session)(struct sk_buff *, struct flowi *); 254extern void (*ip_nat_decode_session)(struct sk_buff *, struct flowi *);