]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: nf_tables: add insert operation
authorEric Leblond <eric@regit.org>
Thu, 10 Oct 2013 11:41:44 +0000 (13:41 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Mon, 14 Oct 2013 16:01:00 +0000 (18:01 +0200)
commit4f3ca5a5d968bd6f7326204dff2934030125305f
tree46b3537f5307e673fc1746bed655e9bc5d6e72e4
parent0479c0b6682afd17aceb72f2b9d572fcad8297ab
netfilter: nf_tables: add insert operation

This patch adds a new rule attribute NFTA_RULE_POSITION which is
used to store the position of a rule relatively to the others.
By providing the create command and specifying the position, the
rule is inserted after the rule with the handle equal to the
provided position.

Regarding notification, the position attribute specifies the
handle of the previous rule to make sure we don't point to any
stale rule in notifications coming from the commit path.

This patch includes the following fix from Pablo:

* nf_tables: fix rule deletion event reporting

Signed-off-by: Eric Leblond <eric@regit.org>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
include/uapi/linux/netfilter/nf_tables.h
net/netfilter/nf_tables_api.c