All new accounts created on Gitlab now require administrator approval. If you invite any collaborators, please let Flux staff know so they can approve the accounts.

Commit 1f3a437f authored by Eric Ren's avatar Eric Ren Committed by Linus Torvalds

ocfs2: fix improper handling of return errno

Previously, if a bad inode was found in ocfs2_iget(), -ESTALE was
returned back to the caller anyway.  Since commit d2b9d71a2da7 ("ocfs2:
check/fix inode block for online file check") can handle with return
value from ocfs2_read_locked_inode() now, we know the exact errno
returned for us.

Link: default avatarEric Ren <>
Reviewed-by: default avatarJoseph Qi <>
Cc: Mark Fasheh <>
Cc: Joel Becker <>
Cc: Junxiao Bi <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent d96c84f8
......@@ -176,12 +176,7 @@ struct inode *ocfs2_iget(struct ocfs2_super *osb, u64 blkno, unsigned flags,
if (is_bad_inode(inode)) {
if ((flags & OCFS2_FI_FLAG_FILECHECK_CHK) ||
/* Return OCFS2_FILECHECK_ERR_XXX related errno */
inode = ERR_PTR(rc);
inode = ERR_PTR(-ESTALE);
inode = ERR_PTR(rc);
goto bail;
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