All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH nf-next,RFC 3/8] netfilter: nf_tables: expose opaque set element as struct nft_elem_priv
Date: Fri, 20 Oct 2023 13:31:19 +0200	[thread overview]
Message-ID: <20231020113119.GE9493@breakpoint.cc> (raw)
In-Reply-To: <20231019141958.653727-4-pablo@netfilter.org>

Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> +static inline void *nft_elem_priv_cast(const struct nft_elem_priv *priv)
> +{
> +	return (void *)priv;
> +}

I'm fine with this, alternative would be to make this per-set backend:

#define nft_elem_priv_to_bitmap_elem(ptr)	container_of_const(ptr, struct nft_bitmap_elem, priv)

I'll leave it up to you.  The only advantage of the latter is that priv
doesn't have to be the first member.

  reply	other threads:[~2023-10-20 11:31 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-19 14:19 [PATCH nf-next,RFC 0/8] nf_tables set updates Pablo Neira Ayuso
2023-10-19 14:19 ` [PATCH nf-next,RFC 1/8] netfilter: nft_set_pipapo: no need to call pipapo_deactivate() from flush Pablo Neira Ayuso
2023-10-19 14:19 ` [PATCH nf-next,RFC 2/8] netfilter: nf_tables: set backend .flush always succeeds Pablo Neira Ayuso
2023-10-19 14:19 ` [PATCH nf-next,RFC 3/8] netfilter: nf_tables: expose opaque set element as struct nft_elem_priv Pablo Neira Ayuso
2023-10-20 11:31   ` Florian Westphal [this message]
2023-10-19 14:19 ` [PATCH nf-next,RFC 4/8] netfilter: nf_tables: shrink memory consumption of set elements Pablo Neira Ayuso
2023-10-19 14:19 ` [PATCH nf-next,RFC 5/8] netfilter: nf_tables: set->ops->insert returns opaque set element in case of EEXIST Pablo Neira Ayuso
2023-10-19 14:19 ` [PATCH nf-next,RFC 6/8] netfilter: nf_tables: use timestamp to check for set element timeout Pablo Neira Ayuso
2023-10-20 11:46   ` Florian Westphal
2023-10-19 14:19 ` [PATCH nf-next,RFC 7/8] netfilter: nf_tables: add timeout extension to elements to prepare for updates Pablo Neira Ayuso
2023-10-19 14:19 ` [PATCH nf-next,RFC 8/8] netfilter: nf_tables: set element timeout update support 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=20231020113119.GE9493@breakpoint.cc \
    --to=fw@strlen.de \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=pablo@netfilter.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.