aboutsummaryrefslogtreecommitdiffstats
path: root/tools/xentrace/xenctx.c
Commit message (Collapse)AuthorAgeFilesLines
* libxc: introduce xc_domain_get_guest_width()Dario Faggioli2013-09-131-6/+3
| | | | | | | | | | | | | | As a wrapper to XEN_DOMCTL_get_address_size, and use it wherever the call was being issued directly via do_domctl(), saving quite some line of code. Actually, the function returns the guest width in bytes, rather than directly what XEN_DOMCTL_get_address_size provides (which is a number of bits), since that is what it is useful almost everywhere. Signed-off-by: Dario Faggioli <dario.faggioli@citrix.com> Acked-by: Ian Campbell <ian.campbell@citrix.com>
* xenctx: Support arm64 and actually implement output for 32 and 64 bitIan Campbell2013-04-241-4/+137
| | | | | | | A bit basic and fuggly but a start. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
* xenctx: remove trailing whitespaceIan Campbell2013-04-241-9/+9
| | | | | Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
* xenctx: remove remnants of ia64 supportIan Campbell2013-04-241-301/+1
| | | | | | Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Acked-by: Jan Beulich <jbeulich@suse.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
* Fix emacs local variable block to use correct C style variable.David Vrabel2013-02-211-1/+1
| | | | | | | The emacs variable to set the C style from a local variable block is c-file-style, not c-set-style. Signed-off-by: David Vrabel <david.vrabel@citrix.com
* arm: compile xentraceStefano Stabellini2012-05-301-0/+12
| | | | | | | Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Acked-by: Ian Campbell <ian.campbell@citrix.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com> Committed-by: Ian Campbell <ian.campbell@citrix.com>
* xenctx: add option -C to dump context for all vcpusOlaf Hering2011-06-171-2/+24
| | | | | Signed-off-by: Olaf Hering <olaf@aepfle.de> Committed-by: Ian Jackson <ian.jackson.citrix.com>
* xenctx: move xc_* access out of dump_ctxOlaf Hering2011-06-171-41/+62
| | | | | | | | | move xc_* access out of dump_ctx. Update code paths to return an error instead of calling exit(). On error unpause the guest if it was paused by xenctx. Signed-off-by: Olaf Hering <olaf@aepfle.de> Committed-by: Ian Jackson <ian.jackson.citrix.com>
* xenctx: move all globals into struct xenctxOlaf Hering2011-06-171-37/+39
| | | | | | | | Move all globals used for options and libxc data into a new struct xenctx. This is used in subsequent changes. Signed-off-by: Olaf Hering <olaf@aepfle.de> Committed-by: Ian Jackson <ian.jackson.citrix.com>
* xenctx: recognize also -S option for --stack-traceOlaf Hering2011-06-171-2/+2
| | | | | | | Update help text. Signed-off-by: Olaf Hering <olaf@aepfle.de> Committed-by: Ian Jackson <ian.jackson.citrix.com>
* xentrace: build fix "array subscript has type 'char'"Keir Fraser2011-01-111-3/+3
| | | | Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
* xenctx: misc adjustmentsKeir Fraser2011-01-111-13/+28
| | | | | | | | | - fix off-by-one errors during symbol insertion and lookup - don't store the symbol type, as it wasn't needed at all so far and is only needed now at parsing time - don't insert certain kinds of symbols Signed-off-by: Jan Beulich <jbeulich@novell.com>
* libxc: eliminate static variables, use xentoollog; API changeKeir Fraser2010-05-281-3/+3
| | | | | | | | | | | | | | | | | | | | This patch eliminate the global variables in libxenctrl (used for logging and error reporting). Instead the information which was in the global variables is now in a new xc_interface* opaque structure, which xc_interface open returns instead of the raw file descriptor; furthermore, logging is done via xentoollog. There are three new parameters to xc_interface_open to control the logging, but existing callers can just pass "0" for all three to get the old behaviour. All libxc callers have been adjusted accordingly. Also update QEMU_TAG for corresponding qemu change. Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
* xenctx: Add --kernel-start option, to set the user/kernel splitKeir Fraser2010-05-271-7/+14
| | | | | | Used when displaying stack traces. Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
* xenctx, ia64: fix compilation error.Keir Fraser2009-04-021-1/+1
| | | | Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
* xenctx: Teach xenctx how to find the right addresses in real-mode.Keir Fraser2009-03-311-8/+30
| | | | Signed-off-by: George Dunlap <george.dunlap@eu.citrix.com>
* xenctx: Always show code context, even when not in kernel modeKeir Fraser2009-03-311-14/+20
| | | | Signed-off-by: George Dunlap <george.dunlap@eu.citrix.com>
* xenctx: print x86_32 context on x86_64Keir Fraser2009-02-061-0/+31
| | | | | | Although x86_64 context covers x86_32, I think it's easy to watch. Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>
* xenctx support for 64-bit HVM guestsKeir Fraser2009-02-051-10/+17
| | | | | | | Now that we can easily find EFER.LMA, xenctx can detect 64-bit HVM VCPUs Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
* [IA64] compilation fix of xenctxIsaku Yamahata2009-01-071-3/+3
| | | | | | | | | | | | This patch fixes the following compilation error caused by 18963:9cc632cc6d40 of xen-unstable.hg > xenctx.c: In function 'print_ctx': > xenctx.c:430: error: request for member 'c' in something not a structure or union > xenctx.c:431: error: 'vcpu_guest_context_any_t' has no member named 'regs' > xenctx.c:484: error: 'vcpu_guest_context_any_t' has no member named 'event_callback_ip' Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
* xenctx: compat-mode/HVM supportKeir Fraser2009-01-051-105/+185
| | | | | | | | Add support to xenctx for guests that have a different word size to the tools (x86 only, but shouldn't break ia64). Again, only 32-bit HVM guests are supported until EFER.LMA is easier to get at. Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
* xenctx: fix xenctx --all option on x86Keir Fraser2008-09-221-1/+1
| | | | Signed-off-by: Akio Takebe <takebe_akio@jp.fujitsu.com>
* tools: Declare functions static where they should be, and provideKeir Fraser2008-07-151-14/+16
| | | | | | proper prototypes for others as required. Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
* Compilation fix for x86_64 caused by 17880:d3a87899985d.Keir Fraser2008-06-201-2/+0
| | | | Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
* libxc: The following patch replace the libxc interface to useKeir Fraser2008-06-191-4/+6
| | | | | | | vcpu_guest_context_any_t (which is both 32 and 64 bits) instead of vcpu_guest_context_t. Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>
* xenctx/x86: fix format for readability and add informationKeir Fraser2008-01-181-31/+59
| | | | Signed-off-by: Jan Beulich <jbeulich@novell.com>
* xentrace: make xentrace and xenmon work on Solaris and *BSD.Keir Fraser2007-11-161-3/+8
| | | | | | | | | | | | - Use getopt() to get rid of argp dependency which does not exist on Solaris and *BSD. Done by Tariq Magdon-Ismail. - Minor modifications by me (Christoph) to make it also work on *BSD. - Tested on Linux by me (Christoph). No functional change on Linux. - Tariq ok'd BSD modifications for Solaris - Tariq ok'd submission by me :) Signed-off-by: Tariq Magdon-Ismail <tariqmi@sun.com> Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
* merge with xen-unstable.hg (staging)Alex Williamson2007-10-021-6/+49
|\
| * xenctx: Print EFLAGS for i386 and x86/64.Keir Fraser2007-10-021-6/+49
| | | | | | | | | | From: Peter Johnston <pjohnston@xensource.com> Signed-off-by: Keir Fraser <keir@xensource.com>
* | [IA64] xenctx: fix rse arithmeticAlex Williamson2007-10-011-1/+1
|/ | | | Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
* [IA64] Remove IA64_GUEST_CONTEXT_RBS_OFFSETAlex Williamson2007-07-021-4/+7
| | | | | | | Pass the offset in the vcpu_reg struct. Fix displaying stack register in xenctx. Signed-off-by: Tristan Gingold <tgingold@free.fr>
* [IA64] Many more registers displayed (through a command-line option).Alex Williamson2007-06-211-96/+255
| | | | | Signed-off-by: Tristan Gingold <tgingold@free.fr> Acked-by: Keir Fraser <keir@xensource.com>
* [IA64] Rewrite ia64 vcpu_guest_context_regs structureAlex Williamson2007-05-071-89/+83
| | | | | | | All registers and the rbs are now declared in the structure. Minimal updates to other parts. Signed-off-by: Tristan Gingold <tgingold@free.fr>
* [IA64] xenctx shows more registers for ia64awilliam@xenbuild.aw2006-10-241-4/+102
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds more user registers to show them to xenctx for ia64. Tested domU/domVTi on ia64. Sample is the below. # ./xenctx 1 0 iip: e000000000000810 ipsr: 00001012087a6010 b0: a000000100068a70 b6: a00000010014ff60 b7: e000000000000800 cr_ifs: 800000000000050a ar_unat: 0000000000000000 ar_pfs: 8000000000000209 ar_rsc: 0000000000000008 ar_rnat: 0000000000000000 ar_bspstore: a000000100c19030 ar_fpsr: 0009804c8a70433f event_callback_ip: a000000100067a20 pr: 000000000005aa85 loadrs: 0000000000780000 iva: a000000100008000 dcr: 0000000000007e04 r1: a0000001010369a0 r2: 0000000000001000 r3: 8000000000000209 r4: 0000000000000000 r5: 0000000000000000 r6: 0000000000000000 r7: 0000000000000000 r8: a000000100068a70 r9: 0000000000000100 r10: 0000000000000000 r11: 0000000000050ac5 sp: a000000100c1fd80 tp: a000000100c18000 r14: 0000000000000001 r15: 0000000000000000 r16: fffffffffff04c18 r17: a000000100c1fdb0 r18: a000000100c1fdb1 r19: a000000100c1fe90 r20: a000000100c1fe10 r21: 0000000000000000 r22: 0000000000000001 r23: 0000000000000000 r24: a000000100e5a448 r25: a000000100c18f10 r26: ffffffffffff0030 r27: 0000000000000000 r28: 000000000000001d r29: 0000000000000000 r30: 0000000000000000 r31: 0000000000000000 itr: P rid va pa ps ed pl ar a d ma key [0] 1 000005 a000000100000000 0000004000000 1a 64M 1 2 3 1 1 0 WB 000000 [1] 1 000007 e000000000000000 0000000000000 18 16M 1 2 3 1 1 0 WB 000000 [2] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [3] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [4] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [5] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [6] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [7] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 dtr: P rid va pa ps ed pl ar a d ma key [0] 1 000005 a000000100000000 0000004000000 1a 64M 1 2 3 1 1 0 WB 000000 [1] 1 000007 ffffffffffff0000 0000000010000 10 64K 1 2 3 1 1 0 WB 000000 [2] 1 000007 e000000000000000 0000000000000 18 16M 1 2 3 1 1 0 WB 000000 [3] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [4] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [5] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [6] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 [7] 0 000000 0000000000000000 0000000000000 00 0 0 0 0 0 0 WB 000000 Signed-off-by: Akio Takebe <takebe_akio@jp.fujitsu.com> Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
* [IA64] dummy print_stack() func for NO_TRANSLATION pathawilliam@xenbuild.aw2006-06-191-2/+2
| | | | | | Signed-off-by: Alex Williamson <alex.williamson@hp.com>
* [IA64] fix is_kernel_text in xenctx and show more registersawilliam@xenbuild.aw2006-06-191-16/+39
| | | | | | Signed-off-by: Akio Takebe <takebe_akio@jp.fujitsu.com>
* [IA64] enable xenctx on ia64awilliam@xenbuild.aw2006-06-191-1/+38
| | | | | | Signed-off-by: Tristan Gingold <tristan.gingold@bull.net>
* add the hypercall_page to xenctx knowledge.vhanquez@kneesa.uk.xensource.com2006-01-311-1/+6
| | | | | Signed-off-by: Vincent Hanquez <vincent@xensource.com>
* Fix a couple of bogus dom0_op names:kaf24@firebug.cl.cam.ac.uk2006-01-061-2/+2
| | | | | | | | | setdomaininfo -> setvcpucontext pincpudomain -> setvcpuaffinity Signed-off-by: Keir Fraser <keir@xensource.com>
* Add support to xenctx for printing stack traces on x86_32 and x86_64.Ian.Campbell@xensource.com2005-12-221-12/+386
| | | | | | | | | 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>
* Fix Xen public interfaces and the tools to consistentlykaf24@firebug.cl.cam.ac.uk2005-10-121-1/+1
| | | | | | | | use stdint-format bitsize types (uint32_t and friends). Signed-off-by: Keir Fraser <keir@xensource.com>
* Rename libxc => libxenctrl and xc.h => xen/xenctrl.hcl349@firebug.cl.cam.ac.uk2005-08-241-1/+1
| | | | | | | | | Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk> --HG-- rename : tools/libxc/xc.h => tools/libxc/xenctrl.h
* Don't build xenctx by default,a nd fix one error msg.kaf24@firebug.cl.cam.ac.uk2005-07-111-1/+1
|
* Fix xenctx compilation and support 64 bit.kaf24@firebug.cl.cam.ac.uk2005-07-111-15/+47
| | | | | Signed-off-by: Arun Sharma <arun.sharma@intel.com>
* bitkeeper revision 1.1389.1.2 (4270ed5dZvr_HdIQR0eBM2m4Kj81_A)kaf24@firebug.cl.cam.ac.uk2005-04-281-17/+16
| | | | | | | | | Renames: execution_context/xen_regs -> cpu_user_regs full_execution_context -> vcpu_guest_context [defined both 'struct xxx' and 'xxx_t' forms] Signed-off-by: Keir Fraser <keir@xensource.com>
* bitkeeper revision 1.1189 (420d52d34bmxozCOzbUs5pmo2zfT-w)iap10@freefall.cl.cam.ac.uk2005-02-121-0/+84
Subject: [PATCH] xenctx.patch Does this sound interesting? I found it useful to debug looping guests. A gdb stub would be nicer - but this one is lighter weight. -Arun Tool for dumping the cpu context # xenctx 1 0 eip: c01dfeab esp: c1603c98 eax: 00000020 ebx: c0432e10 ecx: 00000ee6 edx: 000001f7 esi: c0432d60 edi: 00000296 ebp: c0432d60 cs: 00000060 ds: 00000068 fs: 00000000 gs: 00000033 Signed-off-by: Arun Sharma <arun.sharma@intel.com> Signed-off-by: ian@xensource.com