diff options
Diffstat (limited to 'arch/xtensa/include/asm/system.h')
-rw-r--r-- | arch/xtensa/include/asm/system.h | 33 |
1 files changed, 1 insertions, 32 deletions
diff --git a/arch/xtensa/include/asm/system.h b/arch/xtensa/include/asm/system.h index 62b1e8f3c13c..1e7e09ab6cd7 100644 --- a/arch/xtensa/include/asm/system.h +++ b/arch/xtensa/include/asm/system.h | |||
@@ -12,41 +12,10 @@ | |||
12 | #define _XTENSA_SYSTEM_H | 12 | #define _XTENSA_SYSTEM_H |
13 | 13 | ||
14 | #include <linux/stringify.h> | 14 | #include <linux/stringify.h> |
15 | #include <linux/irqflags.h> | ||
15 | 16 | ||
16 | #include <asm/processor.h> | 17 | #include <asm/processor.h> |
17 | 18 | ||
18 | /* interrupt control */ | ||
19 | |||
20 | #define local_save_flags(x) \ | ||
21 | __asm__ __volatile__ ("rsr %0,"__stringify(PS) : "=a" (x)); | ||
22 | #define local_irq_restore(x) do { \ | ||
23 | __asm__ __volatile__ ("wsr %0, "__stringify(PS)" ; rsync" \ | ||
24 | :: "a" (x) : "memory"); } while(0); | ||
25 | #define local_irq_save(x) do { \ | ||
26 | __asm__ __volatile__ ("rsil %0, "__stringify(LOCKLEVEL) \ | ||
27 | : "=a" (x) :: "memory");} while(0); | ||
28 | |||
29 | static inline void local_irq_disable(void) | ||
30 | { | ||
31 | unsigned long flags; | ||
32 | __asm__ __volatile__ ("rsil %0, "__stringify(LOCKLEVEL) | ||
33 | : "=a" (flags) :: "memory"); | ||
34 | } | ||
35 | static inline void local_irq_enable(void) | ||
36 | { | ||
37 | unsigned long flags; | ||
38 | __asm__ __volatile__ ("rsil %0, 0" : "=a" (flags) :: "memory"); | ||
39 | |||
40 | } | ||
41 | |||
42 | static inline int irqs_disabled(void) | ||
43 | { | ||
44 | unsigned long flags; | ||
45 | local_save_flags(flags); | ||
46 | return flags & 0xf; | ||
47 | } | ||
48 | |||
49 | |||
50 | #define smp_read_barrier_depends() do { } while(0) | 19 | #define smp_read_barrier_depends() do { } while(0) |
51 | #define read_barrier_depends() do { } while(0) | 20 | #define read_barrier_depends() do { } while(0) |
52 | 21 | ||