X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/8f6c56a50524aa785f7e596d52dddfb331e18961..4a3eedf9ecc9bbe3f3a5c6ce5e53ad199d639d32:/osfmk/ppc/genassym.c diff --git a/osfmk/ppc/genassym.c b/osfmk/ppc/genassym.c index cca211733..8207aeb55 100644 --- a/osfmk/ppc/genassym.c +++ b/osfmk/ppc/genassym.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000-2005 Apple Computer, Inc. All rights reserved. + * Copyright (c) 2000-2007 Apple Computer, Inc. All rights reserved. * * @APPLE_OSREFERENCE_LICENSE_HEADER_START@ * @@ -43,7 +43,6 @@ * the values, but we cannot run anything on the target machine. */ -#include #include #include @@ -74,6 +73,11 @@ #include #include +#if CONFIG_DTRACE +#define NEED_DTRACE_DEFS +#include <../bsd/sys/lockstat.h> +#endif + /* Undefine standard offsetof because it is different than the one here */ #undef offsetof #define offsetof(TYPE, MEMBER) ((size_t) &((TYPE)0)->MEMBER) @@ -441,6 +445,8 @@ int main(int argc, char *argv[]) DECLARE("hwMckIEratPE", offsetof(struct per_proc_info *, hwCtr.hwMckIEratPE)); DECLARE("hwMckDEratPE", offsetof(struct per_proc_info *, hwCtr.hwMckDEratPE)); + DECLARE("ijsave", offsetof(struct per_proc_info *, ijsave)); + DECLARE("napStamp", offsetof(struct per_proc_info *, hwCtr.napStamp)); DECLARE("napTotal", offsetof(struct per_proc_info *, hwCtr.napTotal)); DECLARE("PP_PROCESSOR", offsetof(struct per_proc_info *, processor[0])); @@ -470,8 +476,8 @@ int main(int argc, char *argv[]) #define IKSBASE (u_int)STACK_IKS(0) /* values from kern/thread.h */ - DECLARE("THREAD_OPTIONS", offsetof(thread_t, options)); - DECLARE("TH_OPT_DELAYIDLE", TH_OPT_DELAYIDLE); + DECLARE("THREAD_STATE", offsetof(thread_t, state)); + DECLARE("TH_IDLE", TH_IDLE); DECLARE("THREAD_KERNEL_STACK", offsetof(thread_t, kernel_stack)); DECLARE("THREAD_RECOVER", offsetof(thread_t, recover)); DECLARE("THREAD_FUNNEL_LOCK", @@ -752,13 +758,13 @@ int main(int argc, char *argv[]) DECLARE("vmm64Bit", vmm64Bit); /* values from kern/task.h */ - DECLARE("TASK_SYSCALLS_MACH", - offsetof(struct task *, syscalls_mach)); - DECLARE("TASK_SYSCALLS_UNIX", - offsetof(struct task *, syscalls_unix)); + DECLARE("TASK_SYSCALLS_MACH", offsetof(struct task *, syscalls_mach)); + DECLARE("TASK_SYSCALLS_UNIX", offsetof(struct task *, syscalls_unix)); + + DECLARE("TASK_VTIMERS", offsetof(struct task *, vtimers)); /* values from vm/vm_map.h */ - DECLARE("VMMAP_PMAP", offsetof(struct vm_map *, pmap)); + DECLARE("VMMAP_PMAP", offsetof(struct _vm_map *, pmap)); /* values from machine/pmap.h */ DECLARE("pmapSpace", offsetof(struct pmap *, space)); @@ -802,6 +808,7 @@ int main(int argc, char *argv[]) DECLARE("pmapVAddr", offsetof(struct pmapTransTab *, pmapVAddr)); DECLARE("pmapTransSize", sizeof(pmapTransTab)); DECLARE("pmapResidentCnt", offsetof(struct pmap *, stats.resident_count)); + DECLARE("pmapResidentMax", offsetof(struct pmap *, stats.resident_max)); DECLARE("maxAdrSp", maxAdrSp); DECLARE("maxAdrSpb", maxAdrSpb); @@ -858,9 +865,13 @@ int main(int argc, char *argv[]) DECLARE("TIMER_HIGHCHK", offsetof(struct timer *, high_bits_check)); DECLARE("TIMER_TSTAMP", offsetof(struct timer *, tstamp)); - DECLARE("CURRENT_TIMER", offsetof(struct processor *, processor_data.current_timer)); + DECLARE("THREAD_TIMER", offsetof(struct processor *, processor_data.thread_timer)); + DECLARE("KERNEL_TIMER", offsetof(struct processor *, processor_data.kernel_timer)); DECLARE("SYSTEM_TIMER", offsetof(struct thread *, system_timer)); DECLARE("USER_TIMER", offsetof(struct thread *, user_timer)); + DECLARE("SYSTEM_STATE", offsetof(struct processor *, processor_data.system_state)); + DECLARE("USER_STATE", offsetof(struct processor *, processor_data.user_state)); + DECLARE("CURRENT_STATE", offsetof(struct processor *, processor_data.current_state)); /* Constants from pmap.h */ DECLARE("PPC_SID_KERNEL", PPC_SID_KERNEL); @@ -882,6 +893,7 @@ int main(int argc, char *argv[]) /* Misc values used by assembler */ DECLARE("AST_ALL", AST_ALL); DECLARE("AST_URGENT", AST_URGENT); + DECLARE("AST_BSD", AST_BSD); /* Spin Lock structure */ DECLARE("SLOCK_ILK", offsetof(lck_spin_t *, interlock)); @@ -1417,5 +1429,10 @@ int main(int argc, char *argv[]) DECLARE("scomstat", offsetof(struct scomcomm *, scomstat)); DECLARE("scomdata", offsetof(struct scomcomm *, scomdata)); +#if CONFIG_DTRACE + DECLARE("LS_LCK_MTX_UNLOCK_RELEASE", LS_LCK_MTX_UNLOCK_RELEASE); + DECLARE("LS_LCK_MTX_LOCK_ACQUIRE", LS_LCK_MTX_LOCK_ACQUIRE); +#endif + return(0); /* For ANSI C :-) */ }