Whamcloud - gitweb
LU-6235 osd-ldiskfs: NOT skip LMAC_NOT_IN_OI in osd_check_lma 22/13922/2
authorFan Yong <fan.yong@intel.com>
Thu, 4 Dec 2014 14:21:13 +0000 (22:21 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 25 Mar 2015 12:59:25 +0000 (12:59 +0000)
Sometimes, the ost-object may references a wrong indoe because of
the invalid OI mapping. Usually, the OSD can auto detect that via
osd_check_lma(). For old system, if the inode's LMV contains flag
LMAC_NOT_IN_OI, it would skip related checking. But such behavior
is wrong, if may cause the osd-object to reference some important
system inode, and cause system crash via subsequent modification.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Ib5cdf2ee4d9893a87fde3caf81109eabdad9ecfa
Reviewed-on: http://review.whamcloud.com/13922
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>

index 369914a..a321a5e 100644 (file)
@@ -524,7 +524,7 @@ static int osd_check_lma(const struct lu_env *env, struct osd_object *obj)
                              lma->lma_incompat & ~LMA_INCOMPAT_SUPP,
                              PFID(rfid), inode->i_ino);
                        rc = -EOPNOTSUPP;
-               } else if (!(lma->lma_compat & LMAC_NOT_IN_OI)) {
+               } else {
                        fid = &lma->lma_self_fid;