From: Florian Westphal <fw@strlen.de>
To: <netdev@vger.kernel.org>
Cc: steffen.klassert@secunet.com, ilant@mellanox.com
Subject: [PATCH net-next 0/10] xfrm: remove flow cache
Date: Mon, 17 Jul 2017 13:57:17 +0200 [thread overview]
Message-ID: <20170717115727.26042-1-fw@strlen.de> (raw)
After RCU-ification of ipsec packet path there are no major scalability
issues anymore without flow cache.
We still incur a performance hit, which comes mostly from the extra xfrm
dst allocation/freeing.
The last patch in the series adds a simple percpu cache to avoid the
extra allocation if a packet matched the same policies as last one.
The main concern with this is that we will see performance drops,
especially with large numbers of policies/SAs.
However, during hallway discussions at nfws 2017 it seemed the issues
with flow caching outweight the removal downsides, and that it
might be best to just 'remove it' and see where the practical issues
(if any) will appear.
It should now be possible to also remove the genid member in the policies
as we don't hold bundles for prolonged time anymore, but I think
this change is controversial (and intrusive) enough as-is, so defer
that to a later point in time.
Changes since last rfc:
- fix build failures due to implicit interrupt.h includes
- rework last patch (pcpu cache):
* avoid xchg()
* check policies for walk.dead = 1 instead of more costly bundle_ok().
* flush pcpu bundles when sa/policies get removed, to allow module
references to go away (suggested by Ilan Tayari)
Documentation/networking/ip-sysctl.txt | 7
drivers/net/arcnet/arcdevice.h | 2
drivers/net/ethernet/amd/xgbe/xgbe.h | 1
drivers/net/ethernet/synopsys/dwc-xlgmac-net.c | 1
drivers/net/ieee802154/ca8210.c | 1
include/net/flow.h | 34 -
include/net/netns/xfrm.h | 11
include/net/xfrm.h | 9
net/core/Makefile | 1
net/ipv4/ip_vti.c | 31 -
net/ipv4/xfrm4_policy.c | 11
net/ipv6/ip6_vti.c | 31 -
net/ipv6/xfrm6_policy.c | 11
net/key/af_key.c | 6
net/xfrm/xfrm_device.c | 4
net/xfrm/xfrm_policy.c | 417 +++++++-----------
net/xfrm/xfrm_state.c | 5
net/xfrm/xfrm_user.c | 3
security/selinux/include/xfrm.h | 4
include/net/flowcache.h | 25 -
net/core/flow.c | 516 -----------------------
21 files changed, 173 insertions(+), 957 deletions(-)
next reply other threads:[~2017-07-17 11:57 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-17 11:57 Florian Westphal [this message]
2017-07-17 11:57 ` [PATCH net-next 01/10] drivers: net: add missing interrupt.h include Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 02/10] vti: revert flush x-netns xfrm cache when vti interface is removed Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 03/10] net: xfrm: revert to lower xfrm dst gc limit Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 04/10] xfrm_policy: bypass flow_cache_lookup Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 05/10] xfrm_policy: remove always true/false branches Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 06/10] xfrm_policy: kill flow to policy dir conversion Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 07/10] xfrm_policy: remove xfrm_policy_lookup Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 08/10] xfrm_policy: make xfrm_bundle_lookup return xfrm dst object Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 09/10] xfrm: remove flow cache Florian Westphal
2017-07-17 11:57 ` [PATCH net-next 10/10] xfrm: add xdst pcpu cache Florian Westphal
2017-07-18 18:15 ` [PATCH net-next 0/10] xfrm: remove flow cache David Miller
2018-06-12 19:42 ` Kristian Evensen
2018-06-13 12:40 ` Florian Westphal
2018-06-13 13:43 ` Kristian Evensen
2018-06-18 15:46 ` Kristian Evensen
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=20170717115727.26042-1-fw@strlen.de \
--to=fw@strlen.de \
--cc=ilant@mellanox.com \
--cc=netdev@vger.kernel.org \
--cc=steffen.klassert@secunet.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