debuggers.hg

changeset 20682:e73d666b4d30

docs: add a document about guest cpuid configuration

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
author Keir Fraser <keir.fraser@citrix.com>
date Mon Dec 14 07:59:40 2009 +0000 (2009-12-14)
parents 7088591b454b
children 45fc26e2d05a
files docs/misc/cpuid-config-for-guest.txt
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/docs/misc/cpuid-config-for-guest.txt	Mon Dec 14 07:59:40 2009 +0000
     1.3 @@ -0,0 +1,23 @@
     1.4 +CPUID emulation for guest
     1.5 +-------------------------
     1.6 +
     1.7 +When HVM guest tries to execute CPUID, or PV guest tries to execute XEN_CPUID,
     1.8 +the xen hypervior traps and emultes them.
     1.9 +
    1.10 +For HVM guest and PV DomU guest, xen's CPUID emulation can be adjusted using
    1.11 +the guest configation file if necessary (e.g., to supply better support for
    1.12 +guest live migration). The CPUID syntax in guest configration file is
    1.13 +described in detail in the examples like /etc/xen/xmexample.hvm,
    1.14 +/etc/xen/xmexample.hvm-stubdom.
    1.15 +
    1.16 +However, a user (or an administrator) must be aware that the CPUID in guest
    1.17 +configuration file can NOT be configured casually. The default CPUID
    1.18 +configuration should be safe, but illegal configuration can cause unexpected
    1.19 +behaviors of guest -- even can crash guest.
    1.20 +
    1.21 +For example, we should not expose the MONITOR CPUID feature flag (ECX bit 3;
    1.22 +CPUID executed EAX = 1) to HVM guest, otherwise, on guest's attempt of
    1.23 +executing MWAIT, the VMExit handler in Xen would inject #UD (Invalid Opcode
    1.24 +Exception) into the HVM guest, and guest kernel would panic.
    1.25 +
    1.26 +/* We can add more unsafe CPUID configuration here in future. */