diff options
Diffstat (limited to 'include/linux/sched.h')
-rw-r--r-- | include/linux/sched.h | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index 1e2a6db2d7dd..c9ac4fc837ba 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -38,6 +38,7 @@ | |||
38 | #define SCHED_BATCH 3 | 38 | #define SCHED_BATCH 3 |
39 | /* SCHED_ISO: reserved but not implemented yet */ | 39 | /* SCHED_ISO: reserved but not implemented yet */ |
40 | #define SCHED_IDLE 5 | 40 | #define SCHED_IDLE 5 |
41 | #define SCHED_LITMUS 6 | ||
41 | /* Can be ORed in to make sure the process is reverted back to SCHED_NORMAL on fork */ | 42 | /* Can be ORed in to make sure the process is reverted back to SCHED_NORMAL on fork */ |
42 | #define SCHED_RESET_ON_FORK 0x40000000 | 43 | #define SCHED_RESET_ON_FORK 0x40000000 |
43 | 44 | ||
@@ -94,6 +95,9 @@ struct sched_param { | |||
94 | 95 | ||
95 | #include <asm/processor.h> | 96 | #include <asm/processor.h> |
96 | 97 | ||
98 | #include <litmus/rt_param.h> | ||
99 | #include <litmus/preempt.h> | ||
100 | |||
97 | struct exec_domain; | 101 | struct exec_domain; |
98 | struct futex_pi_state; | 102 | struct futex_pi_state; |
99 | struct robust_list_head; | 103 | struct robust_list_head; |
@@ -1159,6 +1163,7 @@ struct sched_rt_entity { | |||
1159 | }; | 1163 | }; |
1160 | 1164 | ||
1161 | struct rcu_node; | 1165 | struct rcu_node; |
1166 | struct od_table_entry; | ||
1162 | 1167 | ||
1163 | struct task_struct { | 1168 | struct task_struct { |
1164 | volatile long state; /* -1 unrunnable, 0 runnable, >0 stopped */ | 1169 | volatile long state; /* -1 unrunnable, 0 runnable, >0 stopped */ |
@@ -1243,9 +1248,9 @@ struct task_struct { | |||
1243 | unsigned long stack_canary; | 1248 | unsigned long stack_canary; |
1244 | #endif | 1249 | #endif |
1245 | 1250 | ||
1246 | /* | 1251 | /* |
1247 | * pointers to (original) parent process, youngest child, younger sibling, | 1252 | * pointers to (original) parent process, youngest child, younger sibling, |
1248 | * older sibling, respectively. (p->father can be replaced with | 1253 | * older sibling, respectively. (p->father can be replaced with |
1249 | * p->real_parent->pid) | 1254 | * p->real_parent->pid) |
1250 | */ | 1255 | */ |
1251 | struct task_struct *real_parent; /* real parent process */ | 1256 | struct task_struct *real_parent; /* real parent process */ |
@@ -1453,6 +1458,13 @@ struct task_struct { | |||
1453 | int make_it_fail; | 1458 | int make_it_fail; |
1454 | #endif | 1459 | #endif |
1455 | struct prop_local_single dirties; | 1460 | struct prop_local_single dirties; |
1461 | |||
1462 | /* LITMUS RT parameters and state */ | ||
1463 | struct rt_param rt_param; | ||
1464 | |||
1465 | /* references to PI semaphores, etc. */ | ||
1466 | struct od_table_entry *od_table; | ||
1467 | |||
1456 | #ifdef CONFIG_LATENCYTOP | 1468 | #ifdef CONFIG_LATENCYTOP |
1457 | int latency_record_count; | 1469 | int latency_record_count; |
1458 | struct latency_record latency_record[LT_SAVECOUNT]; | 1470 | struct latency_record latency_record[LT_SAVECOUNT]; |
@@ -2014,7 +2026,7 @@ static inline int dequeue_signal_lock(struct task_struct *tsk, sigset_t *mask, s | |||
2014 | spin_unlock_irqrestore(&tsk->sighand->siglock, flags); | 2026 | spin_unlock_irqrestore(&tsk->sighand->siglock, flags); |
2015 | 2027 | ||
2016 | return ret; | 2028 | return ret; |
2017 | } | 2029 | } |
2018 | 2030 | ||
2019 | extern void block_all_signals(int (*notifier)(void *priv), void *priv, | 2031 | extern void block_all_signals(int (*notifier)(void *priv), void *priv, |
2020 | sigset_t *mask); | 2032 | sigset_t *mask); |
@@ -2290,6 +2302,7 @@ static inline int test_tsk_thread_flag(struct task_struct *tsk, int flag) | |||
2290 | static inline void set_tsk_need_resched(struct task_struct *tsk) | 2302 | static inline void set_tsk_need_resched(struct task_struct *tsk) |
2291 | { | 2303 | { |
2292 | set_tsk_thread_flag(tsk,TIF_NEED_RESCHED); | 2304 | set_tsk_thread_flag(tsk,TIF_NEED_RESCHED); |
2305 | sched_state_will_schedule(tsk); | ||
2293 | } | 2306 | } |
2294 | 2307 | ||
2295 | static inline void clear_tsk_need_resched(struct task_struct *tsk) | 2308 | static inline void clear_tsk_need_resched(struct task_struct *tsk) |