Commit Graph
6564 Commits
Author SHA1 Message Date
Keir Fraser 08a42ca0b5 pvSCSI: xend changes
Signed-off-by: Tomonari Horikoshi <t.horikoshi@jp.fujitsu.com>
Signed-off-by: Jun Kamada <kama@jp.fujitsu.com>
2008-07-03 13:39:06 +01:00
Keir Fraser d2831c8ba9 xm-test: Remove a policy reset from acm test case
Remove the resetting of the policy from this point in the test case
since the new default policy has the '__UNLABELED__' label, which is
not expected in subsequent checks.

Signed-off-by; Stefan Berger <stefanb@us.ibm.com>
2008-07-03 11:32:10 +01:00
Keir Fraser 8d574cc772 vtpm: Add two missing quotes in the vTPM hotplug script.
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2008-07-03 11:31:40 +01:00
Keir Fraser c896dc3dcc ioemu: Explicitly define certain PCI/MSI macros.
From: Haitao Shan <haitao.shan@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-07-03 10:59:43 +01:00
Keir Fraser 554a3a3375 Support building of out-of-tree merged qemu from git
This provides support for building the new merged qemu from
qemu-xen.git, or from a local checkout.

The default is still to use the in-tree version, because the patchman
infrastructure for testing, and propagation from staging to
xen-unstable, needs a small amount of work to cope with git.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
2008-07-03 10:44:13 +01:00
Keir Fraser 8e65d32968 XenAPI: Add Direct PCI Device (DPCI) Assignment Support
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
2008-07-03 10:27:12 +01:00
Keir Fraser 5a940c0997 XenAPI: Add Physical PCI Device (PPCI) Support
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
2008-07-03 10:26:16 +01:00
Keir Fraser de4e084064 stubdom: PCI passthrough support via PV-PCI
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
2008-07-02 13:54:20 +01:00
Keir Fraser badc969545 ioemu: Add check for mapping MSI pirqs.
From: Haitao Shan <haitao.shan@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-07-02 09:45:18 +01:00
Keir Fraser aa506f9185 xend: Replace stray tab-indent with space-indent
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
2008-07-02 09:42:37 +01:00
Isaku Yamahata 3819ac39eb merge with xen-unstable.hg 2008-07-02 11:30:37 +09:00
Keir Fraser b484177fb7 xenballoond (memory overcommit) scripts
See the README and conf files for more info.

Signed-off-by: Dan Magenheimer <dan.magenheimer@oracle.com>
2008-07-01 11:40:07 +01:00
Keir Fraser 9c28c1b8b9 ioemu: limit xen-console buffering
Set dom->buffer.max_capacity to xend configured limit.

