diff options
author | Christian Lamparter <chunkeey@web.de> | 2008-10-25 10:14:14 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-10-27 17:46:11 -0400 |
commit | f2c2e25554991f9c17bcd24028db5e1c50ecb0ad (patch) | |
tree | 23fc52708e86fefe93cbeca9eecb6c95086d91ca /drivers/net | |
parent | bc1b32d6bdd2d6f3fbee9a7c01c9b099f11c579c (diff) |
p54: fix build warnings
On Saturday 25 October 2008 10:24:10 Johannes Berg wrote:
> just FYI in case you haven't seen them. the p54 one looks like a genuine
> problem.
>
> drivers/net/wireless/p54/p54common.c: In function ‘p54_parse_eeprom’:
> drivers/net/wireless/p54/p54common.c:325: warning: ‘synth’ may be used uninitialized in this function
There you go. Yes, it is a genuine problem, if the device's eeprom is screwed really up.
Signed-off-by: Christian Lamparter <chunkeey@web.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/wireless/p54/p54common.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/net/wireless/p54/p54common.c b/drivers/net/wireless/p54/p54common.c index 2d022f83774c..827ca0384a4c 100644 --- a/drivers/net/wireless/p54/p54common.c +++ b/drivers/net/wireless/p54/p54common.c | |||
@@ -319,7 +319,7 @@ static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | |||
319 | void *tmp; | 319 | void *tmp; |
320 | int err; | 320 | int err; |
321 | u8 *end = (u8 *)eeprom + len; | 321 | u8 *end = (u8 *)eeprom + len; |
322 | u16 synth; | 322 | u16 synth = 0; |
323 | DECLARE_MAC_BUF(mac); | 323 | DECLARE_MAC_BUF(mac); |
324 | 324 | ||
325 | wrap = (struct eeprom_pda_wrap *) eeprom; | 325 | wrap = (struct eeprom_pda_wrap *) eeprom; |
@@ -422,7 +422,8 @@ static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | |||
422 | entry = (void *)entry + (entry_len + 1)*2; | 422 | entry = (void *)entry + (entry_len + 1)*2; |
423 | } | 423 | } |
424 | 424 | ||
425 | if (!priv->iq_autocal || !priv->output_limit || !priv->curve_data) { | 425 | if (!synth || !priv->iq_autocal || !priv->output_limit || |
426 | !priv->curve_data) { | ||
426 | printk(KERN_ERR "p54: not all required entries found in eeprom!\n"); | 427 | printk(KERN_ERR "p54: not all required entries found in eeprom!\n"); |
427 | err = -EINVAL; | 428 | err = -EINVAL; |
428 | goto err; | 429 | goto err; |