[PATCH] xen/blkback: Propagate changed size of VBDs

Support dynamic resizing of virtual block devices. This patch supports
both file backed block devices as well as physical devices that can be
dynamically resized on the host side.

Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/blkback: add accessor for xenbus backend device

Since backend_info is hidden away now.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/msi: fix dom0 S3 when MSI is used

The old commit a234848f works only when the device supports D3hot; when the
device only supports D3cold, the device doesn't work properly after resuming
from Dom0 S3.
A better workaround is invoking the PHYSDEVOP_restore_msi hypercall.
The patch reverts the old commit and invokes the hypercall.

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles wang <muming.wq@taobao.com>
[PATCH] xen/netback: use get_sset_count rather than obsolete

 get_stats_count

commit: 6442f18a0579df297f24809219d0b91393b47bc0

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/apic: Control-flow cleanup in xen_register_gsi

It is nice to have only one return, but it does not make it easier to
read or change.

Signed-off-by: Bastian Blank <waldi@debian.org>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen: make sure supported_pte_flags is used to create IO APIC

 dummy mapping

commit: de67ec8b23629776f786d62c3109552ea7f8cc27

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/apic: Map physical interrupt before setting up GSI

We need to make sure we're ready to accept interrupts from a device
before unmasking the interrupt source.

Signed-off-by: Bastian Blank <waldi@debian.org>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/apic: Don't register GSI in pre-setup

Xen behaves the same way that native Linux, it only allows any IO-APIC
pin to be setup once.  Therefore we must not set it up in the initial
run over all legacy interrupts or we lose the ability to use them as
non-legacy interrupts later.

Signed-off-by: Bastian Blank <waldi@debian.org>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen: Enable ACPI sleep in Xen

Open CONFIG_ACPI_SLEEP in xenlinux, to enable ACPI based
power management. Basically, user can trigger power event
now by "echo *** > /sys/power/state". Also gear to pm
interface defined between xenlinux and Xen.

Also sync to xen interface headers consequently

[ From http://xenbits.xensource.com/linux-2.6.18-xen.hg
change c68699484a65 ]

Signed-off-by: Ke Yu <ke.yu@intel.com>
Signed-off-by: Kevin Tian <kevin.tian@intel.com>
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/acpi: Domain0 acpi parser related platform hypercall

This patches implements the xen_platform_op hypercall, to pass the parsed
ACPI info to hypervisor.

Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Tian Kevin <kevin.tian@intel.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>

Conflict(by Charles):
	include/xen/interface/platform.h
[PATCH] xen/acpi: add xen acpi processor driver

Xen hypervisor need parsed acpi processor info for CPU Cx/Px power management,
so this patch introduces xen acpi processor driver to parse the acpi info,
and notify the hypervisor upon receiving the info.

This patch has two components:
- driver/acpi/processor_xen.c: implement the xen acpi processor driver
- drivers/xen/acpi_processor.c: provide the interface to notify Xen hypervisor

Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Tian Kevin <kevin.tian@intel.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/acpi: Export host physical CPU information to dom0

This patch expose host's physical CPU information to dom0 in sysfs, so
that dom0's management tools can control the physical CPU if needed.

It also provides interface in sysfs to logical online/offline a physical CPU.

Notice: The information in dom0 is synced with xen hypervisor asynchronously.

Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>

Conflict(by Charles):
	include/xen/interface/platform.h
[PATCH] xen/acpi: Add pcpu hotplug support to pvops dom0.

This patch implement CPU hotplug callback in xen acpi_processor. User
can later bring the pcpu online through sysfs interface.

xen_get_apic_id() is mostly duplicated with the get_cpu_id() in
driver/acpi/processor_core.c, but it should be ok since it has been
duplicated in arch directory already by upstream kernel.

One thing left is, currently the acpi_processor's id is quite
confusing (it is in fact with vcpu's dom0 cpu_id). Will update it with
xen's cpuid through the pcpu interface. But to achieve it, we need
investigate more on the pr->id, and also we need change the pcpu logic
to use spin_lock, instead of mutex for the pcpu list. That will be
next step.

Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/acpi: Move acpi_memory_info definition to public

Move this definition to header file so that it can be used by dom0
memory hotadd logic also.

Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/acpi: Add memory hotadd to pvops dom0

When memory hotadd event happen, a Xen hook will be called, to notify
hypervisor of the new added memory.

Because xen hypervisor will use the new memory to setup frametable/m2p
table, so dom0 will always return success to acpi bios, and notify xen
hypervisor later.

It add a hook in driver/acpi/acpi_memhotplug.c, but that change is
quite small, not sure if it is acceptable. Other method is to provide
a xen specific acpi_memory_device_driver, but I'm not sure if it worth
to add so much changes, to simply avoid two hooks.

Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/apic: remove warnings from stray mismerges

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] xen/dom0: set wallclock time in Xen

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] vmap: consolidate 3 if() blocks into one

All the code is dominated by one conditional, so just put them into the
same if().

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] vmap: fast path out of __purge_vmap_area_lazy if there's

 nothing to purge

commit: fd335b413c2a95d5816637c98897151a02779a65

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>
[PATCH] vmap: add flag to allow lazy unmap to be disabled at runtime

Add a flag to force lazy_max_pages() to zero to prevent any outstanding
mapped pages.  We'll need this for Xen.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Charles Wang <muming.wq@taobao.com>