patch-2.4.0-test12 linux/drivers/isdn/avmb1/avm_cs.c

Next file: linux/drivers/isdn/avmb1/b1.c
Previous file: linux/drivers/isdn/avmb1/Makefile
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.0-test11/linux/drivers/isdn/avmb1/avm_cs.c linux/drivers/isdn/avmb1/avm_cs.c
@@ -145,9 +145,7 @@
     /* The io structure describes IO port mapping */
     link->io.NumPorts1 = 16;
     link->io.Attributes1 = IO_DATA_PATH_WIDTH_8;
-    link->io.NumPorts2 = 16;
-    link->io.Attributes2 = IO_DATA_PATH_WIDTH_16;
-    link->io.IOAddrLines = 5;
+    link->io.NumPorts2 = 0;
 
     /* Interrupt setup */
     link->irq.Attributes = IRQ_TYPE_EXCLUSIVE;
@@ -329,9 +327,10 @@
 		link->conf.ConfigIndex = cf->index;
 		link->io.BasePort1 = cf->io.win[0].base;
 		link->io.NumPorts1 = cf->io.win[0].len;
+		link->io.NumPorts2 = 0;
                 printk(KERN_INFO "avm_cs: testing i/o %#x-%#x\n",
 			link->io.BasePort1,
-		        link->io.BasePort1+link->io.NumPorts1);
+		        link->io.BasePort1+link->io.NumPorts1-1);
 		i = CardServices(RequestIO, link->handle, &link->io);
 		if (i == CS_SUCCESS) goto found_port;
 	    }
@@ -504,7 +503,7 @@
 
 /*====================================================================*/
 
-int init_module(void)
+static int __init avmcs_init(void)
 {
     servinfo_t serv;
     CardServices(GetCardServicesInfo, &serv);
@@ -517,7 +516,7 @@
     return 0;
 }
 
-void cleanup_module(void)
+static void __exit avmcs_exit(void)
 {
     unregister_pccard_driver(&dev_info);
     while (dev_list != NULL) {
@@ -526,3 +525,6 @@
 	avmcs_detach(dev_list);
     }
 }
+
+module_init(avmcs_init);
+module_exit(avmcs_exit);

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