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.
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.
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>
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>
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.
- 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.
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>
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>
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>
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>
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.
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>
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>
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.
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>
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>
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>
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.
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.
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>
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>
xenstore: support building the xenstore clients statically.
This removes threading from libxenstore.a (but not libxenstore.so)
since pthreads is incompatible with static linking and none of the
command line clients require threads anyway.
It is now possible to build these utilities statically with a uclibc
toolchain which is useful for small userspace utility domains.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
x86, vmx: Enable EPT (Extended PageTable) support on new Intel processors.
We use the EPT page table as P2M (guest physical to machine
mapping), removing the linear page table when EPT is used for the
domain (see the new file p2m-ept.c). We did this by adding three
operations in the p2m_domain. If VT-d is enabled, the EPT page table
will be used as the VT-d page table as well (i.e. shared).
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>
Currently, tap:ioemu can only be used for domains which have a device
model running. This isn't the case for all domains. The most important
of the missing domains is Dom0 which needs acces e.g. to extract the
kernel from the domain's image.
tapdisk-ioemu is a tool compiled from ioemu source plus a small
wrapper which handles tap:ioemu access for domains without device
model (currently Dom0). You must start tapdisk-ioemu manually before
trying to attach a tap:ioemu disk to Dom0 at the moment. A patch to
blktapctrl will follow to automatically start tapdisk-ioemu when
needed.
Signed-off-by: Kevin Wolf <kwolf@suse.de> Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
AMD IOMMU: Defer IO pagetable construction until device assignment
During HVM domain creation, I/O page tables are filled by coping p2m
entries from p2m table, which is a useless step for non-passthru
domain. This patch defers I/O page table construction until the moment
of device assignment. In case that pci devices are never assigned or
hot plugged, the unnecessary duplication will be avoided.
x86: Adjust ACPI PM1a/b event/control information retrieval
Restore the fallback to v1 fields which got removed as a side effect
of c/s 17249. Additionally, use the correct width from the tables
rather than hardcoded values. Also make the copying code more compact
by using a macro, and print the results earlier to have better
indication whether subsequent failures lead to the information
retrieved getting invalidated.