Skip to content

Commit 364189f

Browse files
Sagi GrimbergNicholas Bellinger
authored andcommitted
iser-target: Fix session hang in case of an rdma read DIF error
This hang was a result of a missing command put when a DIF error occurred during a rdma read (and we sent an CHECK_CONDITION error without passing it to the backend). Signed-off-by: Sagi Grimberg <[email protected]> Cc: <[email protected]> # v3.14+ Signed-off-by: Nicholas Bellinger <[email protected]>
1 parent 901c04a commit 364189f

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

drivers/infiniband/ulp/isert/ib_isert.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1861,11 +1861,13 @@ isert_completion_rdma_read(struct iser_tx_desc *tx_desc,
18611861
cmd->i_state = ISTATE_RECEIVED_LAST_DATAOUT;
18621862
spin_unlock_bh(&cmd->istate_lock);
18631863

1864-
if (ret)
1864+
if (ret) {
1865+
target_put_sess_cmd(se_cmd->se_sess, se_cmd);
18651866
transport_send_check_condition_and_sense(se_cmd,
18661867
se_cmd->pi_err, 0);
1867-
else
1868+
} else {
18681869
target_execute_cmd(se_cmd);
1870+
}
18691871
}
18701872

18711873
static void

0 commit comments

Comments
 (0)