sched/rt: Add Kconfig option to enable panicking for RT throttling
This may be useful for detecting and debugging RT throttling issues. Change-Id: I5807a897d11997d76421c1fcaa2918aad988c6c9 Signed-off-by: Matt Wagantall <mattw@codeaurora.org> [rameezmustafa@codeaurora.org]: Port to msm-3.18] Signed-off-by: Syed Rameez Mustafa <rameezmustafa@codeaurora.org> [jstultz: forwardported to 4.4] Signed-off-by: John Stultz <john.stultz@linaro.org>
This commit is contained in:
parent
6bd4858471
commit
6c6dc1632a
2 changed files with 18 additions and 0 deletions
|
@ -924,7 +924,16 @@ static void dump_throttled_rt_tasks(struct rt_rq *rt_rq)
|
||||||
idx = find_next_bit(array->bitmap, MAX_RT_PRIO, idx + 1);
|
idx = find_next_bit(array->bitmap, MAX_RT_PRIO, idx + 1);
|
||||||
}
|
}
|
||||||
out:
|
out:
|
||||||
|
#ifdef CONFIG_PANIC_ON_RT_THROTTLING
|
||||||
|
/*
|
||||||
|
* Use pr_err() in the BUG() case since printk_sched() will
|
||||||
|
* not get flushed and deadlock is not a concern.
|
||||||
|
*/
|
||||||
|
pr_err("%s", buf);
|
||||||
|
BUG();
|
||||||
|
#else
|
||||||
printk_deferred("%s", buf);
|
printk_deferred("%s", buf);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
static int sched_rt_runtime_exceeded(struct rt_rq *rt_rq)
|
static int sched_rt_runtime_exceeded(struct rt_rq *rt_rq)
|
||||||
|
|
|
@ -867,6 +867,15 @@ config SCHED_INFO
|
||||||
bool
|
bool
|
||||||
default n
|
default n
|
||||||
|
|
||||||
|
config PANIC_ON_RT_THROTTLING
|
||||||
|
bool "Panic on RT throttling"
|
||||||
|
help
|
||||||
|
Say Y here to enable the kernel to panic when a realtime
|
||||||
|
runqueue is throttled. This may be useful for detecting
|
||||||
|
and debugging RT throttling issues.
|
||||||
|
|
||||||
|
Say N if unsure.
|
||||||
|
|
||||||
config SCHEDSTATS
|
config SCHEDSTATS
|
||||||
bool "Collect scheduler statistics"
|
bool "Collect scheduler statistics"
|
||||||
depends on DEBUG_KERNEL && PROC_FS
|
depends on DEBUG_KERNEL && PROC_FS
|
||||||
|
|
Loading…
Add table
Reference in a new issue