]> xenbits.xensource.com Git - xen.git/log
xen.git
17 years agodocs: Update xencons- Linux boot parameter to reflect xvc0 is default.
Keir Fraser [Wed, 23 Apr 2008 16:01:43 +0000 (17:01 +0100)]
docs: Update xencons- Linux boot parameter to reflect xvc0 is default.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agodocs: Update for Xen boot parameter changes.
Keir Fraser [Wed, 23 Apr 2008 13:22:20 +0000 (14:22 +0100)]
docs: Update for Xen boot parameter changes.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoDrop characters if an asynchronous serial tx buffer fills up.
Keir Fraser [Wed, 23 Apr 2008 13:17:35 +0000 (14:17 +0100)]
Drop characters if an asynchronous serial tx buffer fills up.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoNew boot parameter 'serial_tx_buffer=<size>' to change serial
Keir Fraser [Wed, 23 Apr 2008 13:06:51 +0000 (14:06 +0100)]
New boot parameter 'serial_tx_buffer=<size>' to change serial
transmit buffer size from default of 16kB.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agovt-d: Reduce printk() output to a more sensible level.
Keir Fraser [Wed, 23 Apr 2008 12:51:55 +0000 (13:51 +0100)]
vt-d: Reduce printk() output to a more sensible level.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoACM: Put hash of XML policy into binary policy to tie them together
Keir Fraser [Wed, 23 Apr 2008 12:29:09 +0000 (13:29 +0100)]
ACM: Put hash of XML policy into binary policy to tie them together

This patch extends the ACM binary policy format with an embedded hash
of the corresponding XML policy in order to tie them together. This
allows xend to determine whether it has the correct XML policy in its
repository and react appropriately if it does not have it.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
17 years agox86: Fix a typo in shadow_get_and_create_l1e().
Keir Fraser [Wed, 23 Apr 2008 12:32:58 +0000 (13:32 +0100)]
x86: Fix a typo in shadow_get_and_create_l1e().

The typo is benign because sh_page_fault() gates the call to
shadow_get_and_create_l1e() on an equivalent test.

Signed-off-by: Tim Deegan <tim.deegan@citrix.com>
17 years agoRevert 17499:451ae3b8e5c8
Keir Fraser [Wed, 23 Apr 2008 12:30:24 +0000 (13:30 +0100)]
Revert 17499:451ae3b8e5c8

