| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Changes:
- Added to_ma function which translates a physical address to a
machine address for HVM guests and just returns the address for PV
guests.
- Use to_ma() in map_domain_va_32, map_domain_va_pae and
map_domain_va_64 to abstract away differences between HVM and PV
guests.
- (From Keir, Ryan) Export CR0 to PV guests as well.
I've removed the address checks against 0 since the last version since
physical/machine address 0 should be valid. Invalid translations
should be catched in xc_map_foreign_domain.
Signed-Off-By: Simon Kagstrom <simon.kagstrom@bth.se>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
in the elf paddr and entry fields.
Add a new __xen_guest header field to distinguish between kernels with
the previous use of the paddr field and the new use.
Add a new __xen_guest header field to control the kernel entry point,
since the elf header entry field now points to a physical address.
This header field is also useful for supporting alternative entry
points in kernel images which run both on xen and native.
Also add a kernel config option to control whether the resulting kernel
should include compatibility code to run on Xen 3.0.2 or whether such
code such be left out, resulting in a kernel which will only run on
newer Xen versions. Default to having compatibility enabled.
Kernels built with the new use of the elf header fields would otherwise
not work on Xen versions prior to this changeset.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
|
| |
| |
| |
| |
| |
| | |
to a live guest.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
reset num_pfns before hypercalling, more checks in hypercall, cleanup
Signed-off-by: Tristan Gingold <tristan.gingold@bull.net>
|
|/
|
|
|
|
|
|
| |
Move evtchn_vector from vcpu_info to shared_info.
Signed-off-by: Tristan Gingold <tristan.gingold@bull.net>
|
|
|
|
|
|
|
|
|
| |
Make header path for kernel's privcmd/evtchn headers generic.
Remove pointless xi_*() interface that was using private libxc
interfaces.
Signed-off-by: John Levon <john.levon@sun.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
interface (the legacy hypercalls would break if subcommands with large
argument structures were added, as it would grow the size of the
union of all argument structures).
Also, based on a patch from Kevin Tian, add a new physdev op to
signal EOI for a particular irq.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
| |
Signed-off-by Kevin Tian <kevin.tian@intel.com>
|
|
|
|
|
|
|
| |
are function macros rather than define/declare macros.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
| |
GET/SET_XEN_GUEST_HANDLE patch.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
| |
in Linux and libxc.
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
|
|\ |
|
| |
| |
| |
| |
| | |
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
|
|\| |
|
| |
| |
| |
| |
| |
| |
| |
| | |
Trailing whitespace removed with:
perl -p -i -e 's/\s+$/\n/g' tools/libxc/*.[ch]
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
|
|\| |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Move .PHONY directives next to targets,
this makes them a lot harder to miss
* Add missing .PHONY directives
* Remove nonexistent .PHONY directives
* Hopefully I didn'T miss anything...
Signed-Off-By: Horms <horms@verge.net.au>
|
| |
| |
| |
| |
| | |
Signed-off-by: Steven Hand <steven@xensource.com>
|
| |
| |
| |
| |
| | |
Signed-off-by: Steven Hand <steven@xensource.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
paravirtualized and fully virtualized. This approach uses the new
sched_op to handle other domains than the current domain. The new
code, SCHEDOP_remote_shutdown, is very much like SCHEDOP_shutdown, but
is called with the id of the domain which is to be shut down. This
allows fully virtualized shutdown and para-virtualized shutdown to be
identical from that point forward.
A paravirtualized domain uses sched_op to shut down and set the reason
code. This will send a VIRQ_DOM_EXC, which can be handled in dom0 by
control software. In some ways, this resembles SIGCHILD/waitpid, and
is a reasonable model.
The fully virtualized case has qemu invoke xm directly. This is a
different path than paravirtualized. It also removes decision and
policy making choices from the rest of the control software and places
it within qemu. When any dom0 logic eventually gets a VIRQ_DOM_EXC,
the information about the domain is gone having been destroyed by xm.
A libxenctrl wrapper, xc_shutdown_domain has been added and qemu now
calls it.
As a freebie, #if 0 some very verbose logging code in qemu. Totally
unrelated, but as long as I was there...
Signed-off-by: Ben Thomas <ben@virtualiron.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
Catch Ctrl-C for gdbserver and let gdb break from continue command.
Signed-Off-By: Nitin A Kamble <nitin.a.kamble@intel.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
writing back of register state for HVM guests.
From: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Keir Fraser <keir@xensource.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
As we know, the mechanism for hypervisor to pass parameter through pointer
is not complete. Hypervisor use copy_from/to_user functions to copy parameter
to hypervisor and copy result to user, if there is a tlb miss happening and
hypervisor can't handled this. This hypercall fails, there is no mechanism to
handle this failure, that may cause domain crash. Get_pfn_list hypercall copy
large data from hypervisor to user, it is easy to trigger this issue when
creating VTI-domain.
If fails, Get_pfn_list returns the number of pfn entries, and this patch will
Dummy access parameter memory block to cause this tlb mapping tracked by
Hypervisor, then continue to do get_pfn_list.
It's a workaround before we design a new mechanism of passing parameter thr
pointer.
Signed-off-by: Anthony Xu <anthony.xu@intel.com>
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch removes ugly hack upon memory operation and thus
allow inc/decrease_reservation op available for xen/ia64 now.
As a result:
* Now we conform to common sequence where all domain pages
are allocated together by increase_reservation before
image builder
* physmap table is now built at point of arch_set_info_guest
* DOM0_GETMEMLIST can only query without allocation now
After this patch, some long-existing hacks due to mismatched
memory interface are cleaned this time. Also this is a base
step toward introducing balloon feature into xen/ia64.
Signed-off-by Kevin Tian <kevin.tian@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1. gdb_regs for 64bit, and macros to transfer regisers between ptrace
registers to gdb registers
2. xc_ptrace code building for 64bit
3. Implementation of new map_domain_va for 64bit
4. gdbserver-xen build configuration fixes for 64bit
From: Nitin Kamble
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
| |
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
guest guest physical address, even when the guest paging is disabled.
The gdbserver-xen tries to access guest pdes & ptes to map memory of
hvm guest being debugged; and it gets a seg-fault because guest has not
setup it's paging yet. The attached patch adds guest paging state check,
so that the map_domain_va() can get the correct guest physical address
from guest va.
Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
|
|
|
|
|
|
|
|
|
| |
Also change v_end type from unsigned long to unsigned long long, for we
will have PAE VMX guest with more than 4G memory on PAE xen.
Signed-off-by: Xin Li <xin.b.li@intel.com>
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| | |
bytes as unsigned quantities.
Signed-off-by: David Lively <dlively@virtualiron.com>
|
|\| |
|
| |
| |
| |
| |
| |
| | |
Signed-off-by: Alex Williamson <alex.williamson@hp.com>
|
| |
| |
| |
| |
| |
| | |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
| |
| |
| |
| |
| |
| | |
Signed-off-by: Andrew D. Ball <aball@us.ibm.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
output. Refactor the code slightly to allow more user-specified
control. This is done by adding a parallel
xc_domain_dumpcore_via_callback, which allows the specification of a
callback routine and an opaque argument block. The existing dumpcore
routine is modified to use the callback for all write operations and
to turn the single seek into a small write (it's for page alignment).
Signed-off-by: Ben Thomas <bthomas@virtualiron.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
with new subcommand add_to_physmap.
This changes the domain0 tools interface, but only when building
shadow-translate-mode guests.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
xc_domain_getinfo returns information about a domain, but not
necessarily the one you asked about. Add check for this.
max_vcpu_id in xc_domain_getinfo is really an ID, not a count, so
make the loop include the last VCPU
Signed-off-by: Ben Thomas <ben@virtualiron.com>
|
| |
| |
| |
| |
| |
| | |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
like to control the base compilation flags from a central place.
Signed-off-by: Charles Coffing <ccoffing@novell.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Instead of putting the page outside of the guests pseudo-physical address
space, we put it next to the other pages filled by the domain builder,
such that the page is already mapped in the initial pagetables and/or a
lowmem-type memory mapping.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
than all in one go, to conserve memory. This always has been
the behaviour, but it was changed by a changeset earlier today.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
parameters where possible, to avoid unnecessary casts.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
ramdisks to be passed via buffer, rather than via file. This allows
usage of the underlying domain building routines in "file-challenged"
enviroments.
Specifically, xc_linux_build_mem is the buffer oriented version of the
file-oriented xc_linux_build. Likewise, xc_hvm_build_mem is the
buffer oriented analog of the file based xc_hvm_build.
Signed-off-by: Ben Thomas (bthomas@virtualiron.com)
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
to move blocks of memory 4096 pages at a time, and a buffer is
allocated for this. Unfortunately, the #define is without
parentheses and %/* are the same order and evaluated left to right.
Result: very big buffer being used 4 pages at a time.
Signed-off-by: Ben Thomas (bthomas@virtualiron.com)
|
| |
| |
| |
| |
| |
| | |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
| |
| |
| |
| |
| |
| | |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|/
|
|
|
|
| |
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
|
|
|
|
|
|
|
|
|
|
| |
The xen core files record a magic number,
but when they are loaded it isn't checked.
This patch resolves this.
Signed-Off-By: Horms <horms@verge.net.au>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* xc_ptrace
- Merge xc_ptrace_core into xc_ptrace
- ATTACH now reads the data argument. If non-zero then
a corefile is being debuged. Otherwise a thread has
been attached to. This allows xc_waitdomain_core() or
xc_waitdomain() to be called as appropriate in
subsequent xc_ptrace() calls.
* xc_waitdomain
- Rename xc_waitdomain (xc_ptrace.c version) __xc_waitdomain
- Rename xc_waitdomain (xc_ptrace_core.c version) xc_waitdomain_core
- Create xc_waitdomain (in xc_ptrace.c), a wrapper for __xc_waitdomain
and xc_waitdomain_core.
Consolidation seemed difficult but ctxt needs to be
passed into xc_waitdomain_core or made global.
Alternatively, xc_waitdomain_core could be moved into xc_ptrace.c,
but this seems messy.
* map_domain_va
- Rename map_domain_va (xc_ptrace_core.c version) map_domain_va_core
- Have it accept ctxt, like xc_waitdomain_core
* myptrace and myxcwait (linux-xen-low.c)
Removed, call the now generic xc_ptrace() and xc_waitdomain() instead
When calling xc_ptrace ATTACH, if a corefile is in use, a fd will
be passed, otherwise a pid. The fd part is important, as this
is saved internally in xc_ptrace_core.c, and passed to xc_waitdomain_core()
as neccessary. Pereviously xc_waitdomain_core() received a pid and
thus could not open the corefile.
Signed-Off-By: Horms <horms@verge.net.au>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
General Cleanups
* Use { after if consistently in xc_ptrace.c and xc_ptrace_core.c
(But not in xc_ptrace_core() which should be removed shortly)
* Remove duplicate code and centralise around xc_ptrace.h
* Avoid ifing values covered by case in xc_ptrace()
- PTRACE_GETREGS, PTRACE_GETFPREGS and PTRACE_GETFPXREGS are grouped into
a single case, and then with the exception of a call to FETCH_REGS(),
different code is executed based on ifing the values covered by the
case. The PTRACE_GETFPREGS and PTRACE_GETFPXREGS code is actually a
duplicate. This patch breaks the code out to two different cases.
Error Handling
* Eliminate FETCH_REGS macro as it forces several functions
to have an otherwise uneeded error_out label, mittigating
any code savins.
* Rework error handling in xc_ptrace().
- Remove FETCH_REGS as above
- Make sure that all dom0 errors are caught
- Make sure errno is always set on error
* Eliminate gotos in xc_ptrace_core.c that do nothing but return
Signed-Off-By: Horms <horms@verge.net.au>
|