Acquire Giant arounds calls into the linker from Netgraph sockets.

We now no longer hold Giant in send(), so it isn't inheritted by the
linker, which calls into VFS.

Reported by:	glebius
Discussed with:	glebius, bz
This commit is contained in:
Robert Watson 2004-08-30 14:41:25 +00:00
parent 74bf4e164b
commit c6bfdc5d32

View File

@ -300,7 +300,9 @@ printf("errx=%d\n",error);
/* Not found, try to load it as a loadable module */
snprintf(filename, sizeof(filename), "ng_%s", mkp->type);
mtx_lock(&Giant);
error = linker_load_module(NULL, filename, NULL, NULL, &lf);
mtx_unlock(&Giant);
if (error != 0) {
FREE(msg, M_NETGRAPH_MSG);
goto release;