diff options
author | David S. Miller <davem@davemloft.net> | 2008-04-28 03:47:20 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-04-28 03:47:20 -0400 |
commit | 6eda3a75928a3dc1072dfffd228ab818869d83ad (patch) | |
tree | 56e44907f23134273fe383424c69df4d62c6544c /arch/sparc64/kernel/getsetcc.S | |
parent | 194f1a68b93e959ede6ec363db4714e630bdbb6a (diff) |
sparc64: Split entry.S up into seperate files.
entry.S was a hodge-podge of several totally unrelated
sets of assembler routines, ranging from FPU trap handlers
to hypervisor call functions.
Split it up into topic-sized pieces.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64/kernel/getsetcc.S')
-rw-r--r-- | arch/sparc64/kernel/getsetcc.S | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/arch/sparc64/kernel/getsetcc.S b/arch/sparc64/kernel/getsetcc.S new file mode 100644 index 000000000000..a14d272d2061 --- /dev/null +++ b/arch/sparc64/kernel/getsetcc.S | |||
@@ -0,0 +1,24 @@ | |||
1 | .globl getcc | ||
2 | .type getcc,#function | ||
3 | getcc: | ||
4 | ldx [%o0 + PT_V9_TSTATE], %o1 | ||
5 | srlx %o1, 32, %o1 | ||
6 | and %o1, 0xf, %o1 | ||
7 | retl | ||
8 | stx %o1, [%o0 + PT_V9_G1] | ||
9 | .size getcc,.-getcc | ||
10 | |||
11 | .globl setcc | ||
12 | .type setcc,#function | ||
13 | setcc: | ||
14 | ldx [%o0 + PT_V9_TSTATE], %o1 | ||
15 | ldx [%o0 + PT_V9_G1], %o2 | ||
16 | or %g0, %ulo(TSTATE_ICC), %o3 | ||
17 | sllx %o3, 32, %o3 | ||
18 | andn %o1, %o3, %o1 | ||
19 | sllx %o2, 32, %o2 | ||
20 | and %o2, %o3, %o2 | ||
21 | or %o1, %o2, %o1 | ||
22 | retl | ||
23 | stx %o1, [%o0 + PT_V9_TSTATE] | ||
24 | .size setcc,.-setcc | ||