netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH nf-next v2 0/2] NF NAT deduplication refactoring
@ 2023-03-15 21:47 Jeremy Sowden
  2023-03-15 21:48 ` Jeremy Sowden
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Jeremy Sowden @ 2023-03-15 21:47 UTC (permalink / raw)
  To: Netfilter Devel

These two patches perform refactoring in NF NAT modules to remove
duplicate code.  I've incorporated the changes that Pablo suggested.

Changes since v1.

  * The two redirect patches in v1 have been merged.
  * The new `struct nf_nat_range2` instance in nf_nat_redirect.c is
    memset to zero.
  * The two `union nf_inet_addr` instances in nf_nat_redirect.c are
    zero-initialized.
  * The `WARN_ON` call in nf_nat_redirect.c has been removed.

Jeremy Sowden (2):
  netfilter: nft_redir: use `struct nf_nat_range2` throughout and
    deduplicate eval call-backs
  netfilter: nft_masq: deduplicate eval call-backs

 include/net/netfilter/nf_nat_redirect.h |  3 +-
 net/netfilter/nf_nat_redirect.c         | 71 ++++++++++-----------
 net/netfilter/nft_masq.c                | 75 +++++++++-------------
 net/netfilter/nft_redir.c               | 84 +++++++++----------------
 net/netfilter/xt_REDIRECT.c             | 10 ++-
 5 files changed, 101 insertions(+), 142 deletions(-)

-- 
2.39.2


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

end of thread, other threads:[~2023-03-15 21:48 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-15 21:47 [PATCH nf-next v2 0/2] NF NAT deduplication refactoring Jeremy Sowden
2023-03-15 21:48 ` Jeremy Sowden
2023-03-15 21:48 ` [PATCH nf-next v2 1/2] netfilter: nft_redir: use `struct nf_nat_range2` throughout and deduplicate eval call-backs Jeremy Sowden
2023-03-15 21:48 ` [PATCH nf-next v2 2/2] netfilter: nft_masq: " Jeremy Sowden

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).