Skip to content

Commit

Permalink
[PATCH] yenta: free_irq() on suspend.
Browse files Browse the repository at this point in the history
Resume doesn't seem to work without.

Signed-off-by: Daniel Ritz <daniel.ritz@gmx.ch>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
dr-itz authored and Linus Torvalds committed Jul 28, 2005
1 parent a1b274f commit d8c4b41
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions drivers/pcmcia/yenta_socket.c
Original file line number Diff line number Diff line change
Expand Up @@ -1107,6 +1107,8 @@ static int yenta_dev_suspend (struct pci_dev *dev, pm_message_t state)
pci_read_config_dword(dev, 17*4, &socket->saved_state[1]);
pci_disable_device(dev);

free_irq(dev->irq, socket);

/*
* Some laptops (IBM T22) do not like us putting the Cardbus
* bridge into D3. At a guess, some other laptop will
Expand All @@ -1132,6 +1134,13 @@ static int yenta_dev_resume (struct pci_dev *dev)
pci_enable_device(dev);
pci_set_master(dev);

if (socket->cb_irq)
if (request_irq(socket->cb_irq, yenta_interrupt,
SA_SHIRQ, "yenta", socket)) {
printk(KERN_WARNING "Yenta: request_irq() failed on resume!\n");
socket->cb_irq = 0;
}

if (socket->type && socket->type->restore_state)
socket->type->restore_state(socket);
}
Expand Down

0 comments on commit d8c4b41

Please sign in to comment.