diff options
author | Jens Axboe <jens.axboe@oracle.com> | 2009-01-13 09:28:32 -0500 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2009-01-30 06:34:37 -0500 |
commit | cec0707e40ae25794b5a2de7b7f03c51961f80d9 (patch) | |
tree | 85975a5b68ebf20bdb54b01846484fbc4b2c6455 /block | |
parent | dbdac9b71dff5d27885f82eb2cfca310861fdf9e (diff) |
block: silently error an unsupported barrier bio
This fixes a "regression" from 2.6.28, where the barrier probes that file
systems may do would trigger additional end request warnings in dmesg.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'block')
-rw-r--r-- | block/blk-core.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/block/blk-core.c b/block/blk-core.c index 9e2e86fb78b8..ae75c047f45d 100644 --- a/block/blk-core.c +++ b/block/blk-core.c | |||
@@ -1451,6 +1451,11 @@ static inline void __generic_make_request(struct bio *bio) | |||
1451 | err = -EOPNOTSUPP; | 1451 | err = -EOPNOTSUPP; |
1452 | goto end_io; | 1452 | goto end_io; |
1453 | } | 1453 | } |
1454 | if (bio_barrier(bio) && bio_has_data(bio) && | ||
1455 | (q->next_ordered == QUEUE_ORDERED_NONE)) { | ||
1456 | err = -EOPNOTSUPP; | ||
1457 | goto end_io; | ||
1458 | } | ||
1454 | 1459 | ||
1455 | ret = q->make_request_fn(q, bio); | 1460 | ret = q->make_request_fn(q, bio); |
1456 | } while (ret); | 1461 | } while (ret); |