diff options
| -rw-r--r-- | include/linux/compiler.h | 4 | ||||
| -rw-r--r-- | kernel/rcupreempt.c | 8 |
2 files changed, 3 insertions, 9 deletions
diff --git a/include/linux/compiler.h b/include/linux/compiler.h index c8bd2daf95ec..8322141ee480 100644 --- a/include/linux/compiler.h +++ b/include/linux/compiler.h | |||
| @@ -190,7 +190,9 @@ extern void __chk_io_ptr(const volatile void __iomem *); | |||
| 190 | * ACCESS_ONCE() in different C statements. | 190 | * ACCESS_ONCE() in different C statements. |
| 191 | * | 191 | * |
| 192 | * This macro does absolutely -nothing- to prevent the CPU from reordering, | 192 | * This macro does absolutely -nothing- to prevent the CPU from reordering, |
| 193 | * merging, or refetching absolutely anything at any time. | 193 | * merging, or refetching absolutely anything at any time. Its main intended |
| 194 | * use is to mediate communication between process-level code and irq/NMI | ||
| 195 | * handlers, all running on the same CPU. | ||
| 194 | */ | 196 | */ |
| 195 | #define ACCESS_ONCE(x) (*(volatile typeof(x) *)&(x)) | 197 | #define ACCESS_ONCE(x) (*(volatile typeof(x) *)&(x)) |
| 196 | 198 | ||
diff --git a/kernel/rcupreempt.c b/kernel/rcupreempt.c index 27827931ca0d..ca4bbbe04aa4 100644 --- a/kernel/rcupreempt.c +++ b/kernel/rcupreempt.c | |||
| @@ -59,14 +59,6 @@ | |||
| 59 | #include <linux/rcupreempt_trace.h> | 59 | #include <linux/rcupreempt_trace.h> |
| 60 | 60 | ||
| 61 | /* | 61 | /* |
| 62 | * Macro that prevents the compiler from reordering accesses, but does | ||
| 63 | * absolutely -nothing- to prevent CPUs from reordering. This is used | ||
| 64 | * only to mediate communication between mainline code and hardware | ||
| 65 | * interrupt and NMI handlers. | ||
| 66 | */ | ||
| 67 | #define ACCESS_ONCE(x) (*(volatile typeof(x) *)&(x)) | ||
| 68 | |||
| 69 | /* | ||
| 70 | * PREEMPT_RCU data structures. | 62 | * PREEMPT_RCU data structures. |
| 71 | */ | 63 | */ |
| 72 | 64 | ||
