xref: /freebsd/sys/dev/sound/pci/hda/pin_patch_realtek.h (revision e9ac41698b2f322d55ccf9da50a3596edb2c1800)
1 /*-
2  * SPDX-License-Identifier: BSD-2-Clause
3  *
4  * Copyright (c) 2018 Khamba Staring <k.staring@quickdecay.com>
5  * All rights reserved.
6  *
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions
9  * are met:
10  * 1. Redistributions of source code must retain the above copyright
11  *    notice, this list of conditions and the following disclaimer.
12  * 2. Redistributions in binary form must reproduce the above copyright
13  *    notice, this list of conditions and the following disclaimer in the
14  *    documentation and/or other materials provided with the distribution.
15  *
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
17  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
20  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26  * SUCH DAMAGE.
27  */
28 
29 #ifndef PIN_PATCH_REALTEK_H
30 #define PIN_PATCH_REALTEK_H
31 
32 #include "hdac.h"
33 #include "pin_patch.h"
34 
35 /*
36  * Pin patches
37  */
38 static struct pin_patch_t pin_patches_lg_lw20[] = {
39 	{
40 		.nid = 26,
41 		.type = PIN_PATCH_TYPE_MASK,
42 		.patch.mask = {	HDA_CONFIG_DEFAULTCONF_DEVICE_MASK,
43 					HDA_CONFIG_DEFAULTCONF_DEVICE_LINE_IN }
44 	}, {
45 		.nid = 27,
46 		.type = PIN_PATCH_TYPE_MASK,
47 		.patch.mask = {	HDA_CONFIG_DEFAULTCONF_DEVICE_MASK,
48 					HDA_CONFIG_DEFAULTCONF_DEVICE_HP_OUT }
49 	}, { }
50 };
51 
52 static struct pin_patch_t pin_patches_clevo_d900t_asus_m5200[] = {
53 	{
54 		.nid = 24,
55 		.type = PIN_PATCH_TYPE_MASK,
56 		.patch.mask = {	HDA_CONFIG_DEFAULTCONF_DEVICE_MASK,
57 					HDA_CONFIG_DEFAULTCONF_DEVICE_LINE_IN }
58 	}, {
59 		.nid = 25,
60 		.type = PIN_PATCH_TYPE_MASK,
61 		.patch.mask = {	HDA_CONFIG_DEFAULTCONF_DEVICE_MASK,
62 					HDA_CONFIG_DEFAULTCONF_DEVICE_MIC_IN }
63 	}, {
64 		.nid = 26,
65 		.type = PIN_PATCH_TYPE_MASK,
66 		.patch.mask = {	HDA_CONFIG_DEFAULTCONF_DEVICE_MASK,
67 					HDA_CONFIG_DEFAULTCONF_DEVICE_LINE_IN }
68 	}, {
69 		.nid = 27,
70 		.type = PIN_PATCH_TYPE_MASK,
71 		.patch.mask = {	HDA_CONFIG_DEFAULTCONF_DEVICE_MASK,
72 					HDA_CONFIG_DEFAULTCONF_DEVICE_LINE_IN }
73 	}, {
74 		.nid = 28,
75 		.type = PIN_PATCH_TYPE_MASK,
76 		.patch.mask = {	HDA_CONFIG_DEFAULTCONF_DEVICE_MASK,
77 					HDA_CONFIG_DEFAULTCONF_DEVICE_CD }
78 	}, { }
79 };
80 
81 static struct pin_patch_t pin_patches_msi_ms034a[] = {
82 	{
83 		.nid = 25,
84 		.type = PIN_PATCH_TYPE_MASK,
85 		.patch.mask = {
86 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
87 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
88 			HDA_CONFIG_DEFAULTCONF_DEVICE_MIC_IN |
89 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_FIXED }
90 	}, {
91 		.nid = 28,
92 		.type = PIN_PATCH_TYPE_MASK,
93 		.patch.mask = {
94 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
95 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
96 			HDA_CONFIG_DEFAULTCONF_DEVICE_CD |
97 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_FIXED }
98 	}, { }
99 };
100 
101 static struct pin_patch_t pin_patches_asus_w6f[] = {
102 	{
103 		.nid = 11,
104 		.type = PIN_PATCH_TYPE_MASK,
105 		.patch.mask = {
106 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
107 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
108 			HDA_CONFIG_DEFAULTCONF_DEVICE_MIC_IN |
109 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_FIXED }
110 	}, {
111 		.nid = 12,
112 		.type = PIN_PATCH_TYPE_MASK,
113 		.patch.mask = {
114 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
115 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
116 			HDA_CONFIG_DEFAULTCONF_DEVICE_MIC_IN |
117 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_FIXED }
118 	}, {
119 		.nid = 14,
120 		.type = PIN_PATCH_TYPE_MASK,
121 		.patch.mask = {
122 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
123 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
124 			HDA_CONFIG_DEFAULTCONF_DEVICE_MIC_IN |
125 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_FIXED }
126 	}, {
127 		.nid = 15,
128 		.type = PIN_PATCH_TYPE_MASK,
129 		.patch.mask = {
130 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
131 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
132 			HDA_CONFIG_DEFAULTCONF_DEVICE_HP_OUT |
133 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_JACK }
134 	}, {
135 		.nid = 16,
136 		.type = PIN_PATCH_TYPE_MASK,
137 		.patch.mask = {
138 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
139 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
140 			HDA_CONFIG_DEFAULTCONF_DEVICE_MIC_IN |
141 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_FIXED }
142 	}, {
143 		.nid = 31,
144 		.type = PIN_PATCH_TYPE_MASK,
145 		.patch.mask = {
146 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
147 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
148 			HDA_CONFIG_DEFAULTCONF_DEVICE_MIC_IN |
149 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_FIXED }
150 	}, {
151 		.nid = 32,
152 		.type = PIN_PATCH_TYPE_MASK,
153 		.patch.mask = {
154 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
155 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
156 			HDA_CONFIG_DEFAULTCONF_DEVICE_MIC_IN |
157 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_FIXED }
158 	}, { }
159 };
160 
161 static struct pin_patch_t pin_patches_uniwill_9075[] = {
162 	{
163 		.nid = 15,
164 		.type = PIN_PATCH_TYPE_MASK,
165 		.patch.mask = {
166 			HDA_CONFIG_DEFAULTCONF_DEVICE_MASK |
167 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_MASK,
168 			HDA_CONFIG_DEFAULTCONF_DEVICE_HP_OUT |
169 			HDA_CONFIG_DEFAULTCONF_CONNECTIVITY_JACK }
170 	}, { }
171 };
172 
173 static struct pin_patch_t pin_patches_dell_xps_jack[] = {
174 	PIN_PATCH_JACK_WO_DETECT(24),
175 	PIN_PATCH_HPMIC_WO_DETECT(26),
176 	{ }
177 };
178 
179 /*
180  * List of models and patches
181  */
182 static struct hdaa_model_pin_patch_t realtek_model_pin_patches[] = {
183 	{ /**** CODEC: HDA_CODEC_ALC255 ****/
184 		.id = HDA_CODEC_ALC255,
185 		.patches = (struct model_pin_patch_t[]){
186 			{
187 				.models = (struct pin_machine_model_t[]){
188 					PIN_SUBVENDOR(ASUS_X556UR_SUBVENDOR),
189 					PIN_SUBVENDOR(ASUS_X540LA_SUBVENDOR),
190 					PIN_SUBVENDOR(ASUS_Z550MA_SUBVENDOR),
191 					{ }
192 				},
193 				.pin_patches = (struct pin_patch_t[]){
194 					PIN_PATCH_JACK_WO_DETECT(25),
195 					{ }
196 				}
197 			}, {
198 				.models = (struct pin_machine_model_t[]){
199 					PIN_SUBVENDOR(DELL_9020M_SUBVENDOR),
200 					{ }
201 				},
202 				.pin_patches = (struct pin_patch_t[]){
203 					PIN_PATCH_JACK_WO_DETECT(25),
204 					PIN_PATCH_HPMIC_WO_DETECT(26),
205 					{ }
206 				}
207 			}, { }
208 		}
209 	}, { /**** CODEC: HDA_CODEC_ALC256 ****/
210 		.id = HDA_CODEC_ALC256,
211 		.patches = (struct model_pin_patch_t[]){
212 			{
213 				.models = (struct pin_machine_model_t[]){
214 					PIN_SUBVENDOR(DELL_9020M_SUBVENDOR),
215 					PIN_SUBVENDOR(DELL_7000_SUBVENDOR),
216 					{ }
217 				},
218 				.pin_patches = (struct pin_patch_t[]){
219 					PIN_PATCH_STRING(27, "seq=1 as=5 misc=1 ctype=Analog device=Speaker loc=Internal conn=Fixed"),
220 					{ }
221 				}
222 			}, {
223 				.models = (struct pin_machine_model_t[]){
224 					PIN_SUBVENDOR(ASUS_X540A_SUBVENDOR),
225 					PIN_SUBVENDOR(ASUS_X540SA_SUBVENDOR),
226 					PIN_SUBVENDOR(ASUS_X541SA_SUBVENDOR),
227 					PIN_SUBVENDOR(ASUS_X541UV_SUBVENDOR),
228 					PIN_SUBVENDOR(ASUS_Z550SA_SUBVENDOR),
229 					PIN_SUBVENDOR(ASUS_X705UD_SUBVENDOR),
230 					PIN_SUBVENDOR(ASUS_X555UB_SUBVENDOR),
231 					{ }
232 				},
233 				.pin_patches = (struct pin_patch_t[]){
234 					PIN_PATCH_MIC_INTERNAL(19),
235 					PIN_PATCH_STRING(25, "as=2 misc=1 color=Black ctype=1/8 device=Mic loc=Right"),
236 					{ }
237 				}
238 			}, { }
239 		}
240 	}, { /**** CODEC: HDA_CODEC_ALC260 ****/
241 		.id = HDA_CODEC_ALC260,
242 		.patches = (struct model_pin_patch_t[]){
243 			{
244 				.models = (struct pin_machine_model_t[]){
245 					PIN_SUBVENDOR(SONY_S5_SUBVENDOR),
246 					{ }
247 				},
248 				.pin_patches = (struct pin_patch_t[]){
249 					PIN_PATCH_STRING(16, "seq=15 device=Headphones"),
250 					{ }
251 				}
252 			}, {
253 				.models = (struct pin_machine_model_t[]){
254 					PIN_SUBVENDOR(HP_DC5750_SUBVENDOR),
255 					{ }
256 				},
257 				.pin_patches = (struct pin_patch_t[]){
258 					PIN_PATCH_STRING(17, "as=1 misc=1 ctype=ATAPI device=Speaker loc=Internal conn=Fixed"),
259 					{ }
260 				}
261 			}, {
262 				.models = (struct pin_machine_model_t[]){
263 					PIN_SUBVENDOR(SONY_VAIO_TX_SUBVENDOR),
264 					{ }
265 				},
266 				.pin_patches = (struct pin_patch_t[]){
267 					PIN_PATCH_STRING(15, "color=Green ctype=1/8 device=Headphones loc=Rear"),
268 					{ }
269 				}
270 			}, {
271 				.models = (struct pin_machine_model_t[]){
272 					PIN_SUBVENDOR(SONY_81BBID_SUBVENDOR),
273 					{ }
274 				},
275 				.pin_patches = (struct pin_patch_t[]){
276 					PIN_PATCH_STRING(15,  "as=2 color=Black ctype=1/8 device=Headphones loc=Rear"),
277 					PIN_PATCH_STRING(16, "seq=15 as=3 ctype=1/8"),
278 					PIN_PATCH_NOT_APPLICABLE(17),
279 					PIN_PATCH_STRING(18, "as=3 misc=9 color=Red ctype=1/8 device=Mic loc=Rear"),
280 					PIN_PATCH_NOT_APPLICABLE(19),
281 					PIN_PATCH_NOT_APPLICABLE(20),
282 					PIN_PATCH_NOT_APPLICABLE(21),
283 					PIN_PATCH_NOT_APPLICABLE(22),
284 					PIN_PATCH_NOT_APPLICABLE(23),
285 					PIN_PATCH_NOT_APPLICABLE(24),
286 					PIN_PATCH_NOT_APPLICABLE(25),
287 					{ }
288 				}
289 			}, { }
290 		}
291 	}, { /**** CODEC: HDA_CODEC_ALC262 ****/
292 		.id = HDA_CODEC_ALC262,
293 		.patches = (struct model_pin_patch_t[]){
294 			{
295 				.models = (struct pin_machine_model_t[]){
296 					PIN_SUBVENDOR(FS_H270_SUBVENDOR),
297 					{ }
298 				},
299 				.pin_patches = (struct pin_patch_t[]){
300 					PIN_PATCH_STRING(20, "as=1 misc=1 ctype=ATAPI device=Speaker loc=Onboard conn=Fixed"),
301 					PIN_PATCH_STRING(21, "seq=15 as=2 misc=4 color=Black ctype=1/8 device=Headphones loc=Front"),
302 					PIN_PATCH_STRING(22, "seq=15 as=1 misc=4 color=Black ctype=1/8 device=Headphones loc=Rear"),
303 					{ }
304 				}
305 			}, {
306 				.models = (struct pin_machine_model_t[]){
307 					PIN_SUBVENDOR(FL_LB_S7110_SUBVENDOR),
308 					{ }
309 				},
310 				.pin_patches = (struct pin_patch_t[]){
311 					PIN_PATCH_STRING(21, "as=1 misc=1 ctype=Analog device=Speaker loc=Internal conn=Fixed"),
312 					{ }
313 				}
314 			}, {
315 				.models = (struct pin_machine_model_t[]){
316 					PIN_SUBVENDOR(HP_Z200_SUBVENDOR),
317 					{ }
318 				},
319 				.pin_patches = (struct pin_patch_t[]){
320 					PIN_PATCH_STRING(22, "as=2 misc=1 ctype=ATAPI device=Speaker loc=Onboard conn=Fixed"),
321 					{ }
322 				}
323 			}, {
324 				.models = (struct pin_machine_model_t[]){
325 					PIN_SUBVENDOR(TYAN_N6650W_SUBVENDOR),
326 					{ }
327 				},
328 				.pin_patches = (struct pin_patch_t[]){
329 					PIN_PATCH_STRING(22, "as=15 misc=1 color=White ctype=ATAPI device=AUX loc=Onboard"),
330 					{ }
331 				}
332 			}, {
333 				.models = (struct pin_machine_model_t[]){
334 					PIN_SUBVENDOR(LENOVO_3000_SUBVENDOR),
335 					{ }
336 				},
337 				.pin_patches = (struct pin_patch_t[]){
338 					PIN_PATCH_STRING(22, "seq=1 as=2"),
339 					{ }
340 				}
341 			}, { }
342 		}
343 	}, { /**** CODEC: HDA_CODEC_ALC268 ****/
344 		.id = HDA_CODEC_ALC268,
345 		.patches = (struct model_pin_patch_t[]){
346 			{
347 				.models = (struct pin_machine_model_t[]){
348 					PIN_SUBVENDOR(ACER_T5320_SUBVENDOR),
349 					{ }
350 				},
351 				.pin_patches = (struct pin_patch_t[]){
352 					PIN_PATCH_STRING(20, "as=1 seq=15"),
353 					{ }
354 				}
355 			}, {
356 				.models = (struct pin_machine_model_t[]){
357 					PIN_SUBVENDOR(ACER_TM_6293_SUBVENDOR),
358 					{ }
359 				},
360 				.pin_patches = (struct pin_patch_t[]){
361 					PIN_PATCH_STRING(30, "as=8 misc=1 color=Black ctype=Combo device=SPDIF-out loc=Rear"),
362 					{ }
363 				}
364 			}, { }
365 		}
366 	}, { /**** CODEC: HDA_CODEC_ALC269 ****/
367 		.id = HDA_CODEC_ALC269,
368 		.patches = (struct model_pin_patch_t[]){
369 			{
370 				.models = (struct pin_machine_model_t[]){
371 					PIN_SUBVENDOR(LENOVO_X1CRBN_SUBVENDOR),
372 					{ }
373 				},
374 				.pin_patches = (struct pin_patch_t[]){
375 					PIN_PATCH_STRING(21, "as=1 seq=15"),
376 					{ }
377 				}
378 			}, {
379 				.models = (struct pin_machine_model_t[]){
380 					PIN_SUBVENDOR(LENOVO_T430_SUBVENDOR),
381 					PIN_SUBVENDOR(LENOVO_T430S_SUBVENDOR),
382 					PIN_SUBVENDOR(LENOVO_X230_SUBVENDOR),
383 					PIN_SUBVENDOR(LENOVO_X230T_SUBVENDOR),
384 					PIN_SUBVENDOR(LENOVO_T431S_SUBVENDOR),
385 					{ }
386 				},
387 				.pin_patches = (struct pin_patch_t[]){
388 					PIN_PATCH_DOCK_MIC_IN(25),
389 					PIN_PATCH_DOCK_HP(27),
390 					{ }
391 				}
392 			}, {
393 				.models = (struct pin_machine_model_t[]){
394 					PIN_SUBVENDOR(ASUS_UX31A_SUBVENDOR),
395 					{ }
396 				},
397 				.pin_patches = (struct pin_patch_t[]){
398 					PIN_PATCH_STRING(33, "as=1 seq=15"),
399 					{ }
400 				}
401 			}, {
402 				.models = (struct pin_machine_model_t[]){
403 					PIN_SUBVENDOR(ASUS_G73JW_SUBVENDOR),
404 					{ }
405 				},
406 				.pin_patches = (struct pin_patch_t[]){
407 					PIN_PATCH_SUBWOOFER(23),
408 					{ }
409 				}
410 			}, {
411 				.models = (struct pin_machine_model_t[]){
412 					PIN_SUBVENDOR(FL_1475ID_SUBVENDOR),
413 					{ }
414 				},
415 				.pin_patches = (struct pin_patch_t[]){
416 					PIN_PATCH_DOCK_LINE_OUT(26),
417 					PIN_PATCH_DOCK_MIC_IN(27),
418 					{ }
419 				}
420 			}, {
421 				.models = (struct pin_machine_model_t[]){
422 					PIN_SUBVENDOR(FL_LB_U904_SUBVENDOR),
423 					{ }
424 				},
425 				.pin_patches = (struct pin_patch_t[]){
426 					PIN_PATCH_HPMIC_WITH_DETECT(25),
427 					{ }
428 				}
429 			}, {
430 				.models = (struct pin_machine_model_t[]){
431 					PIN_SUBVENDOR(FL_LB_T731_SUBVENDOR),
432 					PIN_SUBVENDOR(FL_LB_E725_SUBVENDOR),
433 					{ }
434 				},
435 				.pin_patches = (struct pin_patch_t[]){
436 					PIN_PATCH_STRING(33, "seq=15 as=2 color=Black ctype=1/8 device=Headphones loc=Front"),
437 					{ }
438 				}
439 			}, {
440 				.models = (struct pin_machine_model_t[]){
441 					PIN_SUBVENDOR(DELL_05F4ID_SUBVENDOR),
442 					PIN_SUBVENDOR(DELL_05F5ID_SUBVENDOR),
443 					PIN_SUBVENDOR(DELL_05F6ID_SUBVENDOR),
444 					{ }
445 				},
446 				.pin_patches = (struct pin_patch_t[]){
447 					PIN_PATCH_JACK_WO_DETECT(25),
448 					PIN_PATCH_HPMIC_WO_DETECT(26),
449 					{ }
450 				}
451 			}, {
452 				.models = (struct pin_machine_model_t[]){
453 					PIN_SUBVENDOR(ACER_V5_571G_SUBVENDOR),
454 					PIN_SUBVENDOR(ACER_V5_122P_SUBVENDOR),
455 					{ }
456 				},
457 				.pin_patches = (struct pin_patch_t[]){
458 					PIN_PATCH_JACK_WO_DETECT(25),
459 					{ }
460 				}
461 			}, {
462 				.models = (struct pin_machine_model_t[]){
463 					PIN_SUBVENDOR(ASUS_X101CH_SUBVENDOR),
464 					{ }
465 				},
466 				.pin_patches = (struct pin_patch_t[]){
467 					PIN_PATCH_STRING(24, "seq=12 as=2 misc=8 color=Black ctype=1/8 device=Mic loc=Right"),
468 					{ }
469 				}
470 			}, {
471 				.models = (struct pin_machine_model_t[]){
472 					PIN_SUBVENDOR(ACER_AC700_SUBVENDOR),
473 					{ }
474 				},
475 				.pin_patches = (struct pin_patch_t[]){
476 					PIN_PATCH_STRING(18, "seq=15 as=2 misc=9 ctype=ATAPI device=Mic loc=Onboard conn=Fixed"),
477 					PIN_PATCH_STRING(20,  "as=1 misc=1 ctype=ATAPI device=Speaker loc=Onboard conn=Fixed"),
478 					PIN_PATCH_STRING(24, "as=1 misc=1 ctype=ATAPI device=Speaker loc=Onboard conn=Fixed"),
479 					PIN_PATCH_STRING(30, "seq=14 as=1 color=Black ctype=Digital device=SPDIF-out loc=Left"),
480 					PIN_PATCH_STRING(33, "seq=15 as=1 color=Black ctype=1/8 device=Headphones loc=Left"),
481 					{ }
482 				}
483 			}, {
484 				.models = (struct pin_machine_model_t[]){
485 					PIN_SUBVENDOR(HP_225AID_SUBVENDOR),
486 					{ }
487 				},
488 				.pin_patches = (struct pin_patch_t[]){
489 					PIN_PATCH_STRING(24, "seq=15 as=3 color=Black ctype=1/8 device=Line-in loc=Ext-Rear"),
490 					PIN_PATCH_STRING(27, "as=2 color=Black ctype=1/8 loc=Ext-Rear"),
491 					{ }
492 				}
493 			}, { }
494 		}
495 	}, { /**** CODEC: HDA_CODEC_ALC271 ****/
496 		.id = HDA_CODEC_ALC271,
497 		.patches = (struct model_pin_patch_t[]){
498 			{
499 				.models = (struct pin_machine_model_t[]){
500 					PIN_SUBVENDOR(ACER_AO725_SUBVENDOR),
501 					PIN_SUBVENDOR(ACER_AO756_SUBVENDOR),
502 					PIN_SUBVENDOR(ACER_E1_472_SUBVENDOR),
503 					PIN_SUBVENDOR(ACER_E1_572_SUBVENDOR),
504 					{ }
505 				},
506 				.pin_patches = (struct pin_patch_t[]){
507 					PIN_PATCH_STRING(20, "as=1 misc=1 ctype=ATAPI device=Speaker loc=Onboard conn=Fixed"),
508 					PIN_PATCH_STRING(25, "as=2 misc=12 color=Pink ctype=1/8 device=Mic loc=Rear"),
509 					PIN_PATCH_STRING(27, "seq=15 as=2 misc=1 ctype=Analog device=Mic loc=Onboard conn=Fixed"),
510 					PIN_PATCH_HP_OUT(33),
511 					{ }
512 				}
513 			}, { }
514 		}
515 	}, { /**** CODEC: HDA_CODEC_ALC280 ****/
516 		.id = HDA_CODEC_ALC280,
517 		.patches = (struct model_pin_patch_t[]){
518 			{
519 				.models = (struct pin_machine_model_t[]){
520 					PIN_SUBVENDOR(HP_2272ID_SUBVENDOR),
521 					PIN_SUBVENDOR(HP_2273ID_SUBVENDOR),
522 					{ }
523 				},
524 				.pin_patches = (struct pin_patch_t[]){
525 					PIN_PATCH_STRING(27, "as=2 color=Black ctype=1/8 loc=Ext-Rear"),
526 					PIN_PATCH_HPMIC_WITH_DETECT(26),
527 					PIN_PATCH_STRING(24, "seq=15 as=3 color=Black ctype=1/8 device=Line-in loc=Ext-Rear"),
528 					{ }
529 				}
530 			}, { }
531 		}
532 	}, { /**** CODEC: HDA_CODEC_ALC282 ****/
533 		.id = HDA_CODEC_ALC282,
534 		.patches = (struct model_pin_patch_t[]){
535 			{
536 				.models = (struct pin_machine_model_t[]){
537 					PIN_SUBVENDOR(ACER_V5_573G_SUBVENDOR),
538 					{ }
539 				},
540 				.pin_patches = (struct pin_patch_t[]){
541 					PIN_PATCH_STRING(18, "as=3 misc=1 ctype=Digital device=Mic loc=Internal conn=Fixed"),
542 					PIN_PATCH_STRING(20, "as=1 misc=1 ctype=Analog device=Speaker loc=Internal conn=Fixed"),
543 					PIN_PATCH_STRING(23, "seq=8 conn=None"),
544 					PIN_PATCH_NOT_APPLICABLE(24),
545 					PIN_PATCH_JACK_WO_DETECT(25),
546 					PIN_PATCH_NOT_APPLICABLE(26),
547 					PIN_PATCH_NOT_APPLICABLE(27),
548 					PIN_PATCH_STRING(29, "seq=13 as=2 misc=11 color=Pink ctype=DIN device=Other conn=None"),
549 					PIN_PATCH_NOT_APPLICABLE(30),
550 					PIN_PATCH_STRING(33, "seq=15 as=1 color=Black ctype=1/8 device=Headphones loc=Left"),
551 					{ }
552 				}
553 			}, { }
554 		}
555 	}, { /**** CODEC: HDA_CODEC_ALC285 ****/
556 		.id = HDA_CODEC_ALC285,
557 		.patches = (struct model_pin_patch_t[]){
558 			{
559 				.models = (struct pin_machine_model_t[]){
560 					PIN_SUBVENDOR(LENOVO_X120KH_SUBVENDOR),
561 					PIN_SUBVENDOR(LENOVO_X120QD_SUBVENDOR),
562 					{ }
563 				},
564 				.pin_patches = (struct pin_patch_t[]){
565 					PIN_PATCH_STRING(33, "seq=15 as=1 color=Black ctype=1/8 device=Headphones loc=Left"),
566 					{ }
567 				}
568 			}, { }
569 		}
570 	}, { /**** CODEC: HDA_CODEC_ALC286 ****/
571 		.id = HDA_CODEC_ALC286,
572 		.patches = (struct model_pin_patch_t[]){
573 			{
574 				.models = (struct pin_machine_model_t[]){
575 					PIN_SUBVENDOR(SONY_VAIO_P11_SUBVENDOR),
576 					PIN_SUBVENDOR(SONY_VAIO_P13_SUBVENDOR),
577 					{ }
578 				},
579 				.pin_patches = (struct pin_patch_t[]){
580 					PIN_PATCH_JACK_WO_DETECT(25),
581 					{ }
582 				}
583 			}, { }
584 		}
585 	}, { /**** CODEC: HDA_CODEC_ALC287 ****/
586 		.id = HDA_CODEC_ALC287,
587 		.patches = (struct model_pin_patch_t[]){
588 			{
589 				.models = (struct pin_machine_model_t[]){
590 					PIN_SUBVENDOR(LENOVO_X1CRBNG11_SUBVENDOR),
591 					{ }
592 				},
593 				.pin_patches = (struct pin_patch_t[]){
594 					PIN_PATCH_NOT_APPLICABLE(20),
595 					PIN_PATCH_STRING(33, "as=1 seq=15 device=Headphones loc=Right"),
596 					{ }
597 				}
598 			}, { }
599 		}
600 	}, { /**** CODEC: HDA_CODEC_ALC288 ****/
601 		.id = HDA_CODEC_ALC288,
602 		.patches = (struct model_pin_patch_t[]){
603 			{
604 				.models = (struct pin_machine_model_t[]){
605 					PIN_SUBVENDOR(DELL_E7240_SUBVENDOR),
606 					{ }
607 				},
608 				.pin_patches = pin_patches_dell_xps_jack
609 			}, { }
610 		}
611 	}, { /**** CODEC: HDA_CODEC_ALC290 ****/
612 		.id = HDA_CODEC_ALC290,
613 		.patches = (struct model_pin_patch_t[]){
614 			{
615 				.models = (struct pin_machine_model_t[]){
616 					PIN_SUBVENDOR(DELL_V5470_SUBVENDOR),
617 					PIN_SUBVENDOR(DELL_V5470_1_SUBVENDOR),
618 					PIN_SUBVENDOR(DELL_V5480_SUBVENDOR),
619 					{ }
620 				},
621 				.pin_patches = (struct pin_patch_t[]){
622 					PIN_PATCH_STRING(18, "as=4 misc=1 ctype=Digital device=Mic loc=Internal conn=Fixed"),
623 					PIN_PATCH_STRING(20, "as=1 misc=1 ctype=Analog device=Speaker loc=Internal conn=Fixed"),
624 					PIN_PATCH_STRING(21, "seq=15 as=1 color=Green ctype=1/8 device=Headphones loc=Front"),
625 					PIN_PATCH_STRING(23, "seq=2 as=1 misc=1 ctype=Analog device=Speaker loc=Internal conn=Fixed"),
626 					PIN_PATCH_JACK_WO_DETECT(26),
627 					{ }
628 				}
629 			}, { }
630 		}
631 	}, { /**** CODEC: HDA_CODEC_ALC292 ****/
632 		.id = HDA_CODEC_ALC292,
633 		.patches = (struct model_pin_patch_t[]){
634 			{
635 				.models = (struct pin_machine_model_t[]){
636 					PIN_SUBVENDOR(LENOVO_X120BS_SUBVENDOR),
637 					{ }
638 				},
639 				.pin_patches = (struct pin_patch_t[]){
640 					PIN_PATCH_STRING(21, "as=1 seq=15"),
641 					{ }
642 				}
643 			}, { }
644 		}
645 	}, { /**** CODEC: HDA_CODEC_ALC293 ****/
646 		.id = HDA_CODEC_ALC293,
647 		.patches = (struct model_pin_patch_t[]){
648 			{
649 				.models = (struct pin_machine_model_t[]){
650 					PIN_SUBVENDOR(DELL_064AID_SUBVENDOR),
651 					PIN_SUBVENDOR(DELL_064BID_SUBVENDOR),
652 					PIN_SUBVENDOR(DELL_06D9ID_SUBVENDOR),
653 					PIN_SUBVENDOR(DELL_06DAID_SUBVENDOR),
654 					PIN_SUBVENDOR(DELL_06DBID_SUBVENDOR),
655 					PIN_SUBVENDOR(DELL_06DDID_SUBVENDOR),
656 					PIN_SUBVENDOR(DELL_06DEID_SUBVENDOR),
657 					PIN_SUBVENDOR(DELL_06DFID_SUBVENDOR),
658 					PIN_SUBVENDOR(DELL_06E0ID_SUBVENDOR),
659 					PIN_SUBVENDOR(DELL_164AID_SUBVENDOR),
660 					PIN_SUBVENDOR(DELL_164BID_SUBVENDOR),
661 					{ }
662 				},
663 				.pin_patches = (struct pin_patch_t[]){
664 					PIN_PATCH_HPMIC_WO_DETECT(24),
665 					PIN_PATCH_JACK_WO_DETECT(26),
666 					{ }
667 				}
668 			}, { }
669 		}
670 	}, { /**** CODEC: HDA_CODEC_ALC298 ****/
671 		.id = HDA_CODEC_ALC298,
672 		.patches = (struct model_pin_patch_t[]){
673 			{
674 				.models = (struct pin_machine_model_t[]){
675 					PIN_SUBVENDOR(DELL_XPS9560_SUBVENDOR),
676 					{ }
677 				},
678 				.pin_patches = pin_patches_dell_xps_jack
679 			},
680 			{
681 				.models = (struct pin_machine_model_t[]){
682 					PIN_SUBVENDOR(LENOVO_ALL_SUBVENDOR),
683 					{ }
684 				},
685 				.pin_patches = (struct pin_patch_t[]){
686 					PIN_PATCH_DOCK_LINE_OUT(23),
687 					PIN_PATCH_HP_OUT(33),
688 					{ }
689 				},
690 			}, { }
691 		}
692 	}, { /**** CODEC: HDA_CODEC_ALC861 ****/
693 		.id = HDA_CODEC_ALC861,
694 		.patches = (struct model_pin_patch_t[]){
695 			{
696 				.models = (struct pin_machine_model_t[]){
697 					PIN_SUBVENDOR(ASUS_W6F_SUBVENDOR),
698 					{ }
699 				},
700 				.pin_patches = pin_patches_asus_w6f
701 			}, {
702 				.models = (struct pin_machine_model_t[]){
703 					PIN_SUBVENDOR(UNIWILL_9075_SUBVENDOR),
704 					{ }
705 				},
706 				.pin_patches = pin_patches_uniwill_9075
707 			}, { }
708 		}
709 	}, { /**** CODEC: HDA_CODEC_ALC880 ****/
710 		.id = HDA_CODEC_ALC880,
711 		.patches = (struct model_pin_patch_t[]){
712 			{ // old patch
713 				.models = (struct pin_machine_model_t[]){
714 					PIN_SUBVENDOR(LG_LW20_SUBVENDOR),
715 					{ }
716 				},
717 				.pin_patches = pin_patches_lg_lw20
718 			}, { // old patch
719 				.models = (struct pin_machine_model_t[]){
720 					PIN_SUBVENDOR(CLEVO_D900T_SUBVENDOR),
721 					PIN_SUBVENDOR(ASUS_M5200_SUBVENDOR),
722 					{ }
723 				},
724 				.pin_patches = pin_patches_clevo_d900t_asus_m5200
725 			}, {
726 				.models = (struct pin_machine_model_t[]){
727 					PIN_SUBVENDOR(LG_M1_SUBVENDOR),
728 					PIN_SUBVENDOR(LG_P1_SUBVENDOR),
729 					PIN_SUBVENDOR(LG_W1_SUBVENDOR),
730 					{ }
731 				},
732 				.pin_patches = (struct pin_patch_t[]){
733 					PIN_PATCH_NOT_APPLICABLE(22),
734 					PIN_PATCH_NOT_APPLICABLE(24),
735 					PIN_PATCH_NOT_APPLICABLE(26),
736 					{ }
737 				}
738 			}, {
739 				.models = (struct pin_machine_model_t[]){
740 					PIN_SUBVENDOR(COEUS_G610P_SUBVENDOR),
741 					PIN_SUBVENDOR(ARIMA_W810_SUBVENDOR),
742 					{ }
743 				},
744 				.pin_patches = (struct pin_patch_t[]){
745 					PIN_PATCH_NOT_APPLICABLE(23),
746 					{ }
747 				}
748 			}, {
749 				.models = (struct pin_machine_model_t[]){
750 					PIN_SUBVENDOR(FS_AMILO_M1437_SUBVENDOR),
751 					PIN_SUBVENDOR(FS_AMILO_M1451G_SUBVENDOR),
752 					PIN_SUBVENDOR(FS_AMILO_PI1556_SUBVENDOR),
753 					{ }
754 				},
755 				.pin_patches = (struct pin_patch_t[]){
756 					PIN_PATCH_HP_OUT(20),
757 					PIN_PATCH_SPEAKER(21),
758 					PIN_PATCH_BASS_SPEAKER(22),
759 					PIN_PATCH_NOT_APPLICABLE(23),
760 					PIN_PATCH_NOT_APPLICABLE(24),
761 					PIN_PATCH_MIC_IN(25),
762 					PIN_PATCH_NOT_APPLICABLE(26),
763 					PIN_PATCH_NOT_APPLICABLE(27),
764 					PIN_PATCH_NOT_APPLICABLE(28),
765 					PIN_PATCH_NOT_APPLICABLE(29),
766 					PIN_PATCH_NOT_APPLICABLE(30),
767 					{ }
768 				}
769 			}, {
770 				.models = (struct pin_machine_model_t[]){
771 					PIN_SUBVENDOR(UNIWILL_9054_SUBVENDOR),
772 					PIN_SUBVENDOR(FS_AMILO_XI1526_SUBVENDOR),
773 					{ }
774 				},
775 				.pin_patches = (struct pin_patch_t[]){
776 					PIN_PATCH_HP_OUT(20),
777 					PIN_PATCH_SPEAKER(21),
778 					PIN_PATCH_NOT_APPLICABLE(22),
779 					PIN_PATCH_NOT_APPLICABLE(23),
780 					PIN_PATCH_NOT_APPLICABLE(24),
781 					PIN_PATCH_MIC_IN(25),
782 					PIN_PATCH_NOT_APPLICABLE(26),
783 					PIN_PATCH_NOT_APPLICABLE(27),
784 					PIN_PATCH_NOT_APPLICABLE(28),
785 					PIN_PATCH_NOT_APPLICABLE(29),
786 					PIN_PATCH_SPDIF_OUT(30),
787 					{ }
788 				}
789 			}, {
790 				.models = (struct pin_machine_model_t[]){
791 					PIN_SUBVENDOR(LG_LW25_SUBVENDOR),
792 					{ }
793 				},
794 				.pin_patches = (struct pin_patch_t[]){
795 					PIN_PATCH_STRING(26, "seq=15 as=4 misc=4 color=Blue ctype=1/8 device=Line-in loc=Rear"),
796 					PIN_PATCH_STRING(27, "seq=15 as=3 color=Green ctype=1/8 device=Headphones loc=Left"),
797 					{ }
798 				}
799 			}, {
800 				.models = (struct pin_machine_model_t[]){
801 					PIN_SUBVENDOR(UNIWILL_9070_SUBVENDOR),
802 					{ }
803 				},
804 				.pin_patches = (struct pin_patch_t[]){
805 					PIN_PATCH_HP(20),
806 					PIN_PATCH_SPEAKER(21),
807 					PIN_PATCH_BASS_SPEAKER(22),
808 					{ }
809 				}
810 			}, {
811 				.models = (struct pin_machine_model_t[]){
812 					PIN_SUBVENDOR(UNIWILL_9050_SUBVENDOR),
813 					{ }
814 				},
815 				.pin_patches = (struct pin_patch_t[]){
816 					PIN_PATCH_NOT_APPLICABLE(23),
817 					PIN_PATCH_NOT_APPLICABLE(25),
818 					PIN_PATCH_NOT_APPLICABLE(27),
819 					PIN_PATCH_NOT_APPLICABLE(31),
820 					{ }
821 				}
822 			}, {
823 				.models = (struct pin_machine_model_t[]){
824 					PIN_SUBVENDOR(ASUS_Z71V_SUBVENDOR),
825 					{ }
826 				},
827 				.pin_patches = (struct pin_patch_t[]){
828 					PIN_PATCH_SPEAKER(20),
829 					PIN_PATCH_HP(21),
830 					PIN_PATCH_NOT_APPLICABLE(22),
831 					PIN_PATCH_NOT_APPLICABLE(23),
832 					PIN_PATCH_MIC_IN(24),
833 					PIN_PATCH_NOT_APPLICABLE(25),
834 					PIN_PATCH_LINE_IN(26),
835 					{ }
836 				}
837 			}, {
838 				.models = (struct pin_machine_model_t[]){
839 					PIN_SUBVENDOR(ASUS_W5A_SUBVENDOR),
840 					{ }
841 				},
842 				.pin_patches = (struct pin_patch_t[]){
843 					PIN_PATCH_HP(20),
844 					PIN_PATCH_NOT_APPLICABLE(21),
845 					PIN_PATCH_NOT_APPLICABLE(22),
846 					PIN_PATCH_NOT_APPLICABLE(23),
847 					PIN_PATCH_MIC_INTERNAL(24),
848 					PIN_PATCH_NOT_APPLICABLE(25),
849 					PIN_PATCH_NOT_APPLICABLE(26),
850 					PIN_PATCH_NOT_APPLICABLE(27),
851 					PIN_PATCH_NOT_APPLICABLE(28),
852 					PIN_PATCH_NOT_APPLICABLE(29),
853 					PIN_PATCH_STRING(30, "seq=14 as=1 misc=1 color=Black ctype=ATAPI device=SPDIF-out loc=Lid-In conn=Fixed"),
854 					{ }
855 				}
856 			}, {
857 				.models = (struct pin_machine_model_t[]){
858 					PIN_SUBVENDOR(ACER_E310ID_SUBVENDOR),
859 					PIN_SUBVENDOR(SONY_81A0ID_SUBVENDOR),
860 					PIN_SUBVENDOR(SONY_81D6ID_SUBVENDOR),
861 					{ }
862 				},
863 				.pin_patches = (struct pin_patch_t[]){
864 					PIN_PATCH_LINE_OUT(20),
865 					PIN_PATCH_NOT_APPLICABLE(21),
866 					PIN_PATCH_NOT_APPLICABLE(22),
867 					PIN_PATCH_NOT_APPLICABLE(23),
868 					PIN_PATCH_STRING(24, "as=3 misc=12 color=Pink ctype=1/8 device=Mic loc=Rear"),
869 					PIN_PATCH_HP(25),
870 					PIN_PATCH_LINE_IN(26),
871 					PIN_PATCH_MIC_FRONT(27),
872 					PIN_PATCH_NOT_APPLICABLE(28),
873 					PIN_PATCH_NOT_APPLICABLE(29),
874 					PIN_PATCH_NOT_APPLICABLE(30),
875 					PIN_PATCH_NOT_APPLICABLE(31),
876 					{ }
877 				}
878 			}, {
879 				.models = (struct pin_machine_model_t[]){
880 					PIN_SUBVENDOR(ACER_0070ID_SUBVENDOR),
881 					PIN_SUBVENDOR(ACER_E309ID_SUBVENDOR),
882 					PIN_SUBVENDOR(INTEL_D402ID_SUBVENDOR),
883 					PIN_SUBVENDOR(INTEL_E305ID_SUBVENDOR),
884 					PIN_SUBVENDOR(INTEL_E308ID_SUBVENDOR),
885 					{ }
886 				},
887 				.pin_patches = (struct pin_patch_t[]){
888 					PIN_PATCH_LINE_OUT(20),
889 					PIN_PATCH_NOT_APPLICABLE(21),
890 					PIN_PATCH_NOT_APPLICABLE(22),
891 					PIN_PATCH_NOT_APPLICABLE(23),
892 					PIN_PATCH_STRING(24, "as=3 misc=12 color=Pink ctype=1/8 device=Mic loc=Rear"),
893 					PIN_PATCH_HP(25),
894 					PIN_PATCH_LINE_IN(26),
895 					PIN_PATCH_MIC_FRONT(27),
896 					PIN_PATCH_NOT_APPLICABLE(28),
897 					PIN_PATCH_NOT_APPLICABLE(29),
898 					PIN_PATCH_STRING(30, "seq=14 as=1 misc=1 color=Black ctype=RCA device=SPDIF-out loc=Rear"),
899 					PIN_PATCH_NOT_APPLICABLE(31),
900 					{ }
901 				}
902 			}, {
903 				.models = (struct pin_machine_model_t[]){
904 					PIN_SUBVENDOR(GATEWAY_3032ID_SUBVENDOR),
905 					PIN_SUBVENDOR(GATEWAY_3033ID_SUBVENDOR),
906 					PIN_SUBVENDOR(GATEWAY_4039ID_SUBVENDOR),
907 					{ }
908 				},
909 				.pin_patches = (struct pin_patch_t[]){
910 					PIN_PATCH_LINE_OUT(20),
911 					PIN_PATCH_NOT_APPLICABLE(21),
912 					PIN_PATCH_CLFE(22),
913 					PIN_PATCH_SURROUND(23),
914 					PIN_PATCH_STRING(24, "as=3 misc=12 color=Pink ctype=1/8 device=Mic loc=Rear"),
915 					PIN_PATCH_HP(25),
916 					PIN_PATCH_LINE_IN(26),
917 					PIN_PATCH_MIC_FRONT(27),
918 					PIN_PATCH_NOT_APPLICABLE(28),
919 					PIN_PATCH_NOT_APPLICABLE(29),
920 					PIN_PATCH_NOT_APPLICABLE(30),
921 					PIN_PATCH_NOT_APPLICABLE(31),
922 					{ }
923 				}
924 			}, {
925 				.models = (struct pin_machine_model_t[]){
926 					PIN_SUBVENDOR(COEUS_A880ID_SUBVENDOR),
927 					PIN_SUBVENDOR(BIOSTAR_8202ID_SUBVENDOR),
928 					PIN_SUBVENDOR(EPOX_400DID_SUBVENDOR),
929 					PIN_SUBVENDOR(EPOX_EP5LDA_SUBVENDOR),
930 					PIN_SUBVENDOR(INTEL_A100ID_SUBVENDOR),
931 					PIN_SUBVENDOR(INTEL_D400ID_SUBVENDOR),
932 					PIN_SUBVENDOR(INTEL_D401ID_SUBVENDOR),
933 					PIN_SUBVENDOR(INTEL_E224ID_SUBVENDOR),
934 					PIN_SUBVENDOR(INTEL_E400ID_SUBVENDOR),
935 					PIN_SUBVENDOR(INTEL_E401ID_SUBVENDOR),
936 					PIN_SUBVENDOR(INTEL_E402ID_SUBVENDOR),
937 					PIN_SUBVENDOR(AOPEN_I915GMMHFS_SUBVENDOR),
938 					{ }
939 				},
940 				.pin_patches = (struct pin_patch_t[]){
941 					PIN_PATCH_LINE_OUT(20),
942 					PIN_PATCH_NOT_APPLICABLE(21),
943 					PIN_PATCH_CLFE(22),
944 					PIN_PATCH_SURROUND(23),
945 					PIN_PATCH_STRING(24, "as=3 misc=12 color=Pink ctype=1/8 device=Mic loc=Rear"),
946 					PIN_PATCH_HP(25),
947 					PIN_PATCH_LINE_IN(26),
948 					PIN_PATCH_MIC_FRONT(27),
949 					PIN_PATCH_NOT_APPLICABLE(28),
950 					PIN_PATCH_NOT_APPLICABLE(29),
951 					PIN_PATCH_STRING(30, "seq=14 as=1 misc=1 color=Black ctype=RCA device=SPDIF-out loc=Rear"),
952 					PIN_PATCH_NOT_APPLICABLE(31),
953 					{ }
954 				}
955 			}, {
956 				.models = (struct pin_machine_model_t[]){
957 					PIN_SUBVENDOR(ACER_APFV_SUBVENDOR),
958 					{ }
959 				},
960 				.pin_patches = (struct pin_patch_t[]){
961 					PIN_PATCH_LINE_OUT(20),
962 					PIN_PATCH_SURROUND(21),
963 					PIN_PATCH_CLFE(22),
964 					PIN_PATCH_STRING(23, "seq=4 as=1 misc=4 color=Grey ctype=1/8 loc=Rear"),
965 					PIN_PATCH_STRING(24, "as=3 misc=12 color=Pink ctype=1/8 device=Mic loc=Rear"),
966 					PIN_PATCH_MIC_FRONT(25),
967 					PIN_PATCH_LINE_IN(26),
968 					PIN_PATCH_HP(27),
969 					PIN_PATCH_NOT_APPLICABLE(28),
970 					PIN_PATCH_NOT_APPLICABLE(29),
971 					PIN_PATCH_NOT_APPLICABLE(30),
972 					PIN_PATCH_NOT_APPLICABLE(31),
973 					{ }
974 				}
975 			}, {
976 				.models = (struct pin_machine_model_t[]){
977 					PIN_SUBVENDOR(ACER_0077ID_SUBVENDOR),
978 					PIN_SUBVENDOR(ACER_0078ID_SUBVENDOR),
979 					PIN_SUBVENDOR(ACER_0087ID_SUBVENDOR),
980 					PIN_SUBVENDOR(SHUTTLE_ST20G5_SUBVENDOR),
981 					PIN_SUBVENDOR(GB_K8_SUBVENDOR),
982 					PIN_SUBVENDOR(MSI_1150ID_SUBVENDOR),
983 					PIN_SUBVENDOR(FIC_P4M_SUBVENDOR),
984 					{ }
985 				},
986 				.pin_patches = (struct pin_patch_t[]){
987 					PIN_PATCH_LINE_OUT(20),
988 					PIN_PATCH_SURROUND(21),
989 					PIN_PATCH_CLFE(22),
990 					PIN_PATCH_STRING(23, "seq=4 as=1 misc=4 color=Grey ctype=1/8 loc=Rear"),
991 					PIN_PATCH_STRING(24, "as=3 misc=12 color=Pink ctype=1/8 device=Mic loc=Rear"),
992 					PIN_PATCH_MIC_FRONT(25),
993 					PIN_PATCH_LINE_IN(26),
994 					PIN_PATCH_HP(27),
995 					PIN_PATCH_NOT_APPLICABLE(28),
996 					PIN_PATCH_NOT_APPLICABLE(29),
997 					PIN_PATCH_STRING(30, "seq=14 as=1 misc=1 color=Black ctype=RCA device=SPDIF-out loc=Rear"),
998 					PIN_PATCH_NOT_APPLICABLE(31),
999 					{ }
1000 				}
1001 			}, { }
1002 		}
1003 	}, { /**** CODEC: HDA_CODEC_ALC883 ****/
1004 		.id = HDA_CODEC_ALC883,
1005 		.patches = (struct model_pin_patch_t[]){
1006 			{
1007 				.models = (struct pin_machine_model_t[]){
1008 					PIN_SUBVENDOR(MSI_MS034A_SUBVENDOR),
1009 					{ }
1010 				},
1011 				.pin_patches = pin_patches_msi_ms034a
1012 			}, { }
1013 		}
1014 	}, { /**** CODEC: HDA_CODEC_ALC892 ****/
1015 		.id = HDA_CODEC_ALC892,
1016 		.patches = (struct model_pin_patch_t[]){
1017 			{
1018 				.models = (struct pin_machine_model_t[]){
1019 					PIN_SUBVENDOR(INTEL_DH87RL_SUBVENDOR),
1020 					{ }
1021 				},
1022 				.pin_patches = (struct pin_patch_t[]){
1023 					PIN_PATCH_STRING(27, "as=1 seq=15"),
1024 					{ }
1025 				}
1026 			}, { }
1027 		}
1028 	}
1029 };
1030 
1031 #endif /* PIN_PATCH_REALTEK_H */
1032