blob: e0454c7824c0ec6e0b04b9fc07e40e1002ee9f52 [file] [log] [blame]
Stefan Reinauera7198b32012-12-11 16:00:47 -08001/*
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 Reinauera7198b32012-12-11 16:00:47 -080014 */
15
16/*
17 * Parrot audio ports:
18 * ALC269:
19 * out:
20 * Internal Speaker: PORT D (0x14)
21 * Headphone: PORT A - (0x21) (SenseA)
22 *
23 * in:
24 * Mic2: PORT F (0x19) (SenseB)
25 * Line2 (internal Mic): PORT E (0x1B)
26 * PCBeep
27 *
28 * HDMI PatherPoint
29 */
30
Vladimir Serbinenko75c83872014-09-05 01:01:31 +020031#include <device/azalia_device.h>
32
33const u32 cim_verb_data[] = {
Stefan Reinauera7198b32012-12-11 16:00:47 -080034 /* coreboot specific header */
35 0x10ec0269, // Codec Vendor / Device ID: Realtek ALC269
36 0x10250742, // Subsystem ID
37 0x0000000E, // Number of jacks (NID entries)
38
39
40 /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x10250742 */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020041 AZALIA_SUBVENDOR(0x0, 0x10250742),
Stefan Reinauera7198b32012-12-11 16:00:47 -080042
43 /* Pin Widget Verb Table */
44
45 /* Pin Complex (NID 0x12) DMIC */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020046 AZALIA_PIN_CFG(0x0, 0x12, 0x411111f0),
Stefan Reinauera7198b32012-12-11 16:00:47 -080047
48 /* Pin Complex (NID 0x14) SPKR-OUT PORTD */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020049 // group 1, front left/right
50 // no connector, no jack detect
51 // speaker out, analog
52 // fixed function, internal
53 AZALIA_PIN_CFG(0x0, 0x14, 0x90170110),
Stefan Reinauera7198b32012-12-11 16:00:47 -080054
55 /* Pin Complex (NID 0x17) */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020056 AZALIA_PIN_CFG(0x0, 0x17, 0x411111f0),
Stefan Reinauera7198b32012-12-11 16:00:47 -080057
58 /* Pin Complex (NID 0x18) MIC1 PORTB */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020059 AZALIA_PIN_CFG(0x0, 0x18, 0x411111f0),
Stefan Reinauera7198b32012-12-11 16:00:47 -080060
61 /* Pin Complex (NID 0x19) MIC2 PORTF */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020062 // group 2, cap 1
63 // black, jack detect
64 // mic in, analog
65 // connector, right panel
66 AZALIA_PIN_CFG(0x0, 0x19, 0x04a71021),
Stefan Reinauera7198b32012-12-11 16:00:47 -080067
68 /* Pin Complex (NID 0x1A) LINE1 PORTC */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020069 AZALIA_PIN_CFG(0x0, 0x1a, 0x411111f0),
Stefan Reinauera7198b32012-12-11 16:00:47 -080070
71 /* Pin Complex (NID 0x1B) LINE2 PORTE */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020072 // group 2, cap 0
73 // no connector, no jack detect
74 // mic in, analog
75 // fixed function, internal
76 AZALIA_PIN_CFG(0x0, 0x1b, 0x90a70120),
Stefan Reinauera7198b32012-12-11 16:00:47 -080077
78 /* Pin Complex (NID 0x1d) PCBeep */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020079 // eapd low on ex-amp, laptop, custom enable
80 // mute spkr on hpout
81 // pcbeep en able, checksum
82 // no physical, internal
83 AZALIA_PIN_CFG(0x0, 0x1d, 0x4015812d),
Stefan Reinauera7198b32012-12-11 16:00:47 -080084
85 /* Pin Complex (NID 0x1E) SPDIF-OUT */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020086 AZALIA_PIN_CFG(0x0, 0x1e, 0x411111f0),
Stefan Reinauera7198b32012-12-11 16:00:47 -080087
88 /* Pin Complex (NID 0x21) HPOUT PORTA? */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +020089 // group1,
90 // black, jack detect
91 // HPOut, 1/8 stereo
92 // connector, right panel
93 AZALIA_PIN_CFG(0x0, 0x21, 0x0421101f),
Stefan Reinauera7198b32012-12-11 16:00:47 -080094
95 /* Undocumented speaker output volume settings from Compal and Realtek */
96 /* Widget node 0x20 */
97 0x02050011,
98 0x02040710,
99 0x02050012,
100 0x02041901,
101
102 0x02050002,
103 0x0204AAB8,
104 0x0205000D,
105 0x02044440,
106
107 0x02050008,
108 0x02040300,
109 0x02050017,
110 0x020400AF,
111
112 /* --- Next Codec --- */
113
114 /* coreboot specific header */
115 0x80862806, // Codec Vendor / Device ID: Intel PantherPoint HDMI
116 0x80860101, // Subsystem ID
117 0x00000004, // Number of jacks
118
119 /* NID 0x01, HDA Codec Subsystem ID Verb Table: 0x80860101 */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +0200120 AZALIA_SUBVENDOR(0x0, 0x80860101),
Stefan Reinauera7198b32012-12-11 16:00:47 -0800121
122 /* Pin Complex (NID 0x05) Digital Out at Int HDMI */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +0200123 AZALIA_PIN_CFG(0x3, 0x05, 0x18560010),
Stefan Reinauera7198b32012-12-11 16:00:47 -0800124
125 /* Pin Complex (NID 0x06) Digital Out at Int HDMI */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +0200126 AZALIA_PIN_CFG(0x3, 0x06, 0x18560020),
Stefan Reinauera7198b32012-12-11 16:00:47 -0800127
128 /* Pin Complex (NID 0x07) Digital Out at Int HDMI */
Vladimir Serbinenko02d674a2014-09-04 22:04:11 +0200129 AZALIA_PIN_CFG(0x3, 0x07, 0x18560030)
Stefan Reinauera7198b32012-12-11 16:00:47 -0800130};
131
Vladimir Serbinenko75c83872014-09-05 01:01:31 +0200132const u32 pc_beep_verbs[] = {
Stefan Reinauera7198b32012-12-11 16:00:47 -0800133 0x00170500, /* power up everything (codec, dac, adc, mixers) */
134 0x01470740, /* enable speaker out */
135 0x01470c02, /* set speaker EAPD pin */
136 0x0143b01f, /* unmute speaker */
137 0x00c37100, /* unmute mixer nid 0xc input 1 */
138 0x00b37410, /* unmute mixer nid 0xb beep input and set volume */
139};
140
Vladimir Serbinenko75c83872014-09-05 01:01:31 +0200141AZALIA_ARRAY_SIZES;