Subject: kern/5382: defopt KMEMSTATS doesn't appear to work
To: None <gnats-bugs@gnats.netbsd.org>
From: Simon Burge <simonb@telstra.com.au>
List: netbsd-bugs
Date: 05/01/1998 17:16:10
>Number:         5382
>Category:       kern
>Synopsis:       defopt KMEMSTATS doesn't appear to work
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    kern-bug-people (Kernel Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri May  1 00:20:01 1998
>Last-Modified:
>Originator:     Simon Burge
>Organization:
	IBM Global Services Australia
>Release:        NetBSD 1.3.1
>Environment:
System: NetBSD vlad 1.3.1 NetBSD 1.3.1 (MONA) #0: Thu Apr  2 10:40:59 EST 1998	simonb@vlad:/usr/src/sys/arch/pmax/compile/MONA pmax

>Description:
	defopt KMEMSTATS doesn't seem to work.  Under 1.3.1, I have
	a i386 with has "options KMEMSTATS" in the GENERIC kernel,
	and a pmax which doesn't.  "vmstat -m" only works on the
	i386.

	"config GENERIC" on the pmax generates an opt_kmemstats.h
	without KMEMSTATS defined:

		vlad:pmax/compile/GENERIC 121> cat opt_kmemstats.h 
		/* option `KMEMSTATS' not defined */

	even though it appears in /sys/conf/files:

		vlad:pmax/compile/GENERIC 122> head ../../../../conf/files 
		#       $NetBSD: files,v 1.183 1998/04/29 21:37:52 matt Exp $

		#       @(#)files.newconf       7.5 (Berkeley) 5/10/93

		# options understood by the machine-independent part of the kernel
		# (note, these are case-sensitive)
		defopt  KMEMSTATS
		defopt  RTC_OFFSET
		defopt  TCP_RECVSPACE
		defopt  TCP_SENDSPACE

	Adding "options KMEMSTATS" to the config file works...

>How-To-Repeat:
	Build a GENERIC kernel on (for example) a pmax, and type
	"vmstat -m".  Look for the follow error:

		vlad:~ 118> vmstat -m
		Kmem statistics are not being gathered by the kernel.

>Fix:
	Unknown.  Adding "options KMEMSTATS" is obviously going
	down the wrong path...
>Audit-Trail:
>Unformatted: