Annotation of 43BSD/sys/vax/machparam.h, revision 1.1.1.1

1.1       root        1: /*
                      2:  * Copyright (c) 1982, 1986 Regents of the University of California.
                      3:  * All rights reserved.  The Berkeley software License Agreement
                      4:  * specifies the terms and conditions for redistribution.
                      5:  *
                      6:  *     @(#)machparam.h 7.1 (Berkeley) 6/5/86
                      7:  */
                      8: 
                      9: /*
                     10:  * Machine dependent constants for vax.
                     11:  */
                     12: #define        NBPG    512             /* bytes/page */
                     13: #define        PGOFSET (NBPG-1)        /* byte offset into page */
                     14: #define        PGSHIFT 9               /* LOG2(NBPG) */
                     15: 
                     16: #define        CLSIZE          2
                     17: #define        CLSIZELOG2      1
                     18: 
                     19: #define        SSIZE   4               /* initial stack size/NBPG */
                     20: #define        SINCR   4               /* increment of stack/NBPG */
                     21: 
                     22: #define        UPAGES  10              /* pages of u-area */
                     23: 
                     24: /*
                     25:  * Some macros for units conversion
                     26:  */
                     27: /* Core clicks (512 bytes) to segments and vice versa */
                     28: #define        ctos(x) (x)
                     29: #define        stoc(x) (x)
                     30: 
                     31: /* Core clicks (512 bytes) to disk blocks */
                     32: #define        ctod(x) (x)
                     33: #define        dtoc(x) (x)
                     34: #define        dtob(x) ((x)<<9)
                     35: 
                     36: /* clicks to bytes */
                     37: #define        ctob(x) ((x)<<9)
                     38: 
                     39: /* bytes to clicks */
                     40: #define        btoc(x) ((((unsigned)(x)+511)>>9))
                     41: 
                     42: /*
                     43:  * Macros to decode processor status word.
                     44:  */
                     45: #define        USERMODE(ps)    (((ps) & PSL_CURMOD) == PSL_CURMOD)
                     46: #define        BASEPRI(ps)     (((ps) & PSL_IPL) == 0)
                     47: 
                     48: #ifdef KERNEL
                     49: #ifndef LOCORE
                     50: int    cpuspeed;
                     51: #endif
                     52: #define        DELAY(n)        { register int N = cpuspeed * (n); while (--N > 0); }
                     53: 
                     54: #else KERNEL
                     55: #define        DELAY(n)        { register int N = (n); while (--N > 0); }
                     56: #endif KERNEL

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.