[dm-devel] [PATCH 4/9] blk: Call unprep_fn from elv_abort_queue is available
Mike Anderson
andmike at linux.vnet.ibm.com
Tue May 4 03:37:03 UTC 2010
Call the unprep_fn for the queue if it has been set for requests that have
been prepped indicated by REQ_DONTPREP being set.
Signed-off-by: Mike Anderson <andmike at linux.vnet.ibm.com>
Cc: Jens Axobe <jens.axboe at oracle.com>
---
block/elevator.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/block/elevator.c b/block/elevator.c
index ac98008..1f1e942 100644
--- a/block/elevator.c
+++ b/block/elevator.c
@@ -817,8 +817,12 @@ void elv_abort_queue(struct request_queue *q)
list_splice_init(&q->queue_head, &list);
list_for_each_entry_safe(rq, tmp, &list, queuelist) {
- if (rq->cmd_flags & REQ_DONTPREP)
- continue;
+ if (rq->cmd_flags & REQ_DONTPREP) {
+ if (q->unprep_rq_fn)
+ q->unprep_rq_fn(q, rq);
+ else
+ continue;
+ }
rq->cmd_flags |= REQ_QUIET;
trace_block_rq_abort(q, rq);
/*
--
1.6.6.1
More information about the dm-devel
mailing list