ia64/xen-unstable

changeset 16750:0f5926ba1d28

[IA64] vti fault handler clean up: vmx_vit.S white space & stale comments

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
author Alex Williamson <alex.williamson@hp.com>
date Fri Dec 14 13:07:01 2007 -0700 (2007-12-14)
parents 54ed70d1dd11
children ba569af64b44
files xen/arch/ia64/vmx/vmx_ivt.S
line diff
     1.1 --- a/xen/arch/ia64/vmx/vmx_ivt.S	Fri Dec 14 13:04:27 2007 -0700
     1.2 +++ b/xen/arch/ia64/vmx/vmx_ivt.S	Fri Dec 14 13:07:01 2007 -0700
     1.3 @@ -70,28 +70,23 @@
     1.4  
     1.5  
     1.6  #ifdef VTI_DEBUG
     1.7 -  /*
     1.8 -   * This lets you track the last eight faults that occurred on the CPU.  Make sure ar.k2 isn't
     1.9 -   * needed for something else before enabling this...
    1.10 -   */
    1.11 -#define VMX_DBG_FAULT(i) \
    1.12 -    add r16=IVT_CUR_OFS,r21;    \
    1.13 -    add r17=IVT_DBG_OFS,r21;;   \
    1.14 -    ld8  r18=[r16];;    \
    1.15 -    add r17=r18,r17;   \
    1.16 -    mov r19=cr.iip;     \
    1.17 -    mov r20=cr.ipsr;    \
    1.18 -    mov r22=cr.ifa;     \
    1.19 -    mov r23=i;;          \
    1.20 -    st8 [r17]=r19,8;   \
    1.21 -    add r18=32,r18;;     \
    1.22 -    st8 [r17]=r20,8;    \
    1.23 -    mov r19=0xfe0;;      \
    1.24 -    st8 [r17]=r22,8;   \
    1.25 -    and r18=r19,r18;;   \
    1.26 -    st8 [r17]=r23;      \
    1.27 -    st8 [r16]=r18;;     \
    1.28 -//# define VMX_DBG_FAULT(i)   mov r16=ar.k2;; shl r16=r16,8;; add r16=(i),r16;;mov ar.k2=r16
    1.29 +#define VMX_DBG_FAULT(i)                \
    1.30 +    add r16=IVT_CUR_OFS,r21;            \
    1.31 +    add r17=IVT_DBG_OFS,r21;;           \
    1.32 +    ld8  r18=[r16];;                    \
    1.33 +    add r17=r18,r17;                    \
    1.34 +    mov r19=cr.iip;                     \
    1.35 +    mov r20=cr.ipsr;                    \
    1.36 +    mov r22=cr.ifa;                     \
    1.37 +    mov r23=i;;                         \
    1.38 +    st8 [r17]=r19,8;                    \
    1.39 +    add r18=32,r18;;                    \
    1.40 +    st8 [r17]=r20,8;                    \
    1.41 +    mov r19=0xfe0;;                     \
    1.42 +    st8 [r17]=r22,8;                    \
    1.43 +    and r18=r19,r18;;                   \
    1.44 +    st8 [r17]=r23;                      \
    1.45 +    st8 [r16]=r18;;
    1.46  #else
    1.47  # define VMX_DBG_FAULT(i)
    1.48  #endif
    1.49 @@ -102,23 +97,21 @@
    1.50  #include "minstate.h"
    1.51  
    1.52  
    1.53 -#define VMX_FAULT(n)    \
    1.54 -vmx_fault_##n:;          \
    1.55 -    mov r19=n;           \
    1.56 -    br.sptk.many dispatch_to_fault_handler;         \
    1.57 -    ;;                  \
    1.58 -
    1.59 +#define VMX_FAULT(n)                            \
    1.60 +vmx_fault_##n:;                                 \
    1.61 +    mov r19=n;                                  \
    1.62 +    br.sptk.many dispatch_to_fault_handler;     \
    1.63 +    ;;
    1.64  
    1.65 -#define VMX_REFLECT(n)    \
    1.66 -    mov r31=pr;           \
    1.67 -    mov r19=n;       /* prepare to save predicates */ \
    1.68 -    mov r29=cr.ipsr;      \
    1.69 -    ;;      \
    1.70 -    tbit.z p6,p7=r29,IA64_PSR_VM_BIT;       \
    1.71 -(p7)br.sptk.many vmx_dispatch_reflection;        \
    1.72 +#define VMX_REFLECT(n)                              \
    1.73 +    mov r31=pr;                                     \
    1.74 +    mov r19=n;  /* prepare to save predicates */    \
    1.75 +    mov r29=cr.ipsr;                                \
    1.76 +    ;;                                              \
    1.77 +    tbit.z p6,p7=r29,IA64_PSR_VM_BIT;               \
    1.78 +(p7)br.sptk.many vmx_dispatch_reflection;           \
    1.79      br.sptk.many dispatch_to_fault_handler
    1.80  
    1.81 -
    1.82  GLOBAL_ENTRY(vmx_panic)
    1.83      br.sptk.many vmx_panic
    1.84      ;;