Skip to contentSkip to conversation

nvmet-fc: Remove a set-but-not-used variable

PATCH New Bart Van Assche 3 participants 3 messages Jun 8, 2017 – Jun 15, 2017

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 nvmet-fc: Remove a set-but-not-used variable

From: Bart Van Assche <[email protected]>

This was detected by building the nvmet-fc driver with W=1.

Signed-off-by Bart Van Assche <bart.vanassche at sandisk.com>
Cc James Smart <james.smart at broadcom.com>
Cc Christoph Hellwig <hch at lst.de>
Cc Johannes Thumshirn <jthumshirn at suse.de>
---
 drivers/nvme/target/fcloop.c | 2 --
 1 file changed, 2 deletions(-)
drivers/nvme/target/fcloop.c +0 -2
index 294a6611fb24..1bb9d5b311b1 100644
@@ -569,7 +569,6 @@ fcloop_tgt_fcp_abort(struct nvmet_fc_target_port *tgtport,
 			struct nvmefc_tgt_fcp_req *tgt_fcpreq)
 {
 	struct fcloop_fcpreq *tfcp_req = tgt_fcp_req_to_fcpreq(tgt_fcpreq);
-	int active;
 
 	/*
 	 * mark aborted only in case there were 2 threads in transport
@@ -577,7 +576,6 @@ fcloop_tgt_fcp_abort(struct nvmet_fc_target_port *tgtport,
 	 * after the abort request
 	 */
 	spin_lock(&tfcp_req->reqlock);
-	active = tfcp_req->active;
 	tfcp_req->aborted = true;
 	spin_unlock(&tfcp_req->reqlock);
 
Signature · 1 line
2.12.2
#1 lore raw

PATCH 1/1 nvmet-fc: Remove a set-but-not-used variable

Quoted 3 lines · Bart Van Assche

From: Bart Van Assche <bart.vanassche at sandisk.com>

This was detected by building the nvmet-fc driver with W=1.

Thanks Bart, applied to the nvme-4.13 branch.

maintainer
#2 lore raw

PATCH 1/1 nvmet-fc: Remove a set-but-not-used variable

In reply to Bart Van Assche

already applied, but FWIW,

Reviewed-by Sagi Grimberg <sagi at grimberg.me>
Quoted 33 lines · Bart Van Assche

From: Bart Van Assche <bart.vanassche at sandisk.com>

This was detected by building the nvmet-fc driver with W=1.

Signed-off-by Bart Van Assche <bart.vanassche at sandisk.com>
Cc James Smart <james.smart at broadcom.com>
Cc Christoph Hellwig <hch at lst.de>
Cc Johannes Thumshirn <jthumshirn at suse.de>
---
  drivers/nvme/target/fcloop.c | 2 --
  1 file changed, 2 deletions(-)
drivers/nvme/target/fcloop.c +0 -2
index 294a6611fb24..1bb9d5b311b1 100644
@@ -569,7 +569,6 @@ fcloop_tgt_fcp_abort(struct nvmet_fc_target_port *tgtport,
  			struct nvmefc_tgt_fcp_req *tgt_fcpreq)
  {
  	struct fcloop_fcpreq *tfcp_req = tgt_fcp_req_to_fcpreq(tgt_fcpreq);
-	int active;
 
  	/*
  	 * mark aborted only in case there were 2 threads in transport
@@ -577,7 +576,6 @@ fcloop_tgt_fcp_abort(struct nvmet_fc_target_port *tgtport,
  	 * after the abort request
  	 */
  	spin_lock(&tfcp_req->reqlock);
-	active = tfcp_req->active;
  	tfcp_req->aborted = true;
  	spin_unlock(&tfcp_req->reqlock);