Whamcloud - gitweb
LU-11271 lnd: conditionally set health status 42/33042/2
authorAmir Shehata <ashehata@whamcloud.com>
Tue, 21 Aug 2018 19:15:30 +0000 (12:15 -0700)
committerOleg Drokin <green@whamcloud.com>
Tue, 4 Sep 2018 03:48:14 +0000 (03:48 +0000)
For specific error scenarios a more accurate health status is set
per transmit. These shouldn't be overwritten in
kiblnd_txlist_done()

Test-Parameters: trivial
Signed-off-by: Amir Shehata <ashehata@whamcloud.com>
Change-Id: I6c3ad6660aa654d32e823b29ebe3aedb9fc5508e
Reviewed-on: https://review.whamcloud.com/33042
Tested-by: Jenkins
Reviewed-by: Olaf Weber <olaf.weber@hpe.com>
Reviewed-by: Sonia Sharma <sharmaso@whamcloud.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/klnds/o2iblnd/o2iblnd_cb.c

index 65eb85e..a6e06e6 100644 (file)
@@ -107,7 +107,8 @@ kiblnd_txlist_done(struct list_head *txlist, int status,
                /* complete now */
                tx->tx_waiting = 0;
                tx->tx_status = status;
-               tx->tx_hstatus = hstatus;
+               if (hstatus != LNET_MSG_STATUS_OK)
+                       tx->tx_hstatus = hstatus;
                kiblnd_tx_done(tx);
        }
 }
@@ -2177,9 +2178,11 @@ kiblnd_abort_txs(struct kib_conn *conn, struct list_head *txs)
 
        /*
         * aborting transmits occurs when finalizing the connection.
-        * The connection is finalized on error
+        * The connection is finalized on error.
+        * Passing LNET_MSG_STATUS_OK to txlist_done() will not
+        * override the value already set in tx->tx_hstatus above.
         */
-       kiblnd_txlist_done(&zombies, -ECONNABORTED, -1);
+       kiblnd_txlist_done(&zombies, -ECONNABORTED, LNET_MSG_STATUS_OK);
 }
 
 static void