Commit Graph
1036 Commits
Author SHA1 Message Date
Isaku Yamahata 3819ac39eb merge with xen-unstable.hg 2008-07-02 11:30:37 +09:00
Keir Fraser 7d03c1bec2 stubdom: add live migration support by having ioemu just notify the
hypervisor about memory changes.

The impact on disk performance is typically making it from 71.5MBps
down to 70.5Mbps during the live migration. The impact on network
performance is actually even hard to measure.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
2008-06-30 09:57:27 +01:00
Keir Fraser 947835578c [IA64] compilation fix caused by 17880:d3a87899985d
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-06-20 12:26:23 +01:00
Keir Fraser a1b2027c86 Compilation fix for x86_64 caused by 17880:d3a87899985d.
Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
2008-06-20 12:18:10 +01:00
Keir Fraser 50bddc9307 libxc: The following patch replace the libxc interface to use
vcpu_guest_context_any_t (which is both 32 and 64 bits) instead of
vcpu_guest_context_t.

Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
2008-06-19 16:15:05 +01:00
Keir Fraser a2c7db64f5 Add PV-GRUB
This fetches GRUB1 sources, applies the {graphical, print function,
save default, and ext3_256byte} patches from debian, and applies a
patch to make it work on x86_64 and port it to Mini-OS.  By using
libxc, PV-GRUB can then "kexec" the loaded kernel from inside the
domain itself, hence permitting to avoid the security-concerned
pygrub.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
2008-06-18 09:36:47 +01:00
Keir Fraser a1d529a86b hvm: Fix the realmode live migration issue with Intel EPT
The patch save/restore the HVM_PARAM_IDENT_PT parameter, then the live
migration during real mode with EPT may work fine.

Signed-off-by: Xiaohui Xin <Xiaohui.xin@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-06-13 10:13:25 +01:00
Keir Fraser d1318a44ad [IA64] compilation fix caused by 17814:9af7a535225f
ia64 compliation fix caused by 17814:9af7a535225f.
- generate_acpi_checksum() is replaced by acpi_tb_checksum()
- move dump_execution_state() definitions from asm-ia64/xenprocessor.h
  to asm-ia64/bug.h

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-06-12 15:42:09 +01:00
Keir Fraser 461990971f tools: replace sprintf with snprintf where applicable
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
2008-06-12 15:41:15 +01:00
Keir Fraser 923ca284eb x86: cpuid configuration for PV guest
Add pv guest support for the cpuid configuration and checking. That
feature only works for cpuid request which are coming from the guest's
kernel, a process could still call the cpuid directly.

A new policy for pv guest has been created in libxc. dom0 cpuid
emulation is left hardcoded in Xen.

Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-06-11 11:35:35 +01:00
Isaku Yamahata d20f38afda merge with xen-unstable.hg 2008-06-19 12:46:26 +09:00
Keir Fraser deb3650245 libxc: Update for NetBSD
returns hypercall return value when ioctl was successful.

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
2008-06-10 13:49:02 +01:00
Isaku Yamahata 006dff9e04 [IA64] ia64 save/restore new formart. save part.
Introduce ia64 save/restore new formart. save part.
The formart twist is necessary for pv_ops linux support saving/restoring
all of the online vcpu context.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-06-10 16:00:33 +09:00
Isaku Yamahata 55c5209d25 [IA64] ia64 save/restore new formart. restore part.
Introduce ia64 save/restore new formart. restore part.
The formart twist is necessary for pv_ops linux support saving/restoring
all of the online vcpu context.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-06-10 15:58:09 +09:00
Keir Fraser 7e4196ee73 libxc: Use vpath rather than VPATH, to avoid linking with hypervisor .o files.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-06-09 13:25:35 +01:00
Keir Fraser e00ed2adcd xc hvm: Fix default CPUID features according to PAE/64-bit
capabilities of the guest and of the hypervisor.

Based on a patch by Juergen Keil <jk@tools.de>

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-06-02 16:00:45 +01:00
Keir Fraser 491c0ade25 iommu: Handle sibling device assignment correctly
Domctl interface is extended to allow libxc retrieve device group
information from hypervisor. Vendor-specific iommu_ops is also
extended by adding a new operation "get_device_group_id()", which is
currently a null pointer but could be implemented later for vt-d.

Error will be raised from tools side when user trying to assign PCI
device with a sibling device being driven by dom0. User will keep
being prompted until he has hidden the entire device group (at least,
the sibling devices driven by dom0) in dom0 kernel
parameter. Hopefully this framework could be flexible enough to
support both amd iommu and vt-d.

