Skip to contentSkip to conversation

(xen) stable/for-linus-3.8-rc0-tag

GIT PULL Konrad Rzeszutek Wilk 1 participant 1 message Dec 13, 2012

Subsystems (5)
lore
Share & tools
lore
#0 lore raw

Hey Linus,

Please git pull the following tag:

git pull git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen.git stable/for-linus-3.8-rc0-tag

or branch (this is included in this email b/c I keep on getting:
"fatal: Couldn't find remote ref stable/for-linus-3.8-rc0-tag" even though I _know_ that the tag is there?! I can see it on the website and when I do git fetch/clone). Anyhow if you get the same message, please git pull the branch:

git pull git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen.git stable/for-linus-3.8

which has <copied from the signed tag>
Features:
- Add necessary infrastructure to make balloon driver work under ARM.
- Add /dev/xen/privcmd interfaces to work with ARM and PVH.
- Improve Xen PCIBack wild-card parsing.
- Add Xen ACPI PAD (Processor Aggregator) support - so can offline/online sockets depending on the power consumption.
- PVHVM + kexec = use an E820_RESV region for the shared region so we don't overwrite said region during kexec reboot.
- Cleanups, compile fixes.
<end of copy>

This merge will result in conflicts - there were some ARM patches in v3.7-rcX that this branch does not contain. The recipe is that the balloon drivers (drivers/xen/balloon.c) can now compile under ARM, so the temporary functions added in arch/arm/xen/enlighten.c. can be ripped out (so these functions are axed: alloc_xenballooned_pages and free_xenballooned_pages). Consequently the drivers/xen/Makefile can now have the balloon.o on the generic build target.

