Commit ce4b1cebdcd4779097e9862670e5c5208e76712b
Committed by
David S. Miller
1 parent
2b628a0866
[NETFILTER]: nf_nat: sprinkle a few __read_mostlys
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Showing 1 changed file with 5 additions and 4 deletions Side-by-side Diff
net/ipv4/netfilter/nf_nat_core.c
... | ... | @@ -33,16 +33,17 @@ |
33 | 33 | |
34 | 34 | static DEFINE_RWLOCK(nf_nat_lock); |
35 | 35 | |
36 | -static struct nf_conntrack_l3proto *l3proto = NULL; | |
36 | +static struct nf_conntrack_l3proto *l3proto __read_mostly; | |
37 | 37 | |
38 | 38 | /* Calculated at init based on memory size */ |
39 | -static unsigned int nf_nat_htable_size; | |
39 | +static unsigned int nf_nat_htable_size __read_mostly; | |
40 | 40 | static int nf_nat_vmalloced; |
41 | 41 | |
42 | -static struct hlist_head *bysource; | |
42 | +static struct hlist_head *bysource __read_mostly; | |
43 | 43 | |
44 | 44 | #define MAX_IP_NAT_PROTO 256 |
45 | -static const struct nf_nat_protocol *nf_nat_protos[MAX_IP_NAT_PROTO]; | |
45 | +static const struct nf_nat_protocol *nf_nat_protos[MAX_IP_NAT_PROTO] | |
46 | + __read_mostly; | |
46 | 47 | |
47 | 48 | static inline const struct nf_nat_protocol * |
48 | 49 | __nf_nat_proto_find(u_int8_t protonum) |