]> www.infradead.org Git - users/hch/block.git/commit
ubd: untagle discard vs write zeroes not support handling
authorChristoph Hellwig <hch@lst.de>
Thu, 30 May 2024 06:36:27 +0000 (08:36 +0200)
committerChristoph Hellwig <hch@lst.de>
Fri, 31 May 2024 05:50:07 +0000 (07:50 +0200)
commitf19e754b8f47f56864e7cae14f52e880557a52f3
treeca17e39d329158b0fe4af435962e97caa69f362e
parentdb3ce0b1f17cf88f806445c92993995099dc3e08
ubd: untagle discard vs write zeroes not support handling

Discard and Write Zeroes are different operation and implemented
by different fallocate opcodes for ubd.  If one fails the other one
can work and vice versa.

Split the code to disable the operations in ubd_handler to only
disable the operation that actually failed.

Fixes: 50109b5a03b4 ("um: Add support for DISCARD in the UBD Driver")
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
arch/um/drivers/ubd_kern.c