Commit Graph
8474 Commits
Author SHA1 Message Date
kaf24@firebug.cl.cam.ac.uk 8f5424c6bb merge 2006-01-03 14:36:56 +01:00
kaf24@firebug.cl.cam.ac.uk 29c3bf78b9 Rename VMX option name lapic to apic, and pass it to xen by
hvm_info_table.  Previous we pass it to xen by guest vcpu context ECX
register, now we unify to use hvm_info_table.

Signed-off-by: Xin Li <xin.b.li@intel.com>
2006-01-03 14:35:45 +01:00
vhanquez@kneesa.uk.xensource.com 28d7365b01 merge 2006-01-03 13:04:59 +00:00
vhanquez@kneesa.uk.xensource.com ee4eb30e9d mixup during reorganization. when SIF_INITDOMAIN it should kcons_write_dom0
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2006-01-03 13:03:35 +00:00
kaf24@firebug.cl.cam.ac.uk 61cf7e808a Fix VMX disk config string parse (allow leading whitespace).
Signed-off-by: Xin Li <xin.b.li@intel.com>
2006-01-02 11:35:29 +01:00
kaf24@firebug.cl.cam.ac.uk cfa0fac2c2 Provide an option to disable ACPI from the VMX config file.
By default ACPI is disabled.

Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Jun Nakajima <jun.nakajima@intel.com>
Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
2006-01-01 11:29:17 +01:00
vhanquez@kneesa.uk.xensource.com d33de0f496 fix possible memory leak if one of the kmalloc fail.
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-31 20:17:45 +00:00
vhanquez@kneesa.uk.xensource.com 27c7f637f8 remove one pointless macro and make code paths explicit.
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-31 19:35:11 +00:00
vhanquez@kneesa.uk.xensource.com 05a04604e5 reorganize code to avoid duplication
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-31 15:58:44 +00:00
vhanquez@kneesa.uk.xensource.com 1b296eaa07 Convert old initializer to C99 initializer.
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-31 14:20:01 +00:00
vhanquez@kneesa.uk.xensource.com 80a654a545 directly return -ENOMEM instead of jumping to a return -ENOMEM label
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-31 14:17:10 +00:00
vhanquez@kneesa.uk.xensource.com 4b6164a042 move error handling out of line to avoid duplicated code.
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-31 14:16:13 +00:00
kaf24@firebug.cl.cam.ac.uk 24b0fec3cf Clean up 'q' debug key output.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-31 14:33:00 +01:00
kaf24@firebug.cl.cam.ac.uk 7e127cd35f Allow non-privileged domains restricted access to
I/O memory and physical interrupts, under control
of domain0. Capabilities are maintained as rangesets
in Xen.

Signed-off-by: Ryan Wilson <hap9@epoch.ncsc.mil>
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-31 14:15:22 +01:00
kaf24@firebug.cl.cam.ac.uk a8f5fb8508 Store admin-specified ioport capabilities in a rangeset
rather than a bitmap. arch_do_createdomain() can now
fail and the caller will clean up.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-31 13:11:47 +01:00
kaf24@firebug.cl.cam.ac.uk 9be588cacb Fix a missing break in ioemu command-line parsing switch
statement.

Signed-off-by: Xin Li <xin.b.li@intel.com>
2005-12-30 17:12:40 +01:00
kaf24@firebug.cl.cam.ac.uk 96905f367b Fix rdmsrl() for x86_32 -- high 32 bits must be cast to
u64 before shifting left.

Signed-off-by: Avi Kivity <avi@qumranet.com>
2005-12-30 17:11:05 +01:00
kaf24@firebug.cl.cam.ac.uk 0129e126c4 Avoid xen crash if there is no VMX support. If a platform
doesn't support VMX, creating VMX domain will crash xen
HV.

Signed-off-by: Xin Li <xin.b.li@intel.com>
2005-12-30 17:07:34 +01:00
kaf24@firebug.cl.cam.ac.uk e9ac3bbcca Move initial stack-pointer adjustment into assembly
bootstrap code. Avoids need for indirection thru
reset_stack_and_jump() in C code (which was incorrect for
secondary CPUs since nothing was pushed on the stack on
that initial call, hence the masking operation had no
effect and we ended up running on a bogus stack pointer).

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-30 17:02:30 +01:00
kaf24@firebug.cl.cam.ac.uk aafd5e14e1 Virtual TPM persistent states contain VTPM secrets, which are encrypted
using symmetric keys and stored on disk along with those symmetric keys.
The attached patch uses the TPM to encrypt the symmetric keys and other
global secrets before saving them to disk.

