From 5f31bc4bc5fdd9c16e2be2b482d35e227cf36d66 Mon Sep 17 00:00:00 2001 From: Naveen Manohar Date: Wed, 14 Oct 2020 18:16:26 +0530 Subject: [PATCH] ASoC: codec: max98373-sdw: Avoid read of volatile registers during suspend If codec is suspended, a error of Device or resource busy occurs when executing amixer. Amixer accesses AMP_PATH_GAIN which is a volatile register and the regmap is set to cache_only when codec is suspended, so regmap can't get its data from regmap cache and return -EBUSY. Patch removes volatile attribute of such registers. Signed-off-by: Naveen Manohar --- sound/soc/codecs/max98373-sdw.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/sound/soc/codecs/max98373-sdw.c b/sound/soc/codecs/max98373-sdw.c index fa589d834f9aa9..0700c619b399cd 100644 --- a/sound/soc/codecs/max98373-sdw.c +++ b/sound/soc/codecs/max98373-sdw.c @@ -211,9 +211,6 @@ static bool max98373_readable_register(struct device *dev, unsigned int reg) static bool max98373_volatile_reg(struct device *dev, unsigned int reg) { switch (reg) { - case MAX98373_R2054_MEAS_ADC_PVDD_CH_READBACK: - case MAX98373_R2055_MEAS_ADC_THERM_CH_READBACK: - case MAX98373_R20B6_BDE_CUR_STATE_READBACK: case MAX98373_R21FF_REV_ID: /* SoundWire Control Port Registers */ case MAX98373_R0040_SCP_INIT_STAT_1 ... MAX98373_R0070_SCP_FRAME_CTLR: