HomeFreeBSD

FreeBSD: Clean up zfsdev_close to match Linux

Description

FreeBSD: Clean up zfsdev_close to match Linux

Resolve some oddities in zfsdev_close() which could result in a
panic and were not present in the equivalent function for Linux.

  • Remove unused definition ZFS_MIN_MINOR
  • FreeBSD: Simplify zfsdev state destruction
  • Assert zs_minor is valid in zfsdev_close
  • Make locking around zfsdev state match Linux

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

Details

Provenance
freqlabsAuthored on Mar 13 2021, 12:09 AM
GitHub <noreply@github.com>Committed on Mar 13 2021, 12:09 AM
Parents
rGe3e82dcc5155: FreeBSD: switch teardown lock to rms
Branches
Unknown
Tags
Unknown