[PATCH] pcmcia: add pcmcia_disable_device

pcmcia_disable_device(struct pcmcia_device *p_dev) performs the necessary
cleanups upon device or driver removal: it calls the appropriate
pcmcia_release_* functions, and can replace (most) of the current drivers'
_release() functions.

Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
This commit is contained in:
Dominik Brodowski
2006-01-15 09:32:39 +01:00
parent 1de9cedfbd
commit 5f2a71fcb7
43 changed files with 153 additions and 401 deletions

View File

@@ -377,16 +377,8 @@ failed:
static void com20020_release(dev_link_t *link)
{
DEBUG(1,"release...\n");
DEBUG(0, "com20020_release(0x%p)\n", link);
pcmcia_release_configuration(link->handle);
pcmcia_release_io(link->handle, &link->io);
pcmcia_release_irq(link->handle, &link->irq);
link->state &= ~(DEV_CONFIG | DEV_RELEASE_PENDING);
DEBUG(0, "com20020_release(0x%p)\n", link);
pcmcia_disable_device(link->handle);
}
static int com20020_suspend(struct pcmcia_device *p_dev)