From: Florian Westphal <fw@strlen.de>
To: Tom Herbert <tom@herbertland.com>
Cc: davem@davemloft.net, netdev@vger.kernel.org, kernel-team@fb.com
Subject: Re: [PATCH net-next v4 4/4] ila: Add generic ILA translation facility
Date: Fri, 11 Dec 2015 12:19:04 +0100 [thread overview]
Message-ID: <20151211111904.GB5665@breakpoint.cc> (raw)
In-Reply-To: <1449793173-4086221-5-git-send-email-tom@herbertland.com>
Tom Herbert <tom@herbertland.com> wrote:
> +static struct nf_hook_ops ila_nf_hook_ops[] __read_mostly = {
> + {
> + .hook = ila_nf_input,
> + .pf = NFPROTO_IPV6,
> + .hooknum = NF_INET_PRE_ROUTING,
> + .priority = -1,
[..]
> +int ila_xlat_init(void)
[..]
> + for (; nf_hook < ARRAY_SIZE(ila_nf_hook_ops); nf_hook++) {
> + ret = nf_register_hook(&ila_nf_hook_ops[nf_hook]);
Nit:
We have nf_register_hooks() which does "all or none" registration
for you.
How likely is it that ILA is done in initial ns only on setups with
lots of net namespaces?
The problem with "nf_register_hook(s)" is that the hooks are placed
in all namespaces & inherited by all newly created namespaces.
So if we do ILA in init ns it & pass such skbs to other netns
it would be preferable to use nf_register_net_hooks in a namespace
once the first ila translation is added within that namespace.
next prev parent reply other threads:[~2015-12-11 11:19 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-11 0:19 [PATCH net-next v4 0/4] ila: Optimization to preserve value of early demux Tom Herbert
2015-12-11 0:19 ` [PATCH net-next v4 1/4] ila: Create net/ipv6/ila directory Tom Herbert
2015-12-11 0:19 ` [PATCH net-next v4 2/4] rhashtable: add function to replace an element Tom Herbert
2015-12-11 0:19 ` [PATCH net-next v4 3/4] netlink: add a start callback for starting a netlink dump Tom Herbert
2015-12-11 0:19 ` [PATCH net-next v4 4/4] ila: Add generic ILA translation facility Tom Herbert
2015-12-11 11:19 ` Florian Westphal [this message]
2015-12-18 19:18 ` David Miller
2015-12-14 21:19 ` [PATCH net-next v4 0/4] ila: Optimization to preserve value of early demux David Miller
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=20151211111904.GB5665@breakpoint.cc \
--to=fw@strlen.de \
--cc=davem@davemloft.net \
--cc=kernel-team@fb.com \
--cc=netdev@vger.kernel.org \
--cc=tom@herbertland.com \
/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).