All of lore.kernel.org
 help / color / mirror / Atom feed
* Fixed GPIO2 value assigned
@ 2023-02-13  7:20 Kailang
  2023-02-13  8:10 ` Takashi Iwai
  0 siblings, 1 reply; 2+ messages in thread
From: Kailang @ 2023-02-13  7:20 UTC (permalink / raw)
  To: Takashi Iwai (tiwai@suse.de); +Cc:  (alsa-devel@alsa-project.org)

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

Hi Takashi,

This fix was GPIO2 value 0x3 change to 0x4.
GPIO2 GPIO1 GPIO0
  1     0    0    ==> 0x4 ==> GPIO2 HIGH

GPIO2 GPIO1 GPIO0
  0     1    1    ==> 0x3 ==> GPIO0 and GPIO1 HIGH

BR,
Kailang


[-- Attachment #2: 0000-gpio2-high.patch --]
[-- Type: application/octet-stream, Size: 855 bytes --]

From 76ecb6b4597daf2d034ae7f9566fce611bb72d72 Mon Sep 17 00:00:00 2001
From: Kailang Yang <kailang@realtek.com>
Date: Mon, 13 Feb 2023 14:54:22 +0800
Subject: [PATCH] ALSA: hda/realtek - fixed wrong gpio assigned

GPIO2 PIN use for output. Mask Dir and Data need to assign for 0x4. Not 0x3.
This fixed was for Lenovo Desktop(0x17aa1056). GPIO2 use for AMP enable.

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 1134a493d225..14b84a1f43d3 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -832,7 +832,7 @@ static int alc_subsystem_id(struct hda_codec *codec, const hda_nid_t *ports)
 			alc_setup_gpio(codec, 0x02);
 			break;
 		case 7:
-			alc_setup_gpio(codec, 0x03);
+			alc_setup_gpio(codec, 0x04);
 			break;
 		case 5:
 		default:

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

* Re: Fixed GPIO2 value assigned
  2023-02-13  7:20 Fixed GPIO2 value assigned Kailang
@ 2023-02-13  8:10 ` Takashi Iwai
  0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2023-02-13  8:10 UTC (permalink / raw)
  To: Kailang; +Cc:  (alsa-devel@alsa-project.org)

On Mon, 13 Feb 2023 08:20:17 +0100,
Kailang wrote:
> 
> Hi Takashi,
> 
> This fix was GPIO2 value 0x3 change to 0x4.
> GPIO2 GPIO1 GPIO0
>   1     0    0    ==> 0x4 ==> GPIO2 HIGH
> 
> GPIO2 GPIO1 GPIO0
>   0     1    1    ==> 0x3 ==> GPIO0 and GPIO1 HIGH
> 
> BR,
> Kailang

Thanks, applied now.


Takashi

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

end of thread, other threads:[~2023-02-13  8:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-13  7:20 Fixed GPIO2 value assigned Kailang
2023-02-13  8:10 ` 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.