Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/sys/arch/i386/i386/genassym.cf,v rcsdiff: /ftp/cvs/cvsroot/src/sys/arch/i386/i386/genassym.cf,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.49.10.2 retrieving revision 1.49.10.3 diff -u -p -r1.49.10.2 -r1.49.10.3 --- src/sys/arch/i386/i386/genassym.cf 2008/01/09 01:46:35 1.49.10.2 +++ src/sys/arch/i386/i386/genassym.cf 2008/03/23 02:04:06 1.49.10.3 @@ -1,4 +1,4 @@ -# $NetBSD: genassym.cf,v 1.49.10.2 2008/01/09 01:46:35 matt Exp $ +# genassym.cf,v 1.49.10.2 2008/01/09 01:46:35 matt Exp # # Copyright (c) 1998, 2006, 2007 The NetBSD Foundation, Inc. @@ -80,6 +80,7 @@ include "opt_compat_freebsd.h" include "opt_compat_linux.h" include "opt_compat_netbsd.h" include "opt_multiprocessor.h" +include "opt_xen.h" endif quote #define __MUTEX_PRIVATE @@ -109,10 +110,20 @@ include include include +ifdef XEN +ifdef XEN3 +include +else +include +endif +endif + if defined(_KERNEL) && !defined(_LKM) include "ioapic.h" +ifndef XEN include "apmbios.h" endif +endif if NAPMBIOS > 0 include include @@ -151,6 +162,7 @@ endif include + include define PAGE_SIZE PAGE_SIZE @@ -189,6 +201,8 @@ define L_PROC offsetof(struct lwp, l_p define L_MD_REGS offsetof(struct lwp, l_md.md_regs) define L_CTXSWTCH offsetof(struct lwp, l_ctxswtch) define L_MD_ASTPENDING offsetof(struct lwp, l_md.md_astpending) +define L_CPU offsetof(struct lwp, l_cpu) +define L_NCSW offsetof(struct lwp, l_ncsw) define P_FLAG offsetof(struct proc, p_flag) define P_RASLIST offsetof(struct proc, p_raslist) define P_MD_SYSCALL offsetof(struct proc, p_md.md_syscall) @@ -216,7 +230,6 @@ define PCB_EBP offsetof(struct pcb, pc define PCB_ESP offsetof(struct pcb, pcb_esp) define PCB_ESP0 offsetof(struct pcb, pcb_esp0) define PCB_CR0 offsetof(struct pcb, pcb_cr0) -define PCB_LDT_SEL offsetof(struct pcb, pcb_ldt_sel) define PCB_ONFAULT offsetof(struct pcb, pcb_onfault) define PCB_FPCPU offsetof(struct pcb, pcb_fpcpu) define PCB_FSD offsetof(struct pcb, pcb_fsd) @@ -265,7 +278,11 @@ endif define IH_FUN offsetof(struct intrhand, ih_fun) define IH_ARG offsetof(struct intrhand, ih_arg) define IH_LEVEL offsetof(struct intrhand, ih_level) +ifdef XEN +define IH_IPL_NEXT offsetof(struct intrhand, ih_ipl_next) +else define IH_NEXT offsetof(struct intrhand, ih_next) +endif if NAPMBIOS > 0 define APM_CODE32 offsetof(struct apm_connect_info, apm_code32_seg_base) @@ -304,6 +321,8 @@ define CPU_INFO_ESP0 offsetof(struct cp define CPU_INFO_IOBASE offsetof(struct cpu_info, ci_tss.tss_iobase) define CPU_INFO_IOMAP offsetof(struct cpu_info, ci_iomap) define IOMAP_INVALOFF IOMAP_INVALOFF +define CPU_INFO_CC offsetof(struct cpu_info, ci_cc) +define CPU_INFO_NSYSCALL offsetof(struct cpu_info, ci_data.cpu_nsyscall) define CPU_INFO_LEVEL offsetof(struct cpu_info, ci_cpuid_level) define CPU_INFO_VENDOR offsetof(struct cpu_info, ci_vendor[0]) @@ -326,6 +345,12 @@ define CPU_INFO_MTX_OLDSPL offsetof(stru define CPU_INFO_INTRSTACK offsetof(struct cpu_info, ci_intrstack) define CPU_INFO_ISTATE offsetof(struct cpu_info, ci_istate) +define CC_DENOM offsetof(struct cc_microtime_state, cc_denom) +define CC_DELTA offsetof(struct cc_microtime_state, cc_denom) +define CC_VAL offsetof(struct cc_microtime_state, cc_val) +define CC_GEN offsetof(struct cc_microtime_state, cc_gen) +define CC_CC offsetof(struct cc_microtime_state, cc_cc) + define ACPI_SUSPEND_GDT offsetof(struct cpu_info, ci_suspend_gdt) define ACPI_SUSPEND_IDT offsetof(struct cpu_info, ci_suspend_idt) define ACPI_SUSPEND_TR offsetof(struct cpu_info, ci_suspend_tr) @@ -351,10 +376,16 @@ define PIC_LOCK offsetof(struct pic, p endif define SIZEOF_CPU_INFO sizeof(struct cpu_info) - -define SIZEOF_ISOURCE sizeof(struct intrsource) define SIZEOF_ISTUB sizeof(struct intrstub) +ifdef XEN +define SIZEOF_IPLSOURCE sizeof(struct iplsource) +define IS_RECURSE offsetof(struct iplsource, ipl_recurse) +define IS_RESUME offsetof(struct iplsource, ipl_resume) +define IS_HANDLERS offsetof(struct iplsource, ipl_handlers) +define EV_EVCNTL offsetof(struct evcnt, ev_count) +else +define SIZEOF_ISOURCE sizeof(struct intrsource) define IS_RECURSE offsetof(struct intrsource, is_recurse) define IS_RESUME offsetof(struct intrsource, is_resume) define IS_EVCNTLO offsetof(struct intrsource, is_evcnt.ev_count) @@ -366,6 +397,7 @@ define IS_PIN offsetof(struct intrsour define IS_TYPE offsetof(struct intrsource, is_type) define IS_MAXLEVEL offsetof(struct intrsource, is_maxlevel) define IS_LWP offsetof(struct intrsource, is_lwp) +endif define TREC_SP offsetof(struct trec, tr_sp) define TREC_HPC offsetof(struct trec, tr_hpc) @@ -437,3 +469,26 @@ define L2_SHIFT L2_SHIFT define L2_FRAME L2_FRAME define PGOFSET PGOFSET define PGSHIFT PGSHIFT + +ifdef XEN +ifdef XEN3 +define START_INFO_SHARED_INFO offsetof(struct start_info, shared_info) +define START_INFO_FLAGS offsetof(struct start_info, flags) +define START_INFO_CONSOLE_MFN offsetof(struct start_info, console_mfn) +define START_INFO_STORE_MFN offsetof(struct start_info, store_mfn) +else +define START_INFO_SHARED_INFO offsetof(start_info_t, shared_info) +endif +define SIF_INITDOMAIN SIF_INITDOMAIN +ifdef XEN3 +define EVTCHN_UPCALL_PENDING offsetof(struct shared_info, vcpu_info[0].evtchn_upcall_pending) +define EVTCHN_UPCALL_MASK offsetof(struct shared_info, vcpu_info[0].evtchn_upcall_mask) +else +define EVTCHN_UPCALL_PENDING offsetof(struct shared_info_st, vcpu_info[0].evtchn_upcall_pending) +define EVTCHN_UPCALL_MASK offsetof(struct shared_info_st, vcpu_info[0].evtchn_upcall_mask) +endif + +define HYPERVISOR_sched_op __HYPERVISOR_sched_op +define SCHEDOP_yield SCHEDOP_yield +endif +