Subject: CLBYTES undefined in kern_malloc.c for vax port
To: None <port-vax@netbsd.org, current-users@netbsd.org>
From: NetBSD Mailing list <netbsd@mrynet.com>
List: port-vax
Date: 12/11/1999 20:42:09
I've been experiencing the following in kern_malloc of the vax port for the
last three days:
cc -O2 -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wno-main -mno-pic -I. -I../../../../arch -I../../../.. -nostdinc -I../../../../../gnu/sys -DVAX630 -DVAX650 -DVAX410 -DVAX43 -DCOMPAT_VAX1K -DLKM -DMAXUSERS=16 -D_KERNEL -D_VAX_INLINE_ -c ../../../../kern/kern_malloc.c
../../../../kern/kern_malloc.c: In function `kmeminit':
../../../../kern/kern_malloc.c:611: `CLBYTES' undeclared (first use in this function)
../../../../kern/kern_malloc.c:611: (Each undeclared identifier is reported only once
The offending code is in the kmeminit() function of kern_malloc.c:
611: npg = VM_KMEM_SIZE/ NBPG;
A grep(1) of the entire /usr/src tree indicates CLBYTES references as follows:
/usr/src/sys/arch/alpha/a12/if_ade.c
#define CLBYTES PAGE_SIZE
/usr/src/sys/arch/vax/include/param.h
#define VM_KMEM_SIZE (NKMEMCLUSTERS*CLBYTES)
/usr/src/sys/arch/vax/include/vmparam.h
curbufsize = CLBYTES * (i < residual ? base + 1 : base);
curbuf += CLBYTES;
curbufsize -= CLBYTES;
format_bytes(pbuf, sizeof(pbuf), bufpages * CLBYTES);
* Don't dump on the first CLBYTES (why CLBYTES?) in case the dump
if (dumplo < btodb(CLBYTES))
dumplo = btodb(CLBYTES);
/usr/src/sys/arch/vax/vax/machdep.c
malloc(CLBYTES, M_TEMP, M_WAITOK);
bzero(zeropage, CLBYTES);
c = min(iov->iov_len, CLBYTES);
/usr/src/sys/dev/pci/if_de.c
#define CLBYTES PAGE_SIZE
/usr/src/sys/dev/pci/if_lmc.c
#define CLBYTES PAGE_SIZE
This doesn't provide enough information for me to make an assumption. Additionally,
the widespread use of MCLBYTES (note the M) confuses the issue more.
Has anyone resolved this issue on their own for the VAX platform?
Cheers,
-skots
--
Scott G. Akmentins-Taylor InterNet: staylor@mrynet.com
MRY Systems staylor@mrynet.lv
(Skots Gregorijs Akmentins-Teilors -- just call me "Skots")
----- Labak miris neka sarkans -----