diff options
author | James Chapman <jchapman@katalix.com> | 2024-06-20 12:22:39 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2024-06-21 11:33:33 +0100 |
commit | 2a3339f6c9636aa39f2493865e4664df1ef2baed (patch) | |
tree | 26a15f56b6328b138e00f322fe479afbaf488354 /tools/perf/scripts/python/task-analyzer.py | |
parent | aa5e17e1f5ecb68d3f67a069f7345dbf1a8f274f (diff) |
l2tp: store l2tpv2 sessions in per-net IDR
L2TPv2 sessions are currently kept in a per-tunnel hashlist, keyed by
16-bit session_id. When handling received L2TPv2 packets, we need to
first derive the tunnel using the 16-bit tunnel_id or sock, then
lookup the session in a per-tunnel hlist using the 16-bit session_id.
We want to avoid using sk_user_data in the datapath and double lookups
on every packet. So instead, use a per-net IDR to hold L2TPv2
sessions, keyed by a 32-bit value derived from the 16-bit tunnel_id
and session_id. This will allow the L2TPv2 UDP receive datapath to
lookup a session with a single lookup without deriving the tunnel
first.
L2TPv2 sessions are held in their own IDR to avoid potential
key collisions with L2TPv3 sessions.
Signed-off-by: James Chapman <jchapman@katalix.com>
Reviewed-by: Tom Parkin <tparkin@katalix.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf/scripts/python/task-analyzer.py')
0 files changed, 0 insertions, 0 deletions