diff options
author | Maxim Levitsky <maximlevitsky@gmail.com> | 2010-11-29 03:09:49 +0100 |
---|---|---|
committer | Stefan Richter <stefanr@s5r6.in-berlin.de> | 2010-12-13 20:39:15 +0100 |
commit | 8662b6b029636c35e5876e184d90daf6b0072667 (patch) | |
tree | 448ac2fb1db32087cb414f9f00ca420fc6ac3d7e /drivers/firewire/ohci.c | |
parent | firewire: ohci: use common buffer for self IDs and AR descriptors (diff) | |
download | linux-8662b6b029636c35e5876e184d90daf6b0072667.tar.xz linux-8662b6b029636c35e5876e184d90daf6b0072667.zip |
firewire: ohci: restore GUID on resume.
Some lousy BIOSes, e.g. my Aspire 5720 BIOS forget to restore the GUID
register on resume from RAM.
Fix that by setting it to the last value that was read from it.
Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Diffstat (limited to 'drivers/firewire/ohci.c')
-rw-r--r-- | drivers/firewire/ohci.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/firewire/ohci.c b/drivers/firewire/ohci.c index eb7b591e1c1b..3a908038ff62 100644 --- a/drivers/firewire/ohci.c +++ b/drivers/firewire/ohci.c @@ -3284,6 +3284,13 @@ static int pci_resume(struct pci_dev *dev) return err; } + /* Some systems don't setup GUID register on resume from ram */ + if (!reg_read(ohci, OHCI1394_GUIDLo) && + !reg_read(ohci, OHCI1394_GUIDHi)) { + reg_write(ohci, OHCI1394_GUIDLo, (u32)ohci->card.guid); + reg_write(ohci, OHCI1394_GUIDHi, (u32)(ohci->card.guid >> 32)); + } + return ohci_enable(&ohci->card, NULL, 0); } #endif |