All of lore.kernel.org
 help / color / mirror / Atom feed
* [ThinkPad] speaker no sound after system resume
@ 2018-03-22  8:25 Kailang
  2018-03-22  8:45 ` Takashi Iwai
  0 siblings, 1 reply; 2+ messages in thread
From: Kailang @ 2018-03-22  8:25 UTC (permalink / raw)
  To: Takashi Iwai (tiwai@suse.de); +Cc:  (alsa-devel@alsa-project.org)

[-- Attachment #1: Type: text/plain, Size: 318 bytes --]

Hi Takashi,
 
Attach patch will fix ThinkPad T580 family for resume issue.
 
It will have a chance speaker no sound after system resume.
To toggle NID 0x53 index 0x2 bit 15 will solve this issue.
This usage will also suitable with ALC256.
 
This patch also tested by Ubuntu QA.
Many Thanks.
 
BR,
Kailang

[-- Attachment #2: 0000-lenovo-spk-no-sound.patch --]
[-- Type: application/octet-stream, Size: 1280 bytes --]

From 0689d79d96690bc3475af34cfb2512f67156ecb3 Mon Sep 17 00:00:00 2001
From: Kailang Yang <kailang@realtek.com>
Date: Wed, 14 Mar 2018 16:08:57 +0800
Subject: [PATCH] ALSA: hda/realtek - Fix speaker no sound after system resume

It will have a chance speaker no sound after system resume.
To toggle NID 0x53 index 0x2 bit 15 will solve this issue.
This usage will also suitable with ALC256.

Signed-off-by: Kailang Yang <kailang@realtek.com>

diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 9af301c..e9b5173 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -3130,6 +3130,8 @@ static void alc256_init(struct hda_codec *codec)
 
 	alc_update_coef_idx(codec, 0x46, 3 << 12, 0);
 	alc_update_coefex_idx(codec, 0x57, 0x04, 0x0007, 0x4); /* Hight power */
+	alc_update_coefex_idx(codec, 0x53, 0x02, 0x8000, 1 << 15); /* Clear bit */
+	alc_update_coefex_idx(codec, 0x53, 0x02, 0x8000, 0 << 15);
 }
 
 static void alc256_shutup(struct hda_codec *codec)
@@ -7154,6 +7156,8 @@ static int patch_alc269(struct hda_codec *codec)
 		break;
 	case 0x10ec0257:
 		spec->codec_variant = ALC269_TYPE_ALC257;
+		spec->shutup = alc256_shutup;
+		spec->init_hook = alc256_init;
 		spec->gen.mixer_nid = 0;
 		break;
 	case 0x10ec0215:

[-- Attachment #3: Type: text/plain, Size: 0 bytes --]



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

* Re: [ThinkPad] speaker no sound after system resume
  2018-03-22  8:25 [ThinkPad] speaker no sound after system resume Kailang
@ 2018-03-22  8:45 ` Takashi Iwai
  0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2018-03-22  8:45 UTC (permalink / raw)
  To: Kailang; +Cc:  (alsa-devel@alsa-project.org)

On Thu, 22 Mar 2018 09:25:07 +0100,
Kailang wrote:
> 
> Hi Takashi,
>  
> Attach patch will fix ThinkPad T580 family for resume issue.
>  
> It will have a chance speaker no sound after system resume.
> To toggle NID 0x53 index 0x2 bit 15 will solve this issue.
> This usage will also suitable with ALC256.
>  
> This patch also tested by Ubuntu QA.
> Many Thanks.
>  
> BR,
> Kailang

OK, applied now this one, too.
Thanks!

Takashi

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

end of thread, other threads:[~2018-03-22  8:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-22  8:25 [ThinkPad] speaker no sound after system resume Kailang
2018-03-22  8:45 ` Takashi Iwai

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.