Skip to content

Commit e5448d7

Browse files
Dan Murphybroonie
authored andcommitted
ASoC: tlv320adcx140: Fix various style errors and warnings
Fix white space issues and remove else case where it was not needed. Convert "static const char *" to "static const char * const" Fixes: 689c765 ("ASoC: tlv320adcx140: Add the tlv320adcx140 codec driver family") Signed-off-by: Dan Murphy <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent e0c6ecf commit e5448d7

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

sound/soc/codecs/tlv320adcx140.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -218,8 +218,8 @@ static const struct snd_kcontrol_new in4_resistor_controls[] = {
218218
};
219219

220220
/* Analog/Digital Selection */
221-
static const char *adcx140_mic_sel_text[] = {"Analog", "Line In", "Digital"};
222-
static const char *adcx140_analog_sel_text[] = {"Analog", "Line In"};
221+
static const char * const adcx140_mic_sel_text[] = {"Analog", "Line In", "Digital"};
222+
static const char * const adcx140_analog_sel_text[] = {"Analog", "Line In"};
223223

224224
static SOC_ENUM_SINGLE_DECL(adcx140_mic1p_enum,
225225
ADCX140_CH1_CFG0, 5,
@@ -598,7 +598,7 @@ static int adcx140_reset(struct adcx140_priv *adcx140)
598598
gpiod_direction_output(adcx140->gpio_reset, 1);
599599
} else {
600600
ret = regmap_write(adcx140->regmap, ADCX140_SW_RESET,
601-
ADCX140_RESET);
601+
ADCX140_RESET);
602602
}
603603

604604
/* 8.4.2: wait >= 10 ms after entering sleep mode. */
@@ -841,7 +841,7 @@ static int adcx140_codec_probe(struct snd_soc_component *component)
841841
if (ret)
842842
goto out;
843843

844-
if(adcx140->supply_areg == NULL)
844+
if (adcx140->supply_areg == NULL)
845845
sleep_cfg_val |= ADCX140_AREG_INTERNAL;
846846

847847
ret = regmap_write(adcx140->regmap, ADCX140_SLEEP_CFG, sleep_cfg_val);
@@ -942,8 +942,8 @@ static int adcx140_i2c_probe(struct i2c_client *i2c,
942942
if (IS_ERR(adcx140->supply_areg)) {
943943
if (PTR_ERR(adcx140->supply_areg) == -EPROBE_DEFER)
944944
return -EPROBE_DEFER;
945-
else
946-
adcx140->supply_areg = NULL;
945+
946+
adcx140->supply_areg = NULL;
947947
} else {
948948
ret = regulator_enable(adcx140->supply_areg);
949949
if (ret) {

0 commit comments

Comments
 (0)