diff options
author | Gao feng <gaofeng@cn.fujitsu.com> | 2013-01-21 17:10:27 -0500 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2013-01-23 06:55:39 -0500 |
commit | 73f4001a52c986114f540504d70b21e52eb0d92a (patch) | |
tree | dc14dd7bc44c9f49bdd14c7f4547ea56b89d8d50 /include | |
parent | b7ff3a1fae78783e0ab1ef82f5978aeb89ddd16b (diff) |
netfilter: nf_ct_tstamp: move initialization out of pernet_operations
Move the global initial codes to the module_init/exit context.
Signed-off-by: Gao feng <gaofeng@cn.fujitsu.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/net/netfilter/nf_conntrack_timestamp.h | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/include/net/netfilter/nf_conntrack_timestamp.h b/include/net/netfilter/nf_conntrack_timestamp.h index fc9c82b1f06b..b00461413efd 100644 --- a/include/net/netfilter/nf_conntrack_timestamp.h +++ b/include/net/netfilter/nf_conntrack_timestamp.h | |||
@@ -48,15 +48,28 @@ static inline void nf_ct_set_tstamp(struct net *net, bool enable) | |||
48 | } | 48 | } |
49 | 49 | ||
50 | #ifdef CONFIG_NF_CONNTRACK_TIMESTAMP | 50 | #ifdef CONFIG_NF_CONNTRACK_TIMESTAMP |
51 | extern int nf_conntrack_tstamp_init(struct net *net); | 51 | extern int nf_conntrack_tstamp_pernet_init(struct net *net); |
52 | extern void nf_conntrack_tstamp_fini(struct net *net); | 52 | extern void nf_conntrack_tstamp_pernet_fini(struct net *net); |
53 | |||
54 | extern int nf_conntrack_tstamp_init(void); | ||
55 | extern void nf_conntrack_tstamp_fini(void); | ||
53 | #else | 56 | #else |
54 | static inline int nf_conntrack_tstamp_init(struct net *net) | 57 | static inline int nf_conntrack_tstamp_pernet_init(struct net *net) |
58 | { | ||
59 | return 0; | ||
60 | } | ||
61 | |||
62 | static inline void nf_conntrack_tstamp_pernet_fini(struct net *net) | ||
63 | { | ||
64 | return; | ||
65 | } | ||
66 | |||
67 | static inline int nf_conntrack_tstamp_init(void) | ||
55 | { | 68 | { |
56 | return 0; | 69 | return 0; |
57 | } | 70 | } |
58 | 71 | ||
59 | static inline void nf_conntrack_tstamp_fini(struct net *net) | 72 | static inline void nf_conntrack_tstamp_fini(void) |
60 | { | 73 | { |
61 | return; | 74 | return; |
62 | } | 75 | } |