Subject: maxusers and its progeny
To: None <port-alpha@NetBSD.ORG>
From: David Paul Zimmerman <dpz@apple.com>
List: port-alpha
Date: 01/02/1996 19:39:31
Dear NetBSD/Alpha folks,

I'm attempting to build a system with a fairly large maxusers setting 
(250), and am hitting a strange boot-time event.  951220's 
arch/alpha/alpha/machdep.c/cpu_startup() prints the 
reserved-PROM/used-NetBSD memory usage line, heads off into 
vm/vm_kern.c/kmem_suballoc() to build the buffer_map, which itself heads 
into vm/vm_map.c/vm_map_create(), and apparently never returns.  I've 
chased the logic around the vm code a bit, and am not getting anywhere.

The really odd thing is that things work fine with a small maxusers 
setting (16), so I think I'm simply blowing some array along the way that 
a maxusers-derived variable uses.  I've tracked this problem to begin at 
a fairly low maxusers, like 32 to 48.  So the question: am I chasing 
around a known issue, or is this a new thing?  My system config is an 
AlphaStation 250 4/266 with 128MB of memory, 1GB sd0, 2GB sd1, console on 
ttyC0; config file attached.

dp

#	$NetBSD: GALAGA,v 1.0 1996/1/2 00:00:00 dpz Exp $
#
# Alpha kernel

include	"std.alpha"

maxusers 256

# CPU Support
options		DEC_2100_A50	# Avanti etc:	AlphaStation 400, 200, etc.
options		DEC_KN20AA	# KN20AA:	AlphaStation 600
options		DEC_AXPPCI_33	# NoName:	AXPpci33, etc.

# bump up the number of buffers, for quicker compiles
options		BUFPAGES=2048		# 16M of buffer cache

# needs to be set per system
options		TIMEZONE="5*60"		# Minutes west of GMT (for param.c)
options		DST=1			# Daylight savings rules (for param.c)

# Standard system options
options		SWAPPAGER, VNODEPAGER, DEVPAGER # Paging (mandatory)
options		DEBUG, DIAGNOSTIC	# Extra kernel debugging
options		KTRACE			# System call tracing support

# File system options
options		FIFO		# POSIX fifo support (in all file systems)
options		FFS		# Fast file system
options		QUOTA		# User and group quotas for the FFS
options		CD9660		# ISO-9660 CD-ROM FS (w/RockRidge extensions)
options		NFSSERVER	# Sun NFS-compatible file system server
options		NFSCLIENT	# Sun NFS-compatible file system client

# Networking options
options		INET		# Internet protocol suite

# 4.3BSD compatibility.  Should be optional, but necessary for now.
options		COMPAT_43

# Binary compatibility with previous versions of NetBSD.
options		COMPAT_10

# System V-like message queues
options		SYSVMSG

# System V-like semaphores
options		SYSVSEM

# System V-like shared memory
options		SYSVSHM
#options	SHMMAXPGS=1024		# 1024 pages is the default

# Loadable Kernel Modules
options		LKM

# Disable kernel security.
#options	INSECURE

# Misc. options
options		PCIVERBOSE	# recognize "unknown" PCI devices

config		netbsd	root on sd0 swap on sd0 and sd1

mainbus0 at	root
cpu*	at	mainbus0

# PCI host bus adapter support
apecs*	at	mainbus?
cia*	at	mainbus?
lca*	at	mainbus?

# PCI bus support
pci*	at	apecs?
pci*	at	cia?
pci*	at	lca?
pci*	at	ppb?

# PCI devices
de*	at	pci?
ncr*	at	pci?
pceb*	at	pci?
pcivga*	at	pci?
ppb*	at	pci?
sio*	at	pci?
tga*	at	pci?

# ISA/EISA bus support
isa*	at	pceb?
eisa*	at	pceb?
isa*	at	sio?

# ISA devices
clock0	at	isa? port 0x70
pckbd0	at	isa? port 0x60 irq 1		# PC-ish ISA keyboard
com0	at	isa? port 0x3f8 irq 4		# standard serial ports
com1	at	isa? port 0x2f8 irq 3
lpt0	at	isa? port 0x3bc irq 7		# standard parallel port

# SCSI bus support
scsibus* at	esp?
scsibus* at	ncr?

# SCSI devices
sd*	at	scsibus? target ? lun ?
st*	at	scsibus? target ? lun ?
cd*	at	scsibus? target ? lun ?

pseudo-device	bpfilter
pseudo-device	loop
pseudo-device	pty
pseudo-device	mmclock