From: David Miller <davem@davemloft.net>
To: prarit@redhat.com
Cc: netdev@vger.kernel.org, mchan@broadcom.com
Subject: Re: [PATCH]: bnx2: Fix uninitialized variable warning in bnx2_disable_forced_2g5()
Date: Thu, 27 May 2010 16:26:33 -0700 (PDT) [thread overview]
Message-ID: <20100527.162633.39169784.davem@davemloft.net> (raw)
In-Reply-To: <20100527220856.25418.86593.sendpatchset@prarit.bos.redhat.com>
From: Prarit Bhargava <prarit@redhat.com>
Date: Thu, 27 May 2010 18:13:01 -0400
> Fix warning:
>
> drivers/net/bnx2.c: In function 'bnx2_disable_forced_2g5':
> drivers/net/bnx2.c:1489: warning: 'bmcr' may be used uninitialized in this function
>
> Signed-off-by: Prarit Bhargava <prarit@redhat.com>
This is another bad patch, you're hiding a bug by making this warning
go away.
If bnx2_read_phy() in fact does not initialize "bmcr" we might
want to do something about that instead of just blindly using
whatever garbage is in that local variable.
Please stop making these patches without applying at least some
intelligence to the analysis of why these warnings are being
printed at all.
None of these cases you're posting patches for are situations where
the compiler simply can't see the control flow properly, they are real
issues.
Thanks.
prev parent reply other threads:[~2010-05-27 23:26 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-27 22:13 [PATCH]: bnx2: Fix uninitialized variable warning in bnx2_disable_forced_2g5() Prarit Bhargava
2010-05-27 23:26 ` David Miller [this message]
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=20100527.162633.39169784.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=mchan@broadcom.com \
--cc=netdev@vger.kernel.org \
--cc=prarit@redhat.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).