netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH iptables 0/6] cache rework
@ 2019-05-20 12:26 Pablo Neira Ayuso
  2019-05-20 12:26 ` [PATCH iptables 1/6] nft: add struct nft_cache Pablo Neira Ayuso
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Pablo Neira Ayuso @ 2019-05-20 12:26 UTC (permalink / raw)
  To: netfilter-devel; +Cc: phil, fw

This patchset updates the cache logic:

* Update nft_table_list_get() to use a list of tables from the cache,
  instead of listing them from the kernel.

* Ensure cache consistency by checking for generation ID is consistent
  when building up the cache.

Without this, we may end up with an inconsistent cache, hence defeating
the refresh transaction logic.

The other patches are just a few preparation patches to allow to
maintain the original cache and a cache that is refreshed everytime this
hits ERESTART.

My plan is to send another batch to revisit the refresh transaction
logic after this patchset, since 0004-restore-race_0 still does not
work after this.

Pablo Neira Ayuso (6):
  nft: add struct nft_cache
  nft: statify nft_rebuild_cache()
  nft: add __nft_table_builtin_find()
  nft: add flush_cache()
  nft: cache table list
  nft: ensure cache consistency

 iptables/nft.c | 195 ++++++++++++++++++++++++++++++++++-----------------------
 iptables/nft.h |  15 +++--
 2 files changed, 126 insertions(+), 84 deletions(-)

-- 
2.11.0


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-05-20 12:45 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-20 12:26 [PATCH iptables 0/6] cache rework Pablo Neira Ayuso
2019-05-20 12:26 ` [PATCH iptables 1/6] nft: add struct nft_cache Pablo Neira Ayuso
2019-05-20 12:26 ` [PATCH iptables 2/6] nft: statify nft_rebuild_cache() Pablo Neira Ayuso
2019-05-20 12:26 ` [PATCH iptables 3/6] nft: add __nft_table_builtin_find() Pablo Neira Ayuso
2019-05-20 12:26 ` [PATCH iptables 4/6] nft: add flush_cache() Pablo Neira Ayuso
2019-05-20 12:26 ` [PATCH iptables 5/6] nft: cache table list Pablo Neira Ayuso
2019-05-20 12:26 ` [PATCH iptables 6/6] nft: ensure cache consistency Pablo Neira Ayuso

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).