Keir Fraser [Thu, 12 Jun 2008 14:22:35 +0000 (15:22 +0100)]
32-on-64: Clean up and unify compat_arg_xlat_area handling.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 12 Jun 2008 08:24:35 +0000 (09:24 +0100)]
minios can cope with >4G CR3 since it never uses it
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Wed, 11 Jun 2008 15:38:02 +0000 (16:38 +0100)]
MSI: Handle MSI EOI for amd systems
Signed-off-by: Wei Wang <wei.wang2@amd.com>
Keir Fraser [Wed, 11 Jun 2008 14:19:42 +0000 (15:19 +0100)]
MSI: Fix msi delivery for hvm guest
Some parameters like "dest_mode", "delivery_mode" and "trig_mode"
seem to have been miscalculated before delivering MSI interrupt into
hvm passthru guest. This will cause guest driver to roll back to
legacy interrupt mode.
Signed-off-by: Wei Wang <wei.wang2@amd.com>
Keir Fraser [Wed, 11 Jun 2008 14:18:26 +0000 (15:18 +0100)]
AMD IOMMU: Enable MSI for hvm guest
Signed-off-by: Wei Wang <wei.wang2@amd.com>
Keir Fraser [Wed, 11 Jun 2008 10:35:35 +0000 (11:35 +0100)]
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>
Keir Fraser [Wed, 11 Jun 2008 08:44:42 +0000 (09:44 +0100)]
Push python-related make variable definitions into tools/misc.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 11 Jun 2008 08:36:23 +0000 (09:36 +0100)]
Have `make install' write the Python version number in the #!
The Xen tools contain a number of Python extensions written in C. The
C API to Python, used by these extensions, is not stable from one
version of Python to the next.
Our build system uses whatever version of Python is the default on the
build system at that time to build these extensions. However, the
actual scripts such as `xm' use #!/usr/bin/env python which uses
whichever version of Python is the default on the deployment system at
the time of invocation.
If for any reason these two versions of Python are not the same (eg,
because the system is built on one computer and executed on another,
or because the system's gains a more recent Python installation
alongside the original which changes the previous default), warnings
and failures occur.
In this patch I arrange for Python scripts to be installed via a
special wrapper around `install', which determines the build-time
Python version and path and then writes that into the #! line at the
point of `make install' (or `make dist'). (It can also be overridden
by setting PYTHON_PATH.)
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Keir Fraser [Tue, 10 Jun 2008 15:59:24 +0000 (16:59 +0100)]
minios: Fix >4GB machine addresses
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Tue, 10 Jun 2008 14:30:50 +0000 (15:30 +0100)]
x86/64: Fix build.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Tue, 10 Jun 2008 13:53:01 +0000 (14:53 +0100)]
xend: minor ballooning cleanup
In xend/balloon.py, there's only one place where dom0_start_alloc_mb
is used. Move its initialization to right before its usage.
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Tue, 10 Jun 2008 13:51:00 +0000 (14:51 +0100)]
x86: Default ACPI reboot method.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Tue, 10 Jun 2008 13:17:20 +0000 (14:17 +0100)]
xenstore: Fix error path broken by c/s 17816
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Tue, 10 Jun 2008 13:15:53 +0000 (14:15 +0100)]
xenstat: some cleanups
sprintf -> snprintf
malloc(n * m) -> calloc(n, m)
get rid of a cast
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Tue, 10 Jun 2008 12:50:31 +0000 (13:50 +0100)]
xm on xenapi: Add PVFB support in xenapi_create.py.
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
Keir Fraser [Tue, 10 Jun 2008 12:49:54 +0000 (13:49 +0100)]
xenstore: cleanups
Attached patch uses calloc() for hash allocation.
This makes sure, the allocated memory is always initialized.
Also cleanup error handling a bit.
On *BSD avoid conflicts with BSD list macros.
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Tue, 10 Jun 2008 12:49:02 +0000 (13:49 +0100)]
libxc: Update for NetBSD
returns hypercall return value when ioctl was successful.
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Tue, 10 Jun 2008 12:45:29 +0000 (13:45 +0100)]
Pull in ACPI table parsing code from Linux 2.6.26-rc4.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Tue, 10 Jun 2008 08:27:01 +0000 (09:27 +0100)]
libxenstat: Fix statistics for blktap disks on linux
Overview: update xenstat vbd statistics parsing from
/sys/devices/xen-backend to process blktap disks
Reason:
-blktap devices (now referenced as tap rather than vbd in
/sys) have statistics counters
(e.g., rd_req, wr_req, oo_req) prepended by tap_
-xenstat behavior did not previously account for this
behavior, which resulted in 0 disks
visible and similarly impacted disk statistics
To reproduce these conditions, make a domain with tap:aio backed disks
on 3.2.x, run xentop, and press B to view VBD stats (nothing will
appear for the domain using tap:aio)
Signed-off-by: steve.maresca@gmail.com
Keir Fraser [Tue, 10 Jun 2008 08:25:47 +0000 (09:25 +0100)]
Fix the build with perfc=y.
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
Keir Fraser [Tue, 10 Jun 2008 08:24:47 +0000 (09:24 +0100)]
x86: Fix the build after HVMTRACE changes.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Tue, 10 Jun 2008 08:17:55 +0000 (09:17 +0100)]
tools/python/xen/lowlevel: some cleanups
Mainly:
malloc(n * m) -> calloc(n, m)
sprintf -> snprintf
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Mon, 9 Jun 2008 16:18:27 +0000 (17:18 +0100)]
Allow older PAE Linux guests to access entire compat m2p.
Older PAE guests (prior to xen-unstable.hg 8924:
229c602a075a, Feb
2006, this includes some vendor's kernel in the field) use a limit of
0xf6800000 on their code and data segments (i.e. up to the end of the
read-only m2p table).
Newer kernels use a limit of 4G and rely on the hypervisor to clamp to
the actual maximum allowed. 32on64 mode takes advantage of this to
allow a larger m2p than would fit in the PAEonPAE sized hole.
This means that PAE guests with the hardcoded low limit cannot run on
top of a 64 bit hypervisor on a host machine which has more than 16G
of RAM. Fix this by extending any code or data segment which ends
above the start of the hypervisor hole for that guest.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Keir Fraser [Mon, 9 Jun 2008 14:06:26 +0000 (15:06 +0100)]
libfsimage: make pygrub work on ufs
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Mon, 9 Jun 2008 14:05:18 +0000 (15:05 +0100)]
ioemu: simplyfing vga_draw_text code
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 12:26:30 +0000 (13:26 +0100)]
minios: add proper shutdown facilities
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 12:26:05 +0000 (13:26 +0100)]
stubdom: fetch command line from start_info instead of xenstore
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 12:25:35 +0000 (13:25 +0100)]
libxc: Use vpath rather than VPATH, to avoid linking with hypervisor .o files.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 9 Jun 2008 10:45:10 +0000 (11:45 +0100)]
stubdom: simplify xenfb resize handler
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 09:44:09 +0000 (10:44 +0100)]
When building from a tarball release use hardcoded path to
linux-2.6.18-xen.hg as a last resort when searching for a Linux source
tree.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Keir Fraser [Mon, 9 Jun 2008 08:51:14 +0000 (09:51 +0100)]
x86: Fix S3 resume after creating an HVM guest.
If we don't use PIT, we should disable it at boot time and at S3
resuming. In Xen this is done by disable_pit_irq(), but this function
is used by __initcall(). After bootstrap it will be discarded and may be
overwritten. This usually results in S3 resuming failure.
Signed-off-by: Huacai Chen <huacai.chen@intel.com>
Signed-off-by: Li Zhang <li.zhang@intel.com>
Keir Fraser [Mon, 9 Jun 2008 08:47:51 +0000 (09:47 +0100)]
xm on xenapi: Fixes for rfb console.
- set 'vncunused' param default to 1
- add 'vncdisplay' param
- handle the case when sdl=1
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
Keir Fraser [Mon, 9 Jun 2008 08:47:00 +0000 (09:47 +0100)]
stubdom: document that pty usage should be disabled
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 08:46:46 +0000 (09:46 +0100)]
stubdom: make non-VNC + stdvga work
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 08:46:32 +0000 (09:46 +0100)]
stubdom: permit compilation without lwip
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 08:46:16 +0000 (09:46 +0100)]
minios: use inlines instead of macros for bswap*
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 08:45:38 +0000 (09:45 +0100)]
xentrace: fix tracing for 64bit guests
Xen tracing some times ago used to put values of type 'long' into the
trace buffer. This has changed to uint32_t. Some trace points log
virtual addresses, which get cropped to 32bit in this case. There were
some inline functions to handle at least PF_XEN and VMEXIT, which
caused a lot of code duplication. The attached patch fixes several
issues:
1. fix and extend tools/xentrace/formats
2. Fix xentrace_format to handle up to 7 parameters
3. create convenience macros to properly log long values
4. remove the inline functions in hvm/trace.h and replace them by macros
5. Change the CPUID trace to work correctly
6. group HVM trace points enable mechanism
I used a similar approach as in PV tracing with bit 8 indicating 64bit
pointers.
Signed-off-by: Andre Przywara <andre.przywara@amd.com>
Keir Fraser [Mon, 9 Jun 2008 08:44:21 +0000 (09:44 +0100)]
AMD IOMMU: add support for PV guest
Assuming iommu_populate_page_table() is only used for PV guest, a new
check is added into assign_device() to avoid duplicating the work done
by amd_iommu_sync_p2m() for hvm guest.
Signed-off-by: Wei Wang <wei.wang2@amd.com>
Keir Fraser [Mon, 9 Jun 2008 08:42:51 +0000 (09:42 +0100)]
xend: Use get_config_string for 'keymap' and 'resource-label-change-script'.
Signed-off-by: Juergen Keil <jk@tools.de>
Keir Fraser [Mon, 9 Jun 2008 08:42:14 +0000 (09:42 +0100)]
stubdom: prevent newlib from emiting cli/sti in longjmp
Also fix build dependencies and cleanup.
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 08:39:15 +0000 (09:39 +0100)]
ioemu: cleaning DisplayState->dpy_resize interface
Bring the DisplayState dpy_resize interface back to how it is in qemu
mainstream, thus making the code easier to merge.
In order to support sharing the framebuffer, I am adding a new resize
interface called dpy_resize_shared that also has a depth and a pixels
parameters. As a consequence I could remove the dpy_colourdepth
callback and make the code cleaner and easier to read.
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Keir Fraser [Mon, 9 Jun 2008 08:37:56 +0000 (09:37 +0100)]
acm: check for duplicate labels and types
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
Keir Fraser [Mon, 9 Jun 2008 08:37:22 +0000 (09:37 +0100)]
acm: Allow remove of labels from suspended domains.
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
Keir Fraser [Mon, 9 Jun 2008 08:36:27 +0000 (09:36 +0100)]
xm: Set device_model option value default to None.
If device_model is set to '', xend will fail to execute the device
model. If None, xend will detect it and set a sensible qemu-dm path
instead.
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
Keir Fraser [Mon, 9 Jun 2008 08:36:07 +0000 (09:36 +0100)]
xm on xenapi: Enable more platform configurations
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
Keir Fraser [Thu, 5 Jun 2008 12:04:07 +0000 (13:04 +0100)]
stubdom: .hgignore updates
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Thu, 5 Jun 2008 12:03:47 +0000 (13:03 +0100)]
stubdom: upgrade lwip to newer upstream version since it provides bugfixes
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Thu, 5 Jun 2008 12:03:31 +0000 (13:03 +0100)]
minios: add a blkfront synchronous interface
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Thu, 5 Jun 2008 09:47:08 +0000 (10:47 +0100)]
32-on-64: Fix physaddr_bitsize computation when creating a 32b x86
compat domain.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 5 Jun 2008 09:42:37 +0000 (10:42 +0100)]
x86, p2m: Fix typo in p2m_change_type_global().
From: Wei Huang <wei.huang2@amd.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 5 Jun 2008 09:36:19 +0000 (10:36 +0100)]
x86 hvm: Improve paging performance for 64b solaris guests
The following patch provides a 'fast-path' for sh_remove_write_access()
for 64 bit Solaris HVM guests. This provides a significant performance
boost for such guests; our testing shows a 200-400% improvement in
microbenchmarks such as fork(), exit(), etc...
From: Gary Pennington <Gary.Pennington@sun.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 5 Jun 2008 09:34:01 +0000 (10:34 +0100)]
xen: build fix for NetBSD (test -x usage).
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Thu, 5 Jun 2008 09:33:01 +0000 (10:33 +0100)]
libfsimage: Build fix for NetBSD.
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir Fraser [Thu, 5 Jun 2008 09:31:17 +0000 (10:31 +0100)]
xm: Fix formatting of xm block-list output.
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Thu, 5 Jun 2008 09:30:29 +0000 (10:30 +0100)]
Fix blkif.py for virsh start
I defined a cdrom to a guest domain as follows.
",hdc:cdrom,r"
When the guest domain was created by using xm create command, uname
of the cdrom was ''. Then creating the guest domain succeeded.
[2008-06-03 15:23:41 xend.XendDomainInfo 25956] DEBUG
(XendDomainInfo:200)
XendDomainInfo.create(['vm', ['name', 'rhel5.2ga_hvm_lvol1'],
<<snip>>
['device', ['vbd', ['uname', ''], ['dev', 'hdc:cdrom'], ['mode',
'r']]],
<<snip>>
But, when the guest domain was created by using virsh start command,
uname of the cdrom was None. Then creating the guest domain failed.
[2008-06-03 15:22:10 xend.XendDomainInfo 25559] DEBUG
(XendDomainInfo:200)
XendDomainInfo.create(['vm', ['name', 'rhel5.2ga_hvm_lvol1'],
<<snip>>
['device', ['vbd', ['dev', 'hdc:cdrom'], ['mode', 'r']]],
<<snip>>
This patch fixes to be able to create guest domains by both xm create
command and virsh start command.
FYI:
"if uname is None:" --> "if uname == '':" --> "if not uname:"
till CS#17625 current by this patch
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Tue, 3 Jun 2008 08:41:19 +0000 (09:41 +0100)]
Improve HPET comparator reprog to prevent intr-near-missing case
HPET intr-near-missing means if the current counter value is too close
to the comparator value to be reprogrammed the expected HPET intr may
be missing. Linux kernel uses a mininal 48-hpet-ticks(~3.5us) distance
to workaround this, but personal observation showed there is still
failure case while delta=3D0xba (~13.5us). So choosing 20us as the
MIN_DELTA_NS should be helpful to prevent near-missing from happening.
local_irq_save/restore were used to avoid disturbance. (+ 2) was used
as a final guard to avoid wrong judgement due to the real happened
near-missing case.
Signed-off-by: Wei Gang <gang.wei@intel.com>
Signed-off-by: Tian Kevin <kevin.tian@intel.com>
Keir Fraser [Tue, 3 Jun 2008 08:35:02 +0000 (09:35 +0100)]
x86: Enhance Cx stability by adding softirq check before entry cstate
Without checking softirq_pending before entry Cx state, softirq such
as SCHEDULE_SOFTIRQ and TIMER_SOFTIRQ can't be handled timely. It may
cause severe failures such as disk I/O failure.
This patch addresses the issue above, meanwhile move timing points
closer to cstate entry/exit point to make C3 residency more accurate,
and enable irq a little earlier.
Signed-off-by: Wei Gang <gang.wei@intel.com>
Signed-off-by: Tian Kevin <kevin.tian@intel.com>
Keir Fraser [Tue, 3 Jun 2008 08:33:41 +0000 (09:33 +0100)]
xend: implement VM_hard_reboot of XenAPI.
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Tue, 3 Jun 2008 08:32:50 +0000 (09:32 +0100)]
stubdom: Add console reading support
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Mon, 2 Jun 2008 15:05:07 +0000 (16:05 +0100)]
rombios: S3 resume fixes.
On AMD cpus, HVM S3 resume was hanging in the bios when trying
to load the x_firmware_waking_vector from absolute
address 0xEA01C (that is, a segment offset greater than 64kB).
This change also now uses 20-bits (instead of 16) from the FACS
standard firmware_waking_vector.
Signed-off-by: Juergen Keil <jk@tools.de>
Keir Fraser [Mon, 2 Jun 2008 15:00:45 +0000 (16:00 +0100)]
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>
Keir Fraser [Mon, 2 Jun 2008 09:56:52 +0000 (10:56 +0100)]
Remove domain_pause()/domain_unpause() from SCHEDOP_remote_shutdown.
It is pointless and causes the hypervisor to hang if dom0 invokes this
hypercall on itself.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 2 Jun 2008 09:55:55 +0000 (10:55 +0100)]
vmx: Better diagnostic messages when VMXON might have failed due to
bad setting of the IA32_FEATURE_CONTROL MSR.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 2 Jun 2008 09:04:19 +0000 (10:04 +0100)]
vtd: Fix pagetable teardown on domain detsruction.
Signed-off-by: Xiaowei Yang <xiaowei.yang@intel.com>
Keir Fraser [Mon, 2 Jun 2008 09:03:18 +0000 (10:03 +0100)]
vtd: build fix.
Signed-off-by: Akio Takebe <takebe_akio@jp.fujitsu.com>
Isaku Yamahata [Mon, 2 Jun 2008 02:35:39 +0000 (11:35 +0900)]
merge with xen-unstable.hg
Isaku Yamahata [Mon, 2 Jun 2008 02:35:02 +0000 (11:35 +0900)]
[IA64] compilation fix of c/s 17723:
c684cf331f94
This patch fixes the compilation error caused by the c/s 17723:
c684cf331f94.
Define stub functions which return -ENOSYS.
ia64-linux-gnu-ld -g -T xen.lds.s -N \
-Map map.out linux-xen/head.o xen-unstable.hg/xen/common/built_in.o xen-unstable.hg/xen/drivers/built_in.o xen-unstable.hg/xen/xsm/built_in.o xen-unstable.hg/xen/arch/ia64/built_in.o \
xen-unstable.hg/xen/common/symbols-dummy.o -o xen-unstable.hg/xen/xen-syms
xen-unstable.hg/xen/common/built_in.o: In function `__gnttab_unmap_common':
xen-unstable.hg/xen/common/grant_table.c:566: undefined reference to `iommu_unmap_page'
xen-unstable.hg/xen/common/built_in.o: In function `__gnttab_map_grant_ref':
xen-unstable.hg/xen/common/grant_table.c:388: undefined reference to `iommu_map_page'
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Keir Fraser [Sun, 1 Jun 2008 08:16:26 +0000 (09:16 +0100)]
x86: Fix teardown of relocated vcpu_info structures.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 30 May 2008 18:31:18 +0000 (19:31 +0100)]
x86: i8254 device model is shared between PV and HVM guests, so must
take care not to run hvm_get_guest_time() on a PV VCPU. The spinlock
is not initialised and spin_lock() can thus spin forever.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 30 May 2008 15:44:13 +0000 (16:44 +0100)]
x86 hvm: Fix task-switch operation ordering.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 30 May 2008 15:30:40 +0000 (16:30 +0100)]
x86 hvm: Support task switch when task state segments straddle page
boundaries. Also improve error diagnostics from hvm_map().
Fixes multi-processor shutdown for some types of Windows OS.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 30 May 2008 15:04:20 +0000 (16:04 +0100)]
Add xen_phys_start value in the crash info note
This patch makes the vmcore utilities (ex. crash, makedumpfile) be
able to get the relocation address of the xen hypervisor from a
vmcore. It is necessary for the utilities to find the data of the
hypervisor structures.
Note that this patch does not raise any comptibility issue for the
utilities (which I know) nor the other components of xen.
Signed-off-by: Itsuro Oda <oda@valinux.co.jp>
Keir Fraser [Fri, 30 May 2008 14:09:40 +0000 (15:09 +0100)]
[IA64] compilation fix of iommu.h
Trivial compilation fix of iommu.h.
It includes asm/msi.h for struct msi_desc and struct msi_msg
definition.
msi.h doesn't exist yet on ia64 so declare struct msi_desc and
struct msi_msg in iommu.h and don't include asm/msi.h.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Keir Fraser [Fri, 30 May 2008 14:06:08 +0000 (15:06 +0100)]
vtd: Various cleanups and fixes:
* Handle DRHDs with different supported AGAWs. To support this we
create page tables which always have 4 levels, and skip top levels
for units which support only 2 or 3 levels.
* Handle systems with mixed DRHD support for cache snooping. We must
pessimistically CLFLUSH if any DRHD does not support snooping.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 29 May 2008 13:30:48 +0000 (14:30 +0100)]
vtd: Remove dead code.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 29 May 2008 12:38:31 +0000 (13:38 +0100)]
xend: Add node parameter to do_migrate() for HTTP interface
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Thu, 29 May 2008 10:19:16 +0000 (11:19 +0100)]
ia64: Do not guest_physmap_remove_page() old page in gnttab_transfer op.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 29 May 2008 08:42:59 +0000 (09:42 +0100)]
x86: Fix reboot failure after S3
"warm reset vector" is used to start APs. At booting time, it is set
by BP, and cleared after all APs have started. When do S3, similar work
need to do. However, when enable non-boot CPUs after S3, Xen just sets
this vector, but forgets to clear it after APs startup.
Signed-off-by: Huacai Chen <huacai.chen@intel.com>
Keir Fraser [Thu, 29 May 2008 08:40:07 +0000 (09:40 +0100)]
pv-on-hvm: Change barrier from rmb to wmb.
Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>
Keir Fraser [Thu, 29 May 2008 08:39:23 +0000 (09:39 +0100)]
vtd: addr_to_dma_page_maddr() must release its lock.
Signed-off-by: Xiaowei Yang <xiaowei.yang@intel.com>
Keir Fraser [Wed, 28 May 2008 15:14:10 +0000 (16:14 +0100)]
vtd: More TLB flush fixes.
- Made the non-present flush testing a bit simpler.
- Removed dma_addr_level_page_maddr(). Use a modified
addr_to_dma_page_maddr() instead.
- Upon mapping new context entry: flush old entry using domid 0 and
always flush iotlb.
Signed-off-by: Espen Skoglund <espen.skoglund@netronome.com>
Keir Fraser [Wed, 28 May 2008 13:41:23 +0000 (14:41 +0100)]
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>
Keir Fraser [Wed, 28 May 2008 11:22:36 +0000 (12:22 +0100)]
ioemu: set up all xenstore watches even if there are no VBDs.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Keir Fraser [Wed, 28 May 2008 10:43:37 +0000 (11:43 +0100)]
grant_table: Flush host CPU TLBs during grant transfer.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Isaku Yamahata [Wed, 28 May 2008 09:10:44 +0000 (18:10 +0900)]
[IA64] cleanup: vcpu_set_psr_sm.
It is pointless to set the machine psr.
Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>
Keir Fraser [Wed, 28 May 2008 09:05:57 +0000 (10:05 +0100)]
vtd: TLB flush fixups.
Signed-off-by: Xiaowei Yang <xiaowei.yang@intel.com>
Keir Fraser [Wed, 28 May 2008 09:02:00 +0000 (10:02 +0100)]
hvmloader: No need to map shared_info page into the legacy VGA MMIO
hole. We can access address 0xfffff000 from 32-bit protected mode.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 28 May 2008 08:31:49 +0000 (09:31 +0100)]
vtd: IOTLB flush fixups
On map: only flush when old PTE was valid or invalid PTE may be
cached.
On unmap: always flush old entry, but skip flush for unaffected
IOMMUs.
Signed-off-by: Espen Skoglund <espen.skoglund@netronome.com>
Keir Fraser [Wed, 28 May 2008 08:31:04 +0000 (09:31 +0100)]
stubdom: Save main_thread value by moving it out from app_bss which
gets cleared.
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Wed, 28 May 2008 08:30:48 +0000 (09:30 +0100)]
stubdom: make the build more generic by moving as many stubdom parts
into stubdom/ as possible. That also permits to build all of
ioemu, c and caml stubdoms at the same time.
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Wed, 28 May 2008 08:29:05 +0000 (09:29 +0100)]
vtd: interrupt remapping for MSI/MSI-x.
Signed-off-by: Weidong Han <weidong.han@intel.com>
Keir Fraser [Wed, 28 May 2008 08:28:42 +0000 (09:28 +0100)]
vtd: Fix bugs of ioapic interrupt remapping.
Signed-off-by: Weidong Han <weidong.han@intel.com>
Signed-off-by: Allen Kay <allen.m.kay@intel.com>
Keir Fraser [Tue, 27 May 2008 12:03:05 +0000 (13:03 +0100)]
minios: We do not need to pin the page tables, as they implicitly get
pinned when we point the permanent page directory to them.
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Keir Fraser [Tue, 27 May 2008 10:51:33 +0000 (11:51 +0100)]
ioemu: Force floppy disk images to be interpreted as raw.
Fixes specifying fda/fdb image names in domain configs.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Tue, 27 May 2008 10:50:43 +0000 (11:50 +0100)]
Revert 17731:
eafb252f141.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Tue, 27 May 2008 09:35:10 +0000 (10:35 +0100)]
Fix 17725:
c0c0f4fa8850: use type paddr_t instead of unsigned long for physcial memory address
Otherwise, the address overflows on PAE system with memory size > 4G.
Signed-off-by: Yang, Xiaowei <xiaowei.yang@intel.com>
Keir Fraser [Tue, 27 May 2008 09:31:55 +0000 (10:31 +0100)]
xend: fix a typo in domain_migrate().
- @rtype: -> @type node:
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Tue, 27 May 2008 09:31:25 +0000 (10:31 +0100)]
xend: add a reset button to Web interface.
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Mon, 26 May 2008 07:53:25 +0000 (08:53 +0100)]
xend: take care of dead qemu-dm process
This patch fix xend as when fatal error happened (e.g. qemu-dm process
was killed) log error message then mark that domain as crashed, do
what specified on crashed in the domain config file. Added some code in
xend to check those crashed hvm DM status each 30 seconds.
Signed-off-by: Xiaowei Hu <xiaowei.hu@oracle.com>
Keir Fraser [Mon, 26 May 2008 07:45:59 +0000 (08:45 +0100)]
x86 hvm: Drop pagetable reference when resetting a VCPU to real mode.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>