Move MSGBUFSIZE from machdep.c to param.h
Use the last page for msgbuf instead of fixed MSGBUFADDR.
This commit is contained in:
parent
90a73bba2c
commit
bb426487a5
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: param.h,v 1.3 1998/09/03 14:10:56 tsubai Exp $ */
|
||||
/* $NetBSD: param.h,v 1.4 1999/01/12 10:51:40 tsubai Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (C) 1995, 1996 Wolfgang Solfrank.
|
||||
|
@ -46,7 +46,7 @@
|
|||
|
||||
#define ALIGNBYTES (sizeof(double) - 1)
|
||||
#define ALIGN(p) (((u_int)(p) + ALIGNBYTES) & ~ALIGNBYTES)
|
||||
#define ALIGNED_POINTER(p,t) ((((u_long)(p)) & (sizeof(t)-1)) == 0)
|
||||
#define ALIGNED_POINTER(p,t) ((((u_long)(p)) & (sizeof(t)-1)) == 0)
|
||||
|
||||
#define PGSHIFT 12
|
||||
#define NBPG (1 << PGSHIFT) /* Page size */
|
||||
|
@ -63,6 +63,10 @@
|
|||
#define UPAGES 4
|
||||
#define USPACE (UPAGES * NBPG)
|
||||
|
||||
#ifndef MSGBUFSIZE
|
||||
#define MSGBUFSIZE NBPG /* default message buffer size */
|
||||
#endif
|
||||
|
||||
#define KERNBASE 0x100000
|
||||
|
||||
/*
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: machdep.c,v 1.26 1999/01/09 22:10:19 thorpej Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.27 1999/01/12 10:51:41 tsubai Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996 Wolfgang Solfrank.
|
||||
|
@ -114,12 +114,8 @@ extern struct user *proc0paddr;
|
|||
struct bat battable[16];
|
||||
int astpending;
|
||||
char *bootpath;
|
||||
paddr_t msgbuf_paddr;
|
||||
|
||||
/*
|
||||
* We use the page just above the interrupt vector as message buffer
|
||||
*/
|
||||
#define MSGBUFADDR 0x3000
|
||||
#define MSGBUFSIZE 4096
|
||||
int msgbufmapped = 0;
|
||||
|
||||
#ifdef NBUF
|
||||
|
@ -437,7 +433,7 @@ cpu_startup()
|
|||
vaddr_t minaddr, maxaddr;
|
||||
int base, residual;
|
||||
|
||||
initmsgbuf((caddr_t)MSGBUFADDR, round_page(MSGBUFSIZE));
|
||||
initmsgbuf((caddr_t)msgbuf_paddr, round_page(MSGBUFSIZE));
|
||||
|
||||
proc0.p_addr = proc0paddr;
|
||||
v = (caddr_t)proc0paddr + USPACE;
|
||||
|
|
Loading…
Reference in New Issue