Skip to content

Commit 88bae77

Browse files
ummakynesgregkh
authored andcommitted
netfilter: nf_tables: use net_generic infra for transaction data
[ 0854db2 ] This moves all nf_tables pernet data from struct net to a net_generic extension, with the exception of the gencursor. The latter is used in the data path and also outside of the nf_tables core. All others are only used from the configuration plane. Signed-off-by: Florian Westphal <[email protected]> Signed-off-by: Pablo Neira Ayuso <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent f2a0072 commit 88bae77

File tree

5 files changed

+210
-125
lines changed

5 files changed

+210
-125
lines changed

include/net/netfilter/nf_tables.h

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1409,4 +1409,14 @@ struct nft_trans_flowtable {
14091409
int __init nft_chain_filter_init(void);
14101410
void nft_chain_filter_fini(void);
14111411

1412+
struct nftables_pernet {
1413+
struct list_head tables;
1414+
struct list_head commit_list;
1415+
struct list_head module_list;
1416+
struct list_head notify_list;
1417+
struct mutex commit_mutex;
1418+
unsigned int base_seq;
1419+
u8 validate_state;
1420+
};
1421+
14121422
#endif /* _NET_NF_TABLES_H */

include/net/netns/nftables.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,7 @@
55
#include <linux/list.h>
66

77
struct netns_nftables {
8-
struct list_head tables;
9-
struct list_head commit_list;
10-
struct mutex commit_mutex;
11-
unsigned int base_seq;
128
u8 gencursor;
13-
u8 validate_state;
149
};
1510

1611
#endif

0 commit comments

Comments
 (0)