X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;ds=sidebyside;f=drivers%2Fisdn%2Fhisax%2Favma1_cs.c;h=663a0bf703b707b6fcc2c6ebfa2de1cbbd409605;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=79091cf202a5a8dfd00ad4da8a6812fc7ec63ac1;hpb=87fc8d1bb10cd459024a742c6a10961fefcef18f;p=linux-2.6.git diff --git a/drivers/isdn/hisax/avma1_cs.c b/drivers/isdn/hisax/avma1_cs.c index 79091cf20..663a0bf70 100644 --- a/drivers/isdn/hisax/avma1_cs.c +++ b/drivers/isdn/hisax/avma1_cs.c @@ -41,7 +41,7 @@ MODULE_LICENSE("GPL"); */ #ifdef PCMCIA_DEBUG static int pc_debug = PCMCIA_DEBUG; -MODULE_PARM(pc_debug, "i"); +module_param(pc_debug, int, 0); #define DEBUG(n, args...) if (pc_debug>(n)) printk(KERN_DEBUG args); static char *version = "avma1_cs.c 1.00 1998/01/23 10:00:00 (Carsten Paeth)"; @@ -53,12 +53,9 @@ static char *version = /* Parameters that can be set with 'insmod' */ -static int default_irq_list[11] = { 15, 13, 12, 11, 10, 9, 7, 5, 4, 3, -1 }; -static int irq_list[11] = { -1 }; static int isdnprot = 2; -MODULE_PARM(irq_list, "1-11i"); -MODULE_PARM(isdnprot, "1-4i"); +module_param(isdnprot, int, 0); /*====================================================================*/ @@ -143,7 +140,7 @@ static dev_link_t *avma1cs_attach(void) client_reg_t client_reg; dev_link_t *link; local_info_t *local; - int ret, i; + int ret; DEBUG(0, "avma1cs_attach()\n"); @@ -173,15 +170,8 @@ static dev_link_t *avma1cs_attach(void) link->irq.Attributes = IRQ_TYPE_EXCLUSIVE; link->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING|IRQ_FIRST_SHARED; - link->irq.IRQInfo1 = IRQ_INFO2_VALID|IRQ_LEVEL_ID; - if (irq_list[0] != -1) { - for (i = 0; i < 10 && irq_list[i] > 0; i++) - link->irq.IRQInfo2 |= 1 << irq_list[i]; - } else { - for (i = 0; i < 10 && default_irq_list[i] > 0; i++) - link->irq.IRQInfo2 |= 1 << default_irq_list[i]; - } - + link->irq.IRQInfo1 = IRQ_LEVEL_ID; + /* General socket configuration */ link->conf.Attributes = CONF_ENABLE_IRQ; link->conf.Vcc = 50; @@ -193,7 +183,6 @@ static dev_link_t *avma1cs_attach(void) link->next = dev_list; dev_list = link; client_reg.dev_info = &dev_info; - client_reg.Attributes = INFO_IO_CLIENT | INFO_CARD_SHARE; client_reg.EventMask = CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL | CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET | @@ -531,13 +520,7 @@ static int __init init_avma1_cs(void) static void __exit exit_avma1_cs(void) { pcmcia_unregister_driver(&avma1cs_driver); - - /* XXX: this really needs to move into generic code.. */ - while (dev_list != NULL) { - if (dev_list->state & DEV_CONFIG) - avma1cs_release(dev_list); - avma1cs_detach(dev_list); - } + BUG_ON(dev_list != NULL); } module_init(init_avma1_cs);