Patch for current Linux kernel - pcmcia events

Pavel Roskin proski
Tue Jul 12 14:06:25 PDT 2005


Hello!

I'm posting this patch to help those trying to keep up with the Linux
kernel.  The event function in PCMCIA drivers should be moved from
client_reg to pcmcia_driver.

I don't think it should be applied to CVS yet.  PCMCIA is under heavy
development, and further API changes are expected.  From the Linux git
log (commit 1e212f3645a6b355de8c43a23376bc0e2ac49a63):

[PATCH] pcmcia: move event handler
    
Move the "event handler" to struct pcmcia_driver -- the unified event
handler will disappear really soon, but switching it to struct
pcmcia_driver in the meantime allows for better "step-by-step" patches.

So let's wait until 2.6.13 before we put more ifdefs into the hostap
code.  In the meantime, use this patch:

--- driver/modules/hostap_cs.c
+++ driver/modules/hostap_cs.c
@@ -532,7 +532,6 @@ static dev_link_t *prism2_attach(void)
 		CS_EVENT_CARD_REMOVAL |
 		CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
 		CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
-	client_reg.event_handler = &prism2_event;
 	client_reg.Version = 0x0210;
 	client_reg.event_callback_args.client_data = link;
 	ret = pcmcia_register_client(&link->handle, &client_reg);
@@ -916,6 +915,7 @@ static struct pcmcia_driver hostap_drive
 	},
 	.attach		= prism2_attach,
 	.detach		= prism2_detach,
+	.event		= prism2_event,
 	.owner		= THIS_MODULE,
 };
 


-- 
Regards,
Pavel Roskin





More information about the Hostap mailing list