[rtems-libbsd commit] Widen ifnet_detach_sxlock coverage

Sebastian Huber sebh at rtems.org
Mon Jul 11 11:46:14 UTC 2022


Module:    rtems-libbsd
Branch:    6-freebsd-12
Commit:    ee823c1666d5bd23f3c28064f4c0a0cff363c434
Changeset: http://git.rtems.org/rtems-libbsd/commit/?id=ee823c1666d5bd23f3c28064f4c0a0cff363c434

Author:    Kristof Provost <kp at FreeBSD.org>
Date:      Mon Feb  8 10:04:27 2021 +0100

Widen ifnet_detach_sxlock coverage

Widen the ifnet_detach_sxlock to cover the entire vnet sysuninit code.
This ensures that we can't end up having the vnet_sysuninit free the UDP
pcb while the detach code is running and trying to purge the UDP pcb.

MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D28530

---

 rtemsbsd/include/machine/_kernel_if.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/rtemsbsd/include/machine/_kernel_if.h b/rtemsbsd/include/machine/_kernel_if.h
index 08086658..f89adc13 100644
--- a/rtemsbsd/include/machine/_kernel_if.h
+++ b/rtemsbsd/include/machine/_kernel_if.h
@@ -41,6 +41,8 @@ MALLOC_DECLARE(M_IFADDR);
 MALLOC_DECLARE(M_IFMADDR);
 #endif
 
+extern struct sx ifnet_detach_sxlock;
+
 #define	ifr_buffer	ifr_ifru.ifru_buffer	/* user supplied buffer with its length */
 #define	ifr_data	ifr_ifru.ifru_data	/* for use by interface */
 



More information about the vc mailing list