Root/
1 | #ifndef _LINUX_USER_RETURN_NOTIFIER_H |
2 | #define _LINUX_USER_RETURN_NOTIFIER_H |
3 | |
4 | #ifdef CONFIG_USER_RETURN_NOTIFIER |
5 | |
6 | #include <linux/list.h> |
7 | #include <linux/sched.h> |
8 | |
9 | struct user_return_notifier { |
10 | void (*on_user_return)(struct user_return_notifier *urn); |
11 | struct hlist_node link; |
12 | }; |
13 | |
14 | |
15 | void user_return_notifier_register(struct user_return_notifier *urn); |
16 | void user_return_notifier_unregister(struct user_return_notifier *urn); |
17 | |
18 | static inline void propagate_user_return_notify(struct task_struct *prev, |
19 | struct task_struct *next) |
20 | { |
21 | if (test_tsk_thread_flag(prev, TIF_USER_RETURN_NOTIFY)) { |
22 | clear_tsk_thread_flag(prev, TIF_USER_RETURN_NOTIFY); |
23 | set_tsk_thread_flag(next, TIF_USER_RETURN_NOTIFY); |
24 | } |
25 | } |
26 | |
27 | void fire_user_return_notifiers(void); |
28 | |
29 | static inline void clear_user_return_notifier(struct task_struct *p) |
30 | { |
31 | clear_tsk_thread_flag(p, TIF_USER_RETURN_NOTIFY); |
32 | } |
33 | |
34 | #else |
35 | |
36 | struct user_return_notifier {}; |
37 | |
38 | static inline void propagate_user_return_notify(struct task_struct *prev, |
39 | struct task_struct *next) |
40 | { |
41 | } |
42 | |
43 | static inline void fire_user_return_notifiers(void) {} |
44 | |
45 | static inline void clear_user_return_notifier(struct task_struct *p) {} |
46 | |
47 | #endif |
48 | |
49 | #endif |
50 |
Branches:
ben-wpan
ben-wpan-stefan
javiroman/ks7010
jz-2.6.34
jz-2.6.34-rc5
jz-2.6.34-rc6
jz-2.6.34-rc7
jz-2.6.35
jz-2.6.36
jz-2.6.37
jz-2.6.38
jz-2.6.39
jz-3.0
jz-3.1
jz-3.11
jz-3.12
jz-3.13
jz-3.15
jz-3.16
jz-3.18-dt
jz-3.2
jz-3.3
jz-3.4
jz-3.5
jz-3.6
jz-3.6-rc2-pwm
jz-3.9
jz-3.9-clk
jz-3.9-rc8
jz47xx
jz47xx-2.6.38
master
Tags:
od-2011-09-04
od-2011-09-18
v2.6.34-rc5
v2.6.34-rc6
v2.6.34-rc7
v3.9