diff options
author | kfraser@localhost.localdomain <kfraser@localhost.localdomain> | 2007-02-26 17:04:39 +0000 |
---|---|---|
committer | kfraser@localhost.localdomain <kfraser@localhost.localdomain> | 2007-02-26 17:04:39 +0000 |
commit | 7998832e812ab453e5373d8e63c0afa164fcddfe (patch) | |
tree | 1f105b06000962c19187324a661b2491185d41f5 /xen/include/asm-x86 | |
parent | 05741dbcafce2672294d685f1dd099556693b8b7 (diff) | |
download | xen-7998832e812ab453e5373d8e63c0afa164fcddfe.tar.gz xen-7998832e812ab453e5373d8e63c0afa164fcddfe.tar.bz2 xen-7998832e812ab453e5373d8e63c0afa164fcddfe.zip |
[xentrace][HVM] introduce HVM tracing to unify SVM and VMX tracing
* new tracing class TRC_HVM replacing TRC_VMX
* 20 new trace events to differentiate the information carried by them
** added corresponding trace points in SVM and VMX code
** updated formats file: descriptive formatting of trace event data
** completely replacing previous simple tracing in VMX
* possibility to toggle single events on and off at compile time in
include/asm-x86/hvm/trace.h
Signed-off-by: Thomas Friebel <thomas.friebel@amd.com>
Diffstat (limited to 'xen/include/asm-x86')
-rw-r--r-- | xen/include/asm-x86/hvm/support.h | 3 | ||||
-rw-r--r-- | xen/include/asm-x86/hvm/vcpu.h | 2 | ||||
-rw-r--r-- | xen/include/asm-x86/hvm/vmx/vmx.h | 6 |
3 files changed, 6 insertions, 5 deletions
diff --git a/xen/include/asm-x86/hvm/support.h b/xen/include/asm-x86/hvm/support.h index 4a3b14afe5..6e43a0301c 100644 --- a/xen/include/asm-x86/hvm/support.h +++ b/xen/include/asm-x86/hvm/support.h @@ -116,9 +116,6 @@ extern unsigned int opt_hvm_debug_level; #define HVM_DBG_LOG(level, _f, _a...) #endif -#define TRACE_VMEXIT(index, value) \ - current->arch.hvm_vcpu.hvm_trace_values[index] = (value) - /* * Save/restore support */ diff --git a/xen/include/asm-x86/hvm/vcpu.h b/xen/include/asm-x86/hvm/vcpu.h index 0d4c95930c..4da4c8a9c6 100644 --- a/xen/include/asm-x86/hvm/vcpu.h +++ b/xen/include/asm-x86/hvm/vcpu.h @@ -45,8 +45,6 @@ struct hvm_vcpu { /* Flags */ int flag_dr_dirty; - unsigned long hvm_trace_values[5]; - union { struct arch_vmx_struct vmx; struct arch_svm_struct svm; diff --git a/xen/include/asm-x86/hvm/vmx/vmx.h b/xen/include/asm-x86/hvm/vmx/vmx.h index 701edf0e63..43be711bd2 100644 --- a/xen/include/asm-x86/hvm/vmx/vmx.h +++ b/xen/include/asm-x86/hvm/vmx/vmx.h @@ -25,6 +25,7 @@ #include <asm/processor.h> #include <asm/hvm/vmx/vmcs.h> #include <asm/i387.h> +#include <asm/hvm/trace.h> extern void vmx_asm_vmexit_handler(struct cpu_user_regs); extern void vmx_asm_do_vmentry(void); @@ -294,6 +295,11 @@ static inline void __vmx_inject_exception(struct vcpu *v, int trap, int type, __vmwrite(VM_ENTRY_INSTRUCTION_LEN, ilen); __vmwrite(VM_ENTRY_INTR_INFO_FIELD, intr_fields); + + if (trap == TRAP_page_fault) + HVMTRACE_2D(PF_INJECT, v, v->arch.hvm_vmx.cpu_cr2, error_code); + else + HVMTRACE_2D(INJ_EXC, v, trap, error_code); } static inline void vmx_inject_hw_exception( |