Commit Graph
6801 Commits
Author SHA1 Message Date
Keir Fraser 39f97ffa29 x86, hvm: Hyper-V guest interface support with small set of enlightenments
A minimal implementation of the Viridian (Hyper-V) guest
interface. The only enlightenments advertised and supported are vAPIC
MSRs and long-spin-wait notifications. The set of enlightenments can
easily be extended in future, as they are found to provide a
performance win, and configured via an extended HVM_PARAM_VIRIDIAN hvm
parameter.

Signed-off-by: Peter Johnston <peter.johnston@citrix.com>
Signed-off-by: Tim Deegan <tim.deegan@citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-14 10:45:29 +01:00
Keir Fraser 7e3496ba25 xend: fixup the Secondary Bus Reset.
Use the read-modify-write operation.
Change the wrong 'I' to a correct 'H'.

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
2008-10-13 10:08:36 +01:00
Keir Fraser 7a05f7cc51 xenpm: Fix logic when Hyperthreading is enabled.
Signed-off-by: Guanqun Lu <guanqun.lu@intel.com>
2008-10-13 10:06:33 +01:00
Keir Fraser 27b182400b xend: Fix dev backend path construction.
Signed-off-by: Jim Fehlig <jfehlig@novell.com>
2008-10-13 10:03:36 +01:00
Keir Fraser d0fedc8895 xend: Restore bridge control register after secondary bus reset
From: Chris Dalton <cid@hp.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-10 11:52:26 +01:00
Keir Fraser 05272715e2 Merge with IA64 tree 2008-10-10 10:18:06 +01:00
Keir Fraser de07008fdd xend: Fix the detection of the upmost bridge in the python function find_parent().
Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
2008-10-10 10:03:28 +01:00
Keir Fraser 6bb3a63089 [IA64] compile xenpm for ia64.
Now ia64 supports cpufreq, compile xenpm.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-10-10 10:00:21 +01:00
Isaku Yamahata 71c2db7e6e merge with xen-unstable.hg 2008-10-10 12:06:46 +09:00
Keir Fraser 3fddebffd7 hvmloader: smbios support for large memory guests
This reports more than one memory device if the memory for the guest
is larger than 16G.

Signed-off-by: Bill Rieske <brieske@novell.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-09 17:18:11 +01:00
Keir Fraser 6de3c93f7f xenpm: Fix typo bug.
From: Guanqun Lu <guanqun.lu@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-09 10:16:49 +01:00
Keir Fraser 7c72e3bf4c xend: Fix typo _gatherDom -> gatherDom.
Signed-off-by: Jim Fehlig <jfehlig@novell.com>
2008-10-09 10:06:50 +01:00
Keir Fraser 8c755b0a98 flask: Fix a problem in xend code when starting a guest with XSM/Flask enabled.
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2008-10-08 10:03:47 +01:00
Keir Fraser 913481379c flask: Add 2 permissions to the default flask policy to get a VIF-enabled guest to work
This adds two more permissions to the default Flask policy to get a VM
with a network interface to work.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2008-10-08 10:03:09 +01:00
Keir Fraser 4208b9286f flask: Fix to default policy to get simple VM running
This fix gets to the default Flask/XSM policy gets a simple guest VM
(Ramdisk only, no VIF) running.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2008-10-08 10:02:27 +01:00
Keir Fraser 688581c472 pygrub: fix the parameter default' and timeout' in elilo.conf
This patch fixes two issues related to the parameter `default' and
`timeout' in elilo.conf:

- LiloConf.py cannot interpret the parameter `default' and
  `timeout'. The first kernel always boot up even if the second kernel
  is specified by `default'. And `timeout' is ignored.

  This issue is introduced by cset 15953:70bb28b62ffb.

