ia64/xen-unstable

changeset 9865:ee97d247a3b7

[IA64] cleanup hyperprivop definitions

Move hyperprivop definitions into arch-ia64.h

Signed-off-by: Tristan Gingold <tristan.gingold@bull.net>
author awilliam@xenbuild.aw
date Mon May 08 13:08:37 2006 -0600 (2006-05-08)
parents da5a42b7d719
children 707737b66f58
files linux-2.6-xen-sparse/include/asm-ia64/xen/privop.h xen/arch/ia64/xen/hyperprivop.S xen/arch/ia64/xen/privop.c xen/include/public/arch-ia64.h
line diff
     1.1 --- a/linux-2.6-xen-sparse/include/asm-ia64/xen/privop.h	Mon May 08 13:05:47 2006 -0600
     1.2 +++ b/linux-2.6-xen-sparse/include/asm-ia64/xen/privop.h	Mon May 08 13:08:37 2006 -0600
     1.3 @@ -11,33 +11,34 @@
     1.4  
     1.5  
     1.6  #include <asm/xen/asm-xsi-offsets.h>
     1.7 +#include <xen/interface/arch-ia64.h>
     1.8  
     1.9  #define IA64_PARAVIRTUALIZED
    1.10  
    1.11  #ifdef __ASSEMBLY__
    1.12 -#define	XEN_HYPER_RFI			break 0x1
    1.13 -#define	XEN_HYPER_RSM_PSR_DT		break 0x2
    1.14 -#define	XEN_HYPER_SSM_PSR_DT		break 0x3
    1.15 -#define	XEN_HYPER_COVER			break 0x4
    1.16 -#define	XEN_HYPER_ITC_D			break 0x5
    1.17 -#define	XEN_HYPER_ITC_I			break 0x6
    1.18 -#define	XEN_HYPER_SSM_I			break 0x7
    1.19 -#define	XEN_HYPER_GET_IVR		break 0x8
    1.20 -#define	XEN_HYPER_GET_TPR		break 0x9
    1.21 -#define	XEN_HYPER_SET_TPR		break 0xa
    1.22 -#define	XEN_HYPER_EOI			break 0xb
    1.23 -#define	XEN_HYPER_SET_ITM		break 0xc
    1.24 -#define	XEN_HYPER_THASH			break 0xd
    1.25 -#define	XEN_HYPER_PTC_GA		break 0xe
    1.26 -#define	XEN_HYPER_ITR_D			break 0xf
    1.27 -#define	XEN_HYPER_GET_RR		break 0x10
    1.28 -#define	XEN_HYPER_SET_RR		break 0x11
    1.29 -#define	XEN_HYPER_SET_KR		break 0x12
    1.30 -#define	XEN_HYPER_FC			break 0x13
    1.31 -#define	XEN_HYPER_GET_CPUID		break 0x14
    1.32 -#define	XEN_HYPER_GET_PMD		break 0x15
    1.33 -#define	XEN_HYPER_GET_EFLAG		break 0x16
    1.34 -#define	XEN_HYPER_SET_EFLAG		break 0x17
    1.35 +#define	XEN_HYPER_RFI			break HYPERPRIVOP_RFI
    1.36 +#define	XEN_HYPER_RSM_PSR_DT		break HYPERPRIVOP_RSM_DT
    1.37 +#define	XEN_HYPER_SSM_PSR_DT		break HYPERPRIVOP_SSM_DT
    1.38 +#define	XEN_HYPER_COVER			break HYPERPRIVOP_COVER
    1.39 +#define	XEN_HYPER_ITC_D			break HYPERPRIVOP_ITC_D
    1.40 +#define	XEN_HYPER_ITC_I			break HYPERPRIVOP_ITC_I
    1.41 +#define	XEN_HYPER_SSM_I			break HYPERPRIVOP_SSM_I
    1.42 +#define	XEN_HYPER_GET_IVR		break HYPERPRIVOP_GET_IVR
    1.43 +#define	XEN_HYPER_GET_TPR		break HYPERPRIVOP_GET_TPR
    1.44 +#define	XEN_HYPER_SET_TPR		break HYPERPRIVOP_SET_TPR
    1.45 +#define	XEN_HYPER_EOI			break HYPERPRIVOP_EOI
    1.46 +#define	XEN_HYPER_SET_ITM		break HYPERPRIVOP_SET_ITM
    1.47 +#define	XEN_HYPER_THASH			break HYPERPRIVOP_THASH
    1.48 +#define	XEN_HYPER_PTC_GA		break HYPERPRIVOP_PTC_GA
    1.49 +#define	XEN_HYPER_ITR_D			break HYPERPRIVOP_ITR_D
    1.50 +#define	XEN_HYPER_GET_RR		break HYPERPRIVOP_GET_RR
    1.51 +#define	XEN_HYPER_SET_RR		break HYPERPRIVOP_SET_RR
    1.52 +#define	XEN_HYPER_SET_KR		break HYPERPRIVOP_SET_KR
    1.53 +#define	XEN_HYPER_FC			break HYPERPRIVOP_FC
    1.54 +#define	XEN_HYPER_GET_CPUID		break HYPERPRIVOP_GET_CPUID
    1.55 +#define	XEN_HYPER_GET_PMD		break HYPERPRIVOP_GET_PMD
    1.56 +#define	XEN_HYPER_GET_EFLAG		break HYPERPRIVOP_GET_EFLAG
    1.57 +#define	XEN_HYPER_SET_EFLAG		break HYPERPRIVOP_SET_EFLAG
    1.58  #endif
    1.59  
    1.60  #ifndef __ASSEMBLY__
    1.61 @@ -48,8 +49,8 @@ extern int is_running_on_xen(void);
    1.62  extern int running_on_xen;
    1.63  #endif
    1.64  
    1.65 -#define	XEN_HYPER_SSM_I			asm("break 0x7");
    1.66 -#define	XEN_HYPER_GET_IVR		asm("break 0x8");
    1.67 +#define	XEN_HYPER_SSM_I		asm("break %0" : : "i" (HYPERPRIVOP_SSM_I))
    1.68 +#define	XEN_HYPER_GET_IVR	asm("break %0" : : "i" (HYPERPRIVOP_GET_IVR))
    1.69  
    1.70  /************************************************/
    1.71  /* Instructions paravirtualized for correctness */
     2.1 --- a/xen/arch/ia64/xen/hyperprivop.S	Mon May 08 13:05:47 2006 -0600
     2.2 +++ b/xen/arch/ia64/xen/hyperprivop.S	Mon May 08 13:08:37 2006 -0600
     2.3 @@ -46,25 +46,6 @@
     2.4  #undef RFI_TO_INTERRUPT // not working yet
     2.5  #endif
     2.6  
     2.7 -#define    XEN_HYPER_RFI           0x1
     2.8 -#define    XEN_HYPER_RSM_DT        0x2
     2.9 -#define    XEN_HYPER_SSM_DT        0x3
    2.10 -#define    XEN_HYPER_COVER         0x4
    2.11 -#define    XEN_HYPER_ITC_D         0x5
    2.12 -#define    XEN_HYPER_ITC_I         0x6
    2.13 -#define    XEN_HYPER_SSM_I         0x7
    2.14 -#define    XEN_HYPER_GET_IVR       0x8
    2.15 -#define    XEN_HYPER_GET_TPR       0x9
    2.16 -#define    XEN_HYPER_SET_TPR       0xa
    2.17 -#define    XEN_HYPER_EOI           0xb
    2.18 -#define    XEN_HYPER_SET_ITM       0xc
    2.19 -#define    XEN_HYPER_THASH         0xd
    2.20 -#define    XEN_HYPER_PTC_GA        0xe
    2.21 -#define    XEN_HYPER_ITR_D         0xf
    2.22 -#define    XEN_HYPER_GET_RR        0x10
    2.23 -#define    XEN_HYPER_SET_RR        0x11
    2.24 -#define    XEN_HYPER_SET_KR        0x12
    2.25 -
    2.26  #ifdef CONFIG_SMP
    2.27  #warning "FIXME: ptc.ga instruction requires spinlock for SMP"
    2.28  #undef FAST_PTC_GA
    2.29 @@ -106,7 +87,7 @@ GLOBAL_ENTRY(fast_hyperprivop)
    2.30  #endif
    2.31  	// HYPERPRIVOP_SSM_I?
    2.32  	// assumes domain interrupts pending, so just do it
    2.33 -	cmp.eq p7,p6=XEN_HYPER_SSM_I,r17
    2.34 +	cmp.eq p7,p6=HYPERPRIVOP_SSM_I,r17
    2.35  (p7)	br.sptk.many hyper_ssm_i;;
    2.36  
    2.37  	// FIXME. This algorithm gives up (goes to the slow path) if there
    2.38 @@ -127,70 +108,70 @@ GLOBAL_ENTRY(fast_hyperprivop)
    2.39  1:	// when we get to here r20=~=interrupts pending
    2.40  
    2.41  	// HYPERPRIVOP_RFI?
    2.42 -	cmp.eq p7,p6=XEN_HYPER_RFI,r17
    2.43 +	cmp.eq p7,p6=HYPERPRIVOP_RFI,r17
    2.44  (p7)	br.sptk.many hyper_rfi;;
    2.45  
    2.46  	// HYPERPRIVOP_GET_IVR?
    2.47 -	cmp.eq p7,p6=XEN_HYPER_GET_IVR,r17
    2.48 +	cmp.eq p7,p6=HYPERPRIVOP_GET_IVR,r17
    2.49  (p7)	br.sptk.many hyper_get_ivr;;
    2.50  
    2.51  	cmp.ne p7,p0=r20,r0
    2.52  (p7)	br.spnt.many dispatch_break_fault ;;
    2.53  
    2.54  	// HYPERPRIVOP_COVER?
    2.55 -	cmp.eq p7,p6=XEN_HYPER_COVER,r17
    2.56 +	cmp.eq p7,p6=HYPERPRIVOP_COVER,r17
    2.57  (p7)	br.sptk.many hyper_cover;;
    2.58  
    2.59  	// HYPERPRIVOP_SSM_DT?
    2.60 -	cmp.eq p7,p6=XEN_HYPER_SSM_DT,r17
    2.61 +	cmp.eq p7,p6=HYPERPRIVOP_SSM_DT,r17
    2.62  (p7)	br.sptk.many hyper_ssm_dt;;
    2.63  
    2.64  	// HYPERPRIVOP_RSM_DT?
    2.65 -	cmp.eq p7,p6=XEN_HYPER_RSM_DT,r17
    2.66 +	cmp.eq p7,p6=HYPERPRIVOP_RSM_DT,r17
    2.67  (p7)	br.sptk.many hyper_rsm_dt;;
    2.68  
    2.69  	// HYPERPRIVOP_GET_TPR?
    2.70 -	cmp.eq p7,p6=XEN_HYPER_GET_TPR,r17
    2.71 +	cmp.eq p7,p6=HYPERPRIVOP_GET_TPR,r17
    2.72  (p7)	br.sptk.many hyper_get_tpr;;
    2.73  
    2.74  	// HYPERPRIVOP_SET_TPR?
    2.75 -	cmp.eq p7,p6=XEN_HYPER_SET_TPR,r17
    2.76 +	cmp.eq p7,p6=HYPERPRIVOP_SET_TPR,r17
    2.77  (p7)	br.sptk.many hyper_set_tpr;;
    2.78  
    2.79  	// HYPERPRIVOP_EOI?
    2.80 -	cmp.eq p7,p6=XEN_HYPER_EOI,r17
    2.81 +	cmp.eq p7,p6=HYPERPRIVOP_EOI,r17
    2.82  (p7)	br.sptk.many hyper_eoi;;
    2.83  
    2.84  	// HYPERPRIVOP_SET_ITM?
    2.85 -	cmp.eq p7,p6=XEN_HYPER_SET_ITM,r17
    2.86 +	cmp.eq p7,p6=HYPERPRIVOP_SET_ITM,r17
    2.87  (p7)	br.sptk.many hyper_set_itm;;
    2.88  
    2.89  	// HYPERPRIVOP_SET_RR?
    2.90 -	cmp.eq p7,p6=XEN_HYPER_SET_RR,r17
    2.91 +	cmp.eq p7,p6=HYPERPRIVOP_SET_RR,r17
    2.92  (p7)	br.sptk.many hyper_set_rr;;
    2.93  
    2.94  	// HYPERPRIVOP_GET_RR?
    2.95 -	cmp.eq p7,p6=XEN_HYPER_GET_RR,r17
    2.96 +	cmp.eq p7,p6=HYPERPRIVOP_GET_RR,r17
    2.97  (p7)	br.sptk.many hyper_get_rr;;
    2.98  
    2.99  	// HYPERPRIVOP_PTC_GA?
   2.100 -	cmp.eq p7,p6=XEN_HYPER_PTC_GA,r17
   2.101 +	cmp.eq p7,p6=HYPERPRIVOP_PTC_GA,r17
   2.102  (p7)	br.sptk.many hyper_ptc_ga;;
   2.103  
   2.104  	// HYPERPRIVOP_ITC_D?
   2.105 -	cmp.eq p7,p6=XEN_HYPER_ITC_D,r17
   2.106 +	cmp.eq p7,p6=HYPERPRIVOP_ITC_D,r17
   2.107  (p7)	br.sptk.many hyper_itc_d;;
   2.108  
   2.109  	// HYPERPRIVOP_ITC_I?
   2.110 -	cmp.eq p7,p6=XEN_HYPER_ITC_I,r17
   2.111 +	cmp.eq p7,p6=HYPERPRIVOP_ITC_I,r17
   2.112  (p7)	br.sptk.many hyper_itc_i;;
   2.113  
   2.114  	// HYPERPRIVOP_THASH?
   2.115 -	cmp.eq p7,p6=XEN_HYPER_THASH,r17
   2.116 +	cmp.eq p7,p6=HYPERPRIVOP_THASH,r17
   2.117  (p7)	br.sptk.many hyper_thash;;
   2.118  
   2.119  	// HYPERPRIVOP_SET_KR?
   2.120 -	cmp.eq p7,p6=XEN_HYPER_SET_KR,r17
   2.121 +	cmp.eq p7,p6=HYPERPRIVOP_SET_KR,r17
   2.122  (p7)	br.sptk.many hyper_set_kr;;
   2.123  
   2.124  	// if not one of the above, give up for now and do it the slow way
   2.125 @@ -250,7 +231,7 @@ ENTRY(hyper_ssm_i)
   2.126  	cmp.ne p7,p0=r21,r0
   2.127  (p7)	br.sptk.many dispatch_break_fault ;;
   2.128  #ifdef FAST_HYPERPRIVOP_CNT
   2.129 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_SSM_I);;
   2.130 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_SSM_I);;
   2.131  	ld8 r21=[r20];;
   2.132  	adds r21=1,r21;;
   2.133  	st8 [r20]=r21;;
   2.134 @@ -1066,7 +1047,7 @@ 1:
   2.135  
   2.136  1:	// OK now, let's do an rfi.
   2.137  #ifdef FAST_HYPERPRIVOP_CNT
   2.138 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_RFI);;
   2.139 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_RFI);;
   2.140  	ld8 r23=[r20];;
   2.141  	adds r23=1,r23;;
   2.142  	st8 [r20]=r23;;
   2.143 @@ -1318,7 +1299,7 @@ GLOBAL_ENTRY(rfi_with_interrupt)
   2.144  
   2.145  ENTRY(hyper_cover)
   2.146  #ifdef FAST_HYPERPRIVOP_CNT
   2.147 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_COVER);;
   2.148 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_COVER);;
   2.149  	ld8 r21=[r20];;
   2.150  	adds r21=1,r21;;
   2.151  	st8 [r20]=r21;;
   2.152 @@ -1353,7 +1334,7 @@ ENTRY(hyper_cover)
   2.153  // return from metaphysical mode (meta=1) to virtual mode (meta=0)
   2.154  ENTRY(hyper_ssm_dt)
   2.155  #ifdef FAST_HYPERPRIVOP_CNT
   2.156 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_SSM_DT);;
   2.157 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_SSM_DT);;
   2.158  	ld8 r21=[r20];;
   2.159  	adds r21=1,r21;;
   2.160  	st8 [r20]=r21;;
   2.161 @@ -1389,7 +1370,7 @@ 1:	extr.u r26=r24,41,2 ;;
   2.162  // go to metaphysical mode (meta=1) from virtual mode (meta=0)
   2.163  ENTRY(hyper_rsm_dt)
   2.164  #ifdef FAST_HYPERPRIVOP_CNT
   2.165 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_RSM_DT);;
   2.166 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_RSM_DT);;
   2.167  	ld8 r21=[r20];;
   2.168  	adds r21=1,r21;;
   2.169  	st8 [r20]=r21;;
   2.170 @@ -1425,7 +1406,7 @@ 1:	extr.u r26=r24,41,2 ;;
   2.171  
   2.172  ENTRY(hyper_get_tpr)
   2.173  #ifdef FAST_HYPERPRIVOP_CNT
   2.174 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_GET_TPR);;
   2.175 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_GET_TPR);;
   2.176  	ld8 r21=[r20];;
   2.177  	adds r21=1,r21;;
   2.178  	st8 [r20]=r21;;
   2.179 @@ -1454,7 +1435,7 @@ END(hyper_get_tpr)
   2.180  // (or accidentally missing) delivering an interrupt
   2.181  ENTRY(hyper_set_tpr)
   2.182  #ifdef FAST_HYPERPRIVOP_CNT
   2.183 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_SET_TPR);;
   2.184 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_SET_TPR);;
   2.185  	ld8 r21=[r20];;
   2.186  	adds r21=1,r21;;
   2.187  	st8 [r20]=r21;;
   2.188 @@ -1482,7 +1463,7 @@ END(hyper_set_tpr)
   2.189  
   2.190  ENTRY(hyper_get_ivr)
   2.191  #ifdef FAST_HYPERPRIVOP_CNT
   2.192 -	movl r22=fast_hyperpriv_cnt+(8*XEN_HYPER_GET_IVR);;
   2.193 +	movl r22=fast_hyperpriv_cnt+(8*HYPERPRIVOP_GET_IVR);;
   2.194  	ld8 r21=[r22];;
   2.195  	adds r21=1,r21;;
   2.196  	st8 [r22]=r21;;
   2.197 @@ -1594,7 +1575,7 @@ ENTRY(hyper_eoi)
   2.198  	cmp.ne p7,p0=r20,r0
   2.199  (p7)	br.spnt.many dispatch_break_fault ;;
   2.200  #ifdef FAST_HYPERPRIVOP_CNT
   2.201 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_EOI);;
   2.202 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_EOI);;
   2.203  	ld8 r21=[r20];;
   2.204  	adds r21=1,r21;;
   2.205  	st8 [r20]=r21;;
   2.206 @@ -1658,7 +1639,7 @@ ENTRY(hyper_set_itm)
   2.207  	cmp.ne p7,p0=r20,r0
   2.208  (p7)	br.spnt.many dispatch_break_fault ;;
   2.209  #ifdef FAST_HYPERPRIVOP_CNT
   2.210 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_SET_ITM);;
   2.211 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_SET_ITM);;
   2.212  	ld8 r21=[r20];;
   2.213  	adds r21=1,r21;;
   2.214  	st8 [r20]=r21;;
   2.215 @@ -1699,7 +1680,7 @@ END(hyper_set_itm)
   2.216  
   2.217  ENTRY(hyper_get_rr)
   2.218  #ifdef FAST_HYPERPRIVOP_CNT
   2.219 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_GET_RR);;
   2.220 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_GET_RR);;
   2.221  	ld8 r21=[r20];;
   2.222  	adds r21=1,r21;;
   2.223  	st8 [r20]=r21;;
   2.224 @@ -1731,7 +1712,7 @@ ENTRY(hyper_set_rr)
   2.225  	cmp.leu p7,p0=7,r25	// punt on setting rr7
   2.226  (p7)	br.spnt.many dispatch_break_fault ;;
   2.227  #ifdef FAST_HYPERPRIVOP_CNT
   2.228 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_SET_RR);;
   2.229 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_SET_RR);;
   2.230  	ld8 r21=[r20];;
   2.231  	adds r21=1,r21;;
   2.232  	st8 [r20]=r21;;
   2.233 @@ -1789,7 +1770,7 @@ ENTRY(hyper_set_kr)
   2.234  	cmp.ne p7,p0=r0,r25	// if kr# > 7, go slow way
   2.235  (p7)	br.spnt.many dispatch_break_fault ;;
   2.236  #ifdef FAST_HYPERPRIVOP_CNT
   2.237 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_SET_KR);;
   2.238 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_SET_KR);;
   2.239  	ld8 r21=[r20];;
   2.240  	adds r21=1,r21;;
   2.241  	st8 [r20]=r21;;
   2.242 @@ -1847,7 +1828,7 @@ END(hyper_set_kr)
   2.243  //	r31 == pr
   2.244  GLOBAL_ENTRY(hyper_thash)
   2.245  #ifdef FAST_HYPERPRIVOP_CNT
   2.246 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_THASH);;
   2.247 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_THASH);;
   2.248  	ld8 r21=[r20];;
   2.249  	adds r21=1,r21;;
   2.250  	st8 [r20]=r21;;
   2.251 @@ -1916,7 +1897,7 @@ ENTRY(hyper_ptc_ga)
   2.252  #endif
   2.253  	// FIXME: validate not flushing Xen addresses
   2.254  #ifdef FAST_HYPERPRIVOP_CNT
   2.255 -	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_PTC_GA);;
   2.256 +	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_PTC_GA);;
   2.257  	ld8 r21=[r20];;
   2.258  	adds r21=1,r21;;
   2.259  	st8 [r20]=r21;;
   2.260 @@ -1995,7 +1976,7 @@ ENTRY(recover_and_dispatch_break_fault)
   2.261  	br.sptk.many dispatch_break_fault;;
   2.262  
   2.263  //  Registers at entry
   2.264 -//	r17 = break immediate (XEN_HYPER_ITC_D or I)
   2.265 +//	r17 = break immediate (HYPERPRIVOP_ITC_D or I)
   2.266  //	r18 == XSI_PSR_IC_OFS
   2.267  //	r31 == pr
   2.268  GLOBAL_ENTRY(hyper_itc)
   2.269 @@ -2028,9 +2009,9 @@ ENTRY(hyper_itc_d)
   2.270  	cmp.ne p7,p0=r27,r28
   2.271  (p7)	br.spnt.many dispatch_break_fault ;;
   2.272  #ifdef FAST_HYPERPRIVOP_CNT
   2.273 -	cmp.eq p6,p7=XEN_HYPER_ITC_D,r17;;
   2.274 -(p6)	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_ITC_D);;
   2.275 -(p7)	movl r20=fast_hyperpriv_cnt+(8*XEN_HYPER_ITC_I);;
   2.276 +	cmp.eq p6,p7=HYPERPRIVOP_ITC_D,r17;;
   2.277 +(p6)	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_ITC_D);;
   2.278 +(p7)	movl r20=fast_hyperpriv_cnt+(8*HYPERPRIVOP_ITC_I);;
   2.279  	ld8 r21=[r20];;
   2.280  	adds r21=1,r21;;
   2.281  	st8 [r20]=r21;;
     3.1 --- a/xen/arch/ia64/xen/privop.c	Mon May 08 13:05:47 2006 -0600
     3.2 +++ b/xen/arch/ia64/xen/privop.c	Mon May 08 13:08:37 2006 -0600
     3.3 @@ -794,33 +794,6 @@ priv_emulate(VCPU *vcpu, REGS *regs, UIN
     3.4  	return fault;
     3.5  }
     3.6  
     3.7 -
     3.8 -// FIXME: Move these to include/public/arch-ia64?
     3.9 -#define HYPERPRIVOP_RFI			0x1
    3.10 -#define HYPERPRIVOP_RSM_DT		0x2
    3.11 -#define HYPERPRIVOP_SSM_DT		0x3
    3.12 -#define HYPERPRIVOP_COVER		0x4
    3.13 -#define HYPERPRIVOP_ITC_D		0x5
    3.14 -#define HYPERPRIVOP_ITC_I		0x6
    3.15 -#define HYPERPRIVOP_SSM_I		0x7
    3.16 -#define HYPERPRIVOP_GET_IVR		0x8
    3.17 -#define HYPERPRIVOP_GET_TPR		0x9
    3.18 -#define HYPERPRIVOP_SET_TPR		0xa
    3.19 -#define HYPERPRIVOP_EOI			0xb
    3.20 -#define HYPERPRIVOP_SET_ITM		0xc
    3.21 -#define HYPERPRIVOP_THASH		0xd
    3.22 -#define HYPERPRIVOP_PTC_GA		0xe
    3.23 -#define HYPERPRIVOP_ITR_D		0xf
    3.24 -#define HYPERPRIVOP_GET_RR		0x10
    3.25 -#define HYPERPRIVOP_SET_RR		0x11
    3.26 -#define HYPERPRIVOP_SET_KR		0x12
    3.27 -#define HYPERPRIVOP_FC			0x13
    3.28 -#define HYPERPRIVOP_GET_CPUID		0x14
    3.29 -#define HYPERPRIVOP_GET_PMD		0x15
    3.30 -#define HYPERPRIVOP_GET_EFLAG		0x16
    3.31 -#define HYPERPRIVOP_SET_EFLAG		0x17
    3.32 -#define HYPERPRIVOP_MAX			0x17
    3.33 -
    3.34  static const char * const hyperpriv_str[HYPERPRIVOP_MAX+1] = {
    3.35  	0, "rfi", "rsm.dt", "ssm.dt", "cover", "itc.d", "itc.i", "ssm.i",
    3.36  	"=ivr", "=tpr", "tpr=", "eoi", "itm=", "thash", "ptc.ga", "itr.d",
     4.1 --- a/xen/include/public/arch-ia64.h	Mon May 08 13:05:47 2006 -0600
     4.2 +++ b/xen/include/public/arch-ia64.h	Mon May 08 13:08:37 2006 -0600
     4.3 @@ -363,6 +363,32 @@ DEFINE_GUEST_HANDLE(vcpu_guest_context_t
     4.4  
     4.5  #endif /* !__ASSEMBLY__ */
     4.6  
     4.7 +/* Hyperprivops.  */
     4.8 +#define HYPERPRIVOP_RFI			0x1
     4.9 +#define HYPERPRIVOP_RSM_DT		0x2
    4.10 +#define HYPERPRIVOP_SSM_DT		0x3
    4.11 +#define HYPERPRIVOP_COVER		0x4
    4.12 +#define HYPERPRIVOP_ITC_D		0x5
    4.13 +#define HYPERPRIVOP_ITC_I		0x6
    4.14 +#define HYPERPRIVOP_SSM_I		0x7
    4.15 +#define HYPERPRIVOP_GET_IVR		0x8
    4.16 +#define HYPERPRIVOP_GET_TPR		0x9
    4.17 +#define HYPERPRIVOP_SET_TPR		0xa
    4.18 +#define HYPERPRIVOP_EOI			0xb
    4.19 +#define HYPERPRIVOP_SET_ITM		0xc
    4.20 +#define HYPERPRIVOP_THASH		0xd
    4.21 +#define HYPERPRIVOP_PTC_GA		0xe
    4.22 +#define HYPERPRIVOP_ITR_D		0xf
    4.23 +#define HYPERPRIVOP_GET_RR		0x10
    4.24 +#define HYPERPRIVOP_SET_RR		0x11
    4.25 +#define HYPERPRIVOP_SET_KR		0x12
    4.26 +#define HYPERPRIVOP_FC			0x13
    4.27 +#define HYPERPRIVOP_GET_CPUID		0x14
    4.28 +#define HYPERPRIVOP_GET_PMD		0x15
    4.29 +#define HYPERPRIVOP_GET_EFLAG		0x16
    4.30 +#define HYPERPRIVOP_SET_EFLAG		0x17
    4.31 +#define HYPERPRIVOP_MAX			0x17
    4.32 +
    4.33  #endif /* __HYPERVISOR_IF_IA64_H__ */
    4.34  
    4.35  /*