Messages in this thread | | | Date | Mon, 31 Jan 2000 14:48:04 -0600 (CST) | From | Jeff Garzik <> | Subject | Re: [linux-usb] __initcall diff, version 2 |
| |
On Mon, 31 Jan 2000, Linus Torvalds wrote: > However, instead of using "__initcall" directly, I would suggest using > "module_init()" and "module_exit()". Which will do the right things for > drivers whether that driver is compiled as a module or not (basically, a > good driver these days should have NO code that is inside #ifdef MODULE > any more).
Adding to this, for modules which require explicit init order like fbdev, you will typically find a single ifdef:
#ifdef MODULE module_init(driver_init); #endif module_exit(driver_cleanup);
Ideally you can let Makefile link order take care of these things, but there are always special cases...
Jeff
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |