diff options
author | Takashi Iwai <tiwai@suse.de> | 2015-03-23 08:14:02 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2015-03-23 08:14:02 -0400 |
commit | 3372dbdd8ca11f51be8c6a30b2bc79eb04c4a902 (patch) | |
tree | d4499bf5a5665b4820ffaf96bce55bf6b895195e /sound/core/seq/seq_midi.c | |
parent | bc465aa9d045feb0e13b4a8f32cc33c1943f62d6 (diff) | |
parent | 967b1307b69b8ada8b331e01046ad1ef83742e99 (diff) |
Merge branch 'for-next' into topic/hda-core
Diffstat (limited to 'sound/core/seq/seq_midi.c')
-rw-r--r-- | sound/core/seq/seq_midi.c | 36 |
1 files changed, 14 insertions, 22 deletions
diff --git a/sound/core/seq/seq_midi.c b/sound/core/seq/seq_midi.c index 68fec776da26..5dd0ee258359 100644 --- a/sound/core/seq/seq_midi.c +++ b/sound/core/seq/seq_midi.c | |||
@@ -273,8 +273,9 @@ static void snd_seq_midisynth_delete(struct seq_midisynth *msynth) | |||
273 | 273 | ||
274 | /* register new midi synth port */ | 274 | /* register new midi synth port */ |
275 | static int | 275 | static int |
276 | snd_seq_midisynth_register_port(struct snd_seq_device *dev) | 276 | snd_seq_midisynth_probe(struct device *_dev) |
277 | { | 277 | { |
278 | struct snd_seq_device *dev = to_seq_dev(_dev); | ||
278 | struct seq_midisynth_client *client; | 279 | struct seq_midisynth_client *client; |
279 | struct seq_midisynth *msynth, *ms; | 280 | struct seq_midisynth *msynth, *ms; |
280 | struct snd_seq_port_info *port; | 281 | struct snd_seq_port_info *port; |
@@ -427,8 +428,9 @@ snd_seq_midisynth_register_port(struct snd_seq_device *dev) | |||
427 | 428 | ||
428 | /* release midi synth port */ | 429 | /* release midi synth port */ |
429 | static int | 430 | static int |
430 | snd_seq_midisynth_unregister_port(struct snd_seq_device *dev) | 431 | snd_seq_midisynth_remove(struct device *_dev) |
431 | { | 432 | { |
433 | struct snd_seq_device *dev = to_seq_dev(_dev); | ||
432 | struct seq_midisynth_client *client; | 434 | struct seq_midisynth_client *client; |
433 | struct seq_midisynth *msynth; | 435 | struct seq_midisynth *msynth; |
434 | struct snd_card *card = dev->card; | 436 | struct snd_card *card = dev->card; |
@@ -457,24 +459,14 @@ snd_seq_midisynth_unregister_port(struct snd_seq_device *dev) | |||
457 | return 0; | 459 | return 0; |
458 | } | 460 | } |
459 | 461 | ||
462 | static struct snd_seq_driver seq_midisynth_driver = { | ||
463 | .driver = { | ||
464 | .name = KBUILD_MODNAME, | ||
465 | .probe = snd_seq_midisynth_probe, | ||
466 | .remove = snd_seq_midisynth_remove, | ||
467 | }, | ||
468 | .id = SNDRV_SEQ_DEV_ID_MIDISYNTH, | ||
469 | .argsize = 0, | ||
470 | }; | ||
460 | 471 | ||
461 | static int __init alsa_seq_midi_init(void) | 472 | module_snd_seq_driver(seq_midisynth_driver); |
462 | { | ||
463 | static struct snd_seq_dev_ops ops = { | ||
464 | snd_seq_midisynth_register_port, | ||
465 | snd_seq_midisynth_unregister_port, | ||
466 | }; | ||
467 | memset(&synths, 0, sizeof(synths)); | ||
468 | snd_seq_autoload_lock(); | ||
469 | snd_seq_device_register_driver(SNDRV_SEQ_DEV_ID_MIDISYNTH, &ops, 0); | ||
470 | snd_seq_autoload_unlock(); | ||
471 | return 0; | ||
472 | } | ||
473 | |||
474 | static void __exit alsa_seq_midi_exit(void) | ||
475 | { | ||
476 | snd_seq_device_unregister_driver(SNDRV_SEQ_DEV_ID_MIDISYNTH); | ||
477 | } | ||
478 | |||
479 | module_init(alsa_seq_midi_init) | ||
480 | module_exit(alsa_seq_midi_exit) | ||