]>
Commit | Line | Data |
---|---|---|
5c9a8750 DV |
1 | #ifndef _LINUX_KCOV_H |
2 | #define _LINUX_KCOV_H | |
3 | ||
4 | #include <uapi/linux/kcov.h> | |
5 | ||
6 | struct task_struct; | |
7 | ||
8 | #ifdef CONFIG_KCOV | |
9 | ||
10 | void kcov_task_init(struct task_struct *t); | |
11 | void kcov_task_exit(struct task_struct *t); | |
12 | ||
13 | enum kcov_mode { | |
14 | /* Coverage collection is not enabled yet. */ | |
15 | KCOV_MODE_DISABLED = 0, | |
16 | /* | |
17 | * Tracing coverage collection mode. | |
18 | * Covered PCs are collected in a per-task buffer. | |
19 | */ | |
20 | KCOV_MODE_TRACE = 1, | |
21 | }; | |
22 | ||
23 | #else | |
24 | ||
25 | static inline void kcov_task_init(struct task_struct *t) {} | |
26 | static inline void kcov_task_exit(struct task_struct *t) {} | |
27 | ||
28 | #endif /* CONFIG_KCOV */ | |
29 | #endif /* _LINUX_KCOV_H */ |