Commit 18e030b5 authored by Christoph Hellwig's avatar Christoph Hellwig Committed by James Bottomley

[PATCH] update qlogic and fdomain drivers to use pcmcia_register_driver

parent 07171f64
......@@ -379,24 +379,25 @@ static int fdomain_event(event_t event, int priority,
return 0;
} /* fdomain_event */
/*====================================================================*/
static int __init init_fdomain_cs(void) {
servinfo_t serv;
DEBUG(0, "%s\n", version);
CardServices(GetCardServicesInfo, &serv);
if (serv.Revision != CS_RELEASE_CODE) {
printk(KERN_NOTICE "fdomain_cs: Card Services release "
"does not match!\n");
return -1;
}
register_pccard_driver(&dev_info, &fdomain_attach, &fdomain_detach);
return 0;
static struct pcmcia_driver fdomain_cs_driver = {
.owner = THIS_MODULE,
.drv = {
.name = "fdomain_cs",
},
.attach = fdomain_attach,
.detach = fdomain_detach,
};
static int __init init_fdomain_cs(void)
{
return pcmcia_register_driver(&fdomain_cs_driver);
}
static void __exit exit_fdomain_cs(void) {
DEBUG(0, "fdomain_cs: unloading\n");
unregister_pccard_driver(&dev_info);
static void __exit exit_fdomain_cs(void)
{
pcmcia_unregister_driver(&fdomain_cs_driver);
/* XXX: this really needs to move into generic code.. */
while (dev_list != NULL)
fdomain_detach(dev_list);
}
......
......@@ -397,25 +397,26 @@ static int qlogic_event(event_t event, int priority, event_callback_args_t * arg
return 0;
} /* qlogic_event */
/*====================================================================*/
static struct pcmcia_driver qlogic_cs_driver = {
.owner = THIS_MODULE,
.drv = {
.name = "qlogic_cs",
},
.attach = qlogic_attach,
.detach = qlogic_detach,
};
static int __init init_qlogic_cs(void)
{
servinfo_t serv;
DEBUG(0, "%s\n", version);
CardServices(GetCardServicesInfo, &serv);
if (serv.Revision != CS_RELEASE_CODE) {
printk(KERN_NOTICE "qlogic_cs: Card Services release " "does not match!\n");
return -1;
}
register_pccard_driver(&dev_info, &qlogic_attach, &qlogic_detach);
return 0;
return pcmcia_register_driver(&qlogic_cs_driver);
}
static void __exit exit_qlogic_cs(void)
{
DEBUG(0, "qlogic_cs: unloading\n");
unregister_pccard_driver(&dev_info);
pcmcia_unregister_driver(&qlogic_cs_driver);
/* XXX: this really needs to move into generic code.. */
while (dev_list != NULL)
qlogic_detach(dev_list);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment