diff mbox

ext4: error should be cleared if ea_inode isn't added to the cache

Message ID 07A0E441A926DB4D91D25518F435CC777C9D62FD@SHSMSX104.ccr.corp.intel.com
State Accepted, archived
Headers show

Commit Message

Emoly Liu July 17, 2017, 2:12 a.m. UTC
Hi,

This patch needs to be included into the release along with the ea_inode feature to maintain proper feature compatibility with Lustre.
Could it be landed as soon as possible?

Thanks,
Emoly

-----Original Message-----
From: Emoly Liu [mailto:emoly.liu@intel.com] 
Sent: Wednesday, July 12, 2017 11:57 AM
To: tytso@mit.edu
Cc: linux-ext4@vger.kernel.org; Liu, Emoly <emoly.liu@intel.com>
Subject: [PATCH] ext4: error should be cleared if ea_inode isn't added to the cache

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(+)

--
1.8.3.1

Comments

Theodore Ts'o July 31, 2017, 4:43 a.m. UTC | #1
On Mon, Jul 17, 2017 at 02:12:34AM +0000, Liu, Emoly wrote:
> Hi,
> 
> This patch needs to be included into the release along with the ea_inode feature to maintain proper feature compatibility with Lustre.
> Could it be landed as soon as possible?

Thanks, applied.  It will be pushed to Linus before 4.13 is released.

		     	     	    - Ted
diff mbox

Patch

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;