Annotation of coherent/a/usr/include.b4ps2/sys/coherent.h, revision 1.1

1.1     ! root        1: /*
        !             2:  * Some useful and miscellaneous things.
        !             3:  */
        !             4: #ifndef        COHERENT_H
        !             5: #define        COHERENT_H      COHERENT_H
        !             6: 
        !             7: #define         KERNEL
        !             8: #include <sys/types.h>
        !             9: #include <sys/timeout.h>
        !            10: #include <sys/param.h>
        !            11: #include <sys/fun.h>
        !            12: #include <sys/mmu.h>
        !            13: #include <sys/uproc.h>
        !            14: #ifdef _I386
        !            15: #include <sys/reg.h>
        !            16: #else
        !            17: #include <sys/machine.h>
        !            18: #define v_sleep(a1,a2,a3,a4,a5)                sleep(a1,a2,a3,a4)
        !            19: #endif
        !            20: 
        !            21: #ifdef TRACER
        !            22: #include <sys/mwc_coherent.h>
        !            23: #else
        !            24: #define SET_U_ERROR(errno, msg)        { u.u_error = errno; }
        !            25: #define T_HAL(f,c)
        !            26: #define T_PIGGY(f,c)
        !            27: #define T_VLAD(f,c)
        !            28: #define T_CON(f,c)
        !            29: #define T_MSGQ(f,c)
        !            30: #endif /* TRACER */
        !            31: 
        !            32: #ifdef _I386
        !            33: #define CHIRP(ch)              chirp(ch)
        !            34: #define _CHIRP(ch, locn)       _chirp(ch, locn)
        !            35: #if 1
        !            36: #define kclear(buf, nbytes)            memset(buf, 0, nbytes)
        !            37: #define kkcopy(src, dest, nbytes)      (memcpy(dest, src, nbytes),nbytes)
        !            38: #endif
        !            39: #else
        !            40: #define CHIRP(ch)
        !            41: #define _CHIRP(ch, locn)
        !            42: #endif
        !            43: 
        !            44: /*
        !            45:  * Null
        !            46:  */
        !            47: #ifndef        NULL            /* machine.h doesn't have any ideas */
        !            48: #define NULL   0
        !            49: #endif
        !            50: 
        !            51: /*
        !            52:  * Storage management functions.
        !            53:  */
        !            54: extern char            *alloc();
        !            55: #define        kalloc(n)       alloc(allkp, n)
        !            56: #define kfree(p)       free(p)
        !            57: 
        !            58: /*
        !            59:  * Functions for copying between kernel and segments.
        !            60:  */
        !            61: #define kscopy(k, s, o, n)     kpcopy(k, s->s_paddr+o, n)
        !            62: #define skcopy(s, o, k, n)     pkcopy(s->s_paddr+o, k, n)
        !            63: 
        !            64: /*
        !            65:  * Time of day structure.
        !            66:  */
        !            67: typedef struct TIME {
        !            68:        time_t  t_time;                 /* Time and date */
        !            69:        int     t_tick;                 /* Clock ticks into this second */
        !            70:        int     t_zone;                 /* Time zone */
        !            71:        int     t_dstf;                 /* Daylight saving time used */
        !            72: } TIME;
        !            73: 
        !            74: /*
        !            75:  * General global variables.
        !            76:  */
        !            77: extern int      debflag;               /* General debug flag */
        !            78: extern int      batflag;               /* Turn on clock flag */
        !            79: extern int      outflag;               /* Device timeouts */
        !            80: extern int      ttyflag;               /* Console is present */
        !            81: extern int      mactype;               /* Machine type */
        !            82: extern unsigned utimer;                /* Unsigned timer */
        !            83: extern long     lbolt;                 /* Clock ticks since system startup */
        !            84: extern TIM     stimer;                 /* Swap timer */
        !            85: extern unsigned msize;                 /* Memory size in K */
        !            86: extern unsigned asize;                 /* Alloc size in bytes */
        !            87: extern TIME     timer;                 /* Current time */
        !            88: extern char     *icodep;               /* Init code start */
        !            89: extern int      icodes;                /* Init code size */
        !            90: extern dev_t    rootdev;               /* Root device */
        !            91: extern dev_t    swapdev;               /* Swap device */
        !            92: extern dev_t    pipedev;               /* Pipe device */
        !            93: extern paddr_t  corebot;               /* Bottom of core */
        !            94: extern paddr_t  coretop;               /* Top of core */
        !            95: extern paddr_t  holebot;               /* Bottom of I/O memory */
        !            96: extern paddr_t  holetop;               /* Top of I/O memory */
        !            97: extern daddr_t  swapbot;               /* Bottom of swap */
        !            98: extern daddr_t  swaptop;               /* Top of swap */
        !            99: extern paddr_t  clistp;                /* Base of clists */
        !           100: extern struct   all *allkp;            /* Alloc space */
        !           101: extern int      NSLOT;                 /* Num of loadable driver data slots */
        !           102: extern int      slotsz;                /* Size of loadable driver data slot */
        !           103: extern int *    slotp;                 /* Loadable driver pids/data space */
        !           104: extern int      (*altclk)();           /* hook for polled devices */
        !           105: extern UPROC    u;                     /* Current user area. */
        !           106: 
        !           107: #ifdef _I386
        !           108: 
        !           109: extern unsigned total_mem;             /* Total physical memory in bytes.  */
        !           110: extern SR      blockp;                 /* Base of buffers */
        !           111: extern SR      allocp;
        !           112: extern int     dev_loaded;
        !           113: extern int     DUMP_LIM;
        !           114: 
        !           115: #else
        !           116: 
        !           117: extern char     *idatap;               /* Init data start */
        !           118: extern int      idatas;                /* Init data size */
        !           119: extern paddr_t  blockp;                /* Base of buffers */
        !           120: extern int      altsel;                /* for far polling, this is selector */
        !           121:                                        /* ... for altclk; for near polling, */
        !           122:                                        /* ... this is zero */
        !           123: extern int     is_ps;                  /* 1 if running on a PS/2            */ 
        !           124: 
        !           125: #endif
        !           126: #endif /* COHERENT_H */

unix.superglobalmegacorp.com

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