]> git.proxmox.com Git - mirror_zfs.git/commitdiff
Retire ZFS_TEARDOWN_TRY_ENTER_READ
authorMateusz Guzik <mjguzik@gmail.com>
Tue, 20 Sep 2022 22:34:41 +0000 (00:34 +0200)
committerGitHub <noreply@github.com>
Tue, 20 Sep 2022 22:34:41 +0000 (15:34 -0700)
There were never any users and it so happens the operation is not even
supported by rrm locks -- the macros were wrong for Linux and FreeBSD
when not using it's RMS locks.

Reviewed-by: Richard Yao <richard.yao@alumni.stonybrook.edu>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Mateusz Guzik <mjguzik@gmail.com>
Closes #13906

include/os/freebsd/zfs/sys/zfs_vfsops_os.h
include/os/linux/zfs/sys/zfs_vfsops_os.h

index c44f7c6f06b18f730f9330f4081d8c52715ca911..f765d38dbac8a7434f7e013a608235667337692f 100644 (file)
@@ -128,9 +128,6 @@ struct zfsvfs {
 #define        ZFS_TEARDOWN_DESTROY(zfsvfs)            \
        rms_destroy(&(zfsvfs)->z_teardown_lock)
 
-#define        ZFS_TEARDOWN_TRY_ENTER_READ(zfsvfs)     \
-       rms_try_rlock(&(zfsvfs)->z_teardown_lock)
-
 #define        ZFS_TEARDOWN_ENTER_READ(zfsvfs, tag)    \
        rms_rlock(&(zfsvfs)->z_teardown_lock);
 
@@ -161,9 +158,6 @@ struct zfsvfs {
 #define        ZFS_TEARDOWN_DESTROY(zfsvfs)            \
        rrm_destroy(&(zfsvfs)->z_teardown_lock)
 
-#define        ZFS_TEARDOWN_TRY_ENTER_READ(zfsvfs)     \
-       rw_tryenter(&(zfsvfs)->z_teardown_lock, RW_READER)
-
 #define        ZFS_TEARDOWN_ENTER_READ(zfsvfs, tag)    \
        rrm_enter_read(&(zfsvfs)->z_teardown_lock, tag);
 
index 697ae2018ec4fa47c7b6b26563cd479ffe5f71d1..e320b8de4222f296ceb529bbccef3279a30d03f1 100644 (file)
@@ -143,9 +143,6 @@ struct zfsvfs {
 #define        ZFS_TEARDOWN_DESTROY(zfsvfs)            \
        rrm_destroy(&(zfsvfs)->z_teardown_lock)
 
-#define        ZFS_TEARDOWN_TRY_ENTER_READ(zfsvfs)     \
-       rw_tryenter(&(zfsvfs)->z_teardown_lock, RW_READER)
-
 #define        ZFS_TEARDOWN_ENTER_READ(zfsvfs, tag)    \
        rrm_enter_read(&(zfsvfs)->z_teardown_lock, tag);