From: Bob Glossman Date: Mon, 23 Apr 2018 22:25:31 +0000 (-0700) Subject: LU-10944 kernel: kernel update [SLES12 SP3 4.4.126-94.22] X-Git-Tag: 2.10.4-RC1~4 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=69104007fc367587b5dfc9b0db3156f7e618c0b1;p=fs%2Flustre-release.git LU-10944 kernel: kernel update [SLES12 SP3 4.4.126-94.22] Update target, kernel_config, and ldiskfs files for new version ldiskfs for sles12sp2 and sles12sp3 are no longer identical, so revise some build files for sles12sp2 here too. Test-Parameters: clientdistro=sles12sp3 testgroup=review-ldiskfs \ mdsdistro=sles12sp3 ossdistro=sles12sp3 \ mdtfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs Signed-off-by: Bob Glossman Change-Id: If554b24644f763462002d81309f8edfa016210e8 Reviewed-on: https://review.whamcloud.com/32146 Tested-by: Jenkins Reviewed-by: Minh Diep Reviewed-by: Yang Sheng Tested-by: Maloo Reviewed-by: John L. Hammond --- diff --git a/ldiskfs/kernel_patches/patches/sles12sp3/ext4-disable-mb-cache.patch b/ldiskfs/kernel_patches/patches/sles12sp3/ext4-disable-mb-cache.patch new file mode 100644 index 0000000..f47bdcd --- /dev/null +++ b/ldiskfs/kernel_patches/patches/sles12sp3/ext4-disable-mb-cache.patch @@ -0,0 +1,152 @@ +mbcache provides absolutely no value for Lustre xattrs (because +they are unique and cannot be shared between files) and as we can +see it has a noticable overhead in some cases. In the past there +was a CONFIG_MBCACHE option that would allow it to be disabled, +but this was removed in newer kernels, so we will need to patch +ldiskfs to fix this. + +Index: linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/ext4.h +=================================================================== +--- linux-3.10.0-123.13.2.el7.x86_64.orig/fs/ext4/ext4.h ++++ linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/ext4.h +@@ -944,6 +944,7 @@ struct ext4_inode_info { + /* + * Mount flags set via mount options or defaults + */ ++#define EXT4_MOUNT_NO_MBCACHE 0x00001 /* Disable mbcache */ + #define EXT4_MOUNT_GRPID 0x00004 /* Create files with directory's group */ + #define EXT4_MOUNT_DEBUG 0x00008 /* Some debugging messages */ + #define EXT4_MOUNT_ERRORS_CONT 0x00010 /* Continue on errors */ +Index: linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/super.c +=================================================================== +--- linux-3.10.0-123.13.2.el7.x86_64.orig/fs/ext4/super.c ++++ linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/super.c +@@ -1157,6 +1157,7 @@ enum { + Opt_nomblk_io_submit, Opt_block_validity, Opt_noblock_validity, + Opt_inode_readahead_blks, Opt_journal_ioprio, + Opt_dioread_nolock, Opt_dioread_lock, ++ Opt_no_mbcache, + Opt_discard, Opt_nodiscard, Opt_init_itable, Opt_noinit_itable, + Opt_max_dir_size_kb, + }; +@@ -1231,6 +1232,7 @@ static const match_table_t tokens = { + {Opt_discard, "discard"}, + {Opt_nodiscard, "nodiscard"}, + {Opt_init_itable, "init_itable=%u"}, ++ {Opt_no_mbcache, "no_mbcache"}, + {Opt_init_itable, "init_itable"}, + {Opt_noinit_itable, "noinit_itable"}, + {Opt_max_dir_size_kb, "max_dir_size_kb=%u"}, +@@ -1390,6 +1392,7 @@ static const struct mount_opts { + {Opt_noauto_da_alloc, EXT4_MOUNT_NO_AUTO_DA_ALLOC, MOPT_SET}, + {Opt_auto_da_alloc, EXT4_MOUNT_NO_AUTO_DA_ALLOC, MOPT_CLEAR}, + {Opt_noinit_itable, EXT4_MOUNT_INIT_INODE_TABLE, MOPT_CLEAR}, ++ {Opt_no_mbcache, EXT4_MOUNT_NO_MBCACHE, MOPT_SET}, + {Opt_commit, 0, MOPT_GTE0}, + {Opt_max_batch_time, 0, MOPT_GTE0}, + {Opt_min_batch_time, 0, MOPT_GTE0}, +Index: linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/xattr.c +=================================================================== +--- linux-3.10.0-123.13.2.el7.x86_64.orig/fs/ext4/xattr.c ++++ linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/xattr.c +@@ -80,7 +80,7 @@ + # define ea_bdebug(bh, fmt, ...) no_printk(fmt, ##__VA_ARGS__) + #endif + +-static void ext4_xattr_cache_insert(struct mb_cache *, struct buffer_head *); ++static void _ext4_xattr_cache_insert(struct mb_cache *, struct buffer_head *); + static struct buffer_head *ext4_xattr_cache_find(struct inode *, + struct ext4_xattr_header *, + struct mb_cache_entry **); +@@ -401,7 +401,8 @@ bad_block: + error = -EFSCORRUPTED; + goto cleanup; + } +- ext4_xattr_cache_insert(ext4_mb_cache, bh); ++ if (!test_opt(inode->i_sb, NO_MBCACHE)) ++ _ext4_xattr_cache_insert(ext4_mb_cache, bh); + entry = BFIRST(bh); + error = ext4_xattr_find_entry(&entry, name_index, name, bh->b_size, 1, + inode); +@@ -565,7 +566,8 @@ ext4_xattr_block_list(struct dentry *den + error = -EFSCORRUPTED; + goto cleanup; + } +- ext4_xattr_cache_insert(ext4_mb_cache, bh); ++ if (!test_opt(inode->i_sb, NO_MBCACHE)) ++ _ext4_xattr_cache_insert(ext4_mb_cache, bh); + error = ext4_xattr_list_entries(dentry, BFIRST(bh), buffer, buffer_size); + + cleanup: +@@ -678,7 +680,9 @@ ext4_xattr_release_block(handle_t *handl + * This must happen under buffer lock for + * ext4_xattr_block_set() to reliably detect freed block + */ +- mb_cache_entry_delete_block(ext4_mb_cache, hash, bh->b_blocknr); ++ if (!test_opt(inode->i_sb, NO_MBCACHE)) ++ mb_cache_entry_delete_block(ext4_mb_cache, ++ hash, bh->b_blocknr); + get_bh(bh); + unlock_buffer(bh); + ext4_free_blocks(handle, inode, bh, 0, 1, +@@ -690,9 +694,10 @@ ext4_xattr_release_block(handle_t *handl + + + if (ref == EXT4_XATTR_REFCOUNT_MAX - 1) { +- struct mb_cache_entry *ce; ++ struct mb_cache_entry *ce = NULL; + +- ce = mb_cache_entry_get(ext4_mb_cache, hash, ++ if (!test_opt(inode->i_sb, NO_MBCACHE)) ++ ce = mb_cache_entry_get(ext4_mb_cache, hash, + bh->b_blocknr); + if (ce) { + ce->e_reusable = 1; +@@ -1107,7 +1112,8 @@ ext4_xattr_block_set(handle_t *handle, s + * ext4_xattr_block_set() to reliably detect modified + * block + */ +- mb_cache_entry_delete_block(ext4_mb_cache, hash, ++ if (!test_opt(inode->i_sb, NO_MBCACHE)) ++ mb_cache_entry_delete_block(ext4_mb_cache, hash, + bs->bh->b_blocknr); + ea_bdebug(bs->bh, "modifying in-place"); + error = ext4_xattr_set_entry(i, s, handle, inode); +@@ -1281,7 +1287,8 @@ inserted: + } else if (bs->bh && s->base == bs->bh->b_data) { + /* We were modifying this block in-place. */ + ea_bdebug(bs->bh, "keeping this block"); +- ext4_xattr_cache_insert(ext4_mb_cache, bs->bh); ++ if (!test_opt(inode->i_sb, NO_MBCACHE)) ++ _ext4_xattr_cache_insert(ext4_mb_cache, bs->bh); + new_bh = bs->bh; + get_bh(new_bh); + } else { +@@ -1277,7 +1284,8 @@ getblk_failed: + memcpy(new_bh->b_data, s->base, new_bh->b_size); + set_buffer_uptodate(new_bh); + unlock_buffer(new_bh); +- ext4_xattr_cache_insert(ext4_mb_cache, new_bh); ++ if (!test_opt(inode->i_sb, NO_MBCACHE)) ++ _ext4_xattr_cache_insert(ext4_mb_cache, new_bh); + error = ext4_handle_dirty_xattr_block(handle, + inode, new_bh); + if (error) +@@ -2068,7 +2076,7 @@ ext4_xattr_inode_array_free(struct inode + * Returns 0, or a negative error number on failure. + */ + static void +-ext4_xattr_cache_insert(struct mb_cache *ext4_mb_cache, struct buffer_head *bh) ++_ext4_xattr_cache_insert(struct mb_cache *ext4_mb_cache, struct buffer_head *bh) + { + struct ext4_xattr_header *header = BHDR(bh); + __u32 hash = le32_to_cpu(header->h_hash); +@@ -2140,6 +2148,8 @@ ext4_xattr_cache_find(struct inode *inod + struct mb_cache_entry *ce; + struct mb_cache *ext4_mb_cache = EXT4_GET_MB_CACHE(inode); + ++ if (test_opt(inode->i_sb, NO_MBCACHE)) ++ return NULL; + if (!header->h_hash) + return NULL; /* never share */ + ea_idebug(inode, "looking for cached blocks [%x]", (int)hash); diff --git a/ldiskfs/kernel_patches/series/ldiskfs-4.4-sles12sp2.series b/ldiskfs/kernel_patches/series/ldiskfs-4.4-sles12sp2.series index 2c5fc63..1bbca1a 100644 --- a/ldiskfs/kernel_patches/series/ldiskfs-4.4-sles12sp2.series +++ b/ldiskfs/kernel_patches/series/ldiskfs-4.4-sles12sp2.series @@ -4,7 +4,7 @@ sles12sp2/ext4-print-inum-in-htree-warning.patch sles12sp2/ext4-prealloc.patch sles12sp2/ext4-osd-iop-common.patch sles12sp2/ext4-misc.patch -sles12sp2/ext4-mballoc-extra-checks.patch +sles12sp3/ext4-mballoc-extra-checks.patch sles12sp2/ext4-hash-indexed-dir-dotdot-update.patch sles12sp2/ext4-kill-dx-root.patch rhel7/ext4-mballoc-pa-free-mismatch.patch @@ -16,7 +16,7 @@ sles12sp2/ext4-large-dir.patch sles12sp2/ext4-pdirop.patch sles12sp2/ext4-max-dir-size.patch rhel7/ext4-remove-truncate-warning.patch -sles12sp2/ext4-corrupted-inode-block-bitmaps-handling-patches.patch +sles12sp3/ext4-corrupted-inode-block-bitmaps-handling-patches.patch sles12sp2/ext4-give-warning-with-dir-htree-growing.patch sles12sp2/ext4-mmp-brelse.patch rhel7/ext4-jcb-optimization.patch diff --git a/ldiskfs/kernel_patches/series/ldiskfs-4.4-sles12sp3.series b/ldiskfs/kernel_patches/series/ldiskfs-4.4-sles12sp3.series index 1bbca1a..3d5da29 100644 --- a/ldiskfs/kernel_patches/series/ldiskfs-4.4-sles12sp3.series +++ b/ldiskfs/kernel_patches/series/ldiskfs-4.4-sles12sp3.series @@ -10,7 +10,7 @@ sles12sp2/ext4-kill-dx-root.patch rhel7/ext4-mballoc-pa-free-mismatch.patch sles12sp2/ext4-data-in-dirent.patch sles12sp2/ext4-large-eas.patch -sles12sp2/ext4-disable-mb-cache.patch +sles12sp3/ext4-disable-mb-cache.patch rhel7/ext4-nocmtime.patch sles12sp2/ext4-large-dir.patch sles12sp2/ext4-pdirop.patch diff --git a/lustre/ChangeLog b/lustre/ChangeLog index c27faac..28d5e56 100644 --- a/lustre/ChangeLog +++ b/lustre/ChangeLog @@ -13,7 +13,7 @@ TBD Intel Corporation 3.0.101-107 (SLES11 SP4) 3.12.74-60.64.40 (SLES12 SP1) 4.4.120-92.70 (SLES12 SP2) - 4.4.120-94.17 (SLES12 SP3) + 4.4.126-94.22 (SLES12 SP3) vanilla linux 4.6.7 (ZFS only) * Client known to build on unpatched kernels: 2.6.32-431.29.2.el6 (RHEL6.5) @@ -26,7 +26,7 @@ TBD Intel Corporation 3.0.101-107 (SLES11 SP4) 3.12.74-60.64.40 (SLES12 SP1) 4.4.120-92.70 (SLES12 SP2) - 4.4.120-94.17 (SLES12 SP3) + 4.4.126-94.22 (SLES12 SP3) vanilla linux 4.6.7 * Recommended e2fsprogs version: 1.42.13.wc6 or newer * Recommended ZFS / SPL version: 0.7.8 diff --git a/lustre/kernel_patches/kernel_configs/kernel-4.4-4.4-sles12sp3-x86_64.config b/lustre/kernel_patches/kernel_configs/kernel-4.4-4.4-sles12sp3-x86_64.config index b6d8c27..e2d2dc0 100644 --- a/lustre/kernel_patches/kernel_configs/kernel-4.4-4.4-sles12sp3-x86_64.config +++ b/lustre/kernel_patches/kernel_configs/kernel-4.4-4.4-sles12sp3-x86_64.config @@ -1,6 +1,6 @@ # # Automatically generated file; DO NOT EDIT. -# Linux/x86 4.4.120 Kernel Configuration +# Linux/x86 4.4.126 Kernel Configuration # CONFIG_64BIT=y CONFIG_X86_64=y @@ -54,7 +54,7 @@ CONFIG_BUILDTIME_EXTABLE_SORT=y CONFIG_INIT_ENV_ARG_LIMIT=32 CONFIG_CROSS_COMPILE="" # CONFIG_COMPILE_TEST is not set -CONFIG_LOCALVERSION="-94.17-default" +CONFIG_LOCALVERSION="-94.22-default" # CONFIG_LOCALVERSION_AUTO is not set CONFIG_HAVE_KERNEL_GZIP=y CONFIG_HAVE_KERNEL_BZIP2=y diff --git a/lustre/kernel_patches/targets/4.4-sles12.target.in b/lustre/kernel_patches/targets/4.4-sles12.target.in index 7b1c1da..df1474c 100644 --- a/lustre/kernel_patches/targets/4.4-sles12.target.in +++ b/lustre/kernel_patches/targets/4.4-sles12.target.in @@ -12,7 +12,7 @@ FLAVOR_DELIMITER="-" KERNEL_SRPM=kernel-source-${lnxmaj}${lnxmin}-${lnxrel}${rpmfix}.src.rpm SERIES=4.4-sles12.series -LDISKFS_SERIES=4.4-sles12sp3.series +LDISKFS_SERIES=4.4-sles12sp2.series VERSION=$lnxmaj EXTRA_VERSION="${lnxmin#.}-${lnxrel}_lustre.@VERSION@" LUSTRE_VERSION=@VERSION@ diff --git a/lustre/kernel_patches/targets/4.4-sles12sp3.target.in b/lustre/kernel_patches/targets/4.4-sles12sp3.target.in index 5a0d277..e2b44c0 100644 --- a/lustre/kernel_patches/targets/4.4-sles12sp3.target.in +++ b/lustre/kernel_patches/targets/4.4-sles12sp3.target.in @@ -1,10 +1,14 @@ lnxmaj="4.4" -lnxmin=".120" -lnxrel="94.17" +lnxmin=".126" +lnxrel="94.22" # use this when there is an "RPM fix" which means that the name of the # (source) RPM has been updated but the version of the kernel inside the # RPM is not also updated -rpmfix=".1" +rpmfix=".2" +# for some odd reasons (bug??) -devel and source have different fix +# so we'll add another one to detect this, make it the same or remove +# this change they fix the bug +rpmfix_diff=".1" # this is the delimeter that goes before the "smp" at the end of the version # defaults to empty diff --git a/lustre/kernel_patches/which_patch b/lustre/kernel_patches/which_patch index 4db3b76..d86c52d 100644 --- a/lustre/kernel_patches/which_patch +++ b/lustre/kernel_patches/which_patch @@ -23,6 +23,6 @@ PATCH SERIES FOR SERVER KERNELS: 3.0-sles11sp3.series 3.0.101-107 (SLES11 SP4) 3.12-sles12.series 3.12.74-60.64.40 (SLES12 SP1) 4.4-sles12.series 4.4.120-92.70 (SLES12 SP2) -4.4-sles12sp3.series 4.4.120-94.17 (SLES12 SP3) +4.4-sles12sp3.series 4.4.126-94.22 (SLES12 SP3) See lustre/ChangeLog for supported client kernel versions.