android_kernel_xiaomi_sm8450/drivers/block
Ross Lagerwall 7c0b17679b xen/blkfront: Only check REQ_FUA for writes
[ Upstream commit b6ebaa8100090092aa602530d7e8316816d0c98d ]

The existing code silently converts read operations with the
REQ_FUA bit set into write-barrier operations. This results in data
loss as the backend scribbles zeroes over the data instead of returning
it.

While the REQ_FUA bit doesn't make sense on a read operation, at least
one well-known out-of-tree kernel module does set it and since it
results in data loss, let's be safe here and only look at REQ_FUA for
writes.

Signed-off-by: Ross Lagerwall <ross.lagerwall@citrix.com>
Acked-by: Juergen Gross <jgross@suse.com>
Link: https://lore.kernel.org/r/20230426164005.2213139-1-ross.lagerwall@citrix.com
Signed-off-by: Juergen Gross <jgross@suse.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-06-21 15:45:36 +02:00
..
aoe block: lift setting the readahead size into the block layer 2020-09-24 13:43:39 -06:00
drbd drbd: correctly submit flush bio on barrier 2023-05-17 11:48:18 +02:00
mtip32xx blk-mq: move failure injection out of blk_mq_complete_request 2020-06-24 09:15:57 -06:00
null_blk null_blk: Always check queue mode setting from configfs 2023-05-30 12:57:49 +01:00
paride paride/pcd: use bdev_check_media_change 2020-09-10 09:32:31 -06:00
rnbd block/rnbd: replace REQ_OP_FLUSH with REQ_OP_WRITE 2023-06-09 10:30:09 +02:00
rsxx block: rsxx: fix error return code of rsxx_pci_probe() 2021-03-17 17:06:33 +01:00
xen-blkback xen-blkback: Advertise feature-persistent as user requested 2022-09-08 11:11:39 +02:00
zram zram: do not lookup algorithm in backends table 2022-08-25 11:38:14 +02:00
amiflop.c amiflop: use bdev_check_media_change 2020-09-10 09:32:30 -06:00
ataflop.c ataflop: use bdev_check_media_change 2020-09-10 09:32:30 -06:00
brd.c brd: return 0/-error from brd_insert_page() 2023-03-11 16:39:59 +01:00
cryptoloop.c cryptoloop: add a deprecation warning 2021-09-08 08:49:01 +02:00
floppy.c floppy: use a statically allocated error counter 2022-05-25 09:17:51 +02:00
Kconfig remove the sx8 block driver 2023-06-14 11:09:30 +02:00
loop.c loop: loop_set_status_from_info() check before assignment 2023-03-11 16:40:14 +01:00
loop.h
Makefile remove the sx8 block driver 2023-06-14 11:09:30 +02:00
nbd.c nbd: Fix debugfs_create_dir error checking 2023-06-09 10:30:08 +02:00
pktcdvd.c pktcdvd: use blkdev_get_by_dev instead of open coding it 2020-09-23 10:43:19 -06:00
ps3disk.c ps3disk: use the default segment boundary 2020-05-19 00:10:35 +10:00
ps3vram.c block: move ->make_request_fn to struct block_device_operations 2020-07-01 07:27:24 -06:00
rbd_types.h libceph, rbd: replace zero-length array with flexible-array 2020-06-01 13:22:53 +02:00
rbd.c rbd: get snapshot context after exclusive lock is ensured to be held 2023-06-14 11:09:54 +02:00
skd_main.c skd_main: remove unused including <linux/version.h> 2020-10-17 08:11:14 -06:00
skd_s1120.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 497 2019-06-19 17:09:53 +02:00
sunvdc.c block: sunvdc: add check for mdesc_grab() returning NULL 2023-03-22 13:29:59 +01:00
swim3.c swim3: use bdev_check_media_changed 2020-09-10 09:32:31 -06:00
swim_asm.S treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
swim.c swim: simplify media change handling 2020-09-10 09:32:30 -06:00
umem.c umem: fix error return code in mm_pci_probe() 2021-03-30 14:31:50 +02:00
umem.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 348 2019-06-05 17:37:08 +02:00
virtio_blk.c virtio_blk: fix the discard_granularity and discard_alignment queue limits 2022-06-09 10:21:05 +02:00
xen-blkfront.c xen/blkfront: Only check REQ_FUA for writes 2023-06-21 15:45:36 +02:00
xsysace.c xsysace: use platform_get_resource() and platform_get_irq_optional() 2020-10-29 08:22:33 -06:00
z2ram.c mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00