All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ASoC: rt5682: Fix the issue of garbled recording after powerd_dbus_suspend
@ 2021-07-16  8:58 Oder Chiou
  2021-07-16 15:05 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Oder Chiou @ 2021-07-16  8:58 UTC (permalink / raw)
  To: broonie, lgirdwood
  Cc: Oder Chiou, jack.yu, alsa-devel, judyhsiao, albertchen,
	derek.fang, shumingf, flove

While using the DMIC recording, the garbled data will be captured by the
DMIC. It is caused by the critical power of PLL closed in the jack detect
function.

Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
---
 sound/soc/codecs/rt5682.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/sound/soc/codecs/rt5682.c b/sound/soc/codecs/rt5682.c
index e4c91571abae..abcd6f483788 100644
--- a/sound/soc/codecs/rt5682.c
+++ b/sound/soc/codecs/rt5682.c
@@ -973,10 +973,14 @@ int rt5682_headset_detect(struct snd_soc_component *component, int jack_insert)
 		rt5682_enable_push_button_irq(component, false);
 		snd_soc_component_update_bits(component, RT5682_CBJ_CTRL_1,
 			RT5682_TRIG_JD_MASK, RT5682_TRIG_JD_LOW);
-		if (!snd_soc_dapm_get_pin_status(dapm, "MICBIAS"))
+		if (!snd_soc_dapm_get_pin_status(dapm, "MICBIAS") &&
+			!snd_soc_dapm_get_pin_status(dapm, "PLL1") &&
+			!snd_soc_dapm_get_pin_status(dapm, "PLL2B"))
 			snd_soc_component_update_bits(component,
 				RT5682_PWR_ANLG_1, RT5682_PWR_MB, 0);
-		if (!snd_soc_dapm_get_pin_status(dapm, "Vref2"))
+		if (!snd_soc_dapm_get_pin_status(dapm, "Vref2") &&
+			!snd_soc_dapm_get_pin_status(dapm, "PLL1") &&
+			!snd_soc_dapm_get_pin_status(dapm, "PLL2B"))
 			snd_soc_component_update_bits(component,
 				RT5682_PWR_ANLG_1, RT5682_PWR_VREF2, 0);
 		snd_soc_component_update_bits(component, RT5682_PWR_ANLG_3,
-- 
2.31.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] ASoC: rt5682: Fix the issue of garbled recording after powerd_dbus_suspend
  2021-07-16  8:58 [PATCH] ASoC: rt5682: Fix the issue of garbled recording after powerd_dbus_suspend Oder Chiou
@ 2021-07-16 15:05 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2021-07-16 15:05 UTC (permalink / raw)
  To: lgirdwood, Oder Chiou
  Cc: jack.yu, alsa-devel, judyhsiao, albertchen, Mark Brown,
	derek.fang, shumingf, flove

On Fri, 16 Jul 2021 16:58:53 +0800, Oder Chiou wrote:
> While using the DMIC recording, the garbled data will be captured by the
> DMIC. It is caused by the critical power of PLL closed in the jack detect
> function.

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/1] ASoC: rt5682: Fix the issue of garbled recording after powerd_dbus_suspend
      commit: 6a503e1c455316fd0bfd8188c0a62cce7c5525ca

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-07-16 15:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-16  8:58 [PATCH] ASoC: rt5682: Fix the issue of garbled recording after powerd_dbus_suspend Oder Chiou
2021-07-16 15:05 ` Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.