aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/ice1712/phase.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/ice1712/phase.c')
-rw-r--r--sound/pci/ice1712/phase.c25
1 files changed, 12 insertions, 13 deletions
diff --git a/sound/pci/ice1712/phase.c b/sound/pci/ice1712/phase.c
index de29be8c9657..0011e04f36a2 100644
--- a/sound/pci/ice1712/phase.c
+++ b/sound/pci/ice1712/phase.c
@@ -42,7 +42,6 @@
42 * Digital receiver: CS8414-CS (supported in this release) 42 * Digital receiver: CS8414-CS (supported in this release)
43 */ 43 */
44 44
45#include <asm/io.h>
46#include <linux/delay.h> 45#include <linux/delay.h>
47#include <linux/interrupt.h> 46#include <linux/interrupt.h>
48#include <linux/init.h> 47#include <linux/init.h>
@@ -103,13 +102,13 @@ static const unsigned char wm_vol[256] = {
103#define WM_VOL_MAX (sizeof(wm_vol) - 1) 102#define WM_VOL_MAX (sizeof(wm_vol) - 1)
104#define WM_VOL_MUTE 0x8000 103#define WM_VOL_MUTE 0x8000
105 104
106static struct snd_akm4xxx akm_phase22 __devinitdata = { 105static struct snd_akm4xxx akm_phase22 = {
107 .type = SND_AK4524, 106 .type = SND_AK4524,
108 .num_dacs = 2, 107 .num_dacs = 2,
109 .num_adcs = 2, 108 .num_adcs = 2,
110}; 109};
111 110
112static struct snd_ak4xxx_private akm_phase22_priv __devinitdata = { 111static struct snd_ak4xxx_private akm_phase22_priv = {
113 .caddr = 2, 112 .caddr = 2,
114 .cif = 1, 113 .cif = 1,
115 .data_mask = 1 << 4, 114 .data_mask = 1 << 4,
@@ -121,7 +120,7 @@ static struct snd_ak4xxx_private akm_phase22_priv __devinitdata = {
121 .mask_flags = 0, 120 .mask_flags = 0,
122}; 121};
123 122
124static int __devinit phase22_init(struct snd_ice1712 *ice) 123static int phase22_init(struct snd_ice1712 *ice)
125{ 124{
126 struct snd_akm4xxx *ak; 125 struct snd_akm4xxx *ak;
127 int err; 126 int err;
@@ -158,7 +157,7 @@ static int __devinit phase22_init(struct snd_ice1712 *ice)
158 return 0; 157 return 0;
159} 158}
160 159
161static int __devinit phase22_add_controls(struct snd_ice1712 *ice) 160static int phase22_add_controls(struct snd_ice1712 *ice)
162{ 161{
163 int err = 0; 162 int err = 0;
164 163
@@ -172,7 +171,7 @@ static int __devinit phase22_add_controls(struct snd_ice1712 *ice)
172 return 0; 171 return 0;
173} 172}
174 173
175static unsigned char phase22_eeprom[] __devinitdata = { 174static unsigned char phase22_eeprom[] = {
176 [ICE_EEP2_SYSCONF] = 0x28, /* clock 512, mpu 401, 175 [ICE_EEP2_SYSCONF] = 0x28, /* clock 512, mpu 401,
177 spdif-in/1xADC, 1xDACs */ 176 spdif-in/1xADC, 1xDACs */
178 [ICE_EEP2_ACLINK] = 0x80, /* I2S */ 177 [ICE_EEP2_ACLINK] = 0x80, /* I2S */
@@ -189,7 +188,7 @@ static unsigned char phase22_eeprom[] __devinitdata = {
189 [ICE_EEP2_GPIO_STATE2] = 0x00, 188 [ICE_EEP2_GPIO_STATE2] = 0x00,
190}; 189};
191 190
192static unsigned char phase28_eeprom[] __devinitdata = { 191static unsigned char phase28_eeprom[] = {
193 [ICE_EEP2_SYSCONF] = 0x2b, /* clock 512, mpu401, 192 [ICE_EEP2_SYSCONF] = 0x2b, /* clock 512, mpu401,
194 spdif-in/1xADC, 4xDACs */ 193 spdif-in/1xADC, 4xDACs */
195 [ICE_EEP2_ACLINK] = 0x80, /* I2S */ 194 [ICE_EEP2_ACLINK] = 0x80, /* I2S */
@@ -379,7 +378,7 @@ static int wm_master_vol_put(struct snd_kcontrol *kcontrol,
379 return change; 378 return change;
380} 379}
381 380
382static int __devinit phase28_init(struct snd_ice1712 *ice) 381static int phase28_init(struct snd_ice1712 *ice)
383{ 382{
384 static const unsigned short wm_inits_phase28[] = { 383 static const unsigned short wm_inits_phase28[] = {
385 /* These come first to reduce init pop noise */ 384 /* These come first to reduce init pop noise */
@@ -722,7 +721,7 @@ static int phase28_deemp_put(struct snd_kcontrol *kcontrol,
722static int phase28_oversampling_info(struct snd_kcontrol *k, 721static int phase28_oversampling_info(struct snd_kcontrol *k,
723 struct snd_ctl_elem_info *uinfo) 722 struct snd_ctl_elem_info *uinfo)
724{ 723{
725 static char *texts[2] = { "128x", "64x" }; 724 static const char * const texts[2] = { "128x", "64x" };
726 725
727 uinfo->type = SNDRV_CTL_ELEM_TYPE_ENUMERATED; 726 uinfo->type = SNDRV_CTL_ELEM_TYPE_ENUMERATED;
728 uinfo->count = 1; 727 uinfo->count = 1;
@@ -770,7 +769,7 @@ static int phase28_oversampling_put(struct snd_kcontrol *kcontrol,
770static const DECLARE_TLV_DB_SCALE(db_scale_wm_dac, -12700, 100, 1); 769static const DECLARE_TLV_DB_SCALE(db_scale_wm_dac, -12700, 100, 1);
771static const DECLARE_TLV_DB_SCALE(db_scale_wm_pcm, -6400, 50, 1); 770static const DECLARE_TLV_DB_SCALE(db_scale_wm_pcm, -6400, 50, 1);
772 771
773static struct snd_kcontrol_new phase28_dac_controls[] __devinitdata = { 772static struct snd_kcontrol_new phase28_dac_controls[] = {
774 { 773 {
775 .iface = SNDRV_CTL_ELEM_IFACE_MIXER, 774 .iface = SNDRV_CTL_ELEM_IFACE_MIXER,
776 .name = "Master Playback Switch", 775 .name = "Master Playback Switch",
@@ -885,7 +884,7 @@ static struct snd_kcontrol_new phase28_dac_controls[] __devinitdata = {
885 } 884 }
886}; 885};
887 886
888static struct snd_kcontrol_new wm_controls[] __devinitdata = { 887static struct snd_kcontrol_new wm_controls[] = {
889 { 888 {
890 .iface = SNDRV_CTL_ELEM_IFACE_MIXER, 889 .iface = SNDRV_CTL_ELEM_IFACE_MIXER,
891 .name = "PCM Playback Switch", 890 .name = "PCM Playback Switch",
@@ -919,7 +918,7 @@ static struct snd_kcontrol_new wm_controls[] __devinitdata = {
919 } 918 }
920}; 919};
921 920
922static int __devinit phase28_add_controls(struct snd_ice1712 *ice) 921static int phase28_add_controls(struct snd_ice1712 *ice)
923{ 922{
924 unsigned int i, counts; 923 unsigned int i, counts;
925 int err; 924 int err;
@@ -943,7 +942,7 @@ static int __devinit phase28_add_controls(struct snd_ice1712 *ice)
943 return 0; 942 return 0;
944} 943}
945 944
946struct snd_ice1712_card_info snd_vt1724_phase_cards[] __devinitdata = { 945struct snd_ice1712_card_info snd_vt1724_phase_cards[] = {
947 { 946 {
948 .subvendor = VT1724_SUBDEVICE_PHASE22, 947 .subvendor = VT1724_SUBDEVICE_PHASE22,
949 .name = "Terratec PHASE 22", 948 .name = "Terratec PHASE 22",