For upcoming posix-timer changes to avoid include recursion hell.
Unified · Split
| @@ -25,6 +25,7 @@ · 24 unmodified lines | ||
| 25 | 25 | #include <linux/resource.h> |
| 26 | 26 | #include <linux/latencytop.h> |
| 27 | 27 | #include <linux/sched/prio.h> |
| 28 | +#include <linux/sched/types.h> | |
| 28 | 29 | #include <linux/signal_types.h> |
| 29 | 30 | #include <linux/mm_types_task.h> |
| 30 | 31 | #include <linux/task_io_accounting.h> |
| @@ -245,22 +246,6 @@ struct prev_cputime { · 214 unmodified lines | ||
| 245 | 246 | #endif |
| 246 | 247 | }; |
| 247 | 248 | |
| 248 | −/** | |
| 249 | − * struct task_cputime - collected CPU time counts | |
| 250 | − * @utime: time spent in user mode, in nanoseconds | |
| 251 | − * @stime: time spent in kernel mode, in nanoseconds | |
| 252 | − * @sum_exec_runtime: total time spent on the CPU, in nanoseconds | |
| 253 | − * | |
| 254 | − * This structure groups together three kinds of CPU time that are tracked for | |
| 255 | − * threads and thread groups. Most things considering CPU time want to group | |
| 256 | − * these counts together and treat all three of them in parallel. | |
| 257 | − */ | |
| 258 | −struct task_cputime { | |
| 259 | − u64 utime; | |
| 260 | − u64 stime; | |
| 261 | − unsigned long long sum_exec_runtime; | |
| 262 | −}; | |
| 263 | − | |
| 264 | 249 | /* Alternate field names when used on cache expirations: */ |
| 265 | 250 | #define virt_exp utime |
| 266 | 251 | #define prof_exp stime |
| @@ -0,0 +1,23 @@ | ||
| 1 | +/* SPDX-License-Identifier: GPL-2.0 */ | |
| 2 | +#ifndef _LINUX_SCHED_TYPES_H | |
| 3 | +#define _LINUX_SCHED_TYPES_H | |
| 4 | + | |
| 5 | +#include <linux/types.h> | |
| 6 | + | |
| 7 | +/** | |
| 8 | + * struct task_cputime - collected CPU time counts | |
| 9 | + * @utime: time spent in user mode, in nanoseconds | |
| 10 | + * @stime: time spent in kernel mode, in nanoseconds | |
| 11 | + * @sum_exec_runtime: total time spent on the CPU, in nanoseconds | |
| 12 | + * | |
| 13 | + * This structure groups together three kinds of CPU time that are tracked for | |
| 14 | + * threads and thread groups. Most things considering CPU time want to group | |
| 15 | + * these counts together and treat all three of them in parallel. | |
| 16 | + */ | |
| 17 | +struct task_cputime { | |
| 18 | + u64 utime; | |
| 19 | + u64 stime; | |
| 20 | + unsigned long long sum_exec_runtime; | |
| 21 | +}; | |
| 22 | + | |
| 23 | +#endif | |