1dnl # 2dnl # 5.12 API 3dnl # 4dnl # generic_fillattr in linux/fs.h now requires a struct user_namespace* 5dnl # as the first arg, to support idmapped mounts. 6dnl # 7dnl # 6.3 API 8dnl # generic_fillattr() now takes struct mnt_idmap* as the first argument 9dnl # 10AC_DEFUN([ZFS_AC_KERNEL_SRC_GENERIC_FILLATTR], [ 11 ZFS_LINUX_TEST_SRC([generic_fillattr_userns], [ 12 #include <linux/fs.h> 13 ],[ 14 struct user_namespace *userns = NULL; 15 struct inode *in = NULL; 16 struct kstat *k = NULL; 17 generic_fillattr(userns, in, k); 18 ]) 19 20 ZFS_LINUX_TEST_SRC([generic_fillattr_mnt_idmap], [ 21 #include <linux/fs.h> 22 ],[ 23 struct mnt_idmap *idmap = NULL; 24 struct inode *in = NULL; 25 struct kstat *k = NULL; 26 generic_fillattr(idmap, in, k); 27 ]) 28]) 29 30AC_DEFUN([ZFS_AC_KERNEL_GENERIC_FILLATTR], [ 31 AC_MSG_CHECKING([whether generic_fillattr requires struct mnt_idmap*]) 32 ZFS_LINUX_TEST_RESULT([generic_fillattr_mnt_idmap], [ 33 AC_MSG_RESULT([yes]) 34 AC_DEFINE(HAVE_GENERIC_FILLATTR_IDMAP, 1, 35 [generic_fillattr requires struct mnt_idmap*]) 36 ],[ 37 AC_MSG_CHECKING([whether generic_fillattr requires struct user_namespace*]) 38 ZFS_LINUX_TEST_RESULT([generic_fillattr_userns], [ 39 AC_MSG_RESULT([yes]) 40 AC_DEFINE(HAVE_GENERIC_FILLATTR_USERNS, 1, 41 [generic_fillattr requires struct user_namespace*]) 42 ],[ 43 AC_MSG_RESULT([no]) 44 ]) 45 ]) 46]) 47 48