Merge branch 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
[linux-2.6-block.git] / include / linux / sched.h
index 8e43e54a02c732bde8f2f1d7c9e42fb81a8dba86..2c2e56bd8913250e88982ee8e47e36b23081fe23 100644 (file)
 #include <linux/resource.h>
 #include <linux/latencytop.h>
 #include <linux/sched/prio.h>
+#include <linux/sched/types.h>
 #include <linux/signal_types.h>
 #include <linux/mm_types_task.h>
 #include <linux/task_io_accounting.h>
+#include <linux/posix-timers.h>
 #include <linux/rseq.h>
 
 /* task_struct member predeclarations (sorted alphabetically): */
@@ -244,27 +246,6 @@ struct prev_cputime {
 #endif
 };
 
-/**
- * struct task_cputime - collected CPU time counts
- * @utime:             time spent in user mode, in nanoseconds
- * @stime:             time spent in kernel mode, in nanoseconds
- * @sum_exec_runtime:  total time spent on the CPU, in nanoseconds
- *
- * This structure groups together three kinds of CPU time that are tracked for
- * threads and thread groups.  Most things considering CPU time want to group
- * these counts together and treat all three of them in parallel.
- */
-struct task_cputime {
-       u64                             utime;
-       u64                             stime;
-       unsigned long long              sum_exec_runtime;
-};
-
-/* Alternate field names when used on cache expirations: */
-#define virt_exp                       utime
-#define prof_exp                       stime
-#define sched_exp                      sum_exec_runtime
-
 enum vtime_state {
        /* Task is sleeping or running in a CPU with VTIME inactive: */
        VTIME_INACTIVE = 0,
@@ -881,10 +862,8 @@ struct task_struct {
        unsigned long                   min_flt;
        unsigned long                   maj_flt;
 
-#ifdef CONFIG_POSIX_TIMERS
-       struct task_cputime             cputime_expires;
-       struct list_head                cpu_timers[3];
-#endif
+       /* Empty if CONFIG_POSIX_CPUTIMERS=n */
+       struct posix_cputimers          posix_cputimers;
 
        /* Process credentials: */
 
@@ -979,6 +958,10 @@ struct task_struct {
        struct mutex_waiter             *blocked_on;
 #endif
 
+#ifdef CONFIG_DEBUG_ATOMIC_SLEEP
+       int                             non_block_count;
+#endif
+
 #ifdef CONFIG_TRACE_IRQFLAGS
        unsigned int                    irq_events;
        unsigned long                   hardirq_enable_ip;