Breaks HVM guest creation (bugzilla #1221).

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86: Reduce assertion aggressiveness in send_IPI_mask().
Keir Fraser [Wed, 23 Apr 2008 08:15:34 +0000 (09:15 +0100)]
x86: Reduce assertion aggressiveness in send_IPI_mask().
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agofiglet: Fix handling of full final line of octal output.
Keir Fraser [Wed, 23 Apr 2008 08:02:15 +0000 (09:02 +0100)]
figlet: Fix handling of full final line of octal output.
It should not be terminated with a backslash.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agovt-d: Clean up and fix dom0 initialisation.
Keir Fraser [Tue, 22 Apr 2008 18:07:48 +0000 (19:07 +0100)]
vt-d: Clean up and fix dom0 initialisation.
Based on a patch by Weidong Han <weidong.han@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86/hvm: fix copy-and-paste mistakes
Keir Fraser [Tue, 22 Apr 2008 13:40:34 +0000 (14:40 +0100)]
x86/hvm: fix copy-and-paste mistakes
Signed-off-by: Jan Beulich <jbeulich@novell.com>
17 years agoblktap: Automatically start tapdisk-ioemu on demand
Keir Fraser [Tue, 22 Apr 2008 13:39:33 +0000 (14:39 +0100)]
blktap: Automatically start tapdisk-ioemu on demand

When a domain wants to use a tap:ioemu disk but has no device model,
start a tapdisk-ioemu instance as provider. Also, move the creation
and removal of communication pipes to xend so that qemu-dm doesn't
need the unwanted SIGHUP handler anymore.

Signed-off-by: Kevin Wolf <kwolf@suse.de>
17 years agox86_emulate: Support CMPXCHG16B.
Keir Fraser [Tue, 22 Apr 2008 13:34:16 +0000 (14:34 +0100)]
x86_emulate: Support CMPXCHG16B.

Also clean up cmpxchg() callback handling so we can get rid of teh
specific cmpxchg8b handler.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86 iommu: Better synchronisation on dirq_mask.
Keir Fraser [Tue, 22 Apr 2008 10:46:41 +0000 (11:46 +0100)]
x86 iommu: Better synchronisation on dirq_mask.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86_emulate: Disable writeback if BSF/BSR are passed zero input.
Keir Fraser [Tue, 22 Apr 2008 10:44:56 +0000 (11:44 +0100)]
x86_emulate: Disable writeback if BSF/BSR are passed zero input.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86: Fix handling of BSF and BSR instructions.
Keir Fraser [Tue, 22 Apr 2008 10:43:10 +0000 (11:43 +0100)]
x86: Fix handling of BSF and BSR instructions.

 1. We cannot rely on BSF/BSR leaving the destination register intact
    if the source is zero (according to Intel manuals)
 2. We race clear_bit() in find_first_bit(), which may occur after
    SCAS but before BSF. So we must handle zero input to BSF.

Signed-off-by: Naoki Nishiguchi <nisiguti@jp.fujitsu.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoconsole: Provide option to stall the inter-domain console ring rather
Keir Fraser [Tue, 22 Apr 2008 09:34:55 +0000 (10:34 +0100)]
console: Provide option to stall the inter-domain console ring rather
than discard characters in the console daemon buffers.

New option: -o, --overflow-data=discard|keep

This option changes the behaviour when dealing with data that overflow
the max capacity of the buffer. If overflow-data is set to discard
(the default), the current behaviour is used: we discard some data in
the middle of the buffer.

If overflow-data is set to keep, we stop listening to the ring until
we free some space in the buffer. This can cause the ring to fill up
and the guest kernel internal buffer to fill up as well. When this
happens the guest kernel stops reading characters from the console
device so the application generating data hangs. When xenconsoled
resumes reading from the ring, the guest kernel will be able to resume
reading from the console device as well. At that point the guest
application will be allowed to continue.

The risk of making this behaviour the default is that existing kernel
drivers may assume they can rely on timely ring updates by the console
daemon and thus themselves block on the ring being emptied.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
17 years agohotplug scripts: Fix sharing check for blktap
Keir Fraser [Tue, 22 Apr 2008 09:29:32 +0000 (10:29 +0100)]
hotplug scripts: Fix sharing check for blktap

Run check_blktap_sharing() only when a disk is added to guest with blktap.
A check_blktap_sharing() doesn't have to be run when a disk is removed.

Signed-off-by: Hirofumi Tsujimura <tsujimura.hirof@jp.fujitsu.com>
Signed-off-by: Takanori Kasai <kasai.takanori@jp.fujitsu.com>
17 years agox86_emulate: BT instruction does not write to its 'destination' operand.
Keir Fraser [Tue, 22 Apr 2008 09:27:04 +0000 (10:27 +0100)]
x86_emulate: BT instruction does not write to its 'destination' operand.

This fixes w2k3 guests occasionally writing back to read-only registers.

Signed-off-by: Xu Dongxiao <dongxiao.xu@intel.com>
17 years agovt-d: Fix a bug in addr_to_dma_page_maddr(), and add timeout in infinite loop
Keir Fraser [Tue, 22 Apr 2008 09:20:05 +0000 (10:20 +0100)]
vt-d: Fix a bug in addr_to_dma_page_maddr(), and add timeout in infinite loop

In addr_to_dma_page_maddr(), pte should not be used after
unmap_vtd_domain_page(parent). In addition, timeout is added in some
infinite loops.

Signed-off-by: Weidong Han <weidong.han@intel.com>
17 years agoxm: Add a new command: xm reset
Keir Fraser [Tue, 22 Apr 2008 09:18:13 +0000 (10:18 +0100)]
xm: Add a new command: xm reset

If a hang-up of a guest OS occurs, we will restart the guest OS by
using
the following commands.
 1. xm destroy
 2. xm create or xm start

To reduce the number of xm commands to use, this patch adds a new
command.  The command is "xm reset".  The command executes destruction
of a domain, and then creation of the domain.

Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
17 years agosrc-tarball: Remove source control metadata.
Keir Fraser [Mon, 21 Apr 2008 19:21:39 +0000 (20:21 +0100)]
src-tarball: Remove source control metadata.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoCache figlet output across builds, and provide src-tarball target
Keir Fraser [Mon, 21 Apr 2008 19:08:29 +0000 (20:08 +0100)]
Cache figlet output across builds, and provide src-tarball target
which creates figlet output and then deletes figlet itself (which is
not licensed under GPL).

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoiommu: initialisation cleanup and bugfix.
Keir Fraser [Mon, 21 Apr 2008 16:41:29 +0000 (17:41 +0100)]
iommu: initialisation cleanup and bugfix.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoAMD IOV: Fix xen boot on non-iommu systems.
Keir Fraser [Mon, 21 Apr 2008 13:59:25 +0000 (14:59 +0100)]
AMD IOV: Fix xen boot on non-iommu systems.
Signed-off-by: Wei Wang <wei.wang2@amd.com>
17 years agox86, hvm: Merge 32-bit and 64-bit asm stubs into common files.
Keir Fraser [Mon, 21 Apr 2008 13:55:15 +0000 (14:55 +0100)]
x86, hvm: Merge 32-bit and 64-bit asm stubs into common files.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agosvm: Do not hide 3DNow! CPU capabilities from SVM guests.
Keir Fraser [Mon, 21 Apr 2008 11:23:55 +0000 (12:23 +0100)]
svm: Do not hide 3DNow! CPU capabilities from SVM guests.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86, hvm: Assembly stub cleanups.
Keir Fraser [Mon, 21 Apr 2008 11:19:15 +0000 (12:19 +0100)]
x86, hvm: Assembly stub cleanups.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoiommu: Consolidate iommu enablement logic. Now there is only one
Keir Fraser [Mon, 21 Apr 2008 09:33:40 +0000 (10:33 +0100)]
iommu: Consolidate iommu enablement logic. Now there is only one
command-line parameter for disabling IOV/VTD: "iommu"/"no-iommu".

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoamd iommu: clean up debug information.
Keir Fraser [Mon, 21 Apr 2008 09:01:46 +0000 (10:01 +0100)]
amd iommu: clean up debug information.

Signed-off-by: Wei Wang <wei.wang2@amd.com>
17 years agodocs: update xen-apic docs
Keir Fraser [Fri, 18 Apr 2008 10:10:17 +0000 (11:10 +0100)]
docs: update xen-apic docs

Added undocumented fields and methods for default_netmask and
default_gateway to the Network class. Remove an unimplemented method
from the XSPolicy class and remove the 'optional' from 'oldlabel'
parameters.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
17 years agoioemu: Fix cross-build of tapdisk-ioemu
Keir Fraser [Fri, 18 Apr 2008 10:08:10 +0000 (11:08 +0100)]
ioemu: Fix cross-build of tapdisk-ioemu

changeset e1962ac0fb1c breaks cross-builds because it assumes the
system strip tool applies to the generated binaries.  This assumption
isn't made anywhere else in the xen tools build.

Signed-off-by: Aron Griffis <aron@hp.com>
17 years agox86: Fix the non-PAE build.
Keir Fraser [Thu, 17 Apr 2008 14:48:40 +0000 (15:48 +0100)]
x86: Fix the non-PAE build.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86, hvm: Allow emulation of 'multi-cycle' MMIO reads and writes,
Keir Fraser [Thu, 17 Apr 2008 11:37:35 +0000 (12:37 +0100)]
x86, hvm: Allow emulation of 'multi-cycle' MMIO reads and writes,
which may require multiple round trips to the device model.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86_emulate: Emulate MMX movq instructions.
Keir Fraser [Thu, 17 Apr 2008 09:46:54 +0000 (10:46 +0100)]
x86_emulate: Emulate MMX movq instructions.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86_emulate: Emulate certain FPU instructions by building the opcode
Keir Fraser [Wed, 16 Apr 2008 15:42:47 +0000 (16:42 +0100)]
x86_emulate: Emulate certain FPU instructions by building the opcode
on the stack. This allows us to add emulation for a number of extra
FPU opcodes without inflating the executable code size.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86_emulate: Implement a more dynamic interface for handling FPU
Keir Fraser [Wed, 16 Apr 2008 15:10:41 +0000 (16:10 +0100)]
x86_emulate: Implement a more dynamic interface for handling FPU
exceptions, which will allow emulation stubs to be built dynamically
in a future patch.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoAMD IOMMU: Add event logging support.
Keir Fraser [Wed, 16 Apr 2008 12:43:23 +0000 (13:43 +0100)]
AMD IOMMU: Add event logging support.

MSI interrupt will be triggered on IO page fault and the fault address
will be written into an in-memory event log buffer automatically by
hardware. This patch handles the MSI interrupt simply by reading event
log entry and printing out the parsed result.

Signed-off-by: Wei Wang <wei.wang2@amd.com>
17 years ago[VTD] Fix VT-d PAE issues.
Keir Fraser [Wed, 16 Apr 2008 12:40:46 +0000 (13:40 +0100)]
[VTD] Fix VT-d PAE issues.

Cast unsigned long PFNs to paddr_t before shifting left.

Signed-off-by: Weidong Han <weidong.han@intel.com>
17 years agox86, hvm: Lots of MTRR/PAT emulation cleanup.
Keir Fraser [Wed, 16 Apr 2008 12:36:44 +0000 (13:36 +0100)]
x86, hvm: Lots of MTRR/PAT emulation cleanup.

 - Move MTRR MSR initialisation into hvmloader.
 - Simplify initialisation logic by overlaying UC on default WB rather
   than vice versa.
 - Clean up hypervisor HVM MTRR/PAE code's interface with rest of
   hypervisor.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agostubdom: make use of PVFB resize event
Keir Fraser [Wed, 16 Apr 2008 09:21:08 +0000 (10:21 +0100)]
stubdom: make use of PVFB resize event
which with the offset support also permits to expose the VGA vram and
non-shared vram throught PVFB at the same time, switching between both
as appropriate.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
17 years agoioemu: drop reschedule of handle_buffered_io on I/O reqs
Keir Fraser [Wed, 16 Apr 2008 09:07:49 +0000 (10:07 +0100)]
ioemu: drop reschedule of handle_buffered_io on I/O reqs

Rescheduling the call to handle_buffered_io costs the system call to
qemu_get_clock(), which is very expensive considering the the latency
we would like to achieve for I/O reqs, so we should avoid it.

That means that handle_buffered_io may be called as often as every
0.1s, but that's not so costly.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
17 years agominios: simplify schedule()
Keir Fraser [Wed, 16 Apr 2008 09:06:34 +0000 (10:06 +0100)]
minios: simplify schedule()
- Merge the search, wakeup, and timeout loops.
- Avoid unnecessarily switching to the idle thread.
- Perform stack release _after_ we get out of it.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
17 years agominios: call do_hypervisor_callback directly from force_evtchn_callback
Keir Fraser [Wed, 16 Apr 2008 09:06:19 +0000 (10:06 +0100)]
minios: call do_hypervisor_callback directly from force_evtchn_callback
instead of unnecessarily going through the hypervisor.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
17 years agostubdom: sparse application's BSS by linking it separately first, put
Keir Fraser [Wed, 16 Apr 2008 09:05:57 +0000 (10:05 +0100)]
stubdom: sparse application's BSS by linking it separately first, put
markers at its beginning and end, and then link with mini-os.
That permits to stick a bit more to upstream qemu.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
17 years agox86: Fix emulation of PCI access register at I/O port 0xcf8.
Keir Fraser [Wed, 16 Apr 2008 09:04:22 +0000 (10:04 +0100)]
x86: Fix emulation of PCI access register at I/O port 0xcf8.
The register is only visible for DWORD accesses. Furthermore, some
chipsets place other registers in the range 0xf8-0xcfb for sub-DWORD
accesses.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years ago[LIBFSIMAGE] Support 256 byte inodes on ext3
Keir Fraser [Wed, 16 Apr 2008 08:45:44 +0000 (09:45 +0100)]
[LIBFSIMAGE] Support 256 byte inodes on ext3

Patch taken from Debian grub package version 0.97-32.
See http://bugs.debian.org/463236 & http://bugs.debian.org/463123

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
17 years agox86, hvm: Fix memory leak.
Keir Fraser [Wed, 16 Apr 2008 08:32:45 +0000 (09:32 +0100)]
x86, hvm: Fix memory leak.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agohvmloader: Explicitly revert to text section after declaring bss fields.
Keir Fraser [Tue, 15 Apr 2008 17:11:44 +0000 (18:11 +0100)]
hvmloader: Explicitly revert to text section after declaring bss fields.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agohvmloader: Framework for multiprocessor initialisation.
Keir Fraser [Tue, 15 Apr 2008 15:39:00 +0000 (16:39 +0100)]
hvmloader: Framework for multiprocessor initialisation.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86, hvm: APIC INIT handling can make use of existing hvm_vcpu_down()
Keir Fraser [Tue, 15 Apr 2008 15:38:25 +0000 (16:38 +0100)]
x86, hvm: APIC INIT handling can make use of existing hvm_vcpu_down()
helper function.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agotools: Build fixes for *BSD.
Keir Fraser [Tue, 15 Apr 2008 15:07:30 +0000 (16:07 +0100)]
tools: Build fixes for *BSD.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoioemu: COW driver flush method should return an int.
Keir Fraser [Tue, 15 Apr 2008 15:04:30 +0000 (16:04 +0100)]
ioemu: COW driver flush method should return an int.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86, hvm: Clean up handling of APIC INIT and SIPI messages.
Keir Fraser [Tue, 15 Apr 2008 14:47:53 +0000 (15:47 +0100)]
x86, hvm: Clean up handling of APIC INIT and SIPI messages.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86, hvm: If an MMIO handler returns X86EMUL_RETRY we must still
Keir Fraser [Tue, 15 Apr 2008 14:45:42 +0000 (15:45 +0100)]
x86, hvm: If an MMIO handler returns X86EMUL_RETRY we must still
complete the dummy I/O request-response cycle.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86: per-domain p2m structure must be initialised to all-zeroes when
Keir Fraser [Tue, 15 Apr 2008 14:44:40 +0000 (15:44 +0100)]
x86: per-domain p2m structure must be initialised to all-zeroes when
it is allocated.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoTasklet bug fixes.
Keir Fraser [Tue, 15 Apr 2008 14:03:40 +0000 (15:03 +0100)]
Tasklet bug fixes.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agodomctl: Do not return XEN_DOMINF_blocked if no VCPUs are online.
Keir Fraser [Tue, 15 Apr 2008 14:03:08 +0000 (15:03 +0100)]
domctl: Do not return XEN_DOMINF_blocked if no VCPUs are online.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86, hvm: I/O emulation handlers return X86EMUL_* return codes.
Keir Fraser [Tue, 15 Apr 2008 12:28:02 +0000 (13:28 +0100)]
x86, hvm: I/O emulation handlers return X86EMUL_* return codes.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoxend/acm: Fixes to labelling of resources.
Keir Fraser [Tue, 15 Apr 2008 09:24:55 +0000 (10:24 +0100)]
xend/acm: Fixes to labelling of resources.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
17 years ago[IA64] Remove duplicate tasklet code
Keir Fraser [Tue, 15 Apr 2008 09:21:35 +0000 (10:21 +0100)]
[IA64] Remove duplicate tasklet code

Make use of the newly added common code.

Signed-off-by: Alex Williamson <alex.williamson@hp.com>
17 years ago[IA64] Fix pci.h include overlap
Keir Fraser [Tue, 15 Apr 2008 09:21:17 +0000 (10:21 +0100)]
[IA64] Fix pci.h include overlap

The new upstream xen/pci.h has a name conflict with our modified
linux/pci.h and shows up earlier in the include search path.  Since
our usage of linux/pci.h is limited, rename to linux/linux-pci.h to
avoid duplicate names and cleanup the few users.

Signed-off-by: Alex Williamson <alex.williamson@hp.com>
17 years agoChange tasklet implementation so that tasklet_kill() does not have to
Keir Fraser [Tue, 15 Apr 2008 09:19:58 +0000 (10:19 +0100)]
Change tasklet implementation so that tasklet_kill() does not have to
busy-wait for softirq work to start. This reduces the possibility of
deadlocks, but the implementation is now less efficient. For the
current few users of tasklets this does not matter.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoRename 'big lock' to 'domain lock'.
Keir Fraser [Mon, 14 Apr 2008 15:07:54 +0000 (16:07 +0100)]
Rename 'big lock' to 'domain lock'.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agohvmloader: Small cleanups.
Keir Fraser [Mon, 14 Apr 2008 13:10:11 +0000 (14:10 +0100)]
hvmloader: Small cleanups.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agosvm: Fix an assertion.
Keir Fraser [Fri, 11 Apr 2008 16:29:26 +0000 (17:29 +0100)]
svm: Fix an assertion.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agohvm: Add HVM_PARAM_DM_DOMAIN to let ioreq events go to a stub domain
Keir Fraser [Fri, 11 Apr 2008 16:19:07 +0000 (17:19 +0100)]
hvm: Add HVM_PARAM_DM_DOMAIN to let ioreq events go to a stub domain
instead of dom0.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoTurn some simple softirqs into tasklets.
Keir Fraser [Fri, 11 Apr 2008 14:55:42 +0000 (15:55 +0100)]
Turn some simple softirqs into tasklets.

TRACE_SOFTIRQ does not appear to be necessary at all.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoSupport tasklets in Xen as a more dynamic alternative to softirqs.
Keir Fraser [Fri, 11 Apr 2008 14:37:48 +0000 (15:37 +0100)]
Support tasklets in Xen as a more dynamic alternative to softirqs.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86: Emulate accesses to PCI window registers cf8/cfc to synchronise
Keir Fraser [Fri, 11 Apr 2008 12:19:55 +0000 (13:19 +0100)]
x86: Emulate accesses to PCI window registers cf8/cfc to synchronise
with accesses by teh hypervisor itself. All users of cf8/cfc go
through new access functions which take the appropriate spinlock.

Based on a patch by Haitao Shan <haitao.shan@intel.com>

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agotools: Make xend set time offset for all kinds of domains, so that
Keir Fraser [Fri, 11 Apr 2008 08:14:03 +0000 (09:14 +0100)]
tools: Make xend set time offset for all kinds of domains, so that
ioemu doesn't need to do it.

Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
17 years agoVT-d: DMAR device scope parse fixup
Keir Fraser [Fri, 11 Apr 2008 08:12:56 +0000 (09:12 +0100)]
VT-d: DMAR device scope parse fixup

Previously applied sanity check fixup is incorrect.

Signed-off-by: Espen Skoglund <espen.skoglund@netronome.com>
17 years agox86/64 compat: Replace hypervisor BUG_ON() with a cleaner hypercall failure.
Keir Fraser [Fri, 11 Apr 2008 08:10:58 +0000 (09:10 +0100)]
x86/64 compat: Replace hypervisor BUG_ON() with a cleaner hypercall failure.

While trying to run a 32-bit PV domU on a 64-bit hypervisor, I
triggered an assert in the hypervisor.  The assert dealt with the
maximum number of grants that a domU can have.  I made the hypervisor
a bit more graceful by returning an error rather than asserting.

Signed-off-by: Michael Abd-El-Malek <mabdelmalek@cmu.edu>
17 years agolibxenguest: Fix a typo.
Keir Fraser [Fri, 11 Apr 2008 08:07:58 +0000 (09:07 +0100)]
libxenguest: Fix a typo.

Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
17 years agox86: disable PIT irq after S3 resume
Keir Fraser [Fri, 11 Apr 2008 08:06:11 +0000 (09:06 +0100)]
x86: disable PIT irq after S3 resume

Signed-off-by: Yu Ke <ke.yu@intel.com>
17 years agohvm: Fix a typo in p2m.c.
Keir Fraser [Thu, 10 Apr 2008 15:17:28 +0000 (16:17 +0100)]
hvm: Fix a typo in p2m.c.

Spotted by Xiao Wang <sirouni@yahoo.com.cn>

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86, hvm: Fix up MTRR setup for extra magic page (IDENT_PT).
Keir Fraser [Thu, 10 Apr 2008 10:17:50 +0000 (11:17 +0100)]
x86, hvm: Fix up MTRR setup for extra magic page (IDENT_PT).
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86: Conditionally disable PIT 100HZ timer interrupt
Keir Fraser [Thu, 10 Apr 2008 10:11:25 +0000 (11:11 +0100)]
x86: Conditionally disable PIT 100HZ timer interrupt

100HZ PIT timer interrupt set a 10ms upper limit for C state
residency, which makes Xen not power friendly. This patch disable PIT
timer interrupt in the conditions:
 - CPU has APIC support, and
 - PIT is not used as platform time source

Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agox86: Remove jiffies usage.
Keir Fraser [Thu, 10 Apr 2008 09:12:04 +0000 (10:12 +0100)]
x86: Remove jiffies usage.

Jiffies will be obsolete in x86 after PIT timer interupt is disabled,
so this patch replace jiffies usage with NOW() API.

Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agovmx: Enable live-migration with EPT
Keir Fraser [Thu, 10 Apr 2008 09:00:41 +0000 (10:00 +0100)]
vmx: Enable live-migration with EPT

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>
17 years agoVT-d: Allocates page table pgd, root_entry, iremap and qinval from
Keir Fraser [Thu, 10 Apr 2008 08:22:38 +0000 (09:22 +0100)]
VT-d: Allocates page table pgd, root_entry, iremap and qinval from
domheap rather than xenheap, and get rid of structure page_info in
iommu.c.

Signed-off-by: Weidong Han <weidong.han@intel.com>
17 years agoVT-d: Share VT-d code between x86 and IA64
Keir Fraser [Thu, 10 Apr 2008 08:20:07 +0000 (09:20 +0100)]
VT-d: Share VT-d code between x86 and IA64

Declare arch-dependent functions in vtd.h, and implement them for x86.

Signed-off-by: Weidong Han <weidong.han@intel.com>
17 years agohvmloader: Fix build with gcc 4.1 and later.
Keir Fraser [Thu, 10 Apr 2008 08:12:44 +0000 (09:12 +0100)]
hvmloader: Fix build with gcc 4.1 and later.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agolibxc: Move xg_memalign() into a proper source file, so that it
Keir Fraser [Wed, 9 Apr 2008 16:49:25 +0000 (17:49 +0100)]
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>
17 years agolibxc: Leave portability of xg_memalign() as in original patch, rather
Keir Fraser [Wed, 9 Apr 2008 15:54:44 +0000 (16:54 +0100)]
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>
17 years agox86 hvm: Make sure that we correctly tear down the vlapic periodic
Keir Fraser [Wed, 9 Apr 2008 15:32:51 +0000 (16:32 +0100)]
x86 hvm: Make sure that we correctly tear down the vlapic periodic
timer when the vlapic is destroyed or reset.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
17 years agosave/restore: Use page-aligned allocations for hypercall args that are
Keir Fraser [Wed, 9 Apr 2008 15:31:16 +0000 (16:31 +0100)]
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>
17 years agox86 libxc: Fix mlock sizes in libxc around vcpu context hypercalls
Keir Fraser [Wed, 9 Apr 2008 15:24:46 +0000 (16:24 +0100)]
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>
17 years agolsevtchn: Simple tool to list event channel states for a domain.
Keir Fraser [Wed, 9 Apr 2008 15:11:34 +0000 (16:11 +0100)]
lsevtchn: Simple tool to list event channel states for a domain.

Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
17 years agox86: Suppress scary console message from sh_remove_shadows()
Keir Fraser [Wed, 9 Apr 2008 15:04:10 +0000 (16:04 +0100)]
x86: Suppress scary console message from sh_remove_shadows()
except in cases where the guest's behaviour is unrecoverable.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
17 years agoioemu: Fix rtl8139 emulation so that reboot works correctly in 64-bit
Keir Fraser [Wed, 9 Apr 2008 15:03:40 +0000 (16:03 +0100)]
ioemu: Fix rtl8139 emulation so that reboot works correctly in 64-bit
Windows VMs. Return an error if the guest OS tries to transmit a
packet with the transmitter disabled, so that it doesn't spin forever
waiting for it to complete.

Signed-off-by: Steven Smith <Steven.Smith@eu.citrix.com>
17 years agoxenstore: Place return statement in the correct place to fix the build.
Keir Fraser [Wed, 9 Apr 2008 15:02:49 +0000 (16:02 +0100)]
xenstore: Place return statement in the correct place to fix the build.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoxenstore: fix canonicalize for metanodes
Keir Fraser [Wed, 9 Apr 2008 14:59:54 +0000 (15:59 +0100)]
xenstore: fix canonicalize for metanodes

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
17 years agohvm: Clean out save/restore debug tracing.
Keir Fraser [Wed, 9 Apr 2008 14:57:31 +0000 (15:57 +0100)]
hvm: Clean out save/restore debug tracing.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agohvm: Allocate memory for hvm domains in batches.
Keir Fraser [Wed, 9 Apr 2008 14:25:16 +0000 (15:25 +0100)]
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>
17 years agosave/restore: Batch contiguous page-sized writes together during domain save.
Keir Fraser [Wed, 9 Apr 2008 14:19:09 +0000 (15:19 +0100)]
save/restore: Batch contiguous page-sized writes together during domain save.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
17 years agox86, vmx: Enable VPID (Virtual Processor Identification)
Keir Fraser [Wed, 9 Apr 2008 13:34:49 +0000 (14:34 +0100)]
x86, vmx: Enable VPID (Virtual Processor Identification)

Allows TLB entries to be retained across VM entry and VM exit, and Xen
can now identify distinct address spaces through a new
virtual-processor ID (VPID) field of the VMCS.

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>
17 years agoRevert 17409:a8ce3e934abd5d99 as it breaks the build.
Keir Fraser [Wed, 9 Apr 2008 13:10:32 +0000 (14:10 +0100)]
Revert 17409:a8ce3e934abd5d99 as it breaks the build.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
17 years agoInstall missing ia64 hvm public headers.
Keir Fraser [Wed, 9 Apr 2008 12:53:38 +0000 (13:53 +0100)]
Install missing ia64 hvm public headers.

Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>