summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/rt1011.c
diff options
context:
space:
mode:
authorJack Yu <jack.yu@realtek.com>2021-04-08 11:32:40 +0300
committerMark Brown <broonie@kernel.org>2021-04-08 17:08:49 +0300
commit44de8d80dba4e65f4fe7c17ea4be75e3cf9a902c (patch)
treec7969be3c1bbfff16f566156ab858fcd39f62feb /sound/soc/codecs/rt1011.c
parent6f68accaa8641b70b698da659216f82f87537869 (diff)
downloadlinux-44de8d80dba4e65f4fe7c17ea4be75e3cf9a902c.tar.xz
ASoC: rt1011: remove pack_id check in rt1011
For latest design, different package could use the same setting, therefore the check of pack_id will no longer be used. Signed-off-by: Jack Yu <jack.yu@realtek.com> Link: https://lore.kernel.org/r/4cbe1cd3b8664140889132464c7dee7b@realtek.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/rt1011.c')
-rw-r--r--sound/soc/codecs/rt1011.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/sound/soc/codecs/rt1011.c b/sound/soc/codecs/rt1011.c
index 098ecf13814d..bfe045367db3 100644
--- a/sound/soc/codecs/rt1011.c
+++ b/sound/soc/codecs/rt1011.c
@@ -2239,18 +2239,9 @@ static int rt1011_calibrate(struct rt1011_priv *rt1011, unsigned char cali_flag)
dc_offset |= (value & 0xffff);
dev_info(dev, "Gain1 offset=0x%x\n", dc_offset);
- /* check the package info. */
- regmap_read(rt1011->regmap, RT1011_EFUSE_MATCH_DONE, &value);
- if (value & 0x4)
- rt1011->pack_id = 1;
-
if (cali_flag) {
- if (rt1011->pack_id)
- regmap_write(rt1011->regmap, RT1011_ADC_SET_1, 0x292c);
- else
- regmap_write(rt1011->regmap, RT1011_ADC_SET_1, 0x2925);
-
+ regmap_write(rt1011->regmap, RT1011_ADC_SET_1, 0x2925);
/* Class D on */
regmap_write(rt1011->regmap, RT1011_CLASS_D_POS, 0x010e);
regmap_write(rt1011->regmap,
@@ -2376,10 +2367,7 @@ static void rt1011_calibration_work(struct work_struct *work)
rt1011_r0_load(rt1011);
}
- if (rt1011->pack_id)
- snd_soc_component_write(component, RT1011_ADC_SET_1, 0x292c);
- else
- snd_soc_component_write(component, RT1011_ADC_SET_1, 0x2925);
+ snd_soc_component_write(component, RT1011_ADC_SET_1, 0x2925);
}
static int rt1011_parse_dp(struct rt1011_priv *rt1011, struct device *dev)