summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortruckman <truckman@FreeBSD.org>2003-12-07 21:53:41 +0000
committertruckman <truckman@FreeBSD.org>2003-12-07 21:53:41 +0000
commite9a439edcd2a226a8a04d87f426d17f839b1afbc (patch)
tree76f07437415fc153dfc7d2433a8bf221afab16e1
parentf472357a27642db6d335217d107fd3d7ce83b52d (diff)
downloadFreeBSD-src-e9a439edcd2a226a8a04d87f426d17f839b1afbc.zip
FreeBSD-src-e9a439edcd2a226a8a04d87f426d17f839b1afbc.tar.gz
Pass MTX_DEF as the last argument to mtx_init() instead of 0. This
is not a functional change. The code happened to work properly only because MTX_DEF is defined as 0.
-rw-r--r--sys/kern/subr_mbpool.c2
-rw-r--r--sys/kern/subr_mbuf.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/subr_mbpool.c b/sys/kern/subr_mbpool.c
index 02c25e8..9ca5199 100644
--- a/sys/kern/subr_mbpool.c
+++ b/sys/kern/subr_mbpool.c
@@ -138,7 +138,7 @@ mbp_create(struct mbpool **pp, const char *name, bus_dma_tag_t dmat,
(*pp)->nchunks = nchunks;
SLIST_INIT(&(*pp)->free_list);
- mtx_init(&(*pp)->free_lock, name, NULL, 0);
+ mtx_init(&(*pp)->free_lock, name, NULL, MTX_DEF);
return (0);
}
diff --git a/sys/kern/subr_mbuf.c b/sys/kern/subr_mbuf.c
index cb930a2..2743cb7 100644
--- a/sys/kern/subr_mbuf.c
+++ b/sys/kern/subr_mbuf.c
@@ -426,7 +426,7 @@ mbuf_init(void *dummy)
/*
* Initialize condition variables and general container mutex locks.
*/
- mtx_init(&mbuf_gen, "mbuf subsystem general lists lock", NULL, 0);
+ mtx_init(&mbuf_gen, "mbuf subsystem general lists lock", NULL, MTX_DEF);
cv_init(&(mb_list_mbuf.ml_genlist->mgl_mstarved), "mbuf pool starved");
cv_init(&(mb_list_clust.ml_genlist->mgl_mstarved),
"mcluster pool starved");
@@ -491,7 +491,7 @@ mbuf_init(void *dummy)
(mb_list_clust.ml_cntlst[i] == NULL))
goto bad;
- mtx_init(&mbuf_pcpu[i], "mbuf PCPU list lock", NULL, 0);
+ mtx_init(&mbuf_pcpu[i], "mbuf PCPU list lock", NULL, MTX_DEF);
mb_list_mbuf.ml_cntlst[i]->mb_cont.mc_lock =
mb_list_clust.ml_cntlst[i]->mb_cont.mc_lock = &mbuf_pcpu[i];
OpenPOWER on IntegriCloud