The hardware latency tracer calls into instrumentable functions. Move the calls into the RCU watching sections and annotate them.
Showing the changes to include/linux (1 of 1 file). Show all
Unified · Split
| @@ -87,20 +87,24 @@ extern void rcu_nmi_exit(void); · 86 unmodified lines | |||
| 87 | arch_nmi_enter(); \ | 87 | arch_nmi_enter(); \ |
| 88 | printk_nmi_enter(); \ | 88 | printk_nmi_enter(); \ |
| 89 | lockdep_off(); \ | 89 | lockdep_off(); \ |
| 90 | ftrace_nmi_enter(); \ | ||
| 91 | BUG_ON(in_nmi() == NMI_MASK); \ | 90 | BUG_ON(in_nmi() == NMI_MASK); \ |
| 92 | __preempt_count_add(NMI_OFFSET + HARDIRQ_OFFSET); \ | 91 | __preempt_count_add(NMI_OFFSET + HARDIRQ_OFFSET); \ |
| 93 | rcu_nmi_enter(); \ | 92 | rcu_nmi_enter(); \ |
| 94 | lockdep_hardirq_enter(); \ | 93 | lockdep_hardirq_enter(); \ |
| 94 | instrumentation_begin(); \ | ||
| 95 | ftrace_nmi_enter(); \ | ||
| 96 | instrumentation_end(); \ | ||
| 95 | } while (0) | 97 | } while (0) |
| 96 | 98 | ||
| 97 | #define nmi_exit() \ | 99 | #define nmi_exit() \ |
| 98 | do { \ | 100 | do { \ |
| 101 | instrumentation_begin(); \ | ||
| 102 | ftrace_nmi_exit(); \ | ||
| 103 | instrumentation_end(); \ | ||
| 99 | lockdep_hardirq_exit(); \ | 104 | lockdep_hardirq_exit(); \ |
| 100 | rcu_nmi_exit(); \ | 105 | rcu_nmi_exit(); \ |
| 101 | BUG_ON(!in_nmi()); \ | 106 | BUG_ON(!in_nmi()); \ |
| 102 | __preempt_count_sub(NMI_OFFSET + HARDIRQ_OFFSET); \ | 107 | __preempt_count_sub(NMI_OFFSET + HARDIRQ_OFFSET); \ |
| 103 | ftrace_nmi_exit(); \ | ||
| 104 | lockdep_on(); \ | 108 | lockdep_on(); \ |
| 105 | printk_nmi_exit(); \ | 109 | printk_nmi_exit(); \ |
| 106 | arch_nmi_exit(); \ | 110 | arch_nmi_exit(); \ |