From b9f009b08da97f99c596289b146208c0d0dcb094 Mon Sep 17 00:00:00 2001 From: Peter Wemm Date: Sat, 7 Sep 2002 22:11:45 +0000 Subject: Make UAREA_PAGES and KSTACK_PAGES visible to userland via sysctl, like PS_STRINGS and USRSTACK is. This is necessary in order to decode a.out core dumps. kern_proc.c was already referring to both of these values but was missing the #include "opt_kstack_pages.h". Make the sysctl variables visible so that certain kld modules can see how their parent kernel was configured. --- sys/kern/kern_proc.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'sys/kern/kern_proc.c') diff --git a/sys/kern/kern_proc.c b/sys/kern/kern_proc.c index b4091e712658..61be8de91259 100644 --- a/sys/kern/kern_proc.c +++ b/sys/kern/kern_proc.c @@ -35,6 +35,7 @@ */ #include "opt_ktrace.h" +#include "opt_kstack_pages.h" #include #include @@ -101,6 +102,11 @@ static int active_procs; static int cached_procs; static int allocated_procs; +int kstack_pages = KSTACK_PAGES; +int uarea_pages = UAREA_PAGES; +SYSCTL_INT(_kern, OID_AUTO, kstack_pages, CTLFLAG_RD, &kstack_pages, 0, ""); +SYSCTL_INT(_kern, OID_AUTO, uarea_pages, CTLFLAG_RD, &uarea_pages, 0, ""); + #define RANGEOF(type, start, end) (offsetof(type, end) - offsetof(type, start)) CTASSERT(sizeof(struct kinfo_proc) == KINFO_PROC_SIZE); -- cgit v1.2.3