diff options
author | mav <mav@FreeBSD.org> | 2015-10-02 20:09:16 +0000 |
---|---|---|
committer | mav <mav@FreeBSD.org> | 2015-10-02 20:09:16 +0000 |
commit | 507088a8fab790bee8f93abfb5379a7fb2b670af (patch) | |
tree | 75b6d2ece745c672600f5c6184cf238d043ab596 /sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c | |
parent | 70cfec0df3dc1ec235822bbbf269c83082cdc65c (diff) | |
download | FreeBSD-src-507088a8fab790bee8f93abfb5379a7fb2b670af.zip FreeBSD-src-507088a8fab790bee8f93abfb5379a7fb2b670af.tar.gz |
MFC r279996 (by smh): Allow zvol_geom_worker to process BIO_DELETE's
If zvol_geom_start is called with a BIO_DELETE from a thread which can
sleep it queues it for later processing by the zvol_geom_worker. The
zvol_geom_worker didn't have a delete case so would simply loose the bio
hence preventing the original caller from every completing. In addition
an other unknown types would suffer the same fate.
Allow zvol_geom_worker to process BIO_DELETE's via zvol_strategy and
return unsupported for all unknown bio types.
Diffstat (limited to 'sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c')
-rw-r--r-- | sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c index 234e13e..554fbd1 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c +++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c @@ -2776,8 +2776,12 @@ zvol_geom_worker(void *arg) break; case BIO_READ: case BIO_WRITE: + case BIO_DELETE: zvol_strategy(bp); break; + default: + g_io_deliver(bp, EOPNOTSUPP); + break; } } } |