diff options
author | Takashi Iwai <tiwai@suse.de> | 2005-11-17 08:13:14 -0500 |
---|---|---|
committer | Jaroslav Kysela <perex@suse.cz> | 2006-01-03 06:18:04 -0500 |
commit | 5b1646a8eceff0a4ff06f309abb6e7f43f99a498 (patch) | |
tree | ecbb7c1d5ffdf2f3f732a18aae3ed6b2a3752e9e /sound/drivers/opl3/opl3_midi.c | |
parent | e1fad17bb4084dc7c435360185417aed55656ec8 (diff) |
[ALSA] Remove xxx_t typedefs: OPL3
Modules: OPL3,Raw OPL FM
Remove xxx_t typedefs from the OPL3 driver
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/drivers/opl3/opl3_midi.c')
-rw-r--r-- | sound/drivers/opl3/opl3_midi.c | 70 |
1 files changed, 35 insertions, 35 deletions
diff --git a/sound/drivers/opl3/opl3_midi.c b/sound/drivers/opl3/opl3_midi.c index 93d674070b71..48c480e050ce 100644 --- a/sound/drivers/opl3/opl3_midi.c +++ b/sound/drivers/opl3/opl3_midi.c | |||
@@ -60,7 +60,7 @@ static char opl3_volume_table[128] = | |||
60 | }; | 60 | }; |
61 | 61 | ||
62 | void snd_opl3_calc_volume(unsigned char *volbyte, int vel, | 62 | void snd_opl3_calc_volume(unsigned char *volbyte, int vel, |
63 | snd_midi_channel_t *chan) | 63 | struct snd_midi_channel *chan) |
64 | { | 64 | { |
65 | int oldvol, newvol, n; | 65 | int oldvol, newvol, n; |
66 | int volume; | 66 | int volume; |
@@ -93,7 +93,7 @@ static short opl3_note_table[16] = | |||
93 | }; | 93 | }; |
94 | 94 | ||
95 | static void snd_opl3_calc_pitch(unsigned char *fnum, unsigned char *blocknum, | 95 | static void snd_opl3_calc_pitch(unsigned char *fnum, unsigned char *blocknum, |
96 | int note, snd_midi_channel_t *chan) | 96 | int note, struct snd_midi_channel *chan) |
97 | { | 97 | { |
98 | int block = ((note / 12) & 0x07) - 1; | 98 | int block = ((note / 12) & 0x07) - 1; |
99 | int idx = (note % 12) + 2; | 99 | int idx = (note % 12) + 2; |
@@ -121,7 +121,7 @@ static void snd_opl3_calc_pitch(unsigned char *fnum, unsigned char *blocknum, | |||
121 | 121 | ||
122 | 122 | ||
123 | #ifdef DEBUG_ALLOC | 123 | #ifdef DEBUG_ALLOC |
124 | static void debug_alloc(opl3_t *opl3, char *s, int voice) { | 124 | static void debug_alloc(struct snd_opl3 *opl3, char *s, int voice) { |
125 | int i; | 125 | int i; |
126 | char *str = "x.24"; | 126 | char *str = "x.24"; |
127 | 127 | ||
@@ -135,12 +135,12 @@ static void debug_alloc(opl3_t *opl3, char *s, int voice) { | |||
135 | /* | 135 | /* |
136 | * Get a FM voice (channel) to play a note on. | 136 | * Get a FM voice (channel) to play a note on. |
137 | */ | 137 | */ |
138 | static int opl3_get_voice(opl3_t *opl3, int instr_4op, | 138 | static int opl3_get_voice(struct snd_opl3 *opl3, int instr_4op, |
139 | snd_midi_channel_t *chan) { | 139 | struct snd_midi_channel *chan) { |
140 | int chan_4op_1; /* first voice for 4op instrument */ | 140 | int chan_4op_1; /* first voice for 4op instrument */ |
141 | int chan_4op_2; /* second voice for 4op instrument */ | 141 | int chan_4op_2; /* second voice for 4op instrument */ |
142 | 142 | ||
143 | snd_opl3_voice_t *vp, *vp2; | 143 | struct snd_opl3_voice *vp, *vp2; |
144 | unsigned int voice_time; | 144 | unsigned int voice_time; |
145 | int i; | 145 | int i; |
146 | 146 | ||
@@ -237,13 +237,13 @@ static int opl3_get_voice(opl3_t *opl3, int instr_4op, | |||
237 | void snd_opl3_timer_func(unsigned long data) | 237 | void snd_opl3_timer_func(unsigned long data) |
238 | { | 238 | { |
239 | 239 | ||
240 | opl3_t *opl3 = (opl3_t *)data; | 240 | struct snd_opl3 *opl3 = (struct snd_opl3 *)data; |
241 | int again = 0; | 241 | int again = 0; |
242 | int i; | 242 | int i; |
243 | 243 | ||
244 | spin_lock(&opl3->sys_timer_lock); | 244 | spin_lock(&opl3->sys_timer_lock); |
245 | for (i = 0; i < opl3->max_voices; i++) { | 245 | for (i = 0; i < opl3->max_voices; i++) { |
246 | snd_opl3_voice_t *vp = &opl3->voices[i]; | 246 | struct snd_opl3_voice *vp = &opl3->voices[i]; |
247 | if (vp->state > 0 && vp->note_off_check) { | 247 | if (vp->state > 0 && vp->note_off_check) { |
248 | if (vp->note_off == jiffies) | 248 | if (vp->note_off == jiffies) |
249 | snd_opl3_note_off(opl3, vp->note, 0, vp->chan); | 249 | snd_opl3_note_off(opl3, vp->note, 0, vp->chan); |
@@ -263,7 +263,7 @@ void snd_opl3_timer_func(unsigned long data) | |||
263 | /* | 263 | /* |
264 | * Start system timer | 264 | * Start system timer |
265 | */ | 265 | */ |
266 | static void snd_opl3_start_timer(opl3_t *opl3) | 266 | static void snd_opl3_start_timer(struct snd_opl3 *opl3) |
267 | { | 267 | { |
268 | unsigned long flags; | 268 | unsigned long flags; |
269 | spin_lock_irqsave(&opl3->sys_timer_lock, flags); | 269 | spin_lock_irqsave(&opl3->sys_timer_lock, flags); |
@@ -285,15 +285,15 @@ static int snd_opl3_oss_map[MAX_OPL3_VOICES] = { | |||
285 | /* | 285 | /* |
286 | * Start a note. | 286 | * Start a note. |
287 | */ | 287 | */ |
288 | void snd_opl3_note_on(void *p, int note, int vel, snd_midi_channel_t *chan) | 288 | void snd_opl3_note_on(void *p, int note, int vel, struct snd_midi_channel *chan) |
289 | { | 289 | { |
290 | opl3_t *opl3; | 290 | struct snd_opl3 *opl3; |
291 | snd_seq_instr_t wanted; | 291 | struct snd_seq_instr wanted; |
292 | snd_seq_kinstr_t *kinstr; | 292 | struct snd_seq_kinstr *kinstr; |
293 | int instr_4op; | 293 | int instr_4op; |
294 | 294 | ||
295 | int voice; | 295 | int voice; |
296 | snd_opl3_voice_t *vp, *vp2; | 296 | struct snd_opl3_voice *vp, *vp2; |
297 | unsigned short connect_mask; | 297 | unsigned short connect_mask; |
298 | unsigned char connection; | 298 | unsigned char connection; |
299 | unsigned char vol_op[4]; | 299 | unsigned char vol_op[4]; |
@@ -310,7 +310,7 @@ void snd_opl3_note_on(void *p, int note, int vel, snd_midi_channel_t *chan) | |||
310 | unsigned char fnum, blocknum; | 310 | unsigned char fnum, blocknum; |
311 | int i; | 311 | int i; |
312 | 312 | ||
313 | fm_instrument_t *fm; | 313 | struct fm_instrument *fm; |
314 | unsigned long flags; | 314 | unsigned long flags; |
315 | 315 | ||
316 | opl3 = p; | 316 | opl3 = p; |
@@ -615,13 +615,13 @@ void snd_opl3_note_on(void *p, int note, int vel, snd_midi_channel_t *chan) | |||
615 | spin_unlock_irqrestore(&opl3->voice_lock, flags); | 615 | spin_unlock_irqrestore(&opl3->voice_lock, flags); |
616 | } | 616 | } |
617 | 617 | ||
618 | static void snd_opl3_kill_voice(opl3_t *opl3, int voice) | 618 | static void snd_opl3_kill_voice(struct snd_opl3 *opl3, int voice) |
619 | { | 619 | { |
620 | unsigned short reg_side; | 620 | unsigned short reg_side; |
621 | unsigned char voice_offset; | 621 | unsigned char voice_offset; |
622 | unsigned short opl3_reg; | 622 | unsigned short opl3_reg; |
623 | 623 | ||
624 | snd_opl3_voice_t *vp, *vp2; | 624 | struct snd_opl3_voice *vp, *vp2; |
625 | 625 | ||
626 | snd_assert(voice < MAX_OPL3_VOICES, return); | 626 | snd_assert(voice < MAX_OPL3_VOICES, return); |
627 | 627 | ||
@@ -663,12 +663,12 @@ static void snd_opl3_kill_voice(opl3_t *opl3, int voice) | |||
663 | /* | 663 | /* |
664 | * Release a note in response to a midi note off. | 664 | * Release a note in response to a midi note off. |
665 | */ | 665 | */ |
666 | void snd_opl3_note_off(void *p, int note, int vel, snd_midi_channel_t *chan) | 666 | void snd_opl3_note_off(void *p, int note, int vel, struct snd_midi_channel *chan) |
667 | { | 667 | { |
668 | opl3_t *opl3; | 668 | struct snd_opl3 *opl3; |
669 | 669 | ||
670 | int voice; | 670 | int voice; |
671 | snd_opl3_voice_t *vp; | 671 | struct snd_opl3_voice *vp; |
672 | 672 | ||
673 | unsigned long flags; | 673 | unsigned long flags; |
674 | 674 | ||
@@ -708,9 +708,9 @@ void snd_opl3_note_off(void *p, int note, int vel, snd_midi_channel_t *chan) | |||
708 | /* | 708 | /* |
709 | * key pressure change | 709 | * key pressure change |
710 | */ | 710 | */ |
711 | void snd_opl3_key_press(void *p, int note, int vel, snd_midi_channel_t *chan) | 711 | void snd_opl3_key_press(void *p, int note, int vel, struct snd_midi_channel *chan) |
712 | { | 712 | { |
713 | opl3_t *opl3; | 713 | struct snd_opl3 *opl3; |
714 | 714 | ||
715 | opl3 = p; | 715 | opl3 = p; |
716 | #ifdef DEBUG_MIDI | 716 | #ifdef DEBUG_MIDI |
@@ -722,9 +722,9 @@ void snd_opl3_key_press(void *p, int note, int vel, snd_midi_channel_t *chan) | |||
722 | /* | 722 | /* |
723 | * terminate note | 723 | * terminate note |
724 | */ | 724 | */ |
725 | void snd_opl3_terminate_note(void *p, int note, snd_midi_channel_t *chan) | 725 | void snd_opl3_terminate_note(void *p, int note, struct snd_midi_channel *chan) |
726 | { | 726 | { |
727 | opl3_t *opl3; | 727 | struct snd_opl3 *opl3; |
728 | 728 | ||
729 | opl3 = p; | 729 | opl3 = p; |
730 | #ifdef DEBUG_MIDI | 730 | #ifdef DEBUG_MIDI |
@@ -733,7 +733,7 @@ void snd_opl3_terminate_note(void *p, int note, snd_midi_channel_t *chan) | |||
733 | #endif | 733 | #endif |
734 | } | 734 | } |
735 | 735 | ||
736 | static void snd_opl3_update_pitch(opl3_t *opl3, int voice) | 736 | static void snd_opl3_update_pitch(struct snd_opl3 *opl3, int voice) |
737 | { | 737 | { |
738 | unsigned short reg_side; | 738 | unsigned short reg_side; |
739 | unsigned char voice_offset; | 739 | unsigned char voice_offset; |
@@ -741,7 +741,7 @@ static void snd_opl3_update_pitch(opl3_t *opl3, int voice) | |||
741 | 741 | ||
742 | unsigned char fnum, blocknum; | 742 | unsigned char fnum, blocknum; |
743 | 743 | ||
744 | snd_opl3_voice_t *vp; | 744 | struct snd_opl3_voice *vp; |
745 | 745 | ||
746 | snd_assert(voice < MAX_OPL3_VOICES, return); | 746 | snd_assert(voice < MAX_OPL3_VOICES, return); |
747 | 747 | ||
@@ -780,10 +780,10 @@ static void snd_opl3_update_pitch(opl3_t *opl3, int voice) | |||
780 | /* | 780 | /* |
781 | * Update voice pitch controller | 781 | * Update voice pitch controller |
782 | */ | 782 | */ |
783 | static void snd_opl3_pitch_ctrl(opl3_t *opl3, snd_midi_channel_t *chan) | 783 | static void snd_opl3_pitch_ctrl(struct snd_opl3 *opl3, struct snd_midi_channel *chan) |
784 | { | 784 | { |
785 | int voice; | 785 | int voice; |
786 | snd_opl3_voice_t *vp; | 786 | struct snd_opl3_voice *vp; |
787 | 787 | ||
788 | unsigned long flags; | 788 | unsigned long flags; |
789 | 789 | ||
@@ -810,9 +810,9 @@ static void snd_opl3_pitch_ctrl(opl3_t *opl3, snd_midi_channel_t *chan) | |||
810 | * Deal with a controler type event. This includes all types of | 810 | * Deal with a controler type event. This includes all types of |
811 | * control events, not just the midi controllers | 811 | * control events, not just the midi controllers |
812 | */ | 812 | */ |
813 | void snd_opl3_control(void *p, int type, snd_midi_channel_t *chan) | 813 | void snd_opl3_control(void *p, int type, struct snd_midi_channel *chan) |
814 | { | 814 | { |
815 | opl3_t *opl3; | 815 | struct snd_opl3 *opl3; |
816 | 816 | ||
817 | opl3 = p; | 817 | opl3 = p; |
818 | #ifdef DEBUG_MIDI | 818 | #ifdef DEBUG_MIDI |
@@ -846,10 +846,10 @@ void snd_opl3_control(void *p, int type, snd_midi_channel_t *chan) | |||
846 | /* | 846 | /* |
847 | * NRPN events | 847 | * NRPN events |
848 | */ | 848 | */ |
849 | void snd_opl3_nrpn(void *p, snd_midi_channel_t *chan, | 849 | void snd_opl3_nrpn(void *p, struct snd_midi_channel *chan, |
850 | snd_midi_channel_set_t *chset) | 850 | struct snd_midi_channel_set *chset) |
851 | { | 851 | { |
852 | opl3_t *opl3; | 852 | struct snd_opl3 *opl3; |
853 | 853 | ||
854 | opl3 = p; | 854 | opl3 = p; |
855 | #ifdef DEBUG_MIDI | 855 | #ifdef DEBUG_MIDI |
@@ -862,9 +862,9 @@ void snd_opl3_nrpn(void *p, snd_midi_channel_t *chan, | |||
862 | * receive sysex | 862 | * receive sysex |
863 | */ | 863 | */ |
864 | void snd_opl3_sysex(void *p, unsigned char *buf, int len, | 864 | void snd_opl3_sysex(void *p, unsigned char *buf, int len, |
865 | int parsed, snd_midi_channel_set_t *chset) | 865 | int parsed, struct snd_midi_channel_set *chset) |
866 | { | 866 | { |
867 | opl3_t *opl3; | 867 | struct snd_opl3 *opl3; |
868 | 868 | ||
869 | opl3 = p; | 869 | opl3 = p; |
870 | #ifdef DEBUG_MIDI | 870 | #ifdef DEBUG_MIDI |