summaryrefslogtreecommitdiffstats
path: root/sys/dev/md
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2004-09-07 07:54:45 +0000
committerphk <phk@FreeBSD.org>2004-09-07 07:54:45 +0000
commitfb5fe8618b5719321cb72a6362cc4090ea5e154f (patch)
tree733c2f8be8e2e15bb4e229acf85269ad2c308690 /sys/dev/md
parent71485468ce02f55e15d51aa1bc88ccf15b41eeb7 (diff)
downloadFreeBSD-src-fb5fe8618b5719321cb72a6362cc4090ea5e154f.zip
FreeBSD-src-fb5fe8618b5719321cb72a6362cc4090ea5e154f.tar.gz
Use bioq_takefirst()
Diffstat (limited to 'sys/dev/md')
-rw-r--r--sys/dev/md/md.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/sys/dev/md/md.c b/sys/dev/md/md.c
index 607c492..e18dd10 100644
--- a/sys/dev/md/md.c
+++ b/sys/dev/md/md.c
@@ -619,9 +619,7 @@ md_kthread(void *arg)
for (;;) {
mtx_lock(&sc->queue_mtx);
- bp = bioq_first(&sc->bio_queue);
- if (bp)
- bioq_remove(&sc->bio_queue, bp);
+ bp = bioq_takefirst(&sc->bio_queue);
if (!bp) {
if (sc->flags & MD_SHUTDOWN) {
mtx_unlock(&sc->queue_mtx);
OpenPOWER on IntegriCloud