Skip to content

Commit

Permalink
scsi: libcxgbi: fix incorrect DDP resource cleanup
Browse files Browse the repository at this point in the history
Before calling task_release_itt() task data is memset to zero because of
which DDP context information is lost resulting in incorrect DDP
resource cleanup, to fix this call task_release_itt() before memset.

Signed-off-by: Varun Prakash <varun@chelsio.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
  • Loading branch information
Varun Prakash authored and Martin K. Petersen committed Nov 9, 2016
1 parent a5dd506 commit 69e2d1e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/scsi/cxgbi/libcxgbi.c
Original file line number Diff line number Diff line change
Expand Up @@ -2081,9 +2081,10 @@ void cxgbi_cleanup_task(struct iscsi_task *task)
/* never reached the xmit task callout */
if (tdata->skb)
__kfree_skb(tdata->skb);
memset(tdata, 0, sizeof(*tdata));

task_release_itt(task, task->hdr_itt);
memset(tdata, 0, sizeof(*tdata));

iscsi_tcp_cleanup_task(task);
}
EXPORT_SYMBOL_GPL(cxgbi_cleanup_task);
Expand Down

0 comments on commit 69e2d1e

Please sign in to comment.