diff options
author | David Shaohua Li | 2005-03-18 22:43:54 +0100 |
---|---|---|
committer | Len Brown | 2005-07-12 05:23:46 +0200 |
commit | d58da590451cf6ae75379a2ebf96d3afb8d810d8 (patch) | |
tree | 3b39228dbd1ed798965cf64f5bd98a498f5811cc /drivers/pcmcia | |
parent | [ACPI] S3 Suspend to RAM: interrupt resume fix (diff) | |
download | kernel-qcow2-linux-d58da590451cf6ae75379a2ebf96d3afb8d810d8.tar.gz kernel-qcow2-linux-d58da590451cf6ae75379a2ebf96d3afb8d810d8.tar.xz kernel-qcow2-linux-d58da590451cf6ae75379a2ebf96d3afb8d810d8.zip |
[ACPI] S3 Suspend to RAM: fix driver suspend/resume methods
Drivers should do this:
.suspend()
pci_disable_device()
.resume()
pci_enable_device()
http://bugzilla.kernel.org/show_bug.cgi?id=3469
Signed-off-by: David Shaohua Li <shaohua.li@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/pcmcia')
-rw-r--r-- | drivers/pcmcia/yenta_socket.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/pcmcia/yenta_socket.c b/drivers/pcmcia/yenta_socket.c index 6404d97a12eb..caf7159a54be 100644 --- a/drivers/pcmcia/yenta_socket.c +++ b/drivers/pcmcia/yenta_socket.c @@ -1032,6 +1032,7 @@ static int yenta_dev_suspend (struct pci_dev *dev, pm_message_t state) pci_save_state(dev); pci_read_config_dword(dev, 16*4, &socket->saved_state[0]); pci_read_config_dword(dev, 17*4, &socket->saved_state[1]); + pci_disable_device(dev); /* * Some laptops (IBM T22) do not like us putting the Cardbus @@ -1055,6 +1056,8 @@ static int yenta_dev_resume (struct pci_dev *dev) pci_restore_state(dev); pci_write_config_dword(dev, 16*4, socket->saved_state[0]); pci_write_config_dword(dev, 17*4, socket->saved_state[1]); + pci_enable_device(dev); + pci_set_master(dev); if (socket->type && socket->type->restore_state) socket->type->restore_state(socket); |