From: Don Slutz Subject: [PATCH v8 00/20] xenctx: Many changes. Date: Thu, 27 Mar 2014 15:05:27 -0400 Message-ID: <1395947147-5262-1-git-send-email-dslutz@verizon.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xen.org Cc: Ian Campbell , Stefano Stabellini , George Dunlap , Ian Jackson , Don Slutz , Jan Beulich List-Id: xen-devel@lists.xenproject.org Add more functionality to xenctx. Fix some bugs. Change from v7 to v8: Moved v5 #17 "xenctx: Fixup options checking" and renamed to #11 "xenctx: Add error output if --all-vcpus (-C) and": New commit message make the new copy const. Added: #18: "xenctx: Add 16 bit output" Bug fix add: #19: "xenctx: Fix print_ctx_32on64's print_special call." #20: "xenctx: Ensure errno is not zero on error in xc_translate_foreign_address()" Changed: #4 "xenctx: Add command line options -b": Commit message adjusted. More CODING_STYLE changes. INT_MAX was too big. #13 "xenctx: change is_kernel_text() into kernel_addr().": Added more to commit message. Added some basic linux kernel module reporting. Moved kernel_end into define tree in case no symbol found. At some point __bss_stop was added and _end was dropped. Both mean end of named kernel data. #17 "xenctx: Allow output for offline vcpu when": Also change xc_translate_foreign_address() to work. Ian Campbell #1 "xenctx: clean up usage output": Acked-by #3 "xenctx: Add -n (--display-stack-pages) option to": Reworked comment. multiple_pages => nr_stack_pages me: Changed usage output. me: Added range checking of option. #5 "xenctx: Add command line option -D": Add "...exceeds 80 characters..." to commit message #6 "xenctx: Add command line option -t": Acked-by Add "...exceeds 80 characters..." to commit message #9 "xenctx: Add output of stack address to Call and" Was: "xenctx: Add command line option -T (--tag-trace)" Drop option. Add new routine: print_stack_addr #10 "xenctx: Add -m (--memory) option to dump": Add "Moved xenctx because.." to commit message Changed init of sopts to only have one copy of common options. Make common code into routine, me: Fixed bug with extra set bits on small widths. #15 "xenctx: Add output of vcpu value and state for": Acked-by me: Removed extra {} #16 "xenctx: Fix handling of !guest_protected_mode": A little more in the commit message. Change from v6 to v7: Jan Beulich: #13: "xenctx: Add convert of more registers to symbols": Move reg_is_addr_mask to an x86-specific section. Change from v5 to v6: Jan Beulich: #13: "xenctx: Add convert of more registers to symbols": Move reg_is_addr_mask to a common static. Change from v4 to v5: Jan Beulich: #13 "xenctx: Add convert of more registers to symbols": Add reg_is_addr_mask. #14 "xenctx: Add output of vcpu value and state for": Change vcpu=3 to vcpu3. Drop online. George Dunlap: #1 "xenctx: clean up usage output": Reviewed-by #2 "xenctx: Clean up stack trace when hypercall_page not": Acked-by #3 "xenctx: Add -n (--display-stack-pages) option to": Adjust option to -n, --display-stack-pages. Adjust usage message. #4 "xenctx: Add command line options -b": Add defaults to disply. Accept MAX for -l. #5 "xenctx: Add command line option -D": Add comment, move printf. #6 "xenctx: Add command line option -t": Reviewed-by #7 "xenctx: Change print_symbol to do the space before.": Acked-by #8 "xenctx: More info on failed to map page.": Acked-by #9 "xenctx: Add command line option -T (--tag-trace)": Adjust option name, usage. #10 "xenctx: Add -m (--memory) option to dump": Remove extra #ifndef. Make common routine print_lines(). Added #16 "xenctx: Allow output for offline vcpu when" #17 "xenctx: Fixup options checking." Change from v3 to v4: Dropped patches: v3 #2 "xenctx: Correct check for xc_interface_open failing (prevents SIGSEGV)" Simular code already in master v3 #16 "MAINTAINERS: Add XENCTX maintainer" Way too soon for this. Most: re-sytled all adds or changes to be in CODING_STYLE. #1 "xenctx: clean up usage output": Changed from kaddr to KADDR. Jan Beulich: v3 #4 "xenctx: Add -2 (--two-pages) option to switch stack size to 8KiB" Converted to #3 "xenctx: Add -m (--multiple_pages) option to output larger stack" #10 "xenctx: Add -M option to dump memory at" Changed from -m to -M Added #15 "xenctx: Fix handling of !guest_protected_mode" Dropped forever: v1 patch #11 "xenctx: Dump registers via hvm info if available" This was a hack to work around a bug fix that is in 4.4.0 Change from v2 to v3: Added patches #1, #2, #5, and #16. v3 #1 "xenctx: clean up usage output": Move all usage cleanup into it's own patch/ v3 #2 "xenctx: Correct check for xc_interface_open failing (prevents SIGSEGV)": Move xenctx.xc_handle out of patch v2 #9 "" v3 #5 "xenctx: Add command line options -b and -l": Redo to stack dump output size adjustments into commanle line options. v3 #16 "MAINTAINERS: Add XENCTX maintainer": Declare this I maintain xenctx, and drop George Dunlap. Unchanged (other then their number) v3 #3 "xenctx: Clean up stack trace when hypercall_page not in symbol table" v3 #8 "xenctx: Change print_symbol to do the space before." v3 #9 "xenctx: More info on failed to map page." Mostly from Jan Beulich: v3 #4 "xenctx: Add -2 (--two-pages) option to switch stack size to 8KiB": * Dropped extra change about i < 10. * Move add to usage to the end. v3 #6 "xenctx: Add command line option -D (--decode-as-ascii)": v3 #7 "xenctx: Add command line option -t (--tag-stack-dump)": v3 #10 "xenctx: Add command line option -T (--tag-call-trace)": * Add command line option to control this. * More info in commit message. v3 #11 "xenctx: Add -m option to dump memory at maddr.": * Reworked option handling to allow multiple actions to work. * Add check for NO_TRANSLATION where needed. * Support -b and -l. v3 #12 "xenctx: Add -d option to dump memory at daddr as a stack.": * Do this patch after -m patch. * Reworked option handling to allow multiple actions to work. * Add check for NO_TRANSLATION where needed. * More info in commit message. v3 #13 "xenctx: change is_kernel_text() into kernel_addr().": * new name is kernel_addr(). * Use kernel_start if set. * Remove other changes. v3 #14 "xenctx: Add convert of more registers to symbols": * Extract just the symbol printing code from "xenctx: Dump registers via hvm info if available" v3 #15 "xenctx: Add output of vcpu value and state for --all-vcpus": * Extract just the vcpu printing code from "xenctx: xenctx: Add optional fCPU" v1 patch #11 "xenctx: Dump registers via hvm info if available" has been defered to the "merge xenctx and xen_hvmctx" patch set. v1 patch #12 "xenctx: Add optional fCPU" has been dropped. Change from v1 to v2: title was: xenctx: Add an option to output more registers. Processed review comments. Jan Beulich: Split 1 change into 12. Switch to enum for is_kernel_text(), renamed to is_kernel_addr(). Renamed vars like memAddr to mem_addr. Ian Campbell: More on is_kernel_text(). Don Slutz (20): xenctx: clean up usage output xenctx: Clean up stack trace when hypercall_page not in symbol table xenctx: Add -n (--display-stack-pages) option to output larger stack xenctx: Add command line options -b (--bytes-per-line) and -l (--lines) xenctx: Add command line option -D (--decode-as-ascii) xenctx: Add command line option -t (--tag-stack-dump) xenctx: Change print_symbol to do the space before. xenctx: More info on failed to map page. xenctx: Add output of stack address to Call and Stack Trace. xenctx: Add -m (--memory) option to dump memory at maddr. xenctx: Add error output if --all-vcpus (-C) and [VCPU] are both specified. xenctx: Add -d (--dump-as-stack) option to dump memory at daddr as a stack. xenctx: change is_kernel_text() into kernel_addr(). xenctx: Add convert of more registers to symbols xenctx: Add output of vcpu value and state for --all-vcpus xenctx: Fix handling of !guest_protected_mode xenctx: Allow output for offline vcpu when specified. xenctx: Add 16 bit output xenctx: Fix print_ctx_32on64's print_special call. xenctx: Ensure errno is not zero on error in xc_translate_foreign_address() tools/libxc/xc_pagetab.c | 94 +++++-- tools/xentrace/xenctx.c | 627 +++++++++++++++++++++++++++++++++++++++-------- 2 files changed, 607 insertions(+), 114 deletions(-) -- 1.8.4