--- drivers/staging/lustre/lustre/ldlm/ldlm_extent.c.orig 2014-07-27 20:26:53.714161698 +0100 +++ drivers/staging/lustre/lustre/ldlm/ldlm_extent.c 2014-07-27 20:27:50.410159692 +0100 @@ -151,7 +151,8 @@ static inline int lock_mode_to_index(ldl LASSERT(mode != 0); LASSERT(IS_PO2(mode)); - for (index = -1; mode; index++, mode >>= 1) ; + for (index = -1; mode; index++, mode >>= 1) + ; LASSERT(index < LCK_MODE_NUM); return index; }