The following 2 cases are not covered by this patch, but should be
easy to handle.
* Checking for hot-plug devices (maybe we can delay calling
ImageHandler.signalDeviceModel() until all checks are done?)
* Checking for splitted device group between different passthru
domains

Signed-off-by: Wei Wang <wei.wang2@amd.com>
2008-05-28 14:41:23 +01:00
Keir Fraser 8543c562dd stubdom: complete libxc support
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
2008-05-23 09:35:23 +01:00
Keir Fraser a93dfae74e libxc: drop double un?lock_pages definition to fix static linking
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
2008-05-22 15:09:49 +01:00
Keir Fraser 2ce4e98c30 libxc, x86: Fix CPUID inline asm for x86/64.
Must save all 64 bits of RBX, not just the EBX sub-part.

Based on bug diagnosis and patch by Juergen Keil <jk@tools.de>

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-05-21 16:55:11 +01:00
Keir Fraser f219d911b7 Add statistic interface for cx.
Implement statistic interface for cx via sysctl & libxc. Provide a
easy way to collect processor cx info within dom0.

Signed-off-by: Wei Gang <gang.wei@intel.com>
2008-05-21 10:59:49 +01:00
Keir Fraser 2950bd57c1 Provide Px statistic data to user through libxc
Sampling and collecting dynamic Px statistic data, including
Px state value, Px count, Px residency time, Px transition
matrix, etc. Provide Px statistic data to user through libxc.

Signed-off-by: Liu Jinsong <jinsong.liu@intel.com>
2008-05-16 09:37:19 +01:00
Keir Fraser ff635e12aa x86, hvm: Support 2MB superpage allocations for HVM guests.
Signed-off-by: Xin Xiaohui <xiaohui.xin@intel.com>
Signed-off-by: Li Xin, B <xin.b.li@intel.com>
Signed-off-by: Wei Huang <wei.huang2@amd.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-05-15 11:09:16 +01:00
Keir Fraser 24f7da83f5 x86 hvm: Support MSI-X for HVM domains.
Signed-off-by: Shan Haitao <Haitao.shan@intel.com>
2008-05-12 10:07:26 +01:00
Keir Fraser 1aa3c54a31 Remove defunct powerpc port.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-05-08 13:40:40 +01:00
Keir Fraser 8bcb3b3622 minios: let events get mixed
since events do not need to be counted

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-05-06 16:29:01 +01:00
Keir Fraser 4fe64c6d1b shadow: track video RAM dirty bits
This adds a new HVM op that enables tracking dirty bits of a range of
video RAM.  The idea is to optimize just for the most common case
(only one guest mapping, with sometimes some temporary other
mappings), which permits to keep the overhead on shadow as low as
possible.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
2008-05-02 15:08:27 +01:00
Keir Fraser b2870e0a21 libxc foreign address translation bug
In the xc_translate_foreign_address function from libxc, there is a
check on the page directory entry to see if the page is 4K or 4M.
However, the check is looking at bit 3, when it should be looking at
bit 7.  This patch fixes the problem.

Signed-off-by: Bryan D. Payne <bryan@thepaynes.cc>
2008-05-02 13:46:16 +01:00
Keir Fraser 1d45c8ef8c x86 hvm cpuid: fix some problem with the hvm's cpuid configuration.
- When we overwrite a cpuid's input, apply the default policy
    for the other registers.
  - For the python binding, get unsigned long instead long.
  - Fix the multiple inputs cpuid's configuration parsing.

Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
2008-05-01 16:08:36 +01:00
Keir Fraser 85715f4bc7 MSI 5/6: add MSI support to passthrough HVM domain
Currently it only inercept access to MSI config space, no MSI-x support.

Signed-off-by: Jiang Yunhong <yunhong.jiang@intel.com>
Signed-off-by: Shan Haitao <haitao.shan@intel.com>
2008-05-01 10:33:03 +01:00
Keir Fraser ca0074e519 MSI 2/6: change the pirq to be per-domain
Signed-off-by: Jiang Yunhong <yunhong.jiang@intel.com>
Signed-off-by: Shan Haitao <haitao.shan@intel.com>
2008-05-01 10:30:22 +01:00
Keir Fraser 5f14a87ceb x86, hvm: Guest CPUID configuration.
CPUID's replies are now pre-calculated in libxc and given to the
hypervisor via a new domctl.

