Commit f1712b36 authored by Lai Siyao's avatar Lai Siyao Committed by Oleg Drokin
Browse files

LU-13437 lmv: check stripe FID sanity

Striped directory layout may be broken, if some stripe FID is insane,
return -ENODEV.

Lustre-commit: 698a496a

Signed-off-by: default avatarLai Siyao <>
Change-Id: I7ed8c7c561e34625e2cb29bfd14bc0ecf3fce46c
Reviewed-by: default avatarAndreas Dilger <>
Reviewed-by: default avatarHongchao Zhang <>
Signed-off-by: default avatarMinh Diep <>

Tested-by: default avatarjenkins <>
Tested-by: default avatarMaloo <>
Reviewed-by: default avatarOleg Drokin <>
parent b4b93d26
......@@ -1596,6 +1596,9 @@ __lmv_locate_tgt(struct lmv_obd *lmv, struct lmv_stripe_md *lsm,
*fid = oinfo->lmo_fid;
if (mds != NULL)
*mds = oinfo->lmo_mds;
/* check stripe FID is sane */
if (!fid_is_sane(&oinfo->lmo_fid))
return ERR_PTR(-ENODEV);
tgt = lmv_get_target(lmv, oinfo->lmo_mds, NULL);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment