ALSA: seq: Don't compile snd_seq_device_load_drivers() for built-in
authorTakashi Iwai <tiwai@suse.de>
Wed, 11 Feb 2015 21:39:51 +0000 (22:39 +0100)
committerTakashi Iwai <tiwai@suse.de>
Thu, 12 Feb 2015 10:35:11 +0000 (11:35 +0100)
Signed-off-by: Takashi Iwai <tiwai@suse.de>
include/sound/seq_device.h
sound/core/seq/seq_device.c

index 2b5f24cc75488844cc1e18183c0482298c653923..d52433563da225ba6a32b8f7921f71f9d3b26c65 100644 (file)
@@ -67,7 +67,11 @@ struct snd_seq_dev_ops {
 /*
  * prototypes
  */
+#ifdef CONFIG_MODULES
 void snd_seq_device_load_drivers(void);
+#else
+#define snd_seq_device_load_drivers()
+#endif
 int snd_seq_device_new(struct snd_card *card, int device, char *id, int argsize, struct snd_seq_device **result);
 int snd_seq_device_register_driver(char *id, struct snd_seq_dev_ops *entry, int argsize);
 int snd_seq_device_unregister_driver(char *id);
index a752a79a8d3a08305a480a03a0d302de432dcee8..075a66c0cc6a4c36b72b33d21110aecfac438b87 100644 (file)
@@ -198,19 +198,16 @@ void snd_seq_autoload_init(void)
 #endif
 }
 EXPORT_SYMBOL(snd_seq_autoload_init);
-#else
-#define try_autoload(ops) /* NOP */
-#endif
-
 
 void snd_seq_device_load_drivers(void)
 {
-#ifdef CONFIG_MODULES
        queue_autoload_drivers();
        flush_work(&autoload_work);
-#endif
 }
 EXPORT_SYMBOL(snd_seq_device_load_drivers);
+#else
+#define try_autoload(ops) /* NOP */
+#endif
 
 /*
  * register a sequencer device