X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lustre%2Fautoconf%2Flustre-core.m4;h=09e256a1aa03018cf202491897b52540e0a401f4;hp=af03b84c77c7f854c0fe078a442424aacc12ad24;hb=f55fdfff5dede69e6674999fb02c1add513704f0;hpb=a7d68d9f32abb85d3e01d184292ba6f10c774704 diff --git a/lustre/autoconf/lustre-core.m4 b/lustre/autoconf/lustre-core.m4 index af03b84..09e256a 100644 --- a/lustre/autoconf/lustre-core.m4 +++ b/lustre/autoconf/lustre-core.m4 @@ -393,6 +393,13 @@ No openssl-devel headers found, unable to build l_getsepol and SELinux status ch AC_MSG_RESULT([$enable_getsepol]) ]) # LC_OPENSSL_GETSEPOL +# LC_HAVE_LIBAIO +AC_DEFUN([LC_HAVE_LIBAIO], [ + AC_CHECK_HEADER([libaio.h], + enable_libaio="yes", + AC_MSG_WARN([libaio is not installed in the system])) +]) # LC_HAVE_LIBAIO + AC_DEFUN([LC_HAVE_PROJECT_QUOTA], [ LB_CHECK_COMPILE([if get_projid exists], get_projid, [ @@ -989,6 +996,23 @@ aio_complete, [ ]) # LC_HAVE_AIO_COMPLETE # +# LC_HAVE_IS_ROOT_INODE +# +# 3.19 kernel adds is_root_inode() +# Commit a7400222e3eb ("new helper: is_root_inode()") +# +AC_DEFUN([LC_HAVE_IS_ROOT_INODE], [ +LB_CHECK_COMPILE([if kernel has is_root_inode() ], +is_root_inode, [ + #include +],[ + is_root_inode(NULL); +],[ + AC_DEFINE(HAVE_IS_ROOT_INODE, 1, [is_root_inode defined]) +]) +]) # LC_HAVE_IS_ROOT_INODE + +# # LC_BACKING_DEV_INFO_REMOVAL # # 3.20 kernel removed backing_dev_info from address_space @@ -1136,6 +1160,24 @@ account_page_dirtied, [ ]) # LC_ACCOUNT_PAGE_DIRTIED_3ARGS # +# LC_HAVE_CRYPTO_ALLOC_SKCIPHER +# +# Kernel version 4.12 commit 7a7ffe65c8c5 +# introduced crypto_alloc_skcipher(). +# +AC_DEFUN([LC_HAVE_CRYPTO_ALLOC_SKCIPHER], [ +LB_CHECK_COMPILE([if crypto_alloc_skcipher is defined], +crypto_alloc_skcipher, [ + #include +],[ + crypto_alloc_skcipher(NULL, 0, 0); +],[ + AC_DEFINE(HAVE_CRYPTO_ALLOC_SKCIPHER, 1, + [crypto_alloc_skcipher is defined]) +]) +]) # LC_HAVE_CRYPTO_ALLOC_SKCIPHER + +# # LC_HAVE_INTERVAL_EXP_BLK_INTEGRITY # # 4.3 replace interval with interval_exp in 'struct blk_integrity' @@ -1280,8 +1322,7 @@ LB_CHECK_COMPILE([if kernel has clean_bdev_aliases], have_clean_bdev_aliases, [ #include ],[ - struct block_device bdev; - clean_bdev_aliases(&bdev,1,1); + clean_bdev_aliases(NULL,1,1); ], [ AC_DEFINE(HAVE_CLEAN_BDEV_ALIASES, 1, [kernel has clean_bdev_aliases]) @@ -1540,6 +1581,19 @@ fop_iterate_shared, [ ]) # LC_FOP_ITERATE_SHARED # +# LC_EXPORT_DEFAULT_FILE_SPLICE_READ +# +# 4.8-rc8 commit 82c156f853840645604acd7c2cebcb75ed1b6652 switched +# generic_file_splice_read() to using ->read_iter. We can test this +# change since default_file_splice_read() is no longer exported. +# +AC_DEFUN([LC_EXPORT_DEFAULT_FILE_SPLICE_READ], [ +LB_CHECK_EXPORT([default_file_splice_read], [fs/splice.c], + [AC_DEFINE(HAVE_DEFAULT_FILE_SPLICE_READ_EXPORT, 1, + [default_file_splice_read is exported])]) +]) # LC_EXPORT_DEFAULT_FILE_SPLCE_READ + +# # LC_HAVE_POSIX_ACL_VALID_USER_NS # # 4.8 posix_acl_valid takes struct user_namespace @@ -1935,6 +1989,33 @@ bi_bdev, [ ]) # LC_BI_BDEV # +# LC_INTERVAL_TREE_CACHED +# +# 4.14 f808c13fd3738948e10196496959871130612b61 +# switched INTERVAL_TREE_DEFINE to use cached RB_Trees. +# +AC_DEFUN([LC_INTERVAL_TREE_CACHED], [ +tmp_flags="$EXTRA_KCFLAGS" +EXTRA_KCFLAGS="-Werror" +LB_CHECK_COMPILE([if interval_trees use rb_tree_cached], +itree_cached, [ + #include + struct foo { struct rb_node rb; int last; int a,b;}; + #define START(n) ((n)->a) + #define LAST(n) ((n)->b) + struct rb_root_cached tree; + INTERVAL_TREE_DEFINE(struct foo, rb, int, last, + START, LAST, , foo); +],[ + foo_insert(NULL, &tree); +],[ + AC_DEFINE(HAVE_INTERVAL_TREE_CACHED, 1, + [interval trees use rb_tree_cached]) +]) +EXTRA_KCFLAGS="$tmp_flags" +]) # LC_INTERVAL_TREE_CACHED + +# # LC_IS_ENCRYPTED # # 4.14 introduced IS_ENCRYPTED and S_ENCRYPTED @@ -1990,6 +2071,27 @@ vm_fault_t, [ ]) # LC_VM_FAULT_T # +# LC_VM_FAULT_RETRY +# +# kernel 4.17 commit 3d3539018d2cbd12e5af4a132636ee7fd8d43ef0 +# mm: VM_FAULT_RETRY is defined in enum vm_fault_reason +# +AC_DEFUN([LC_VM_FAULT_RETRY], [ +LB_CHECK_COMPILE([if VM_FAULT_RETRY is defined], +VM_FAULT_RETRY, [ + #include +],[ + #ifndef VM_FAULT_RETRY + vm_fault_t x; + x = VM_FAULT_RETRY; + #endif +],[ + AC_DEFINE(HAVE_VM_FAULT_RETRY, 1, + [if VM_FAULT_RETRY is defined]) +]) +]) # LC_VM_FAULT_RETRY + +# # LC_INODE_TIMESPEC64 # # kernel 4.17-rc7 commit 8efd6894ff089adeeac7cb9f32125b85d963d1bc @@ -2230,7 +2332,13 @@ fscrypt_support, [ ],[ fscrypt_ioctl_get_policy_ex(NULL, NULL); ],[ - has_fscrypt_support="yes" + dnl When Lustre supports file name encryption, restore "yes" value + dnl for has_fscrypt_support and remove warning message. + has_fscrypt_support="no" + AC_MSG_WARN([ +This version of Lustre lacks file name encryption support, +so it cannot make use of in-kernel fscrypt. +Will use embedded llcrypt if possible.]) ]) ]) # LC_FSCRYPT_SUPPORT @@ -2305,6 +2413,7 @@ AC_DEFUN([LC_PROG_LINUX], [ LC_KIOCB_HAS_NBYTES LC_HAVE_DQUOT_QC_DQBLK LC_HAVE_AIO_COMPLETE + LC_HAVE_IS_ROOT_INODE # 3.20 LC_BACKING_DEV_INFO_REMOVAL @@ -2319,6 +2428,7 @@ AC_DEFUN([LC_PROG_LINUX], [ LC_BIO_ENDIO_USES_ONE_ARG LC_SYMLINK_OPS_USE_NAMEIDATA LC_ACCOUNT_PAGE_DIRTIED_3ARGS + LC_HAVE_CRYPTO_ALLOC_SKCIPHER # 4.3 LC_HAVE_INTERVAL_EXP_BLK_INTEGRITY @@ -2353,6 +2463,7 @@ AC_DEFUN([LC_PROG_LINUX], [ LC_FOP_ITERATE_SHARED # 4.8 + LC_EXPORT_DEFAULT_FILE_SPLICE_READ LC_HAVE_POSIX_ACL_VALID_USER_NS LC_D_COMPARE_4ARGS LC_FULL_NAME_HASH_3ARGS @@ -2386,9 +2497,11 @@ AC_DEFUN([LC_PROG_LINUX], [ # 4.14 LC_PAGEVEC_INIT_ONE_PARAM LC_BI_BDEV + LC_INTERVAL_TREE_CACHED # 4.17 LC_VM_FAULT_T + LC_VM_FAULT_RETRY LC_I_PAGES # 4.18 @@ -2767,6 +2880,7 @@ AM_CONDITIONAL(XATTR_HANDLER, test "x$lb_cv_compile_xattr_handler_flags" = xyes) AM_CONDITIONAL(SELINUX, test "$SELINUX" = "-lselinux") AM_CONDITIONAL(GETSEPOL, test x$enable_getsepol = xyes) AM_CONDITIONAL(LLCRYPT, test x$enable_llcrypt = xyes) +AM_CONDITIONAL(LIBAIO, test x$enable_libaio = xyes) ]) # LC_CONDITIONALS # @@ -2786,9 +2900,11 @@ lustre/doc/Makefile lustre/include/Makefile lustre/include/lustre/Makefile lustre/include/uapi/linux/lustre/Makefile +lustre/kernel_patches/targets/4.18-rhel8.3.target lustre/kernel_patches/targets/4.18-rhel8.2.target lustre/kernel_patches/targets/4.18-rhel8.1.target lustre/kernel_patches/targets/4.18-rhel8.target +lustre/kernel_patches/targets/3.10-rhel7.9.target lustre/kernel_patches/targets/3.10-rhel7.8.target lustre/kernel_patches/targets/3.10-rhel7.7.target lustre/kernel_patches/targets/3.10-rhel7.6.target @@ -2798,6 +2914,7 @@ lustre/kernel_patches/targets/4.14-rhel7.6.target lustre/kernel_patches/targets/4.12-sles12sp4.target lustre/kernel_patches/targets/4.12-sles12sp5.target lustre/kernel_patches/targets/4.12-sles15sp1.target +lustre/kernel_patches/targets/4.12-sles15sp2.target lustre/kernel_patches/targets/3.x-fc18.target lustre/ldlm/Makefile lustre/fid/Makefile