From: John L. Hammond Date: Mon, 16 Apr 2018 04:14:54 +0000 (-0400) Subject: staging: lustre: llite: handle xattr cache refill race X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=a2fc74bc368f399c385bdb2a480c06b0b55c0c77;p=linux.git staging: lustre: llite: handle xattr cache refill race In ll_xattr_cache_refill() if the xattr cache was invalid (and no request was sent) then return -EAGAIN so that ll_getxattr_common() caller will fetch the xattr from the MDT. Signed-off-by: John L. Hammond Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-10132 Reviewed-on: https://review.whamcloud.com/29654 Reviewed-by: Andreas Dilger Reviewed-by: Lai Siyao Reviewed-by: Oleg Drokin Signed-off-by: James Simmons Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/lustre/lustre/llite/xattr_cache.c b/drivers/staging/lustre/lustre/llite/xattr_cache.c index 53dfaeade5352..5da69ba088c40 100644 --- a/drivers/staging/lustre/lustre/llite/xattr_cache.c +++ b/drivers/staging/lustre/lustre/llite/xattr_cache.c @@ -357,7 +357,7 @@ static int ll_xattr_cache_refill(struct inode *inode) if (unlikely(!req)) { CDEBUG(D_CACHE, "cancelled by a parallel getxattr\n"); ll_intent_drop_lock(&oit); - rc = -EIO; + rc = -EAGAIN; goto err_unlock; }