sound: soc: codecs: cs35l41: fix variable declaration
authorStricted <info@stricted.net>
Sat, 25 Apr 2020 23:53:50 +0000 (23:53 +0000)
committerCosmin Tanislav <demonsingur@gmail.com>
Mon, 22 Apr 2024 17:24:02 +0000 (20:24 +0300)
Change-Id: Ief5c96b73b59670c71025b879776a50b9b435d38

sound/soc/codecs/cs35l41.c

index 757af395571ac5422e2d76d3071ff2032166c4bf..a25191513acac53fcc54dcc2b02057aa2b7a5aea 100755 (executable)
@@ -799,6 +799,7 @@ static int cs35l41_main_amp_event(struct snd_soc_dapm_widget *w,
        struct snd_soc_codec *codec = snd_soc_dapm_to_codec(w->dapm);
        struct cs35l41_private *cs35l41 = snd_soc_codec_get_drvdata(codec);
        int ret = 0,status = -1;
+       int i;
 
        switch (event) {
        case SND_SOC_DAPM_POST_PMU:
@@ -846,7 +847,7 @@ static int cs35l41_main_amp_event(struct snd_soc_dapm_widget *w,
                regmap_multi_reg_write_bypassed(cs35l41->regmap,
                                        cs35l41_pdn_patch,
                                        ARRAY_SIZE(cs35l41_pdn_patch));
-               for (int i = 0; i < 5; i++) {
+               for (i = 0; i < 5; i++) {
                        msleep(5);
                        regmap_read(cs35l41->regmap, CS35L41_IRQ1_STATUS1 , &status);
                        dev_err(cs35l41->dev, "%s  cs35l41_main_amp_event status=%x\n",__func__,status);