3 * included by patch_realtek.c
14 #ifdef CONFIG_SND_DEBUG
17 ALC260_MODEL_LAST /* last tag */
20 static const hda_nid_t alc260_dac_nids[1] = {
25 static const hda_nid_t alc260_adc_nids[1] = {
30 static const hda_nid_t alc260_adc_nids_alt[1] = {
35 /* NIDs used when simultaneous access to both ADCs makes sense. Note that
36 * alc260_capture_mixer assumes ADC0 (nid 0x04) is the first ADC.
38 static const hda_nid_t alc260_dual_adc_nids[2] = {
43 #define ALC260_DIGOUT_NID 0x03
44 #define ALC260_DIGIN_NID 0x06
46 static const struct hda_input_mux alc260_capture_source = {
56 /* On Fujitsu S702x laptops capture only makes sense from Mic/LineIn jack,
57 * headphone jack and the internal CD lines since these are the only pins at
58 * which audio can appear. For flexibility, also allow the option of
59 * recording the mixer output on the second ADC (ADC0 doesn't have a
60 * connection to the mixer output).
62 static const struct hda_input_mux alc260_fujitsu_capture_sources[2] = {
83 /* Acer TravelMate(/Extensa/Aspire) notebooks have similar configuration to
84 * the Fujitsu S702x, but jacks are marked differently.
86 static const struct hda_input_mux alc260_acer_capture_sources[2] = {
102 { "Headphone", 0x6 },
108 /* Maxdata Favorit 100XS */
109 static const struct hda_input_mux alc260_favorit100_capture_sources[2] = {
128 * This is just place-holder, so there's something for alc_build_pcms to look
129 * at when it calculates the maximum number of channels. ALC260 has no mixer
130 * element which allows changing the channel mode, so the verb list is
133 static const struct hda_channel_mode alc260_modes[1] = {
138 /* Mixer combinations
140 * basic: base_output + input + pc_beep + capture
141 * fujitsu: fujitsu + capture
142 * acer: acer + capture
145 static const struct snd_kcontrol_new alc260_base_output_mixer[] = {
146 HDA_CODEC_VOLUME("Front Playback Volume", 0x08, 0x0, HDA_OUTPUT),
147 HDA_BIND_MUTE("Front Playback Switch", 0x08, 2, HDA_INPUT),
148 HDA_CODEC_VOLUME("Headphone Playback Volume", 0x09, 0x0, HDA_OUTPUT),
149 HDA_BIND_MUTE("Headphone Playback Switch", 0x09, 2, HDA_INPUT),
150 HDA_CODEC_VOLUME_MONO("Mono Playback Volume", 0x0a, 1, 0x0, HDA_OUTPUT),
151 HDA_BIND_MUTE_MONO("Mono Playback Switch", 0x0a, 1, 2, HDA_INPUT),
155 static const struct snd_kcontrol_new alc260_input_mixer[] = {
156 HDA_CODEC_VOLUME("CD Playback Volume", 0x07, 0x04, HDA_INPUT),
157 HDA_CODEC_MUTE("CD Playback Switch", 0x07, 0x04, HDA_INPUT),
158 HDA_CODEC_VOLUME("Line Playback Volume", 0x07, 0x02, HDA_INPUT),
159 HDA_CODEC_MUTE("Line Playback Switch", 0x07, 0x02, HDA_INPUT),
160 HDA_CODEC_VOLUME("Mic Playback Volume", 0x07, 0x0, HDA_INPUT),
161 HDA_CODEC_MUTE("Mic Playback Switch", 0x07, 0x0, HDA_INPUT),
162 HDA_CODEC_VOLUME("Front Mic Playback Volume", 0x07, 0x01, HDA_INPUT),
163 HDA_CODEC_MUTE("Front Mic Playback Switch", 0x07, 0x01, HDA_INPUT),
167 /* Fujitsu S702x series laptops. ALC260 pin usage: Mic/Line jack = 0x12,
168 * HP jack = 0x14, CD audio = 0x16, internal speaker = 0x10.
170 static const struct snd_kcontrol_new alc260_fujitsu_mixer[] = {
171 HDA_CODEC_VOLUME("Headphone Playback Volume", 0x08, 0x0, HDA_OUTPUT),
172 HDA_BIND_MUTE("Headphone Playback Switch", 0x08, 2, HDA_INPUT),
173 ALC_PIN_MODE("Headphone Jack Mode", 0x14, ALC_PIN_DIR_INOUT),
174 HDA_CODEC_VOLUME("CD Playback Volume", 0x07, 0x04, HDA_INPUT),
175 HDA_CODEC_MUTE("CD Playback Switch", 0x07, 0x04, HDA_INPUT),
176 HDA_CODEC_VOLUME("Mic/Line Playback Volume", 0x07, 0x0, HDA_INPUT),
177 HDA_CODEC_MUTE("Mic/Line Playback Switch", 0x07, 0x0, HDA_INPUT),
178 ALC_PIN_MODE("Mic/Line Jack Mode", 0x12, ALC_PIN_DIR_IN),
179 HDA_CODEC_VOLUME("Speaker Playback Volume", 0x09, 0x0, HDA_OUTPUT),
180 HDA_BIND_MUTE("Speaker Playback Switch", 0x09, 2, HDA_INPUT),
184 /* Mixer for Acer TravelMate(/Extensa/Aspire) notebooks. Note that current
185 * versions of the ALC260 don't act on requests to enable mic bias from NID
186 * 0x0f (used to drive the headphone jack in these laptops). The ALC260
187 * datasheet doesn't mention this restriction. At this stage it's not clear
188 * whether this behaviour is intentional or is a hardware bug in chip
189 * revisions available in early 2006. Therefore for now allow the
190 * "Headphone Jack Mode" control to span all choices, but if it turns out
191 * that the lack of mic bias for this NID is intentional we could change the
192 * mode from ALC_PIN_DIR_INOUT to ALC_PIN_DIR_INOUT_NOMICBIAS.
194 * In addition, Acer TravelMate(/Extensa/Aspire) notebooks in early 2006
195 * don't appear to make the mic bias available from the "line" jack, even
196 * though the NID used for this jack (0x14) can supply it. The theory is
197 * that perhaps Acer have included blocking capacitors between the ALC260
198 * and the output jack. If this turns out to be the case for all such
199 * models the "Line Jack Mode" mode could be changed from ALC_PIN_DIR_INOUT
200 * to ALC_PIN_DIR_INOUT_NOMICBIAS.
202 * The C20x Tablet series have a mono internal speaker which is controlled
203 * via the chip's Mono sum widget and pin complex, so include the necessary
204 * controls for such models. On models without a "mono speaker" the control
207 static const struct snd_kcontrol_new alc260_acer_mixer[] = {
208 HDA_CODEC_VOLUME("Master Playback Volume", 0x08, 0x0, HDA_OUTPUT),
209 HDA_BIND_MUTE("Master Playback Switch", 0x08, 2, HDA_INPUT),
210 ALC_PIN_MODE("Headphone Jack Mode", 0x0f, ALC_PIN_DIR_INOUT),
211 HDA_CODEC_VOLUME_MONO("Speaker Playback Volume", 0x0a, 1, 0x0,
213 HDA_BIND_MUTE_MONO("Speaker Playback Switch", 0x0a, 1, 2,
215 HDA_CODEC_VOLUME("CD Playback Volume", 0x07, 0x04, HDA_INPUT),
216 HDA_CODEC_MUTE("CD Playback Switch", 0x07, 0x04, HDA_INPUT),
217 HDA_CODEC_VOLUME("Mic Playback Volume", 0x07, 0x0, HDA_INPUT),
218 HDA_CODEC_MUTE("Mic Playback Switch", 0x07, 0x0, HDA_INPUT),
219 ALC_PIN_MODE("Mic Jack Mode", 0x12, ALC_PIN_DIR_IN),
220 HDA_CODEC_VOLUME("Line Playback Volume", 0x07, 0x02, HDA_INPUT),
221 HDA_CODEC_MUTE("Line Playback Switch", 0x07, 0x02, HDA_INPUT),
222 ALC_PIN_MODE("Line Jack Mode", 0x14, ALC_PIN_DIR_INOUT),
226 /* Maxdata Favorit 100XS: one output and one input (0x12) jack
228 static const struct snd_kcontrol_new alc260_favorit100_mixer[] = {
229 HDA_CODEC_VOLUME("Master Playback Volume", 0x08, 0x0, HDA_OUTPUT),
230 HDA_BIND_MUTE("Master Playback Switch", 0x08, 2, HDA_INPUT),
231 ALC_PIN_MODE("Output Jack Mode", 0x0f, ALC_PIN_DIR_INOUT),
232 HDA_CODEC_VOLUME("Line/Mic Playback Volume", 0x07, 0x0, HDA_INPUT),
233 HDA_CODEC_MUTE("Line/Mic Playback Switch", 0x07, 0x0, HDA_INPUT),
234 ALC_PIN_MODE("Line/Mic Jack Mode", 0x12, ALC_PIN_DIR_IN),
238 /* Replacer 672V ALC260 pin usage: Mic jack = 0x12,
239 * Line In jack = 0x14, ATAPI Mic = 0x13, speaker = 0x0f.
241 static const struct snd_kcontrol_new alc260_replacer_672v_mixer[] = {
242 HDA_CODEC_VOLUME("Master Playback Volume", 0x08, 0x0, HDA_OUTPUT),
243 HDA_BIND_MUTE("Master Playback Switch", 0x08, 0x2, HDA_INPUT),
244 HDA_CODEC_VOLUME("Mic Playback Volume", 0x07, 0x0, HDA_INPUT),
245 HDA_CODEC_MUTE("Mic Playback Switch", 0x07, 0x0, HDA_INPUT),
246 ALC_PIN_MODE("Mic Jack Mode", 0x12, ALC_PIN_DIR_IN),
247 HDA_CODEC_VOLUME("ATAPI Mic Playback Volume", 0x07, 0x1, HDA_INPUT),
248 HDA_CODEC_MUTE("ATATI Mic Playback Switch", 0x07, 0x1, HDA_INPUT),
249 HDA_CODEC_VOLUME("Line Playback Volume", 0x07, 0x02, HDA_INPUT),
250 HDA_CODEC_MUTE("Line Playback Switch", 0x07, 0x02, HDA_INPUT),
251 ALC_PIN_MODE("Line Jack Mode", 0x14, ALC_PIN_DIR_INOUT),
256 * initialization verbs
258 static const struct hda_verb alc260_init_verbs[] = {
259 /* Line In pin widget for input */
260 {0x14, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_IN},
261 /* CD pin widget for input */
262 {0x16, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_IN},
263 /* Mic1 (rear panel) pin widget for input and vref at 80% */
264 {0x12, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_VREF80},
265 /* Mic2 (front panel) pin widget for input and vref at 80% */
266 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_VREF80},
267 /* LINE-2 is used for line-out in rear */
268 {0x15, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
269 /* select line-out */
270 {0x0e, AC_VERB_SET_CONNECT_SEL, 0x00},
272 {0x0f, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
274 {0x10, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_HP},
276 {0x11, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
277 /* mute capture amp left and right */
278 {0x04, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
279 /* set connection select to line in (default select for this ADC) */
280 {0x04, AC_VERB_SET_CONNECT_SEL, 0x02},
281 /* mute capture amp left and right */
282 {0x05, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
283 /* set connection select to line in (default select for this ADC) */
284 {0x05, AC_VERB_SET_CONNECT_SEL, 0x02},
285 /* set vol=0 Line-Out mixer amp left and right */
286 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
287 /* unmute pin widget amp left and right (no gain on this amp) */
288 {0x0f, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
289 /* set vol=0 HP mixer amp left and right */
290 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
291 /* unmute pin widget amp left and right (no gain on this amp) */
292 {0x10, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
293 /* set vol=0 Mono mixer amp left and right */
294 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
295 /* unmute pin widget amp left and right (no gain on this amp) */
296 {0x11, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
297 /* unmute LINE-2 out pin */
298 {0x15, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
299 /* Amp Indexes: CD = 0x04, Line In 1 = 0x02, Mic 1 = 0x00 &
302 /* mute analog inputs */
303 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
304 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
305 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(2)},
306 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(3)},
307 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(4)},
308 /* Amp Indexes: DAC = 0x01 & mixer = 0x00 */
309 /* mute Front out path */
310 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
311 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
312 /* mute Headphone out path */
313 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
314 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
315 /* mute Mono out path */
316 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
317 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
321 /* Initialisation sequence for ALC260 as configured in Fujitsu S702x
322 * laptops. ALC260 pin usage: Mic/Line jack = 0x12, HP jack = 0x14, CD
323 * audio = 0x16, internal speaker = 0x10.
325 static const struct hda_verb alc260_fujitsu_init_verbs[] = {
326 /* Disable all GPIOs */
327 {0x01, AC_VERB_SET_GPIO_MASK, 0},
328 /* Internal speaker is connected to headphone pin */
329 {0x10, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_HP},
330 /* Headphone/Line-out jack connects to Line1 pin; make it an output */
331 {0x14, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
332 /* Mic/Line-in jack is connected to mic1 pin, so make it an input */
333 {0x12, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_IN},
334 /* Ensure all other unused pins are disabled and muted. */
335 {0x0f, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
336 {0x0f, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
337 {0x11, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
338 {0x11, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
339 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
340 {0x13, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
341 {0x15, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
342 {0x15, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
344 /* Disable digital (SPDIF) pins */
345 {0x03, AC_VERB_SET_DIGI_CONVERT_1, 0},
346 {0x06, AC_VERB_SET_DIGI_CONVERT_1, 0},
348 /* Ensure Line1 pin widget takes its input from the OUT1 sum bus
349 * when acting as an output.
351 {0x0d, AC_VERB_SET_CONNECT_SEL, 0},
353 /* Start with output sum widgets muted and their output gains at min */
354 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
355 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
356 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
357 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
358 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
359 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
360 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
361 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
362 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
364 /* Unmute HP pin widget amp left and right (no equiv mixer ctrl) */
365 {0x10, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
366 /* Unmute Line1 pin widget output buffer since it starts as an output.
367 * If the pin mode is changed by the user the pin mode control will
368 * take care of enabling the pin's input/output buffers as needed.
369 * Therefore there's no need to enable the input buffer at this
372 {0x14, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
373 /* Unmute input buffer of pin widget used for Line-in (no equiv
376 {0x12, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
378 /* Mute capture amp left and right */
379 {0x04, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
380 /* Set ADC connection select to match default mixer setting - line
383 {0x04, AC_VERB_SET_CONNECT_SEL, 0x00},
385 /* Do the same for the second ADC: mute capture input amp and
386 * set ADC connection to line in (on mic1 pin)
388 {0x05, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
389 {0x05, AC_VERB_SET_CONNECT_SEL, 0x00},
391 /* Mute all inputs to mixer widget (even unconnected ones) */
392 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)}, /* mic1 pin */
393 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)}, /* mic2 pin */
394 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(2)}, /* line1 pin */
395 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(3)}, /* line2 pin */
396 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(4)}, /* CD pin */
397 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(5)}, /* Beep-gen pin */
398 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(6)}, /* Line-out pin */
399 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(7)}, /* HP-pin pin */
404 /* Initialisation sequence for ALC260 as configured in Acer TravelMate and
405 * similar laptops (adapted from Fujitsu init verbs).
407 static const struct hda_verb alc260_acer_init_verbs[] = {
408 /* On TravelMate laptops, GPIO 0 enables the internal speaker and
409 * the headphone jack. Turn this on and rely on the standard mute
410 * methods whenever the user wants to turn these outputs off.
412 {0x01, AC_VERB_SET_GPIO_MASK, 0x01},
413 {0x01, AC_VERB_SET_GPIO_DIRECTION, 0x01},
414 {0x01, AC_VERB_SET_GPIO_DATA, 0x01},
415 /* Internal speaker/Headphone jack is connected to Line-out pin */
416 {0x0f, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_HP},
417 /* Internal microphone/Mic jack is connected to Mic1 pin */
418 {0x12, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_VREF50},
419 /* Line In jack is connected to Line1 pin */
420 {0x14, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_IN},
421 /* Some Acers (eg: C20x Tablets) use Mono pin for internal speaker */
422 {0x11, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_HP},
423 /* Ensure all other unused pins are disabled and muted. */
424 {0x10, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
425 {0x10, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
426 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
427 {0x13, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
428 {0x15, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
429 {0x15, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
430 /* Disable digital (SPDIF) pins */
431 {0x03, AC_VERB_SET_DIGI_CONVERT_1, 0},
432 {0x06, AC_VERB_SET_DIGI_CONVERT_1, 0},
434 /* Ensure Mic1 and Line1 pin widgets take input from the OUT1 sum
435 * bus when acting as outputs.
437 {0x0b, AC_VERB_SET_CONNECT_SEL, 0},
438 {0x0d, AC_VERB_SET_CONNECT_SEL, 0},
440 /* Start with output sum widgets muted and their output gains at min */
441 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
442 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
443 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
444 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
445 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
446 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
447 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
448 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
449 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
451 /* Unmute Line-out pin widget amp left and right
452 * (no equiv mixer ctrl)
454 {0x0f, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
455 /* Unmute mono pin widget amp output (no equiv mixer ctrl) */
456 {0x11, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
457 /* Unmute Mic1 and Line1 pin widget input buffers since they start as
458 * inputs. If the pin mode is changed by the user the pin mode control
459 * will take care of enabling the pin's input/output buffers as needed.
460 * Therefore there's no need to enable the input buffer at this
463 {0x12, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
464 {0x14, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
466 /* Mute capture amp left and right */
467 {0x04, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
468 /* Set ADC connection select to match default mixer setting - mic
471 {0x04, AC_VERB_SET_CONNECT_SEL, 0x00},
473 /* Do similar with the second ADC: mute capture input amp and
474 * set ADC connection to mic to match ALSA's default state.
476 {0x05, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
477 {0x05, AC_VERB_SET_CONNECT_SEL, 0x00},
479 /* Mute all inputs to mixer widget (even unconnected ones) */
480 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)}, /* mic1 pin */
481 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)}, /* mic2 pin */
482 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(2)}, /* line1 pin */
483 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(3)}, /* line2 pin */
484 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(4)}, /* CD pin */
485 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(5)}, /* Beep-gen pin */
486 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(6)}, /* Line-out pin */
487 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(7)}, /* HP-pin pin */
492 /* Initialisation sequence for Maxdata Favorit 100XS
493 * (adapted from Acer init verbs).
495 static const struct hda_verb alc260_favorit100_init_verbs[] = {
496 /* GPIO 0 enables the output jack.
497 * Turn this on and rely on the standard mute
498 * methods whenever the user wants to turn these outputs off.
500 {0x01, AC_VERB_SET_GPIO_MASK, 0x01},
501 {0x01, AC_VERB_SET_GPIO_DIRECTION, 0x01},
502 {0x01, AC_VERB_SET_GPIO_DATA, 0x01},
503 /* Line/Mic input jack is connected to Mic1 pin */
504 {0x12, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_VREF50},
505 /* Ensure all other unused pins are disabled and muted. */
506 {0x10, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
507 {0x10, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
508 {0x11, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
509 {0x11, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
510 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
511 {0x13, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
512 {0x14, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
513 {0x14, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
514 {0x15, AC_VERB_SET_PIN_WIDGET_CONTROL, 0},
515 {0x15, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
516 /* Disable digital (SPDIF) pins */
517 {0x03, AC_VERB_SET_DIGI_CONVERT_1, 0},
518 {0x06, AC_VERB_SET_DIGI_CONVERT_1, 0},
520 /* Ensure Mic1 and Line1 pin widgets take input from the OUT1 sum
521 * bus when acting as outputs.
523 {0x0b, AC_VERB_SET_CONNECT_SEL, 0},
524 {0x0d, AC_VERB_SET_CONNECT_SEL, 0},
526 /* Start with output sum widgets muted and their output gains at min */
527 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
528 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
529 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
530 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
531 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
532 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
533 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
534 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
535 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
537 /* Unmute Line-out pin widget amp left and right
538 * (no equiv mixer ctrl)
540 {0x0f, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
541 /* Unmute Mic1 and Line1 pin widget input buffers since they start as
542 * inputs. If the pin mode is changed by the user the pin mode control
543 * will take care of enabling the pin's input/output buffers as needed.
544 * Therefore there's no need to enable the input buffer at this
547 {0x12, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
549 /* Mute capture amp left and right */
550 {0x04, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
551 /* Set ADC connection select to match default mixer setting - mic
554 {0x04, AC_VERB_SET_CONNECT_SEL, 0x00},
556 /* Do similar with the second ADC: mute capture input amp and
557 * set ADC connection to mic to match ALSA's default state.
559 {0x05, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
560 {0x05, AC_VERB_SET_CONNECT_SEL, 0x00},
562 /* Mute all inputs to mixer widget (even unconnected ones) */
563 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)}, /* mic1 pin */
564 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)}, /* mic2 pin */
565 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(2)}, /* line1 pin */
566 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(3)}, /* line2 pin */
567 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(4)}, /* CD pin */
568 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(5)}, /* Beep-gen pin */
569 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(6)}, /* Line-out pin */
570 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(7)}, /* HP-pin pin */
575 static const struct hda_verb alc260_replacer_672v_verbs[] = {
576 {0x0f, AC_VERB_SET_EAPD_BTLENABLE, 0x02},
577 {0x1a, AC_VERB_SET_COEF_INDEX, 0x07},
578 {0x1a, AC_VERB_SET_PROC_COEF, 0x3050},
580 {0x01, AC_VERB_SET_GPIO_MASK, 0x01},
581 {0x01, AC_VERB_SET_GPIO_DIRECTION, 0x01},
582 {0x01, AC_VERB_SET_GPIO_DATA, 0x00},
584 {0x0f, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | ALC_HP_EVENT},
588 /* toggle speaker-output according to the hp-jack state */
589 static void alc260_replacer_672v_automute(struct hda_codec *codec)
591 unsigned int present;
593 /* speaker --> GPIO Data 0, hp or spdif --> GPIO data 1 */
594 present = snd_hda_jack_detect(codec, 0x0f);
596 snd_hda_codec_write_cache(codec, 0x01, 0,
597 AC_VERB_SET_GPIO_DATA, 1);
598 snd_hda_codec_write_cache(codec, 0x0f, 0,
599 AC_VERB_SET_PIN_WIDGET_CONTROL,
602 snd_hda_codec_write_cache(codec, 0x01, 0,
603 AC_VERB_SET_GPIO_DATA, 0);
604 snd_hda_codec_write_cache(codec, 0x0f, 0,
605 AC_VERB_SET_PIN_WIDGET_CONTROL,
610 static void alc260_replacer_672v_unsol_event(struct hda_codec *codec,
613 if ((res >> 26) == ALC_HP_EVENT)
614 alc260_replacer_672v_automute(codec);
617 static const struct hda_verb alc260_hp_dc7600_verbs[] = {
618 {0x05, AC_VERB_SET_CONNECT_SEL, 0x01},
619 {0x15, AC_VERB_SET_CONNECT_SEL, 0x01},
620 {0x0f, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
621 {0x10, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_HP},
622 {0x11, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
623 {0x15, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
624 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_VREF80},
625 {0x10, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | ALC_HP_EVENT},
626 {0x11, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | ALC_HP_EVENT},
627 {0x15, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | ALC_HP_EVENT},
631 /* Test configuration for debugging, modelled after the ALC880 test
634 #ifdef CONFIG_SND_DEBUG
635 static const hda_nid_t alc260_test_dac_nids[1] = {
638 static const hda_nid_t alc260_test_adc_nids[2] = {
641 /* For testing the ALC260, each input MUX needs its own definition since
642 * the signal assignments are different. This assumes that the first ADC
645 static const struct hda_input_mux alc260_test_capture_sources[2] = {
651 { "LINE1 pin", 0x2 },
652 { "LINE2 pin", 0x3 },
654 { "LINE-OUT pin", 0x5 },
655 { "HP-OUT pin", 0x6 },
663 { "LINE1 pin", 0x2 },
664 { "LINE2 pin", 0x3 },
667 { "LINE-OUT pin", 0x6 },
668 { "HP-OUT pin", 0x7 },
672 static const struct snd_kcontrol_new alc260_test_mixer[] = {
673 /* Output driver widgets */
674 HDA_CODEC_VOLUME_MONO("Mono Playback Volume", 0x0a, 1, 0x0, HDA_OUTPUT),
675 HDA_BIND_MUTE_MONO("Mono Playback Switch", 0x0a, 1, 2, HDA_INPUT),
676 HDA_CODEC_VOLUME("LOUT2 Playback Volume", 0x09, 0x0, HDA_OUTPUT),
677 HDA_BIND_MUTE("LOUT2 Playback Switch", 0x09, 2, HDA_INPUT),
678 HDA_CODEC_VOLUME("LOUT1 Playback Volume", 0x08, 0x0, HDA_OUTPUT),
679 HDA_BIND_MUTE("LOUT1 Playback Switch", 0x08, 2, HDA_INPUT),
681 /* Modes for retasking pin widgets
682 * Note: the ALC260 doesn't seem to act on requests to enable mic
683 * bias from NIDs 0x0f and 0x10. The ALC260 datasheet doesn't
684 * mention this restriction. At this stage it's not clear whether
685 * this behaviour is intentional or is a hardware bug in chip
686 * revisions available at least up until early 2006. Therefore for
687 * now allow the "HP-OUT" and "LINE-OUT" Mode controls to span all
688 * choices, but if it turns out that the lack of mic bias for these
689 * NIDs is intentional we could change their modes from
690 * ALC_PIN_DIR_INOUT to ALC_PIN_DIR_INOUT_NOMICBIAS.
692 ALC_PIN_MODE("HP-OUT pin mode", 0x10, ALC_PIN_DIR_INOUT),
693 ALC_PIN_MODE("LINE-OUT pin mode", 0x0f, ALC_PIN_DIR_INOUT),
694 ALC_PIN_MODE("LINE2 pin mode", 0x15, ALC_PIN_DIR_INOUT),
695 ALC_PIN_MODE("LINE1 pin mode", 0x14, ALC_PIN_DIR_INOUT),
696 ALC_PIN_MODE("MIC2 pin mode", 0x13, ALC_PIN_DIR_INOUT),
697 ALC_PIN_MODE("MIC1 pin mode", 0x12, ALC_PIN_DIR_INOUT),
699 /* Loopback mixer controls */
700 HDA_CODEC_VOLUME("MIC1 Playback Volume", 0x07, 0x00, HDA_INPUT),
701 HDA_CODEC_MUTE("MIC1 Playback Switch", 0x07, 0x00, HDA_INPUT),
702 HDA_CODEC_VOLUME("MIC2 Playback Volume", 0x07, 0x01, HDA_INPUT),
703 HDA_CODEC_MUTE("MIC2 Playback Switch", 0x07, 0x01, HDA_INPUT),
704 HDA_CODEC_VOLUME("LINE1 Playback Volume", 0x07, 0x02, HDA_INPUT),
705 HDA_CODEC_MUTE("LINE1 Playback Switch", 0x07, 0x02, HDA_INPUT),
706 HDA_CODEC_VOLUME("LINE2 Playback Volume", 0x07, 0x03, HDA_INPUT),
707 HDA_CODEC_MUTE("LINE2 Playback Switch", 0x07, 0x03, HDA_INPUT),
708 HDA_CODEC_VOLUME("CD Playback Volume", 0x07, 0x04, HDA_INPUT),
709 HDA_CODEC_MUTE("CD Playback Switch", 0x07, 0x04, HDA_INPUT),
710 HDA_CODEC_VOLUME("LINE-OUT loopback Playback Volume", 0x07, 0x06, HDA_INPUT),
711 HDA_CODEC_MUTE("LINE-OUT loopback Playback Switch", 0x07, 0x06, HDA_INPUT),
712 HDA_CODEC_VOLUME("HP-OUT loopback Playback Volume", 0x07, 0x7, HDA_INPUT),
713 HDA_CODEC_MUTE("HP-OUT loopback Playback Switch", 0x07, 0x7, HDA_INPUT),
715 /* Controls for GPIO pins, assuming they are configured as outputs */
716 ALC_GPIO_DATA_SWITCH("GPIO pin 0", 0x01, 0x01),
717 ALC_GPIO_DATA_SWITCH("GPIO pin 1", 0x01, 0x02),
718 ALC_GPIO_DATA_SWITCH("GPIO pin 2", 0x01, 0x04),
719 ALC_GPIO_DATA_SWITCH("GPIO pin 3", 0x01, 0x08),
721 /* Switches to allow the digital IO pins to be enabled. The datasheet
722 * is ambigious as to which NID is which; testing on laptops which
723 * make this output available should provide clarification.
725 ALC_SPDIF_CTRL_SWITCH("SPDIF Playback Switch", 0x03, 0x01),
726 ALC_SPDIF_CTRL_SWITCH("SPDIF Capture Switch", 0x06, 0x01),
728 /* A switch allowing EAPD to be enabled. Some laptops seem to use
729 * this output to turn on an external amplifier.
731 ALC_EAPD_CTRL_SWITCH("LINE-OUT EAPD Enable Switch", 0x0f, 0x02),
732 ALC_EAPD_CTRL_SWITCH("HP-OUT EAPD Enable Switch", 0x10, 0x02),
736 static const struct hda_verb alc260_test_init_verbs[] = {
737 /* Enable all GPIOs as outputs with an initial value of 0 */
738 {0x01, AC_VERB_SET_GPIO_DIRECTION, 0x0f},
739 {0x01, AC_VERB_SET_GPIO_DATA, 0x00},
740 {0x01, AC_VERB_SET_GPIO_MASK, 0x0f},
742 /* Enable retasking pins as output, initially without power amp */
743 {0x10, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
744 {0x0f, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
745 {0x15, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
746 {0x14, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
747 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
748 {0x12, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
750 /* Disable digital (SPDIF) pins initially, but users can enable
751 * them via a mixer switch. In the case of SPDIF-out, this initverb
752 * payload also sets the generation to 0, output to be in "consumer"
753 * PCM format, copyright asserted, no pre-emphasis and no validity
756 {0x03, AC_VERB_SET_DIGI_CONVERT_1, 0},
757 {0x06, AC_VERB_SET_DIGI_CONVERT_1, 0},
759 /* Ensure mic1, mic2, line1 and line2 pin widgets take input from the
760 * OUT1 sum bus when acting as an output.
762 {0x0b, AC_VERB_SET_CONNECT_SEL, 0},
763 {0x0c, AC_VERB_SET_CONNECT_SEL, 0},
764 {0x0d, AC_VERB_SET_CONNECT_SEL, 0},
765 {0x0e, AC_VERB_SET_CONNECT_SEL, 0},
767 /* Start with output sum widgets muted and their output gains at min */
768 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
769 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
770 {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
771 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
772 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
773 {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
774 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
775 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
776 {0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_ZERO},
778 /* Unmute retasking pin widget output buffers since the default
779 * state appears to be output. As the pin mode is changed by the
780 * user the pin mode control will take care of enabling the pin's
781 * input/output buffers as needed.
783 {0x10, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
784 {0x0f, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
785 {0x15, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
786 {0x14, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
787 {0x13, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
788 {0x12, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
789 /* Also unmute the mono-out pin widget */
790 {0x11, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE},
792 /* Mute capture amp left and right */
793 {0x04, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
794 /* Set ADC connection select to match default mixer setting (mic1
797 {0x04, AC_VERB_SET_CONNECT_SEL, 0x00},
799 /* Do the same for the second ADC: mute capture input amp and
800 * set ADC connection to mic1 pin
802 {0x05, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
803 {0x05, AC_VERB_SET_CONNECT_SEL, 0x00},
805 /* Mute all inputs to mixer widget (even unconnected ones) */
806 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)}, /* mic1 pin */
807 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)}, /* mic2 pin */
808 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(2)}, /* line1 pin */
809 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(3)}, /* line2 pin */
810 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(4)}, /* CD pin */
811 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(5)}, /* Beep-gen pin */
812 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(6)}, /* Line-out pin */
813 {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(7)}, /* HP-pin pin */
820 * ALC260 configurations
822 static const char * const alc260_models[ALC260_MODEL_LAST] = {
823 [ALC260_BASIC] = "basic",
824 [ALC260_FUJITSU_S702X] = "fujitsu",
825 [ALC260_ACER] = "acer",
826 [ALC260_REPLACER_672V] = "replacer",
827 [ALC260_FAVORIT100] = "favorit100",
828 #ifdef CONFIG_SND_DEBUG
829 [ALC260_TEST] = "test",
831 [ALC260_AUTO] = "auto",
834 static const struct snd_pci_quirk alc260_cfg_tbl[] = {
835 SND_PCI_QUIRK(0x1025, 0x007b, "Acer C20x", ALC260_ACER),
836 SND_PCI_QUIRK(0x1025, 0x008f, "Acer", ALC260_ACER),
837 SND_PCI_QUIRK(0x1509, 0x4540, "Favorit 100XS", ALC260_FAVORIT100),
838 SND_PCI_QUIRK(0x104d, 0x81bb, "Sony VAIO", ALC260_BASIC),
839 SND_PCI_QUIRK(0x104d, 0x81cc, "Sony VAIO", ALC260_BASIC),
840 SND_PCI_QUIRK(0x104d, 0x81cd, "Sony VAIO", ALC260_BASIC),
841 SND_PCI_QUIRK(0x10cf, 0x1326, "Fujitsu S702X", ALC260_FUJITSU_S702X),
842 SND_PCI_QUIRK(0x152d, 0x0729, "CTL U553W", ALC260_BASIC),
843 SND_PCI_QUIRK(0x161f, 0x2057, "Replacer 672V", ALC260_REPLACER_672V),
847 static const struct alc_config_preset alc260_presets[] = {
849 .mixers = { alc260_base_output_mixer,
850 alc260_input_mixer },
851 .init_verbs = { alc260_init_verbs },
852 .num_dacs = ARRAY_SIZE(alc260_dac_nids),
853 .dac_nids = alc260_dac_nids,
854 .num_adc_nids = ARRAY_SIZE(alc260_dual_adc_nids),
855 .adc_nids = alc260_dual_adc_nids,
856 .num_channel_mode = ARRAY_SIZE(alc260_modes),
857 .channel_mode = alc260_modes,
858 .input_mux = &alc260_capture_source,
860 [ALC260_FUJITSU_S702X] = {
861 .mixers = { alc260_fujitsu_mixer },
862 .init_verbs = { alc260_fujitsu_init_verbs },
863 .num_dacs = ARRAY_SIZE(alc260_dac_nids),
864 .dac_nids = alc260_dac_nids,
865 .num_adc_nids = ARRAY_SIZE(alc260_dual_adc_nids),
866 .adc_nids = alc260_dual_adc_nids,
867 .num_channel_mode = ARRAY_SIZE(alc260_modes),
868 .channel_mode = alc260_modes,
869 .num_mux_defs = ARRAY_SIZE(alc260_fujitsu_capture_sources),
870 .input_mux = alc260_fujitsu_capture_sources,
873 .mixers = { alc260_acer_mixer },
874 .init_verbs = { alc260_acer_init_verbs },
875 .num_dacs = ARRAY_SIZE(alc260_dac_nids),
876 .dac_nids = alc260_dac_nids,
877 .num_adc_nids = ARRAY_SIZE(alc260_dual_adc_nids),
878 .adc_nids = alc260_dual_adc_nids,
879 .num_channel_mode = ARRAY_SIZE(alc260_modes),
880 .channel_mode = alc260_modes,
881 .num_mux_defs = ARRAY_SIZE(alc260_acer_capture_sources),
882 .input_mux = alc260_acer_capture_sources,
884 [ALC260_FAVORIT100] = {
885 .mixers = { alc260_favorit100_mixer },
886 .init_verbs = { alc260_favorit100_init_verbs },
887 .num_dacs = ARRAY_SIZE(alc260_dac_nids),
888 .dac_nids = alc260_dac_nids,
889 .num_adc_nids = ARRAY_SIZE(alc260_dual_adc_nids),
890 .adc_nids = alc260_dual_adc_nids,
891 .num_channel_mode = ARRAY_SIZE(alc260_modes),
892 .channel_mode = alc260_modes,
893 .num_mux_defs = ARRAY_SIZE(alc260_favorit100_capture_sources),
894 .input_mux = alc260_favorit100_capture_sources,
896 [ALC260_REPLACER_672V] = {
897 .mixers = { alc260_replacer_672v_mixer },
898 .init_verbs = { alc260_init_verbs, alc260_replacer_672v_verbs },
899 .num_dacs = ARRAY_SIZE(alc260_dac_nids),
900 .dac_nids = alc260_dac_nids,
901 .num_adc_nids = ARRAY_SIZE(alc260_adc_nids),
902 .adc_nids = alc260_adc_nids,
903 .dig_out_nid = ALC260_DIGOUT_NID,
904 .num_channel_mode = ARRAY_SIZE(alc260_modes),
905 .channel_mode = alc260_modes,
906 .input_mux = &alc260_capture_source,
907 .unsol_event = alc260_replacer_672v_unsol_event,
908 .init_hook = alc260_replacer_672v_automute,
910 #ifdef CONFIG_SND_DEBUG
912 .mixers = { alc260_test_mixer },
913 .init_verbs = { alc260_test_init_verbs },
914 .num_dacs = ARRAY_SIZE(alc260_test_dac_nids),
915 .dac_nids = alc260_test_dac_nids,
916 .num_adc_nids = ARRAY_SIZE(alc260_test_adc_nids),
917 .adc_nids = alc260_test_adc_nids,
918 .num_channel_mode = ARRAY_SIZE(alc260_modes),
919 .channel_mode = alc260_modes,
920 .num_mux_defs = ARRAY_SIZE(alc260_test_capture_sources),
921 .input_mux = alc260_test_capture_sources,