diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-29 10:19:27 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-29 10:19:27 -0800 |
commit | 076d84bbdb396360d16aaa108c55aa1e24ad47a3 (patch) | |
tree | 7ea509f9d6160fafa9ed6bdadeae649e204a8337 /include/linux/hardirq.h | |
parent | d40e705903397445c6861a0a56c23e5b2e8f9b9a (diff) | |
parent | 7be2a03e3174cee3a3cdcdf17db357470f51caff (diff) | |
download | lwn-076d84bbdb396360d16aaa108c55aa1e24ad47a3.tar.gz lwn-076d84bbdb396360d16aaa108c55aa1e24ad47a3.zip |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/mingo/linux-2.6-sched
* git://git.kernel.org/pub/scm/linux/kernel/git/mingo/linux-2.6-sched:
softlockup: fix task state setting
rcu: add support for dynamic ticks and preempt rcu
Diffstat (limited to 'include/linux/hardirq.h')
-rw-r--r-- | include/linux/hardirq.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/hardirq.h b/include/linux/hardirq.h index 2961ec788046..49829988bfa0 100644 --- a/include/linux/hardirq.h +++ b/include/linux/hardirq.h @@ -109,6 +109,14 @@ static inline void account_system_vtime(struct task_struct *tsk) } #endif +#if defined(CONFIG_PREEMPT_RCU) && defined(CONFIG_NO_HZ) +extern void rcu_irq_enter(void); +extern void rcu_irq_exit(void); +#else +# define rcu_irq_enter() do { } while (0) +# define rcu_irq_exit() do { } while (0) +#endif /* CONFIG_PREEMPT_RCU */ + /* * It is safe to do non-atomic ops on ->hardirq_context, * because NMI handlers may not preempt and the ops are @@ -117,6 +125,7 @@ static inline void account_system_vtime(struct task_struct *tsk) */ #define __irq_enter() \ do { \ + rcu_irq_enter(); \ account_system_vtime(current); \ add_preempt_count(HARDIRQ_OFFSET); \ trace_hardirq_enter(); \ @@ -135,6 +144,7 @@ extern void irq_enter(void); trace_hardirq_exit(); \ account_system_vtime(current); \ sub_preempt_count(HARDIRQ_OFFSET); \ + rcu_irq_exit(); \ } while (0) /* |