aboutsummaryrefslogtreecommitdiffstats
path: root/block
diff options
context:
space:
mode:
Diffstat (limited to 'block')
-rw-r--r--block/blk-core.c5
-rw-r--r--block/blk-exec.c1
2 files changed, 1 insertions, 5 deletions
diff --git a/block/blk-core.c b/block/blk-core.c
index 8b4a0af7d69f..7e0fab53e930 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -1082,16 +1082,13 @@ void init_request_from_bio(struct request *req, struct bio *bio)
1082 if (bio_failfast_driver(bio)) 1082 if (bio_failfast_driver(bio))
1083 req->cmd_flags |= REQ_FAILFAST_DRIVER; 1083 req->cmd_flags |= REQ_FAILFAST_DRIVER;
1084 1084
1085 /*
1086 * REQ_BARRIER implies no merging, but lets make it explicit
1087 */
1088 if (unlikely(bio_discard(bio))) { 1085 if (unlikely(bio_discard(bio))) {
1089 req->cmd_flags |= REQ_DISCARD; 1086 req->cmd_flags |= REQ_DISCARD;
1090 if (bio_barrier(bio)) 1087 if (bio_barrier(bio))
1091 req->cmd_flags |= REQ_SOFTBARRIER; 1088 req->cmd_flags |= REQ_SOFTBARRIER;
1092 req->q->prepare_discard_fn(req->q, req); 1089 req->q->prepare_discard_fn(req->q, req);
1093 } else if (unlikely(bio_barrier(bio))) 1090 } else if (unlikely(bio_barrier(bio)))
1094 req->cmd_flags |= (REQ_HARDBARRIER | REQ_NOMERGE); 1091 req->cmd_flags |= REQ_HARDBARRIER;
1095 1092
1096 if (bio_sync(bio)) 1093 if (bio_sync(bio))
1097 req->cmd_flags |= REQ_RW_SYNC; 1094 req->cmd_flags |= REQ_RW_SYNC;
diff --git a/block/blk-exec.c b/block/blk-exec.c
index 6af716d1e54e..49557e91f0da 100644
--- a/block/blk-exec.c
+++ b/block/blk-exec.c
@@ -51,7 +51,6 @@ void blk_execute_rq_nowait(struct request_queue *q, struct gendisk *bd_disk,
51 int where = at_head ? ELEVATOR_INSERT_FRONT : ELEVATOR_INSERT_BACK; 51 int where = at_head ? ELEVATOR_INSERT_FRONT : ELEVATOR_INSERT_BACK;
52 52
53 rq->rq_disk = bd_disk; 53 rq->rq_disk = bd_disk;
54 rq->cmd_flags |= REQ_NOMERGE;
55 rq->end_io = done; 54 rq->end_io = done;
56 WARN_ON(irqs_disabled()); 55 WARN_ON(irqs_disabled());
57 spin_lock_irq(q->queue_lock); 56 spin_lock_irq(q->queue_lock);