patch-2.3.99-pre4 linux/drivers/net/wan/cycx_drv.c

Next file: linux/drivers/net/wan/cycx_main.c
Previous file: linux/drivers/net/tokenring/ibmtr.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.99-pre3/linux/drivers/net/wan/cycx_drv.c linux/drivers/net/wan/cycx_drv.c
@@ -48,14 +48,8 @@
 * Aug  8, 1998	acme		Initial version.
 */
 
-#ifdef MODULE
-#ifdef MODVERSIONS
-#include <linux/modversions.h>
-#endif
+#include <linux/init.h>		/* __init */
 #include <linux/module.h>
-#else
-#define EXPORT_SYMBOL(function)
-#endif
 #include <linux/kernel.h>	/* printk(), and other useful stuff */
 #include <linux/stddef.h>	/* offsetof(), etc. */
 #include <linux/errno.h>	/* return codes */
@@ -66,12 +60,10 @@
 #include <asm/io.h>		/* read[wl], write[wl], ioremap, iounmap */
 
 #define	MOD_VERSION	0
-#define	MOD_RELEASE	5
+#define	MOD_RELEASE	6
 
-#ifdef MODULE
 MODULE_AUTHOR("Arnaldo Carvalho de Melo");
 MODULE_DESCRIPTION("Cyclom 2x Sync Card Driver");
-#endif
 
 /* Function Prototypes */
 /* Module entry points. These are called by the OS and must be public. */
@@ -129,20 +121,21 @@
  * Return:	0	Ok
  *		< 0	error.
  * Context:	process */
-#ifdef MODULE
-int init_module(void)
+
+int __init cycx_drv_init(void)
 {
 	printk(KERN_INFO "%s v%u.%u %s\n", fullname, MOD_VERSION, MOD_RELEASE,
 			 copyright);
 
 	return 0;
 }
+
 /* Module 'remove' entry point.
  * o release all remaining system resources */
-void cleanup_module(void)
+void cycx_drv_cleanup(void)
 {
 }
-#endif
+
 /* Kernel APIs */
 /* Set up adapter.
  * o detect adapter type
@@ -599,4 +592,8 @@
 
 	return crc;
 }
+
+module_init(cycx_drv_init);
+module_exit(cycx_drv_cleanup);
+
 /* End */

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)