From: Florian Westphal <fw@strlen.de>
To: Dao Quang Minh <dqminh89@gmail.com>
Cc: Florian Westphal <fw@strlen.de>, netfilter-devel@vger.kernel.org
Subject: Re: [PATCH nf 1/2] netfilter: nat: Revert "netfilter: nat: convert nat bysrc hash to rhashtable"
Date: Wed, 6 Sep 2017 15:07:50 +0200 [thread overview]
Message-ID: <20170906130750.GE11551@breakpoint.cc> (raw)
In-Reply-To: <CAFoGUiyjXxgYBU+POj2_x3H9BXPW=FUGr3LS3KNUDdxDL0vbng@mail.gmail.com>
Dao Quang Minh <dqminh89@gmail.com> wrote:
> Thanks for the patch !
>
> > rhlist removal however requires a rhlist walk.
> We can have thousands of entries in such a list if source port/addresses
> are reused for multiple flows, if this happens removal requests are so
> expensive that deletions of a few thousand flows can take several
> seconds(!).
>
> Do you think rhlist can use double linked list instead of single linked so
> removal doesn't need to walk the whole chain ?
Yes, but:
> > I tried to add hlist_node to rhlist to speed up rhltable_remove but this
> > isn't doable without changing semantics. rhltable_remove_fast will
> > check that the to-be-deleted object is part of the table and that
> > requires a list walk that we want to avoid.
> >
> > Furthermore, using hlist_node increases size of struct rhlist_head, which
> > in turn increases nf_conn size.
next prev parent reply other threads:[~2017-09-06 13:10 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-06 12:39 [PATCH nf 0/2] netfilter: nat: do not use rhltable Florian Westphal
2017-09-06 12:39 ` [PATCH nf 1/2] netfilter: nat: Revert "netfilter: nat: convert nat bysrc hash to rhashtable" Florian Westphal
[not found] ` <CAFoGUiyjXxgYBU+POj2_x3H9BXPW=FUGr3LS3KNUDdxDL0vbng@mail.gmail.com>
2017-09-06 13:07 ` Florian Westphal [this message]
2017-09-06 12:39 ` [PATCH nf 2/2] netfilter: nat: use keyed locks Florian Westphal
2017-09-08 11:55 ` [PATCH nf 0/2] netfilter: nat: do not use rhltable Pablo Neira Ayuso
2017-09-11 11:47 ` Guillaume Nault
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=20170906130750.GE11551@breakpoint.cc \
--to=fw@strlen.de \
--cc=dqminh89@gmail.com \
--cc=netfilter-devel@vger.kernel.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 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).