Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 1 | /* |
| 2 | * This file is part of the coreboot project. |
| 3 | * |
| 4 | * Copyright (C) 2011 The ChromiumOS Authors. All rights reserved. |
| 5 | * |
| 6 | * This program is free software; you can redistribute it and/or |
| 7 | * modify it under the terms of the GNU General Public License as |
| 8 | * published by the Free Software Foundation; version 2 of the License. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 14 | */ |
| 15 | |
Vladimir Serbinenko | 75c8387 | 2014-09-05 01:01:31 +0200 | [diff] [blame] | 16 | #include <device/azalia_device.h> |
| 17 | |
| 18 | const u32 cim_verb_data[] = { |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 19 | /* coreboot specific header */ |
| 20 | 0x10ec0269, // Codec Vendor / Device ID: Realtek |
| 21 | 0x17aa21fe, // Subsystem ID |
| 22 | 0x0000000c, // Number of jacks |
| 23 | |
| 24 | /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x17aa21fe */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 25 | AZALIA_SUBVENDOR(0x0, 0x17aa21fe), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 26 | |
| 27 | /* Pin Widget Verb Table */ |
| 28 | |
| 29 | /* Pin Complex (NID 0x12): 0x90a60930 DMIC */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 30 | AZALIA_PIN_CFG(0x0, 0x12, 0x90a60930), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 31 | |
| 32 | /* Pin Complex (NID 0x14): 0x90170110 SPEAKER-OUT (Port-D) */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 33 | AZALIA_PIN_CFG(0x0, 0x14, 0x90170110), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 34 | |
| 35 | /* Pin Complex (NID 0x15): 0x0321101f HP-OUT (Port-A) */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 36 | AZALIA_PIN_CFG(0x0, 0x15, 0x0321101f), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 37 | |
| 38 | /* Pin Complex (NID 0x17): 0x411111f0 MONO-OUT (Port-H) */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 39 | AZALIA_PIN_CFG(0x0, 0x17, 0x411111f0), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 40 | |
| 41 | /* Pin Complex (NID 0x18): 0x03a11820 MIC1 (Port-B) */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 42 | AZALIA_PIN_CFG(0x0, 0x18, 0x03a11820), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 43 | |
| 44 | /* Pin Complex (NID 0x19): 0x411111f0 MIC2 (Port-F) */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 45 | AZALIA_PIN_CFG(0x0, 0x19, 0x411111f0), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 46 | |
| 47 | /* Pin Complex (NID 0x1a): 0x411111f0 LINE1 (Port-C) */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 48 | AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 49 | |
| 50 | /* Pin Complex (NID 0x1b): 0x411111f0 LINE2 (Port-E) */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 51 | AZALIA_PIN_CFG(0x0, 0x1b, 0x411111f0), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 52 | |
| 53 | /* Pin Complex (NID 0x1d): 0x4016862d PC-BEEP */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 54 | AZALIA_PIN_CFG(0x0, 0x1d, 0x4016862d), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 55 | |
| 56 | /* Pin Complex (NID 0x1e): 0x411111f0 S/PDIF-OUT */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 57 | AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 58 | |
| 59 | /* Stout MIC detect setup */ |
| 60 | 0x02050018, |
| 61 | 0x02045184, |
| 62 | 0x02050008, |
| 63 | 0x02040300, |
| 64 | |
| 65 | /* coreboot specific header */ |
| 66 | 0x80862806, // Codec Vendor / Device ID: Intel PantherPoint HDMI |
| 67 | 0x80860101, // Subsystem ID |
| 68 | 0x00000004, // Number of jacks |
| 69 | |
| 70 | /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x80860101 */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 71 | AZALIA_SUBVENDOR(0x3, 0x80860101), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 72 | |
| 73 | /* Pin Complex (NID 0x05) Digital Out at Int HDMI */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 74 | AZALIA_PIN_CFG(0x3, 0x05, 0x18560010), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 75 | |
| 76 | /* Pin Complex (NID 0x06) Not Connected */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 77 | AZALIA_PIN_CFG(0x3, 0x06, 0x58560020), |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 78 | |
| 79 | /* Pin Complex (NID 0x07) Not Connected */ |
Vladimir Serbinenko | 02d674a | 2014-09-04 22:04:11 +0200 | [diff] [blame] | 80 | AZALIA_PIN_CFG(0x3, 0x07, 0x58560030) |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 81 | }; |
| 82 | |
Vladimir Serbinenko | 75c8387 | 2014-09-05 01:01:31 +0200 | [diff] [blame] | 83 | const u32 pc_beep_verbs[] = { |
Stefan Reinauer | b7ecf6d | 2013-03-13 17:13:32 -0700 | [diff] [blame] | 84 | 0x00170500, /* power up everything (codec, dac, adc, mixers) */ |
| 85 | 0x01470740, /* enable speaker out */ |
| 86 | 0x01470c02, /* set speaker EAPD pin */ |
| 87 | 0x0143b01f, /* unmute speaker */ |
| 88 | 0x00c37100, /* unmute mixer nid 0xc input 1 */ |
| 89 | 0x00b37410, /* unmute mixer nid 0xb beep input and set volume */ |
| 90 | }; |
Vladimir Serbinenko | 75c8387 | 2014-09-05 01:01:31 +0200 | [diff] [blame] | 91 | AZALIA_ARRAY_SIZES; |