Signed-off-by: Vinnie Scarlata <vincent.r.scarlata@intel.com>
2005-12-30 11:31:12 +01:00
kaf24@firebug.cl.cam.ac.uk fc41b5c1fd Extend the range abstraction by adding an internal
insert_range() helper function. Pretty printer uses
the internal abstractions rather than accessing the
linked list directly.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-29 18:39:50 +01:00
kaf24@firebug.cl.cam.ac.uk 9e1d90563d Add a little more internal abstraction to the rangeset
library, avoiding direct interaction with the linked-list
structure.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-29 18:16:01 +01:00
kaf24@firebug.cl.cam.ac.uk ff6d5dac81 Reset the stack pointer on every cpu early during bootstrap.
Ensures we do not overlap with the cpu_info structure.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-29 17:53:22 +01:00
kaf24@firebug.cl.cam.ac.uk 9647c68ca2 Initialise grant tables via core_initcall so that it happens
suitably early during the boot process.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-29 17:37:08 +01:00
kaf24@firebug.cl.cam.ac.uk b33ac9e433 Various fixes to Xen stack management. Ensure the cpu0_stack
is always sufficiently aligned (requires some linker script
tricks). Small fixes to show_trace() and ensure that Xen
stack pointers are always below the 'struct cpu_info' region.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-29 16:59:12 +01:00
kaf24@firebug.cl.cam.ac.uk 484a058c48 Add auto-destructing per-domain rangeset data structure,
for representing sets of contiguous numeric ranges. This
will be used for representing permissions lists (e.g.,
io memory, io ports, irqs).

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-29 15:47:23 +01:00
kaf24@firebug.cl.cam.ac.uk d17f04f5f8 Fix iobmp_mask setup when permitting a domU access to
I/O port ranges.

Signed-off-by: Ryan Wilson <hap9@epoch.ncsc.mil>
2005-12-28 16:23:42 +01:00
kaf24@firebug.cl.cam.ac.uk 8be86755a9 Fix a leak occurring at netif_map(). The problem raised after allocating
both {rx,tx}_comms_area, and one (and just one) of them failed. As we
were
doing a single test for both, returning would leave one of them
allocated.

Signed-off-by: Glauber de Oliveira Costa <glommer@br.ibm.com>
2005-12-28 15:17:04 +01:00
kaf24@firebug.cl.cam.ac.uk 5fb7e24473 Set up X11 authorization when a VMX domain uses SDL.
Signed-off-by: Hiromichi Itou <ito@begi.net>
2005-12-28 15:14:23 +01:00
kaf24@firebug.cl.cam.ac.uk ada4e79b32 Reorganizes network frontend device unregister and removal, so that
occur in the right order and succeed.

Now on Closing state we:
- stop queue
- unbind irq
- unregister the device

On removal:
- end foreign access to TX and RX pages (we cannot do this before)
- free_netdev, doing the last stage of destroying an allocated device

Makes xm-test network "03_attach_detach_multiple_pos" pass:
http://xmtest.dague.org/cgi-bin/display?view=single&testid=1068

Signed-off-by: Murillo F. Bernardes <mfb@br.ibm.com>
2005-12-28 15:07:43 +01:00
kaf24@firebug.cl.cam.ac.uk 914dc0db80 Missing file from previous changeset. 2005-12-28 15:07:16 +01:00
kaf24@firebug.cl.cam.ac.uk aabfe47319 Fix uncleaned vif backend devices when frontend does not finish
initialization properly.

Signed-off-by: Murillo F. Bernardes <mfb@br.ibm.com>
2005-12-28 14:55:55 +01:00
kaf24@firebug.cl.cam.ac.uk 2d6e715911 If netfront fails to allocate a receive skbuff, push all pending
skbuffs out onto the shared ring. If there are no skbuffs to push,
schedule a timer to try again later. This will avoid interface
lockups in low-memory conditions.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-28 12:29:15 +01:00
vhanquez@kneesa.uk.xensource.com 9ab2587f30 Prevent vbd frontend from oopsing if the underlying device doesn't exist.
Signed-off-by: Horms <horms@verge.net.au>
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-27 10:40:33 +00:00
kaf24@firebug.cl.cam.ac.uk 62cc71c8a8 Generic x86 emulator now properly supports 16-bit addressing
by narrowing accesses to SI/DI/SP registers. Also supports
real-mode addressing by shifting and adding the appropriate
segment register for certain stack and string operations
where the effective address is not already known.

todo: Stack operations should have address size specified
by B bit in stack segment descriptor, not by default address
size or address-size override. Probably nothing depends on
the proper behaviour though.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-23 18:28:33 +01:00
kaf24@firebug.cl.cam.ac.uk f0010ba27f Modify CR0 access emulation -- return physical CR0 (except
for TS) and allow only the same physical flags to be written
back to CR0 by a guest.

Add write-to-CR4 emulation, but check that the write does not
modify any CR4 flags.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-23 16:42:46 +01:00
Ian.Campbell@xensource.com efec87263e Only build xenctx on x86_32 and x86_64.
Signed-off-by: Ian Campbell <Ian.Campbell@XenSource.com>
2005-12-23 09:12:41 +00:00
Ian.Campbell@xensource.com e201be5d57 Merge. 2005-12-22 16:15:33 +00:00
emellor@leeni.uk.xensource.com 27efc4fd12 This patch fixes a bug/typo of main.py.
1. show option "-c" of help of xm dmesg
2. fix value of parameter of arg_check of xm log
3. fix aliases of vbd-create and vbd-destroy

Signed-off-by Yoshinori Katase <y_katase@soft.fujitsu.com>
2005-12-22 15:38:10 +00:00
cl349@firebug.cl.cam.ac.uk 7fae73c67e Remove xen specific bug() implementation -- the regular one works just fine.
From: "Jan Beulich" <JBeulich@novell.com>
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-12-22 15:50:06 +01:00
Ian.Campbell@xensource.com 40924689a9 Add support to xenctx for printing stack traces on x86_32 and x86_64.
To support this add xc_translate_foreign_address to libxc. This function
walks page tables and translates virtual addresses using a given domain
and vcpu page table.

Signed-off-by: Ian Campbell <Ian.Campbell@XenSource.com>
2005-12-22 14:33:19 +00:00
kaf24@firebug.cl.cam.ac.uk 4f27f31a47 Remove acpi_count_madt functions. Only appear to be used
for diagnostic tracing in xen/ia64.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-21 20:18:19 +01:00
kaf24@firebug.cl.cam.ac.uk b20f22d5c4 Remove unused local variables (from removed REASIGN_PAGE
function).

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-21 20:17:22 +01:00
kaf24@firebug.cl.cam.ac.uk e82f519465 Merge with xen-ia64-unstable.hg. 2005-12-21 19:52:00 +01:00
kaf24@firebug.cl.cam.ac.uk 93a7173714 Remove obsolete MMUEXT_REASSIGN_PAGE. It's not used by
anyone and is superceded by grant transfers.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-21 19:10:53 +01:00
djm@kirby.fc.hp.com a220ae9a8d Merge 2005-12-21 11:56:19 -06:00
kaf24@firebug.cl.cam.ac.uk db74dfce16 Fix gnttab_release_mappings -- it doesn't need to drop
page refcnts for host mappings as they are already
destroyed by put_page_from_l1e(). Also call
gnttab_release_mappings later (after destroying
page-table references) and from common code rather than
arch/x86.

Also a few other misc gnttab cleanups.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-21 18:45:43 +01:00
kaf24@firebug.cl.cam.ac.uk d9af6ba2e0 Increment page reference count for every host/device
mapping created via a grant reference, rather than one
increment for all uses of a single grant reference.
This avoids a nasty situation in put_page_from_l1e()
where we cannot reliably determine whether a mapping was
created via a grant reference and so we must always
decrement the mapped page's reference count.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-21 18:25:34 +01:00
kaf24@firebug.cl.cam.ac.uk f1e0d84148 Declare kasprintf before use.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-12-21 18:16:31 +01:00
djm@kirby.fc.hp.com 82a32ebf85 Disable chatty translate_domain_pte messages for normal grant table traffic 2005-12-21 10:30:10 -06:00