Frederic Weisbecker | 6ba3c97 | 2012-07-11 20:26:35 +0200 | [diff] [blame] | 1 | #ifndef _ASM_X86_RCU_H |
| 2 | #define _ASM_X86_RCU_H |
| 3 | |
Frederic Weisbecker | 0430499 | 2012-07-11 20:26:38 +0200 | [diff] [blame] | 4 | #ifndef __ASSEMBLY__ |
| 5 | |
Frederic Weisbecker | 6ba3c97 | 2012-07-11 20:26:35 +0200 | [diff] [blame] | 6 | #include <linux/rcupdate.h> |
| 7 | #include <asm/ptrace.h> |
| 8 | |
| 9 | static inline void exception_enter(struct pt_regs *regs) |
| 10 | { |
| 11 | rcu_user_exit(); |
| 12 | } |
| 13 | |
| 14 | static inline void exception_exit(struct pt_regs *regs) |
| 15 | { |
| 16 | #ifdef CONFIG_RCU_USER_QS |
| 17 | if (user_mode(regs)) |
| 18 | rcu_user_enter(); |
| 19 | #endif |
| 20 | } |
| 21 | |
Frederic Weisbecker | 0430499 | 2012-07-11 20:26:38 +0200 | [diff] [blame] | 22 | #else /* __ASSEMBLY__ */ |
| 23 | |
| 24 | #ifdef CONFIG_RCU_USER_QS |
| 25 | # define SCHEDULE_USER call schedule_user |
| 26 | #else |
| 27 | # define SCHEDULE_USER call schedule |
| 28 | #endif |
| 29 | |
| 30 | #endif /* !__ASSEMBLY__ */ |
| 31 | |
Frederic Weisbecker | 6ba3c97 | 2012-07-11 20:26:35 +0200 | [diff] [blame] | 32 | #endif |