netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: <netfilter-devel@vger.kernel.org>
Cc: <netdev@vger.kernel.org>, Florian Westphal <fw@strlen.de>
Subject: [PATCH nf-next 0/5] netfilter: conntrack related cleanups
Date: Fri,  7 Jan 2022 05:03:21 +0100	[thread overview]
Message-ID: <20220107040326.28038-1-fw@strlen.de> (raw)

This patch series contains cleanups to conntrack and related
users such as ovs and act_ct.

First patch converts conntrack reference counting to refcount_t api.
Second patch gets rid of ip_ct_attach hook, we can use existing
nf_ct_hook for this.

Third patch constifies a couple of structures that don't need to be
writeable.

Last two patches splits nf_ct_put and nf_conntrack_put.
These functions still do the same thing, but now only nf_conntrack_put
uses the nf_ct_hook indirection, nf_ct_put uses a direct call.
Virtually all places should use nf_ct_put -- only core kernel code
needs to use the indirection.

Before this change, nf_ct_put was merely an alias for nf_conntrack_put
so even conntrack itself did additional indirection.

Florian Westphal (5):
  netfilter: conntrack: convert to refcount_t api
  netfilter: core: move ip_ct_attach indirection to struct nf_ct_hook
  netfilter: make function op structures const
  netfilter: conntrack: avoid useless indirection during conntrack
    destruction
  net: prefer nf_ct_put instead of nf_conntrack_put

 include/linux/netfilter.h                     | 10 ++--
 include/linux/netfilter/nf_conntrack_common.h | 10 ++--
 include/net/netfilter/nf_conntrack.h          |  8 ++-
 net/netfilter/core.c                          | 29 +++++------
 net/netfilter/nf_conntrack_core.c             | 50 +++++++++----------
 net/netfilter/nf_conntrack_expect.c           |  4 +-
 net/netfilter/nf_conntrack_netlink.c          | 10 ++--
 net/netfilter/nf_conntrack_standalone.c       |  4 +-
 net/netfilter/nf_flow_table_core.c            |  2 +-
 net/netfilter/nf_nat_core.c                   |  2 +-
 net/netfilter/nf_synproxy_core.c              |  1 -
 net/netfilter/nfnetlink_queue.c               |  8 +--
 net/netfilter/nft_ct.c                        |  4 +-
 net/netfilter/xt_CT.c                         |  3 +-
 net/openvswitch/conntrack.c                   | 15 ++++--
 net/sched/act_ct.c                            |  7 ++-
 16 files changed, 84 insertions(+), 83 deletions(-)

-- 
2.34.1


             reply	other threads:[~2022-01-07  4:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-07  4:03 Florian Westphal [this message]
2022-01-07  4:03 ` [PATCH nf-next 1/5] netfilter: conntrack: convert to refcount_t api Florian Westphal
2022-01-07  4:03 ` [PATCH nf-next 2/5] netfilter: core: move ip_ct_attach indirection to struct nf_ct_hook Florian Westphal
2022-01-07  4:03 ` [PATCH nf-next 3/5] netfilter: make function op structures const Florian Westphal
2022-01-07  4:03 ` [PATCH nf-next 4/5] netfilter: conntrack: avoid useless indirection during conntrack destruction Florian Westphal
2022-01-07  4:03 ` [PATCH nf-next 5/5] net: prefer nf_ct_put instead of nf_conntrack_put Florian Westphal
2022-01-09 22:32 ` [PATCH nf-next 0/5] netfilter: conntrack related cleanups Pablo Neira Ayuso

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220107040326.28038-1-fw@strlen.de \
    --to=fw@strlen.de \
    --cc=netdev@vger.kernel.org \
    --cc=netfilter-devel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).