diff mbox

[1/1] block: Minor blk_account_io_start usage cleanup

Message ID tc2y47ryy32.fsf@vmbox.dyndns.org (mailing list archive)
State New, archived
Headers show

Commit Message

Michael Callahan May 3, 2016, 3:12 p.m. UTC
blk_account_io_start does not need to be wrapped with blk_do_io_stat
ais it already checks for that condition.

Signed-off-by: Michael Callahan <michaelcallahan@fb.com>
---
This time for sure!

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

Comments

Jens Axboe May 3, 2016, 3:29 p.m. UTC | #1
On 05/03/2016 09:12 AM, Michael Callahan wrote:
> blk_account_io_start does not need to be wrapped with blk_do_io_stat
> ais it already checks for that condition.
>
> Signed-off-by: Michael Callahan <michaelcallahan@fb.com>

Looks good, applied for 4.7.
diff mbox

Patch

diff --git a/block/blk-mq.c b/block/blk-mq.c
index 1699baf..0c2ed83 100644
--- a/block/blk-mq.c
+++ b/block/blk-mq.c
@@ -1122,8 +1122,7 @@  static void blk_mq_bio_to_request(struct request *rq, struct bio *bio)
 {
 	init_request_from_bio(rq, bio);
 
-	if (blk_do_io_stat(rq))
-		blk_account_io_start(rq, 1);
+	blk_account_io_start(rq, 1);
 }
 
 static inline bool hctx_allow_merges(struct blk_mq_hw_ctx *hctx)