wm8731.c (97884b7a7867fa9926a0711035cefaa4d0aafda4) | wm8731.c (d921184e82e828e9c0bc3958f838decaaa9191a8) |
---|---|
1/* 2 * wm8731.c -- WM8731 ALSA SoC Audio driver 3 * 4 * Copyright 2005 Openedhand Ltd. 5 * 6 * Author: Richard Purdie <richard@openedhand.com> 7 * 8 * Based on wm8753.c by Liam Girdwood --- 60 unchanged lines hidden (view full) --- 69static const struct soc_enum wm8731_enum[] = { 70 SOC_ENUM_SINGLE(WM8731_APANA, 2, 2, wm8731_input_select), 71 SOC_ENUM_SINGLE(WM8731_APDIGI, 1, 4, wm8731_deemph), 72}; 73 74static const DECLARE_TLV_DB_SCALE(in_tlv, -3450, 150, 0); 75static const DECLARE_TLV_DB_SCALE(sidetone_tlv, -1500, 300, 0); 76static const DECLARE_TLV_DB_SCALE(out_tlv, -12100, 100, 1); | 1/* 2 * wm8731.c -- WM8731 ALSA SoC Audio driver 3 * 4 * Copyright 2005 Openedhand Ltd. 5 * 6 * Author: Richard Purdie <richard@openedhand.com> 7 * 8 * Based on wm8753.c by Liam Girdwood --- 60 unchanged lines hidden (view full) --- 69static const struct soc_enum wm8731_enum[] = { 70 SOC_ENUM_SINGLE(WM8731_APANA, 2, 2, wm8731_input_select), 71 SOC_ENUM_SINGLE(WM8731_APDIGI, 1, 4, wm8731_deemph), 72}; 73 74static const DECLARE_TLV_DB_SCALE(in_tlv, -3450, 150, 0); 75static const DECLARE_TLV_DB_SCALE(sidetone_tlv, -1500, 300, 0); 76static const DECLARE_TLV_DB_SCALE(out_tlv, -12100, 100, 1); |
77static const DECLARE_TLV_DB_SCALE(mic_tlv, 0, 2000, 0); |
|
77 78static const struct snd_kcontrol_new wm8731_snd_controls[] = { 79 80SOC_DOUBLE_R_TLV("Master Playback Volume", WM8731_LOUT1V, WM8731_ROUT1V, 81 0, 127, 0, out_tlv), 82SOC_DOUBLE_R("Master Playback ZC Switch", WM8731_LOUT1V, WM8731_ROUT1V, 83 7, 1, 0), 84 85SOC_DOUBLE_R_TLV("Capture Volume", WM8731_LINVOL, WM8731_RINVOL, 0, 31, 0, 86 in_tlv), 87SOC_DOUBLE_R("Line Capture Switch", WM8731_LINVOL, WM8731_RINVOL, 7, 1, 1), 88 | 78 79static const struct snd_kcontrol_new wm8731_snd_controls[] = { 80 81SOC_DOUBLE_R_TLV("Master Playback Volume", WM8731_LOUT1V, WM8731_ROUT1V, 82 0, 127, 0, out_tlv), 83SOC_DOUBLE_R("Master Playback ZC Switch", WM8731_LOUT1V, WM8731_ROUT1V, 84 7, 1, 0), 85 86SOC_DOUBLE_R_TLV("Capture Volume", WM8731_LINVOL, WM8731_RINVOL, 0, 31, 0, 87 in_tlv), 88SOC_DOUBLE_R("Line Capture Switch", WM8731_LINVOL, WM8731_RINVOL, 7, 1, 1), 89 |
89SOC_SINGLE("Mic Boost (+20dB)", WM8731_APANA, 0, 1, 0), | 90SOC_SINGLE_TLV("Mic Boost Volume", WM8731_APANA, 0, 1, 0, mic_tlv), |
90SOC_SINGLE("Mic Capture Switch", WM8731_APANA, 1, 1, 1), 91 92SOC_SINGLE_TLV("Sidetone Playback Volume", WM8731_APANA, 6, 3, 1, 93 sidetone_tlv), 94 95SOC_SINGLE("ADC High Pass Filter Switch", WM8731_APDIGI, 0, 1, 1), 96SOC_SINGLE("Store DC Offset Switch", WM8731_APDIGI, 4, 1, 0), 97 --- 591 unchanged lines hidden --- | 91SOC_SINGLE("Mic Capture Switch", WM8731_APANA, 1, 1, 1), 92 93SOC_SINGLE_TLV("Sidetone Playback Volume", WM8731_APANA, 6, 3, 1, 94 sidetone_tlv), 95 96SOC_SINGLE("ADC High Pass Filter Switch", WM8731_APDIGI, 0, 1, 1), 97SOC_SINGLE("Store DC Offset Switch", WM8731_APDIGI, 4, 1, 0), 98 --- 591 unchanged lines hidden --- |