History

watchdog: Mark watchdog touch functions as notrace

Some architectures need to use stop_machine() to patch functions for ftrace, and the assumption is that the stopped CPUs do not make function calls to traceable functions when they are in the stopped state. Commit ce4f06dcbb5d ("stop_machine: Touch_nmi_watchdog() after MULTI_STOP_PREPARE") added calls to the watchdog touch functions from the stopped CPUs and those functions lack notrace annotations. This leads to crashes when enabling/disabling ftrace on ARM kernels built with the Thumb-2 instruction set. Fix it by adding the necessary notrace annotations.

Vincent Whitchurch committed 8 years ago

Commit cb9d7fd1 parent 5b394b23 files · +4 −4Browse files

Showing the changes to kernel/workqueue.c (1 of 3 files). Show all

Unified · Split

kernel/workqueue.c+1−1
@@ -5574,7 +5574,7 @@ static void wq_watchdog_timer_fn(struct timer_list *unused) · 5573 unmodified lines
5574 mod_timer(&wq_watchdog_timer, jiffies + thresh);5574 mod_timer(&wq_watchdog_timer, jiffies + thresh);
5575}5575}
5576 5576
5577void wq_watchdog_touch(int cpu)5577notrace void wq_watchdog_touch(int cpu)
5578{5578{
5579 if (cpu >= 0)5579 if (cpu >= 0)
5580 per_cpu(wq_watchdog_touched_cpu, cpu) = jiffies;5580 per_cpu(wq_watchdog_touched_cpu, cpu) = jiffies;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t