[ALSA] ali5451 warning fix
authorAndrew Morton <akpm@linux-foundation.org>
Mon, 11 Jun 2007 10:23:31 +0000 (12:23 +0200)
committerJaroslav Kysela <perex@suse.cz>
Fri, 20 Jul 2007 09:11:27 +0000 (11:11 +0200)
sound/pci/ali5451/ali5451.c: In function 'snd_ali_prepare':
sound/pci/ali5451/ali5451.c:716: warning: 'R2' may be used uninitialized in this function

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
sound/pci/ali5451/ali5451.c

index e2c8666..05b4c86 100644 (file)
@@ -731,8 +731,7 @@ static void snd_ali_detect_spdif_rate(struct snd_ali *codec)
                return;
        }
 
-       count = 0;
-       while (count++ <= 50000) {
+       for (count = 0; count <= 50000; count++) {
                snd_ali_delay(codec, 6);
                bval = inb(ALI_REG(codec,ALI_SPDIF_CTRL + 1));
                R2 = bval & 0x1F;