Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
asm-offsets.c
Go to the documentation of this file.
1 /*
2  * Generate definitions needed by assembly language modules.
3  * This code generates raw asm output which is post-processed
4  * to extract and format the required data.
5  */
6 
7 #include <linux/mm.h>
8 #include <linux/sched.h>
9 #include <linux/thread_info.h>
10 #include <linux/kbuild.h>
11 
12 void foo(void)
13 {
15  OFFSET(TI_exec_domain, thread_info, exec_domain);
17  OFFSET(TI_cpu, thread_info, cpu);
19  OFFSET(TI_rar_saved, thread_info, rar_saved);
20  OFFSET(TI_rsr_saved, thread_info, rsr_saved);
21  OFFSET(TI_restart_block, thread_info, restart_block);
22  BLANK();
23  OFFSET(TSK_active_mm, task_struct, active_mm);
24  BLANK();
25  OFFSET(MM_pgd, mm_struct, pgd);
26 }