diff options
Diffstat (limited to 'arch/i386/kernel/asm-offsets.c')
-rw-r--r-- | arch/i386/kernel/asm-offsets.c | 39 |
1 files changed, 38 insertions, 1 deletions
diff --git a/arch/i386/kernel/asm-offsets.c b/arch/i386/kernel/asm-offsets.c index c80271f8f084..1b2f3cd33270 100644 --- a/arch/i386/kernel/asm-offsets.c +++ b/arch/i386/kernel/asm-offsets.c | |||
@@ -15,6 +15,7 @@ | |||
15 | #include <asm/processor.h> | 15 | #include <asm/processor.h> |
16 | #include <asm/thread_info.h> | 16 | #include <asm/thread_info.h> |
17 | #include <asm/elf.h> | 17 | #include <asm/elf.h> |
18 | #include <asm/pda.h> | ||
18 | 19 | ||
19 | #define DEFINE(sym, val) \ | 20 | #define DEFINE(sym, val) \ |
20 | asm volatile("\n->" #sym " %0 " #val : : "i" (val)) | 21 | asm volatile("\n->" #sym " %0 " #val : : "i" (val)) |
@@ -51,13 +52,35 @@ void foo(void) | |||
51 | OFFSET(TI_exec_domain, thread_info, exec_domain); | 52 | OFFSET(TI_exec_domain, thread_info, exec_domain); |
52 | OFFSET(TI_flags, thread_info, flags); | 53 | OFFSET(TI_flags, thread_info, flags); |
53 | OFFSET(TI_status, thread_info, status); | 54 | OFFSET(TI_status, thread_info, status); |
54 | OFFSET(TI_cpu, thread_info, cpu); | ||
55 | OFFSET(TI_preempt_count, thread_info, preempt_count); | 55 | OFFSET(TI_preempt_count, thread_info, preempt_count); |
56 | OFFSET(TI_addr_limit, thread_info, addr_limit); | 56 | OFFSET(TI_addr_limit, thread_info, addr_limit); |
57 | OFFSET(TI_restart_block, thread_info, restart_block); | 57 | OFFSET(TI_restart_block, thread_info, restart_block); |
58 | OFFSET(TI_sysenter_return, thread_info, sysenter_return); | 58 | OFFSET(TI_sysenter_return, thread_info, sysenter_return); |
59 | BLANK(); | 59 | BLANK(); |
60 | 60 | ||
61 | OFFSET(GDS_size, Xgt_desc_struct, size); | ||
62 | OFFSET(GDS_address, Xgt_desc_struct, address); | ||
63 | OFFSET(GDS_pad, Xgt_desc_struct, pad); | ||
64 | BLANK(); | ||
65 | |||
66 | OFFSET(PT_EBX, pt_regs, ebx); | ||
67 | OFFSET(PT_ECX, pt_regs, ecx); | ||
68 | OFFSET(PT_EDX, pt_regs, edx); | ||
69 | OFFSET(PT_ESI, pt_regs, esi); | ||
70 | OFFSET(PT_EDI, pt_regs, edi); | ||
71 | OFFSET(PT_EBP, pt_regs, ebp); | ||
72 | OFFSET(PT_EAX, pt_regs, eax); | ||
73 | OFFSET(PT_DS, pt_regs, xds); | ||
74 | OFFSET(PT_ES, pt_regs, xes); | ||
75 | OFFSET(PT_GS, pt_regs, xgs); | ||
76 | OFFSET(PT_ORIG_EAX, pt_regs, orig_eax); | ||
77 | OFFSET(PT_EIP, pt_regs, eip); | ||
78 | OFFSET(PT_CS, pt_regs, xcs); | ||
79 | OFFSET(PT_EFLAGS, pt_regs, eflags); | ||
80 | OFFSET(PT_OLDESP, pt_regs, esp); | ||
81 | OFFSET(PT_OLDSS, pt_regs, xss); | ||
82 | BLANK(); | ||
83 | |||
61 | OFFSET(EXEC_DOMAIN_handler, exec_domain, handler); | 84 | OFFSET(EXEC_DOMAIN_handler, exec_domain, handler); |
62 | OFFSET(RT_SIGFRAME_sigcontext, rt_sigframe, uc.uc_mcontext); | 85 | OFFSET(RT_SIGFRAME_sigcontext, rt_sigframe, uc.uc_mcontext); |
63 | BLANK(); | 86 | BLANK(); |
@@ -74,4 +97,18 @@ void foo(void) | |||
74 | DEFINE(VDSO_PRELINK, VDSO_PRELINK); | 97 | DEFINE(VDSO_PRELINK, VDSO_PRELINK); |
75 | 98 | ||
76 | OFFSET(crypto_tfm_ctx_offset, crypto_tfm, __crt_ctx); | 99 | OFFSET(crypto_tfm_ctx_offset, crypto_tfm, __crt_ctx); |
100 | |||
101 | BLANK(); | ||
102 | OFFSET(PDA_cpu, i386_pda, cpu_number); | ||
103 | OFFSET(PDA_pcurrent, i386_pda, pcurrent); | ||
104 | |||
105 | #ifdef CONFIG_PARAVIRT | ||
106 | BLANK(); | ||
107 | OFFSET(PARAVIRT_enabled, paravirt_ops, paravirt_enabled); | ||
108 | OFFSET(PARAVIRT_irq_disable, paravirt_ops, irq_disable); | ||
109 | OFFSET(PARAVIRT_irq_enable, paravirt_ops, irq_enable); | ||
110 | OFFSET(PARAVIRT_irq_enable_sysexit, paravirt_ops, irq_enable_sysexit); | ||
111 | OFFSET(PARAVIRT_iret, paravirt_ops, iret); | ||
112 | OFFSET(PARAVIRT_read_cr0, paravirt_ops, read_cr0); | ||
113 | #endif | ||
77 | } | 114 | } |