aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide
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/ide
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/ide')
-rw-r--r--drivers/ide/legacy/ide-cs.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/drivers/ide/legacy/ide-cs.c b/drivers/ide/legacy/ide-cs.c
index 024aad616484..7ad8a95969fb 100644
--- a/drivers/ide/legacy/ide-cs.c
+++ b/drivers/ide/legacy/ide-cs.c
@@ -373,27 +373,6 @@ void ide_release(dev_link_t *link)
373 pcmcia_disable_device(link->handle); 373 pcmcia_disable_device(link->handle);
374} /* ide_release */ 374} /* ide_release */
375 375
376static int ide_suspend(struct pcmcia_device *dev)
377{
378 dev_link_t *link = dev_to_instance(dev);
379
380 link->state |= DEV_SUSPEND;
381 if (link->state & DEV_CONFIG)
382 pcmcia_release_configuration(link->handle);
383
384 return 0;
385}
386
387static int ide_resume(struct pcmcia_device *dev)
388{
389 dev_link_t *link = dev_to_instance(dev);
390
391 link->state &= ~DEV_SUSPEND;
392 if (DEV_OK(link))
393 pcmcia_request_configuration(link->handle, &link->conf);
394
395 return 0;
396}
397 376
398/*====================================================================== 377/*======================================================================
399 378
@@ -456,8 +435,6 @@ static struct pcmcia_driver ide_cs_driver = {
456 .probe = ide_attach, 435 .probe = ide_attach,
457 .remove = ide_detach, 436 .remove = ide_detach,
458 .id_table = ide_ids, 437 .id_table = ide_ids,
459 .suspend = ide_suspend,
460 .resume = ide_resume,
461}; 438};
462 439
463static int __init init_ide_cs(void) 440static int __init init_ide_cs(void)