aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/lockstat.txt1
-rw-r--r--include/asm-um/system-generic.h32
-rw-r--r--include/linux/irqflags.h18
3 files changed, 25 insertions, 26 deletions
diff --git a/Documentation/lockstat.txt b/Documentation/lockstat.txt
index 4ba4664ce5c3..02f36f5c64fe 100644
--- a/Documentation/lockstat.txt
+++ b/Documentation/lockstat.txt
@@ -100,6 +100,7 @@ The first lock (05-10) is a read/write lock, and shows two lines above the
100short separator. The contention points don't match the column descriptors, 100short separator. The contention points don't match the column descriptors,
101they have two: contentions and [<IP>] symbol. 101they have two: contentions and [<IP>] symbol.
102 102
103The integer part of the time values is in us.
103 104
104View the top contending locks: 105View the top contending locks:
105 106
diff --git a/include/asm-um/system-generic.h b/include/asm-um/system-generic.h
index 5bcfa35e7a22..f1ea4da34fad 100644
--- a/include/asm-um/system-generic.h
+++ b/include/asm-um/system-generic.h
@@ -4,15 +4,15 @@
4#include "asm/arch/system.h" 4#include "asm/arch/system.h"
5 5
6#undef switch_to 6#undef switch_to
7#undef local_irq_save 7#undef raw_local_irq_save
8#undef local_irq_restore 8#undef raw_local_irq_restore
9#undef local_irq_disable 9#undef raw_local_irq_disable
10#undef local_irq_enable 10#undef raw_local_irq_enable
11#undef local_save_flags 11#undef raw_local_save_flags
12#undef local_irq_restore 12#undef raw_local_irq_restore
13#undef local_irq_enable 13#undef raw_local_irq_enable
14#undef local_irq_disable 14#undef raw_local_irq_disable
15#undef local_irq_save 15#undef raw_local_irq_save
16#undef irqs_disabled 16#undef irqs_disabled
17 17
18extern void *switch_to(void *prev, void *next, void *last); 18extern void *switch_to(void *prev, void *next, void *last);
@@ -23,21 +23,21 @@ extern int get_signals(void);
23extern void block_signals(void); 23extern void block_signals(void);
24extern void unblock_signals(void); 24extern void unblock_signals(void);
25 25
26#define local_save_flags(flags) do { typecheck(unsigned long, flags); \ 26#define raw_local_save_flags(flags) do { typecheck(unsigned long, flags); \
27 (flags) = get_signals(); } while(0) 27 (flags) = get_signals(); } while(0)
28#define local_irq_restore(flags) do { typecheck(unsigned long, flags); \ 28#define raw_local_irq_restore(flags) do { typecheck(unsigned long, flags); \
29 set_signals(flags); } while(0) 29 set_signals(flags); } while(0)
30 30
31#define local_irq_save(flags) do { local_save_flags(flags); \ 31#define raw_local_irq_save(flags) do { raw_local_save_flags(flags); \
32 local_irq_disable(); } while(0) 32 raw_local_irq_disable(); } while(0)
33 33
34#define local_irq_enable() unblock_signals() 34#define raw_local_irq_enable() unblock_signals()
35#define local_irq_disable() block_signals() 35#define raw_local_irq_disable() block_signals()
36 36
37#define irqs_disabled() \ 37#define irqs_disabled() \
38({ \ 38({ \
39 unsigned long flags; \ 39 unsigned long flags; \
40 local_save_flags(flags); \ 40 raw_local_save_flags(flags); \
41 (flags == 0); \ 41 (flags == 0); \
42}) 42})
43 43
diff --git a/include/linux/irqflags.h b/include/linux/irqflags.h
index 74bde13224c9..f2993512b3b5 100644
--- a/include/linux/irqflags.h
+++ b/include/linux/irqflags.h
@@ -52,10 +52,10 @@
52# define start_critical_timings() do { } while (0) 52# define start_critical_timings() do { } while (0)
53#endif 53#endif
54 54
55#ifdef CONFIG_TRACE_IRQFLAGS_SUPPORT
56
57#include <asm/irqflags.h> 55#include <asm/irqflags.h>
58 56
57#ifdef CONFIG_TRACE_IRQFLAGS_SUPPORT
58
59#define local_irq_enable() \ 59#define local_irq_enable() \
60 do { trace_hardirqs_on(); raw_local_irq_enable(); } while (0) 60 do { trace_hardirqs_on(); raw_local_irq_enable(); } while (0)
61#define local_irq_disable() \ 61#define local_irq_disable() \
@@ -84,21 +84,20 @@
84 * The local_irq_*() APIs are equal to the raw_local_irq*() 84 * The local_irq_*() APIs are equal to the raw_local_irq*()
85 * if !TRACE_IRQFLAGS. 85 * if !TRACE_IRQFLAGS.
86 */ 86 */
87# define raw_local_irq_disable() local_irq_disable() 87#define local_irq_disable() raw_local_irq_disable()
88# define raw_local_irq_enable() local_irq_enable() 88#define local_irq_enable() raw_local_irq_enable()
89# define raw_local_irq_save(flags) \ 89#define local_irq_save(flags) \
90 do { \ 90 do { \
91 typecheck(unsigned long, flags); \ 91 typecheck(unsigned long, flags); \
92 local_irq_save(flags); \ 92 raw_local_irq_save(flags); \
93 } while (0) 93 } while (0)
94# define raw_local_irq_restore(flags) \ 94# define local_irq_restore(flags) \
95 do { \ 95 do { \
96 typecheck(unsigned long, flags); \ 96 typecheck(unsigned long, flags); \
97 local_irq_restore(flags); \ 97 raw_local_irq_restore(flags); \
98 } while (0) 98 } while (0)
99#endif /* CONFIG_TRACE_IRQFLAGS_SUPPORT */ 99#endif /* CONFIG_TRACE_IRQFLAGS_SUPPORT */
100 100
101#ifdef CONFIG_TRACE_IRQFLAGS_SUPPORT
102#define safe_halt() \ 101#define safe_halt() \
103 do { \ 102 do { \
104 trace_hardirqs_on(); \ 103 trace_hardirqs_on(); \
@@ -124,6 +123,5 @@
124 typecheck(unsigned long, flags); \ 123 typecheck(unsigned long, flags); \
125 raw_irqs_disabled_flags(flags); \ 124 raw_irqs_disabled_flags(flags); \
126}) 125})
127#endif /* CONFIG_X86 */
128 126
129#endif 127#endif