x86: trivial printk optimizations
[safe/jmp/linux-2.6] / arch / x86 / kernel / asm-offsets_64.c
index 40f4175..494e1e0 100644 (file)
@@ -46,6 +46,9 @@ int main(void)
        ENTRY(addr_limit);
        ENTRY(preempt_count);
        ENTRY(status);
+#ifdef CONFIG_IA32_EMULATION
+       ENTRY(sysenter_return);
+#endif
        BLANK();
 #undef ENTRY
 #define ENTRY(entry) DEFINE(pda_ ## entry, offsetof(struct x8664_pda, entry))
@@ -58,17 +61,31 @@ int main(void)
        ENTRY(data_offset);
        BLANK();
 #undef ENTRY
+#ifdef CONFIG_PARAVIRT
+       BLANK();
+       OFFSET(PARAVIRT_enabled, pv_info, paravirt_enabled);
+       OFFSET(PARAVIRT_PATCH_pv_cpu_ops, paravirt_patch_template, pv_cpu_ops);
+       OFFSET(PARAVIRT_PATCH_pv_irq_ops, paravirt_patch_template, pv_irq_ops);
+       OFFSET(PV_IRQ_irq_disable, pv_irq_ops, irq_disable);
+       OFFSET(PV_IRQ_irq_enable, pv_irq_ops, irq_enable);
+       OFFSET(PV_CPU_iret, pv_cpu_ops, iret);
+       OFFSET(PV_CPU_irq_enable_syscall_ret, pv_cpu_ops, irq_enable_syscall_ret);
+       OFFSET(PV_CPU_swapgs, pv_cpu_ops, swapgs);
+       OFFSET(PV_MMU_read_cr2, pv_mmu_ops, read_cr2);
+#endif
+
+
 #ifdef CONFIG_IA32_EMULATION
 #define ENTRY(entry) DEFINE(IA32_SIGCONTEXT_ ## entry, offsetof(struct sigcontext_ia32, entry))
-       ENTRY(eax);
-       ENTRY(ebx);
-       ENTRY(ecx);
-       ENTRY(edx);
-       ENTRY(esi);
-       ENTRY(edi);
-       ENTRY(ebp);
-       ENTRY(esp);
-       ENTRY(eip);
+       ENTRY(ax);
+       ENTRY(bx);
+       ENTRY(cx);
+       ENTRY(dx);
+       ENTRY(si);
+       ENTRY(di);
+       ENTRY(bp);
+       ENTRY(sp);
+       ENTRY(ip);
        BLANK();
 #undef ENTRY
        DEFINE(IA32_RT_SIGFRAME_sigcontext,
@@ -80,14 +97,14 @@ int main(void)
        DEFINE(pbe_next, offsetof(struct pbe, next));
        BLANK();
 #define ENTRY(entry) DEFINE(pt_regs_ ## entry, offsetof(struct pt_regs, entry))
-       ENTRY(rbx);
-       ENTRY(rbx);
-       ENTRY(rcx);
-       ENTRY(rdx);
-       ENTRY(rsp);
-       ENTRY(rbp);
-       ENTRY(rsi);
-       ENTRY(rdi);
+       ENTRY(bx);
+       ENTRY(bx);
+       ENTRY(cx);
+       ENTRY(dx);
+       ENTRY(sp);
+       ENTRY(bp);
+       ENTRY(si);
+       ENTRY(di);
        ENTRY(r8);
        ENTRY(r9);
        ENTRY(r10);
@@ -96,7 +113,7 @@ int main(void)
        ENTRY(r13);
        ENTRY(r14);
        ENTRY(r15);
-       ENTRY(eflags);
+       ENTRY(flags);
        BLANK();
 #undef ENTRY
 #define ENTRY(entry) DEFINE(saved_context_ ## entry, offsetof(struct saved_context, entry))
@@ -107,7 +124,7 @@ int main(void)
        ENTRY(cr8);
        BLANK();
 #undef ENTRY
-       DEFINE(TSS_ist, offsetof(struct tss_struct, ist));
+       DEFINE(TSS_ist, offsetof(struct tss_struct, x86_tss.ist));
        BLANK();
        DEFINE(crypto_tfm_ctx_offset, offsetof(struct crypto_tfm, __crt_ctx));
        BLANK();