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 1/3] meta: add random expression key
Date: Tue, 19 Jul 2016 00:09:10 +0200	[thread overview]
Message-ID: <20160718220910.GA29897@breakpoint.cc> (raw)
In-Reply-To: <20160718193421.GA4275@salvia>

Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> On Tue, Jul 05, 2016 at 09:35:33AM +0200, Florian Westphal wrote:
> > meta random fills a 32bit register with a pseudo-random number.
> > 
> > For instance one can now use
> > 
> > meta random <= 2147483647
> > 
> > ... to match every 2nd packet, on average.
> > 
> > A followup patch will add a short-hand version ('probability 0.5') so
> > that users do not have to deal with details.
> > 
> > Signed-off-by: Florian Westphal <fw@strlen.de>
> 
> Please, apply this patch.
> 
> Acked-by: Pablo Neira Ayuso <pablo@netfilter.org>
> 
> We can later on revisit the probability scaling, so keep 2/3 and 3/3
> back by now.

Done, I pushed a slightly amended version (no additional #include, only
needed in followup changes, I also edited the changelog to not mention
probability anymore.

  reply	other threads:[~2016-07-18 22:09 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-05  7:35 [PATCH nft 1/3] meta: add random and probability match Florian Westphal
2016-07-05  7:35 ` [PATCH nft 1/3] meta: add random expression key Florian Westphal
2016-07-18 19:34   ` Pablo Neira Ayuso
2016-07-18 22:09     ` Florian Westphal [this message]
2016-07-05  7:35 ` [PATCH nft 2/3] meta: add short-hand mnemonic for probalistic matching Florian Westphal
2016-07-14 10:41   ` Pablo Neira Ayuso
2016-07-14 10:52     ` Florian Westphal
2016-07-14 11:32       ` Pablo Neira Ayuso
2016-07-14 12:08         ` Florian Westphal
2016-07-14 12:17           ` Pablo Neira Ayuso
2016-07-05  7:35 ` [PATCH nft 3/3] netlink_delinearize, meta: show meta prandom <= value as probability mnemonic Florian Westphal

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=20160718220910.GA29897@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.