Elyes Haouas has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/84246?usp=email )
Change subject: mb/getac/p470/hda_verb: Use macros instead of magic numbers ......................................................................
mb/getac/p470/hda_verb: Use macros instead of magic numbers
Change-Id: I247ac1ae88a623489a98e876ea10d8515b6f3e9d Signed-off-by: Elyes Haouas ehaouas@noos.fr --- M src/mainboard/getac/p470/hda_verb.c 1 file changed, 108 insertions(+), 12 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/46/84246/1
diff --git a/src/mainboard/getac/p470/hda_verb.c b/src/mainboard/getac/p470/hda_verb.c index e7e5828..77db6a1 100644 --- a/src/mainboard/getac/p470/hda_verb.c +++ b/src/mainboard/getac/p470/hda_verb.c @@ -14,40 +14,136 @@ /* Pin Widget Verb Table */
/* Pin Complex (NID 0x12), DMIC */ - AZALIA_PIN_CFG(0, 0x12, 0x411111F0), + AZALIA_PIN_CFG(0, 0x12, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_FRONT, + AZALIA_MIC_IN, + AZALIA_STEREO_MONO_1_8, + AZALIA_COLOR_UNKNOWN, + AZALIA_NO_JACK_PRESENCE_DETECT, + 1, 0 + )),
/* Pin Complex (NID 0x14), LINE_OUT (port D) */ - AZALIA_PIN_CFG(0, 0x14, 0x99130110), + AZALIA_PIN_CFG(0, 0x14, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR, + AZALIA_LINE_OUT, + AZALIA_STEREO_MONO_1_8, + AZALIA_BLACK, + AZALIA_JACK_PRESENCE_DETECT, + 1, 16 + )),
/* Pin Complex (NID 0x15), HP_OUT (port A) */ - AZALIA_PIN_CFG(0, 0x15, 0x01214020), + AZALIA_PIN_CFG(0, 0x15, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_FRONT, + AZALIA_HP_OUT, + AZALIA_STEREO_MONO_1_8, + AZALIA_GREEN, + AZALIA_JACK_PRESENCE_DETECT, + 1, 32 + )),
/* Pin Complex (NID 0x16), MONO-OUT */ - AZALIA_PIN_CFG(0, 0x16, 0x411111F0), + AZALIA_PIN_CFG(0, 0x16, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_INTERNAL, + AZALIA_SPEAKER, + AZALIA_OTHER_ANALOG, + AZALIA_COLOR_UNKNOWN, + AZALIA_NO_JACK_PRESENCE_DETECT, + 1, 0 + )),
/* Pin Complex (NID 0x18), MIC1 (port B) */ - AZALIA_PIN_CFG(0, 0x18, 0x01A19830), + AZALIA_PIN_CFG(0, 0x18, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_LEFT, + AZALIA_MIC_IN, + AZALIA_STEREO_MONO_1_8, + AZALIA_PINK, + AZALIA_JACK_PRESENCE_DETECT, + 1, 48 + )),
/* Pin Complex (NID 0x19), MIC2 (port F) */ - AZALIA_PIN_CFG(0, 0x19, 0x99A30931), + AZALIA_PIN_CFG(0, 0x19, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_FRONT, + AZALIA_MIC_IN, + AZALIA_STEREO_MONO_1_8, + AZALIA_BLACK, + AZALIA_JACK_PRESENCE_DETECT, + 2, 0 + )),
/* Pin Complex (NID 0x1A), LINE1 (port C) */ - AZALIA_PIN_CFG(0, 0x1A, 0x02A1983F), + AZALIA_PIN_CFG(0, 0x1A, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR, + AZALIA_LINE_IN, + AZALIA_STEREO_MONO_1_8, + AZALIA_BLUE, + AZALIA_JACK_PRESENCE_DETECT, + 1, 63 + )),
/* Pin Complex (NID 0x1B), LINE2 (port E) */ - AZALIA_PIN_CFG(0, 0x1B, 0x0221401F), + AZALIA_PIN_CFG(0, 0x1B, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_FRONT, + AZALIA_LINE_IN, + AZALIA_STEREO_MONO_1_8, + AZALIA_GREEN, + AZALIA_JACK_PRESENCE_DETECT, + 1, 31 + )),
/* Pin Complex (NID 0x1C), CD_IN */ - AZALIA_PIN_CFG(0, 0x1C, 0x411111F0), + AZALIA_PIN_CFG(0, 0x1C, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_INTERNAL, + AZALIA_CD_IN, + AZALIA_OTHER_ANALOG, + AZALIA_COLOR_UNKNOWN, + AZALIA_NO_JACK_PRESENCE_DETECT, + 1, 0 + )),
/* Pin Complex (NID 0x1D), PCBEEP */ - AZALIA_PIN_CFG(0, 0x1D, 0x411111F0), + AZALIA_PIN_CFG(0, 0x1D, AZALIA_PIN_DESC( + AZALIA_INTEGRATED, + AZALIA_INTERNAL, + AZALIA_BEEP, + AZALIA_OTHER_ANALOG, + AZALIA_COLOR_UNKNOWN, + AZALIA_NO_JACK_PRESENCE_DETECT, + 1, 0 + )),
/* Pin Complex (NID 0x1E), S/PDIF-OUT */ - AZALIA_PIN_CFG(0, 0x1E, 0x411111F0), + AZALIA_PIN_CFG(0, 0x1E, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR, + AZALIA_DIGITAL_OUT, + AZALIA_OTHER_DIGITAL, + AZALIA_BLACK, + AZALIA_JACK_PRESENCE_DETECT, + 1, 0 + )),
/* Pin Complex (NID 0x1F), S/PDIF-IN */ - AZALIA_PIN_CFG(0, 0x1F, 0x411111F0), + AZALIA_PIN_CFG(0, 0x1F, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_FRONT, + AZALIA_DIGITAL_IN, + AZALIA_OTHER_DIGITAL, + AZALIA_BLACK, + AZALIA_JACK_PRESENCE_DETECT, + 1, 0 + )), };
const u32 pc_beep_verbs[0] = {};