]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ASoC: tpa6130a2: Get rid of compile warning from tpa6130a2_power
authorJarkko Nikula <jhnikula@gmail.com>
Wed, 3 Nov 2010 14:39:00 +0000 (16:39 +0200)
committerTakashi Iwai <tiwai@suse.de>
Wed, 3 Nov 2010 14:50:46 +0000 (15:50 +0100)
Patch "ASoC: tpa6130a2: Fix unbalanced regulator disables" introduced a
compiler warning "‘ret’ may be used uninitialized in this function".
Initialize ret to zero to get rid of it and making sure that the function
does not return any random error code when the code is falling through.

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/soc/codecs/tpa6130a2.c

index 83b5631b13a84f3f946560ab099543a5b834c533..ee4fb201de60ca9ceb969fd00ce1292aad0a9330 100644 (file)
@@ -119,7 +119,7 @@ static int tpa6130a2_power(int power)
 {
        struct  tpa6130a2_data *data;
        u8      val;
-       int     ret;
+       int     ret = 0;
 
        BUG_ON(tpa6130a2_client == NULL);
        data = i2c_get_clientdata(tpa6130a2_client);