Changeset View
Changeset View
Standalone View
Standalone View
head/sys/kern/kern_proc.c
Show First 20 Lines • Show All 133 Lines • ▼ Show 20 Lines | |||||
u_long pgrphash; | u_long pgrphash; | ||||
struct proclist allproc; | struct proclist allproc; | ||||
struct proclist zombproc; | struct proclist zombproc; | ||||
struct sx allproc_lock; | struct sx allproc_lock; | ||||
struct sx proctree_lock; | struct sx proctree_lock; | ||||
struct mtx ppeers_lock; | struct mtx ppeers_lock; | ||||
uma_zone_t proc_zone; | uma_zone_t proc_zone; | ||||
/* | |||||
* The offset of various fields in struct proc and struct thread. | |||||
* These are used by kernel debuggers to enumerate kernel threads and | |||||
* processes. | |||||
*/ | |||||
const int proc_off_p_pid = offsetof(struct proc, p_pid); | |||||
const int proc_off_p_comm = offsetof(struct proc, p_comm); | |||||
const int proc_off_p_list = offsetof(struct proc, p_list); | |||||
const int proc_off_p_threads = offsetof(struct proc, p_threads); | |||||
const int thread_off_td_tid = offsetof(struct thread, td_tid); | |||||
const int thread_off_td_name = offsetof(struct thread, td_name); | |||||
const int thread_off_td_oncpu = offsetof(struct thread, td_oncpu); | |||||
const int thread_off_td_pcb = offsetof(struct thread, td_pcb); | |||||
const int thread_off_td_plist = offsetof(struct thread, td_plist); | |||||
int kstack_pages = KSTACK_PAGES; | int kstack_pages = KSTACK_PAGES; | ||||
SYSCTL_INT(_kern, OID_AUTO, kstack_pages, CTLFLAG_RD, &kstack_pages, 0, | SYSCTL_INT(_kern, OID_AUTO, kstack_pages, CTLFLAG_RD, &kstack_pages, 0, | ||||
"Kernel stack size in pages"); | "Kernel stack size in pages"); | ||||
static int vmmap_skip_res_cnt = 0; | static int vmmap_skip_res_cnt = 0; | ||||
SYSCTL_INT(_kern, OID_AUTO, proc_vmmap_skip_resident_count, CTLFLAG_RW, | SYSCTL_INT(_kern, OID_AUTO, proc_vmmap_skip_resident_count, CTLFLAG_RW, | ||||
&vmmap_skip_res_cnt, 0, | &vmmap_skip_res_cnt, 0, | ||||
"Skip calculation of the pages resident count in kern.proc.vmmap"); | "Skip calculation of the pages resident count in kern.proc.vmmap"); | ||||
▲ Show 20 Lines • Show All 2,925 Lines • Show Last 20 Lines |