Commit 5cb925f3 authored by Bryant G. Ly's avatar Bryant G. Ly Committed by Thadeu Lima de Souza Cascardo

UBUNTU: SAUCE: ibmvscsis: Fix srp_transfer_data fail return code

BugLink: http://bugs.launchpad.net/bugs/1657194

If srp_transfer_data fails within ibmvscsis_write_pending, then
the most likely scenario is that the client timed out the op and
removed the TCE mapping. Thus it will loop forever retrying the
op that is pretty much guaranteed to fail forever. A better return
code would be EIO instead of EAGAIN.

Cc: stable@vger.kernel.org
Reported-by: default avatarSteven Royer <seroyer@linux.vnet.ibm.com>
Tested-by: default avatarSteven Royer <seroyer@linux.vnet.ibm.com>
Signed-off-by: default avatarBryant G. Ly <bgly@us.ibm.com>
Signed-off-by: default avatarTim Gardner <tim.gardner@canonical.com>
Acked-by: default avatarStefan Bader <stefan.bader@canonical.com>
Acked-by: default avatarBrad Figg <brad.figg@canonical.com>
Signed-off-by: default avatarThadeu Lima de Souza Cascardo <cascardo@canonical.com>
parent d7335085
......@@ -3588,7 +3588,7 @@ static int ibmvscsis_write_pending(struct se_cmd *se_cmd)
1, 1);
if (rc) {
pr_err("srp_transfer_data() failed: %d\n", rc);
return -EAGAIN;
return -EIO;
}
/*
* We now tell TCM to add this WRITE CDB directly into the TCM storage
......
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