From: Alex Zhuravlev Date: Mon, 22 May 2017 02:14:18 +0000 (-0400) Subject: LU-9333 osd: few cleanups to support gcc6 X-Git-Tag: 2.9.59~73 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=095551c2cdc358269f05cdcbfe45f5ca3f0b8aec;p=fs%2Flustre-release.git LU-9333 osd: few cleanups to support gcc6 few cleanups to support gcc6 Change-Id: Ibe664e87ff67eb3d34ce09c9a1892e55a63ab2cb Signed-off-by: Alex Zhuravlev Reviewed-on: https://review.whamcloud.com/26584 Tested-by: Jenkins Reviewed-by: Dmitry Eremin Tested-by: Maloo Reviewed-by: James Simmons Reviewed-by: Oleg Drokin --- diff --git a/ldiskfs/kernel_patches/patches/rhel6.5/ext4-brackets-in-ext4-remove-blocks.patch b/ldiskfs/kernel_patches/patches/rhel6.5/ext4-brackets-in-ext4-remove-blocks.patch new file mode 100644 index 0000000..845cf2d --- /dev/null +++ b/ldiskfs/kernel_patches/patches/rhel6.5/ext4-brackets-in-ext4-remove-blocks.patch @@ -0,0 +1,16 @@ +diff --git a/fs/ext4/extents.c b/fs/ext4/extents.c +index 1ed737f..77e2fb3 100644 +--- a/fs/ext4/extents.c ++++ b/fs/ext4/extents.c +@@ -2276,9 +2276,10 @@ static int ext4_remove_blocks(handle_t *handle, + unsigned short ee_len = ext4_ext_get_actual_len(ex); + int i, metadata = 0, flags =0; + +- if (S_ISDIR(inode->i_mode) || S_ISLNK(inode->i_mode)) ++ if (S_ISDIR(inode->i_mode) || S_ISLNK(inode->i_mode)) { + metadata = 1; + flags = EXT4_FREE_BLOCKS_METADATA; ++ } + #ifdef EXTENTS_STATS + { + struct ext4_sb_info *sbi = EXT4_SB(inode->i_sb); diff --git a/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.5.series b/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.5.series index 43d8ff4..e662543 100644 --- a/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.5.series +++ b/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.5.series @@ -47,3 +47,4 @@ rhel6.5/ext4-give-warning-with-dir-htree-growing.patch rhel6.5/ext4-fix-journal-quota.patch rhel6.3/ext4-dont-check-in-ro.patch rhel6.3/ext4-dont-check-before-replay.patch +rhel6.5/ext4-brackets-in-ext4-remove-blocks.patch diff --git a/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.6.series b/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.6.series index 96400b0..84962a9 100644 --- a/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.6.series +++ b/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.6.series @@ -47,3 +47,4 @@ rhel6.3/ext4-notalloc_under_idatasem.patch rhel6.5/ext4-give-warning-with-dir-htree-growing.patch rhel6.6/ext4_s_max_ext_tree_depth.patch rhel6.5/ext4-fix-journal-quota.patch +rhel6.5/ext4-brackets-in-ext4-remove-blocks.patch diff --git a/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.7.series b/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.7.series index 67f4bde..51b6734 100644 --- a/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.7.series +++ b/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.7.series @@ -46,3 +46,4 @@ rhel6.3/ext4-notalloc_under_idatasem.patch rhel6.5/ext4-give-warning-with-dir-htree-growing.patch rhel6.6/ext4_s_max_ext_tree_depth.patch rhel6.5/ext4-fix-journal-quota.patch +rhel6.5/ext4-brackets-in-ext4-remove-blocks.patch diff --git a/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.8.series b/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.8.series index 3c4ab71..70b2e61 100644 --- a/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.8.series +++ b/ldiskfs/kernel_patches/series/ldiskfs-2.6-rhel6.8.series @@ -44,3 +44,4 @@ rhel6.3/ext4-notalloc_under_idatasem.patch rhel6.5/ext4-give-warning-with-dir-htree-growing.patch rhel6.6/ext4_s_max_ext_tree_depth.patch rhel6.5/ext4-fix-journal-quota.patch +rhel6.5/ext4-brackets-in-ext4-remove-blocks.patch diff --git a/lustre/include/lustre_fid.h b/lustre/include/lustre_fid.h index dc996a5..8759b31 100644 --- a/lustre/include/lustre_fid.h +++ b/lustre/include/lustre_fid.h @@ -772,6 +772,7 @@ static inline void ost_fid_from_resid(struct lu_fid *fid, /* old resid */ struct ost_id oi; + memset(&oi, 0, sizeof(oi)); ostid_set_seq(&oi, name->name[LUSTRE_RES_ID_VER_OID_OFF]); if (ostid_set_id(&oi, name->name[LUSTRE_RES_ID_SEQ_OFF])) { CERROR("Bad %llu to set " DOSTID "\n", diff --git a/lustre/ldlm/ldlm_resource.c b/lustre/ldlm/ldlm_resource.c index 52036fb..9f35954 100644 --- a/lustre/ldlm/ldlm_resource.c +++ b/lustre/ldlm/ldlm_resource.c @@ -78,7 +78,6 @@ lprocfs_dump_ns_seq_write(struct file *file, const char __user *buffer, LPROC_SEQ_FOPS_WO_TYPE(ldlm, dump_ns); LPROC_SEQ_FOPS_RW_TYPE(ldlm_rw, uint); -LPROC_SEQ_FOPS_RO_TYPE(ldlm, uint); #ifdef HAVE_SERVER_SUPPORT