version 3.11.1-1
Finally ACPI S3 patches are fully integrated in upstream kernel. This commits comes with updates for other patches and of course kernel config.
This commit is contained in:
parent
bd5d0c63a3
commit
96d320d4e0
515
config-pvops
515
config-pvops
File diff suppressed because it is too large
Load Diff
@ -1,112 +0,0 @@
|
|||||||
From b2ed886e43ec90bae86d6cae6582b457e76d1fd8 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
|
|
||||||
Date: Thu, 8 Dec 2011 17:16:43 +0800
|
|
||||||
Subject: x86/acpi/sleep: Provide registration for acpi_suspend_lowlevel.
|
|
||||||
|
|
||||||
Which by default will be x86_acpi_suspend_lowlevel.
|
|
||||||
This registration allows us to register another callback
|
|
||||||
if there is a need to use another platform specific callback.
|
|
||||||
|
|
||||||
CC: Thomas Gleixner <tglx@linutronix.de>
|
|
||||||
CC: "H. Peter Anvin" <hpa@zytor.com>
|
|
||||||
CC: x86@kernel.org
|
|
||||||
CC: Len Brown <len.brown@intel.com>
|
|
||||||
CC: Joseph Cihula <joseph.cihula@intel.com>
|
|
||||||
CC: Shane Wang <shane.wang@intel.com>
|
|
||||||
CC: linux-pm@lists.linux-foundation.org
|
|
||||||
CC: linux-acpi@vger.kernel.org
|
|
||||||
CC: Len Brown <len.brown@intel.com>
|
|
||||||
Signed-off-by: Liang Tang <liang.tang@oracle.com>
|
|
||||||
[v1: Fix when CONFIG_ACPI_SLEEP is not set]
|
|
||||||
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
|
|
||||||
---
|
|
||||||
arch/x86/include/asm/acpi.h | 2 +-
|
|
||||||
arch/x86/kernel/acpi/boot.c | 7 +++++++
|
|
||||||
arch/x86/kernel/acpi/sleep.c | 4 ++--
|
|
||||||
arch/x86/kernel/acpi/sleep.h | 2 ++
|
|
||||||
drivers/acpi/sleep.c | 2 ++
|
|
||||||
5 files changed, 14 insertions(+), 3 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/arch/x86/include/asm/acpi.h b/arch/x86/include/asm/acpi.h
|
|
||||||
index 610001d..68cf060 100644
|
|
||||||
--- a/arch/x86/include/asm/acpi.h
|
|
||||||
+++ b/arch/x86/include/asm/acpi.h
|
|
||||||
@@ -115,7 +115,7 @@ static inline void acpi_disable_pci(void)
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Low-level suspend routine. */
|
|
||||||
-extern int acpi_suspend_lowlevel(void);
|
|
||||||
+extern int (*acpi_suspend_lowlevel)(void);
|
|
||||||
|
|
||||||
/* Physical address to resume after wakeup */
|
|
||||||
#define acpi_wakeup_address ((unsigned long)(real_mode_header->wakeup_start))
|
|
||||||
diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c
|
|
||||||
index ce664f3..c3a5b95 100644
|
|
||||||
--- a/arch/x86/kernel/acpi/boot.c
|
|
||||||
+++ b/arch/x86/kernel/acpi/boot.c
|
|
||||||
@@ -44,6 +44,7 @@
|
|
||||||
#include <asm/mpspec.h>
|
|
||||||
#include <asm/smp.h>
|
|
||||||
|
|
||||||
+#include "sleep.h" /* To include x86_acpi_suspend_lowlevel */
|
|
||||||
static int __initdata acpi_force = 0;
|
|
||||||
u32 acpi_rsdt_forced;
|
|
||||||
int acpi_disabled;
|
|
||||||
@@ -558,6 +559,12 @@ static int acpi_register_gsi_ioapic(struct device *dev, u32 gsi,
|
|
||||||
int (*__acpi_register_gsi)(struct device *dev, u32 gsi,
|
|
||||||
int trigger, int polarity) = acpi_register_gsi_pic;
|
|
||||||
|
|
||||||
+#ifdef CONFIG_ACPI_SLEEP
|
|
||||||
+int (*acpi_suspend_lowlevel)(void) = x86_acpi_suspend_lowlevel;
|
|
||||||
+#else
|
|
||||||
+int (*acpi_suspend_lowlevel)(void);
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
/*
|
|
||||||
* success: return IRQ number (>=0)
|
|
||||||
* failure: return < 0
|
|
||||||
diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c
|
|
||||||
index 103b6ab..4d2d0b1 100644
|
|
||||||
--- a/arch/x86/kernel/acpi/sleep.c
|
|
||||||
+++ b/arch/x86/kernel/acpi/sleep.c
|
|
||||||
@@ -25,12 +25,12 @@ static char temp_stack[4096];
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/**
|
|
||||||
- * acpi_suspend_lowlevel - save kernel state
|
|
||||||
+ * x86_acpi_suspend_lowlevel - save kernel state
|
|
||||||
*
|
|
||||||
* Create an identity mapped page table and copy the wakeup routine to
|
|
||||||
* low memory.
|
|
||||||
*/
|
|
||||||
-int acpi_suspend_lowlevel(void)
|
|
||||||
+int x86_acpi_suspend_lowlevel(void)
|
|
||||||
{
|
|
||||||
struct wakeup_header *header =
|
|
||||||
(struct wakeup_header *) __va(real_mode_header->wakeup_header);
|
|
||||||
diff --git a/arch/x86/kernel/acpi/sleep.h b/arch/x86/kernel/acpi/sleep.h
|
|
||||||
index 416d4be..4d3feb5 100644
|
|
||||||
--- a/arch/x86/kernel/acpi/sleep.h
|
|
||||||
+++ b/arch/x86/kernel/acpi/sleep.h
|
|
||||||
@@ -13,3 +13,5 @@ extern unsigned long acpi_copy_wakeup_routine(unsigned long);
|
|
||||||
extern void wakeup_long64(void);
|
|
||||||
|
|
||||||
extern void do_suspend_lowlevel(void);
|
|
||||||
+
|
|
||||||
+extern int x86_acpi_suspend_lowlevel(void);
|
|
||||||
diff --git a/drivers/acpi/sleep.c b/drivers/acpi/sleep.c
|
|
||||||
index 0a7ed69..44dbdde 100644
|
|
||||||
--- a/drivers/acpi/sleep.c
|
|
||||||
+++ b/drivers/acpi/sleep.c
|
|
||||||
@@ -254,6 +254,8 @@ static int acpi_suspend_enter(suspend_state_t pm_state)
|
|
||||||
break;
|
|
||||||
|
|
||||||
case ACPI_STATE_S3:
|
|
||||||
+ if (!acpi_suspend_lowlevel)
|
|
||||||
+ return -ENOSYS;
|
|
||||||
error = acpi_suspend_lowlevel();
|
|
||||||
if (error)
|
|
||||||
return error;
|
|
||||||
--
|
|
||||||
1.7.6.4
|
|
||||||
|
|
@ -1,53 +0,0 @@
|
|||||||
From 5000cd48f33e3e4d31cdeda0751188794f8bebf4 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
|
|
||||||
Date: Thu, 8 Dec 2011 17:34:58 +0800
|
|
||||||
Subject: xen/acpi/sleep: Register to the acpi_suspend_lowlevel a callback.
|
|
||||||
|
|
||||||
We piggyback on "x86/acpi: Provide registration for acpi_suspend_lowlevel."
|
|
||||||
to register a Xen version of the callback. The callback does not
|
|
||||||
do anything special - except it omits the x86_acpi_suspend_lowlevel.
|
|
||||||
It does that b/c during suspend it tries to save cr8 values (which
|
|
||||||
the hypervisor does not support), and then on resume path the
|
|
||||||
cr3, cr8, idt, and gdt are all resumed which clashes with what
|
|
||||||
the hypervisor has set up for the guest.
|
|
||||||
|
|
||||||
Signed-off-by: Liang Tang <liang.tang@oracle.com>
|
|
||||||
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
|
|
||||||
---
|
|
||||||
include/xen/acpi.h | 16 +++++++++++++++-
|
|
||||||
1 files changed, 15 insertions(+), 1 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/include/xen/acpi.h b/include/xen/acpi.h
|
|
||||||
index 48a9c01..ebaabbb 100644
|
|
||||||
--- a/include/xen/acpi.h
|
|
||||||
+++ b/include/xen/acpi.h
|
|
||||||
@@ -43,11 +43,25 @@
|
|
||||||
int xen_acpi_notify_hypervisor_state(u8 sleep_state,
|
|
||||||
u32 pm1a_cnt, u32 pm1b_cnd);
|
|
||||||
|
|
||||||
+static inline int xen_acpi_suspend_lowlevel(void)
|
|
||||||
+{
|
|
||||||
+ /*
|
|
||||||
+ * Xen will save and restore CPU context, so
|
|
||||||
+ * we can skip that and just go straight to
|
|
||||||
+ * the suspend.
|
|
||||||
+ */
|
|
||||||
+ acpi_enter_sleep_state(ACPI_STATE_S3);
|
|
||||||
+ return 0;
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
static inline void xen_acpi_sleep_register(void)
|
|
||||||
{
|
|
||||||
- if (xen_initial_domain())
|
|
||||||
+ if (xen_initial_domain()) {
|
|
||||||
acpi_os_set_prepare_sleep(
|
|
||||||
&xen_acpi_notify_hypervisor_state);
|
|
||||||
+
|
|
||||||
+ acpi_suspend_lowlevel = xen_acpi_suspend_lowlevel;
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
static inline void xen_acpi_sleep_register(void)
|
|
||||||
--
|
|
||||||
1.7.6.4
|
|
||||||
|
|
@ -66,7 +66,7 @@ diff --git a/drivers/usb/host/Makefile b/drivers/usb/host/Makefile
|
|||||||
index 0982bcc..d62fe38 100644
|
index 0982bcc..d62fe38 100644
|
||||||
--- a/drivers/usb/host/Makefile
|
--- a/drivers/usb/host/Makefile
|
||||||
+++ b/drivers/usb/host/Makefile
|
+++ b/drivers/usb/host/Makefile
|
||||||
@@ -40,5 +40,7 @@ obj-$(CONFIG_USB_HWA_HCD) += hwa-hc.o
|
@@ -40,6 +40,8 @@ obj-$(CONFIG_USB_HWA_HCD) += hwa-hc.o
|
||||||
obj-$(CONFIG_USB_IMX21_HCD) += imx21-hcd.o
|
obj-$(CONFIG_USB_IMX21_HCD) += imx21-hcd.o
|
||||||
obj-$(CONFIG_USB_FSL_MPH_DR_OF) += fsl-mph-dr-of.o
|
obj-$(CONFIG_USB_FSL_MPH_DR_OF) += fsl-mph-dr-of.o
|
||||||
obj-$(CONFIG_USB_OCTEON2_COMMON) += octeon2-common.o
|
obj-$(CONFIG_USB_OCTEON2_COMMON) += octeon2-common.o
|
||||||
@ -74,6 +74,7 @@ index 0982bcc..d62fe38 100644
|
|||||||
+obj-$(CONFIG_XEN_USBDEV_BACKEND) += xen-usbback/
|
+obj-$(CONFIG_XEN_USBDEV_BACKEND) += xen-usbback/
|
||||||
obj-$(CONFIG_USB_HCD_BCMA) += bcma-hcd.o
|
obj-$(CONFIG_USB_HCD_BCMA) += bcma-hcd.o
|
||||||
obj-$(CONFIG_USB_HCD_SSB) += ssb-hcd.o
|
obj-$(CONFIG_USB_HCD_SSB) += ssb-hcd.o
|
||||||
|
obj-$(CONFIG_USB_FUSBH200_HCD) += fusbh200-hcd.o
|
||||||
diff --git a/drivers/usb/host/xen-usbback/Makefile b/drivers/usb/host/xen-usbback/Makefile
|
diff --git a/drivers/usb/host/xen-usbback/Makefile b/drivers/usb/host/xen-usbback/Makefile
|
||||||
new file mode 100644
|
new file mode 100644
|
||||||
index 0000000..9f3628c
|
index 0000000..9f3628c
|
||||||
@ -88,7 +89,7 @@ new file mode 100644
|
|||||||
index 0000000..d9671ec
|
index 0000000..d9671ec
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/drivers/usb/host/xen-usbback/common.h
|
+++ b/drivers/usb/host/xen-usbback/common.h
|
||||||
@@ -0,0 +1,170 @@
|
@@ -0,0 +1,171 @@
|
||||||
+/*
|
+/*
|
||||||
+ * This file is part of Xen USB backend driver.
|
+ * This file is part of Xen USB backend driver.
|
||||||
+ *
|
+ *
|
||||||
@ -139,6 +140,7 @@ index 0000000..d9671ec
|
|||||||
+#include <linux/interrupt.h>
|
+#include <linux/interrupt.h>
|
||||||
+#include <linux/slab.h>
|
+#include <linux/slab.h>
|
||||||
+#include <linux/usb.h>
|
+#include <linux/usb.h>
|
||||||
|
+#include <linux/usb/ch11.h>
|
||||||
+#include <linux/vmalloc.h>
|
+#include <linux/vmalloc.h>
|
||||||
+#include <linux/kthread.h>
|
+#include <linux/kthread.h>
|
||||||
+#include <linux/wait.h>
|
+#include <linux/wait.h>
|
||||||
|
@ -0,0 +1,49 @@
|
|||||||
|
From c8f92fa48f8d2a8a1ad56347e52ba4c16be57a48 Mon Sep 17 00:00:00 2001
|
||||||
|
From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?=
|
||||||
|
<marmarek@invisiblethingslab.com>
|
||||||
|
Date: Fri, 20 Sep 2013 05:16:21 +0200
|
||||||
|
Subject: [PATCH] Revert "xen/pat: Disable PAT using pat_enabled value."
|
||||||
|
MIME-Version: 1.0
|
||||||
|
Content-Type: text/plain; charset=UTF-8
|
||||||
|
Content-Transfer-Encoding: 8bit
|
||||||
|
Organization: Invisible Things Lab
|
||||||
|
Cc: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
|
||||||
|
|
||||||
|
This reverts commit c79c49826270b8b0061b2fca840fc3f013c8a78a.
|
||||||
|
|
||||||
|
Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
|
||||||
|
---
|
||||||
|
arch/x86/xen/enlighten.c | 10 +---------
|
||||||
|
1 file changed, 1 insertion(+), 9 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
|
||||||
|
index a492be2..a3c8582 100644
|
||||||
|
--- a/arch/x86/xen/enlighten.c
|
||||||
|
+++ b/arch/x86/xen/enlighten.c
|
||||||
|
@@ -68,7 +68,6 @@
|
||||||
|
#include <asm/hypervisor.h>
|
||||||
|
#include <asm/mwait.h>
|
||||||
|
#include <asm/pci_x86.h>
|
||||||
|
-#include <asm/pat.h>
|
||||||
|
|
||||||
|
#ifdef CONFIG_ACPI
|
||||||
|
#include <linux/acpi.h>
|
||||||
|
@@ -1512,14 +1511,7 @@ asmlinkage void __init xen_start_kernel(void)
|
||||||
|
*/
|
||||||
|
acpi_numa = -1;
|
||||||
|
#endif
|
||||||
|
-#ifdef CONFIG_X86_PAT
|
||||||
|
- /*
|
||||||
|
- * For right now disable the PAT. We should remove this once
|
||||||
|
- * git commit 8eaffa67b43e99ae581622c5133e20b0f48bcef1
|
||||||
|
- * (xen/pat: Disable PAT support for now) is reverted.
|
||||||
|
- */
|
||||||
|
- pat_enabled = 0;
|
||||||
|
-#endif
|
||||||
|
+
|
||||||
|
/* Don't do the full vcpu_info placement stuff until we have a
|
||||||
|
possible map and a non-dummy shared_info. */
|
||||||
|
per_cpu(xen_vcpu, 0) = &HYPERVISOR_shared_info->vcpu_info[0];
|
||||||
|
--
|
||||||
|
1.8.3.1
|
||||||
|
|
@ -3,7 +3,7 @@ index 4e86393..34493d7 100644
|
|||||||
--- a/drivers/block/xen-blkfront.c
|
--- a/drivers/block/xen-blkfront.c
|
||||||
+++ b/drivers/block/xen-blkfront.c
|
+++ b/drivers/block/xen-blkfront.c
|
||||||
@@ -1188,7 +1188,7 @@ static void blkfront_connect(struct blkfront_info *info)
|
@@ -1188,7 +1188,7 @@ static void blkfront_connect(struct blkfront_info *info)
|
||||||
unsigned long sector_size;
|
unsigned int physical_sector_size;
|
||||||
unsigned int binfo;
|
unsigned int binfo;
|
||||||
int err;
|
int err;
|
||||||
- int barrier, flush, discard, persistent;
|
- int barrier, flush, discard, persistent;
|
||||||
|
@ -1,75 +0,0 @@
|
|||||||
From 5d66288fa0a177817ca6473a53e27b32fbf37aa9 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Guthro <benjamin.guthro@xxxxxxxxxx>
|
|
||||||
Date: Tue, 2 Apr 2013 02:51:50 +0200
|
|
||||||
Subject: [PATCH] xen: Re-upload processor PM data to hypervisor after S3
|
|
||||||
|
|
||||||
resume
|
|
||||||
|
|
||||||
Upon resume, it was found that ACPI C-states were missing from non-boot CPUs.
|
|
||||||
This change registers a syscore_ops handler for this case, and performs a
|
|
||||||
subset of the xen_acpi_processor_init() functionality to achieve this case.
|
|
||||||
|
|
||||||
Signed-Off-By: Ben Guthro <benjamin.guthro@xxxxxxxxxx>
|
|
||||||
---
|
|
||||||
drivers/xen/xen-acpi-processor.c | 24 ++++++++++++++++++++++++
|
|
||||||
1 file changed, 24 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/drivers/xen/xen-acpi-processor.c b/drivers/xen/xen-acpi-processor.c
|
|
||||||
index 316df65..92dabc8 100644
|
|
||||||
--- a/drivers/xen/xen-acpi-processor.c
|
|
||||||
+++ b/drivers/xen/xen-acpi-processor.c
|
|
||||||
@@ -25,6 +25,7 @@
|
|
||||||
#include <linux/init.h>
|
|
||||||
#include <linux/module.h>
|
|
||||||
#include <linux/types.h>
|
|
||||||
+#include <linux/syscore_ops.h>
|
|
||||||
#include <acpi/acpi_bus.h>
|
|
||||||
#include <acpi/acpi_drivers.h>
|
|
||||||
#include <acpi/processor.h>
|
|
||||||
@@ -467,6 +468,26 @@ static void free_acpi_perf_data(void)
|
|
||||||
free_percpu(acpi_perf_data);
|
|
||||||
}
|
|
||||||
|
|
||||||
+static void xen_acpi_processor_resume(void)
|
|
||||||
+{
|
|
||||||
+ int i;
|
|
||||||
+ printk(KERN_INFO "Resuming Xen processor info\n");
|
|
||||||
+
|
|
||||||
+ for_each_possible_cpu(i) {
|
|
||||||
+ struct acpi_processor *_pr;
|
|
||||||
+ _pr = per_cpu(processors, i /* APIC ID */);
|
|
||||||
+ if (!_pr)
|
|
||||||
+ continue;
|
|
||||||
+
|
|
||||||
+ __clear_bit(_pr->acpi_id, acpi_ids_done);
|
|
||||||
+ (void)upload_pm_data(_pr);
|
|
||||||
+ }
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+static struct syscore_ops xap_syscore_ops = {
|
|
||||||
+ .resume = xen_acpi_processor_resume,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
static int __init xen_acpi_processor_init(void)
|
|
||||||
{
|
|
||||||
struct acpi_processor *pr_backup = NULL;
|
|
||||||
@@ -532,6 +553,8 @@ static int __init xen_acpi_processor_init(void)
|
|
||||||
if (rc)
|
|
||||||
goto err_unregister;
|
|
||||||
|
|
||||||
+ register_syscore_ops(&xap_syscore_ops);
|
|
||||||
+
|
|
||||||
return 0;
|
|
||||||
err_unregister:
|
|
||||||
for_each_possible_cpu(i) {
|
|
||||||
@@ -550,6 +573,7 @@ static void __exit xen_acpi_processor_exit(void)
|
|
||||||
int i;
|
|
||||||
|
|
||||||
kfree(acpi_ids_done);
|
|
||||||
+ unregister_syscore_ops(&xap_syscore_ops);
|
|
||||||
for_each_possible_cpu(i) {
|
|
||||||
struct acpi_processor_performance *perf;
|
|
||||||
perf = per_cpu_ptr(acpi_perf_data, i);
|
|
||||||
--
|
|
||||||
1.8.1.4
|
|
||||||
|
|
@ -1,10 +1,6 @@
|
|||||||
# ACPI S3
|
|
||||||
patches.xen/pvops-0001-x86-acpi-sleep-Provide-registration-for-acpi_suspend.patch
|
|
||||||
patches.xen/pvops-0003-xen-acpi-sleep-Register-to-the-acpi_suspend_lowlevel.patch
|
|
||||||
patches.xen/pvops-xen-Re-upload-processor-PM-data-to-hypervisor-after-.patch
|
|
||||||
|
|
||||||
# fix for GPU performance (revert workaround and apply proper fix), should go in 3.5
|
# fix for GPU performance (revert workaround and apply proper fix), should go in 3.5
|
||||||
patches.xen/pvops-3.4-Revert-xen-pat-Disable-PAT-support-for-now.patch
|
patches.xen/pvops-3.4-Revert-xen-pat-Disable-PAT-support-for-now.patch
|
||||||
|
patches.xen/pvops-Revert-xen-pat-Disable-PAT-using-pat_enabled-value.patch
|
||||||
patches.xen/pvops-3.4-x86-cpa-Use-pte_attrs-instead-of-pte_flags-on-CPA-se.patch
|
patches.xen/pvops-3.4-x86-cpa-Use-pte_attrs-instead-of-pte_flags-on-CPA-se.patch
|
||||||
|
|
||||||
# Additional features
|
# Additional features
|
||||||
|
@ -1 +1 @@
|
|||||||
3.9.2
|
3.11.1
|
||||||
|
Loading…
Reference in New Issue
Block a user