ASoC: codecs: rk_dsm: fix audio aliasing

Set the dsm registers default value so that they can not be changed
as zero with regmap interface.

Change-Id: I1788fe2cabcb65ba09964a79d2fe20c057924839
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
This commit is contained in:
Jason Zhu
2024-10-28 19:23:52 +08:00
committed by Tao Huang
parent 4bfb13e85d
commit e27115aa16

View File

@@ -454,11 +454,19 @@ static const struct snd_soc_component_driver soc_codec_dev_rd = {
.num_controls = ARRAY_SIZE(rk_dsm_snd_controls),
};
static const struct reg_default rd_reg_defaults[] = {
{ DACVUCTL, 0x1 },
{ DACINT_DIV, 0x7 },
{ DACDSM_DIV, 0x3 },
};
static const struct regmap_config rd_regmap_config = {
.reg_bits = 32,
.reg_stride = 4,
.val_bits = 32,
.max_register = VERSION,
.reg_defaults = rd_reg_defaults,
.num_reg_defaults = ARRAY_SIZE(rd_reg_defaults),
.cache_type = REGCACHE_FLAT,
};