- If two kernels or more are installed, the last kernel cannot boot
  up even if it is specified by `default'.

Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
2008-10-03 09:42:11 +01:00
Keir Fraser ac4148f219 xend: Allow guest write access to /local/domain/x/memory
Required for xenballoond, and tools do not need to trust any values
written in that subdirectory.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-03 09:37:35 +01:00
Isaku Yamahata 8b44bc08a3 [IA64] libxc: make xc_ia64_copy_memmap use DOM0VP_get_memmap.
Guest domain's memory map may be updated concurrently so that
it is protected sequence lock.
This patch makes xc_ia64_copy_memmap() use DOM0VP_get_memmap
hypercall to avoid the race.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-10-03 12:50:28 +09:00
Isaku Yamahata bd549c3d00 merge with xen-unstable.hg 2008-10-03 11:49:07 +09:00
Keir Fraser 4b52a38711 libblktap: Remove trailing null byte in xs_printf
xs_printf writes the terminating null byte of the passed string to
Xenstore. When reading, the null byte is returned in the following
form which confuses tools:

sector-size = "512\000"

This patch removes the null byte from the data to write.

Signed-off-by: Kevin Wolf <kwolf@suse.de>
2008-10-02 12:56:55 +01:00
Keir Fraser 668349f38b xc_ptrace: Allow gdbserver to connect to a guest before APs are
brought online.

Signed-off-by: Kip Macy <kmacy@freebsd.org>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-02 11:32:08 +01:00
Keir Fraser eeed0ffe27 xend: Make only selected subdirs of /local/domain/<domid> writable by the guest.
This protects critical data like
/local/domain/<domid>/console/{tty,limit}. It also means we can trust
.../vm, and hence do not need /vm_path. Various parts of the previous
two changesets disappear.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-02 10:37:28 +01:00
Isaku Yamahata 0296f1839a [IA64] libxc clean up.
remove code duplication between xc_ia64_linux_save.c and xc_core_ia64.c
by introducing xc_ia64_copy_memmap().
Later xc_ia64_copy_memmap() will be enhanced.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-10-02 17:27:57 +09:00
Isaku Yamahata 0072510b97 [IA64] xc restore: fix domain restore.
Fix domain restore of version one format.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-10-02 17:27:57 +09:00
Isaku Yamahata ec19302761 [IA64] hvm builder: more precisely use of memory size.
So far, VGA io size is ignored and memory size which assigned to
domain is smaller than what user specified by VGA io size.
This patch take VGA io size into consideration when memory population.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-10-02 17:27:57 +09:00
Isaku Yamahata ae695f6725 [IA64] libxc: improve foreign p2m exposure.
make foreign p2m exposure _PAGE_IO_BIT aware for robustness.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-10-02 17:27:57 +09:00
Isaku Yamahata 8abea5a174 merge with xen-unstable.hg 2008-10-02 15:32:54 +09:00
Keir Fraser 8fe9e65cb4 xend: Fixes after backend xenstore config changes.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-01 14:07:17 +01:00
Keir Fraser e9f884ceda xend: Move some backend configuration info.
This patch moves some dom0 variables and backend device
configuration from frontend directories to
/local/domain/<backdomid>/backend or /vm.

Also,
- /vm_path/<domid> is introduced, referencing the /vm path
- /vm_path/device/backend holds the backend device location,
  rather than storing it in the frontend directory

Signed-off-by: Pascal Bouchareine <pascal@gandi.net>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-10-01 13:35:39 +01:00
Keir Fraser ca2eee92df x86, hvm: Expose host core/HT topology to HVM guests.
Based on an initial patch by Nitin Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-30 10:14:54 +01:00
Keir Fraser 3321e0ef95 hvm: Remove extboot from virtual firmware.
Device model is not present in external qemu repository, and
functionality was never exposed through the toolstack.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-29 15:45:38 +01:00
Keir Fraser 73f43ceca7 xc_save: use correct size when unmapping live p2m.
Otherwise we unmap a larger region than was mapped when saving 32 bit
guest from 64 bit tools, leading to badness.

The equivalent change was made to the restore code in
18329:ca7dd77d5365

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
2008-09-29 11:00:29 +01:00
Keir Fraser 3ff1f0088a hvm: Default timer_mode=1 (do not delay virtual time for missed
ticks). Most guests prefer this mode compared with screwing with
progress of virtual time.

Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-26 17:09:36 +01:00
Keir Fraser c06a7db0c5 X86 and IA64: Update cpufreq statistic logic for supporting both x86
and ia64

Signed-off-by: Yu, Ke <ke.yu@intel.com>
Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>
2008-09-26 14:05:09 +01:00
Keir Fraser 0ae658ea9f xm: Fix xm start -c / --vncviewer
In xm start the --vncviewer option has no effect, instead -c tries to
both connect to the console and start vncviewer. Additionally, to
start vncviewer it uses the domid variable which is only defined a few
lines later. Thus xm start -c doesn't work at all.

This patch fixes both problems.

Signed-off-by: Kevin Wolf <kwolf@suse.de>
2008-09-25 13:07:43 +01:00
Keir Fraser 270fdae556 hvm firmware: Replace etherboot with modern gPXE ROMs.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-25 12:09:10 +01:00
Keir Fraser 876bb8d639 x86: Add xenpm utility to list CPU power info.
Signed-off-by: Lu Guanqun <guanqun.lu@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-25 10:21:40 +01:00
Isaku Yamahata 9dc665723c [IA64] xc_domain_save: Do not poll-wait for guest to shutdown.
This patch is ia64 counter part of 18452:59904b180078.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-09-25 11:47:53 +09:00
Keir Fraser f43f4f1d28 ia64: fix make install under tools/debugger/xenitp
This patch fixes the following error with make install under
the directory, tools/debugger/xenitp by checking whether
the variable is length zero string.

> # make install
> ../../../tools/cross-install -d -m0755 -p //usr/bin
> [ -z " xenitp" ] || ../../../tools/cross-install -d -m0755 -p
> //usr/lib/xen/bin
> ../../../tools/cross-install -d -m0755 -p //usr/share/man/man1
> ../../../tools/cross-install -d -m0755 -p //usr/share/man/man8
> ../../../tools/cross-install -m0755 -p   //usr/bin
> install: too few arguments
> Try `install --help' for more information.
> make: *** [install] Error 1

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-09-24 10:19:07 +01:00
Keir Fraser c2c1029070 hvm, save/restore: Skip page batches which contain no valid pages.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-23 17:11:33 +01:00
Keir Fraser 0e7c1355bc acm, xend: Catch bad vlan identifiers
Add code to intercept badly formatted VLAN identifiers or
those that are out of range.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2008-09-23 12:30:42 +01:00
Keir Fraser c134d74fda libxc: Wrapper functions for cpu online/offline
Signed-off-by: Shan Haitao <haitao.shan@intel.com>
2008-09-22 16:10:25 +01:00
Keir Fraser 13ad235ee7 xentop: Fix display of long domain names.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-22 14:04:27 +01:00
Keir Fraser dd7746fbf3 xenctx: fix xenctx --all option on x86
Signed-off-by: Akio Takebe <takebe_akio@jp.fujitsu.com>
2008-09-22 11:16:56 +01:00
Keir Fraser 11825aea19 xend: Refactor vmmetrics destruction.
Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
2008-09-22 11:15:39 +01:00
Keir Fraser bbc10fbb40 xm list: Return unique exit code for non-existent domain
This patch will make xm return a exit code of 3 if `xm list
<non_existant_domain>` is done rather than the generic code of 1.  I
used 3 because XendClient had a macro setup pointing
ERROR_INVALID_DOMAIN to 3.

From: "Shaun R." <mailinglists@unix-scripts.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-18 10:41:41 +01:00
Keir Fraser 549e1d9ec5 x86, amd, hvm: pass through one more cpuid cache description leaf
Add a missing CPUID leaf that contains AMD-specific cache info.
Without this, Windows can spin trying to prefetch memory buffers using
a stride length of zero.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-18 10:39:53 +01:00
Keir Fraser 19dc3860dc Remove internal tools/ioemu tree.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-18 10:32:40 +01:00
Keir Fraser f2878b5bb1 xc_save/xc_restore: Fix wrong data type
xc_interface_open() may return -1, but if we define xc_fd as unsigned
int, then -1 will be > 0.

Signed-off-by: Zhigang Wang <zhigang.x.wang@oracle.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
2008-09-17 14:16:02 +01:00
Keir Fraser 5c4eccd644 xm: Remove obsolete mechanism using vncviewer -listen
Without this patch, vncviewer processes remain as follows.
This patch fixes it.

> # pgrep -fl vnc
> 4303 vncviewer -log *:stdout:0 -listen 5501
> 5089 vncviewer -log *:stdout:0 -listen 5502
> 5763 vncviewer -log *:stdout:0 -listen 5503

details:
Since 21dd1fdb73d8 there have been (as far as I can see) three
separate mechanisms for achieving a VNC display:
 1. xm spawns vncviewer after getting vnc display info
     from qemu-dm via xenstore  (introduced in 21dd1fdb73d8)
 2. xm spawns vncviewer -listen and qemu-dm connects to it
 3. qemu-dm spawns vncviewer (!)

The latter two are rather strange - No.3 is very strange indeed.
So I decided that rather than try to get No.2 or No.3 on track for
going into qemu upstream, No.2 and No.3 would be dropped.
After discussion on xen-devel the mechanism No.1 was introduced,
above.

No.1 is controlled by the --spawn-vncviewer (and --vncviewer-autopass)
command line options to xm, by analogy with the -c option.

Nos.2 and 3 are controlled by elements of the domain configuration
file - and their code still remains.  So if you turn all of the vnc
options on you can get several vncviewers (although only one of them
will work).

This patch removes the support for the passive connection mode No.2
After all ioemu-remote will never connect to such a vncviewer.
The options to engage this functionality were already removed from
the example config files by Keir in 18241:bf4ef45e6a38.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2008-09-17 13:11:40 +01:00