X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=config%2Flustre-build-ldiskfs.m4;h=b748d498790f8b7b21c59184db7428f005b2f6ce;hb=b982381f9cdbe7a04900f4192af054619f35b12b;hp=25cca46801f4777f0b8ee84c6f959888ec1e5168;hpb=0eee95ca6070f86a7262d89d68cee90f15c70372;p=fs%2Flustre-release.git diff --git a/config/lustre-build-ldiskfs.m4 b/config/lustre-build-ldiskfs.m4 index 25cca46..b748d49 100644 --- a/config/lustre-build-ldiskfs.m4 +++ b/config/lustre-build-ldiskfs.m4 @@ -13,8 +13,11 @@ esac AS_IF([test -z "$LDISKFS_SERIES"], [ AS_IF([test x$RHEL_KERNEL = xyes], [ case $RHEL_RELEASE_NO in + 74) LDISKFS_SERIES="3.10-rhel7.4.series" ;; + 73) LDISKFS_SERIES="3.10-rhel7.3.series" ;; 72) LDISKFS_SERIES="3.10-rhel7.2.series" ;; 71) LDISKFS_SERIES="3.10-rhel7.series" ;; + 69) LDISKFS_SERIES="2.6-rhel6.9.series" ;; 68) LDISKFS_SERIES="2.6-rhel6.8.series" ;; 67) LDISKFS_SERIES="2.6-rhel6.7.series" ;; 66) LDISKFS_SERIES="2.6-rhel6.6.series" ;; @@ -23,6 +26,7 @@ AS_IF([test x$RHEL_KERNEL = xyes], [ 6[0-3]) LDISKFS_SERIES="2.6-rhel6.series" ;; esac ], [test x$SUSE_KERNEL = xyes], [ + AS_VERSION_COMPARE([$LINUXRELEASE],[4.4.0],[ AS_VERSION_COMPARE([$LINUXRELEASE],[3.12.0],[ AS_VERSION_COMPARE([$LINUXRELEASE],[3.0.0],[ AS_VERSION_COMPARE([$LINUXRELEASE],[2.6.32], [], @@ -32,7 +36,9 @@ AS_IF([test x$RHEL_KERNEL = xyes], [ case $PLEV in 2) LDISKFS_SERIES="3.0-sles11.series" ;; - 3|4) LDISKFS_SERIES="3.0-sles11sp3.series" + 3) LDISKFS_SERIES="3.0-sles11sp3.series" + ;; + 4) LDISKFS_SERIES="3.0-sles11sp4.series" ;; esac ])],[LDISKFS_SERIES="3.12-sles12.series"],[ @@ -43,12 +49,13 @@ AS_IF([test x$RHEL_KERNEL = xyes], [ *) LDISKFS_SERIES="3.12-sles12.series" ;; esac - ]) + ])],[LDISKFS_SERIES="4.4-sles12sp2.series"], + [LDISKFS_SERIES="4.4-sles12sp2.series"]) ]) ]) AS_IF([test -z "$LDISKFS_SERIES"], - [AC_MSG_WARN([Unknown kernel version $LDISKFS_VERSIONRELEASE])]) -AC_MSG_RESULT([$LDISKFS_SERIES]) + [AC_MSG_RESULT([failed to identify series])], + [AC_MSG_RESULT([$LDISKFS_SERIES])]) AC_SUBST(LDISKFS_SERIES) ]) # LDISKFS_LINUX_SERIES @@ -142,6 +149,27 @@ ext4_bread, [ ]) # LB_EXT4_BREAD_4ARGS # +# LB_EXT4_HAVE_INFO_DQUOT +# +# in linux 4.4 i_dqout is in ext4_inode_info, not in struct inode +# +AC_DEFUN([LB_EXT4_HAVE_INFO_DQUOT], [ +LB_CHECK_COMPILE([if i_dquot is in ext4_inode_info], +ext4_info_dquot, [ + #include + #include + #include "$EXT4_SRC_DIR/ext4.h" +],[ + struct ext4_inode_info in; + struct dquot *dq; + + dq = in.i_dquot[0]; +],[ + AC_DEFINE(HAVE_EXT4_INFO_DQUOT, 1, [i_dquot is in ext4_inode_info]) +]) +]) # LB_EXT4_HAVE_INFO_DQUOT + +# # LDISKFS_AC_PATCH_PROGRAM # # Determine which program should be used to apply the patches to @@ -221,10 +249,12 @@ AS_IF([test x$enable_ldiskfs != xno],[ LB_EXT4_JOURNAL_START_3ARGS LB_LDISKFS_MAP_BLOCKS LB_EXT4_BREAD_4ARGS + LB_EXT4_HAVE_INFO_DQUOT AC_DEFINE(CONFIG_LDISKFS_FS_POSIX_ACL, 1, [posix acls for ldiskfs]) AC_DEFINE(CONFIG_LDISKFS_FS_SECURITY, 1, [fs security for ldiskfs]) AC_DEFINE(CONFIG_LDISKFS_FS_XATTR, 1, [extened attributes for ldiskfs]) AC_DEFINE(CONFIG_LDISKFS_FS_RW, 1, [enable rw access for ldiskfs]) + AC_DEFINE(CONFIG_LDISKFS_FS_ENCRYPTION, 1, [enable encryption for ldiskfs]) AC_SUBST(LDISKFS_SUBDIR, ldiskfs) AC_DEFINE(HAVE_LDISKFS_OSD, 1, Enable ldiskfs osd) ]) @@ -292,11 +322,21 @@ AS_IF([test -e "$linux_src/fs/ext4/super.c"], [ EXT4_SRC_DIR="$linux_src/fs/ext4" ], [ # Kernel ext source provided by kernel-debuginfo-common package - linux_src=$(ls -1d /usr/src/debug/*/linux-${LINUXRELEASE%.*}* \ + # that extracted to $LINUX + linux_src=$(ls -1d $linux_src/../../debug/*/linux-${LINUXRELEASE%.*}* \ 2>/dev/null | tail -1) - AS_IF([test -e "$linux_src/fs/ext4/super.c"], - [EXT4_SRC_DIR="$linux_src/fs/ext4"], - [EXT4_SRC_DIR=""]) + AS_IF([test -e "$linux_src/fs/ext4/super.c"], [ + EXT4_SRC_DIR="$linux_src/fs/ext4" + ], [ + # Kernel ext source provided by kernel-debuginfo-common package + linux_src=$(ls -1d /usr/src/debug/*/linux-${LINUXRELEASE%.*}* \ + 2>/dev/null | tail -1) + AS_IF([test -e "$linux_src/fs/ext4/super.c"], [ + EXT4_SRC_DIR="$linux_src/fs/ext4" + ], [ + EXT4_SRC_DIR="" + ]) + ]) ]) AC_MSG_RESULT([$EXT4_SRC_DIR]) AC_SUBST(EXT4_SRC_DIR)