3636 */
3737#define SNDRV_EMUX_USE_RAW_EFFECT
3838
39-
40- /*
41- * typedefs
42- */
43- typedef struct snd_emux_effect_table snd_emux_effect_table_t ;
44- typedef struct snd_emux_port snd_emux_port_t ;
45- typedef struct snd_emux_voice snd_emux_voice_t ;
46- typedef struct snd_emux snd_emux_t ;
47-
39+ struct snd_emux ;
40+ struct snd_emux_port ;
41+ struct snd_emux_voice ;
42+ struct snd_emux_effect_table ;
4843
4944/*
5045 * operators
5146 */
52- typedef struct snd_emux_operators {
47+ struct snd_emux_operators {
5348 struct module * owner ;
54- snd_emux_voice_t * (* get_voice )(snd_emux_t * emu , snd_emux_port_t * port );
55- int (* prepare )(snd_emux_voice_t * vp );
56- void (* trigger )(snd_emux_voice_t * vp );
57- void (* release )(snd_emux_voice_t * vp );
58- void (* update )(snd_emux_voice_t * vp , int update );
59- void (* terminate )(snd_emux_voice_t * vp );
60- void (* free_voice )(snd_emux_voice_t * vp );
61- void (* reset )(snd_emux_t * emu , int ch );
62- /* the first parameters are snd_emux_t */
63- int (* sample_new )(snd_emux_t * emu , snd_sf_sample_t * sp , snd_util_memhdr_t * hdr , const void __user * data , long count );
64- int (* sample_free )(snd_emux_t * emu , snd_sf_sample_t * sp , snd_util_memhdr_t * hdr );
65- void (* sample_reset )(snd_emux_t * emu );
66- int (* load_fx )(snd_emux_t * emu , int type , int arg , const void __user * data , long count );
67- void (* sysex )(snd_emux_t * emu , char * buf , int len , int parsed , snd_midi_channel_set_t * chset );
49+ struct snd_emux_voice * (* get_voice )(struct snd_emux * emu ,
50+ struct snd_emux_port * port );
51+ int (* prepare )(struct snd_emux_voice * vp );
52+ void (* trigger )(struct snd_emux_voice * vp );
53+ void (* release )(struct snd_emux_voice * vp );
54+ void (* update )(struct snd_emux_voice * vp , int update );
55+ void (* terminate )(struct snd_emux_voice * vp );
56+ void (* free_voice )(struct snd_emux_voice * vp );
57+ void (* reset )(struct snd_emux * emu , int ch );
58+ /* the first parameters are struct snd_emux */
59+ int (* sample_new )(struct snd_emux * emu , struct snd_sf_sample * sp ,
60+ struct snd_util_memhdr * hdr ,
61+ const void __user * data , long count );
62+ int (* sample_free )(struct snd_emux * emu , struct snd_sf_sample * sp ,
63+ struct snd_util_memhdr * hdr );
64+ void (* sample_reset )(struct snd_emux * emu );
65+ int (* load_fx )(struct snd_emux * emu , int type , int arg ,
66+ const void __user * data , long count );
67+ void (* sysex )(struct snd_emux * emu , char * buf , int len , int parsed ,
68+ struct snd_midi_channel_set * chset );
6869#ifdef CONFIG_SND_SEQUENCER_OSS
69- int (* oss_ioctl )(snd_emux_t * emu , int cmd , int p1 , int p2 );
70+ int (* oss_ioctl )(struct snd_emux * emu , int cmd , int p1 , int p2 );
7071#endif
71- } snd_emux_operators_t ;
72+ };
7273
7374
7475/*
@@ -90,46 +91,46 @@ typedef struct snd_emux_operators {
9091 */
9192struct snd_emux {
9293
93- snd_card_t * card ; /* assigned card */
94+ struct snd_card * card ; /* assigned card */
9495
9596 /* following should be initialized before registration */
9697 int max_voices ; /* Number of voices */
9798 int mem_size ; /* memory size (in byte) */
9899 int num_ports ; /* number of ports to be created */
99100 int pitch_shift ; /* pitch shift value (for Emu10k1) */
100- snd_emux_operators_t ops ; /* operators */
101+ struct snd_emux_operators ops ; /* operators */
101102 void * hw ; /* hardware */
102103 unsigned long flags ; /* other conditions */
103104 int midi_ports ; /* number of virtual midi devices */
104105 int midi_devidx ; /* device offset of virtual midi */
105106 unsigned int linear_panning : 1 ; /* panning is linear (sbawe = 1, emu10k1 = 0) */
106107 int hwdep_idx ; /* hwdep device index */
107- snd_hwdep_t * hwdep ; /* hwdep device */
108+ struct snd_hwdep * hwdep ; /* hwdep device */
108109
109110 /* private */
110111 int num_voices ; /* current number of voices */
111- snd_sf_list_t * sflist ; /* root of SoundFont list */
112- snd_emux_voice_t * voices ; /* Voices (EMU 'channel') */
112+ struct snd_sf_list * sflist ; /* root of SoundFont list */
113+ struct snd_emux_voice * voices ; /* Voices (EMU 'channel') */
113114 int use_time ; /* allocation counter */
114115 spinlock_t voice_lock ; /* Lock for voice access */
115116 struct semaphore register_mutex ;
116117 int client ; /* For the sequencer client */
117118 int ports [SNDRV_EMUX_MAX_PORTS ]; /* The ports for this device */
118- snd_emux_port_t * portptrs [SNDRV_EMUX_MAX_PORTS ];
119+ struct snd_emux_port * portptrs [SNDRV_EMUX_MAX_PORTS ];
119120 int used ; /* use counter */
120121 char * name ; /* name of the device (internal) */
121- snd_rawmidi_t * * vmidi ;
122+ struct snd_rawmidi * * vmidi ;
122123 struct timer_list tlist ; /* for pending note-offs */
123124 int timer_active ;
124125
125- snd_util_memhdr_t * memhdr ; /* memory chunk information */
126+ struct snd_util_memhdr * memhdr ; /* memory chunk information */
126127
127128#ifdef CONFIG_PROC_FS
128- snd_info_entry_t * proc ;
129+ struct snd_info_entry * proc ;
129130#endif
130131
131132#ifdef CONFIG_SND_SEQUENCER_OSS
132- snd_seq_device_t * oss_synth ;
133+ struct snd_seq_device * oss_synth ;
133134#endif
134135};
135136
@@ -139,18 +140,18 @@ struct snd_emux {
139140 */
140141struct snd_emux_port {
141142
142- snd_midi_channel_set_t chset ;
143- snd_emux_t * emu ;
143+ struct snd_midi_channel_set chset ;
144+ struct snd_emux * emu ;
144145
145146 char port_mode ; /* operation mode */
146147 int volume_atten ; /* emuX raw attenuation */
147148 unsigned long drum_flags ; /* drum bitmaps */
148149 int ctrls [EMUX_MD_END ]; /* control parameters */
149150#ifdef SNDRV_EMUX_USE_RAW_EFFECT
150- snd_emux_effect_table_t * effect ;
151+ struct snd_emux_effect_table * effect ;
151152#endif
152153#ifdef CONFIG_SND_SEQUENCER_OSS
153- snd_seq_oss_arg_t * oss_arg ;
154+ struct snd_seq_oss_arg * oss_arg ;
154155#endif
155156};
156157
@@ -179,16 +180,16 @@ struct snd_emux_voice {
179180 unsigned char key ;
180181 unsigned char velocity ; /* Velocity of current note */
181182
182- snd_sf_zone_t * zone ; /* Zone assigned to this note */
183+ struct snd_sf_zone * zone ; /* Zone assigned to this note */
183184 void * block ; /* sample block pointer (optional) */
184- snd_midi_channel_t * chan ; /* Midi channel for this note */
185- snd_emux_port_t * port ; /* associated port */
186- snd_emux_t * emu ; /* assigned root info */
187- void * hw ; /* hardware pointer (emu8000_t or emu10k1_t ) */
185+ struct snd_midi_channel * chan ; /* Midi channel for this note */
186+ struct snd_emux_port * port ; /* associated port */
187+ struct snd_emux * emu ; /* assigned root info */
188+ void * hw ; /* hardware pointer (emu8000 or emu10k1 ) */
188189 unsigned long ontime ; /* jiffies at note triggered */
189190
190191 /* Emu8k/Emu10k1 registers */
191- soundfont_voice_info_t reg ;
192+ struct soundfont_voice_info reg ;
192193
193194 /* additional registers */
194195 int avol ; /* volume attenuation */
@@ -229,15 +230,15 @@ struct snd_emux_effect_table {
229230/*
230231 * prototypes - interface to Emu10k1 and Emu8k routines
231232 */
232- int snd_emux_new (snd_emux_t * * remu );
233- int snd_emux_register (snd_emux_t * emu , snd_card_t * card , int index , char * name );
234- int snd_emux_free (snd_emux_t * emu );
233+ int snd_emux_new (struct snd_emux * * remu );
234+ int snd_emux_register (struct snd_emux * emu , struct snd_card * card , int index , char * name );
235+ int snd_emux_free (struct snd_emux * emu );
235236
236237/*
237238 * exported functions
238239 */
239- void snd_emux_terminate_all (snd_emux_t * emu );
240- void snd_emux_lock_voice (snd_emux_t * emu , int voice );
241- void snd_emux_unlock_voice (snd_emux_t * emu , int voice );
240+ void snd_emux_terminate_all (struct snd_emux * emu );
241+ void snd_emux_lock_voice (struct snd_emux * emu , int voice );
242+ void snd_emux_unlock_voice (struct snd_emux * emu , int voice );
242243
243244#endif /* __SOUND_EMUX_SYNTH_H */
0 commit comments