From 3012948b395ddc3b3659701c1b0c7506988cb770 Mon Sep 17 00:00:00 2001 From: Angel Pons Date: Fri, 6 Dec 2019 00:31:22 +0100 Subject: mb/**/hda_verb.c: Clean up formatting Change-Id: Ibe2d92990d0074266aa05ada749e9dad55e609a2 Signed-off-by: Angel Pons Reviewed-on: https://review.coreboot.org/c/coreboot/+/37541 Tested-by: build bot (Jenkins) Reviewed-by: HAOUAS Elyes --- src/mainboard/lenovo/l520/hda_verb.c | 41 ++------ src/mainboard/lenovo/s230u/hda_verb.c | 89 +++++++---------- src/mainboard/lenovo/t410/hda_verb.c | 33 +++---- src/mainboard/lenovo/t420/hda_verb.c | 33 +++---- src/mainboard/lenovo/t420s/hda_verb.c | 51 ++++------ src/mainboard/lenovo/t430/hda_verb.c | 41 ++------ .../lenovo/t430s/variants/t430s/hda_verb.c | 108 +++++++-------------- .../lenovo/t430s/variants/t431s/hda_verb.c | 41 ++------ src/mainboard/lenovo/t440p/hda_verb.c | 6 +- src/mainboard/lenovo/t520/hda_verb.c | 51 ++++------ src/mainboard/lenovo/t530/hda_verb.c | 105 +++++++------------- src/mainboard/lenovo/t60/hda_verb.c | 8 +- src/mainboard/lenovo/x1_carbon_gen1/hda_verb.c | 41 ++------ src/mainboard/lenovo/x201/hda_verb.c | 59 +++-------- src/mainboard/lenovo/x220/hda_verb.c | 78 ++++++--------- src/mainboard/lenovo/x230/hda_verb.c | 106 +++++++------------- src/mainboard/lenovo/x60/hda_verb.c | 6 +- 17 files changed, 280 insertions(+), 617 deletions(-) (limited to 'src/mainboard/lenovo') diff --git a/src/mainboard/lenovo/l520/hda_verb.c b/src/mainboard/lenovo/l520/hda_verb.c index bca06f5e56..6ab0938466 100644 --- a/src/mainboard/lenovo/l520/hda_verb.c +++ b/src/mainboard/lenovo/l520/hda_verb.c @@ -18,56 +18,27 @@ #include const u32 cim_verb_data[] = { - 0x10ec0269, /* Codec Vendor / Device ID: Realtek */ - 0x17aa21de, /* Subsystem ID */ - - 11, /* Number of 4 dword sets */ - /* NID 0x01: Subsystem ID. */ + 0x10ec0269, /* Codec Vendor / Device ID: Realtek */ + 0x17aa21de, /* Subsystem ID */ + 11, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x0, 0x17aa21de), - - /* NID 0x12. */ AZALIA_PIN_CFG(0x0, 0x12, 0x99a30920), - - /* NID 0x14. */ AZALIA_PIN_CFG(0x0, 0x14, 0x99130110), - - /* NID 0x17. */ AZALIA_PIN_CFG(0x0, 0x17, 0x411111f0), - - /* NID 0x18. */ AZALIA_PIN_CFG(0x0, 0x18, 0x03a11830), - - /* NID 0x19. */ AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), - - /* NID 0x1a. */ AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), - - /* NID 0x1b. */ AZALIA_PIN_CFG(0x0, 0x1b, 0x411111f0), - - /* NID 0x1d. */ AZALIA_PIN_CFG(0x0, 0x1d, 0x40079a2d), - - /* NID 0x1e. */ AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), - - /* NID 0x21. */ AZALIA_PIN_CFG(0x0, 0x21, 0x0321101f), - 0x80862805, /* Codec Vendor / Device ID: Intel */ - 0x80860101, /* Subsystem ID */ - 4, /* Number of 4 dword sets */ - /* NID 0x01: Subsystem ID. */ + 0x80862805, /* Codec Vendor / Device ID: Intel */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* NID 0x05. */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* NID 0x06. */ AZALIA_PIN_CFG(0x3, 0x06, 0x18560020), - - /* NID 0x07. */ AZALIA_PIN_CFG(0x3, 0x07, 0x18560030), }; diff --git a/src/mainboard/lenovo/s230u/hda_verb.c b/src/mainboard/lenovo/s230u/hda_verb.c index 85150e51a5..b096487d48 100644 --- a/src/mainboard/lenovo/s230u/hda_verb.c +++ b/src/mainboard/lenovo/s230u/hda_verb.c @@ -15,22 +15,19 @@ * GNU General Public License for more details. */ +/* Bits 31:28 - Codec Address */ +/* Bits 27:20 - NID */ +/* Bits 19:8 - Verb ID */ +/* Bits 7:0 - Payload */ #include const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x10ec0269, // Codec Vendor / Device ID: Realtek ALC269VC - 0x17aa21fa, // Subsystem ID - 12, // Number of 4 dword sets - - /* Bits 31:28 - Codec Address */ - /* Bits 27:20 - NID */ - /* Bits 19:8 - Verb ID */ - /* Bits 7:0 - Payload */ - - /* NID 0x01 - NodeInfo */ - AZALIA_SUBVENDOR(0x0, 0x17AA21FA), + /* --- Codec #0 --- */ + 0x10ec0269, /* Codec Vendor / Device ID: Realtek ALC269VC */ + 0x17aa21fa, /* Subsystem ID */ + 12, /* Number of 4 dword sets */ + AZALIA_SUBVENDOR(0x0, 0x17aa21fa), /* * PIN_CFG: @@ -64,61 +61,49 @@ const u32 cim_verb_data[] = { * 3:0 Sequence * For stream channel to in/out mapping */ - - /* - * NID 0x12 - Digital MIC - * Fixed function, mic in, digital - */ + /* Digital MIC: Fixed function, mic in, digital */ AZALIA_PIN_CFG(0x0, 0x12, 0x90a60940), - /* - * NID 0x14 - SPK out - * Fixed function, speaker, analog - */ + + /* SPK out: Fixed function, speaker, analog */ AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), - /* - * NID 0x15 - HP out - * Location left, headphone out, 1/8" jack, black - */ + + /* HP out: Location left, headphone out, 1/8" jack, black */ AZALIA_PIN_CFG(0x0, 0x15, 0x03211020), - /* NID 0x17 - ? (Unconnected) */ + + /* Unknown: (Unconnected) */ AZALIA_PIN_CFG(0x0, 0x17, 0x411111f0), - /* - * NID 0x18 - MIC1 in - * Location left, mic in, 1/8" jack, black - */ + + /* MIC1 in: Location left, mic in, 1/8" jack, black */ AZALIA_PIN_CFG(0x0, 0x18, 0x03a11830), - /* NID 0x19 - MIC2 in (Unconnected) */ + + /* MIC2 in: (Unconnected) */ AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), - /* NID 0x1a - Line1 in (Unconnected) */ + + /* Line1 in: (Unconnected) */ AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), - /* NID 0x1b - Line2 in (Unconnected) */ + + /* Line2 in: (Unconnected) */ AZALIA_PIN_CFG(0x0, 0x1b, 0x411111f0), - /* NID 0x1d - PCBEEP */ + + /* PCBEEP */ AZALIA_PIN_CFG(0x0, 0x1d, 0x40148605), - /* NID 0x1e - S/PDIF out (Unconnected) */ - AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), - 0x01470740, // Enable output for NID 0x14 (Speaker out) - 0x015707C0, // Enable output & HP amp for NID 0x15 (HP out) - 0x01870724, // Enable Vrefout NID 0x18 (MIC1 in) - 0x00170500, // Set power state to D0 + /* S/PDIF out: (Unconnected) */ + AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), - /* coreboot specific header */ - 0x80862806, // Codec Vendor / Device ID: Intel PantherPoint HDMI - 0x80860101, // Subsystem ID - 4, // Number of IDs + 0x01470740, /* Enable output for NID 0x14 (Speaker out) */ + 0x015707C0, /* Enable output & HP amp for NID 0x15 (HP out) */ + 0x01870724, /* Enable Vrefout NID 0x18 (MIC1 in) */ + 0x00170500, /* Set power state to D0 */ - /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x80860101 */ + /* --- Codec #3 --- */ + 0x80862806, /* Codec Vendor / Device ID: Intel PantherPoint HDMI */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* Pin Complex (NID 0x05) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* Pin Complex (NID 0x06) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x06, 0x18560020), - - /* Pin Complex (NID 0x07) Digital Out at Int HDMI */ - AZALIA_PIN_CFG(0x3, 0x07, 0x58560030) + AZALIA_PIN_CFG(0x3, 0x07, 0x58560030), }; const u32 pc_beep_verbs[] = { diff --git a/src/mainboard/lenovo/t410/hda_verb.c b/src/mainboard/lenovo/t410/hda_verb.c index 2b871f6280..7569b6b606 100644 --- a/src/mainboard/lenovo/t410/hda_verb.c +++ b/src/mainboard/lenovo/t410/hda_verb.c @@ -17,28 +17,25 @@ #include const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x14F15069, /* Codec Vendor / Device ID: Conexant CX20585 */ - 0x17AA214C, /* Subsystem ID */ + 0x14f15069, /* Codec Vendor / Device ID: Conexant CX20585 */ + 0x17aa214c, /* Subsystem ID */ 11, /* Number of 4 dword sets */ - - AZALIA_SUBVENDOR(0x0, 0x17AA214C), - AZALIA_PIN_CFG(0x0, 0x19, 0x042110F0), - AZALIA_PIN_CFG(0x0, 0x1A, 0x61A190F0), - AZALIA_PIN_CFG(0x0, 0x1B, 0x04A110F0), - AZALIA_PIN_CFG(0x0, 0x1C, 0x612140F0), - AZALIA_PIN_CFG(0x0, 0x1D, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x1E, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x1F, 0x901701F0), - AZALIA_PIN_CFG(0x0, 0x20, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x22, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x23, 0x90A601F0), + AZALIA_SUBVENDOR(0x0, 0x17aa214c), + AZALIA_PIN_CFG(0x0, 0x19, 0x042110f0), + AZALIA_PIN_CFG(0x0, 0x1a, 0x61a190f0), + AZALIA_PIN_CFG(0x0, 0x1b, 0x04a110f0), + AZALIA_PIN_CFG(0x0, 0x1c, 0x612140f0), + AZALIA_PIN_CFG(0x0, 0x1d, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1e, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1f, 0x901701f0), + AZALIA_PIN_CFG(0x0, 0x20, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x22, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x23, 0x90a601f0), 0x80862804, /* Codec Vendor / Device ID: Intel Ibexpeak HDMI. */ - 0x17AA21B5, /* Subsystem ID */ + 0x17aa21b5, /* Subsystem ID */ 4, /* Number of 4 dword sets */ - - AZALIA_SUBVENDOR(0x3, 0x17AA21B5), + AZALIA_SUBVENDOR(0x3, 0x17aa21b5), AZALIA_PIN_CFG(0x3, 0x04, 0x18560010), AZALIA_PIN_CFG(0x3, 0x05, 0x18560020), AZALIA_PIN_CFG(0x3, 0x06, 0x18560030), diff --git a/src/mainboard/lenovo/t420/hda_verb.c b/src/mainboard/lenovo/t420/hda_verb.c index 9287d4adbe..4c68c73080 100644 --- a/src/mainboard/lenovo/t420/hda_verb.c +++ b/src/mainboard/lenovo/t420/hda_verb.c @@ -14,29 +14,18 @@ * GNU General Public License for more details. */ -/* Vendor Name : Conexant - * Vendor ID : 0x14f1506e - * Subsystem ID : 0x17aa21d2 - * Revision ID : 0x100002 - */ - - -#include - -const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x14f1506e, // Codec Vendor / Device ID: Conexant CX20590 - Schematic show CX20672 - 0x17aa21ce, // Subsystem ID - 13, // Number of 4 dword sets - /* Bits 31:28 - Codec Address */ /* Bits 27:20 - NID */ /* Bits 19:8 - Verb ID */ /* Bits 7:0 - Payload */ -/* NID 0x01 - NodeInfo */ - AZALIA_SUBVENDOR(0x0, 0x17AA21D2), +#include +const u32 cim_verb_data[] = { + 0x14f1506e, /* Codec VID / DID: Conexant CX20590 - schematic shows CX20672 */ + 0x17aa21ce, /* Subsystem ID */ + 13, /* Number of 4 dword sets */ + AZALIA_SUBVENDOR(0x0, 0x17aa21d2), AZALIA_PIN_CFG(0x0, 0x12, 0x90a60140), AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), AZALIA_PIN_CFG(0x0, 0x15, 0x03211020), @@ -49,14 +38,14 @@ const u32 cim_verb_data[] = { AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), /* Misc entries */ - 0x00B707C0, /* Enable PortB as Output with HP amp */ - 0x00D70740, /* Enable PortD as Output */ - 0x0017A200, /* Disable ClkEn of PortSenseTst */ - 0x0017C621, /* Slave Port - Port A used as microphone input for + 0x00b707C0, /* Enable PortB as Output with HP amp */ + 0x00d70740, /* Enable PortD as Output */ + 0x0017a200, /* Disable ClkEn of PortSenseTst */ + 0x0017c621, /* Slave Port - Port A used as microphone input for combo Jack Master Port - Port B used for Jack Presence Detect Enable Combo Jack Detection */ - 0x0017A208, /* Enable ClkEn of PortSenseTst */ + 0x0017a208, /* Enable ClkEn of PortSenseTst */ 0x00170500, /* Set power state to D0 */ 0x00170500, /* Padding */ 0x00170500, /* Padding */ diff --git a/src/mainboard/lenovo/t420s/hda_verb.c b/src/mainboard/lenovo/t420s/hda_verb.c index 8a9c3e5b77..9d315d7911 100644 --- a/src/mainboard/lenovo/t420s/hda_verb.c +++ b/src/mainboard/lenovo/t420s/hda_verb.c @@ -14,49 +14,38 @@ * GNU General Public License for more details. */ -/* Vendor Name : Conexant - * Vendor ID : 0x14f1506e - * Subsystem ID : 0x17aa21d2 - * Revision ID : 0x100002 - */ - - -#include - -const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x14f1506e, // Codec Vendor / Device ID: Conexant CX20590 - Schematic show CX20672 - 0x17aa21d2, // Subsystem ID - 13, // Number of 4 dword sets - /* Bits 31:28 - Codec Address */ /* Bits 27:20 - NID */ /* Bits 19:8 - Verb ID */ /* Bits 7:0 - Payload */ -/* NID 0x01 - NodeInfo */ - AZALIA_SUBVENDOR(0x0, 0x17AA21D2), +#include +const u32 cim_verb_data[] = { + 0x14f1506e, /* Codec VID / DID: Conexant CX20590 - schematic shows CX20672 */ + 0x17aa21d2, /* Subsystem ID */ + 13, /* Number of 4 dword sets */ + AZALIA_SUBVENDOR(0x0, 0x17aa21d2), AZALIA_PIN_CFG(0x0, 0x19, 0x04211040), - AZALIA_PIN_CFG(0x0, 0x1A, 0x61A19050), - AZALIA_PIN_CFG(0x0, 0x1B, 0x04A11060), - AZALIA_PIN_CFG(0x0, 0x1C, 0x6121401F), - AZALIA_PIN_CFG(0x0, 0x1D, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x1E, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x1F, 0x90170110), - AZALIA_PIN_CFG(0x0, 0x20, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x22, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x23, 0x90A60170), + AZALIA_PIN_CFG(0x0, 0x1a, 0x61a19050), + AZALIA_PIN_CFG(0x0, 0x1b, 0x04a11060), + AZALIA_PIN_CFG(0x0, 0x1c, 0x6121401f), + AZALIA_PIN_CFG(0x0, 0x1d, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1e, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1f, 0x90170110), + AZALIA_PIN_CFG(0x0, 0x20, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x22, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x23, 0x90a60170), /* Misc entries */ - 0x00B707C0, /* Enable PortB as Output with HP amp */ - 0x00D70740, /* Enable PortD as Output */ - 0x0017A200, /* Disable ClkEn of PortSenseTst */ - 0x0017C621, /* Slave Port - Port A used as microphone input for + 0x00b707C0, /* Enable PortB as Output with HP amp */ + 0x00d70740, /* Enable PortD as Output */ + 0x0017a200, /* Disable ClkEn of PortSenseTst */ + 0x0017c621, /* Slave Port - Port A used as microphone input for combo Jack Master Port - Port B used for Jack Presence Detect Enable Combo Jack Detection */ - 0x0017A208, /* Enable ClkEn of PortSenseTst */ + 0x0017a208, /* Enable ClkEn of PortSenseTst */ 0x00170500, /* Set power state to D0 */ 0x00170500, /* Padding */ 0x00170500, /* Padding */ diff --git a/src/mainboard/lenovo/t430/hda_verb.c b/src/mainboard/lenovo/t430/hda_verb.c index 255198f044..a8f67277f8 100644 --- a/src/mainboard/lenovo/t430/hda_verb.c +++ b/src/mainboard/lenovo/t430/hda_verb.c @@ -16,56 +16,27 @@ #include const u32 cim_verb_data[] = { - 0x10ec0269, /* Codec Vendor / Device ID: Realtek */ - 0x17aa21f3, /* Subsystem ID */ - - 11, /* Number of 4 dword sets */ - /* NID 0x01: Subsystem ID. */ + 0x10ec0269, /* Codec Vendor / Device ID: Realtek */ + 0x17aa21f3, /* Subsystem ID */ + 11, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x0, 0x17aa21f3), - - /* NID 0x12. */ AZALIA_PIN_CFG(0x0, 0x12, 0x90a60140), - - /* NID 0x14. */ AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), - - /* NID 0x15. */ AZALIA_PIN_CFG(0x0, 0x15, 0x03211020), - - /* NID 0x17. */ AZALIA_PIN_CFG(0x0, 0x17, 0x411111f0), - - /* NID 0x18. */ AZALIA_PIN_CFG(0x0, 0x18, 0x03a11830), - - /* NID 0x19. */ AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), - - /* NID 0x1a. */ AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), - - /* NID 0x1b. */ AZALIA_PIN_CFG(0x0, 0x1b, 0x411111f0), - - /* NID 0x1d. */ AZALIA_PIN_CFG(0x0, 0x1d, 0x40138205), - - /* NID 0x1e. */ AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), - 0x80862806, /* Codec Vendor / Device ID: Intel */ - 0x80860101, /* Subsystem ID */ - 4, /* Number of 4 dword sets */ - /* NID 0x01: Subsystem ID. */ + 0x80862806, /* Codec Vendor / Device ID: Intel */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* NID 0x05. */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* NID 0x06. */ AZALIA_PIN_CFG(0x3, 0x06, 0x18560020), - - /* NID 0x07. */ AZALIA_PIN_CFG(0x3, 0x07, 0x18560030), }; diff --git a/src/mainboard/lenovo/t430s/variants/t430s/hda_verb.c b/src/mainboard/lenovo/t430s/variants/t430s/hda_verb.c index c5c17b8061..b8f6bfed16 100644 --- a/src/mainboard/lenovo/t430s/variants/t430s/hda_verb.c +++ b/src/mainboard/lenovo/t430s/variants/t430s/hda_verb.c @@ -14,110 +14,72 @@ * GNU General Public License for more details. */ -/* Vendor Name : Realtek - * Vendor ID : 0x10ec0269 - * Subsystem ID : 0x17aa21fb - * Revision ID : 0x100203 - */ - - -#include - -const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x10ec0269, // Codec Vendor / Device ID: Realtek ALC269VC - 0x17aa21fb, // Subsystem ID - 19, // Number of 4 dword sets - /* Bits 31:28 - Codec Address */ /* Bits 27:20 - NID */ /* Bits 19:8 - Verb ID */ /* Bits 7:0 - Payload */ -/* NID 0x01 - NodeInfo */ - AZALIA_SUBVENDOR(0x0, 0x17AA21FB), +#include -/* NID 0x0A - External Microphone Connector - * Config=0x04A11020 (External,Right; MicIn,3.5mm; Black,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0A, 0x04A11020), +const u32 cim_verb_data[] = { + /* --- Codec #0 --- */ + 0x10ec0269, /* Codec Vendor / Device ID: Realtek ALC269VC */ + 0x17aa21fb, /* Subsystem ID */ + 19, /* Number of 4 dword sets */ + AZALIA_SUBVENDOR(0x0, 0x17aa21fb), -/* NID 0x0B - Headphone Connector - * Config=0x0421101F (External,Right; HP,3.5mm; Black,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0B, 0x0421101F), + /* Ext. Microphone Connector: External,Right; MicIn,3.5mm; Black,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0a, 0x04a11020), -/* NID 0x0C - Not connected - * Config=0x40F000F0 (N/A,N/A; Other,Unknown; Unknown,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0C, 0x40F000F0), + /* Headphones Connector: External,Right; HP,3.5mm; Black,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0b, 0x0421101f), -/* NID 0x0D - Internal Speakers - * Config=0x90170110 (Fixed,Int; Speaker,Other Analog; Unknown,nJD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0D, 0x90170110), + /* Not connected: N/A,N/A; Other,Unknown; Unknown,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0c, 0x40f000f0), -/* NID 0x0F - Not connected - * Config=0x40F000F0 - */ - AZALIA_PIN_CFG(0x0, 0x0F, 0x40F000F0), + /* Internal Speakers Fixed,Int; Speaker,Other Analog; Unknown,nJD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0d, 0x90170110), -/* NID 0x11 - Internal Microphone - * Config=0xD5A30140 (Fixed internal,Top; Mic In,ATIPI; Unknown,nJD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x12, 0x90A60140), + /* Not connected */ + AZALIA_PIN_CFG(0x0, 0x0f, 0x40f000f0), + AZALIA_PIN_CFG(0x0, 0x12, 0x90a60140), AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), AZALIA_PIN_CFG(0x0, 0x15, 0x03211020), - AZALIA_PIN_CFG(0x0, 0x17, 0x411111F0), - AZALIA_PIN_CFG(0x0, 0x18, 0x03A11830), - AZALIA_PIN_CFG(0x0, 0x19, 0x411111F0), + AZALIA_PIN_CFG(0x0, 0x17, 0x411111f0), + AZALIA_PIN_CFG(0x0, 0x18, 0x03a11830), + AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), 0x01970804, 0x01870803, 0x01470740, 0x00970600, - AZALIA_PIN_CFG(0x0, 0x1A, 0x411111F0), - AZALIA_PIN_CFG(0x0, 0x1B, 0x411111F0), - AZALIA_PIN_CFG(0x0, 0x1D, 0x40138205), - AZALIA_PIN_CFG(0x0, 0x1E, 0x411111F0), + AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), + AZALIA_PIN_CFG(0x0, 0x1b, 0x411111f0), + AZALIA_PIN_CFG(0x0, 0x1d, 0x40138205), + AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), /* Misc entries */ 0x00370600, 0x00270600, - 0x00B707C0, /* Enable PortB as Output with HP amp */ - 0x00D70740, /* Enable PortD as Output */ - 0x0017A200, /* Disable ClkEn of PortSenseTst */ - 0x0017C621, /* Slave Port - Port A used as microphone input for + 0x00b707C0, /* Enable PortB as Output with HP amp */ + 0x00d70740, /* Enable PortD as Output */ + 0x0017a200, /* Disable ClkEn of PortSenseTst */ + 0x0017c621, /* Slave Port - Port A used as microphone input for combo Jack Master Port - Port B used for Jack Presence Detect Enable Combo Jack Detection */ - 0x0017A208, /* Enable ClkEn of PortSenseTst */ + 0x0017a208, /* Enable ClkEn of PortSenseTst */ 0x00170500, /* Set power state to D0 */ - /* --- Next Codec --- */ - -/* Vendor Name : Intel - * Vendor ID : 0x80862806 - * Subsystem ID : 0x80860101 - * Revision ID : 0x100000 - */ - /* coreboot specific header */ - 0x80862806, // Codec Vendor / Device ID: Intel PantherPoint HDMI - 0x80860101, // Subsystem ID - 4, // Number of IDs - - /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x80860101 */ + /* --- Codec #3 --- */ + 0x80862806, /* Codec Vendor / Device ID: Intel PantherPoint HDMI */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* Pin Complex (NID 0x05) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* Pin Complex (NID 0x06) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x06, 0x18560020), - - /* Pin Complex (NID 0x07) Digital Out at Int HDMI */ - AZALIA_PIN_CFG(0x3, 0x07, 0x18560030) + AZALIA_PIN_CFG(0x3, 0x07, 0x18560030), }; const u32 pc_beep_verbs[] = { diff --git a/src/mainboard/lenovo/t430s/variants/t431s/hda_verb.c b/src/mainboard/lenovo/t430s/variants/t431s/hda_verb.c index 1c5d376247..5d47099db5 100644 --- a/src/mainboard/lenovo/t430s/variants/t431s/hda_verb.c +++ b/src/mainboard/lenovo/t430s/variants/t431s/hda_verb.c @@ -18,56 +18,27 @@ #include const u32 cim_verb_data[] = { - 0x10ec0269, /* Codec Vendor / Device ID: Realtek */ - 0x17aa2208, /* Subsystem ID */ - - 11, /* Number of 4 dword sets */ - /* NID 0x01: Subsystem ID. */ + 0x10ec0269, /* Codec Vendor / Device ID: Realtek */ + 0x17aa2208, /* Subsystem ID */ + 11, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x0, 0x17aa2208), - - /* NID 0x12. */ AZALIA_PIN_CFG(0x0, 0x12, 0x90a60140), - - /* NID 0x14. */ AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), - - /* NID 0x15. */ AZALIA_PIN_CFG(0x0, 0x15, 0x03211020), - - /* NID 0x17. */ AZALIA_PIN_CFG(0x0, 0x17, 0x40008000), - - /* NID 0x18. */ AZALIA_PIN_CFG(0x0, 0x18, 0x03a11030), - - /* NID 0x19. */ AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), - - /* NID 0x1a. */ AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), - - /* NID 0x1b. */ AZALIA_PIN_CFG(0x0, 0x1b, 0x411111f0), - - /* NID 0x1d. */ AZALIA_PIN_CFG(0x0, 0x1d, 0x40f38205), - - /* NID 0x1e. */ AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), - 0x80862806, /* Codec Vendor / Device ID: Intel */ - 0x80860101, /* Subsystem ID */ - 4, /* Number of 4 dword sets */ - /* NID 0x01: Subsystem ID. */ + 0x80862806, /* Codec Vendor / Device ID: Intel */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* NID 0x05. */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* NID 0x06. */ AZALIA_PIN_CFG(0x3, 0x06, 0x18560020), - - /* NID 0x07. */ AZALIA_PIN_CFG(0x3, 0x07, 0x18560030), }; diff --git a/src/mainboard/lenovo/t440p/hda_verb.c b/src/mainboard/lenovo/t440p/hda_verb.c index 9527312340..791638d760 100644 --- a/src/mainboard/lenovo/t440p/hda_verb.c +++ b/src/mainboard/lenovo/t440p/hda_verb.c @@ -18,9 +18,9 @@ #include const u32 cim_verb_data[] = { - 0x10ec0292, /* Codec Vendor / Device ID: Realtek */ - 0x17aa220e, /* Subsystem ID */ - 12, /* Number of 4 dword sets */ + 0x10ec0292, /* Codec Vendor / Device ID: Realtek */ + 0x17aa220e, /* Subsystem ID */ + 12, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x0, 0x17aa220e), AZALIA_PIN_CFG(0x0, 0x12, 0x90a60130), AZALIA_PIN_CFG(0x0, 0x13, 0x40000000), diff --git a/src/mainboard/lenovo/t520/hda_verb.c b/src/mainboard/lenovo/t520/hda_verb.c index 2d10e35b19..46d7d9484d 100644 --- a/src/mainboard/lenovo/t520/hda_verb.c +++ b/src/mainboard/lenovo/t520/hda_verb.c @@ -14,49 +14,38 @@ * GNU General Public License for more details. */ -/* Vendor Name : Conexant - * Vendor ID : 0x14f1506e - * Subsystem ID : 0x17aa21cf - * Revision ID : 0x100000 - */ - - -#include - -const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x14f1506e, // Codec Vendor / Device ID: Conexant CX20590 - Schematic shows CX20672 - 0x17aa21cf, // Subsystem ID - 13, // Number of 4 dword sets - /* Bits 31:28 - Codec Address */ /* Bits 27:20 - NID */ /* Bits 19:8 - Verb ID */ /* Bits 7:0 - Payload */ -/* NID 0x01 - NodeInfo */ - AZALIA_SUBVENDOR(0x0, 0x17AA21CF), +#include +const u32 cim_verb_data[] = { + 0x14f1506e, /* Codec VID / DID: Conexant CX20590 - Schematic shows CX20672 */ + 0x17aa21cf, /* Subsystem ID */ + 13, /* Number of 4 dword sets */ + AZALIA_SUBVENDOR(0x0, 0x17aa21cf), AZALIA_PIN_CFG(0x0, 0x19, 0x04211040), - AZALIA_PIN_CFG(0x0, 0x1A, 0x61A19050), - AZALIA_PIN_CFG(0x0, 0x1B, 0x04A11060), - AZALIA_PIN_CFG(0x0, 0x1C, 0x6121401F), - AZALIA_PIN_CFG(0x0, 0x1D, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x1E, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x1F, 0x90170110), - AZALIA_PIN_CFG(0x0, 0x20, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x22, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x23, 0x90A60170), + AZALIA_PIN_CFG(0x0, 0x1a, 0x61a19050), + AZALIA_PIN_CFG(0x0, 0x1b, 0x04a11060), + AZALIA_PIN_CFG(0x0, 0x1c, 0x6121401f), + AZALIA_PIN_CFG(0x0, 0x1d, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1e, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1f, 0x90170110), + AZALIA_PIN_CFG(0x0, 0x20, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x22, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x23, 0x90a60170), /* Misc entries */ - 0x00B707C0, /* Enable PortB as Output with HP amp */ - 0x00D70740, /* Enable PortD as Output */ - 0x0017A200, /* Disable ClkEn of PortSenseTst */ - 0x0017C621, /* Slave Port - Port A used as microphone input for + 0x00b707c0, /* Enable PortB as Output with HP amp */ + 0x00d70740, /* Enable PortD as Output */ + 0x0017a200, /* Disable ClkEn of PortSenseTst */ + 0x0017c621, /* Slave Port - Port A used as microphone input for combo Jack Master Port - Port B used for Jack Presence Detect Enable Combo Jack Detection */ - 0x0017A208, /* Enable ClkEn of PortSenseTst */ + 0x0017a208, /* Enable ClkEn of PortSenseTst */ 0x00170500, /* Set power state to D0 */ 0x00170500, /* Padding */ 0x00170500, /* Padding */ diff --git a/src/mainboard/lenovo/t530/hda_verb.c b/src/mainboard/lenovo/t530/hda_verb.c index f8876aa1c8..5ed12b4882 100644 --- a/src/mainboard/lenovo/t530/hda_verb.c +++ b/src/mainboard/lenovo/t530/hda_verb.c @@ -14,108 +14,71 @@ * GNU General Public License for more details. */ -/* Vendor Name : IDT - * Vendor ID : 0x10ec0269 - * Subsystem ID : 0x17aa21fa - * Revision ID : 0x100303 - */ - - -#include - -const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x10ec0269, // Codec Vendor / Device ID: Realtek ALC269VC - 0x17aa21fa, // Subsystem ID - 18, // Number of 4 dword sets - /* Bits 31:28 - Codec Address */ /* Bits 27:20 - NID */ /* Bits 19:8 - Verb ID */ /* Bits 7:0 - Payload */ -/* NID 0x01 - NodeInfo */ - AZALIA_SUBVENDOR(0x0, 0x17AA21FA), +#include -/* NID 0x0A - External Microphone Connector - * Config=0x04A11020 (External,Right; MicIn,3.5mm; Black,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0A, 0x04A11020), +const u32 cim_verb_data[] = { + 0x10ec0269, /* Codec Vendor / Device ID: Realtek ALC269VC */ + 0x17aa21fa, /* Subsystem ID */ + 18, /* Number of 4 dword sets */ + AZALIA_SUBVENDOR(0x0, 0x17aa21fa), -/* NID 0x0B - Headphone Connector - * Config=0x0421101F (External,Right; HP,3.5mm; Black,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0B, 0x0421101F), + /* Ext. Microphone Connector: External,Right; MicIn,3.5mm; Black,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0a, 0x04a11020), -/* NID 0x0C - Not connected - * Config=0x40F000F0 (N/A,N/A; Other,Unknown; Unknown,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0C, 0x40F000F0), + /* Headphones Connector: External,Right; HP,3.5mm; Black,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0b, 0x0421101f), -/* NID 0x0D - Internal Speakers - * Config=0x90170110 (Fixed,Int; Speaker,Other Analog; Unknown,nJD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0D, 0x90170110), + /* Not connected: N/A,N/A; Other,Unknown; Unknown,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0c, 0x40f000f0), -/* NID 0x0F - Not connected - * Config=0x40F000F0 - */ - AZALIA_PIN_CFG(0x0, 0x0F, 0x40F000F0), + /* Internal Speakers Fixed,Int; Speaker,Other Analog; Unknown,nJD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0d, 0x90170110), -/* NID 0x11 - Internal Microphone - * Config=0xD5A30140 (Fixed internal,Top; Mic In,ATIPI; Unknown,nJD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x11, 0xD5A30140), - AZALIA_PIN_CFG(0x0, 0x12, 0x90A60140), + /* Not connected */ + AZALIA_PIN_CFG(0x0, 0x0f, 0x40f000f0), + + /* Internal Microphone: Fixed,Int,Top; Mic In,ATIPI; Unknown,nJD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x11, 0xd5a30140), + AZALIA_PIN_CFG(0x0, 0x12, 0x90a60140), AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), AZALIA_PIN_CFG(0x0, 0x15, 0x03211020), - AZALIA_PIN_CFG(0x0, 0x18, 0x03A11830), - AZALIA_PIN_CFG(0x0, 0x19, 0x411111F0), + AZALIA_PIN_CFG(0x0, 0x18, 0x03a11830), + AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), 0x01970804, 0x01870803, 0x01470740, 0x00970600, - AZALIA_PIN_CFG(0x0, 0x1A, 0x411111F0), - AZALIA_PIN_CFG(0x0, 0x1D, 0x40138205), - AZALIA_PIN_CFG(0x0, 0x1E, 0x411111F0), + AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), + AZALIA_PIN_CFG(0x0, 0x1d, 0x40138205), + AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), /* Misc entries */ 0x00370600, 0x00270600, - 0x00B707C0, /* Enable PortB as Output with HP amp */ - 0x00D70740, /* Enable PortD as Output */ - 0x0017A200, /* Disable ClkEn of PortSenseTst */ - 0x0017C621, /* Slave Port - Port A used as microphone input for + 0x00b707C0, /* Enable PortB as Output with HP amp */ + 0x00d70740, /* Enable PortD as Output */ + 0x0017a200, /* Disable ClkEn of PortSenseTst */ + 0x0017c621, /* Slave Port - Port A used as microphone input for combo Jack Master Port - Port B used for Jack Presence Detect Enable Combo Jack Detection */ - 0x0017A208, /* Enable ClkEn of PortSenseTst */ + 0x0017a208, /* Enable ClkEn of PortSenseTst */ 0x00170500, /* Set power state to D0 */ - /* --- Next Codec --- */ - -/* Vendor Name : Intel - * Vendor ID : 0x80862806 - * Subsystem ID : 0x80860101 - * Revision ID : 0x100000 - */ - /* coreboot specific header */ - 0x80862806, // Codec Vendor / Device ID: Intel PantherPoint HDMI - 0x80860101, // Subsystem ID - 4, // Number of IDs - - /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x80860101 */ + /* --- Codec #3 --- */ + 0x80862806, /* Codec Vendor / Device ID: Intel PantherPoint HDMI */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* Pin Complex (NID 0x05) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* Pin Complex (NID 0x06) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x06, 0x18560020), - - /* Pin Complex (NID 0x07) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x07, 0x18560030) }; diff --git a/src/mainboard/lenovo/t60/hda_verb.c b/src/mainboard/lenovo/t60/hda_verb.c index 216696b22b..22eec0a798 100644 --- a/src/mainboard/lenovo/t60/hda_verb.c +++ b/src/mainboard/lenovo/t60/hda_verb.c @@ -14,12 +14,10 @@ #include const u32 cim_verb_data[] = { - 0x11d41981, /* Codec Vendor / Device ID: Analog Devices AD1981 */ - 0x17aa2025, /* Subsystem ID */ - 11, /* Number of 4 dword sets */ - + 0x11d41981, /* Codec Vendor / Device ID: Analog Devices AD1981 */ + 0x17aa2025, /* Subsystem ID */ + 11, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x0, 0x17aa2025), - AZALIA_PIN_CFG(0, 0x05, 0xc3014110), AZALIA_PIN_CFG(0, 0x06, 0x4221401f), AZALIA_PIN_CFG(0, 0x07, 0x591311f0), diff --git a/src/mainboard/lenovo/x1_carbon_gen1/hda_verb.c b/src/mainboard/lenovo/x1_carbon_gen1/hda_verb.c index 1946286cff..8ea325805c 100644 --- a/src/mainboard/lenovo/x1_carbon_gen1/hda_verb.c +++ b/src/mainboard/lenovo/x1_carbon_gen1/hda_verb.c @@ -17,56 +17,27 @@ #include const u32 cim_verb_data[] = { - 0x10ec0269, /* Codec Vendor / Device ID: Realtek */ - 0x17aa21f9, /* Subsystem ID */ - - 11, /* Number of 4 dword sets */ - /* NID 0x01: Subsystem ID. */ + 0x10ec0269, /* Codec Vendor / Device ID: Realtek */ + 0x17aa21f9, /* Subsystem ID */ + 11, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x0, 0x17aa21f9), - - /* NID 0x12. */ AZALIA_PIN_CFG(0x0, 0x12, 0x90a60140), - - /* NID 0x14. */ AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), - - /* NID 0x15. */ AZALIA_PIN_CFG(0x0, 0x15, 0x03211020), - - /* NID 0x17. */ AZALIA_PIN_CFG(0x0, 0x17, 0x411111f0), - - /* NID 0x18. */ AZALIA_PIN_CFG(0x0, 0x18, 0x03a11830), - - /* NID 0x19. */ AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), - - /* NID 0x1a. */ AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), - - /* NID 0x1b. */ AZALIA_PIN_CFG(0x0, 0x1b, 0x411111f0), - - /* NID 0x1d. */ AZALIA_PIN_CFG(0x0, 0x1d, 0x40138205), - - /* NID 0x1e. */ AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), - 0x80862806, /* Codec Vendor / Device ID: Intel */ - 0x80860101, /* Subsystem ID */ - 4, /* Number of 4 dword sets */ - /* NID 0x01: Subsystem ID. */ + 0x80862806, /* Codec Vendor / Device ID: Intel */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* Pin Complex (NID 0x05) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* Pin Complex (NID 0x06) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x06, 0x58560020), - - /* Pin Complex (NID 0x07) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x07, 0x58560030), }; diff --git a/src/mainboard/lenovo/x201/hda_verb.c b/src/mainboard/lenovo/x201/hda_verb.c index 25a87f57f2..ee12d3adcd 100644 --- a/src/mainboard/lenovo/x201/hda_verb.c +++ b/src/mainboard/lenovo/x201/hda_verb.c @@ -17,58 +17,27 @@ #include const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x14F15069, /* Codec Vendor / Device ID: Conexant CX20585 */ - 0x17AA2155, /* Subsystem ID */ + 0x14f15069, /* Codec Vendor / Device ID: Conexant CX20585 */ + 0x17aa2155, /* Subsystem ID */ 11, /* Number of 4 dword sets */ - - /* NID 0x01: Subsystem ID. */ - AZALIA_SUBVENDOR(0x0, 0x17AA2155), - - /* NID 0x19: Headphone jack. */ - AZALIA_PIN_CFG(0x0, 0x19, 0x042140F0), - - /* NID 0x1A: Dock mic jack. */ - AZALIA_PIN_CFG(0x0, 0x1A, 0x61A190F0), - - /* NID 0x1B: Mic jack. */ - AZALIA_PIN_CFG(0x0, 0x1B, 0x04A190F0), - - /* NID 0x1C: Dock headphone jack. */ - AZALIA_PIN_CFG(0x0, 0x1C, 0x612140F0), - - /* NID 0x1D: EAPD detect. */ - AZALIA_PIN_CFG(0x0, 0x1D, 0x601700F0), - - /* NID 0x1E */ - AZALIA_PIN_CFG(0x0, 0x1E, 0x40F001F0), - - /* NID 0x1F */ - AZALIA_PIN_CFG(0x0, 0x1F, 0x901701F0), - - /* NID 0x20 */ - AZALIA_PIN_CFG(0x0, 0x20, 0x40F001F0), - - /* NID 0x22 */ - AZALIA_PIN_CFG(0x0, 0x22, 0x40F001F0), - - /* NID 0x23: Internal mic boost volume. */ - AZALIA_PIN_CFG(0x0, 0x23, 0x90A601F0), + AZALIA_SUBVENDOR(0x0, 0x17aa2155), + AZALIA_PIN_CFG(0x0, 0x19, 0x042140f0), /* Headphone jack */ + AZALIA_PIN_CFG(0x0, 0x1a, 0x61a190f0), /* Dock mic jack */ + AZALIA_PIN_CFG(0x0, 0x1b, 0x04a190f0), /* Mic jack */ + AZALIA_PIN_CFG(0x0, 0x1c, 0x612140f0), /* Dock headphone jack */ + AZALIA_PIN_CFG(0x0, 0x1d, 0x601700f0), /* EAPD detect */ + AZALIA_PIN_CFG(0x0, 0x1e, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1f, 0x901701f0), + AZALIA_PIN_CFG(0x0, 0x20, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x22, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x23, 0x90a601f0), /* Internal mic boost volume */ 0x80862804, /* Codec Vendor / Device ID: Intel Ibexpeak HDMI. */ 0x17aa21b5, /* Subsystem ID */ 4, /* Number of 4 dword sets */ - - /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x17aa21b5 */ - AZALIA_SUBVENDOR(0x3, 0x17AA21B5), - - /* NID 0x04. */ + AZALIA_SUBVENDOR(0x3, 0x17aa21b5), AZALIA_PIN_CFG(0x3, 0x04, 0x58560010), - - /* NID 0x05. */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560020), - - /* NID 0x06. */ AZALIA_PIN_CFG(0x3, 0x06, 0x58560030), }; diff --git a/src/mainboard/lenovo/x220/hda_verb.c b/src/mainboard/lenovo/x220/hda_verb.c index b7b670d77a..00751c4d6f 100644 --- a/src/mainboard/lenovo/x220/hda_verb.c +++ b/src/mainboard/lenovo/x220/hda_verb.c @@ -14,76 +14,52 @@ * GNU General Public License for more details. */ -/* Vendor Name : Conexant - * Vendor ID : 0x14f1506e - * Subsystem ID : 0x17aa21db - * Revision ID : 0x100002 - */ - - -#include - -const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x14f1506e, // Codec Vendor / Device ID: Conexant CX20590 - 0x17aa21db, // Subsystem ID - 13, // Number of 4 dword sets - /* Bits 31:28 - Codec Address */ /* Bits 27:20 - NID */ /* Bits 19:8 - Verb ID */ /* Bits 7:0 - Payload */ -/* NID 0x01 - NodeInfo */ - AZALIA_SUBVENDOR(0x0, 0x17AA21DB), +#include + +const u32 cim_verb_data[] = { + /* --- Codec #0 --- */ + 0x14f1506e, /* Codec Vendor / Device ID: Conexant CX20590 */ + 0x17aa21db, /* Subsystem ID */ + 13, /* Number of 4 dword sets */ + AZALIA_SUBVENDOR(0x0, 0x17aa21db), AZALIA_PIN_CFG(0x0, 0x19, 0x04211040), - AZALIA_PIN_CFG(0x0, 0x1A, 0x61A19050), - AZALIA_PIN_CFG(0x0, 0x1B, 0x04A11060), - AZALIA_PIN_CFG(0x0, 0x1C, 0x6121401F), - AZALIA_PIN_CFG(0x0, 0x1D, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x1E, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x1F, 0x90170110), - AZALIA_PIN_CFG(0x0, 0x20, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x22, 0x40F001F0), - AZALIA_PIN_CFG(0x0, 0x23, 0x90A60170), + AZALIA_PIN_CFG(0x0, 0x1a, 0x61a19050), + AZALIA_PIN_CFG(0x0, 0x1b, 0x04a11060), + AZALIA_PIN_CFG(0x0, 0x1c, 0x6121401f), + AZALIA_PIN_CFG(0x0, 0x1d, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1e, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x1f, 0x90170110), + AZALIA_PIN_CFG(0x0, 0x20, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x22, 0x40f001f0), + AZALIA_PIN_CFG(0x0, 0x23, 0x90a60170), /* Misc entries */ - 0x00B707C0, /* Enable PortB as Output with HP amp */ - 0x00D70740, /* Enable PortD as Output */ - 0x0017A200, /* Disable ClkEn of PortSenseTst */ - 0x0017C621, /* Slave Port - Port A used as microphone input for + 0x00b707C0, /* Enable PortB as Output with HP amp */ + 0x00d70740, /* Enable PortD as Output */ + 0x0017a200, /* Disable ClkEn of PortSenseTst */ + 0x0017c621, /* Slave Port - Port A used as microphone input for combo Jack Master Port - Port B used for Jack Presence Detect Enable Combo Jack Detection */ - 0x0017A208, /* Enable ClkEn of PortSenseTst */ + 0x0017a208, /* Enable ClkEn of PortSenseTst */ 0x00170500, /* Set power state to D0 */ 0x00170500, /* Padding */ 0x00170500, /* Padding */ - /* --- Next Codec --- */ - -/* Vendor Name : Intel - * Vendor ID : 0x80862806 - * Subsystem ID : 0x80860101 - * Revision ID : 0x100000 - */ - /* coreboot specific header */ - 0x80862805, // Codec Vendor / Device ID: Intel PantherPoint HDMI - 0x80860101, // Subsystem ID - 4, // Number of IDs - - /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x80860101 */ + /* --- Codec #3 --- */ + 0x80862806, /* Codec Vendor / Device ID: Intel PantherPoint HDMI */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* Pin Complex (NID 0x05) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* Pin Complex (NID 0x06) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x06, 0x18560020), - - /* Pin Complex (NID 0x07) Digital Out at Int HDMI */ - AZALIA_PIN_CFG(0x3, 0x07, 0x18560030) + AZALIA_PIN_CFG(0x3, 0x07, 0x18560030), }; const u32 pc_beep_verbs[] = { diff --git a/src/mainboard/lenovo/x230/hda_verb.c b/src/mainboard/lenovo/x230/hda_verb.c index 0393ff50a6..ff1a2dd153 100644 --- a/src/mainboard/lenovo/x230/hda_verb.c +++ b/src/mainboard/lenovo/x230/hda_verb.c @@ -14,67 +14,45 @@ * GNU General Public License for more details. */ -/* Vendor Name : IDT - * Vendor ID : 0x10ec0269 - * Subsystem ID : 0x17aa21fa - * Revision ID : 0x100303 - */ - - -#include - -const u32 cim_verb_data[] = { - /* coreboot specific header */ - 0x10ec0269, // Codec Vendor / Device ID: Realtek ALC269VC - 0x17aa21fa, // Subsystem ID - 19, // Number of 4 dword sets - /* Bits 31:28 - Codec Address */ /* Bits 27:20 - NID */ /* Bits 19:8 - Verb ID */ /* Bits 7:0 - Payload */ -/* NID 0x01 - NodeInfo */ - AZALIA_SUBVENDOR(0x0, 0x17AA21FA), +#include -/* NID 0x0A - External Microphone Connector - * Config=0x04A11020 (External,Right; MicIn,3.5mm; Black,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0A, 0x04A11020), +const u32 cim_verb_data[] = { + /* --- Codec #0 --- */ + 0x10ec0269, /* Codec Vendor / Device ID: Realtek ALC269VC */ + 0x17aa21fa, /* Subsystem ID */ + 19, /* Number of 4 dword sets */ + AZALIA_SUBVENDOR(0x0, 0x17aa21fa), -/* NID 0x0B - Headphone Connector - * Config=0x0421101F (External,Right; HP,3.5mm; Black,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0B, 0x0421101F), + /* Ext. Microphone Connector: External,Right; MicIn,3.5mm; Black,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0a, 0x04a11020), -/* NID 0x0C - Not connected - * Config=0x40F000F0 (N/A,N/A; Other,Unknown; Unknown,JD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0C, 0x40F000F0), + /* Headphones Connector: External,Right; HP,3.5mm; Black,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0b, 0x0421101f), -/* NID 0x0D - Internal Speakers - * Config=0x90170110 (Fixed,Int; Speaker,Other Analog; Unknown,nJD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x0D, 0x90170110), + /* Not connected: N/A,N/A; Other,Unknown; Unknown,JD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0c, 0x40f000f0), -/* NID 0x0F - Not connected - * Config=0x40F000F0 - */ - AZALIA_PIN_CFG(0x0, 0x0F, 0x40F000F0), + /* Internal Speakers Fixed,Int; Speaker,Other Analog; Unknown,nJD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x0d, 0x90170110), -/* NID 0x11 - Internal Microphone - * Config=0xD5A30140 (Fixed internal,Top; Mic In,ATIPI; Unknown,nJD; DA,Seq) - */ - AZALIA_PIN_CFG(0x0, 0x11, 0xD5A30140), - AZALIA_PIN_CFG(0x0, 0x12, 0x90A60140), + /* Not connected */ + AZALIA_PIN_CFG(0x0, 0x0f, 0x40f000f0), + + /* Internal Microphone: Fixed,Int,Top; Mic In,ATIPI; Unknown,nJD; DA,Seq */ + AZALIA_PIN_CFG(0x0, 0x11, 0xd5a30140), + AZALIA_PIN_CFG(0x0, 0x12, 0x90a60140), AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), AZALIA_PIN_CFG(0x0, 0x15, 0x03211020), - AZALIA_PIN_CFG(0x0, 0x18, 0x03A11830), - AZALIA_PIN_CFG(0x0, 0x19, 0x411111F0), - - AZALIA_PIN_CFG(0x0, 0x1A, 0x411111F0), - AZALIA_PIN_CFG(0x0, 0x1D, 0x40138205), - AZALIA_PIN_CFG(0x0, 0x1E, 0x411111F0), + AZALIA_PIN_CFG(0x0, 0x18, 0x03a11830), + AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), + AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), + AZALIA_PIN_CFG(0x0, 0x1d, 0x40138205), + AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), /* Misc entries */ 0x01970804, @@ -84,11 +62,10 @@ const u32 cim_verb_data[] = { 0x00370680, 0x00270680, - 0x01470C02, - 0x01570C02, - - /* ALC coefficients. */ + 0x01470c02, + 0x01570c02, + /* ALC coefficients. */ /* 08 */ 0x02050008, 0x02040700, @@ -102,29 +79,14 @@ const u32 cim_verb_data[] = { 0x01870724, /* Enable Vrefout for mic */ 0x00170500, /* Set power state to D0 */ - /* --- Next Codec --- */ - -/* Vendor Name : Intel - * Vendor ID : 0x80862806 - * Subsystem ID : 0x80860101 - * Revision ID : 0x100000 - */ - /* coreboot specific header */ - 0x80862806, // Codec Vendor / Device ID: Intel PantherPoint HDMI - 0x80860101, // Subsystem ID - 4, // Number of IDs - - /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x80860101 */ + /* --- Codec #3 --- */ + 0x80862806, /* Codec Vendor / Device ID: Intel PantherPoint HDMI */ + 0x80860101, /* Subsystem ID */ + 4, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x3, 0x80860101), - - /* Pin Complex (NID 0x05) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), - - /* Pin Complex (NID 0x06) Digital Out at Int HDMI */ AZALIA_PIN_CFG(0x3, 0x06, 0x18560020), - - /* Pin Complex (NID 0x07) Digital Out at Int HDMI */ - AZALIA_PIN_CFG(0x3, 0x07, 0x18560030) + AZALIA_PIN_CFG(0x3, 0x07, 0x18560030), }; const u32 pc_beep_verbs[] = { diff --git a/src/mainboard/lenovo/x60/hda_verb.c b/src/mainboard/lenovo/x60/hda_verb.c index 216696b22b..071249897c 100644 --- a/src/mainboard/lenovo/x60/hda_verb.c +++ b/src/mainboard/lenovo/x60/hda_verb.c @@ -14,9 +14,9 @@ #include const u32 cim_verb_data[] = { - 0x11d41981, /* Codec Vendor / Device ID: Analog Devices AD1981 */ - 0x17aa2025, /* Subsystem ID */ - 11, /* Number of 4 dword sets */ + 0x11d41981, /* Codec Vendor / Device ID: Analog Devices AD1981 */ + 0x17aa2025, /* Subsystem ID */ + 11, /* Number of 4 dword sets */ AZALIA_SUBVENDOR(0x0, 0x17aa2025), -- cgit v1.2.3