aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/pcmcia/qlogic_stub.c
diff options
context:
space:
mode:
authorDominik Brodowski <linux@dominikbrodowski.net>2006-03-01 18:02:33 -0500
committerDominik Brodowski <linux@dominikbrodowski.net>2006-03-31 10:15:52 -0500
commit8661bb5b4af1849c1f5a4e80c4e275fd13c155d6 (patch)
treead99d85ea8d6f5c4c99b93f869bfd412994fb4ee /drivers/scsi/pcmcia/qlogic_stub.c
parent50db3fdbbc98260fb538c1cc3f8cc597ba7bffe7 (diff)
[PATCH] pcmcia: default suspend and resume handling
In all but one case, the suspend and resume functions of PCMCIA drivers contain mostly of calls to pcmcia_release_configuration() and pcmcia_request_configuration(). Therefore, move this code out of the drivers and into the core. Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/scsi/pcmcia/qlogic_stub.c')
-rw-r--r--drivers/scsi/pcmcia/qlogic_stub.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/drivers/scsi/pcmcia/qlogic_stub.c b/drivers/scsi/pcmcia/qlogic_stub.c
index 1e27059cd462..5a8da5143bd1 100644
--- a/drivers/scsi/pcmcia/qlogic_stub.c
+++ b/drivers/scsi/pcmcia/qlogic_stub.c
@@ -311,22 +311,10 @@ static void qlogic_release(dev_link_t *link)
311 311
312/*====================================================================*/ 312/*====================================================================*/
313 313
314static int qlogic_suspend(struct pcmcia_device *dev)
315{
316 dev_link_t *link = dev_to_instance(dev);
317
318 link->state |= DEV_SUSPEND;
319 if (link->state & DEV_CONFIG)
320 pcmcia_release_configuration(link->handle);
321
322 return 0;
323}
324
325static int qlogic_resume(struct pcmcia_device *dev) 314static int qlogic_resume(struct pcmcia_device *dev)
326{ 315{
327 dev_link_t *link = dev_to_instance(dev); 316 dev_link_t *link = dev_to_instance(dev);
328 317
329 link->state &= ~DEV_SUSPEND;
330 if (link->state & DEV_CONFIG) { 318 if (link->state & DEV_CONFIG) {
331 scsi_info_t *info = link->priv; 319 scsi_info_t *info = link->priv;
332 320
@@ -375,7 +363,6 @@ static struct pcmcia_driver qlogic_cs_driver = {
375 .probe = qlogic_attach, 363 .probe = qlogic_attach,
376 .remove = qlogic_detach, 364 .remove = qlogic_detach,
377 .id_table = qlogic_ids, 365 .id_table = qlogic_ids,
378 .suspend = qlogic_suspend,
379 .resume = qlogic_resume, 366 .resume = qlogic_resume,
380}; 367};
381 368