From: "Gustavo A. R. Silva" <garsilva@embeddedor.com>
To: Adaptec OEM Raid Solutions <aacraid@adaptec.com>,
"James E.J. Bottomley" <jejb@linux.vnet.ibm.com>,
"Martin K. Petersen" <martin.petersen@oracle.com>
Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
"Gustavo A. R. Silva" <garsilva@embeddedor.com>
Subject: [PATCH] scsi: remove useless variable assignment
Date: Wed, 17 May 2017 20:00:32 -0500 [thread overview]
Message-ID: <20170518010032.GA12354@embeddedgus> (raw)
Remove both variable assignments once the value stored in variable _reqlen_
is overwritten at some point either by line 2321: reqlen = mptr - msg;
or by line 2330: reqlen = 12;
Addresses-Coverity-ID: 1226930
Addresses-Coverity-ID: 1226931
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
---
drivers/scsi/dpt_i2o.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/scsi/dpt_i2o.c b/drivers/scsi/dpt_i2o.c
index 256dd67..acad668 100644
--- a/drivers/scsi/dpt_i2o.c
+++ b/drivers/scsi/dpt_i2o.c
@@ -2292,11 +2292,8 @@ static s32 adpt_scsi_to_i2o(adpt_hba* pHba, struct scsi_cmnd* cmd, struct adpt_d
mptr+=4;
lenptr=mptr++; /* Remember me - fill in when we know */
if (dpt_dma64(pHba)) {
- reqlen = 16; // SINGLE SGE
*mptr++ = (0x7C<<24)+(2<<16)+0x02; /* Enable 64 bit */
*mptr++ = 1 << PAGE_SHIFT;
- } else {
- reqlen = 14; // SINGLE SGE
}
/* Now fill in the SGList and command */
--
2.5.0
next reply other threads:[~2017-05-18 1:00 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-18 1:00 Gustavo A. R. Silva [this message]
-- strict thread matches above, loose matches on Subject: below --
2017-06-07 20:27 [PATCH] scsi: remove useless variable assignment Gustavo A. R. Silva
2017-05-18 0:30 Gustavo A. R. Silva
2017-05-18 4:39 ` James Bottomley
2017-05-18 17:41 ` Gustavo A. R. Silva
2017-06-10 21:12 ` James Bottomley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170518010032.GA12354@embeddedgus \
--to=garsilva@embeddedor.com \
--cc=aacraid@adaptec.com \
--cc=jejb@linux.vnet.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).