Initialize ieee1394 early when built in
authorAndi Kleen <ak@suse.de>
Thu, 27 Jul 2006 19:54:00 +0000 (21:54 +0200)
committerStefan Richter <stefanr@s5r6.in-berlin.de>
Sun, 17 Sep 2006 17:29:34 +0000 (19:29 +0200)
This makes debugging with firescope easier.

Signed-off-by: Andi Kleen <ak@suse.de> (original patch)
Update:
 - no need for #ifdef MODULE
 - add comment in ieee1394_core, more verbose comment in ohci1394

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> (update)
drivers/ieee1394/ieee1394_core.c
drivers/ieee1394/ohci1394.c

index e4dd5bc..991c378 100644 (file)
@@ -1170,7 +1170,7 @@ static void __exit ieee1394_cleanup(void)
        unregister_chrdev_region(IEEE1394_CORE_DEV, 256);
 }
 
-module_init(ieee1394_init);
+fs_initcall(ieee1394_init); /* same as ohci1394 */
 module_exit(ieee1394_cleanup);
 
 /* Exported symbols */
index baa090d..330dcf7 100644 (file)
@@ -3719,5 +3719,7 @@ static int __init ohci1394_init(void)
        return pci_register_driver(&ohci1394_pci_driver);
 }
 
-module_init(ohci1394_init);
+/* Register before most other device drivers.
+ * Useful for remote debugging via physical DMA, e.g. using firescope. */
+fs_initcall(ohci1394_init);
 module_exit(ohci1394_cleanup);