Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 8badcb74 authored by Paolo Abeni's avatar Paolo Abeni Committed by Sean Tranchetti
Browse files

udp: implement complete book-keeping for encap_needed



The *encap_needed static keys are enabled by UDP tunnels
and several UDP encapsulations type, but they are never
turned off. This can cause unneeded overall performance
degradation for systems where such features are used
transiently.

This patch introduces complete book-keeping for such keys,
decreasing the usage at socket destruction time, if needed,
and avoiding that the same socket could increase the key
usage multiple times.

rfc v3 -> v1:
 - add socket lock around udp_tunnel_encap_enable()

rfc v2 -> rfc v3:
 - use udp_tunnel_encap_enable() in setsockopt()

Change-Id: I80c10f3c4974537e77ee995de95cf8c2463458c3
Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Git-repo: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git


Git-commit: 60fb9567bf30937e6bedfa939d7c8fd4ee6a1b1c
Signed-off-by: default avatarSean Tranchetti <stranche@codeaurora.org>
parent caf5f93c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment