Commit Graph
21545 Commits
Author SHA1 Message Date
Keir Fraser e9bf40dbce xl: fix 'xl help' command
xl help 'command' should give the help of the 'command',
but current it does not, it just gives a full list of xl
supported commands. This patch fix it.

Signed-off-by: Yang Hongyang <yanghy@cn.fujitsu.com>
2010-06-07 07:49:07 +01:00
Keir Fraser 4244952130 x86: Small APIC timer initialisation cleanup
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-07 07:47:30 +01:00
Keir Fraser 81265c2af9 AMD: Workaround for erratum 411
Clear APIC TMICT when we mask APIC LVTT.

Signed-off-by: Wei Wang <wei.wang2@amd.com>
2010-06-07 07:38:09 +01:00
Keir Fraser ffa84dc13b xend: A few blktap2 fixes
1. Bug fix for error: "Error: Device /dev/xvdp (51952, tap2) is
already connected." (xenstore does not clean after DomU stoped)
2. Bug fix for error: "File 'vhd:/path/.../disk.img' doesn't exist."
(not correct parsing)
3. Bug fix for error: "Error: Device 51952 not connected" (in config
file for DomU we should be use prefix "tap2:tapdisk:xxx" for devices
from (aio, ram, qcow, vhd, remus) or "tap:tapdisk:xxx" for devices
from (sync, vmdk, qcow2, ioemu))
4. Bug fix for error: "Disk is not accessible" (if use 'tap2'-device
type, then '/dev/xpvd' may not be accessible immediately after its
creation)

Signed-off-by: eXeC001er <execooler@gmail.com>
2010-06-07 07:19:43 +01:00
Keir Fraser 16c22751fa xenwatchdogd: Fix build errors
Signed-off-by: Patrick Colp <pjcolp@cs.ubc.ca>
2010-06-07 07:16:43 +01:00
Keir Fraser cbc6cc9ee3 xl: block-detach command line parsing
Command line arguments start at argv[2].

Signed-off-by: Eric Chanudet <eric.chanudet@citrix.com>
2010-06-07 07:14:19 +01:00
Keir Fraser d15309d79c xl: block-list command line parsing
Command line arguments start at argv[2].

Signed-off-by: Eric Chanudet <eric.chanudet@citrix.com>
2010-06-07 07:13:41 +01:00
Keir Fraser 693189ff85 xl: block-attach command line parsing
Command line arguments start at argv[2].

Signed-off-by: Eric Chanudet <eric.chanudet@citrix.com>
2010-06-07 07:13:02 +01:00
Keir Fraser 2d50cfa6e1 xl: network2-detach command
Usage: xl network2-detach <Domain> <DevId>

Signed-off-by: Eric Chanudet <eric.chanudet@citrix.com>
2010-06-07 07:12:20 +01:00
Keir Fraser 2018b98c2f xl: network2-list command
Usage: xl network2-list <Domains>

Signed-off-by: Eric Chanudet <eric.chanudet@citrix.com>
2010-06-07 07:11:15 +01:00
Keir Fraser 1742e2a8ea xl: network2-attach command
Usage: xl network2-attach <Domain> [front_mac=<mac>]
[back_mac=<mac>]
[backend=<BackDomain>] [trusted=<0|1>] [back_trusted=<0|1>]
[bridge=<bridge>] [filter_mac=<0|1>] [front_filter_mac=<0|1>]
[pdev=<PDEV>] [max_bypasses=n]

Signed-off-by: Eric Chanudet <eric.chanudet@citrix.com>
2010-06-07 07:09:41 +01:00
Keir Fraser bf27c9bb39 xentrace: update formats file for INTR_WINDOW and NPF
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
2010-06-07 07:07:03 +01:00
Keir Fraser 0cc54b151a Add xl init scripts
this patch adds an init script for xl, so that it can be used without
xend installed on the system.  In cases in which both toolstacks are
present, only one init script will be run, dependening on the value of
xen_toolstack in /etc/sysconfig/xen_toolstack.  Please note that a
correct value of xen_toolstack (either xl or xend), is required now.
The network script and the vif script to be used with xl can be
specified in /etc/sysconfig/xenlightdaemons.  Xl sets the vif script
to xl-vif-script by default, that reads /etc/sysconfig/xenlightdaemons
and calls the vif script set there.  A port to a debian system should
be straightforward, just replacing /etc/sysconfig with /etc/default
everywhere.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
2010-06-07 07:05:54 +01:00
Keir Fraser 2495a965a0 xl: make mem-set and mem-max to use MB for memory unit by default.
Signed-off-by: Zhigang Wang <zhigang.x.wang@oracle.com>
2010-06-07 06:56:04 +01:00
Keir Fraser 24c41d2dda [IA64] support XEN_SYSCTL_numainfo
Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
2010-06-04 11:39:06 +01:00
Keir Fraser 78c8506e77 Watchdog timers for domains
Each domain is allowed to set, reset and disable its timers; when any
timer runs out the domain is killed.

Patch from Christian Limpach <Christian.Limpach@citrix.com>
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2010-06-04 11:35:23 +01:00
Keir Fraser 77622d85cf libxc: Remove obsolete xc_find_device_number() declaration.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-04 10:46:32 +01:00
Keir Fraser f5736f6958 notify_via_xen_event_channel() takes explicit domain parameter.
Also remove pointless tasklet from mem_event notify path.

Signed-off-by: John Byrne <john.l.byrne@hp.com>
2010-06-04 10:25:45 +01:00
Keir Fraser 2aa16b3831 Intel: Add CPUID feature mask support for NHM processors.
Signed-off-by: Jun Nakajima <jun.nakajima@intel.com>
Signed-off-by: Liping Ke <liping.ke@intel.com>
2010-06-04 10:18:31 +01:00
Keir Fraser 92dbb84764 [VTD] fixed a timing issue on DELL calpella laptop while doing graphics pass-through
Added additional sleep time between FLR and PCI config restore.

Signed-off-by: Allen Kay <allen.m.kay@intel.com>
2010-06-04 10:17:19 +01:00
Keir Fraser ca896d0ca6 libxl/xl: fix multivcpu handling
Signed-off-by: Stefano Stabellini<stefano.stabellini@eu.citrix.com>
2010-06-04 10:14:06 +01:00
Keir Fraser 88d60e45ef xl: enable hap, parse hap option in the config files
This simple patch enables hap by default in xl and also allows xl to
parse the hap option in the VM config file.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
2010-06-04 10:13:02 +01:00
Keir Fraser 8d6cdfed76 xl: correct help message of migrate and migrate-receive command
Signed-off-by: Yang Hongyang <yanghy@cn.fujitsu.com>
2010-06-04 10:12:11 +01:00
Keir Fraser 9a9657f15a xl: fix vcpu-* command line args
Command line arguments start at argv[2]

Signed-off-by: Yang Hongyang <yanghy@cn.fujitsu.com>
2010-06-04 10:11:40 +01:00
Keir Fraser 8ce5d64e3b xl: fix network-detach command line parsing
Command line arguments start at argv[2].  Also, exit(1) on failure.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
2010-06-04 10:10:45 +01:00
Keir Fraser 89c41cfacc xl: fix network-list command line parsing
Command line arguments start at argv[2].

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
2010-06-04 10:10:25 +01:00
Keir Fraser 46d24c4a83 xl: fix network-attach command line parsing
Command line arguments start at argv[2].

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
2010-06-04 10:09:59 +01:00
Keir Fraser da923a6fff Bash completion scripts go to /etc/bash_completion.d/
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-04 10:09:11 +01:00
Keir Fraser a6e99ed7e7 Add the USE_PLATFORM_TIMER flag to the FADT, to make w2k3 use the PMTIMER
...because the default timesource (TSC) drifts under load.

The flag is only defined in ACPI 3.0, and we provide ACPI 2.0 tables,
but Windows seems happy enough to obey it anyway.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2010-06-04 10:06:23 +01:00
Keir Fraser 9c667640ec Add a safety valve to the HVM RTC model for big time jumps
If xen's time leaps forward by a large amount, the RTC will try to
model a tick for every second that it thinks has passed.  This can
livelock a CPU with a series of timer requests each of which fires
immediately and requests the next one.

This patch treats a delay of more than a day between ticks as a
special case, abandoning the attempt to catch up.  That should be good
enough to avoid livelock but doesn't fix the underlying time problem.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2010-06-04 10:05:42 +01:00
Keir Fraser 288f75ff8e x86: Suppress warnings about spurious pagefaults
RHEL4 guests take a fair number of spurious pagefaults on Nehalem; no
need to report each one of them at XENLOG_WARNING.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2010-06-04 10:04:30 +01:00
Keir Fraser 2832d9e24c x86: Quieten the warning about paging domctls called on domains with no vcpus
Xapi tends to trigger this a lot by looking up the shadow memory
allocation of domains that aren't quite built yet.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2010-06-04 10:02:51 +01:00
Keir Fraser 7817c9a3a4 Quieten console warning about incomplete PAE PTE writes
Older (<4.6) RHEL kernels clear PAE pagetable entries without taking
care to write the bottom half first, often enough to make it annoying.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
2010-06-04 10:01:15 +01:00
Keir Fraser f5030c6d76 timer: Do not acquire a lock on a killed timer.
Its cpu field might be stale and refer to an offlined cpu.

Furthermore, this avoids performing invalid operations on killed
timers.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-04 09:50:45 +01:00
Keir Fraser 6e880a2217 Allow domains to set a shutdown code without actually shutting down
Useful for Windows guests, since the PV drivers are notified that
the domain is about to crash just before the crash dump gets written.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-04 09:33:11 +01:00
Keir Fraser 727f9f00e9 timer: Migrate timers from dying CPU on CPU_DYING notification.
Otherwise timer_lock() can race a timer's ->cpu field being updated by
migrate_timers_from_cpu().

The rest of this patch is all debug paranoia.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-03 07:30:54 +01:00
Keir Fraser 0fac8f6876 timers: Track inactive timers and migrate them on cpu offline.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-02 13:13:11 +01:00
Keir Fraser ffd4db9a68 tools: assume that special Xen devices have been created by the platform
Remove all the magic surrounding the special Xen devices in Linux
specific code whereby we attempt to figure out what the correct
major:minor number is and check the the existing device has these
numbers etc. In 2010 we really should be able to trust that the
platform has created the devices correctly or provide correct
configuration settings such that they are without resorting to tearing
down the platform configured state and rebuilding it.

tools/hotplug/Linux/xen-backend.rules already contains the necessary
udev rules to create /dev/xen/evtchn and friends in the correct place.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
2010-06-02 10:54:32 +01:00
Keir Fraser c1d7e20205 xl: adds shutdown and reboot commands
libxl : remote shutdown to work for pure hvm domains

Signed-off-by: Gihan Munasinghe <GMunasinghe@flexiant.com>
2010-06-02 10:52:17 +01:00
Keir Fraser 9d1f137d16 Fix xm man page statement about asynchonous operation
The man page for xm command states that many commands acts
asynchronously which is not true. According to my experience most
commands does act synchronously with several exceptions, like create,
shutdown, mem-set and vcpu-set commands so this fixes the paragraph
available in this xm man page.

Signed-off-by: Michal Novotny <minovotn@redhat.com>
2010-06-02 10:49:35 +01:00
Keir Fraser cb6536f1df x86: On CPU offline, freed stack should be *un*guarded.
Fix stupid typo.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-02 10:38:55 +01:00
Keir Fraser 378fd88665 VMX: does EPT capabilities detection strictly according to Intel SDM.
Signed-off-by: Xin Li <xin.li@intel.com>
2010-06-01 14:25:59 +01:00
Keir Fraser 41b325aff8 x86: During cpu offline, cpu_disable_scheduler() cannot fail.
BUG on this scenario.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-01 13:57:44 +01:00
Keir Fraser 63725a8c54 smp_call_function/on_selected_cpus/on_each_cpu all return void.
None of them can fail, so a return code is pointless.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-01 11:04:08 +01:00
Keir Fraser f55efa2b18 x86 mtrr: Remove (noop) lock_cpu_hotplug().
CPUs coming online sync themselves with current MTRR state at an
appropriate point anyway.

It's not actually possible to have a newly booted CPU immediately have
in-sync MTRR state anyway. It has to be synced up as part of normal
CPU bootstrap procedure. Which is what we do.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-01 10:56:07 +01:00
Keir Fraser 01c02ad2a8 x86 mtrr: Fix set_mtrr() race against cpu_online_map changes.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2010-06-01 10:40:06 +01:00
Keir Fraser 1f60b34911 xl: remove duplicate code in migrate_domain()
libxl_domid_to_name() have already been called in
save_domain_core_begin()->find_domain(), so remove it.

Signed-off-by: Yang Hongyang <yanghy@cn.fujitsu.com>
2010-06-01 07:06:50 +01:00
Keir Fraser 81c0e00a2e libxl: fix domain suspend debug typo.
Signed-off-by: Zhigang Wang <zhigang.x.wang@oracle.com>
2010-06-01 07:06:05 +01:00
Keir Fraser 8567eb4c32 xend: PoD check should be for HVM domain only.
Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
2010-06-01 07:05:22 +01:00
Keir Fraser f6a50a21e5 xc: deal with xen/evtchn and xen/gntdev device names
This patch makes xc_linux properly deal with:
 1. discovering and creating device nodes if necessary
 2. the new form of xen/<dev> device names soon to be used by the
 kernel

This changes the logic slightly:
 - If a device node already exists with the proper name, then it uses
 it as-is, assuming it has already been correctly created.
 - If the path doesn't exist, or it exists but isn't a device node,
 and
   it has successfully found the major/minor for the device, then
   (re)create the device node.

Since this logic is identical for gntdev and evtchn, make a common
function to handle both.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
2010-06-01 07:04:35 +01:00