diff options
author | Takashi Iwai <tiwai@suse.de> | 2005-11-17 08:30:42 -0500 |
---|---|---|
committer | Jaroslav Kysela <perex@suse.cz> | 2006-01-03 06:18:21 -0500 |
commit | ba2375a45c528fd902676ea01014ea0f8931464b (patch) | |
tree | e38833035449d0d65afb3cfc1104b243ce88454c /sound/isa/cs423x/cs4236_lib.c | |
parent | c8ff6647bb8a1865608b2d0c8565ca0ac47fb9b7 (diff) |
[ALSA] Remove xxx_t typedefs: ISA CS423x
Modules: CS4231 driver,CS4236+ driver
Remove xxx_t typedefs from the ISA CS423x drivers.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/isa/cs423x/cs4236_lib.c')
-rw-r--r-- | sound/isa/cs423x/cs4236_lib.c | 106 |
1 files changed, 53 insertions, 53 deletions
diff --git a/sound/isa/cs423x/cs4236_lib.c b/sound/isa/cs423x/cs4236_lib.c index 1adb88d5f8f4..e36981d64ec5 100644 --- a/sound/isa/cs423x/cs4236_lib.c +++ b/sound/isa/cs423x/cs4236_lib.c | |||
@@ -122,13 +122,13 @@ static unsigned char snd_cs4236_ext_map[18] = { | |||
122 | * | 122 | * |
123 | */ | 123 | */ |
124 | 124 | ||
125 | static void snd_cs4236_ctrl_out(cs4231_t *chip, unsigned char reg, unsigned char val) | 125 | static void snd_cs4236_ctrl_out(struct snd_cs4231 *chip, unsigned char reg, unsigned char val) |
126 | { | 126 | { |
127 | outb(reg, chip->cport + 3); | 127 | outb(reg, chip->cport + 3); |
128 | outb(chip->cimage[reg] = val, chip->cport + 4); | 128 | outb(chip->cimage[reg] = val, chip->cport + 4); |
129 | } | 129 | } |
130 | 130 | ||
131 | static unsigned char snd_cs4236_ctrl_in(cs4231_t *chip, unsigned char reg) | 131 | static unsigned char snd_cs4236_ctrl_in(struct snd_cs4231 *chip, unsigned char reg) |
132 | { | 132 | { |
133 | outb(reg, chip->cport + 3); | 133 | outb(reg, chip->cport + 3); |
134 | return inb(chip->cport + 4); | 134 | return inb(chip->cport + 4); |
@@ -140,7 +140,7 @@ static unsigned char snd_cs4236_ctrl_in(cs4231_t *chip, unsigned char reg) | |||
140 | 140 | ||
141 | #define CLOCKS 8 | 141 | #define CLOCKS 8 |
142 | 142 | ||
143 | static ratnum_t clocks[CLOCKS] = { | 143 | static struct snd_ratnum clocks[CLOCKS] = { |
144 | { .num = 16934400, .den_min = 353, .den_max = 353, .den_step = 1 }, | 144 | { .num = 16934400, .den_min = 353, .den_max = 353, .den_step = 1 }, |
145 | { .num = 16934400, .den_min = 529, .den_max = 529, .den_step = 1 }, | 145 | { .num = 16934400, .den_min = 529, .den_max = 529, .den_step = 1 }, |
146 | { .num = 16934400, .den_min = 617, .den_max = 617, .den_step = 1 }, | 146 | { .num = 16934400, .den_min = 617, .den_max = 617, .den_step = 1 }, |
@@ -151,12 +151,12 @@ static ratnum_t clocks[CLOCKS] = { | |||
151 | { .num = 16934400/16, .den_min = 21, .den_max = 192, .den_step = 1 } | 151 | { .num = 16934400/16, .den_min = 21, .den_max = 192, .den_step = 1 } |
152 | }; | 152 | }; |
153 | 153 | ||
154 | static snd_pcm_hw_constraint_ratnums_t hw_constraints_clocks = { | 154 | static struct snd_pcm_hw_constraint_ratnums hw_constraints_clocks = { |
155 | .nrats = CLOCKS, | 155 | .nrats = CLOCKS, |
156 | .rats = clocks, | 156 | .rats = clocks, |
157 | }; | 157 | }; |
158 | 158 | ||
159 | static int snd_cs4236_xrate(snd_pcm_runtime_t *runtime) | 159 | static int snd_cs4236_xrate(struct snd_pcm_runtime *runtime) |
160 | { | 160 | { |
161 | return snd_pcm_hw_constraint_ratnums(runtime, 0, SNDRV_PCM_HW_PARAM_RATE, | 161 | return snd_pcm_hw_constraint_ratnums(runtime, 0, SNDRV_PCM_HW_PARAM_RATE, |
162 | &hw_constraints_clocks); | 162 | &hw_constraints_clocks); |
@@ -181,7 +181,7 @@ static unsigned char divisor_to_rate_register(unsigned int divisor) | |||
181 | } | 181 | } |
182 | } | 182 | } |
183 | 183 | ||
184 | static void snd_cs4236_playback_format(cs4231_t *chip, snd_pcm_hw_params_t *params, unsigned char pdfr) | 184 | static void snd_cs4236_playback_format(struct snd_cs4231 *chip, struct snd_pcm_hw_params *params, unsigned char pdfr) |
185 | { | 185 | { |
186 | unsigned long flags; | 186 | unsigned long flags; |
187 | unsigned char rate = divisor_to_rate_register(params->rate_den); | 187 | unsigned char rate = divisor_to_rate_register(params->rate_den); |
@@ -195,7 +195,7 @@ static void snd_cs4236_playback_format(cs4231_t *chip, snd_pcm_hw_params_t *para | |||
195 | spin_unlock_irqrestore(&chip->reg_lock, flags); | 195 | spin_unlock_irqrestore(&chip->reg_lock, flags); |
196 | } | 196 | } |
197 | 197 | ||
198 | static void snd_cs4236_capture_format(cs4231_t *chip, snd_pcm_hw_params_t *params, unsigned char cdfr) | 198 | static void snd_cs4236_capture_format(struct snd_cs4231 *chip, struct snd_pcm_hw_params *params, unsigned char cdfr) |
199 | { | 199 | { |
200 | unsigned long flags; | 200 | unsigned long flags; |
201 | unsigned char rate = divisor_to_rate_register(params->rate_den); | 201 | unsigned char rate = divisor_to_rate_register(params->rate_den); |
@@ -211,7 +211,7 @@ static void snd_cs4236_capture_format(cs4231_t *chip, snd_pcm_hw_params_t *param | |||
211 | 211 | ||
212 | #ifdef CONFIG_PM | 212 | #ifdef CONFIG_PM |
213 | 213 | ||
214 | static void snd_cs4236_suspend(cs4231_t *chip) | 214 | static void snd_cs4236_suspend(struct snd_cs4231 *chip) |
215 | { | 215 | { |
216 | int reg; | 216 | int reg; |
217 | unsigned long flags; | 217 | unsigned long flags; |
@@ -226,7 +226,7 @@ static void snd_cs4236_suspend(cs4231_t *chip) | |||
226 | spin_unlock_irqrestore(&chip->reg_lock, flags); | 226 | spin_unlock_irqrestore(&chip->reg_lock, flags); |
227 | } | 227 | } |
228 | 228 | ||
229 | static void snd_cs4236_resume(cs4231_t *chip) | 229 | static void snd_cs4236_resume(struct snd_cs4231 *chip) |
230 | { | 230 | { |
231 | int reg; | 231 | int reg; |
232 | unsigned long flags; | 232 | unsigned long flags; |
@@ -261,15 +261,15 @@ static void snd_cs4236_resume(cs4231_t *chip) | |||
261 | 261 | ||
262 | #endif /* CONFIG_PM */ | 262 | #endif /* CONFIG_PM */ |
263 | 263 | ||
264 | int snd_cs4236_create(snd_card_t * card, | 264 | int snd_cs4236_create(struct snd_card *card, |
265 | unsigned long port, | 265 | unsigned long port, |
266 | unsigned long cport, | 266 | unsigned long cport, |
267 | int irq, int dma1, int dma2, | 267 | int irq, int dma1, int dma2, |
268 | unsigned short hardware, | 268 | unsigned short hardware, |
269 | unsigned short hwshare, | 269 | unsigned short hwshare, |
270 | cs4231_t ** rchip) | 270 | struct snd_cs4231 ** rchip) |
271 | { | 271 | { |
272 | cs4231_t *chip; | 272 | struct snd_cs4231 *chip; |
273 | unsigned char ver1, ver2; | 273 | unsigned char ver1, ver2; |
274 | unsigned int reg; | 274 | unsigned int reg; |
275 | int err; | 275 | int err; |
@@ -352,9 +352,9 @@ int snd_cs4236_create(snd_card_t * card, | |||
352 | return 0; | 352 | return 0; |
353 | } | 353 | } |
354 | 354 | ||
355 | int snd_cs4236_pcm(cs4231_t *chip, int device, snd_pcm_t **rpcm) | 355 | int snd_cs4236_pcm(struct snd_cs4231 *chip, int device, struct snd_pcm **rpcm) |
356 | { | 356 | { |
357 | snd_pcm_t *pcm; | 357 | struct snd_pcm *pcm; |
358 | int err; | 358 | int err; |
359 | 359 | ||
360 | if ((err = snd_cs4231_pcm(chip, device, &pcm)) < 0) | 360 | if ((err = snd_cs4231_pcm(chip, device, &pcm)) < 0) |
@@ -375,7 +375,7 @@ int snd_cs4236_pcm(cs4231_t *chip, int device, snd_pcm_t **rpcm) | |||
375 | .get = snd_cs4236_get_single, .put = snd_cs4236_put_single, \ | 375 | .get = snd_cs4236_get_single, .put = snd_cs4236_put_single, \ |
376 | .private_value = reg | (shift << 8) | (mask << 16) | (invert << 24) } | 376 | .private_value = reg | (shift << 8) | (mask << 16) | (invert << 24) } |
377 | 377 | ||
378 | static int snd_cs4236_info_single(snd_kcontrol_t *kcontrol, snd_ctl_elem_info_t * uinfo) | 378 | static int snd_cs4236_info_single(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo) |
379 | { | 379 | { |
380 | int mask = (kcontrol->private_value >> 16) & 0xff; | 380 | int mask = (kcontrol->private_value >> 16) & 0xff; |
381 | 381 | ||
@@ -386,9 +386,9 @@ static int snd_cs4236_info_single(snd_kcontrol_t *kcontrol, snd_ctl_elem_info_t | |||
386 | return 0; | 386 | return 0; |
387 | } | 387 | } |
388 | 388 | ||
389 | static int snd_cs4236_get_single(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 389 | static int snd_cs4236_get_single(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
390 | { | 390 | { |
391 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 391 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
392 | unsigned long flags; | 392 | unsigned long flags; |
393 | int reg = kcontrol->private_value & 0xff; | 393 | int reg = kcontrol->private_value & 0xff; |
394 | int shift = (kcontrol->private_value >> 8) & 0xff; | 394 | int shift = (kcontrol->private_value >> 8) & 0xff; |
@@ -403,9 +403,9 @@ static int snd_cs4236_get_single(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t | |||
403 | return 0; | 403 | return 0; |
404 | } | 404 | } |
405 | 405 | ||
406 | static int snd_cs4236_put_single(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 406 | static int snd_cs4236_put_single(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
407 | { | 407 | { |
408 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 408 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
409 | unsigned long flags; | 409 | unsigned long flags; |
410 | int reg = kcontrol->private_value & 0xff; | 410 | int reg = kcontrol->private_value & 0xff; |
411 | int shift = (kcontrol->private_value >> 8) & 0xff; | 411 | int shift = (kcontrol->private_value >> 8) & 0xff; |
@@ -432,9 +432,9 @@ static int snd_cs4236_put_single(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t | |||
432 | .get = snd_cs4236_get_singlec, .put = snd_cs4236_put_singlec, \ | 432 | .get = snd_cs4236_get_singlec, .put = snd_cs4236_put_singlec, \ |
433 | .private_value = reg | (shift << 8) | (mask << 16) | (invert << 24) } | 433 | .private_value = reg | (shift << 8) | (mask << 16) | (invert << 24) } |
434 | 434 | ||
435 | static int snd_cs4236_get_singlec(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 435 | static int snd_cs4236_get_singlec(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
436 | { | 436 | { |
437 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 437 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
438 | unsigned long flags; | 438 | unsigned long flags; |
439 | int reg = kcontrol->private_value & 0xff; | 439 | int reg = kcontrol->private_value & 0xff; |
440 | int shift = (kcontrol->private_value >> 8) & 0xff; | 440 | int shift = (kcontrol->private_value >> 8) & 0xff; |
@@ -449,9 +449,9 @@ static int snd_cs4236_get_singlec(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_ | |||
449 | return 0; | 449 | return 0; |
450 | } | 450 | } |
451 | 451 | ||
452 | static int snd_cs4236_put_singlec(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 452 | static int snd_cs4236_put_singlec(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
453 | { | 453 | { |
454 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 454 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
455 | unsigned long flags; | 455 | unsigned long flags; |
456 | int reg = kcontrol->private_value & 0xff; | 456 | int reg = kcontrol->private_value & 0xff; |
457 | int shift = (kcontrol->private_value >> 8) & 0xff; | 457 | int shift = (kcontrol->private_value >> 8) & 0xff; |
@@ -478,7 +478,7 @@ static int snd_cs4236_put_singlec(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_ | |||
478 | .get = snd_cs4236_get_double, .put = snd_cs4236_put_double, \ | 478 | .get = snd_cs4236_get_double, .put = snd_cs4236_put_double, \ |
479 | .private_value = left_reg | (right_reg << 8) | (shift_left << 16) | (shift_right << 19) | (mask << 24) | (invert << 22) } | 479 | .private_value = left_reg | (right_reg << 8) | (shift_left << 16) | (shift_right << 19) | (mask << 24) | (invert << 22) } |
480 | 480 | ||
481 | static int snd_cs4236_info_double(snd_kcontrol_t *kcontrol, snd_ctl_elem_info_t * uinfo) | 481 | static int snd_cs4236_info_double(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo) |
482 | { | 482 | { |
483 | int mask = (kcontrol->private_value >> 24) & 0xff; | 483 | int mask = (kcontrol->private_value >> 24) & 0xff; |
484 | 484 | ||
@@ -489,9 +489,9 @@ static int snd_cs4236_info_double(snd_kcontrol_t *kcontrol, snd_ctl_elem_info_t | |||
489 | return 0; | 489 | return 0; |
490 | } | 490 | } |
491 | 491 | ||
492 | static int snd_cs4236_get_double(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 492 | static int snd_cs4236_get_double(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
493 | { | 493 | { |
494 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 494 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
495 | unsigned long flags; | 495 | unsigned long flags; |
496 | int left_reg = kcontrol->private_value & 0xff; | 496 | int left_reg = kcontrol->private_value & 0xff; |
497 | int right_reg = (kcontrol->private_value >> 8) & 0xff; | 497 | int right_reg = (kcontrol->private_value >> 8) & 0xff; |
@@ -511,9 +511,9 @@ static int snd_cs4236_get_double(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t | |||
511 | return 0; | 511 | return 0; |
512 | } | 512 | } |
513 | 513 | ||
514 | static int snd_cs4236_put_double(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 514 | static int snd_cs4236_put_double(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
515 | { | 515 | { |
516 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 516 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
517 | unsigned long flags; | 517 | unsigned long flags; |
518 | int left_reg = kcontrol->private_value & 0xff; | 518 | int left_reg = kcontrol->private_value & 0xff; |
519 | int right_reg = (kcontrol->private_value >> 8) & 0xff; | 519 | int right_reg = (kcontrol->private_value >> 8) & 0xff; |
@@ -554,9 +554,9 @@ static int snd_cs4236_put_double(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t | |||
554 | .get = snd_cs4236_get_double1, .put = snd_cs4236_put_double1, \ | 554 | .get = snd_cs4236_get_double1, .put = snd_cs4236_put_double1, \ |
555 | .private_value = left_reg | (right_reg << 8) | (shift_left << 16) | (shift_right << 19) | (mask << 24) | (invert << 22) } | 555 | .private_value = left_reg | (right_reg << 8) | (shift_left << 16) | (shift_right << 19) | (mask << 24) | (invert << 22) } |
556 | 556 | ||
557 | static int snd_cs4236_get_double1(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 557 | static int snd_cs4236_get_double1(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
558 | { | 558 | { |
559 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 559 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
560 | unsigned long flags; | 560 | unsigned long flags; |
561 | int left_reg = kcontrol->private_value & 0xff; | 561 | int left_reg = kcontrol->private_value & 0xff; |
562 | int right_reg = (kcontrol->private_value >> 8) & 0xff; | 562 | int right_reg = (kcontrol->private_value >> 8) & 0xff; |
@@ -576,9 +576,9 @@ static int snd_cs4236_get_double1(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_ | |||
576 | return 0; | 576 | return 0; |
577 | } | 577 | } |
578 | 578 | ||
579 | static int snd_cs4236_put_double1(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 579 | static int snd_cs4236_put_double1(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
580 | { | 580 | { |
581 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 581 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
582 | unsigned long flags; | 582 | unsigned long flags; |
583 | int left_reg = kcontrol->private_value & 0xff; | 583 | int left_reg = kcontrol->private_value & 0xff; |
584 | int right_reg = (kcontrol->private_value >> 8) & 0xff; | 584 | int right_reg = (kcontrol->private_value >> 8) & 0xff; |
@@ -618,9 +618,9 @@ static inline int snd_cs4236_mixer_master_digital_invert_volume(int vol) | |||
618 | return (vol < 64) ? 63 - vol : 64 + (71 - vol); | 618 | return (vol < 64) ? 63 - vol : 64 + (71 - vol); |
619 | } | 619 | } |
620 | 620 | ||
621 | static int snd_cs4236_get_master_digital(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 621 | static int snd_cs4236_get_master_digital(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
622 | { | 622 | { |
623 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 623 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
624 | unsigned long flags; | 624 | unsigned long flags; |
625 | 625 | ||
626 | spin_lock_irqsave(&chip->reg_lock, flags); | 626 | spin_lock_irqsave(&chip->reg_lock, flags); |
@@ -630,9 +630,9 @@ static int snd_cs4236_get_master_digital(snd_kcontrol_t * kcontrol, snd_ctl_elem | |||
630 | return 0; | 630 | return 0; |
631 | } | 631 | } |
632 | 632 | ||
633 | static int snd_cs4236_put_master_digital(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 633 | static int snd_cs4236_put_master_digital(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
634 | { | 634 | { |
635 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 635 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
636 | unsigned long flags; | 636 | unsigned long flags; |
637 | int change; | 637 | int change; |
638 | unsigned short val1, val2; | 638 | unsigned short val1, val2; |
@@ -677,9 +677,9 @@ static inline int snd_cs4235_mixer_output_accu_set_volume(int vol) | |||
677 | return 1 << 5; | 677 | return 1 << 5; |
678 | } | 678 | } |
679 | 679 | ||
680 | static int snd_cs4235_get_output_accu(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 680 | static int snd_cs4235_get_output_accu(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
681 | { | 681 | { |
682 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 682 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
683 | unsigned long flags; | 683 | unsigned long flags; |
684 | 684 | ||
685 | spin_lock_irqsave(&chip->reg_lock, flags); | 685 | spin_lock_irqsave(&chip->reg_lock, flags); |
@@ -689,9 +689,9 @@ static int snd_cs4235_get_output_accu(snd_kcontrol_t * kcontrol, snd_ctl_elem_va | |||
689 | return 0; | 689 | return 0; |
690 | } | 690 | } |
691 | 691 | ||
692 | static int snd_cs4235_put_output_accu(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 692 | static int snd_cs4235_put_output_accu(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
693 | { | 693 | { |
694 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 694 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
695 | unsigned long flags; | 695 | unsigned long flags; |
696 | int change; | 696 | int change; |
697 | unsigned short val1, val2; | 697 | unsigned short val1, val2; |
@@ -708,7 +708,7 @@ static int snd_cs4235_put_output_accu(snd_kcontrol_t * kcontrol, snd_ctl_elem_va | |||
708 | return change; | 708 | return change; |
709 | } | 709 | } |
710 | 710 | ||
711 | static snd_kcontrol_new_t snd_cs4236_controls[] = { | 711 | static struct snd_kcontrol_new snd_cs4236_controls[] = { |
712 | 712 | ||
713 | CS4236_DOUBLE("Master Digital Playback Switch", 0, CS4236_LEFT_MASTER, CS4236_RIGHT_MASTER, 7, 7, 1, 1), | 713 | CS4236_DOUBLE("Master Digital Playback Switch", 0, CS4236_LEFT_MASTER, CS4236_RIGHT_MASTER, 7, 7, 1, 1), |
714 | CS4236_DOUBLE("Master Digital Capture Switch", 0, CS4236_DAC_MUTE, CS4236_DAC_MUTE, 7, 6, 1, 1), | 714 | CS4236_DOUBLE("Master Digital Capture Switch", 0, CS4236_DAC_MUTE, CS4236_DAC_MUTE, 7, 6, 1, 1), |
@@ -759,7 +759,7 @@ CS4231_SINGLE("Digital Loopback Playback Switch", 0, CS4231_LOOPBACK, 0, 1, 0), | |||
759 | CS4236_DOUBLE1("Digital Loopback Playback Volume", 0, CS4231_LOOPBACK, CS4236_RIGHT_LOOPBACK, 2, 0, 63, 1) | 759 | CS4236_DOUBLE1("Digital Loopback Playback Volume", 0, CS4231_LOOPBACK, CS4236_RIGHT_LOOPBACK, 2, 0, 63, 1) |
760 | }; | 760 | }; |
761 | 761 | ||
762 | static snd_kcontrol_new_t snd_cs4235_controls[] = { | 762 | static struct snd_kcontrol_new snd_cs4235_controls[] = { |
763 | 763 | ||
764 | CS4231_DOUBLE("Master Switch", 0, CS4235_LEFT_MASTER, CS4235_RIGHT_MASTER, 7, 7, 1, 1), | 764 | CS4231_DOUBLE("Master Switch", 0, CS4235_LEFT_MASTER, CS4235_RIGHT_MASTER, 7, 7, 1, 1), |
765 | CS4231_DOUBLE("Master Volume", 0, CS4235_LEFT_MASTER, CS4235_RIGHT_MASTER, 0, 0, 31, 1), | 765 | CS4231_DOUBLE("Master Volume", 0, CS4235_LEFT_MASTER, CS4235_RIGHT_MASTER, 0, 0, 31, 1), |
@@ -812,9 +812,9 @@ CS4231_DOUBLE("Analog Loopback Switch", 0, CS4231_LEFT_INPUT, CS4231_RIGHT_INPUT | |||
812 | .get = snd_cs4236_get_iec958_switch, .put = snd_cs4236_put_iec958_switch, \ | 812 | .get = snd_cs4236_get_iec958_switch, .put = snd_cs4236_put_iec958_switch, \ |
813 | .private_value = 1 << 16 } | 813 | .private_value = 1 << 16 } |
814 | 814 | ||
815 | static int snd_cs4236_get_iec958_switch(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 815 | static int snd_cs4236_get_iec958_switch(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
816 | { | 816 | { |
817 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 817 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
818 | unsigned long flags; | 818 | unsigned long flags; |
819 | 819 | ||
820 | spin_lock_irqsave(&chip->reg_lock, flags); | 820 | spin_lock_irqsave(&chip->reg_lock, flags); |
@@ -832,9 +832,9 @@ static int snd_cs4236_get_iec958_switch(snd_kcontrol_t * kcontrol, snd_ctl_elem_ | |||
832 | return 0; | 832 | return 0; |
833 | } | 833 | } |
834 | 834 | ||
835 | static int snd_cs4236_put_iec958_switch(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) | 835 | static int snd_cs4236_put_iec958_switch(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) |
836 | { | 836 | { |
837 | cs4231_t *chip = snd_kcontrol_chip(kcontrol); | 837 | struct snd_cs4231 *chip = snd_kcontrol_chip(kcontrol); |
838 | unsigned long flags; | 838 | unsigned long flags; |
839 | int change; | 839 | int change; |
840 | unsigned short enable, val; | 840 | unsigned short enable, val; |
@@ -868,7 +868,7 @@ static int snd_cs4236_put_iec958_switch(snd_kcontrol_t * kcontrol, snd_ctl_elem_ | |||
868 | return change; | 868 | return change; |
869 | } | 869 | } |
870 | 870 | ||
871 | static snd_kcontrol_new_t snd_cs4236_iec958_controls[] = { | 871 | static struct snd_kcontrol_new snd_cs4236_iec958_controls[] = { |
872 | CS4236_IEC958_ENABLE("IEC958 Output Enable", 0), | 872 | CS4236_IEC958_ENABLE("IEC958 Output Enable", 0), |
873 | CS4236_SINGLEC("IEC958 Output Validity", 0, 4, 4, 1, 0), | 873 | CS4236_SINGLEC("IEC958 Output Validity", 0, 4, 4, 1, 0), |
874 | CS4236_SINGLEC("IEC958 Output User", 0, 4, 5, 1, 0), | 874 | CS4236_SINGLEC("IEC958 Output User", 0, 4, 5, 1, 0), |
@@ -877,12 +877,12 @@ CS4236_SINGLEC("IEC958 Output Channel Status Low", 0, 5, 1, 127, 0), | |||
877 | CS4236_SINGLEC("IEC958 Output Channel Status High", 0, 6, 0, 255, 0) | 877 | CS4236_SINGLEC("IEC958 Output Channel Status High", 0, 6, 0, 255, 0) |
878 | }; | 878 | }; |
879 | 879 | ||
880 | static snd_kcontrol_new_t snd_cs4236_3d_controls_cs4235[] = { | 880 | static struct snd_kcontrol_new snd_cs4236_3d_controls_cs4235[] = { |
881 | CS4236_SINGLEC("3D Control - Switch", 0, 3, 4, 1, 0), | 881 | CS4236_SINGLEC("3D Control - Switch", 0, 3, 4, 1, 0), |
882 | CS4236_SINGLEC("3D Control - Space", 0, 2, 4, 15, 1) | 882 | CS4236_SINGLEC("3D Control - Space", 0, 2, 4, 15, 1) |
883 | }; | 883 | }; |
884 | 884 | ||
885 | static snd_kcontrol_new_t snd_cs4236_3d_controls_cs4237[] = { | 885 | static struct snd_kcontrol_new snd_cs4236_3d_controls_cs4237[] = { |
886 | CS4236_SINGLEC("3D Control - Switch", 0, 3, 7, 1, 0), | 886 | CS4236_SINGLEC("3D Control - Switch", 0, 3, 7, 1, 0), |
887 | CS4236_SINGLEC("3D Control - Space", 0, 2, 4, 15, 1), | 887 | CS4236_SINGLEC("3D Control - Space", 0, 2, 4, 15, 1), |
888 | CS4236_SINGLEC("3D Control - Center", 0, 2, 0, 15, 1), | 888 | CS4236_SINGLEC("3D Control - Center", 0, 2, 0, 15, 1), |
@@ -890,19 +890,19 @@ CS4236_SINGLEC("3D Control - Mono", 0, 3, 6, 1, 0), | |||
890 | CS4236_SINGLEC("3D Control - IEC958", 0, 3, 5, 1, 0) | 890 | CS4236_SINGLEC("3D Control - IEC958", 0, 3, 5, 1, 0) |
891 | }; | 891 | }; |
892 | 892 | ||
893 | static snd_kcontrol_new_t snd_cs4236_3d_controls_cs4238[] = { | 893 | static struct snd_kcontrol_new snd_cs4236_3d_controls_cs4238[] = { |
894 | CS4236_SINGLEC("3D Control - Switch", 0, 3, 4, 1, 0), | 894 | CS4236_SINGLEC("3D Control - Switch", 0, 3, 4, 1, 0), |
895 | CS4236_SINGLEC("3D Control - Space", 0, 2, 4, 15, 1), | 895 | CS4236_SINGLEC("3D Control - Space", 0, 2, 4, 15, 1), |
896 | CS4236_SINGLEC("3D Control - Volume", 0, 2, 0, 15, 1), | 896 | CS4236_SINGLEC("3D Control - Volume", 0, 2, 0, 15, 1), |
897 | CS4236_SINGLEC("3D Control - IEC958", 0, 3, 5, 1, 0) | 897 | CS4236_SINGLEC("3D Control - IEC958", 0, 3, 5, 1, 0) |
898 | }; | 898 | }; |
899 | 899 | ||
900 | int snd_cs4236_mixer(cs4231_t *chip) | 900 | int snd_cs4236_mixer(struct snd_cs4231 *chip) |
901 | { | 901 | { |
902 | snd_card_t *card; | 902 | struct snd_card *card; |
903 | unsigned int idx, count; | 903 | unsigned int idx, count; |
904 | int err; | 904 | int err; |
905 | snd_kcontrol_new_t *kcontrol; | 905 | struct snd_kcontrol_new *kcontrol; |
906 | 906 | ||
907 | snd_assert(chip != NULL && chip->card != NULL, return -EINVAL); | 907 | snd_assert(chip != NULL && chip->card != NULL, return -EINVAL); |
908 | card = chip->card; | 908 | card = chip->card; |