Angel Pons | 89ab250 | 2020-04-03 01:22:28 +0200 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 2 | |
| 3 | #include <device/azalia_device.h> |
| 4 | |
| 5 | const u32 cim_verb_data[] = { |
| 6 | /* coreboot specific header */ |
| 7 | 0x10ec0269, // Codec Vendor / Device ID: Realtek |
| 8 | 0x17aa21fe, // Subsystem ID |
| 9 | 0x0000000b, // Number of jacks |
| 10 | |
| 11 | /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x17aa21fe */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 12 | AZALIA_SUBVENDOR(0, 0x17aa21fe), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 13 | |
| 14 | /* Pin Widget Verb Table */ |
| 15 | |
| 16 | /* Pin Complex (NID 0x12): 0x90a60930 DMIC */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 17 | AZALIA_PIN_CFG(0, 0x12, 0x90a60930), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 18 | |
| 19 | /* Pin Complex (NID 0x14): 0x90170110 SPEAKER-OUT (Port-D) */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 20 | AZALIA_PIN_CFG(0, 0x14, 0x90170110), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 21 | |
| 22 | /* Pin Complex (NID 0x15): 0x0321101f HP-OUT (Port-A) */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 23 | AZALIA_PIN_CFG(0, 0x15, 0x0321101f), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 24 | |
| 25 | /* Pin Complex (NID 0x17): 0x411111f0 MONO-OUT (Port-H) */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 26 | AZALIA_PIN_CFG(0, 0x17, 0x411111f0), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 27 | |
| 28 | /* Pin Complex (NID 0x18): 0x03a11820 MIC1 (Port-B) */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 29 | AZALIA_PIN_CFG(0, 0x18, 0x03a11820), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 30 | |
| 31 | /* Pin Complex (NID 0x19): 0x411111f0 MIC2 (Port-F) */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 32 | AZALIA_PIN_CFG(0, 0x19, 0x411111f0), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 33 | |
| 34 | /* Pin Complex (NID 0x1a): 0x411111f0 LINE1 (Port-C) */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 35 | AZALIA_PIN_CFG(0, 0x1a, 0x411111f0), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 36 | |
| 37 | /* Pin Complex (NID 0x1b): 0x411111f0 LINE2 (Port-E) */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 38 | AZALIA_PIN_CFG(0, 0x1b, 0x411111f0), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 39 | |
| 40 | /* Pin Complex (NID 0x1d): 0x4016862d PC-BEEP */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 41 | AZALIA_PIN_CFG(0, 0x1d, 0x4016862d), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 42 | |
| 43 | /* Pin Complex (NID 0x1e): 0x411111f0 S/PDIF-OUT */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 44 | AZALIA_PIN_CFG(0, 0x1e, 0x411111f0), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 45 | |
| 46 | /* coreboot specific header */ |
| 47 | 0x80862806, // Codec Vendor / Device ID: Intel PantherPoint HDMI |
| 48 | 0x80860101, // Subsystem ID |
| 49 | 0x00000004, // Number of jacks |
| 50 | |
| 51 | /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x80860101 */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 52 | AZALIA_SUBVENDOR(3, 0x80860101), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 53 | |
| 54 | /* Pin Complex (NID 0x05) Digital Out at Int HDMI */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 55 | AZALIA_PIN_CFG(3, 0x05, 0x18560010), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 56 | |
| 57 | /* Pin Complex (NID 0x06) Not Connected */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 58 | AZALIA_PIN_CFG(3, 0x06, 0x58560020), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 59 | |
| 60 | /* Pin Complex (NID 0x07) Not Connected */ |
Angel Pons | ec21170 | 2019-12-19 19:37:21 +0100 | [diff] [blame] | 61 | AZALIA_PIN_CFG(3, 0x07, 0x58560030), |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 62 | }; |
| 63 | |
| 64 | const u32 pc_beep_verbs[] = { |
Peter Lemenkov | 6b7d40a | 2020-01-22 11:40:16 +0100 | [diff] [blame] | 65 | 0x00170500, /* power up everything (codec, dac, adc, mixers) */ |
James Ye | be6fd4c | 2017-07-22 19:19:42 +1000 | [diff] [blame] | 66 | 0x01470740, /* enable speaker out */ |
| 67 | 0x01470c02, /* set speaker EAPD pin */ |
| 68 | 0x0143b01f, /* unmute speaker */ |
| 69 | 0x00c37100, /* unmute mixer nid 0xc input 1 */ |
| 70 | 0x00b37410, /* unmute mixer nid 0xb beep input and set volume */ |
| 71 | }; |
| 72 | AZALIA_ARRAY_SIZES; |