From: "Satish Kharat (satishkh)" <satishkh@cisco.com>
To: YueHaibing <yuehaibing@huawei.com>,
"Sesidhar Baddela (sebaddel)" <sebaddel@cisco.com>,
"Karan Tilak Kumar (kartilak)" <kartilak@cisco.com>,
"jejb@linux.ibm.com" <jejb@linux.ibm.com>,
"martin.petersen@oracle.com" <martin.petersen@oracle.com>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-scsi@vger.kernel.org" <linux-scsi@vger.kernel.org>
Subject: RE: [PATCH -next] scsi: fnic: Remove set but not used variable 'vdev'
Date: Fri, 25 Jan 2019 19:41:56 +0000 [thread overview]
Message-ID: <e2c3cd5a937045269760d703985392bb@XCH-RCD-012.cisco.com> (raw)
In-Reply-To: <20190125020014.11184-1-yuehaibing@huawei.com>
Looks good to me.
Acked-by: Satish Kharat <satishkh@cisco.com>
Satish Kharat
TECHNICAL LEADER.ENGINEERING
satishkh@cisco.com
Tel: +1 408 526 7504
Cisco Systems, Inc.
3800 Zanker Road
SAN JOSE
95134
United States
cisco.com
Think before you print.
This email may contain confidential and privileged material for the sole use of the intended recipient. Any review, use, distribution or disclosure by others is strictly prohibited. If you are not the intended recipient (or authorized to receive for the recipient), please contact the sender by reply email and delete all copies of this message.
http://www.cisco.com/c/en/us/about/legal/terms-sale-software-license-agreement/company-registration-information.html
-----Original Message-----
From: YueHaibing <yuehaibing@huawei.com>
Sent: Thursday, January 24, 2019 6:00 PM
To: Satish Kharat (satishkh) <satishkh@cisco.com>; Sesidhar Baddela (sebaddel) <sebaddel@cisco.com>; Karan Tilak Kumar (kartilak) <kartilak@cisco.com>; jejb@linux.ibm.com; martin.petersen@oracle.com
Cc: linux-kernel@vger.kernel.org; linux-scsi@vger.kernel.org; YueHaibing <yuehaibing@huawei.com>
Subject: [PATCH -next] scsi: fnic: Remove set but not used variable 'vdev'
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/scsi/fnic/vnic_wq.c: In function 'vnic_wq_alloc_bufs':
drivers/scsi/fnic/vnic_wq.c:50:19: warning:
variable 'vdev' set but not used [-Wunused-but-set-variable]
drivers/scsi/fnic/vnic_rq.c: In function 'vnic_rq_alloc_bufs':
drivers/scsi/fnic/vnic_rq.c:30:19: warning:
variable 'vdev' set but not used [-Wunused-but-set-variable]
It never used since introduction
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
drivers/scsi/fnic/vnic_rq.c | 3 ---
drivers/scsi/fnic/vnic_wq.c | 3 ---
2 files changed, 6 deletions(-)
diff --git a/drivers/scsi/fnic/vnic_rq.c b/drivers/scsi/fnic/vnic_rq.c index 74d2f2c..6a35b1b 100644
--- a/drivers/scsi/fnic/vnic_rq.c
+++ b/drivers/scsi/fnic/vnic_rq.c
@@ -27,12 +27,9 @@
static int vnic_rq_alloc_bufs(struct vnic_rq *rq) {
struct vnic_rq_buf *buf;
- struct vnic_dev *vdev;
unsigned int i, j, count = rq->ring.desc_count;
unsigned int blks = VNIC_RQ_BUF_BLKS_NEEDED(count);
- vdev = rq->vdev;
-
for (i = 0; i < blks; i++) {
rq->bufs[i] = kzalloc(VNIC_RQ_BUF_BLK_SZ, GFP_ATOMIC);
if (!rq->bufs[i]) {
diff --git a/drivers/scsi/fnic/vnic_wq.c b/drivers/scsi/fnic/vnic_wq.c index 74cfc56..015af2c 100644
--- a/drivers/scsi/fnic/vnic_wq.c
+++ b/drivers/scsi/fnic/vnic_wq.c
@@ -47,12 +47,9 @@ int vnic_wq_alloc_ring(struct vnic_dev *vdev, struct vnic_wq *wq, static int vnic_wq_alloc_bufs(struct vnic_wq *wq) {
struct vnic_wq_buf *buf;
- struct vnic_dev *vdev;
unsigned int i, j, count = wq->ring.desc_count;
unsigned int blks = VNIC_WQ_BUF_BLKS_NEEDED(count);
- vdev = wq->vdev;
-
for (i = 0; i < blks; i++) {
wq->bufs[i] = kzalloc(VNIC_WQ_BUF_BLK_SZ, GFP_ATOMIC);
if (!wq->bufs[i]) {
--
2.7.0
next prev parent reply other threads:[~2019-01-25 19:42 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-25 2:00 [PATCH -next] scsi: fnic: Remove set but not used variable 'vdev' YueHaibing
2019-01-25 19:41 ` Satish Kharat (satishkh) [this message]
2019-01-29 6:16 ` Martin K. Petersen
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=e2c3cd5a937045269760d703985392bb@XCH-RCD-012.cisco.com \
--to=satishkh@cisco.com \
--cc=jejb@linux.ibm.com \
--cc=kartilak@cisco.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
--cc=sebaddel@cisco.com \
--cc=yuehaibing@huawei.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).