hc
2024-05-14 bedbef8ad3e75a304af6361af235302bcc61d06b
kernel/drivers/block/xen-blkfront.c
....@@ -792,7 +792,8 @@
792792 ring_req->u.rw.handle = info->handle;
793793 ring_req->operation = rq_data_dir(req) ?
794794 BLKIF_OP_WRITE : BLKIF_OP_READ;
795
- if (req_op(req) == REQ_OP_FLUSH || req->cmd_flags & REQ_FUA) {
795
+ if (req_op(req) == REQ_OP_FLUSH ||
796
+ (req_op(req) == REQ_OP_WRITE && (req->cmd_flags & REQ_FUA))) {
796797 /*
797798 * Ideally we can do an unordered flush-to-disk.
798799 * In case the backend onlysupports barriers, use that.