[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1290996593-32416-2-git-send-email-maximlevitsky@gmail.com>
Date: Mon, 29 Nov 2010 04:09:49 +0200
From: Maxim Levitsky <maximlevitsky@...il.com>
To: linux1394-devel <linux1394-devel@...ts.sourceforge.net>
Cc: Stefan Richter <stefanr@...6.in-berlin.de>, netdev@...r.kernel.org,
Maxim Levitsky <maximlevitsky@...il.com>
Subject: [PATCH 1/5] 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@...il.com>
---
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 6dd56cd..0fbadb7 100644
--- a/drivers/firewire/ohci.c
+++ b/drivers/firewire/ohci.c
@@ -3240,6 +3240,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
--
1.7.1
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists