[PATCH 4/4] SOUND: wm8900, use uninitialized_var(fll_div)

From: Jiri Slaby
Date: Tue Aug 25 2009 - 17:00:01 EST


To avoid a wrong compiler warning, use unitialized_var(fll_div) in
wm8900_set_fll.

If fll_div members are unitialized, we return before their use due to
error.

Signed-off-by: Jiri Slaby <jirislaby@xxxxxxxxx>
Cc: Takashi Iwai <tiwai@xxxxxxx>
Cc: Jaroslav Kysela <perex@xxxxxxxx>
---
sound/soc/codecs/wm8900.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/sound/soc/codecs/wm8900.c b/sound/soc/codecs/wm8900.c
index 5e9c855..255210a 100644
--- a/sound/soc/codecs/wm8900.c
+++ b/sound/soc/codecs/wm8900.c
@@ -747,7 +747,7 @@ static int wm8900_set_fll(struct snd_soc_codec *codec,
int fll_id, unsigned int freq_in, unsigned int freq_out)
{
struct wm8900_priv *wm8900 = codec->private_data;
- struct _fll_div fll_div;
+ struct _fll_div uninitialized_var(fll_div);
unsigned int reg;

if (wm8900->fll_in == freq_in && wm8900->fll_out == freq_out)
--
1.6.3.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/