summaryrefslogtreecommitdiffstats
path: root/block/blk-timeout.c
diff options
context:
space:
mode:
authorJens Axboe <jens.axboe@oracle.com>2009-04-17 08:36:50 +0200
committerJens Axboe <jens.axboe@oracle.com>2009-04-22 08:35:10 +0200
commitb759113499d6c7cb75fab04f56772579308bc0f8 (patch)
treed36a0ea295f675bd678ee30e8191c0358cfc5b74 /block/blk-timeout.c
parent71982a409f12c50d011325a4471aa20666bb908d (diff)
block: make blk_abort_queue() ignore non-request based devices
There's nothing to do for those devices, since the timeout handling is based on requests. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'block/blk-timeout.c')
-rw-r--r--block/blk-timeout.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/block/blk-timeout.c b/block/blk-timeout.c
index bbbdc4b8ccf..8f570c4c80e 100644
--- a/block/blk-timeout.c
+++ b/block/blk-timeout.c
@@ -211,6 +211,12 @@ void blk_abort_queue(struct request_queue *q)
struct request *rq, *tmp;
LIST_HEAD(list);
+ /*
+ * Not a request based block device, nothing to abort
+ */
+ if (!q->request_fn)
+ return;
+
spin_lock_irqsave(q->queue_lock, flags);
elv_abort_queue(q);