[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. Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
bf45d9b0ac
commit
1e212f3645
43 changed files with 85 additions and 245 deletions
|
@ -895,11 +895,6 @@ static dev_link_t *bluecard_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &bluecard_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -1103,6 +1098,7 @@ static struct pcmcia_driver bluecard_driver = {
|
||||||
.name = "bluecard_cs",
|
.name = "bluecard_cs",
|
||||||
},
|
},
|
||||||
.attach = bluecard_attach,
|
.attach = bluecard_attach,
|
||||||
|
.event = bluecard_event,
|
||||||
.detach = bluecard_detach,
|
.detach = bluecard_detach,
|
||||||
.id_table = bluecard_ids,
|
.id_table = bluecard_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -696,11 +696,6 @@ static dev_link_t *bt3c_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &bt3c_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -947,6 +942,7 @@ static struct pcmcia_driver bt3c_driver = {
|
||||||
.name = "bt3c_cs",
|
.name = "bt3c_cs",
|
||||||
},
|
},
|
||||||
.attach = bt3c_attach,
|
.attach = bt3c_attach,
|
||||||
|
.event = bt3c_event,
|
||||||
.detach = bt3c_detach,
|
.detach = bt3c_detach,
|
||||||
.id_table = bt3c_ids,
|
.id_table = bt3c_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -615,11 +615,6 @@ static dev_link_t *btuart_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &btuart_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -867,6 +862,7 @@ static struct pcmcia_driver btuart_driver = {
|
||||||
.name = "btuart_cs",
|
.name = "btuart_cs",
|
||||||
},
|
},
|
||||||
.attach = btuart_attach,
|
.attach = btuart_attach,
|
||||||
|
.event = btuart_event,
|
||||||
.detach = btuart_detach,
|
.detach = btuart_detach,
|
||||||
.id_table = btuart_ids,
|
.id_table = btuart_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -594,11 +594,6 @@ static dev_link_t *dtl1_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &dtl1_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -820,6 +815,7 @@ static struct pcmcia_driver dtl1_driver = {
|
||||||
.name = "dtl1_cs",
|
.name = "dtl1_cs",
|
||||||
},
|
},
|
||||||
.attach = dtl1_attach,
|
.attach = dtl1_attach,
|
||||||
|
.event = dtl1_event,
|
||||||
.detach = dtl1_detach,
|
.detach = dtl1_detach,
|
||||||
.id_table = dtl1_ids,
|
.id_table = dtl1_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -593,11 +593,6 @@ static dev_link_t *mgslpc_attach(void)
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
|
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &mgslpc_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -3093,6 +3088,7 @@ static struct pcmcia_driver mgslpc_driver = {
|
||||||
.name = "synclink_cs",
|
.name = "synclink_cs",
|
||||||
},
|
},
|
||||||
.attach = mgslpc_attach,
|
.attach = mgslpc_attach,
|
||||||
|
.event = mgslpc_event,
|
||||||
.detach = mgslpc_detach,
|
.detach = mgslpc_detach,
|
||||||
.id_table = mgslpc_ids,
|
.id_table = mgslpc_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -134,11 +134,6 @@ static dev_link_t *ide_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &ide_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -497,6 +492,7 @@ static struct pcmcia_driver ide_cs_driver = {
|
||||||
.name = "ide-cs",
|
.name = "ide-cs",
|
||||||
},
|
},
|
||||||
.attach = ide_attach,
|
.attach = ide_attach,
|
||||||
|
.event = ide_event,
|
||||||
.detach = ide_detach,
|
.detach = ide_detach,
|
||||||
.id_table = ide_ids,
|
.id_table = ide_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -161,11 +161,6 @@ static dev_link_t *avmcs_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &avmcs_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -500,6 +495,7 @@ static struct pcmcia_driver avmcs_driver = {
|
||||||
.name = "avm_cs",
|
.name = "avm_cs",
|
||||||
},
|
},
|
||||||
.attach = avmcs_attach,
|
.attach = avmcs_attach,
|
||||||
|
.event = avmcs_event,
|
||||||
.detach = avmcs_detach,
|
.detach = avmcs_detach,
|
||||||
.id_table = avmcs_ids,
|
.id_table = avmcs_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -183,11 +183,6 @@ static dev_link_t *avma1cs_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &avma1cs_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -514,6 +509,7 @@ static struct pcmcia_driver avma1cs_driver = {
|
||||||
.name = "avma1_cs",
|
.name = "avma1_cs",
|
||||||
},
|
},
|
||||||
.attach = avma1cs_attach,
|
.attach = avma1cs_attach,
|
||||||
|
.event = avma1cs_event,
|
||||||
.detach = avma1cs_detach,
|
.detach = avma1cs_detach,
|
||||||
.id_table = avma1cs_ids,
|
.id_table = avma1cs_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -212,11 +212,6 @@ static dev_link_t *elsa_cs_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &elsa_cs_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -521,6 +516,7 @@ static struct pcmcia_driver elsa_cs_driver = {
|
||||||
.name = "elsa_cs",
|
.name = "elsa_cs",
|
||||||
},
|
},
|
||||||
.attach = elsa_cs_attach,
|
.attach = elsa_cs_attach,
|
||||||
|
.event = elsa_cs_event,
|
||||||
.detach = elsa_cs_detach,
|
.detach = elsa_cs_detach,
|
||||||
.id_table = elsa_ids,
|
.id_table = elsa_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -226,11 +226,6 @@ static dev_link_t *sedlbauer_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &sedlbauer_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -634,6 +629,7 @@ static struct pcmcia_driver sedlbauer_driver = {
|
||||||
.name = "sedlbauer_cs",
|
.name = "sedlbauer_cs",
|
||||||
},
|
},
|
||||||
.attach = sedlbauer_attach,
|
.attach = sedlbauer_attach,
|
||||||
|
.event = sedlbauer_event,
|
||||||
.detach = sedlbauer_detach,
|
.detach = sedlbauer_detach,
|
||||||
.id_table = sedlbauer_ids,
|
.id_table = sedlbauer_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -193,11 +193,6 @@ static dev_link_t *teles_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &teles_cs_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -501,6 +496,7 @@ static struct pcmcia_driver teles_cs_driver = {
|
||||||
.name = "teles_cs",
|
.name = "teles_cs",
|
||||||
},
|
},
|
||||||
.attach = teles_attach,
|
.attach = teles_attach,
|
||||||
|
.event = teles_cs_event,
|
||||||
.detach = teles_detach,
|
.detach = teles_detach,
|
||||||
.id_table = teles_ids,
|
.id_table = teles_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -800,11 +800,6 @@ static dev_link_t *pcmciamtd_attach(void)
|
||||||
|
|
||||||
/* Register with Card Services */
|
/* Register with Card Services */
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &pcmciamtd_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
DEBUG(2, "Calling RegisterClient");
|
DEBUG(2, "Calling RegisterClient");
|
||||||
|
@ -850,6 +845,7 @@ static struct pcmcia_driver pcmciamtd_driver = {
|
||||||
.name = "pcmciamtd"
|
.name = "pcmciamtd"
|
||||||
},
|
},
|
||||||
.attach = pcmciamtd_attach,
|
.attach = pcmciamtd_attach,
|
||||||
|
.event = pcmciamtd_event,
|
||||||
.detach = pcmciamtd_detach,
|
.detach = pcmciamtd_detach,
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
.id_table = pcmciamtd_ids,
|
.id_table = pcmciamtd_ids,
|
||||||
|
|
|
@ -312,11 +312,6 @@ static dev_link_t *tc574_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &tc574_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -1299,6 +1294,7 @@ static struct pcmcia_driver tc574_driver = {
|
||||||
.name = "3c574_cs",
|
.name = "3c574_cs",
|
||||||
},
|
},
|
||||||
.attach = tc574_attach,
|
.attach = tc574_attach,
|
||||||
|
.event = tc574_event,
|
||||||
.detach = tc574_detach,
|
.detach = tc574_detach,
|
||||||
.id_table = tc574_ids,
|
.id_table = tc574_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -226,11 +226,6 @@ static dev_link_t *tc589_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &tc589_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -1074,6 +1069,7 @@ static struct pcmcia_driver tc589_driver = {
|
||||||
.name = "3c589_cs",
|
.name = "3c589_cs",
|
||||||
},
|
},
|
||||||
.attach = tc589_attach,
|
.attach = tc589_attach,
|
||||||
|
.event = tc589_event,
|
||||||
.detach = tc589_detach,
|
.detach = tc589_detach,
|
||||||
.id_table = tc589_ids,
|
.id_table = tc589_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -181,11 +181,6 @@ static dev_link_t *axnet_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &axnet_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -884,6 +879,7 @@ static struct pcmcia_driver axnet_cs_driver = {
|
||||||
.name = "axnet_cs",
|
.name = "axnet_cs",
|
||||||
},
|
},
|
||||||
.attach = axnet_attach,
|
.attach = axnet_attach,
|
||||||
|
.event = axnet_event,
|
||||||
.detach = axnet_detach,
|
.detach = axnet_detach,
|
||||||
.id_table = axnet_ids,
|
.id_table = axnet_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -200,11 +200,6 @@ static dev_link_t *com20020_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &com20020_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -495,6 +490,7 @@ static struct pcmcia_driver com20020_cs_driver = {
|
||||||
.name = "com20020_cs",
|
.name = "com20020_cs",
|
||||||
},
|
},
|
||||||
.attach = com20020_attach,
|
.attach = com20020_attach,
|
||||||
|
.event = com20020_event,
|
||||||
.detach = com20020_detach,
|
.detach = com20020_detach,
|
||||||
.id_table = com20020_ids,
|
.id_table = com20020_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -288,11 +288,6 @@ static dev_link_t *fmvj18x_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &fmvj18x_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -797,6 +792,7 @@ static struct pcmcia_driver fmvj18x_cs_driver = {
|
||||||
.name = "fmvj18x_cs",
|
.name = "fmvj18x_cs",
|
||||||
},
|
},
|
||||||
.attach = fmvj18x_attach,
|
.attach = fmvj18x_attach,
|
||||||
|
.event = fmvj18x_event,
|
||||||
.detach = fmvj18x_detach,
|
.detach = fmvj18x_detach,
|
||||||
.id_table = fmvj18x_ids,
|
.id_table = fmvj18x_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -190,11 +190,6 @@ static dev_link_t *ibmtr_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &ibmtr_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -521,6 +516,7 @@ static struct pcmcia_driver ibmtr_cs_driver = {
|
||||||
.name = "ibmtr_cs",
|
.name = "ibmtr_cs",
|
||||||
},
|
},
|
||||||
.attach = ibmtr_attach,
|
.attach = ibmtr_attach,
|
||||||
|
.event = ibmtr_event,
|
||||||
.detach = ibmtr_detach,
|
.detach = ibmtr_detach,
|
||||||
.id_table = ibmtr_ids,
|
.id_table = ibmtr_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -502,11 +502,6 @@ static dev_link_t *nmclan_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &nmclan_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -1688,6 +1683,7 @@ static struct pcmcia_driver nmclan_cs_driver = {
|
||||||
.name = "nmclan_cs",
|
.name = "nmclan_cs",
|
||||||
},
|
},
|
||||||
.attach = nmclan_attach,
|
.attach = nmclan_attach,
|
||||||
|
.event = nmclan_event,
|
||||||
.detach = nmclan_detach,
|
.detach = nmclan_detach,
|
||||||
.id_table = nmclan_ids,
|
.id_table = nmclan_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -276,11 +276,6 @@ static dev_link_t *pcnet_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &pcnet_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -1844,6 +1839,7 @@ static struct pcmcia_driver pcnet_driver = {
|
||||||
.name = "pcnet_cs",
|
.name = "pcnet_cs",
|
||||||
},
|
},
|
||||||
.attach = pcnet_attach,
|
.attach = pcnet_attach,
|
||||||
|
.event = pcnet_event,
|
||||||
.detach = pcnet_detach,
|
.detach = pcnet_detach,
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
.id_table = pcnet_ids,
|
.id_table = pcnet_ids,
|
||||||
|
|
|
@ -370,10 +370,6 @@ static dev_link_t *smc91c92_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask = CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &smc91c92_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -2365,6 +2361,7 @@ static struct pcmcia_driver smc91c92_cs_driver = {
|
||||||
.name = "smc91c92_cs",
|
.name = "smc91c92_cs",
|
||||||
},
|
},
|
||||||
.attach = smc91c92_attach,
|
.attach = smc91c92_attach,
|
||||||
|
.event = smc91c92_event,
|
||||||
.detach = smc91c92_detach,
|
.detach = smc91c92_detach,
|
||||||
.id_table = smc91c92_ids,
|
.id_table = smc91c92_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -619,11 +619,6 @@ xirc2ps_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &xirc2ps_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
if ((err = pcmcia_register_client(&link->handle, &client_reg))) {
|
if ((err = pcmcia_register_client(&link->handle, &client_reg))) {
|
||||||
|
@ -2016,6 +2011,7 @@ static struct pcmcia_driver xirc2ps_cs_driver = {
|
||||||
.name = "xirc2ps_cs",
|
.name = "xirc2ps_cs",
|
||||||
},
|
},
|
||||||
.attach = xirc2ps_attach,
|
.attach = xirc2ps_attach,
|
||||||
|
.event = xirc2ps_event,
|
||||||
.detach = xirc2ps_detach,
|
.detach = xirc2ps_detach,
|
||||||
.id_table = xirc2ps_ids,
|
.id_table = xirc2ps_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -210,11 +210,6 @@ static dev_link_t *airo_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &airo_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -574,6 +569,7 @@ static struct pcmcia_driver airo_driver = {
|
||||||
.name = "airo_cs",
|
.name = "airo_cs",
|
||||||
},
|
},
|
||||||
.attach = airo_attach,
|
.attach = airo_attach,
|
||||||
|
.event = airo_event,
|
||||||
.detach = airo_detach,
|
.detach = airo_detach,
|
||||||
.id_table = airo_ids,
|
.id_table = airo_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -218,11 +218,6 @@ static dev_link_t *atmel_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &atmel_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -668,12 +663,13 @@ static struct pcmcia_device_id atmel_ids[] = {
|
||||||
MODULE_DEVICE_TABLE(pcmcia, atmel_ids);
|
MODULE_DEVICE_TABLE(pcmcia, atmel_ids);
|
||||||
|
|
||||||
static struct pcmcia_driver atmel_driver = {
|
static struct pcmcia_driver atmel_driver = {
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
.drv = {
|
.drv = {
|
||||||
.name = "atmel_cs",
|
.name = "atmel_cs",
|
||||||
},
|
},
|
||||||
.attach = atmel_attach,
|
.attach = atmel_attach,
|
||||||
.detach = atmel_detach,
|
.event = atmel_event,
|
||||||
|
.detach = atmel_detach,
|
||||||
.id_table = atmel_ids,
|
.id_table = atmel_ids,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -491,11 +491,6 @@ static dev_link_t *netwave_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &netwave_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -1680,6 +1675,7 @@ static struct pcmcia_driver netwave_driver = {
|
||||||
.name = "netwave_cs",
|
.name = "netwave_cs",
|
||||||
},
|
},
|
||||||
.attach = netwave_attach,
|
.attach = netwave_attach,
|
||||||
|
.event = netwave_event,
|
||||||
.detach = netwave_detach,
|
.detach = netwave_detach,
|
||||||
.id_table = netwave_ids,
|
.id_table = netwave_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -186,11 +186,6 @@ orinoco_cs_attach(void)
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
|
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &orinoco_cs_event;
|
|
||||||
client_reg.Version = 0x0210; /* FIXME: what does this mean? */
|
client_reg.Version = 0x0210; /* FIXME: what does this mean? */
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -664,6 +659,7 @@ static struct pcmcia_driver orinoco_driver = {
|
||||||
.name = DRIVER_NAME,
|
.name = DRIVER_NAME,
|
||||||
},
|
},
|
||||||
.attach = orinoco_cs_attach,
|
.attach = orinoco_cs_attach,
|
||||||
|
.event = orinoco_cs_event,
|
||||||
.detach = orinoco_cs_detach,
|
.detach = orinoco_cs_detach,
|
||||||
.id_table = orinoco_cs_ids,
|
.id_table = orinoco_cs_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -393,11 +393,6 @@ static dev_link_t *ray_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &ray_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -2916,6 +2911,7 @@ static struct pcmcia_driver ray_driver = {
|
||||||
.name = "ray_cs",
|
.name = "ray_cs",
|
||||||
},
|
},
|
||||||
.attach = ray_attach,
|
.attach = ray_attach,
|
||||||
|
.event = ray_event,
|
||||||
.detach = ray_detach,
|
.detach = ray_detach,
|
||||||
.id_table = ray_ids,
|
.id_table = ray_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -4684,12 +4684,6 @@ wavelan_attach(void)
|
||||||
|
|
||||||
/* Register with Card Services */
|
/* Register with Card Services */
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_REGISTRATION_COMPLETE |
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &wavelan_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -4904,6 +4898,7 @@ static struct pcmcia_driver wavelan_driver = {
|
||||||
.name = "wavelan_cs",
|
.name = "wavelan_cs",
|
||||||
},
|
},
|
||||||
.attach = wavelan_attach,
|
.attach = wavelan_attach,
|
||||||
|
.event = wavelan_event,
|
||||||
.detach = wavelan_detach,
|
.detach = wavelan_detach,
|
||||||
.id_table = wavelan_ids,
|
.id_table = wavelan_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -2005,13 +2005,6 @@ static dev_link_t *wl3501_attach(void)
|
||||||
link->next = wl3501_dev_list;
|
link->next = wl3501_dev_list;
|
||||||
wl3501_dev_list = link;
|
wl3501_dev_list = link;
|
||||||
client_reg.dev_info = &wl3501_dev_info;
|
client_reg.dev_info = &wl3501_dev_info;
|
||||||
client_reg.EventMask = CS_EVENT_CARD_INSERTION |
|
|
||||||
CS_EVENT_RESET_PHYSICAL |
|
|
||||||
CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_PM_SUSPEND |
|
|
||||||
CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = wl3501_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -2246,12 +2239,13 @@ static struct pcmcia_device_id wl3501_ids[] = {
|
||||||
MODULE_DEVICE_TABLE(pcmcia, wl3501_ids);
|
MODULE_DEVICE_TABLE(pcmcia, wl3501_ids);
|
||||||
|
|
||||||
static struct pcmcia_driver wl3501_driver = {
|
static struct pcmcia_driver wl3501_driver = {
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
.drv = {
|
.drv = {
|
||||||
.name = "wl3501_cs",
|
.name = "wl3501_cs",
|
||||||
},
|
},
|
||||||
.attach = wl3501_attach,
|
.attach = wl3501_attach,
|
||||||
.detach = wl3501_detach,
|
.event = wl3501_event,
|
||||||
|
.detach = wl3501_detach,
|
||||||
.id_table = wl3501_ids,
|
.id_table = wl3501_ids,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -133,11 +133,6 @@ static dev_link_t *parport_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &parport_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -386,6 +381,7 @@ static struct pcmcia_driver parport_cs_driver = {
|
||||||
.name = "parport_cs",
|
.name = "parport_cs",
|
||||||
},
|
},
|
||||||
.attach = parport_attach,
|
.attach = parport_attach,
|
||||||
|
.event = parport_event,
|
||||||
.detach = parport_detach,
|
.detach = parport_detach,
|
||||||
.id_table = parport_ids,
|
.id_table = parport_ids,
|
||||||
|
|
||||||
|
|
|
@ -114,9 +114,6 @@ static inline void cs_socket_put(struct pcmcia_socket *skt)
|
||||||
#define CHECK_ERASEQ(q) \
|
#define CHECK_ERASEQ(q) \
|
||||||
(((q) == NULL) || ((q)->eraseq_magic != ERASEQ_MAGIC))
|
(((q) == NULL) || ((q)->eraseq_magic != ERASEQ_MAGIC))
|
||||||
|
|
||||||
#define EVENT(h, e, p) \
|
|
||||||
((h)->event_handler((e), (p), &(h)->event_callback_args))
|
|
||||||
|
|
||||||
/* In cardbus.c */
|
/* In cardbus.c */
|
||||||
int cb_alloc(struct pcmcia_socket *s);
|
int cb_alloc(struct pcmcia_socket *s);
|
||||||
void cb_free(struct pcmcia_socket *s);
|
void cb_free(struct pcmcia_socket *s);
|
||||||
|
|
|
@ -207,6 +207,10 @@ static void pcmcia_check_driver(struct pcmcia_driver *p_drv)
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
u32 hash;
|
u32 hash;
|
||||||
|
|
||||||
|
if (!p_drv->attach || !p_drv->event || !p_drv->detach)
|
||||||
|
printk(KERN_DEBUG "pcmcia: %s does misses a callback function",
|
||||||
|
p_drv->drv.name);
|
||||||
|
|
||||||
while (did && did->match_flags) {
|
while (did && did->match_flags) {
|
||||||
for (i=0; i<4; i++) {
|
for (i=0; i<4; i++) {
|
||||||
if (!did->prod_id[i])
|
if (!did->prod_id[i])
|
||||||
|
@ -914,6 +918,7 @@ struct send_event_data {
|
||||||
static int send_event_callback(struct device *dev, void * _data)
|
static int send_event_callback(struct device *dev, void * _data)
|
||||||
{
|
{
|
||||||
struct pcmcia_device *p_dev = to_pcmcia_dev(dev);
|
struct pcmcia_device *p_dev = to_pcmcia_dev(dev);
|
||||||
|
struct pcmcia_driver *p_drv;
|
||||||
struct send_event_data *data = _data;
|
struct send_event_data *data = _data;
|
||||||
|
|
||||||
/* we get called for all sockets, but may only pass the event
|
/* we get called for all sockets, but may only pass the event
|
||||||
|
@ -921,11 +926,16 @@ static int send_event_callback(struct device *dev, void * _data)
|
||||||
if (p_dev->socket != data->skt)
|
if (p_dev->socket != data->skt)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
p_drv = to_pcmcia_drv(p_dev->dev.driver);
|
||||||
|
if (!p_drv)
|
||||||
|
return 0;
|
||||||
|
|
||||||
if (p_dev->client.state & (CLIENT_UNBOUND|CLIENT_STALE))
|
if (p_dev->client.state & (CLIENT_UNBOUND|CLIENT_STALE))
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
if (p_dev->client.EventMask & data->event)
|
if (p_drv->event)
|
||||||
return EVENT(&p_dev->client, data->event, data->priority);
|
return p_drv->event(data->event, data->priority,
|
||||||
|
&p_dev->event_callback_args);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -992,6 +1002,7 @@ int pcmcia_register_client(client_handle_t *handle, client_reg_t *req)
|
||||||
client_t *client = NULL;
|
client_t *client = NULL;
|
||||||
struct pcmcia_socket *s = NULL;
|
struct pcmcia_socket *s = NULL;
|
||||||
struct pcmcia_device *p_dev = NULL;
|
struct pcmcia_device *p_dev = NULL;
|
||||||
|
struct pcmcia_driver *p_drv = NULL;
|
||||||
|
|
||||||
/* Look for unbound client with matching dev_info */
|
/* Look for unbound client with matching dev_info */
|
||||||
down_read(&pcmcia_socket_list_rwsem);
|
down_read(&pcmcia_socket_list_rwsem);
|
||||||
|
@ -1006,7 +1017,6 @@ int pcmcia_register_client(client_handle_t *handle, client_reg_t *req)
|
||||||
continue;
|
continue;
|
||||||
spin_lock_irqsave(&pcmcia_dev_list_lock, flags);
|
spin_lock_irqsave(&pcmcia_dev_list_lock, flags);
|
||||||
list_for_each_entry(p_dev, &s->devices_list, socket_device_list) {
|
list_for_each_entry(p_dev, &s->devices_list, socket_device_list) {
|
||||||
struct pcmcia_driver *p_drv;
|
|
||||||
p_dev = pcmcia_get_dev(p_dev);
|
p_dev = pcmcia_get_dev(p_dev);
|
||||||
if (!p_dev)
|
if (!p_dev)
|
||||||
continue;
|
continue;
|
||||||
|
@ -1036,10 +1046,9 @@ int pcmcia_register_client(client_handle_t *handle, client_reg_t *req)
|
||||||
*handle = client;
|
*handle = client;
|
||||||
client->state &= ~CLIENT_UNBOUND;
|
client->state &= ~CLIENT_UNBOUND;
|
||||||
client->Socket = s;
|
client->Socket = s;
|
||||||
client->EventMask = req->EventMask;
|
p_dev->event_callback_args = req->event_callback_args;
|
||||||
client->event_handler = req->event_handler;
|
p_dev->event_callback_args.client_handle = client;
|
||||||
client->event_callback_args = req->event_callback_args;
|
|
||||||
client->event_callback_args.client_handle = client;
|
|
||||||
|
|
||||||
if (s->state & SOCKET_CARDBUS)
|
if (s->state & SOCKET_CARDBUS)
|
||||||
client->state |= CLIENT_CARDBUS;
|
client->state |= CLIENT_CARDBUS;
|
||||||
|
@ -1061,12 +1070,12 @@ int pcmcia_register_client(client_handle_t *handle, client_reg_t *req)
|
||||||
|
|
||||||
ds_dbg(1, "register_client(): client 0x%p, dev %s\n",
|
ds_dbg(1, "register_client(): client 0x%p, dev %s\n",
|
||||||
client, p_dev->dev.bus_id);
|
client, p_dev->dev.bus_id);
|
||||||
if (client->EventMask & CS_EVENT_REGISTRATION_COMPLETE)
|
|
||||||
EVENT(client, CS_EVENT_REGISTRATION_COMPLETE, CS_EVENT_PRI_LOW);
|
|
||||||
|
|
||||||
if ((s->state & (SOCKET_PRESENT|SOCKET_CARDBUS)) == SOCKET_PRESENT) {
|
if ((s->state & (SOCKET_PRESENT|SOCKET_CARDBUS)) == SOCKET_PRESENT) {
|
||||||
if (client->EventMask & CS_EVENT_CARD_INSERTION)
|
if (p_drv->event)
|
||||||
EVENT(client, CS_EVENT_CARD_INSERTION, CS_EVENT_PRI_LOW);
|
p_drv->event(CS_EVENT_CARD_INSERTION, CS_EVENT_PRI_LOW,
|
||||||
|
&p_dev->event_callback_args);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return CS_SUCCESS;
|
return CS_SUCCESS;
|
||||||
|
@ -1132,7 +1141,6 @@ int pcmcia_deregister_client(client_handle_t handle)
|
||||||
pcmcia_put_dev(p_dev);
|
pcmcia_put_dev(p_dev);
|
||||||
} else {
|
} else {
|
||||||
handle->state = CLIENT_UNBOUND;
|
handle->state = CLIENT_UNBOUND;
|
||||||
handle->event_handler = NULL;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return CS_SUCCESS;
|
return CS_SUCCESS;
|
||||||
|
|
|
@ -134,11 +134,6 @@ static dev_link_t *aha152x_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.event_handler = &aha152x_event;
|
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_RESET_REQUEST | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -334,6 +329,7 @@ static struct pcmcia_driver aha152x_cs_driver = {
|
||||||
.name = "aha152x_cs",
|
.name = "aha152x_cs",
|
||||||
},
|
},
|
||||||
.attach = aha152x_attach,
|
.attach = aha152x_attach,
|
||||||
|
.event = aha152x_event,
|
||||||
.detach = aha152x_detach,
|
.detach = aha152x_detach,
|
||||||
.id_table = aha152x_ids,
|
.id_table = aha152x_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -120,11 +120,6 @@ static dev_link_t *fdomain_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.event_handler = &fdomain_event;
|
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_RESET_REQUEST | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -314,6 +309,7 @@ static struct pcmcia_driver fdomain_cs_driver = {
|
||||||
.name = "fdomain_cs",
|
.name = "fdomain_cs",
|
||||||
},
|
},
|
||||||
.attach = fdomain_attach,
|
.attach = fdomain_attach,
|
||||||
|
.event = fdomain_event,
|
||||||
.detach = fdomain_detach,
|
.detach = fdomain_detach,
|
||||||
.id_table = fdomain_ids,
|
.id_table = fdomain_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -1642,11 +1642,6 @@ static dev_link_t *nsp_cs_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME ;
|
|
||||||
client_reg.event_handler = &nsp_cs_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -2138,12 +2133,13 @@ static struct pcmcia_device_id nsp_cs_ids[] = {
|
||||||
MODULE_DEVICE_TABLE(pcmcia, nsp_cs_ids);
|
MODULE_DEVICE_TABLE(pcmcia, nsp_cs_ids);
|
||||||
|
|
||||||
static struct pcmcia_driver nsp_driver = {
|
static struct pcmcia_driver nsp_driver = {
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
.drv = {
|
.drv = {
|
||||||
.name = "nsp_cs",
|
.name = "nsp_cs",
|
||||||
},
|
},
|
||||||
.attach = nsp_cs_attach,
|
.attach = nsp_cs_attach,
|
||||||
.detach = nsp_cs_detach,
|
.event = nsp_cs_event,
|
||||||
|
.detach = nsp_cs_detach,
|
||||||
.id_table = nsp_cs_ids,
|
.id_table = nsp_cs_ids,
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -194,8 +194,6 @@ static dev_link_t *qlogic_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.event_handler = &qlogic_event;
|
|
||||||
client_reg.EventMask = CS_EVENT_RESET_REQUEST | CS_EVENT_CARD_RESET | CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL | CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -423,6 +421,7 @@ static struct pcmcia_driver qlogic_cs_driver = {
|
||||||
.name = "qlogic_cs",
|
.name = "qlogic_cs",
|
||||||
},
|
},
|
||||||
.attach = qlogic_attach,
|
.attach = qlogic_attach,
|
||||||
|
.event = qlogic_event,
|
||||||
.detach = qlogic_detach,
|
.detach = qlogic_detach,
|
||||||
.id_table = qlogic_ids,
|
.id_table = qlogic_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -979,10 +979,6 @@ SYM53C500_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.event_handler = &SYM53C500_event;
|
|
||||||
client_reg.EventMask = CS_EVENT_RESET_REQUEST | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -1013,6 +1009,7 @@ static struct pcmcia_driver sym53c500_cs_driver = {
|
||||||
.name = "sym53c500_cs",
|
.name = "sym53c500_cs",
|
||||||
},
|
},
|
||||||
.attach = SYM53C500_attach,
|
.attach = SYM53C500_attach,
|
||||||
|
.event = SYM53C500_event,
|
||||||
.detach = SYM53C500_detach,
|
.detach = SYM53C500_detach,
|
||||||
.id_table = sym53c500_ids,
|
.id_table = sym53c500_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -232,11 +232,6 @@ static dev_link_t *serial_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &serial_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -883,6 +878,7 @@ static struct pcmcia_driver serial_cs_driver = {
|
||||||
.name = "serial_cs",
|
.name = "serial_cs",
|
||||||
},
|
},
|
||||||
.attach = serial_attach,
|
.attach = serial_attach,
|
||||||
|
.event = serial_event,
|
||||||
.detach = serial_detach,
|
.detach = serial_detach,
|
||||||
.id_table = serial_ids,
|
.id_table = serial_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -69,11 +69,6 @@ static dev_link_t *ixj_attach(void)
|
||||||
link->next = dev_list;
|
link->next = dev_list;
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
|
|
||||||
CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &ixj_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -307,6 +302,7 @@ static struct pcmcia_driver ixj_driver = {
|
||||||
.name = "ixj_cs",
|
.name = "ixj_cs",
|
||||||
},
|
},
|
||||||
.attach = ixj_attach,
|
.attach = ixj_attach,
|
||||||
|
.event = ixj_event,
|
||||||
.detach = ixj_detach,
|
.detach = ixj_detach,
|
||||||
.id_table = ixj_ids,
|
.id_table = ixj_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -389,11 +389,6 @@ static dev_link_t *sl811_cs_attach(void)
|
||||||
dev_list = link;
|
dev_list = link;
|
||||||
client_reg.dev_info = (dev_info_t *) &driver_name;
|
client_reg.dev_info = (dev_info_t *) &driver_name;
|
||||||
client_reg.Attributes = INFO_IO_CLIENT | INFO_CARD_SHARE;
|
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 |
|
|
||||||
CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
|
|
||||||
client_reg.event_handler = &sl811_cs_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
ret = pcmcia_register_client(&link->handle, &client_reg);
|
ret = pcmcia_register_client(&link->handle, &client_reg);
|
||||||
|
@ -418,6 +413,7 @@ static struct pcmcia_driver sl811_cs_driver = {
|
||||||
.name = (char *)driver_name,
|
.name = (char *)driver_name,
|
||||||
},
|
},
|
||||||
.attach = sl811_cs_attach,
|
.attach = sl811_cs_attach,
|
||||||
|
.event = sl811_cs_event,
|
||||||
.detach = sl811_cs_detach,
|
.detach = sl811_cs_detach,
|
||||||
.id_table = sl811_ids,
|
.id_table = sl811_ids,
|
||||||
};
|
};
|
||||||
|
|
|
@ -133,6 +133,8 @@ struct pcmcia_socket;
|
||||||
|
|
||||||
struct pcmcia_driver {
|
struct pcmcia_driver {
|
||||||
dev_link_t *(*attach)(void);
|
dev_link_t *(*attach)(void);
|
||||||
|
int (*event) (event_t event, int priority,
|
||||||
|
event_callback_args_t *);
|
||||||
void (*detach)(dev_link_t *);
|
void (*detach)(dev_link_t *);
|
||||||
struct module *owner;
|
struct module *owner;
|
||||||
struct pcmcia_device_id *id_table;
|
struct pcmcia_device_id *id_table;
|
||||||
|
@ -159,15 +161,13 @@ struct pcmcia_device {
|
||||||
/* deprecated, a cleaned up version will be moved into this
|
/* deprecated, a cleaned up version will be moved into this
|
||||||
struct soon */
|
struct soon */
|
||||||
dev_link_t *instance;
|
dev_link_t *instance;
|
||||||
|
event_callback_args_t event_callback_args;
|
||||||
|
|
||||||
struct client_t {
|
struct client_t {
|
||||||
u_short client_magic;
|
u_short client_magic;
|
||||||
struct pcmcia_socket *Socket;
|
struct pcmcia_socket *Socket;
|
||||||
u_char Function;
|
u_char Function;
|
||||||
u_int state;
|
u_int state;
|
||||||
event_t EventMask;
|
|
||||||
int (*event_handler) (event_t event, int priority,
|
|
||||||
event_callback_args_t *);
|
|
||||||
event_callback_args_t event_callback_args;
|
|
||||||
} client;
|
} client;
|
||||||
|
|
||||||
/* information about this device */
|
/* information about this device */
|
||||||
|
|
|
@ -171,14 +171,6 @@ static dev_link_t *snd_pdacf_attach(void)
|
||||||
|
|
||||||
/* Register with Card Services */
|
/* Register with Card Services */
|
||||||
client_reg.dev_info = &dev_info;
|
client_reg.dev_info = &dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL
|
|
||||||
#ifdef CONFIG_PM
|
|
||||||
| CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET
|
|
||||||
| CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME
|
|
||||||
#endif
|
|
||||||
;
|
|
||||||
client_reg.event_handler = &pdacf_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -387,12 +379,13 @@ static struct pcmcia_device_id snd_pdacf_ids[] = {
|
||||||
MODULE_DEVICE_TABLE(pcmcia, snd_pdacf_ids);
|
MODULE_DEVICE_TABLE(pcmcia, snd_pdacf_ids);
|
||||||
|
|
||||||
static struct pcmcia_driver pdacf_cs_driver = {
|
static struct pcmcia_driver pdacf_cs_driver = {
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
.drv = {
|
.drv = {
|
||||||
.name = "snd-pdaudiocf",
|
.name = "snd-pdaudiocf",
|
||||||
},
|
},
|
||||||
.attach = snd_pdacf_attach,
|
.attach = snd_pdacf_attach,
|
||||||
.detach = snd_pdacf_detach,
|
.event = pdacf_event,
|
||||||
|
.detach = snd_pdacf_detach,
|
||||||
.id_table = snd_pdacf_ids,
|
.id_table = snd_pdacf_ids,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,6 @@ MODULE_LICENSE("GPL");
|
||||||
* prototypes
|
* prototypes
|
||||||
*/
|
*/
|
||||||
static void vxpocket_config(dev_link_t *link);
|
static void vxpocket_config(dev_link_t *link);
|
||||||
static int vxpocket_event(event_t event, int priority, event_callback_args_t *args);
|
|
||||||
|
|
||||||
|
|
||||||
static void vxpocket_release(dev_link_t *link)
|
static void vxpocket_release(dev_link_t *link)
|
||||||
|
@ -169,14 +168,6 @@ dev_link_t *snd_vxpocket_attach(struct snd_vxp_entry *hw)
|
||||||
/* Register with Card Services */
|
/* Register with Card Services */
|
||||||
memset(&client_reg, 0, sizeof(client_reg));
|
memset(&client_reg, 0, sizeof(client_reg));
|
||||||
client_reg.dev_info = hw->dev_info;
|
client_reg.dev_info = hw->dev_info;
|
||||||
client_reg.EventMask =
|
|
||||||
CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL
|
|
||||||
#ifdef CONFIG_PM
|
|
||||||
| CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET
|
|
||||||
| CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME
|
|
||||||
#endif
|
|
||||||
;
|
|
||||||
client_reg.event_handler = &vxpocket_event;
|
|
||||||
client_reg.Version = 0x0210;
|
client_reg.Version = 0x0210;
|
||||||
client_reg.event_callback_args.client_data = link;
|
client_reg.event_callback_args.client_data = link;
|
||||||
|
|
||||||
|
@ -321,7 +312,7 @@ static void vxpocket_config(dev_link_t *link)
|
||||||
/*
|
/*
|
||||||
* event callback
|
* event callback
|
||||||
*/
|
*/
|
||||||
static int vxpocket_event(event_t event, int priority, event_callback_args_t *args)
|
int vxpocket_event(event_t event, int priority, event_callback_args_t *args)
|
||||||
{
|
{
|
||||||
dev_link_t *link = args->client_data;
|
dev_link_t *link = args->client_data;
|
||||||
vx_core_t *chip = link->priv;
|
vx_core_t *chip = link->priv;
|
||||||
|
@ -380,4 +371,5 @@ static int vxpocket_event(event_t event, int priority, event_callback_args_t *ar
|
||||||
*/
|
*/
|
||||||
EXPORT_SYMBOL(snd_vxpocket_ops);
|
EXPORT_SYMBOL(snd_vxpocket_ops);
|
||||||
EXPORT_SYMBOL(snd_vxpocket_attach);
|
EXPORT_SYMBOL(snd_vxpocket_attach);
|
||||||
|
EXPORT_SYMBOL(vxpocket_event);
|
||||||
EXPORT_SYMBOL(snd_vxpocket_detach);
|
EXPORT_SYMBOL(snd_vxpocket_detach);
|
||||||
|
|
Loading…
Reference in a new issue