Whamcloud - gitweb
LU-13553 lnd: gracefully handle unexpected events 52/38752/2
authorAmir Shehata <ashehata@whamcloud.com>
Wed, 20 May 2020 05:21:10 +0000 (22:21 -0700)
committerOleg Drokin <green@whamcloud.com>
Sat, 11 Jul 2020 07:28:10 +0000 (07:28 +0000)
commit89e6bf780e33be2020490b28945a53a6d61b8da0
tree59ff562a239867d8fae5de2d5358adaff3837271
parent5a867da63f9ffcc276c517e8e0fecc29b70316f3
LU-13553 lnd: gracefully handle unexpected events

When a tx completes kiblnd_tx_complete() callback is invoked.
We ensure:
LASSERT (tx->tx_sending > 0);
However this assert is being triggered in some rare scenarios.
The reason tx_sending would be 0 at this point is because:
 1. ib_post_send() failed but OFED stack is still sending
    a tx complete event.
 2. We're getting two different events for the same tx

Instead of asserting, ignore that tx_complete event and print
the tx pointer and its status.

Lustre-change: https://review.whamcloud.com/38669
Lustre-commit: 60f9f539e686fc19b080a3cda15ade7111bbd4a7

Signed-off-by: Amir Shehata <ashehata@whamcloud.com>
Change-Id: I8cd192538c0c80abaef23a4b6e6906936043060b
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Serguei Smirnov <ssmirnov@whamcloud.com>
Signed-off-by: Minh Diep <mdiep@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/38752
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/klnds/o2iblnd/o2iblnd_cb.c