[PATCH 7/9] blk: Mark requests aborted

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mark requests aborted using blk_mark_rq_aborted to assist lower levels in
identifying aborted requests.

Signed-off-by: Mike Anderson <andmike@xxxxxxxxxxxxxxxxxx>
Cc: Jens Axobe <jens.axboe@xxxxxxxxxx>
---
 block/blk-timeout.c |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/block/blk-timeout.c b/block/blk-timeout.c
index ad45b44..d8610c1 100644
--- a/block/blk-timeout.c
+++ b/block/blk-timeout.c
@@ -229,9 +229,17 @@ void blk_abort_queue(struct request_queue *q)
 	 */
 	list_splice_init(&q->timeout_list, &list);
 
-	list_for_each_entry_safe(rq, tmp, &list, timeout_list)
+	list_for_each_entry_safe(rq, tmp, &list, timeout_list) {
+                /*
+                 * Mark all requests even if we are unable to abort. The
+                 * aborted flag can used by lower levels to indicate that
+                 * the request should finished as soon as possible.
+                 */
+		blk_mark_rq_aborted(rq);
+
 		if (!blk_queue_stopped(q))
 			blk_abort_request(rq);
+	}
 
 	/*
 	 * Occasionally, blk_abort_request() will return without
-- 
1.6.6.1

--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux