]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Disable TRIM on file backed ZFS vdevs and fix TRIM on init
authorsmh <smh@FreeBSD.org>
Mon, 17 Nov 2014 11:32:10 +0000 (11:32 +0000)
committersmh <smh@FreeBSD.org>
Mon, 17 Nov 2014 11:32:10 +0000 (11:32 +0000)
commitb64d4776338be812cd3f78366063179f4a742828
treed9bdcb2f9b26bb79d6c713bb6ef5b0c0d625b937
parent886f75286d5765de95a263f2952476fad86f73b3
Disable TRIM on file backed ZFS vdevs and fix TRIM on init

After r265152 TRIM requests are ZIO_TYPE_FREE instead of ZIO_TYPE_IOCTL
this meant file backed vdevs to attempted to process the ZIO as a write
causing a panic.

We now disable TRIM on file backed vdevs and ASSERT the ZIO types supported
by each vdev type to ensure we explicity support the ZIO type being
processed.

Also ensure that TRIM on init is not procesed for devices which declare they
didn't support TRIM via vdev_notrim.

PR: 195061, 194976, 191573
Sponsored by: Multiplay
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/trim_map.c
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev_disk.c
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev_file.c
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev_geom.c
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev_label.c