All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: Florian Westphal <fw@strlen.de>, netfilter-devel@vger.kernel.org
Subject: Re: [PATCH nft] src: allow to map key to nfqueue number
Date: Wed, 6 Nov 2024 14:52:44 +0100	[thread overview]
Message-ID: <20241106135244.GA11098@breakpoint.cc> (raw)
In-Reply-To: <Zytu_YJeGyF-RaxI@calendula>

Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> > @@ -447,6 +457,9 @@ extern struct expr *relational_expr_alloc(const struct location *loc, enum ops o
> >  extern void relational_expr_pctx_update(struct proto_ctx *ctx,
> >  					const struct expr *expr);
> >  
> > +extern struct expr *typeof_expr_alloc(const struct location *loc,
> > +				      enum expr_typeof_key key);
> 
> I think it should be possible to follow an alternative path to achieve
> this, that is, use integer_expr and attach a new internal datatype,
> ie. queue_type, for this queue number.
> 
> No need for new TYPE_* in enum, that is only required by
> concatenations and this datatype will not ever be used in that case.
> 
> For reference, there is also use of this alias datatypes such as
> xinteger_type which is used to print integers in hexadecimal.
> 
> From userdata path it should be possible to check for this special
> internal queue_datatype then encode the queue number type in the TLV.

I have no idea how to do any of this.  I don't even know what a "queue number
type" is.

How on earth do i flip the data type on postprocessing without any idea
what "2 octets worth of data" is?

  reply	other threads:[~2024-11-06 13:52 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-25  7:47 [PATCH nft] src: allow to map key to nfqueue number Florian Westphal
2024-11-06 13:28 ` Pablo Neira Ayuso
2024-11-06 13:52   ` Florian Westphal [this message]
2024-11-06 14:32     ` Florian Westphal
2024-11-06 16:03       ` Pablo Neira Ayuso
2024-11-06 23:11         ` Pablo Neira Ayuso
2024-11-06 23:34           ` Pablo Neira Ayuso
2024-11-08 12:08             ` Florian Westphal
2024-11-11 10:38               ` 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=20241106135244.GA11098@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.