From ec6ba977b7d1ab7419a0d0e9a5cfdf428a1f61a1 Mon Sep 17 00:00:00 2001 From: Rob Norris Date: Sun, 4 Aug 2024 13:18:20 +1000 Subject: [PATCH] config: remove HAVE_3ARGS_VFS_GETATTR Sponsored-by: https://despairlabs.com/sponsor/ Reviewed-by: Brian Behlendorf Reviewed-by: Tony Hutter Reviewed-by: Tino Reichardt Signed-off-by: Rob Norris Closes #16479 --- config/kernel-vfs-getattr.m4 | 27 --------------------------- module/os/linux/spl/spl-generic.c | 2 -- module/os/linux/zfs/zfs_file_os.c | 2 -- 3 files changed, 31 deletions(-) diff --git a/config/kernel-vfs-getattr.m4 b/config/kernel-vfs-getattr.m4 index eb07853cc..1923d4ce8 100644 --- a/config/kernel-vfs-getattr.m4 +++ b/config/kernel-vfs-getattr.m4 @@ -48,39 +48,12 @@ AC_DEFUN([ZFS_AC_KERNEL_VFS_GETATTR_2ARGS], [ ]) ]) -dnl # -dnl # <3.9 API -dnl # vfs_getattr(struct vfsmount *v, struct dentry *d, struct kstat *k) -dnl # -AC_DEFUN([ZFS_AC_KERNEL_SRC_VFS_GETATTR_3ARGS], [ - ZFS_LINUX_TEST_SRC([vfs_getattr_3args], [ - #include - ],[ - vfs_getattr((struct vfsmount *)NULL, - (struct dentry *)NULL, - (struct kstat *)NULL); - ]) -]) - -AC_DEFUN([ZFS_AC_KERNEL_VFS_GETATTR_3ARGS], [ - AC_MSG_CHECKING([whether vfs_getattr() wants 3 args]) - ZFS_LINUX_TEST_RESULT([vfs_getattr_3args], [ - AC_MSG_RESULT(yes) - AC_DEFINE(HAVE_3ARGS_VFS_GETATTR, 1, - [vfs_getattr wants 3 args]) - ],[ - AC_MSG_RESULT(no) - ]) -]) - AC_DEFUN([ZFS_AC_KERNEL_SRC_VFS_GETATTR], [ ZFS_AC_KERNEL_SRC_VFS_GETATTR_4ARGS ZFS_AC_KERNEL_SRC_VFS_GETATTR_2ARGS - ZFS_AC_KERNEL_SRC_VFS_GETATTR_3ARGS ]) AC_DEFUN([ZFS_AC_KERNEL_VFS_GETATTR], [ ZFS_AC_KERNEL_VFS_GETATTR_4ARGS ZFS_AC_KERNEL_VFS_GETATTR_2ARGS - ZFS_AC_KERNEL_VFS_GETATTR_3ARGS ]) diff --git a/module/os/linux/spl/spl-generic.c b/module/os/linux/spl/spl-generic.c index 6ee0236d2..4221e0f2c 100644 --- a/module/os/linux/spl/spl-generic.c +++ b/module/os/linux/spl/spl-generic.c @@ -656,8 +656,6 @@ spl_getattr(struct file *filp, struct kstat *stat) AT_STATX_SYNC_AS_STAT); #elif defined(HAVE_2ARGS_VFS_GETATTR) rc = vfs_getattr(&filp->f_path, stat); -#elif defined(HAVE_3ARGS_VFS_GETATTR) - rc = vfs_getattr(filp->f_path.mnt, filp->f_dentry, stat); #else #error "No available vfs_getattr()" #endif diff --git a/module/os/linux/zfs/zfs_file_os.c b/module/os/linux/zfs/zfs_file_os.c index bc753614b..32e71bf37 100644 --- a/module/os/linux/zfs/zfs_file_os.c +++ b/module/os/linux/zfs/zfs_file_os.c @@ -279,8 +279,6 @@ zfs_file_getattr(zfs_file_t *filp, zfs_file_attr_t *zfattr) AT_STATX_SYNC_AS_STAT); #elif defined(HAVE_2ARGS_VFS_GETATTR) rc = vfs_getattr(&filp->f_path, &stat); -#elif defined(HAVE_3ARGS_VFS_GETATTR) - rc = vfs_getattr(filp->f_path.mnt, filp->f_dentry, &stat); #else #error "No available vfs_getattr()" #endif