Commit 80d5e8a2 authored by Bart Van Assche's avatar Bart Van Assche Committed by Roland Dreier

IB/srp: Let srp_abort() return FAST_IO_FAIL if TL offline

If the transport layer is offline it is more appropriate to let
srp_abort() return FAST_IO_FAIL instead of SUCCESS.
Reported-by: default avatarSebastian Riemer <sebastian.riemer@profitbricks.com>
Acked-by: default avatarDavid Dillow <dillowda@ornl.gov>
Signed-off-by: default avatarBart Van Assche <bvanassche@acm.org>
Signed-off-by: default avatarRoland Dreier <roland@purestorage.com>
parent e8ca4135
......@@ -1753,8 +1753,7 @@ static int srp_abort(struct scsi_cmnd *scmnd)
if (!req || !srp_claim_req(target, req, scmnd))
return FAILED;
if (srp_send_tsk_mgmt(target, req->index, scmnd->device->lun,
SRP_TSK_ABORT_TASK) == 0 ||
target->transport_offline)
SRP_TSK_ABORT_TASK) == 0)
ret = SUCCESS;
else if (target->transport_offline)
ret = FAST_IO_FAIL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment