cifs: smbd: Properly process errors on ib_post_send
authorLong Li <longli@microsoft.com>
Thu, 2 Apr 2020 20:56:48 +0000 (13:56 -0700)
committerSteve French <stfrench@microsoft.com>
Tue, 7 Apr 2020 17:41:16 +0000 (12:41 -0500)
commitf1b7b862bf79dc9bf29dd59654c5d765b572411e
tree4356e3afd64e1fa3d3732d9c66779676ddfc7cac
parenteda1c54f148a86f5e64d4d1d3f62d9ea7f94c17e
cifs: smbd: Properly process errors on ib_post_send

When processing errors from ib_post_send(), the transport state needs to be
rolled back to the condition before the error.

Refactor the old code to make it easy to roll back on IB errors, and fix this.

Signed-off-by: Long Li <longli@microsoft.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifs/smbdirect.c