From: Fengguang Wu <fengguang.wu@intel.com>
To: Saurav Kashyap <saurav.kashyap@qlogic.com>
Cc: Yuanhan Liu <yuanhan.liu@intel.com>,
kernel-janitors@vger.kernel.org,
James Bottomley <JBottomley@Parallels.com>,
Chad Dupuis <chad.dupuis@qlogic.com>,
linux-scsi@vger.kernel.org
Subject: [scsi:for-next 92/128] drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used uninitial
Date: Fri, 14 Sep 2012 23:57:28 +0000 [thread overview]
Message-ID: <20120914235728.GA32759@localhost> (raw)
Hi Saurav,
FYI, there are new compile warnings show up in
tree: git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git for-next
head: 71cfff4af0525891941199b142b759d00b293959
commit: 387fddaa3564503c9f82d091d2ebe390f3af62a1 [92/128] [SCSI] qla2xxx: Implementation of bidirectional.
config: x86_64-allmodconfig
All error/warnings:
drivers/scsi/qla2xxx/qla_isr.c: In function 'qla2x00_status_entry':
drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used uninitialized in this function [-Wmaybe-uninitialized]
drivers/scsi/qla2xxx/qla_isr.c:1558:11: note: 'rval' was declared here
It could be uninitialized due to the test in line 1598.
vim +1684 drivers/scsi/qla2xxx/qla_isr.c
1596 switch (comp_status) {
1597 case CS_COMPLETE:
> 1598 if (scsi_status = 0) {
1599 bsg_job->reply->reply_payload_rcv_len 1600
bsg_job->reply_payload.payload_len;
1601 rval = EXT_STATUS_OK;
1602 }
1603 goto done;
1604
...
1674 ql_dbg(ql_dbg_user, vha, 0x70bb,
1675 "Command completed with completion status=0x%x "
1676 "thread_id=%d\n", comp_status, thread_id);
1677 rval = EXT_STATUS_ERR;
1678 break;
1679 }
1680 bsg_job->reply->reply_payload_rcv_len = 0;
1681
1682 done:
1683 /* Return the vendor specific reply to API */
> 1684 bsg_job->reply->reply_data.vendor_reply.vendor_rsp[0] = rval;
1685 bsg_job->reply_len = sizeof(struct fc_bsg_reply);
1686 /* Always return DID_OK, bsg will send the vendor specific response
1687 * in this case only */
1688 sp->done(vha, sp, (DID_OK << 6));
1689
1690 }
---
0-DAY kernel build testing backend Open Source Technology Centre
Fengguang Wu, Yuanhan Liu Intel Corporation
WARNING: multiple messages have this Message-ID (diff)
From: Fengguang Wu <fengguang.wu@intel.com>
To: Saurav Kashyap <saurav.kashyap@qlogic.com>
Cc: Yuanhan Liu <yuanhan.liu@intel.com>,
kernel-janitors@vger.kernel.org,
James Bottomley <JBottomley@Parallels.com>,
Chad Dupuis <chad.dupuis@qlogic.com>,
linux-scsi@vger.kernel.org
Subject: [scsi:for-next 92/128] drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used uninitialized in this function
Date: Sat, 15 Sep 2012 07:57:28 +0800 [thread overview]
Message-ID: <20120914235728.GA32759@localhost> (raw)
Hi Saurav,
FYI, there are new compile warnings show up in
tree: git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git for-next
head: 71cfff4af0525891941199b142b759d00b293959
commit: 387fddaa3564503c9f82d091d2ebe390f3af62a1 [92/128] [SCSI] qla2xxx: Implementation of bidirectional.
config: x86_64-allmodconfig
All error/warnings:
drivers/scsi/qla2xxx/qla_isr.c: In function 'qla2x00_status_entry':
drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used uninitialized in this function [-Wmaybe-uninitialized]
drivers/scsi/qla2xxx/qla_isr.c:1558:11: note: 'rval' was declared here
It could be uninitialized due to the test in line 1598.
vim +1684 drivers/scsi/qla2xxx/qla_isr.c
1596 switch (comp_status) {
1597 case CS_COMPLETE:
> 1598 if (scsi_status == 0) {
1599 bsg_job->reply->reply_payload_rcv_len =
1600
bsg_job->reply_payload.payload_len;
1601 rval = EXT_STATUS_OK;
1602 }
1603 goto done;
1604
...
1674 ql_dbg(ql_dbg_user, vha, 0x70bb,
1675 "Command completed with completion status=0x%x "
1676 "thread_id=%d\n", comp_status, thread_id);
1677 rval = EXT_STATUS_ERR;
1678 break;
1679 }
1680 bsg_job->reply->reply_payload_rcv_len = 0;
1681
1682 done:
1683 /* Return the vendor specific reply to API */
> 1684 bsg_job->reply->reply_data.vendor_reply.vendor_rsp[0] = rval;
1685 bsg_job->reply_len = sizeof(struct fc_bsg_reply);
1686 /* Always return DID_OK, bsg will send the vendor specific response
1687 * in this case only */
1688 sp->done(vha, sp, (DID_OK << 6));
1689
1690 }
---
0-DAY kernel build testing backend Open Source Technology Centre
Fengguang Wu, Yuanhan Liu Intel Corporation
next reply other threads:[~2012-09-14 23:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-14 23:57 Fengguang Wu [this message]
2012-09-14 23:57 ` [scsi:for-next 92/128] drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used uninitialized in this function Fengguang Wu
2012-09-17 12:35 ` [scsi:for-next 92/128] drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used unini James Bottomley
2012-09-17 12:35 ` [scsi:for-next 92/128] drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used uninitialized in this function James Bottomley
2012-09-17 16:13 ` [scsi:for-next 92/128] drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used unini Saurav Kashyap
2012-09-17 16:13 ` [scsi:for-next 92/128] drivers/scsi/qla2xxx/qla_isr.c:1684:56: warning: 'rval' may be used uninitialized in this function Saurav Kashyap
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=20120914235728.GA32759@localhost \
--to=fengguang.wu@intel.com \
--cc=JBottomley@Parallels.com \
--cc=chad.dupuis@qlogic.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=saurav.kashyap@qlogic.com \
--cc=yuanhan.liu@intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.