From: "John W. Linville" <linville@tuxdriver.com>
To: Prarit Bhargava <prarit@redhat.com>
Cc: linux-wireless@vger.kernel.org, ath9k-devel@atheros.com
Subject: Re: [PATCH]: ath: Fix uninitialized variable warnings
Date: Fri, 28 May 2010 13:34:31 -0400 [thread overview]
Message-ID: <20100528173431.GB2405@tuxdriver.com> (raw)
In-Reply-To: <20100527181052.23905.67123.sendpatchset@prarit.bos.redhat.com>
On Thu, May 27, 2010 at 02:14:54PM -0400, Prarit Bhargava wrote:
> Fixes 'make -j24 CONFIG_DEBUG_SECTION_MISMATCH=y' warning:
>
> drivers/net/wireless/ath/ath9k/eeprom_4k.c: In function ‘ath9k_hw_get_4k_gain_boundaries_pdadcs.clone.1’:
> drivers/net/wireless/ath/ath9k/eeprom_4k.c:311: error: ‘minPwrT4’ may be used uninitialized in this function
> drivers/net/wireless/ath/ath9k/eeprom_9287.c: In function ‘ath9k_hw_get_AR9287_gain_boundaries_pdadcs’:
> drivers/net/wireless/ath/ath9k/eeprom_9287.c:302: error: ‘minPwrT4’ may be used uninitialized in this function
> drivers/net/wireless/ath/ath9k/eeprom_def.c: In function ‘ath9k_hw_get_def_gain_boundaries_pdadcs.clone.0’:
> drivers/net/wireless/ath/ath9k/eeprom_def.c:679: error: ‘minPwrT4’ may be used uninitialized in this function
>
> Signed-off-by: Prarit Bhargava <prarit@redhat.com>
It looks to me like minPwrT4 will get initialized as long as
numXpdGains is non-zero in all cases. Anyone know if this is true?
It's probably not a big deal, but better to avoid an unnecessary
memset if we can. Maybe unitialized_var is the better choice?
John
--
John W. Linville Someday the world will need a hero, and you
linville@tuxdriver.com might be all we have. Be ready.
next parent reply other threads:[~2010-05-28 17:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20100527181052.23905.67123.sendpatchset@prarit.bos.redhat.com>
2010-05-28 17:34 ` John W. Linville [this message]
2010-05-28 20:44 ` [PATCH]: ath: Fix uninitialized variable warnings Pavel Roskin
2010-06-17 22:41 ` Prarit Bhargava
2010-06-19 17:33 ` Pavel Roskin
2010-05-27 18:15 Prarit Bhargava
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=20100528173431.GB2405@tuxdriver.com \
--to=linville@tuxdriver.com \
--cc=ath9k-devel@atheros.com \
--cc=linux-wireless@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 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.