[BACK]Return to grf_gbreg.h CVS log [TXT][DIR] Up to [local] / sys / arch / hp300 / stand / include

Annotation of sys/arch/hp300/stand/include/grf_gbreg.h, Revision 1.1

1.1     ! nbrk        1: /*     $OpenBSD: grf_gbreg.h,v 1.1 2005/01/19 17:09:32 miod Exp $      */
        !             2: /*     $NetBSD: grf_gbreg.h,v 1.4 1994/10/26 07:23:53 cgd Exp $        */
        !             3:
        !             4: /*
        !             5:  * Copyright (c) 1988 University of Utah.
        !             6:  * Copyright (c) 1990, 1993
        !             7:  *     The Regents of the University of California.  All rights reserved.
        !             8:  *
        !             9:  * This code is derived from software contributed to Berkeley by
        !            10:  * the Systems Programming Group of the University of Utah Computer
        !            11:  * Science Department.
        !            12:  *
        !            13:  * Redistribution and use in source and binary forms, with or without
        !            14:  * modification, are permitted provided that the following conditions
        !            15:  * are met:
        !            16:  * 1. Redistributions of source code must retain the above copyright
        !            17:  *    notice, this list of conditions and the following disclaimer.
        !            18:  * 2. Redistributions in binary form must reproduce the above copyright
        !            19:  *    notice, this list of conditions and the following disclaimer in the
        !            20:  *    documentation and/or other materials provided with the distribution.
        !            21:  * 3. Neither the name of the University nor the names of its contributors
        !            22:  *    may be used to endorse or promote products derived from this software
        !            23:  *    without specific prior written permission.
        !            24:  *
        !            25:  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
        !            26:  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
        !            27:  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
        !            28:  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
        !            29:  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
        !            30:  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
        !            31:  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
        !            32:  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
        !            33:  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
        !            34:  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
        !            35:  * SUCH DAMAGE.
        !            36:  *
        !            37:  * from: Utah $Hdr: grf_gbreg.h 1.11 92/01/21$
        !            38:  *
        !            39:  *     @(#)grf_gbreg.h 8.1 (Berkeley) 6/10/93
        !            40:  */
        !            41:
        !            42: #include <hp300/dev/iotypes.h> /* XXX */
        !            43:
        !            44: /*
        !            45:  * Gatorbox driver regs
        !            46:  */
        !            47:
        !            48: #define TILER_ENABLE           0x80
        !            49: #define LINE_MOVER_ENABLE      0x80
        !            50: #define UP_LEFT                0x00
        !            51: #define DOWN_RIGHT             0x40
        !            52: #define MOVE_UP_LEFT           TILER_ENABLE|UP_LEFT
        !            53: #define MOVE_DOWN_RIGHT        TILER_ENABLE|DOWN_RIGHT
        !            54:
        !            55: #define tile_mover_waitbusy(regaddr) \
        !            56:        while (((struct gboxfb *)(regaddr))->sec_interrupt & 0x10)
        !            57:
        !            58: #define line_mover_waitbusy(regaddr) \
        !            59:        while ((((struct gboxfb *)(regaddr))->status & 0x80) == 0)
        !            60:
        !            61: #define gbcm_waitbusy(regaddr) \
        !            62:        while (((struct gboxfb *)(regaddr))->cmap_busy != 0xff)
        !            63:
        !            64: struct gboxfb {
        !            65:   u_char       :8;
        !            66:   vu_char      reset;                  /* reset register               0x01 */
        !            67:   vu_char      sec_interrupt;          /* Secondary interrupt register 0x03 */
        !            68:   vu_char      interrupt;              /* interrupt register           0x03 */
        !            69:   u_char       :8;
        !            70:   vu_char      fbwmsb;                 /* frame buffer width MSB       0x05 */
        !            71:   u_char       :8;
        !            72:   vu_char      fbwlsb;                 /* frame buffer width MSB       0x07 */
        !            73:   u_char       :8;
        !            74:   vu_char      fbhmsb;                 /* frame buffer height MSB      0x09 */
        !            75:   u_char       :8;
        !            76:   vu_char      fbhlsb;                 /* frame buffer height MSB      0x0b */
        !            77:   u_char       :8;
        !            78:   vu_char      dwmsb;                  /* display width MSB            0x0d */
        !            79:   u_char       :8;
        !            80:   vu_char      dwlsb;                  /* display width MSB            0x0f */
        !            81:   u_char       :8;
        !            82:   vu_char      dhmsb;                  /* display height MSB           0x11 */
        !            83:   u_char       :8;
        !            84:   vu_char      dhlsb;                  /* display height MSB           0x13 */
        !            85:   u_char       :8;
        !            86:   vu_char      fbid;                   /* Scondary frame buffer id     0x15 */
        !            87:   u_char       f1[0x5d-0x15-1];
        !            88:   vu_char      fbomsb;                 /* frame buffer offset MSB      0x5d */
        !            89:   u_char       :8;
        !            90:   vu_char      fbolsb;                 /* frame buffer offset LSB      0x5f */
        !            91:   u_char       f2[0x4000-0x5f-1];
        !            92:   vu_char      crtc_address;           /* CTR controller address reg 0x4000 */
        !            93:   vu_char      status;                 /* Status register            0x4001 */
        !            94:   vu_char      crtc_data;              /* CTR controller data reg    0x4002 */
        !            95:   u_char       f3[6];
        !            96:   vu_char      line_mover_rep_rule;    /* Line move rep rule                */
        !            97:   u_char       :8, :8;
        !            98:   vu_char      line_mover_width;       /* Line move width                   */
        !            99:   u_char       f4[0xff3];
        !           100:   vu_char      width;                  /* width in tiles             0x5001 */
        !           101:   u_char       :8;
        !           102:   vu_char      height;                 /* height in tiles            0x5003 */
        !           103:   u_char       f5[3];
        !           104:   vu_char      rep_rule;               /* replacement rule           0x5007 */
        !           105:   u_char       f6[0x6001-0x5007-1];
        !           106:   vu_char      blink1;                 /* blink 1                    0x6001 */
        !           107:   u_char       f7[3];
        !           108:   vu_char      blink2;                 /* blink 2                    0x6005 */
        !           109:   u_char       f8[3];
        !           110:   vu_char      write_protect;          /* write protect              0x6009 */
        !           111:   u_char       f9[0x6803-0x6009-1];
        !           112:   vu_char      cmap_busy;              /* color map busy             0x6803 */
        !           113:   u_char       f10[0x68b9-0x6803-1];
        !           114:   vu_char      creg_select;            /* color map register select  0x68b8 */
        !           115:   u_char       f11[0x68f1-0x68b9-1];
        !           116:   vu_char      cmap_write;             /* color map write trigger    0x68f1 */
        !           117:   u_char       f12[0x69b3-0x68f1-1];
        !           118:   vu_char      cmap_red;               /* red value register         0x69b3 */
        !           119:   u_char       :8;
        !           120:   vu_char      cmap_grn;               /* green value register       0x69b5 */
        !           121:   u_char       :8;
        !           122:   vu_char      cmap_blu;               /* blue value register        0x69b6 */
        !           123: };

CVSweb