debuggers.hg

annotate xen/arch/x86/x86_32/asm-offsets.c @ 3674:fb875591fd72

bitkeeper revision 1.1159.223.63 (42028527-fv-d9BM0_LRp8UKGP19gQ)

Fix NMI deferral.
Signed-off-by: keir.fraser@cl.cam.ac.uk
author kaf24@scramble.cl.cam.ac.uk
date Thu Feb 03 20:10:15 2005 +0000 (2005-02-03)
parents a5f1a6abfc46
children 578b6c14e635 0dc3b8b8c298
rev   line source
kaf24@3079 1 /*
kaf24@3079 2 * Generate definitions needed by assembly language modules.
kaf24@3079 3 * This code generates raw asm output which is post-processed
kaf24@3079 4 * to extract and format the required data.
kaf24@3079 5 */
kaf24@3079 6
kaf24@3079 7 #include <xen/sched.h>
kaf24@3079 8
kaf24@3079 9 #define DEFINE(_sym, _val) \
kaf24@3127 10 __asm__ __volatile__ ( "\n->" #_sym " %0 " #_val : : "i" (_val) )
kaf24@3079 11 #define BLANK() \
kaf24@3079 12 __asm__ __volatile__ ( "\n->" : : )
kaf24@3079 13 #define OFFSET(_sym, _str, _mem) \
kaf24@3079 14 DEFINE(_sym, offsetof(_str, _mem));
kaf24@3079 15
kaf24@3079 16 void __dummy__(void)
kaf24@3079 17 {
kaf24@3079 18 OFFSET(XREGS_eax, struct xen_regs, eax);
kaf24@3079 19 OFFSET(XREGS_ebx, struct xen_regs, ebx);
kaf24@3079 20 OFFSET(XREGS_ecx, struct xen_regs, ecx);
kaf24@3079 21 OFFSET(XREGS_edx, struct xen_regs, edx);
kaf24@3079 22 OFFSET(XREGS_esi, struct xen_regs, esi);
kaf24@3079 23 OFFSET(XREGS_edi, struct xen_regs, edi);
kaf24@3079 24 OFFSET(XREGS_esp, struct xen_regs, esp);
kaf24@3079 25 OFFSET(XREGS_ebp, struct xen_regs, ebp);
kaf24@3079 26 OFFSET(XREGS_eip, struct xen_regs, eip);
kaf24@3079 27 OFFSET(XREGS_cs, struct xen_regs, cs);
kaf24@3079 28 OFFSET(XREGS_ds, struct xen_regs, ds);
kaf24@3079 29 OFFSET(XREGS_es, struct xen_regs, es);
kaf24@3079 30 OFFSET(XREGS_fs, struct xen_regs, fs);
kaf24@3079 31 OFFSET(XREGS_gs, struct xen_regs, gs);
kaf24@3079 32 OFFSET(XREGS_ss, struct xen_regs, ss);
kaf24@3079 33 OFFSET(XREGS_eflags, struct xen_regs, eflags);
kaf24@3127 34 OFFSET(XREGS_error_code, struct xen_regs, error_code);
kaf24@3127 35 OFFSET(XREGS_entry_vector, struct xen_regs, entry_vector);
kaf24@3127 36 OFFSET(XREGS_kernel_sizeof, struct xen_regs, esp);
kaf24@3127 37 DEFINE(XREGS_user_sizeof, sizeof(struct xen_regs));
kaf24@3079 38 BLANK();
kaf24@3079 39
kaf24@3079 40 OFFSET(DOMAIN_processor, struct domain, processor);
kaf24@3079 41 OFFSET(DOMAIN_shared_info, struct domain, shared_info);
kaf24@3081 42 OFFSET(DOMAIN_event_sel, struct domain, thread.event_selector);
kaf24@3081 43 OFFSET(DOMAIN_event_addr, struct domain, thread.event_address);
kaf24@3081 44 OFFSET(DOMAIN_failsafe_sel, struct domain, thread.failsafe_selector);
kaf24@3081 45 OFFSET(DOMAIN_failsafe_addr, struct domain, thread.failsafe_address);
kaf24@3081 46 OFFSET(DOMAIN_trap_bounce, struct domain, thread.trap_bounce);
kaf24@3127 47 OFFSET(DOMAIN_thread_flags, struct domain, thread.flags);
kaf24@3079 48 BLANK();
kaf24@3079 49
kaf24@3079 50 OFFSET(SHINFO_upcall_pending, shared_info_t,
kaf24@3079 51 vcpu_data[0].evtchn_upcall_pending);
kaf24@3079 52 OFFSET(SHINFO_upcall_mask, shared_info_t,
kaf24@3079 53 vcpu_data[0].evtchn_upcall_mask);
kaf24@3079 54 BLANK();
kaf24@3079 55
kaf24@3081 56 OFFSET(TRAPBOUNCE_error_code, struct trap_bounce, error_code);
kaf24@3081 57 OFFSET(TRAPBOUNCE_cr2, struct trap_bounce, cr2);
kaf24@3081 58 OFFSET(TRAPBOUNCE_flags, struct trap_bounce, flags);
kaf24@3081 59 OFFSET(TRAPBOUNCE_cs, struct trap_bounce, cs);
kaf24@3081 60 OFFSET(TRAPBOUNCE_eip, struct trap_bounce, eip);
kaf24@3079 61 BLANK();
kaf24@3177 62
kaf24@3177 63 OFFSET(MULTICALL_op, multicall_entry_t, op);
kaf24@3177 64 OFFSET(MULTICALL_arg0, multicall_entry_t, args[0]);
kaf24@3177 65 OFFSET(MULTICALL_arg1, multicall_entry_t, args[1]);
kaf24@3177 66 OFFSET(MULTICALL_arg2, multicall_entry_t, args[2]);
kaf24@3177 67 OFFSET(MULTICALL_arg3, multicall_entry_t, args[3]);
kaf24@3177 68 OFFSET(MULTICALL_arg4, multicall_entry_t, args[4]);
kaf24@3177 69 OFFSET(MULTICALL_result, multicall_entry_t, args[5]);
kaf24@3633 70 BLANK();
kaf24@3633 71
kaf24@3633 72 DEFINE(FIXMAP_apic_base, fix_to_virt(FIX_APIC_BASE));
kaf24@3079 73 }