mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Use bioq_takefirst()
This commit is contained in:
parent
1a31a6c3b2
commit
affa470653
1 changed files with 1 additions and 3 deletions
|
|
@ -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);
|
||||
|
|
|
|||
Loading…
Reference in a new issue