flush: only detect lack of flush support in one place
commit46e06fededd42ff4d6fe2dfe0b60612f609edf0b
authorRob Norris <rob.norris@klarasystems.com>
Mon, 1 Jul 2024 01:19:16 +0000 (1 11:19 +1000)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Fri, 13 Dec 2024 20:19:54 +0000 (13 12:19 -0800)
tree9ecc350352f0e5574842247a2d610bd872ff30d9
parentfbea92432a4664786ff6a9f2f59bb82b6c5f0b84
flush: only detect lack of flush support in one place

It seems there's no good reason for vdev_disk & vdev_geom to explicitly
detect no support for flush and set vdev_nowritecache.  Instead, just
signal it by setting the error to ENOTSUP, and let zio_vdev_io_assess()
take care of it in one place.

Sponsored-by: Klara, Inc.
Sponsored-by: Wasabi Technology, Inc.
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Signed-off-by: Rob Norris <rob.norris@klarasystems.com>
Closes #16855
module/os/freebsd/zfs/vdev_geom.c
module/os/linux/zfs/vdev_disk.c
module/zfs/zio.c