diff options
author | Nicholas Sudsgaard <devel+coreboot@nsudsgaard.com> | 2024-02-22 13:33:15 +0900 |
---|---|---|
committer | Felix Singer <service+coreboot-gerrit@felixsinger.de> | 2024-02-29 03:12:43 +0000 |
commit | 4a62b8a5997873229f5342bffdee3e6b21772b06 (patch) | |
tree | ec21dd1c20bf0a935b8fd82352cb4fc84c6f9b99 /src/mainboard | |
parent | 9620b3d152e0c939d06b900aa65dba3f26ebe2e2 (diff) |
include/device: Merge enums from azalia_device.h and azalia.h
We were keeping 2 copies of the same thing (albeit there were some
slight differences). As azalia_device.h is used much more in the
codebase this was kept as the base and then some of the nice features
of azalia.h were incorporated.
The significant changes are:
- All enum names now use the `AZALIA_` prefix.
This also drops the AzaliaPinConfiguration enum as it was never used
since added in 2013.
Change-Id: Ie874b083a18963679981a9cd2b25d123890d628e
Signed-off-by: Nicholas Sudsgaard <devel+coreboot@nsudsgaard.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/80695
Reviewed-by: Nico Huber <nico.h@gmx.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Reviewed-by: Michael Niewöhner <foss@mniewoehner.de>
Diffstat (limited to 'src/mainboard')
-rw-r--r-- | src/mainboard/clevo/tgl-u/variants/l140mu/hda_verb.c | 70 | ||||
-rw-r--r-- | src/mainboard/siemens/chili/variants/chili/hda_verb.c | 73 |
2 files changed, 75 insertions, 68 deletions
diff --git a/src/mainboard/clevo/tgl-u/variants/l140mu/hda_verb.c b/src/mainboard/clevo/tgl-u/variants/l140mu/hda_verb.c index 0ff24a2c79..2e1a5799d7 100644 --- a/src/mainboard/clevo/tgl-u/variants/l140mu/hda_verb.c +++ b/src/mainboard/clevo/tgl-u/variants/l140mu/hda_verb.c @@ -12,61 +12,61 @@ const u32 cim_verb_data[] = { /* Microphone (display lid), vendor value: 0x90a60130 */ AZALIA_PIN_CFG(0, 0x12, AZALIA_PIN_DESC( - INTEGRATED, - LOCATION_OTHER, /* vendor: SEPARATE_CHASSIS */ - SPECIAL7, /* lid, vendor: NA */ - MIC_IN, - OTHER_DIGITAL, - COLOR_UNKNOWN, - NO_JACK_PRESENCE_DETECT, + AZALIA_INTEGRATED, + AZALIA_LOCATION_OTHER, /* vendor: AZALIA_SEPARATE_CHASSIS */ + AZALIA_SPECIAL7, /* lid, vendor: AZALIA_GEOLOCATION_NA*/ + AZALIA_MIC_IN, + AZALIA_OTHER_DIGITAL, + AZALIA_COLOR_UNKNOWN, + AZALIA_NO_JACK_PRESENCE_DETECT, 3, 0) ), /* Integrated speakers, vendor value: 0x90170110 */ AZALIA_PIN_CFG(0, 0x14, AZALIA_PIN_DESC( - INTEGRATED, - LOCATION_OTHER, /* vendor: SEPARATE_CHASSIS */ - BOTTOM, /* vendor: NA */ - SPEAKER, - OTHER_ANALOG, - COLOR_UNKNOWN, - NO_JACK_PRESENCE_DETECT, + AZALIA_INTEGRATED, + AZALIA_LOCATION_OTHER, /* vendor: AZALIA_SEPARATE_CHASSIS */ + AZALIA_BOTTOM, /* vendor: AZALIA_GEOLOCATION_NA*/ + AZALIA_SPEAKER, + AZALIA_OTHER_ANALOG, + AZALIA_COLOR_UNKNOWN, + AZALIA_NO_JACK_PRESENCE_DETECT, 1, 0) ), /* Headphones, vendor value: 0x02211020 */ AZALIA_PIN_CFG(0, 0x15, AZALIA_PIN_DESC( - JACK, - EXTERNAL_PRIMARY_CHASSIS, - RIGHT, /* vendor: FRONT */ - HP_OUT, - STEREO_MONO_1_8, - BLACK, - JACK_PRESENCE_DETECT, + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS, + AZALIA_RIGHT, /* vendor: AZALIA_FRONT */ + AZALIA_HP_OUT, + AZALIA_STEREO_MONO_1_8, + AZALIA_BLACK, + AZALIA_JACK_PRESENCE_DETECT, 2, 0) ), /* ext. Microphone, vendor value: 0x411111f0, linux override: 0x01a1913c */ AZALIA_PIN_CFG(0, 0x1a, AZALIA_PIN_DESC( - JACK, - EXTERNAL_PRIMARY_CHASSIS, - RIGHT, /* vendor: REAR */ - MIC_IN, - STEREO_MONO_1_8, - BLACK, /* vendor: PINK */ - NO_JACK_PRESENCE_DETECT, + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS, + AZALIA_RIGHT, /* vendor: AZALIA_REAR */ + AZALIA_MIC_IN, + AZALIA_STEREO_MONO_1_8, + AZALIA_BLACK, /* vendor: AZALIA_PINK */ + AZALIA_NO_JACK_PRESENCE_DETECT, 3, 12) ), /* PCBEEP, vendor value: 0x41748245 */ AZALIA_PIN_CFG(0, 0x1d, AZALIA_PIN_DESC( - INTEGRATED, /* vendor: NC */ - INTERNAL, /* vendor: EXTERNAL_PRIMARY_CHASSIS */ - NA, /* vendor: REAR */ - DEVICE_OTHER, /* vendor: MODEM_HANDSET_SIDE */ - OTHER_ANALOG, /* vendor: RCA */ - COLOR_UNKNOWN, /* vendor: PURPLE */ - NO_JACK_PRESENCE_DETECT, /* vendor: 2 */ + AZALIA_INTEGRATED, /* vendor: AZALIA_NC */ + AZALIA_INTERNAL, /* vendor: AZALIA_EXTERNAL_PRIMARY_CHASSIS */ + AZALIA_GEOLOCATION_NA, /* vendor: AZALIA_REAR */ + AZALIA_DEVICE_OTHER, /* vendor: AZALIA_MODEM_HANDSET_SIDE */ + AZALIA_OTHER_ANALOG, /* vendor: AZALIA_RCA */ + AZALIA_COLOR_UNKNOWN, /* vendor: AZALIA_PURPLE */ + AZALIA_NO_JACK_PRESENCE_DETECT, /* vendor: 2 */ 4, 5) ), diff --git a/src/mainboard/siemens/chili/variants/chili/hda_verb.c b/src/mainboard/siemens/chili/variants/chili/hda_verb.c index f0e403acd0..7fdb884465 100644 --- a/src/mainboard/siemens/chili/variants/chili/hda_verb.c +++ b/src/mainboard/siemens/chili/variants/chili/hda_verb.c @@ -1,7 +1,6 @@ /* SPDX-License-Identifier: GPL-2.0-only */ #include <device/azalia_device.h> -#include <device/azalia.h> const u32 cim_verb_data[] = { /* coreboot specific header */ @@ -15,31 +14,36 @@ const u32 cim_verb_data[] = { AZALIA_SUBVENDOR(0, 0x110a4097), /* Pin Widget Verb Table */ - AZALIA_PIN_CFG(0, 0x14, /* 0x14 Speaker OUT */ - (AZALIA_PINCFG_PORT_FIXED << 30) | - (AZALIA_PINCFG_LOCATION_INTERNAL << 24) | - (AZALIA_PINCFG_DEVICE_SPEAKER << 20) | - (AZALIA_PINCFG_CONN_OTHER_ANALOG << 16) | - (AZALIA_PINCFG_MISC_IGNORE_PRESENCE << 8) | - (1 << 4) | 0 - ), - AZALIA_PIN_CFG(0, 0x21, /* 0x21 Headphone OUT */ - (AZALIA_PINCFG_PORT_JACK << 30) | - (AZALIA_PINCFG_LOCATION_FRONT << 24) | - (AZALIA_PINCFG_DEVICE_HP_OUT << 20) | - (AZALIA_PINCFG_CONN_COMBINATION << 16) | - (AZALIA_PINCFG_COLOR_BLACK << 12) | - (2 << 4) | 0 - ), - AZALIA_PIN_CFG(0, 0x19, /* 0x19 MIC2 */ - (AZALIA_PINCFG_PORT_JACK << 30) | - (AZALIA_PINCFG_LOCATION_FRONT << 24) | - (AZALIA_PINCFG_DEVICE_MICROPHONE << 20) | - (AZALIA_PINCFG_CONN_COMBINATION << 16) | - (AZALIA_PINCFG_COLOR_BLACK << 12) | - (AZALIA_PINCFG_MISC_IGNORE_PRESENCE << 8) | - (3 << 4) | 0 - ), + AZALIA_PIN_CFG(0, 0x14, AZALIA_PIN_DESC( /* 0x14 Speaker OUT */ + AZALIA_INTEGRATED, + AZALIA_INTERNAL, + AZALIA_GEOLOCATION_NA, + AZALIA_SPEAKER, + AZALIA_OTHER_ANALOG, + AZALIA_COLOR_UNKNOWN, + AZALIA_NO_JACK_PRESENCE_DETECT, + 1, 0 + )), + AZALIA_PIN_CFG(0, 0x21, AZALIA_PIN_DESC( /* 0x21 Headphone OUT */ + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS, + AZALIA_FRONT, + AZALIA_HP_OUT, + AZALIA_COMBINATION, + AZALIA_BLACK, + AZALIA_JACK_PRESENCE_DETECT, + 2, 0 + )), + AZALIA_PIN_CFG(0, 0x19, AZALIA_PIN_DESC( /* 0x19 MIC2 */ + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS, + AZALIA_FRONT, + AZALIA_MIC_IN, + AZALIA_COMBINATION, + AZALIA_BLACK, + AZALIA_NO_JACK_PRESENCE_DETECT, + 3, 0 + )), AZALIA_PIN_CFG(0, 0x12, AZALIA_PIN_CFG_NC(0)), /* 0x12 Digital MIC */ AZALIA_PIN_CFG(0, 0x17, AZALIA_PIN_CFG_NC(1)), /* 0x17 Mono OUT */ @@ -61,13 +65,16 @@ const u32 cim_verb_data[] = { 0x20878101, AZALIA_PIN_CFG(2, 0x05, AZALIA_PIN_CFG_NC(0)), AZALIA_PIN_CFG(2, 0x06, AZALIA_PIN_CFG_NC(1)), - AZALIA_PIN_CFG(2, 0x07, - (AZALIA_PINCFG_PORT_JACK << 30) | - (AZALIA_PINCFG_LOCATION_REAR_PANEL << 24) | - (AZALIA_PINCFG_DEVICE_DIGITAL_OUT << 20) | - (AZALIA_PINCFG_CONN_OTHER_DIGITAL << 16) | - (1 << 4) | 0 - ), + AZALIA_PIN_CFG(2, 0x07, AZALIA_PIN_DESC( + AZALIA_JACK, + AZALIA_EXTERNAL_PRIMARY_CHASSIS, + AZALIA_SPECIAL7, + AZALIA_DIGITAL_OTHER_OUT, + AZALIA_OTHER_DIGITAL, + AZALIA_COLOR_UNKNOWN, + AZALIA_JACK_PRESENCE_DETECT, + 1, 0 + )), /* Disable 2nd & 3rd pin widgets again */ 0x20878100, 0x20878100, |