summaryrefslogtreecommitdiff
path: root/drivers/scsi
diff options
context:
space:
mode:
authorVarun Prakash <varun@chelsio.com>2016-11-05 19:19:28 +0300
committerMartin K. Petersen <martin.petersen@oracle.com>2016-11-09 03:11:01 +0300
commit69e2d1e6c0af0dd7f18cfd434b008844568641a9 (patch)
tree4090d7dd9018c332dcb1b3ca0c213f5995a151f9 /drivers/scsi
parenta5dd506e1584e91f3e7500ab9a165aa1b49eabd4 (diff)
downloadlinux-69e2d1e6c0af0dd7f18cfd434b008844568641a9.tar.xz
scsi: libcxgbi: fix incorrect DDP resource cleanup
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>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/cxgbi/libcxgbi.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/cxgbi/libcxgbi.c b/drivers/scsi/cxgbi/libcxgbi.c
index d1421139e6ea..2ffe029ff2b6 100644
--- a/drivers/scsi/cxgbi/libcxgbi.c
+++ b/drivers/scsi/cxgbi/libcxgbi.c
@@ -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);