[Meego-kernel] [PATCH] mrst: make ehci controller a wakeup device
Kristen Carlson Accardi
kristen at linux.intel.com
Wed Apr 6 11:04:13 PDT 2011
Add a quirk to make the ehci controller on Moorestown a wakeup
device. Implement run_wake in mid_pci so that we can do this.
Signed-off-by: Kristen Carlson Accardi <kristen at linux.intel.com>
---
arch/x86/pci/mrst.c | 7 +++++++
drivers/pci/mid_pci.c | 10 ++++++----
2 files changed, 13 insertions(+), 4 deletions(-)
diff --git a/arch/x86/pci/mrst.c b/arch/x86/pci/mrst.c
index c580fcc..dcaeffb 100644
--- a/arch/x86/pci/mrst.c
+++ b/arch/x86/pci/mrst.c
@@ -23,6 +23,7 @@
#include <linux/ioport.h>
#include <linux/init.h>
#include <linux/dmi.h>
+#include <linux/pm_runtime.h>
#include <asm/acpi.h>
#include <asm/segment.h>
@@ -328,3 +329,9 @@ static void __devinit langwell_keypad_fixup(struct pci_dev *dev)
iounmap(base);
}
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0805, langwell_keypad_fixup);
+
+static void __devinit mrst_set_run_wake(struct pci_dev *dev)
+{
+ device_set_run_wake(&dev->dev, true);
+}
+DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0806, mrst_set_run_wake);
diff --git a/drivers/pci/mid_pci.c b/drivers/pci/mid_pci.c
index 27ae94f..4b68bd3 100644
--- a/drivers/pci/mid_pci.c
+++ b/drivers/pci/mid_pci.c
@@ -42,16 +42,18 @@ static int mid_pci_sleep_wake(struct pci_dev *dev, bool enable)
return 0;
}
+static int mid_pci_run_wake(struct pci_dev *dev, bool enable)
+{
+ return 0;
+}
+
static struct pci_platform_pm_ops mid_pci_platform_pm = {
.is_manageable = mid_pci_power_manageable,
.set_state = pmu_pci_set_power_state,
.choose_state = mid_pci_choose_state,
.can_wakeup = mid_pci_can_wakeup,
.sleep_wake = mid_pci_sleep_wake,
-#warning pri#2 #28 need pci_platform_pm_ops.run_wake()?
-#if 0
- .run_wake = TBD;
-#endif
+ .run_wake = mid_pci_run_wake,
};
/**
--
1.7.3.1
More information about the MeeGo-kernel
mailing list