From: Jinshan Xiong Date: Tue, 23 Apr 2013 23:59:56 +0000 (-0700) Subject: LU-3205 llite: Set layout_gen before compatibility check X-Git-Tag: 2.3.65~55 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=6e17f3dceb11704d15bafc6b80f5973ced3235df LU-3205 llite: Set layout_gen before compatibility check We should set IO's layout generation to current generation of inode, no matter what it is. Otherwise, it will go into an infinite loop on layout change check. Signed-off-by: Jinshan Xiong Change-Id: I9f1f0d9ae0dd53dea130db46bbcbdbd29526b6eb Reviewed-on: http://review.whamcloud.com/6137 Tested-by: Hudson Reviewed-by: Niu Yawei Tested-by: Maloo Reviewed-by: Andreas Dilger Reviewed-by: Oleg Drokin --- diff --git a/lustre/llite/file.c b/lustre/llite/file.c index 09f9905..e61b696 100644 --- a/lustre/llite/file.c +++ b/lustre/llite/file.c @@ -3437,7 +3437,7 @@ int ll_layout_refresh(struct inode *inode, __u32 *gen) int rc; ENTRY; - *gen = LL_LAYOUT_GEN_NONE; + *gen = lli->lli_layout_gen; if (!(sbi->ll_flags & LL_SBI_LAYOUT_LOCK)) RETURN(0);