To illustrate this I've created a branch called 'for-linus-3.8.resolved'
(http://git.kernel.org/?p=linux/kernel/git/konrad/xen.git;a=commitdiff;h=32423604549179b47d4d31c880c5fc45b0903543)
and also included as a big diff in this email.

Please pull!

 arch/arm/include/asm/xen/interface.h |    1 +
 arch/arm/xen/enlighten.c             |  123 +++++++++++++++++++----
 arch/x86/include/asm/xen/interface.h |    1 +
 arch/x86/xen/Kconfig                 |    1 +
 arch/x86/xen/enlighten.c             |  102 ++++++++++++++-----
 arch/x86/xen/mmu.c                   |   17 +++-
 arch/x86/xen/suspend.c               |    2 +-
 arch/x86/xen/xen-ops.h               |    2 +-
 drivers/xen/Kconfig                  |    3 +
 drivers/xen/Makefile                 |    7 +-
 drivers/xen/balloon.c                |    5 +-
 drivers/xen/privcmd.c                |   72 +++++++++++++-
 drivers/xen/xen-acpi-pad.c           |  182 ++++++++++++++++++++++++++++++++++
 drivers/xen/xen-pciback/pci_stub.c   |  118 ++++++++++++----------
 drivers/xen/xenbus/xenbus_xs.c       |    1 -
 include/xen/interface/memory.h       |   44 ++++++++-
 include/xen/interface/platform.h     |   17 +++
 include/xen/xen-ops.h                |    9 ++-
 18 files changed, 591 insertions(+), 116 deletions(-)

Ian Campbell (5):
xen: add pages parameter to xen_remap_domain_mfn_range
xen: balloon: allow PVMMU interfaces to be compiled out
xen: arm: enable balloon driver
xen: correctly use xen_pfn_t in remap_domain_mfn_range.
xen: arm: implement remap interfaces needed for privcmd mappings.

Jan Beulich (2):
xen-pciback: simplify and tighten parsing of device IDs
xen-pciback: reject out of range inputs

Konrad Rzeszutek Wilk (2):
xen/acpi: Fix compile error by missing decleration for xen_domain. xen/acpi: Move the xen_running_on_version_or_later function.

Liu, Jinsong (2):
xen/acpi: ACPI PAD driver
xen/acpi: revert pad config check in xen_check_mwait

Mukesh Rathor (1):
xen: privcmd: support autotranslated physmap guests.

Olaf Hering (2):
xen PVonHVM: use E820_Reserved area for shared_info xen/PVonHVM: fix compile warning in init_hvm_pv_info

Sachin Kamat (1):
xen/xenbus: Remove duplicate inclusion of asm/xen/hypervisor.h

arch/arm/include/asm/xen/interface.h +1 -0
index 5000397..1151188 100644
@@ -49,6 +49,7 @@ DEFINE_GUEST_HANDLE(void);
 DEFINE_GUEST_HANDLE(uint64_t);
 DEFINE_GUEST_HANDLE(uint32_t);
 DEFINE_GUEST_HANDLE(xen_pfn_t);
+DEFINE_GUEST_HANDLE(xen_ulong_t);
 
 /* Maximum number of virtual CPUs in multi-processor guests. */
 #define MAX_VIRT_CPUS 1
arch/arm/xen/enlighten.c +102 -21

159 lines not on this page · raw message

arch/x86/include/asm/xen/interface.h +1 -0
index 54d52ff..fd9cb76 100644
@@ -63,6 +63,7 @@ DEFINE_GUEST_HANDLE(void);
 DEFINE_GUEST_HANDLE(uint64_t);
 DEFINE_GUEST_HANDLE(uint32_t);
 DEFINE_GUEST_HANDLE(xen_pfn_t);
+DEFINE_GUEST_HANDLE(xen_ulong_t);
 #endif
 
 #ifndef HYPERVISOR_VIRT_START
arch/x86/xen/Kconfig +1 -0
index 9a6775c..131dacd 100644
@@ -6,6 +6,7 @@ config XEN
 	bool "Xen guest support"
 	select PARAVIRT
 	select PARAVIRT_CLOCK
+	select XEN_HAVE_PVMMU
 	depends on X86_64 || (X86_32 && X86_PAE && !X86_VISWS)
 	depends on X86_TSC
 	help
arch/x86/xen/enlighten.c +77 -25

160 lines not on this page · raw message

arch/x86/xen/mmu.c +15 -2
index dcf5f2d..01de35c 100644
@@ -2497,8 +2497,10 @@ static int remap_area_mfn_pte_fn(pte_t *ptep, pgtable_t token,
 
 int xen_remap_domain_mfn_range(struct vm_area_struct *vma,
 			       unsigned long addr,
-			       unsigned long mfn, int nr,
-			       pgprot_t prot, unsigned domid)
+			       xen_pfn_t mfn, int nr,
+			       pgprot_t prot, unsigned domid,
+			       struct page **pages)
+
 {
 	struct remap_data rmd;
 	struct mmu_update mmu_update[REMAP_BATCH_SIZE];
@@ -2542,3 +2544,14 @@ out:
 	return err;
 }
 EXPORT_SYMBOL_GPL(xen_remap_domain_mfn_range);
+
+/* Returns: 0 success */
+int xen_unmap_domain_mfn_range(struct vm_area_struct *vma,
+			       int numpgs, struct page **pages)
+{
+	if (!pages || !xen_feature(XENFEAT_auto_translated_physmap))
+		return 0;
+
+	return -EINVAL;
+}
+EXPORT_SYMBOL_GPL(xen_unmap_domain_mfn_range);
arch/x86/xen/suspend.c +1 -1
index 45329c8..ae8a00c 100644
@@ -30,7 +30,7 @@ void xen_arch_hvm_post_suspend(int suspend_cancelled)
 {
 #ifdef CONFIG_XEN_PVHVM
 	int cpu;
-	xen_hvm_init_shared_info();
+	xen_hvm_resume_shared_info();
 	xen_callback_vector();
 	xen_unplug_emulated_devices();
 	if (xen_feature(XENFEAT_hvm_safe_pvclock)) {
arch/x86/xen/xen-ops.h +1 -1
index a95b417..d2e73d1 100644
@@ -40,7 +40,7 @@ void xen_enable_syscall(void);
 void xen_vcpu_restore(void);
 
 void xen_callback_vector(void);
-void xen_hvm_init_shared_info(void);
+void xen_hvm_resume_shared_info(void);
 void xen_unplug_emulated_devices(void);
 
 void __init xen_build_dynamic_phys_to_machine(void);
drivers/xen/Kconfig +3 -0
index 126d8ce..cabfa97 100644
@@ -206,4 +206,7 @@ config XEN_MCE_LOG
 	  Allow kernel fetching MCE error from Xen platform and
 	  converting it into Linux mcelog format for mcelog tools
 
+config XEN_HAVE_PVMMU
+       bool
+
 endmenu
drivers/xen/Makefile +4 -3
index 7435470..fb213cf 100644
@@ -1,9 +1,9 @@
 ifneq ($(CONFIG_ARM),y)
-obj-y	+= manage.o balloon.o
+obj-y	+= manage.o
 obj-$(CONFIG_HOTPLUG_CPU)		+= cpu_hotplug.o
 endif
 obj-$(CONFIG_X86)			+= fallback.o
-obj-y	+= grant-table.o features.o events.o
+obj-y	+= grant-table.o features.o events.o balloon.o
 obj-y	+= xenbus/
 
 nostackp := $(call cc-option, -fno-stack-protector)
@@ -11,7 +11,8 @@ CFLAGS_features.o			:= $(nostackp)
 
 dom0-$(CONFIG_PCI) += pci.o
 dom0-$(CONFIG_USB_SUPPORT) += dbgp.o
-dom0-$(CONFIG_ACPI) += acpi.o
+dom0-$(CONFIG_ACPI) += acpi.o $(xen-pad-y)
+xen-pad-$(CONFIG_X86) += xen-acpi-pad.o
 dom0-$(CONFIG_X86) += pcpu.o
 obj-$(CONFIG_XEN_DOM0)			+= $(dom0-y)
 obj-$(CONFIG_BLOCK)			+= biomerge.o
drivers/xen/balloon.c +4 -1
index d6886d9..a56776d 100644
@@ -359,6 +359,7 @@ static enum bp_state increase_reservation(unsigned long nr_pages)
 
 		set_phys_to_machine(pfn, frame_list[i]);
 
+#ifdef CONFIG_XEN_HAVE_PVMMU
 		/* Link back into the page tables if not highmem. */
 		if (xen_pv_domain() && !PageHighMem(page)) {
 			int ret;
@@ -368,6 +369,7 @@ static enum bp_state increase_reservation(unsigned long nr_pages)
 				0);
 			BUG_ON(ret);
 		}
+#endif
 
 		/* Relinquish the page back to the allocator. */
 		ClearPageReserved(page);
@@ -416,13 +418,14 @@ static enum bp_state decrease_reservation(unsigned long nr_pages, gfp_t gfp)
 
 		scrub_page(page);
 
+#ifdef CONFIG_XEN_HAVE_PVMMU
 		if (xen_pv_domain() && !PageHighMem(page)) {
 			ret = HYPERVISOR_update_va_mapping(
 				(unsigned long)__va(pfn << PAGE_SHIFT),
 				__pte_ma(0), 0);
 			BUG_ON(ret);
 		}
-
+#endif
 	}
 
 	/* Ensure that ballooned highmem pages don't have kmaps. */
drivers/xen/privcmd.c +69 -3

148 lines not on this page · raw message

drivers/xen/xen-acpi-pad.c new file +182 -0

182 lines not on this page · raw message

drivers/xen/xen-pciback/pci_stub.c +64 -54

239 lines not on this page · raw message

drivers/xen/xenbus/xenbus_xs.c +0 -1
index acedeab..88e677b 100644
@@ -48,7 +48,6 @@
 #include <xen/xenbus.h>
 #include <xen/xen.h>
 #include "xenbus_comms.h"
-#include <asm/xen/hypervisor.h>
 
 struct xs_stored_msg {
 	struct list_head list;
include/xen/interface/memory.h +42 -2

66 lines not on this page · raw message

include/xen/interface/platform.h +17 -0
index 4755b5f..5e36932 100644
@@ -324,6 +324,22 @@ struct xenpf_cpu_ol {
 };
 DEFINE_GUEST_HANDLE_STRUCT(xenpf_cpu_ol);
 
+/*
+ * CMD 58 and 59 are reserved for cpu hotadd and memory hotadd,
+ * which are already occupied at Xen hypervisor side.
+ */
+#define XENPF_core_parking     60
+struct xenpf_core_parking {
+	/* IN variables */
+#define XEN_CORE_PARKING_SET   1
+#define XEN_CORE_PARKING_GET   2
+	uint32_t type;
+	/* IN variables:  set cpu nums expected to be idled */
+	/* OUT variables: get cpu nums actually be idled */
+	uint32_t idle_nums;
+};
+DEFINE_GUEST_HANDLE_STRUCT(xenpf_core_parking);
+
 struct xen_platform_op {
 	uint32_t cmd;
 	uint32_t interface_version; /* XENPF_INTERFACE_VERSION */
@@ -341,6 +357,7 @@ struct xen_platform_op {
 		struct xenpf_set_processor_pminfo set_pminfo;
 		struct xenpf_pcpuinfo          pcpu_info;
 		struct xenpf_cpu_ol            cpu_ol;
+		struct xenpf_core_parking      core_parking;
 		uint8_t                        pad[128];
 	} u;
 };
include/xen/xen-ops.h +7 -2
index 6a198e4..d6fe062 100644
@@ -2,6 +2,7 @@
 #define INCLUDE_XEN_OPS_H
 
 #include <linux/percpu.h>
+#include <asm/xen/interface.h>
 
 DECLARE_PER_CPU(struct vcpu_info *, xen_vcpu);
 
@@ -26,7 +27,11 @@ void xen_destroy_contiguous_region(unsigned long vstart, unsigned int order);
 struct vm_area_struct;
 int xen_remap_domain_mfn_range(struct vm_area_struct *vma,
 			       unsigned long addr,
-			       unsigned long mfn, int nr,
-			       pgprot_t prot, unsigned domid);
+			       xen_pfn_t mfn, int nr,
+			       pgprot_t prot, unsigned domid,
+			       struct page **pages);
+int xen_unmap_domain_mfn_range(struct vm_area_struct *vma,
+			       int numpgs, struct page **pages);
 
+bool xen_running_on_version_or_later(unsigned int major, unsigned int minor);
 #endif /* INCLUDE_XEN_OPS_H */