* [PATCH] ALSA: hda/cirrus: Fix broken audio on hardware with two CS42L42 codecs.
@ 2023-09-04 16:00 Vitaly Rodionov
2023-09-04 16:10 ` Takashi Iwai
0 siblings, 1 reply; 2+ messages in thread
From: Vitaly Rodionov @ 2023-09-04 16:00 UTC (permalink / raw)
To: Takashi Iwai, Jaroslav Kysela
Cc: alsa-devel, patches, linux-kernel, Vitaly Rodionov
Recently in v6.3-rc1 there was a change affecting behaviour of hrtimers
(commit 0c52310f260014d95c1310364379772cb74cf82d) and causing
few issues on platforms with two CS42L42 codecs. Canonical/Dell
has reported an issue with Vostro-3910.
We need to increase this value by 15ms.
Link: https://bugs.launchpad.net/somerville/+bug/2031060
Fixes: 9fb9fa18fb50 (ALSA: hda/cirrus: Add extra 10 ms delay to allow PLL settle and lock.)
Signed-off-by: Vitaly Rodionov <vitalyr@opensource.cirrus.com>
---
sound/pci/hda/patch_cs8409.c | 2 +-
sound/pci/hda/patch_cs8409.h | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/sound/pci/hda/patch_cs8409.c b/sound/pci/hda/patch_cs8409.c
index 0ba1fbcbb21e..627899959ffe 100644
--- a/sound/pci/hda/patch_cs8409.c
+++ b/sound/pci/hda/patch_cs8409.c
@@ -888,7 +888,7 @@ static void cs42l42_resume(struct sub_codec *cs42l42)
/* Initialize CS42L42 companion codec */
cs8409_i2c_bulk_write(cs42l42, cs42l42->init_seq, cs42l42->init_seq_num);
- usleep_range(30000, 35000);
+ msleep(CS42L42_INIT_TIMEOUT_MS);
/* Clear interrupts, by reading interrupt status registers */
cs8409_i2c_bulk_read(cs42l42, irq_regs, ARRAY_SIZE(irq_regs));
diff --git a/sound/pci/hda/patch_cs8409.h b/sound/pci/hda/patch_cs8409.h
index 2a8dfb4ff046..937e9387abdc 100644
--- a/sound/pci/hda/patch_cs8409.h
+++ b/sound/pci/hda/patch_cs8409.h
@@ -229,6 +229,7 @@ enum cs8409_coefficient_index_registers {
#define CS42L42_I2C_SLEEP_US (2000)
#define CS42L42_PDN_TIMEOUT_US (250000)
#define CS42L42_PDN_SLEEP_US (2000)
+#define CS42L42_INIT_TIMEOUT_MS (45)
#define CS42L42_FULL_SCALE_VOL_MASK (2)
#define CS42L42_FULL_SCALE_VOL_0DB (1)
#define CS42L42_FULL_SCALE_VOL_MINUS6DB (0)
--
2.34.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] ALSA: hda/cirrus: Fix broken audio on hardware with two CS42L42 codecs.
2023-09-04 16:00 [PATCH] ALSA: hda/cirrus: Fix broken audio on hardware with two CS42L42 codecs Vitaly Rodionov
@ 2023-09-04 16:10 ` Takashi Iwai
0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2023-09-04 16:10 UTC (permalink / raw)
To: Vitaly Rodionov
Cc: Takashi Iwai, Jaroslav Kysela, alsa-devel, patches, linux-kernel
On Mon, 04 Sep 2023 18:00:33 +0200,
Vitaly Rodionov wrote:
>
> Recently in v6.3-rc1 there was a change affecting behaviour of hrtimers
> (commit 0c52310f260014d95c1310364379772cb74cf82d) and causing
> few issues on platforms with two CS42L42 codecs. Canonical/Dell
> has reported an issue with Vostro-3910.
> We need to increase this value by 15ms.
>
> Link: https://bugs.launchpad.net/somerville/+bug/2031060
> Fixes: 9fb9fa18fb50 (ALSA: hda/cirrus: Add extra 10 ms delay to allow PLL settle and lock.)
>
> Signed-off-by: Vitaly Rodionov <vitalyr@opensource.cirrus.com>
Thanks, applied now (with a slight correction of Fixes tag; it needs
quotes around the commit subject).
Takashi
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-09-04 16:11 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-09-04 16:00 [PATCH] ALSA: hda/cirrus: Fix broken audio on hardware with two CS42L42 codecs Vitaly Rodionov
2023-09-04 16:10 ` Takashi Iwai
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®