Lines Matching refs:emu
44 static void emuspec_control(struct snd_emux *emu, struct snd_emux_port *port,
46 static void gusspec_control(struct snd_emux *emu, struct snd_emux_port *port,
48 static void fake_event(struct snd_emux *emu, struct snd_emux_port *port,
67 snd_emux_init_seq_oss(struct snd_emux *emu) in snd_emux_init_seq_oss() argument
73 if (snd_seq_device_new(emu->card, 1, SNDRV_SEQ_DEV_ID_OSS, in snd_emux_init_seq_oss()
77 emu->oss_synth = dev; in snd_emux_init_seq_oss()
78 strcpy(dev->name, emu->name); in snd_emux_init_seq_oss()
82 arg->nvoices = emu->max_voices; in snd_emux_init_seq_oss()
84 arg->private_data = emu; in snd_emux_init_seq_oss()
87 snd_device_register(emu->card, dev); in snd_emux_init_seq_oss()
95 snd_emux_detach_seq_oss(struct snd_emux *emu) in snd_emux_detach_seq_oss() argument
97 if (emu->oss_synth) { in snd_emux_detach_seq_oss()
98 snd_device_free(emu->card, emu->oss_synth); in snd_emux_detach_seq_oss()
99 emu->oss_synth = NULL; in snd_emux_detach_seq_oss()
113 struct snd_emux *emu; in snd_emux_open_seq_oss() local
118 emu = closure; in snd_emux_open_seq_oss()
119 if (snd_BUG_ON(!arg || !emu)) in snd_emux_open_seq_oss()
122 if (!snd_emux_inc_count(emu)) in snd_emux_open_seq_oss()
129 sprintf(tmpname, "%s OSS Port", emu->name); in snd_emux_open_seq_oss()
130 p = snd_emux_create_port(emu, tmpname, 32, in snd_emux_open_seq_oss()
134 snd_emux_dec_count(emu); in snd_emux_open_seq_oss()
179 struct snd_emux *emu; in snd_emux_close_seq_oss() local
188 emu = p->emu; in snd_emux_close_seq_oss()
189 if (snd_BUG_ON(!emu)) in snd_emux_close_seq_oss()
193 snd_soundfont_close_check(emu->sflist, SF_CLIENT_NO(p->chset.port)); in snd_emux_close_seq_oss()
195 snd_emux_dec_count(emu); in snd_emux_close_seq_oss()
208 struct snd_emux *emu; in snd_emux_load_patch_seq_oss() local
218 emu = p->emu; in snd_emux_load_patch_seq_oss()
219 if (snd_BUG_ON(!emu)) in snd_emux_load_patch_seq_oss()
223 rc = snd_soundfont_load_guspatch(emu->sflist, buf, count, in snd_emux_load_patch_seq_oss()
233 rc = snd_soundfont_load(emu->sflist, buf, count, SF_CLIENT_NO(p->chset.port)); in snd_emux_load_patch_seq_oss()
235 if (emu->ops.load_fx) in snd_emux_load_patch_seq_oss()
236 rc = emu->ops.load_fx(emu, patch.type, patch.optarg, buf, count); in snd_emux_load_patch_seq_oss()
253 struct snd_emux *emu; in snd_emux_ioctl_seq_oss() local
261 emu = p->emu; in snd_emux_ioctl_seq_oss()
262 if (snd_BUG_ON(!emu)) in snd_emux_ioctl_seq_oss()
267 snd_soundfont_remove_samples(emu->sflist); in snd_emux_ioctl_seq_oss()
271 if (emu->memhdr) in snd_emux_ioctl_seq_oss()
272 return snd_util_mem_avail(emu->memhdr); in snd_emux_ioctl_seq_oss()
305 struct snd_emux *emu; in snd_emux_event_oss_input() local
312 emu = p->emu; in snd_emux_event_oss_input()
313 if (snd_BUG_ON(!emu)) in snd_emux_event_oss_input()
324 emuspec_control(emu, p, cmd, data, atomic, hop); in snd_emux_event_oss_input()
326 gusspec_control(emu, p, cmd, data, atomic, hop); in snd_emux_event_oss_input()
335 emuspec_control(struct snd_emux *emu, struct snd_emux_port *port, int cmd, in emuspec_control() argument
356 snd_soundfont_remove_unlocked(emu->sflist); in emuspec_control()
365 snd_emux_terminate_all(emu); in emuspec_control()
376 fake_event(emu, port, voice, MIDI_CTL_ALL_NOTES_OFF, 0, atomic, hop); in emuspec_control()
379 fake_event(emu, port, voice, MIDI_CTL_ALL_SOUNDS_OFF, 0, atomic, hop); in emuspec_control()
417 if (emu->ops.oss_ioctl) in emuspec_control()
418 emu->ops.oss_ioctl(emu, cmd, p1, p2); in emuspec_control()
430 gusspec_control(struct snd_emux *emu, struct snd_emux_port *port, int cmd, in gusspec_control() argument
498 fake_event(struct snd_emux *emu, struct snd_emux_port *port, int ch, int param, int val, int atomic… in fake_event() argument