HomeFreeBSD

zfs_enter rework

Description

zfs_enter rework

Replace ZFS_ENTER and ZFS_VERIFY_ZP, which have hidden returns, with
functions that return error code. The reason we want to do this is
because hidden returns are not obvious and had caused some missing fail
path unwinding.

This patch changes the common, linux, and freebsd parts. Also fixes
fail path unwinding in zfs_fsync, zpl_fsync, zpl_xattr_{list,get,set}, and
zfs_lookup().

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Signed-off-by: Chunwei Chen <david.chen@nutanix.com>
Closes #13831

Details

Provenance
Chunwei Chen <tuxoko@gmail.com>Authored on Sep 16 2022, 8:36 PM
GitHub <noreply@github.com>Committed on Sep 16 2022, 8:36 PM
Parents
rGb24d1c77f7fc: Add zfs_btree_verify_intensity kernel module parameter
Branches
Unknown
Tags
Unknown

Event Timeline

GitHub <noreply@github.com> committed rG768eacedef54: zfs_enter rework (authored by Chunwei Chen <tuxoko@gmail.com>).Sep 16 2022, 8:36 PM