There are two parts to this feature:
   - We can overwrite cpuid's replies.
   - We can check that a vm is compatible with a host's processor.

Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-04-25 13:44:45 +01:00
Keir Fraser d5a22fa12f vmx: Fix address of EPT identity-map pagetable that is passed from the
domain builder down to the hypervisor.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-04-24 14:33:42 +01:00
Keir Fraser 98892a5e57 tools: Build fixes for *BSD.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-04-15 16:07:30 +01:00
Keir Fraser 8a7227082a libxenguest: Fix a typo.
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
2008-04-11 09:07:58 +01:00
Keir Fraser 1386e66a6e libxc: Move xg_memalign() into a proper source file, so that it
definitely does not leak out of tools/libxc. Return to the
ioemu/osdep.c way of checking for posix_memalign() as this works on
Solaris.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-04-09 17:49:25 +01:00
Keir Fraser 3cb6817ad5 libxc: Leave portability of xg_memalign() as in original patch, rather
than following ioemu/osdep.c. This unbreaks build of readnotes.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-04-09 16:54:44 +01:00
Keir Fraser 43650c346e save/restore: Use page-aligned allocations for hypercall args that are
mlock()ed across other hypercall invocations, to avoid aliasing with
other hypercall arguments, causing spurious unlocking.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2008-04-09 16:31:16 +01:00
Keir Fraser 9e4828ca8b x86 libxc: Fix mlock sizes in libxc around vcpu context hypercalls
backing off to the old behaviour if we fail.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2008-04-09 16:24:46 +01:00
Keir Fraser 2434aa5074 lsevtchn: Simple tool to list event channel states for a domain.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
2008-04-09 16:11:34 +01:00
Keir Fraser be4ba13470 hvm: Allocate memory for hvm domains in batches.
Without this change, dom0 is unresponsive while the hvm domain's
physmap is populated in xen.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2008-04-09 15:25:16 +01:00
Keir Fraser 1a74322648 save/restore: Batch contiguous page-sized writes together during domain save.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2008-04-09 15:19:09 +01:00
Keir Fraser e90bc46da3 x86, vmx: Enable EPT (Extended PageTable) support on new Intel processors.
We use the EPT page table as P2M (guest physical to machine
mapping), removing the linear page table when EPT is used for the
domain (see the new file p2m-ept.c). We did this by adding three
operations in the p2m_domain. If VT-d is enabled, the EPT page table
will be used as the VT-d page table as well (i.e. shared).

Signed-off-by: Xin Li <xin.b.li@intel.com>
Signed-off-by: Jun Nakajima <jun.nakajima@intel.com>
Signed-off-by: Xiaohui Xin <Xiaohui.xin@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-04-09 11:30:32 +01:00
Alex Williamson 0590d4e4cf merge with xen-unstable.hg 2008-04-01 11:29:03 -06:00
Keir Fraser f3bf1dc168 x86: Support loading Linux bzImage v2.08 and up.
The latest -mm kernel (2.6.25-rc3-mm1) contains v2.08 of the Linux
bzImage format which embeds an ELF file in place of the raw payload
allowing it to be extracted and used by the Xen domain builder.

It is expected that this functionality will be put forward for 2.6.26.

Signed-off-by : Ian Campbell <ijc@hellion.org.uk>
2008-04-01 10:09:33 +01:00
Alex Williamson 152d0f4ee0 merge with xen-unstable.hg 2008-03-20 12:35:40 -06:00
Keir Fraser f966bc9fc5 libxc: Remove permute() function from xc_domain_save().
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-03-19 12:41:48 +00:00
Keir Fraser 8491525fc2 ia64: Fix ACPI header inclusion into libxc.
Signed-off-by: Alex Williamson <alex.williamson@hp.com>
2008-03-18 21:05:47 +00:00
Keir Fraser 4097715c73 save/restore: Permute saved memory with 2MB chunk size.
The memory permutation cause a slow down in case of a save/restore
(bug 1143). It works better when the mixing is done with 2MB chunks.

Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
2008-03-18 19:36:43 +00:00
Keir Fraser 86d8fe5e6a libxc: Variable-size gntdev support
This patch adds the ability to set the number of slots that may be
used for mapping grant references, using the gntdev user-space grant
reference mapping driver.

Signed-off-by: Derek Murray <Derek.Murray@cl.cam.ac.uk>
2008-03-18 15:00:33 +00:00