diff options
author | jhb <jhb@FreeBSD.org> | 2002-04-04 21:03:38 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2002-04-04 21:03:38 +0000 |
commit | db9aa81e239bb1c46b3b7ba560474cd954b78bf3 (patch) | |
tree | f7344c6a10fdc020dd02fe2ee1f244cb56f92bb6 /sys/net/if.c | |
parent | 5b964d2945fa9a17daef9bc1e6dbbcb4f7154379 (diff) | |
download | FreeBSD-src-db9aa81e239bb1c46b3b7ba560474cd954b78bf3.zip FreeBSD-src-db9aa81e239bb1c46b3b7ba560474cd954b78bf3.tar.gz |
Change callers of mtx_init() to pass in an appropriate lock type name. In
most cases NULL is passed, but in some cases such as network driver locks
(which use the MTX_NETWORK_LOCK macro) and UMA zone locks, a name is used.
Tested on: i386, alpha, sparc64
Diffstat (limited to 'sys/net/if.c')
-rw-r--r-- | sys/net/if.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/net/if.c b/sys/net/if.c index 4b8573f..854a879 100644 --- a/sys/net/if.c +++ b/sys/net/if.c @@ -301,7 +301,8 @@ if_check(dummy) if (!mtx_initialized(&ifp->if_snd.ifq_mtx)) { printf("%s%d XXX: driver didn't initialize queue mtx\n", ifp->if_name, ifp->if_unit); - mtx_init(&ifp->if_snd.ifq_mtx, "unknown", MTX_DEF); + mtx_init(&ifp->if_snd.ifq_mtx, "unknown", + MTX_NETWORK_LOCK, MTX_DEF); } } splx(s); @@ -398,7 +399,7 @@ if_attach(ifp) make_dev_alias(ifdev_byindex(ifp->if_index), "%s%d", net_cdevsw.d_name, ifp->if_index); - mtx_init(&ifp->if_snd.ifq_mtx, ifp->if_name, MTX_DEF); + mtx_init(&ifp->if_snd.ifq_mtx, ifp->if_name, "if send queue", MTX_DEF); /* * create a Link Level name for this device |