aboutsummaryrefslogtreecommitdiffstats
path: root/block
diff options
context:
space:
mode:
Diffstat (limited to 'block')
-rw-r--r--block/blk-core.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/block/blk-core.c b/block/blk-core.c
index 2d053b584410..9e79a485e4f3 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -1075,8 +1075,15 @@ void init_request_from_bio(struct request *req, struct bio *bio)
1075 /* 1075 /*
1076 * inherit FAILFAST from bio (for read-ahead, and explicit FAILFAST) 1076 * inherit FAILFAST from bio (for read-ahead, and explicit FAILFAST)
1077 */ 1077 */
1078 if (bio_rw_ahead(bio) || bio_failfast(bio)) 1078 if (bio_rw_ahead(bio))
1079 req->cmd_flags |= REQ_FAILFAST; 1079 req->cmd_flags |= (REQ_FAILFAST_DEV | REQ_FAILFAST_TRANSPORT |
1080 REQ_FAILFAST_DRIVER);
1081 if (bio_failfast_dev(bio))
1082 req->cmd_flags |= REQ_FAILFAST_DEV;
1083 if (bio_failfast_transport(bio))
1084 req->cmd_flags |= REQ_FAILFAST_TRANSPORT;
1085 if (bio_failfast_driver(bio))
1086 req->cmd_flags |= REQ_FAILFAST_DRIVER;
1080 1087
1081 /* 1088 /*
1082 * REQ_BARRIER implies no merging, but lets make it explicit 1089 * REQ_BARRIER implies no merging, but lets make it explicit