diff options
author | Linux Build Service Account <lnxbuild@localhost> | 2017-04-06 05:39:40 -0700 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2017-04-06 05:39:40 -0700 |
commit | 41941e18ba1f26affbcd6feeabb9b032989c102b (patch) | |
tree | 832a73d2cd7cbd8d62b2172ddde41c7516934a2b /include/linux/sched.h | |
parent | 4594178f22e3dfd89d1b90e7aae26f6bb7aadfb8 (diff) | |
parent | 4748cf2bdee373fba9cec3f1f7e95928ae21c100 (diff) |
Merge "sched/debug: Make the "Preemption disabled at ..." message more useful"
Diffstat (limited to 'include/linux/sched.h')
-rw-r--r-- | include/linux/sched.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index 95d758d63784..4b56a62a0a58 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -3247,6 +3247,15 @@ static inline void cond_resched_rcu(void) #endif } +static inline unsigned long get_preempt_disable_ip(struct task_struct *p) +{ +#ifdef CONFIG_DEBUG_PREEMPT + return p->preempt_disable_ip; +#else + return 0; +#endif +} + /* * Does a critical section need to be broken due to another * task waiting?: (technically does not depend on CONFIG_PREEMPT, |