Home | History | Annotate | Line # | Download | only in hd64461
hd64461videoreg.h revision 1.2.10.1
      1  1.2.10.1  elad /*	$NetBSD: hd64461videoreg.h,v 1.2.10.1 2006/04/19 02:32:44 elad Exp $	*/
      2       1.1   uch 
      3       1.1   uch /*-
      4       1.1   uch  * Copyright (c) 2001 The NetBSD Foundation, Inc.
      5       1.1   uch  * All rights reserved.
      6       1.1   uch  *
      7       1.1   uch  * This code is derived from software contributed to The NetBSD Foundation
      8       1.1   uch  * by UCHIYAMA Yasushi.
      9       1.1   uch  *
     10       1.1   uch  * Redistribution and use in source and binary forms, with or without
     11       1.1   uch  * modification, are permitted provided that the following conditions
     12       1.1   uch  * are met:
     13       1.1   uch  * 1. Redistributions of source code must retain the above copyright
     14       1.1   uch  *    notice, this list of conditions and the following disclaimer.
     15       1.1   uch  * 2. Redistributions in binary form must reproduce the above copyright
     16       1.1   uch  *    notice, this list of conditions and the following disclaimer in the
     17       1.1   uch  *    documentation and/or other materials provided with the distribution.
     18       1.1   uch  * 3. All advertising materials mentioning features or use of this software
     19       1.1   uch  *    must display the following acknowledgement:
     20       1.1   uch  *        This product includes software developed by the NetBSD
     21       1.1   uch  *        Foundation, Inc. and its contributors.
     22       1.1   uch  * 4. Neither the name of The NetBSD Foundation nor the names of its
     23       1.1   uch  *    contributors may be used to endorse or promote products derived
     24       1.1   uch  *    from this software without specific prior written permission.
     25       1.1   uch  *
     26       1.1   uch  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
     27       1.1   uch  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
     28       1.1   uch  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
     29       1.1   uch  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
     30       1.1   uch  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
     31       1.1   uch  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
     32       1.1   uch  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
     33       1.1   uch  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
     34       1.1   uch  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
     35       1.1   uch  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
     36       1.1   uch  * POSSIBILITY OF SUCH DAMAGE.
     37       1.1   uch  */
     38       1.1   uch 
     39       1.2   uwe #ifndef _HPCSH_DEV_HD64461VIDEOREG_H_
     40       1.2   uwe #define _HPCSH_DEV_HD64461VIDEOREG_H_
     41       1.2   uwe 
     42       1.1   uch /*
     43       1.1   uch  * LCD Controller Control Register
     44       1.1   uch  */
     45       1.2   uwe 
     46       1.1   uch /* Base Address Register */
     47       1.1   uch #define HD64461_LCDCBAR_REG16			0xb0001000
     48       1.1   uch #define HD64461_LCDCBAR_MASK			0x3fff
     49       1.1   uch #define HD64461_LCDCBAR_SHIFT			12
     50       1.1   uch #define HD64461_LCDCBAR_BASEADDR(x)					\
     51       1.1   uch 	(((x) & HD64461_LCDCBAR_MASK) << HD64461_LCDCBAR_SHIFT)
     52       1.1   uch 
     53       1.1   uch /* Line Address Offset Register */
     54       1.1   uch #define HD64461_LCDCLOR_REG16			0xb0001002
     55       1.1   uch #define HD64461_LCDCLOR_MASK			0x07ff
     56       1.1   uch #define HD64461_LCDCLOR(x)	((x) & HD64461_LCDCLOR_MASK)
     57       1.1   uch 
     58       1.1   uch /* LCDC Control Register */
     59       1.1   uch #define HD64461_LCDCCR_REG16			0xb0001004
     60       1.1   uch #define HD64461_LCDCCR_STBAK			0x0400
     61       1.1   uch #define HD64461_LCDCCR_STREQ			0x0100
     62       1.1   uch #define HD64461_LCDCCR_MOFF			0x0080
     63       1.1   uch #define HD64461_LCDCCR_REFSEL			0x0040
     64       1.1   uch #define HD64461_LCDCCR_EPON			0x0020
     65       1.1   uch #define HD64461_LCDCCR_SPON			0x0010
     66       1.1   uch #define HD64461_LCDCCR_DSPSEL_MASK		0x7
     67       1.1   uch #define HD64461_LCDCCR_DSPSEL(x)	((x) & HD64461_LCDCCR_DSPSEL_MASK)
     68       1.1   uch #define HD64461_LCDCCR_DSPSEL_LCD_CRT		0x4
     69       1.1   uch #define HD64461_LCDCCR_DSPSEL_CRT		0x2
     70       1.1   uch #define HD64461_LCDCCR_DSPSEL_LCD		0x1
     71       1.1   uch 
     72       1.1   uch /* LCD Display Register */
     73       1.1   uch /* 1 */
     74       1.1   uch #define HD64461_LCDLDR1_REG16			0xb0001010
     75       1.1   uch #define HD64461_LCDLDR1_DINV			0x0100
     76       1.1   uch #define HD64461_LCDLDR1_DON			0x0001
     77       1.1   uch /* 2 */
     78       1.1   uch #define HD64461_LCDLDR2_REG16			0xb0001012
     79       1.1   uch #define HD64461_LCDLDR2_CC1			0x0080
     80       1.1   uch #define HD64461_LCDLDR2_CC2			0x0040
     81       1.1   uch #define HD64461_LCDLDR2_LM_MASK			0x7
     82       1.1   uch #define HD64461_LCDLDR2_LM(x)		((x) & HD64461_LCDLDR2_LM_MASK)
     83       1.1   uch #define HD64461_LCDLDR2_LM_COLOR		0x4
     84       1.1   uch #define HD64461_LCDLDR2_LM_GRAY8		0x1
     85       1.1   uch #define HD64461_LCDLDR2_LM_GRAY4		0x0
     86       1.1   uch /* 3 */
     87       1.1   uch #define HD64461_LCDLDR3_REG16			0xb000101e
     88       1.1   uch #define HD64461_LCDLDR3_CS_SHIFT		5
     89       1.1   uch #define HD64461_LCDLDR3_CS_MASK			0x1f
     90       1.1   uch #define HD64461_LCDLDR3_CS(cr)						\
     91       1.1   uch 	(((cr) >> HD64461_LCDLDR3_CS_SHIFT) &				\
     92       1.1   uch 	HD64461_LCDLDR3_CS_MASK)
     93       1.1   uch #define HD64461_LCDLDR3_CS_SET(cr, val)					\
     94       1.1   uch 	((cr) | (((val) << HD64461_LCDLDR3_CS_SHIFT) &			\
     95       1.1   uch 	(HD64461_LCDLDR3_CS_MASK << HD64461_LCDLDR3_CS_SHIFT)))
     96       1.1   uch #define HD64461_LCDLDR3_CG_MASK			0xf
     97       1.1   uch #define HD64461_LCDLDR3_CG(cr)						\
     98       1.1   uch 	((cr)  & HD64461_LCDLDR3_CG_MASK)
     99       1.1   uch #define HD64461_LCDLDR3_CG_CLR(cr)					\
    100       1.1   uch 	((cr)  & ~HD64461_LCDLDR3_CG_MASK)
    101       1.1   uch #define HD64461_LCDLDR3_CG_SET(cr, val)					\
    102       1.1   uch 	((cr) | ((val) & HD64461_LCDLDR3_CG_MASK))
    103       1.1   uch 
    104       1.1   uch /*
    105       1.1   uch  *	select CL2 frequency
    106       1.1   uch  *	0x0	15 MHz (color) 15/2 (monochrome)
    107       1.1   uch  *	0x1	2.5 MHz
    108  1.2.10.1  elad  *	0x2	3.75 MHz
    109  1.2.10.1  elad  *	0x4	5 MHz
    110  1.2.10.1  elad  *	0x8	7.5 MHz
    111  1.2.10.1  elad  *	0x10	10 MHz
    112       1.1   uch  */
    113       1.1   uch #define HD64461_LCDLDR3_CG_COLOR16	0x8
    114       1.1   uch #define HD64461_LCDLDR3_CG_COLOR8	0x4
    115       1.1   uch #define HD64461_LCDLDR3_CG_GRAY6	0x3
    116       1.1   uch #define HD64461_LCDLDR3_CG_GRAY4	0x2
    117       1.1   uch #define HD64461_LCDLDR3_CG_GRAY2	0x1
    118       1.1   uch #define HD64461_LCDLDR3_CG_GRAY1	0x0
    119       1.1   uch 
    120       1.1   uch /* LCD Number of Characters in Horizontal Register */
    121       1.1   uch #define HD64461_LCDLDHNCR_REG16			0xb0001014
    122       1.1   uch #define HD64461_LCDLDHNCR_NHD_SHIFT		8
    123       1.1   uch #define HD64461_LCDLDHNCR_NHD_MASK		0xff
    124       1.1   uch #define HD64461_LCDLDHNCR_NHD(cr)					\
    125       1.1   uch 	(((cr) >> HD64461_LCDLDHNCR_NHD_SHIFT) &			\
    126       1.1   uch 	HD64461_LCDLDHNCR_NHD_MASK)
    127       1.1   uch #define HD64461_LCDLDHNCR_NHD_SET(cr, val)				\
    128       1.1   uch 	((cr) | (((val) << HD64461_LCDLDHNCR_NHD_SHIFT) &		\
    129       1.1   uch 	(HD64461_LCDLDHNCR_NHD_MASK << HD64461_LCDLDHNCR_NHD_SHIFT)))
    130       1.1   uch #define HD64461_LCDLDHNCR_NHT_SHIFT		0
    131       1.1   uch #define HD64461_LCDLDHNCR_NHT_MASK		0xff
    132       1.1   uch #define HD64461_LCDLDHNCR_NHT(cr)					\
    133       1.1   uch 	(((cr) >> HD64461_LCDLDHNCR_NHT_SHIFT) &			\
    134       1.1   uch 	HD64461_LCDLDHNCR_NHT_MASK)
    135       1.1   uch #define HD64461_LCDLDHNCR_NHT_SET(cr, val)				\
    136       1.1   uch 	((cr) | (((val) << HD64461_LCDLDHNCR_NHT_SHIFT) &		\
    137       1.1   uch 	(HD64461_LCDLDHNCR_NHT_MASK << HD64461_LCDLDHNCR_NHT_SHIFT)))
    138       1.1   uch 
    139       1.1   uch /* Start Position of Horizontal Register */
    140       1.1   uch #define HD64461_LCDLDHNSR_REG16			0xb0001016
    141       1.1   uch #define HD64461_LCDLDHNSR_HSW_SHIFT		8
    142       1.1   uch #define HD64461_LCDLDHNSR_HSW_MASK		0xf
    143       1.1   uch #define HD64461_LCDLDHNSR_HSW(cr)					\
    144       1.1   uch 	(((cr) >> HD64461_LCDLDHNSR_HSW_SHIFT) &			\
    145       1.1   uch 	HD64461_LCDLDHNSR_HSW_MASK)
    146       1.1   uch #define HD64461_LCDLDHNSR_HSW_SET(cr, val)				\
    147       1.1   uch 	((cr) | (((val) << HD64461_LCDLDHNSR_HSW_SHIFT) &		\
    148       1.1   uch 	(HD64461_LCDLDHNSR_HSW_MASK << HD64461_LCDLDHNSR_HSW_SHIFT)))
    149       1.1   uch #define HD64461_LCDLDHNSR_HSP_SHIFT		0
    150       1.1   uch #define HD64461_LCDLDHNSR_HSP_MASK		0xff
    151       1.1   uch #define HD64461_LCDLDHNSR_HSP(cr)					\
    152       1.1   uch 	(((cr) >> HD64461_LCDLDHNSR_HSP_SHIFT) &			\
    153       1.1   uch 	HD64461_LCDLDHNSR_HSP_MASK)
    154       1.1   uch #define HD64461_LCDLDHNSR_HSP_SET(cr, val)				\
    155       1.1   uch 	((cr) | (((val) << HD64461_LCDLDHNSR_HSP_SHIFT) &		\
    156       1.1   uch 	(HD64461_LCDLDHNSR_HSP_MASK << HD64461_LCDLDHNSR_HSP_SHIFT)))
    157       1.1   uch 
    158       1.1   uch /* Total Vertical Lines Register */
    159       1.1   uch #define HD64461_LCDLDVNTR_REG16			0xb0001018
    160       1.1   uch #define HD64461_LCDLDVNTR_VTL_SHIFT		0
    161       1.1   uch #define HD64461_LCDLDVNTR_VTL_MASK		0x3ff
    162       1.1   uch #define HD64461_LCDLDVNTR_VTL(cr)					\
    163       1.1   uch 	(((cr) >> HD64461_LCDLDVNTR_VTL_SHIFT) &			\
    164       1.1   uch 	HD64461_LCDLDVNTR_VTL_MASK)
    165       1.1   uch #define HD64461_LCDLDVNTR_VTL_SET(cr, val)				\
    166       1.1   uch 	((cr) | (((val) << HD64461_LCDLDVNTR_VTL_SHIFT) &		\
    167       1.1   uch 	(HD64461_LCDLDVNTR_VTL_MASK << HD64461_LCDLDVNTR_VTL_SHIFT)))
    168       1.1   uch 
    169       1.1   uch /* Display Vertical Lines Register */
    170       1.1   uch #define HD64461_LCDLDVNDR_REG16			0xb000101a
    171       1.1   uch #define HD64461_LCDLDVNDR_VDL_SHIFT		0
    172       1.1   uch #define HD64461_LCDLDVNDR_VDL_MASK		0x3ff
    173       1.1   uch #define HD64461_LCDLDVNDR_VDL(cr)					\
    174       1.1   uch 	(((cr) >> HD64461_LCDLDVNDR_VDL_SHIFT) &			\
    175       1.1   uch 	HD64461_LCDLDVNDR_VDL_MASK)
    176       1.1   uch #define HD64461_LCDLDVNDR_VDL_SET(cr, val)				\
    177       1.1   uch 	((cr) | (((val) << HD64461_LCDLDVNDR_VDL_SHIFT) &		\
    178       1.1   uch 	(HD64461_LCDLDVNDR_VDL_MASK << HD64461_LCDLDVNDR_VDL_SHIFT)))
    179       1.1   uch 
    180       1.1   uch /* Vertical Synchronization Position Register */
    181       1.1   uch #define HD64461_LCDLDVSPR_REG16			0xb000101c
    182       1.1   uch #define HD64461_LCDLDVSPR_VSP_SHIFT		0
    183       1.1   uch #define HD64461_LCDLDVSPR_VSP_MASK		0x3ff
    184       1.1   uch #define HD64461_LCDLDVSPR_VSP(cr)					\
    185       1.1   uch 	((cr) &	HD64461_LCDLDVSPR_VSP_MASK)
    186       1.1   uch #define HD64461_LCDLDVSPR_VSP_SET(cr, val)				\
    187       1.1   uch 	((cr) | ((val) & HD64461_LCDLDVSPR_VSP_MASK))
    188       1.1   uch 
    189       1.1   uch /*
    190       1.1   uch  * CRT Control Register
    191       1.1   uch  */
    192       1.1   uch /* CRTC Total Vertical Lines Register */
    193       1.1   uch #define HD64461_LCDCRTVTR_REG16			0xb0001020
    194       1.1   uch #define HD64461_LCDCRTVTR_SHIFT		0
    195       1.1   uch #define HD64461_LCDCRTVTR_MASK		0x3ff
    196       1.1   uch #define HD64461_LCDCRTVTR(cr)						\
    197       1.1   uch 	(((cr) >> HD64461_LCDCRTVTR_SHIFT) &				\
    198       1.1   uch 	HD64461_LCDCRTVTR_MASK)
    199       1.1   uch #define HD64461_LCDCRTVTR_SET(cr, val)					\
    200       1.1   uch 	((cr) | (((val) << HD64461_LCDCRTVTR_SHIFT) &			\
    201       1.1   uch 	(HD64461_LCDCRTVTR_MASK << HD64461_LCDCRTVTR_SHIFT)))
    202       1.1   uch 
    203       1.1   uch /* CRTC Vertical Retrace Start Register */
    204       1.1   uch #define HD64461_LCDCRTVRSR_REG16		0xb0001022
    205       1.1   uch #define HD64461_LCDCRTVRSR_SHIFT	0
    206       1.1   uch #define HD64461_LCDCRTVRSR_MASK		0x3ff
    207       1.1   uch #define HD64461_LCDCRTVRSR(cr)						\
    208       1.1   uch 	(((cr) >> HD64461_LCDCRTVRSR_SHIFT) &				\
    209       1.1   uch 	HD64461_LCDCRTVRSR_MASK)
    210       1.1   uch #define HD64461_LCDCRTVRSR_SET(cr, val)					\
    211       1.1   uch 	((cr) | (((val) << HD64461_LCDCRTVRSR_SHIFT) &			\
    212       1.1   uch 	(HD64461_LCDCRTVRSR_MASK << HD64461_LCDCRTVRSR_SHIFT)))
    213       1.1   uch 
    214       1.1   uch /* CRTC Vertical Retrace End Register */
    215       1.1   uch #define HD64461_LCDCRTVRER_REG16		0xb0001024
    216       1.1   uch #define HD64461_LCDCRTVRER_SHIFT	0
    217       1.1   uch #define HD64461_LCDCRTVRER_MASK		0xf
    218       1.1   uch #define HD64461_LCDCRTVRER(cr)						\
    219       1.1   uch 	(((cr) >> HD64461_LCDCRTVRER_SHIFT) & HD64461_LCDCRTVRER_MASK)
    220       1.1   uch 
    221       1.1   uch #define HD64461_LCDCRTVRER_SET(cr, val)					\
    222       1.1   uch 	((cr) | (((val) << HD64461_LCDCRTVRER_SHIFT) &			\
    223       1.1   uch 	(HD64461_LCDCRTVRER_MASK << HD64461_LCDCRTVRER_SHIFT)))
    224       1.1   uch 
    225       1.1   uch /*
    226       1.1   uch  * Palette Register
    227       1.1   uch  */
    228       1.1   uch /* Color Palette Write Address Register */
    229       1.1   uch #define HD64461_LCDCPTWAR_REG16			0xb0001030
    230       1.1   uch #define HD64461_LCDCPTWAR_SHIFT		8
    231       1.1   uch #define HD64461_LCDCPTWAR_MASK		0xff
    232       1.1   uch #define HD64461_LCDCPTWAR_SET(cr, val)					\
    233       1.1   uch 	((cr) | (((val) << HD64461_LCDCPTWAR_SHIFT) &			\
    234       1.1   uch 	(HD64461_LCDCPTWAR_MASK << HD64461_LCDCPTWAR_SHIFT)))
    235       1.1   uch 
    236       1.1   uch /* Color Palette Write Data Register */
    237       1.1   uch #define HD64461_LCDCPTWDR_REG16			0xb0001032
    238       1.1   uch #define HD64461_LCDCPTWDR_SHIFT		0
    239       1.1   uch #define HD64461_LCDCPTWDR_MASK		0x3f
    240       1.1   uch #define HD64461_LCDCPTWDR_SET(cr, val)					\
    241       1.1   uch 	((cr) | ((val) & HD64461_LCDCPTWDR_MASK))
    242       1.1   uch 
    243       1.1   uch /* Color Palette READ Address Register */
    244       1.1   uch #define HD64461_LCDCPTRAR_REG16			0xb0001034
    245       1.1   uch #define HD64461_LCDCPTRAR_SHIFT		8
    246       1.1   uch #define HD64461_LCDCPTRAR_MASK		0xff
    247       1.1   uch #define HD64461_LCDCPTRAR_SET(cr, val)					\
    248       1.1   uch 	((cr) | (((val) << HD64461_LCDCPTRAR_SHIFT) &			\
    249       1.1   uch 	(HD64461_LCDCPTRAR_MASK << HD64461_LCDCPTRAR_SHIFT)))
    250       1.1   uch 
    251       1.1   uch /* Color Palette READ Data Register */
    252       1.1   uch #define HD64461_LCDCPTRDR_REG16			0xb0001036
    253       1.1   uch #define HD64461_LCDCPTRDR_SHIFT		0
    254       1.1   uch #define HD64461_LCDCPTRDR_MASK		0x3f
    255       1.1   uch #define HD64461_LCDCPTRDR(cr)	((cr) & HD64461_LCDCPTRDR_MASK)
    256       1.1   uch 
    257       1.1   uch /*
    258       1.1   uch  * Acceleration Common Register
    259       1.1   uch  */
    260       1.1   uch /* Display Resolution Offset Register */
    261       1.1   uch #define HD64461_LCDGRDOR_REG16			0xb0001040
    262       1.1   uch #define HD64461_LCDGRDOR_SHIFT		0
    263       1.1   uch #define HD64461_LCDGRDOR_MASK		0x7ff
    264       1.1   uch #define HD64461_LCDGRDOR(cr)						\
    265       1.1   uch 	(((cr) >> HD64461_LCDGRDOR_SHIFT) &				\
    266       1.1   uch 	HD64461_LCDGRDOR_MASK)
    267       1.1   uch #define HD64461_LCDGRDOR_SET(cr, val)					\
    268       1.1   uch 	((cr) | (((val) << HD64461_LCDGRDOR_SHIFT) &			\
    269       1.1   uch 	(HD64461_LCDGRDOR_MASK << HD64461_LCDGRDOR_SHIFT)))
    270       1.1   uch 
    271       1.1   uch /* Solid Color Register */
    272       1.1   uch #define HD64461_LCDGRSCR_REG16			0xb0001042
    273       1.1   uch 
    274       1.1   uch /* Accelerator Configuration Register */
    275       1.1   uch #define HD64461_LCDGRCFGR_REG16			0xb0001044
    276       1.1   uch #define HD64461_LCDGRCFGR_ACCSTATUS		0x0010
    277       1.1   uch #define HD64461_LCDGRCFGR_ACCRESET		0x0008
    278       1.1   uch #define HD64461_LCDGRCFGR_ACCSTART_MASK		0x6
    279       1.1   uch #define HD64461_LCDGRCFGR_ACCSTART_BITBLT	0x0006
    280       1.1   uch #define HD64461_LCDGRCFGR_ACCSTART_LINE		0x0004
    281       1.1   uch #define HD64461_LCDGRCFGR_ACCSTART_OFF		0x0000
    282       1.1   uch #define HD64461_LCDGRCFGR_COLORDEPTH_8BPP	0x0001
    283       1.1   uch 
    284       1.1   uch /*
    285       1.1   uch  * Line Drawing Register
    286       1.1   uch  */
    287       1.1   uch /* Line Start Address Register */
    288       1.1   uch #define HD64461_LCDLNSARH_REG16			0xb0001046
    289       1.1   uch #define HD64461_LCDLNSARH_MASK		0x0007
    290       1.1   uch #define HD64461_LCDLNSARL_REG16			0xb0001048
    291       1.1   uch #define HD64461_LCDLNSARL_MASK		0xffff
    292       1.1   uch 
    293       1.1   uch /* Axis Pixel Length Register */
    294       1.1   uch #define HD64461_LCDLNAXLR_REG16			0xb000104a
    295       1.1   uch #define HD64461_LCDLNAXLR_MASK		0x07ff
    296       1.1   uch 
    297       1.1   uch /* Diagonal Regsiter */
    298       1.1   uch #define HD64461_LCDLNDGR_REG16			0xb000104c
    299       1.1   uch #define HD64461_LCDLNDGR_LNDGR_SIGN		0x8000
    300       1.1   uch #define HD64461_LCDLNDGR_LNDGR_MASK	0x07ff
    301       1.1   uch #define HD64461_LCDLNDGR_LNDGR_SET(cr, x)				\
    302       1.1   uch 	((cr) | ((x) & HD64461_LCDLNDGR_LNDGR_MASK))
    303       1.1   uch 
    304       1.1   uch /* Axial Register */
    305       1.1   uch #define HD64461_LCDLNAXR_REG16			0xb000104e
    306       1.1   uch #define HD64461_LCDLNAXR_LNAXR_MASK	0x0fff
    307       1.1   uch #define HD64461_LCDLNAXR_LNAXR_SET(cr, x)				\
    308       1.1   uch 	((cr) | ((x) & HD64461_LCDLNAXR_LNAXR_MASK))
    309       1.1   uch 
    310       1.1   uch /* Start Error Term Register */
    311       1.1   uch #define HD64461_LCDLNERTR_REG16			0xb0001050
    312       1.1   uch #define HD64461_LCDLNERTR_LNERTR_SIGN		0x8000
    313       1.1   uch #define HD64461_LCDLNERTR_LNERTR_MASK	0x07ff
    314       1.1   uch #define HD64461_LCDLNERTR_LNERTR_SET(cr, x)				\
    315       1.1   uch 	((cr) | ((x) & HD64461_LCDLNERTR_LNERTR_MASK))
    316       1.1   uch 
    317       1.1   uch /* Line Mode Register */
    318       1.1   uch #define HD64461_LCDLNMDR_REG16			0xb0001052
    319       1.1   uch #define HD64461_LCDLNMDR_MASK		0x0003
    320       1.1   uch /*
    321       1.1   uch  *    2  1
    322       1.1   uch  *  3      0
    323       1.1   uch  *  4      7
    324       1.1   uch  *    5  6
    325       1.1   uch  *
    326       1.1   uch  * 1 or 5 ... 3
    327       1.1   uch  * 2 or 6 ... 2
    328       1.1   uch  * 0 or 4 ... 1
    329       1.1   uch  * 3 or 7 ... 0
    330       1.1   uch  */
    331       1.1   uch 
    332       1.1   uch /*
    333       1.1   uch  * BitBLT Register
    334       1.1   uch  */
    335       1.1   uch /* Source Start Address Register (19 bit) */
    336       1.1   uch #define HD64461_LCDBBTSSARH_REG16		0xb0001054
    337       1.1   uch #define HD64461_LCDBBTSSARH_SHIFT	16
    338       1.1   uch #define HD64461_LCDBBTSSARH_MASK	0x0007
    339       1.1   uch #define HD64461_LCDBBTSSARL_REG16		0xb0001056
    340       1.1   uch #define HD64461_LCDBBTSSARL_MASK	0xffff
    341       1.1   uch #define HD64461_LCDBBTSSARH(x)						\
    342       1.1   uch 	(((x) >> HD64461_LCDBBTSSARH_SHIFT) & HD64461_LCDBBTSSARH_MASK)
    343       1.1   uch #define HD64461_LCDBBTSSARL(x)	((x) & HD64461_LCDBBTSSARL_MASK)
    344       1.1   uch 
    345       1.1   uch /* Destination Start Address Register (19 bit) */
    346       1.1   uch #define HD64461_LCDBBTDSARH_REG16		0xb0001058
    347       1.1   uch #define HD64461_LCDBBTDSARH_SHIFT	16
    348       1.1   uch #define HD64461_LCDBBTDSARH_MASK	0x0007
    349       1.1   uch #define HD64461_LCDBBTDSARL_REG16		0xb000105a
    350       1.1   uch #define HD64461_LCDBBTDSARL_MASK	0xffff
    351       1.1   uch #define HD64461_LCDBBTDSARH(x)						\
    352       1.1   uch 	(((x) >> HD64461_LCDBBTSSARH_SHIFT) & HD64461_LCDBBTSSARH_MASK)
    353       1.1   uch #define HD64461_LCDBBTDSARL(x)	((x) & HD64461_LCDBBTSSARL_MASK)
    354       1.1   uch 
    355       1.1   uch /* Destination Block Width Register */
    356       1.1   uch #define HD64461_LCDBBTDWR_REG16			0xb000105c
    357       1.1   uch #define HD64461_LCDBBTDWR_MASK		0x07ff
    358       1.1   uch 
    359       1.1   uch /* Destination Block Height Register */
    360       1.1   uch #define HD64461_LCDBBTDHR_REG16			0xb000105e
    361       1.1   uch #define HD64461_LCDBBTDHR_MASK		0x07ff
    362       1.1   uch 
    363       1.1   uch /* Pattern Start Address Register (19 bit) */
    364       1.1   uch #define HD64461_LCDBBTPARH_REG16		0xb0001060
    365       1.1   uch #define HD64461_LCDBBTPARH_MASK		0x0007
    366       1.1   uch #define HD64461_LCDBBTPARL_REG16		0xb0001062
    367       1.1   uch 
    368       1.1   uch /* Mask Start Address Register (19 bit) */
    369       1.1   uch #define HD64461_LCDBBTMARH_REG16		0xb0001064
    370       1.1   uch #define HD64461_LCDBBTMARH_MASK		0x0007
    371       1.1   uch #define HD64461_LCDBBTMARL_REG16		0xb0001066
    372       1.1   uch 
    373       1.1   uch /* ROP Register */
    374       1.1   uch #define HD64461_LCDBBTROPR_REG16		0xb0001068
    375       1.1   uch 
    376       1.1   uch /* BitBLT Mode Register */
    377       1.1   uch #define HD64461_LCDBBTMDR_REG16			0xb000106a
    378       1.1   uch #define HD64461_LCDBBTMDR_MASKENABLE		0x0020
    379       1.1   uch #define HD64461_LCDBBTMDR_PATSELECT_SOLIDCOLOR	0x0010
    380       1.1   uch #define HD64461_LCDBBTMDR_SHIFT		2
    381       1.1   uch #define HD64461_LCDBBTMDR_MASK		0x3
    382       1.1   uch #define HD64461_LCDBBTMDR(cr)						\
    383       1.1   uch 	(((cr) >> HD64461_LCDBBTMDR_SHIFT) & HD64461_LCDBBTMDR_MASK)
    384       1.1   uch 
    385       1.1   uch #define HD64461_LCDBBTMDR_SET(cr, val)					\
    386       1.1   uch 	((cr) | (((val) << HD64461_LCDBBTMDR_SHIFT) &			\
    387       1.1   uch 	(HD64461_LCDBBTMDR_MASK << HD64461_LCDBBTMDR_SHIFT)))
    388       1.1   uch #define HD64461_LCDBBTMDR_ON_SCREEN_TO_ON_SCREEN	0
    389       1.1   uch #define HD64461_LCDBBTMDR_ON_SCREEN_TO_OFF_SCREEN	1
    390       1.1   uch #define HD64461_LCDBBTMDR_OFF_SCREEN_TO_ON_SCREEN	3
    391       1.1   uch 
    392       1.1   uch #define HD64461_LCDBBTMDR_SCANDRCT	0x0001
    393       1.1   uch #define HD64461_LCDBBTMDR_SCANDRCT_RL_BT	0x1
    394       1.1   uch #define HD64461_LCDBBTMDR_SCANDRCT_LR_TB	0x0
    395       1.1   uch 
    396       1.1   uch /*
    397       1.1   uch  * BitBLT Function
    398       1.1   uch  */
    399       1.1   uch #define HD64461_LCDC_BITBLT_SRCAND		0x0088
    400       1.1   uch #define HD64461_LCDC_BITBLT_SRCCOPY		0x00cc
    401       1.1   uch #define HD64461_LCDC_BITBLT_SRCINVERT		0x0066
    402       1.1   uch #define HD64461_LCDC_BITBLT_SRCPAINT		0x00ee
    403       1.1   uch #define HD64461_LCDC_BITBLT_PATCOPY		0x00f0
    404       1.1   uch #define HD64461_LCDC_BITBLT_PATINVERT		0x005a
    405       1.1   uch #define HD64461_LCDC_BITBLT_DSTINVERT		0x0055
    406       1.1   uch #define HD64461_LCDC_BITBLT_BLACKNESS		0x0000
    407       1.1   uch #define HD64461_LCDC_BITBLT_WHITENESS		0x00ff
    408       1.1   uch #define HD64461_LCDC_BITBLT_MASKEDSRCCOPY	0xccaa
    409       1.2   uwe 
    410       1.2   uwe #endif /* !_HPCSH_DEV_HD64461VIDEOREG_H_ */
    411