a3470f
From 5d649e42f6566f6f2f3425298cfee48d170ab4ea Mon Sep 17 00:00:00 2001
a3470f
From: N Balachandran <nbalacha@redhat.com>
a3470f
Date: Wed, 16 May 2018 18:15:02 +0530
a3470f
Subject: [PATCH 282/282] cluster/dht: Remove EIO from dht_inode_missing
a3470f
a3470f
Removed EIO from the list of errnos that triggered
a3470f
a migrate check task.
a3470f
a3470f
upstream patch: https://review.gluster.org/#/c/20028/
a3470f
a3470f
> Change-Id: I7f89c7a16056421588f1af2377cebe6affddcb47
a3470f
> fixes: bz#1578823
a3470f
> Signed-off-by: N Balachandran <nbalacha@redhat.com>
a3470f
a3470f
Change-Id: I1962f0db916af71d2903814dc01f0c0809e57ce7
a3470f
BUG: 1580344
a3470f
Signed-off-by: N Balachandran <nbalacha@redhat.com>
a3470f
Reviewed-on: https://code.engineering.redhat.com/gerrit/139188
a3470f
Tested-by: Sunil Kumar Heggodu Gopala Acharya <sheggodu@redhat.com>
a3470f
Tested-by: RHGS Build Bot <nigelb@redhat.com>
a3470f
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
a3470f
---
a3470f
 xlators/cluster/dht/src/dht-common.h     | 4 +---
a3470f
 xlators/cluster/dht/src/dht-inode-read.c | 2 +-
a3470f
 2 files changed, 2 insertions(+), 4 deletions(-)
a3470f
a3470f
diff --git a/xlators/cluster/dht/src/dht-common.h b/xlators/cluster/dht/src/dht-common.h
a3470f
index 10b7c7e..a70342f 100644
a3470f
--- a/xlators/cluster/dht/src/dht-common.h
a3470f
+++ b/xlators/cluster/dht/src/dht-common.h
a3470f
@@ -795,9 +795,7 @@ typedef struct dht_fd_ctx {
a3470f
                 }                                               \
a3470f
         } while (0)
a3470f
 
a3470f
-#define dht_inode_missing(op_errno) (op_errno == ENOENT || op_errno == ESTALE \
a3470f
-                                     || op_errno == EIO) \
a3470f
-/*Bad fix. Please revert the commit after fixing the bug 1329505*/
a3470f
+#define dht_inode_missing(op_errno) (op_errno == ENOENT || op_errno == ESTALE)
a3470f
 
a3470f
 #define check_is_dir(i,s,x) (IA_ISDIR(s->ia_type))
a3470f
 
a3470f
diff --git a/xlators/cluster/dht/src/dht-inode-read.c b/xlators/cluster/dht/src/dht-inode-read.c
a3470f
index d1895eb..7e4aef4 100644
a3470f
--- a/xlators/cluster/dht/src/dht-inode-read.c
a3470f
+++ b/xlators/cluster/dht/src/dht-inode-read.c
a3470f
@@ -78,7 +78,7 @@ dht_open2 (xlator_t *this, xlator_t *subvol, call_frame_t *frame, int ret)
a3470f
                 goto out;
a3470f
 
a3470f
         local = frame->local;
a3470f
-        op_errno = ENOENT;
a3470f
+        op_errno = local->op_errno;
a3470f
 
a3470f
         if (we_are_not_migrating (ret)) {
a3470f
                 /* This DHT layer is not migrating the file */
a3470f
-- 
a3470f
1.8.3.1
a3470f