51a4c29e8359c9e0f3f1ed2eddc2a7105d9dae2b
[ocaml-bitstring.git] / cil-tools / task_struct.c
1 /* This is an example import file, showing how to import the
2  * Linux task_struct structure from header files.
3  *
4  * Use: bitmatch-import-c task_struct.c > task_struct.ml
5  *
6  * Tip: Add the --debug flag to that command line to see what's going on.
7  * Also use bitmatch-objinfo to examine the bmpp file.
8  */
9
10 /* Any defines, etc. necessary to get the include to work. */
11 #define __KERNEL__
12 #define CONFIG_HZ 100
13 #define CONFIG_PAGE_OFFSETUL 0xc0000000 /* XXX? */
14 #define THREAD_SIZE 4096 /* XXX? */
15
16 /* Include files necessary to get the structure(s) and constant(s) we're
17  * interested in.
18  *
19  * Note in this case glibc strips the useful structures out of the
20  * so-called "kernel headers" that it supplies, so instead I have
21  * a local copy of the real headers from a version of Linux.
22  */
23 #include "linux/sched.h"
24
25 /* This tells the importer program what structures and constants to import. */
26 typedef struct task_struct BITMATCH_IMPORT(task_struct);