diff options
author | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-04-16 18:20:36 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-04-16 18:20:36 -0400 |
commit | 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 (patch) | |
tree | 0bba044c4ce775e45a88a51686b5d9f90697ea9d /arch/alpha/lib/dbg_stackkill.S |
Linux-2.6.12-rc2v2.6.12-rc2
Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.
Let it rip!
Diffstat (limited to 'arch/alpha/lib/dbg_stackkill.S')
-rw-r--r-- | arch/alpha/lib/dbg_stackkill.S | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/arch/alpha/lib/dbg_stackkill.S b/arch/alpha/lib/dbg_stackkill.S new file mode 100644 index 000000000000..e09f2ae1e09e --- /dev/null +++ b/arch/alpha/lib/dbg_stackkill.S | |||
@@ -0,0 +1,35 @@ | |||
1 | /* | ||
2 | * arch/alpha/lib/killstack.S | ||
3 | * Contributed by Richard Henderson (rth@cygnus.com) | ||
4 | * | ||
5 | * Clobber the balance of the kernel stack, hoping to catch | ||
6 | * uninitialized local variables in the act. | ||
7 | */ | ||
8 | |||
9 | #include <asm/asm_offsets.h> | ||
10 | |||
11 | .text | ||
12 | .set noat | ||
13 | |||
14 | .align 5 | ||
15 | .globl _mcount | ||
16 | .ent _mcount | ||
17 | _mcount: | ||
18 | .frame $30, 0, $28, 0 | ||
19 | .prologue 0 | ||
20 | |||
21 | ldi $0, 0xdeadbeef | ||
22 | lda $2, -STACK_SIZE | ||
23 | sll $0, 32, $1 | ||
24 | and $30, $2, $2 | ||
25 | or $0, $1, $0 | ||
26 | lda $2, TASK_SIZE($2) | ||
27 | cmpult $2, $30, $1 | ||
28 | beq $1, 2f | ||
29 | 1: stq $0, 0($2) | ||
30 | addq $2, 8, $2 | ||
31 | cmpult $2, $30, $1 | ||
32 | bne $1, 1b | ||
33 | 2: ret ($28) | ||
34 | |||
35 | .end _mcount | ||