diff options
author | phk <phk@FreeBSD.org> | 2004-10-06 20:59:59 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2004-10-06 20:59:59 +0000 |
commit | c6a0a9edbf8d678f1fc908c8bb1921da3f48666e (patch) | |
tree | bd6b01787b8794fadc2fff6f43e1ce02a16804ed /sys/geom/geom_io.c | |
parent | ac5e347dc0c0ece8bf15c2b5371c4c5b9cc458b4 (diff) | |
download | FreeBSD-src-c6a0a9edbf8d678f1fc908c8bb1921da3f48666e.zip FreeBSD-src-c6a0a9edbf8d678f1fc908c8bb1921da3f48666e.tar.gz |
Don't set the BIO_ONQUEUE debugging flag until we actually put the bio
onto a queue. This made the ENOMEM handling an instant panic.
Diffstat (limited to 'sys/geom/geom_io.c')
-rw-r--r-- | sys/geom/geom_io.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/geom/geom_io.c b/sys/geom/geom_io.c index eb10b79..188d78f 100644 --- a/sys/geom/geom_io.c +++ b/sys/geom/geom_io.c @@ -313,7 +313,6 @@ g_io_deliver(struct bio *bp, int error) KASSERT(!(bp->bio_flags & BIO_ONQUEUE), ("Bio already on queue bp=%p", bp)); - bp->bio_flags |= BIO_ONQUEUE; /* * XXX: next two doesn't belong here @@ -334,6 +333,7 @@ g_io_deliver(struct bio *bp, int error) if (error != ENOMEM) { bp->bio_error = error; TAILQ_INSERT_TAIL(&g_bio_run_up.bio_queue, bp, bio_queue); + bp->bio_flags |= BIO_ONQUEUE; g_bio_run_up.bio_queue_length++; g_bioq_unlock(&g_bio_run_up); wakeup(&g_wait_up); |