public inbox for linux-ext4@vger.kernel.org
 help / color / mirror / Atom feed
From: Emoly Liu <emoly.liu@intel.com>
To: tytso@mit.edu
Cc: linux-ext4@vger.kernel.org, Emoly Liu <emoly.liu@intel.com>
Subject: [PATCH] ext4: error should be cleared if ea_inode isn't added to the cache
Date: Wed, 12 Jul 2017 03:56:53 +0000	[thread overview]
Message-ID: <1499831813-13218-1-git-send-email-emoly.liu@intel.com> (raw)

For Lustre, if ea_inode fails in hash validation but passes parent
inode and generation checks, it won't be added to the cache as well
as the error "-EFSCORRUPTED" should be cleared, otherwise it will
cause "Structure needs cleaning" when running getfattr command.

Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-9723
---
 fs/ext4/xattr.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/fs/ext4/xattr.c b/fs/ext4/xattr.c
index cff4f41..de217a0 100644
--- a/fs/ext4/xattr.c
+++ b/fs/ext4/xattr.c
@@ -451,6 +451,7 @@ static int ext4_xattr_inode_iget(struct inode *parent, unsigned long ea_ino,
 		}
 		/* Do not add ea_inode to the cache. */
 		ea_inode_cache = NULL;
+		err = 0;
 	} else if (err)
 		goto out;
 
-- 
1.8.3.1

             reply	other threads:[~2017-07-12  4:05 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-12  3:56 Emoly Liu [this message]
2017-07-12  4:37 ` [PATCH] ext4: error should be cleared if ea_inode isn't added to the cache Tahsin Erdogan
2017-07-13  5:17   ` Andreas Dilger
2017-07-17  2:12 ` Liu, Emoly
2017-07-31  4:43   ` Theodore Ts'o

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1499831813-13218-1-git-send-email-emoly.liu@intel.com \
    --to=emoly.liu@intel.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=tytso@mit.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox