diff options
Diffstat (limited to 'include/asm-sparc64/head.h')
-rw-r--r-- | include/asm-sparc64/head.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/include/asm-sparc64/head.h b/include/asm-sparc64/head.h index 0abd3a674e8f..67960a751f4d 100644 --- a/include/asm-sparc64/head.h +++ b/include/asm-sparc64/head.h | |||
@@ -4,12 +4,21 @@ | |||
4 | 4 | ||
5 | #include <asm/pstate.h> | 5 | #include <asm/pstate.h> |
6 | 6 | ||
7 | /* wrpr %g0, val, %gl */ | ||
8 | #define SET_GL(val) \ | ||
9 | .word 0xa1902000 | val | ||
10 | |||
11 | /* rdpr %gl, %gN */ | ||
12 | #define GET_GL_GLOBAL(N) \ | ||
13 | .word 0x81540000 | (N << 25) | ||
14 | |||
7 | #define KERNBASE 0x400000 | 15 | #define KERNBASE 0x400000 |
8 | 16 | ||
9 | #define PTREGS_OFF (STACK_BIAS + STACKFRAME_SZ) | 17 | #define PTREGS_OFF (STACK_BIAS + STACKFRAME_SZ) |
10 | 18 | ||
11 | #define __CHEETAH_ID 0x003e0014 | 19 | #define __CHEETAH_ID 0x003e0014 |
12 | #define __JALAPENO_ID 0x003e0016 | 20 | #define __JALAPENO_ID 0x003e0016 |
21 | #define __SERRANO_ID 0x003e0022 | ||
13 | 22 | ||
14 | #define CHEETAH_MANUF 0x003e | 23 | #define CHEETAH_MANUF 0x003e |
15 | #define CHEETAH_IMPL 0x0014 /* Ultra-III */ | 24 | #define CHEETAH_IMPL 0x0014 /* Ultra-III */ |
@@ -19,6 +28,12 @@ | |||
19 | #define PANTHER_IMPL 0x0019 /* Ultra-IV+ */ | 28 | #define PANTHER_IMPL 0x0019 /* Ultra-IV+ */ |
20 | #define SERRANO_IMPL 0x0022 /* Ultra-IIIi+ */ | 29 | #define SERRANO_IMPL 0x0022 /* Ultra-IIIi+ */ |
21 | 30 | ||
31 | #define BRANCH_IF_SUN4V(tmp1,label) \ | ||
32 | sethi %hi(is_sun4v), %tmp1; \ | ||
33 | lduw [%tmp1 + %lo(is_sun4v)], %tmp1; \ | ||
34 | brnz,pn %tmp1, label; \ | ||
35 | nop | ||
36 | |||
22 | #define BRANCH_IF_CHEETAH_BASE(tmp1,tmp2,label) \ | 37 | #define BRANCH_IF_CHEETAH_BASE(tmp1,tmp2,label) \ |
23 | rdpr %ver, %tmp1; \ | 38 | rdpr %ver, %tmp1; \ |
24 | sethi %hi(__CHEETAH_ID), %tmp2; \ | 39 | sethi %hi(__CHEETAH_ID), %tmp2; \ |