Date: Tue, 30 Nov 2004 22:28:50 +0000 (UTC) From: Max Laier <mlaier@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/netgraph ng_socket.csrc/sys/netgraph/bluetooth/socket ng_btsocket.c Message-ID: <200411302228.iAUMSoQC028699@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
mlaier 2004-11-30 22:28:50 UTC
FreeBSD src repository
Modified files:
sys/netgraph ng_socket.c
sys/netgraph/bluetooth/socket ng_btsocket.c
Log:
Move ng_socket and ng_btsocket initialization to SI_SUB_PROTO_DOMAIN as they
call net_add_domain(). Calling this function too early (or late) breaks
assertations about the global domains list.
Actually it should be forbidden to call net_add_domain() outside of
SI_SUB_PROTO_DOMAIN completely as there are many places where we traverse
the domains list unprotected, but for now we allow late calls (mostly to
support netgraph). In order to really fix this we have to lock the domains
list in all places or find another way to ensure that we can safely walk the
list while another thread might be adding a new domain.
Spotted by: se
Reviewed by: julian, glebius
PR: kern/73321 (partly)
Revision Changes Path
1.9 +2 -1 src/sys/netgraph/bluetooth/socket/ng_btsocket.c
1.56 +1 -1 src/sys/netgraph/ng_socket.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200411302228.iAUMSoQC028699>
