summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/libiscsi.c
diff options
context:
space:
mode:
authorMasatake YAMATO <yamato@redhat.com>2013-04-10 18:24:38 +0200
committerJames Bottomley <JBottomley@Parallels.com>2013-04-12 01:54:01 +0200
commit1fc2b00fba55f70ab32ecc493efbca9a1a76a4e3 (patch)
tree77eb0dc3b8407b8536deead9eddef3cccbedc945 /drivers/scsi/libiscsi.c
parent[SCSI] qla4xxx: Update driver version to 5.03.00-k8 (diff)
downloadlinux-1fc2b00fba55f70ab32ecc493efbca9a1a76a4e3.tar.xz
linux-1fc2b00fba55f70ab32ecc493efbca9a1a76a4e3.zip
[SCSI] libiscsi: avoid unnecessary multiple NULL assignments
In iscsi_free_task, NULL is assigned to task->sc twice: before and after kfifo_in invocatoin. Allocating and freeing iscsi_task are guarded with session->lock, so multiple NULL assignments cause no trouble. But people reading the source code may be confused. The second NULL assignment comes from commit: 3e5c28ad0391389959ccae81c938c7533efb3490 It seems that the line after kfifo_in invocation was introduced accidentally. Signed-off-by: Masatake YAMATO <yamato@redhat.com> Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/libiscsi.c')
-rw-r--r--drivers/scsi/libiscsi.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/scsi/libiscsi.c b/drivers/scsi/libiscsi.c
index d5e5c445a33c..5de946984500 100644
--- a/drivers/scsi/libiscsi.c
+++ b/drivers/scsi/libiscsi.c
@@ -507,7 +507,6 @@ static void iscsi_free_task(struct iscsi_task *task)
kfifo_in(&session->cmdpool.queue, (void*)&task, sizeof(void*));
if (sc) {
- task->sc = NULL;
/* SCSI eh reuses commands to verify us */
sc->SCp.ptr = NULL;
/*