HomeFreeBSD

FreeBSD: Fix zvol_*_open() locking

Description

FreeBSD: Fix zvol_*_open() locking

These are the changes for FreeBSD corresponding to the changes made for
Linux in #12863, see that PR for details.

Changes from #12863 are applied for zvol_geom_open and zvol_cdev_open
on FreeBSD. This also adds a check for the zvol dying which we had
in zvol_geom_open but was missing in zvol_cdev_open. The check causes
the open to fail early with ENXIO when we are in the middle of changing
volmode.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Signed-off-by: Ryan Moeller <ryan@iXsystems.com>
Closes #12934

Details

Provenance
freqlabsAuthored on Dec 23 2021, 7:03 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Jan 14 2022, 8:43 PM
Parents
rG69c5e694a18c: FreeBSD: Fix leaked strings in libspl mnttab
Branches
Unknown
Tags
Unknown

Event Timeline