K 10 svn:author V 2 kp K 8 svn:date V 27 2022-02-28T15:40:29.490781Z K 7 svn:log V 862 netinet: allow UDP tunnels to be removed udp_set_kernel_tunneling() rejects new callbacks if one is already set. Allow callbacks to be cleared. The use case for this is OpenVPN DCO, where the socket is opened by userspace and then adopted by the kernel to run the tunnel. If the DCO interface is removed but userspace does not close the socket (something the kernel cannot prevent) the installed callbacks could be called with an invalidated context. Allow new functions to be set, but only if they're NULL (i.e. allow the callback functions to be cleared). Reviewed by: tuexen MFC after: 3 weeks Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D34288 (cherry picked from commit 995cba5a0c9659e623b910429222ac2831a2ecca) Git Hash: 2af412767144ecaaef970c10a146209e521d3dca Git Author: kp@FreeBSD.org END