Signed-off-by: Pat Campbell <plc@novell.com>
2008-07-01 11:38:51 +01:00
Keir Fraser 03f7fd7c9f xend: open qemu-dm logfile in append mode if log rotation is disabled by config.
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
2008-07-01 10:59:09 +01:00
Keir Fraser da67ff89f7 xend: improve the rotation of qemu-dm logfiles.
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
2008-07-01 10:58:43 +01:00
Keir Fraser 1be51142f1 x86_emulate: read/write/insn_fetch emulation hooks now all take a
pointer to emulator data buffer, and an arbitrary byte count (up to
the size of a page of memory).

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-06-30 14:19:09 +01:00
Keir Fraser 04465fbeb9 blktap: Fall back to libcrypto if libgcrypt is not installed.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-06-30 11:39:10 +01:00
Keir Fraser dd258ce6c0 tools/python: fix TypeError for 17903:0728459b3c8d
If `hda' is used in domU config file and domain-0 has /dev/hda,
creating a domain failed by TypeError:

  File "//usr/lib/python/xen/xend/server/blkif.py", line 84, in
getDeviceDetails
    (device_path, devid) = blkif.blkdev_name_to_number(dev)
TypeError: unpack non-sequence

Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
2008-06-30 10:02:21 +01:00
Keir Fraser 2bb1ceab62 Fix up python breakage for blkdev_name_to_number
Signed-off-by: Chris Lalancette <clalance@redhat.com>
2008-06-30 10:01:44 +01:00
Keir Fraser 53a29c4ca7 blktap: link against libgcrypt rather than libcrypto
tapdisk, part of blktap, links against libcrypto. tapdisk includes
GPLv2 (tapaio.c) and other licensed code (block-qcow.c). The license
of OpenSSL is considered incompatible with the GPL by many
people. This patch changes them to link against libgcrypt, which is
LGPL.

Signed-off-by: Bastian Blank <waldi@debian.org>
2008-06-30 10:00:53 +01: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 bbc24abfb2 tools/python: blkdev_name_to_number fixes
Rework blkdev_name_to_number to allow the tools to attach xvd disks
beyond xvdp.

 1.  Adds the handling for the /dev/xvd[q-z] and /dev/xvd[a-i][a-z]
     extended devices

 2.  Changes blkdev_name_to_number() to return a tuple of (xenbus,
     devnum), and then deals with the resulting fallout.

Signed-off-by: Chris Lalancette <clalance@redhat.com>
2008-06-27 16:09:58 +01:00
Keir Fraser 4fe815abd1 blktap: Extend userland busid to 32 bits
Signed-off-by: Chris Lalancette <clalance@redhat.com>
2008-06-27 16:08:56 +01:00
Keir Fraser da43e50cb3 hvm rombios: Move function calls out of 'post' function section
Through recent additions to the rombios the code section of the post
function has filled up considerably. When I enable the BX_TCGBIOS
compile time option the BIOS crashes since the post section code
(starts at $e05b) spills over into the nmi entry point (starts at
$e2c3). as86 doesn't cause an error when building.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2008-06-27 14:43:29 +01:00
Keir Fraser 60b316162b ioemu: Clean up after cset 17646:e3b13e1ecf6c
Remove redundant code.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
2008-06-27 14:16:53 +01:00
Keir Fraser 9a5fd91e50 hvmloader: Set up any Intel ICH for legacy IDE.
Signed-off-by: Li Zhang <li.zhang@intel.com>
2008-06-27 14:15:11 +01:00
Keir Fraser c8af9ce961 tapdisk: Fix qcow2 for images > 2 GB
Signed-off-by: Kevin Wolf <kwolf@suse.de>
2008-06-27 14:03:52 +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 8da3809869 ioemu: Fix usbdevice parameter to encode vbd type.
usbdevice = "disk:<filename>"
expect a raw device (as this probably is the most usual case) and
   usbdevice = "disk-qcow:<filename>"
expect a COW image (autodetected, probably qcow2).

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
2008-06-18 11:55:34 +01:00
Keir Fraser cc5871d6da ioemu: generic PCI device config-space emulation
This patch is an extension for qemu-dm to enable emulation of generic
PCI devices. The information for the PCI devices can be passed by
command line parameter.

The command line parameter is "-pciemulation" followed by the
information which contains a label and hex value of the configuration
registers separated by ":".

The configuration registers for each PCI device are below.
vendorid
deviceid
command
status
revision
classcode
headertype
subvendorid
subsystemid
interruputline
interruptpin

This is an example of command line parameter.

 -pciemulation hba1:1240:0780:0002:0:0:010000:0:10b5:0777:05:1

Signed-off-by: Shinji Matsumoto <smatsumoto@marathontechnologies.com>
2008-06-18 09:40:39 +01:00
Keir Fraser 0a8346854e ioemu: Disable format auto-probing in monitor command change
Format auto-probing of writable images is a security hole.  The last
known remaining instance is monitor command change.  Disable probing
there and use raw.  This breaks change for images in all other
formats.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
2008-06-18 09:39:14 +01:00
Keir Fraser 5201eb72cb doc: Describes a generic 686 via the cpuid configure.
Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
2008-06-18 09:37:40 +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 dbd56b5c30 minios,stubdom: Add OBJ_DIR parameter to compile outside sources,
which permits to easily compile mini-os in various flavors. Also clean
some parts of stubdom build.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
2008-06-17 09:36:25 +01:00
Keir Fraser 96d7365113 ioemu: move xenfb frontend (used by stubdom) to its own file, since it
does not really belong to hw/, but to /, like sdl.c and vnc.c.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
2008-06-17 09:35:36 +01:00
Keir Fraser 8b53284ae7 [ACM] Pass uuid to created policy
A UUID needs to be passed to the created policy.

Signed-off-by: stefan Berger <stefanb@us.ibm.com>
2008-06-13 13:55:50 +01:00
Keir Fraser 639bf0b3c7 [ACM] Enable labeling of resources as inaccessible
Enable the labeling of (disk-type) resources with the special label
__INACCESSIBLE__ to prevent unlabeled domains from accessing them.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2008-06-13 13:55:19 +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 fb0cba646e xend: detect and report qemu-dm failure
Currently, when qemu-dm fails, typically its exit status is lost and
xend doesn't notice.  In the patch below I use a fifo (named pipe) to
detect qemu-dm's termination and report the exit status to the
logfile, if possible.  (If xend has been restarted since the domain
was created, this isn't possible but we can still know that it failed
and report that fact.)

It would be better to have a failure of qemu crash the domain, by
calling the SCHEDOP_shutdown hypercall with SHUTDOWN_crash.  However
if you have on_crash=restart and the configuration is broken in some
way that causes qemu-dm to bomb out straight away this causes xend to
spin endlessly restarting the doomed domain.  This is a general
problem with on_*=restart and ought to be fixed separately.  When it
is fixed, we can safely arrange for domains whose dm has crashed to be
themselves forcibly crashed.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
2008-06-12 17:01:31 +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
Keir Fraser cd6d8982db Push python-related make variable definitions into tools/misc.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-06-11 09:44:42 +01:00
Keir Fraser 9f88f46834 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>
2008-06-11 09:36:23 +01:00
Isaku Yamahata d20f38afda merge with xen-unstable.hg 2008-06-19 12:46:26 +09:00
Keir Fraser fa3226f8f3 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>
2008-06-10 14:53:01 +01:00
Keir Fraser aefef84f02 xenstore: Fix error path broken by c/s 17816
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
2008-06-10 14:17:20 +01:00
Keir Fraser d8be3b59d1 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>
2008-06-10 14:15:53 +01:00