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 /include/asm-mips/asmmacro.h |
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 'include/asm-mips/asmmacro.h')
-rw-r--r-- | include/asm-mips/asmmacro.h | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/include/asm-mips/asmmacro.h b/include/asm-mips/asmmacro.h new file mode 100644 index 000000000000..37a460aa0378 --- /dev/null +++ b/include/asm-mips/asmmacro.h | |||
@@ -0,0 +1,51 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 2003 Ralf Baechle | ||
7 | */ | ||
8 | #ifndef _ASM_ASMMACRO_H | ||
9 | #define _ASM_ASMMACRO_H | ||
10 | |||
11 | #include <linux/config.h> | ||
12 | #include <asm/hazards.h> | ||
13 | |||
14 | #ifdef CONFIG_MIPS32 | ||
15 | #include <asm/asmmacro-32.h> | ||
16 | #endif | ||
17 | #ifdef CONFIG_MIPS64 | ||
18 | #include <asm/asmmacro-64.h> | ||
19 | #endif | ||
20 | |||
21 | .macro local_irq_enable reg=t0 | ||
22 | mfc0 \reg, CP0_STATUS | ||
23 | ori \reg, \reg, 1 | ||
24 | mtc0 \reg, CP0_STATUS | ||
25 | irq_enable_hazard | ||
26 | .endm | ||
27 | |||
28 | .macro local_irq_disable reg=t0 | ||
29 | mfc0 \reg, CP0_STATUS | ||
30 | ori \reg, \reg, 1 | ||
31 | xori \reg, \reg, 1 | ||
32 | mtc0 \reg, CP0_STATUS | ||
33 | irq_disable_hazard | ||
34 | .endm | ||
35 | |||
36 | #ifdef CONFIG_CPU_SB1 | ||
37 | .macro fpu_enable_hazard | ||
38 | .set push | ||
39 | .set noreorder | ||
40 | .set mips2 | ||
41 | SSNOP | ||
42 | bnezl $0, .+4 | ||
43 | SSNOP | ||
44 | .set pop | ||
45 | .endm | ||
46 | #else | ||
47 | .macro fpu_enable_hazard | ||
48 | .endm | ||
49 | #endif | ||
50 | |||
51 | #endif /* _ASM_ASMMACRO_H */ | ||