ia64/xen-unstable

view linux-2.6-xen-sparse/arch/ia64/xen/xenpal.S @ 9296:f85bb99187bf

Update interface documentation to include sched_op_new hypercall
and clean up the style a bit. Also clean up the sched_op_new
description in the sched.h public header.

Signed-off-by: Keir Fraser <keir@xensource.com>
author kaf24@firebug.cl.cam.ac.uk
date Wed Mar 15 19:19:22 2006 +0100 (2006-03-15)
parents 3b6d422fc0be
children 2b6e531dab38
line source
1 /*
2 * ia64/xen/xenpal.S
3 *
4 * Alternate PAL routines for Xen. Heavily leveraged from
5 * ia64/kernel/pal.S
6 *
7 * Copyright (C) 2005 Hewlett-Packard Co
8 * Dan Magenheimer <dan.magenheimer@.hp.com>
9 */
11 #include <asm/asmmacro.h>
12 #include <asm/processor.h>
14 GLOBAL_ENTRY(xen_pal_call_static)
15 .prologue ASM_UNW_PRLG_RP|ASM_UNW_PRLG_PFS, ASM_UNW_PRLG_GRSAVE(5)
16 alloc loc1 = ar.pfs,5,5,0,0
17 #ifdef CONFIG_XEN
18 movl r22=running_on_xen;;
19 ld4 r22=[r22];;
20 cmp.eq p7,p0=r22,r0
21 (p7) br.cond.spnt.many __ia64_pal_call_static;;
22 #endif
23 movl loc2 = pal_entry_point
24 1: {
25 mov r28 = in0
26 mov r29 = in1
27 mov r8 = ip
28 }
29 ;;
30 ld8 loc2 = [loc2] // loc2 <- entry point
31 tbit.nz p6,p7 = in4, 0
32 adds r8 = 1f-1b,r8
33 mov loc4=ar.rsc // save RSE configuration
34 ;;
35 mov ar.rsc=0 // put RSE in enforced lazy, LE mode
36 mov loc3 = psr
37 mov loc0 = rp
38 .body
39 mov r30 = in2
41 #ifdef CONFIG_XEN
42 // this is low priority for paravirtualization, but is called
43 // from the idle loop so confuses privop counting
44 movl r31=XSI_PSR_IC
45 ;;
46 (p6) st8 [r31]=r0
47 ;;
48 (p7) adds r31=XSI_PSR_I-XSI_PSR_IC,r31
49 ;;
50 (p7) st4 [r31]=r0
51 ;;
52 mov r31 = in3
53 mov b7 = loc2
54 ;;
55 #else
56 (p6) rsm psr.i | psr.ic
57 mov r31 = in3
58 mov b7 = loc2
60 (p7) rsm psr.i
61 ;;
62 (p6) srlz.i
63 #endif
64 mov rp = r8
65 br.cond.sptk.many b7
66 1: mov psr.l = loc3
67 mov ar.rsc = loc4 // restore RSE configuration
68 mov ar.pfs = loc1
69 mov rp = loc0
70 ;;
71 srlz.d // seralize restoration of psr.l
72 br.ret.sptk.many b0
73 END(xen_pal_call_static)