mirror of
https://github.com/SCST-project/scst.git
synced 2026-08-20 06:06:23 +00:00
ib_srpt: Fix a bug that was introduced in r4784
Reported by: Matteo Tescione <matteo@rmnet.it> git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@4844 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
+3
-4
@@ -1493,13 +1493,12 @@ static void srpt_handle_send_comp(struct srpt_rdma_ch *ch,
|
||||
struct scst_cmd *scmnd;
|
||||
|
||||
scmnd = &ioctx->scmnd;
|
||||
EXTRACHECKS_WARN_ON((state == SRPT_STATE_MGMT_RSP_SENT)
|
||||
!= (scmnd == NULL));
|
||||
if (scmnd) {
|
||||
if (state != SRPT_STATE_MGMT_RSP_SENT) {
|
||||
srpt_unmap_sg_to_ib_sge(ch, ioctx);
|
||||
scst_tgt_cmd_done(scmnd, context);
|
||||
} else
|
||||
} else {
|
||||
srpt_put_send_ioctx(ioctx);
|
||||
}
|
||||
} else {
|
||||
PRINT_ERROR("IB completion has been received too late for"
|
||||
" wr_id = %u.", ioctx->ioctx.index);
|
||||
|
||||
Reference in New Issue
Block a user