Darrick J. Wong
1fca505614
loop: fix no-unmap write-zeroes request behavior
...
[ Upstream commit efcfec579f6139528c9e6925eca2bc4a36da65c6 ]
Currently, if the loop device receives a WRITE_ZEROES request, it asks
the underlying filesystem to punch out the range. This behavior is
correct if unmapping is allowed. However, a NOUNMAP request means that
the caller doesn't want us to free the storage backing the range, so
punching out the range is incorrect behavior.
To satisfy a NOUNMAP | WRITE_ZEROES request, loop should ask the
underlying filesystem to FALLOC_FL_ZERO_RANGE, which is (according to
the fallocate documentation) required to ensure that the entire range is
backed by real storage, which suffices for our purposes.
Fixes: 19372e2769 ("loop: implement REQ_OP_WRITE_ZEROES")
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-12-31 16:44:31 +01:00
..
aoe
block: aoe: Fix kernel crash due to atomic sleep when exiting
2019-08-08 07:29:02 -06:00
drbd
block: drbd: remove a stray unlock in __drbd_send_protocol()
2019-11-08 06:55:22 -07:00
mtip32xx
block: mtip32xx: Remove call to memset after dma_alloc_coherent
2019-06-29 09:42:50 -06:00
paride
paride/pcd: need to check if cd->disk is null in pcd_detect
2019-09-04 07:04:37 -06:00
rsxx
rsxx: add missed destroy_workqueue calls in remove
2019-11-14 13:59:49 -07:00
xen-blkback
xen/blkback: fix memory leaks
2019-08-12 08:18:37 -06:00
zram
zram: fix race between backing_dev_show and backing_dev_store
2019-10-19 06:32:32 -04:00
amiflop.c
treewide: Add SPDX license identifier for more missed files
2019-05-21 10:50:45 +02:00
ataflop.c
ataflop: Mark expected switch fall-through
2019-07-29 15:24:58 -06:00
brd.c
treewide: Add SPDX license identifier for more missed files
2019-05-21 10:50:45 +02:00
cryptoloop.c
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 30
2019-05-24 17:27:10 +02:00
floppy.c
floppy: fix usercopy direction
2019-08-09 07:41:36 -06:00
Kconfig
docs: blockdev: add it to the admin-guide
2019-07-15 11:03:01 -03:00
loop.c
loop: fix no-unmap write-zeroes request behavior
2019-12-31 16:44:31 +01:00
loop.h
Makefile
nbd.c
nbd: prevent memory leak
2019-11-29 10:09:47 +01:00
null_blk.h
null_blk: format pr_* logs with pr_fmt
2019-09-16 08:38:29 -06:00
null_blk_main.c
null_blk: format pr_* logs with pr_fmt
2019-09-16 08:38:29 -06:00
null_blk_zoned.c
null_blk: Fix zoned command return code
2019-10-09 21:00:20 -06:00
pktcdvd.c
pktcdvd: remove warning on attempting to register non-passthrough dev
2019-09-22 10:01:05 -06:00
ps3disk.c
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 164
2019-05-30 11:26:38 -07:00
ps3vram.c
block/ps3vram: Use %llu to format sector_t after LBDAF removal
2019-06-13 03:17:50 -06:00
rbd.c
rbd: silence bogus uninitialized warning in rbd_object_map_update_finish()
2019-11-14 19:00:53 +01:00
rbd_types.h
rbd: support for object-map and fast-diff
2019-07-08 14:01:45 +02:00
skd_main.c
Linux 5.2-rc6
2019-07-01 08:16:08 -06:00
skd_s1120.h
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 497
2019-06-19 17:09:53 +02:00
sunvdc.c
treewide: Add SPDX license identifier for more missed files
2019-05-21 10:50:45 +02:00
swim.c
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152
2019-05-30 11:26:32 -07:00
swim3.c
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152
2019-05-30 11:26:32 -07:00
swim_asm.S
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152
2019-05-30 11:26:32 -07:00
sx8.c
umem.c
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 349
2019-06-05 17:37:08 +02:00
umem.h
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 348
2019-06-05 17:37:08 +02:00
virtio_blk.c
treewide: Add SPDX license identifier for more missed files
2019-05-21 10:50:45 +02:00
xen-blkfront.c
xen-blkfront: switch kcalloc to kvcalloc for large array allocation
2019-06-03 22:16:19 -04:00
xsysace.c
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500
2019-06-19 17:09:55 +02:00
z2ram.c