Skip to content

Commit 8750dfe

Browse files
committed
doc: Update NMI-RCU.rst
This commit updates NMI-RCU.rst to highlight the ancient heritage of the example code and to discourage wanton compiler "optimizations". Signed-off-by: Paul E. McKenney <[email protected]>
1 parent 4385001 commit 8750dfe

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Documentation/RCU/NMI-RCU.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Although RCU is usually used to protect read-mostly data structures,
88
it is possible to use RCU to provide dynamic non-maskable interrupt
99
handlers, as well as dynamic irq handlers. This document describes
1010
how to do this, drawing loosely from Zwane Mwaikambo's NMI-timer
11-
work in "arch/x86/kernel/traps.c".
11+
work in an old version of "arch/x86/kernel/traps.c".
1212

1313
The relevant pieces of code are listed below, each followed by a
1414
brief explanation::
@@ -116,7 +116,7 @@ Answer to Quick Quiz:
116116

117117
This same sad story can happen on other CPUs when using
118118
a compiler with aggressive pointer-value speculation
119-
optimizations.
119+
optimizations. (But please don't!)
120120

121121
More important, the rcu_dereference_sched() makes it
122122
clear to someone reading the code that the pointer is

0 commit comments

Comments
 (0)