brintos

brintos / linux-shallow public Read only

0
0
Text · 4.9 KiB · 91e225a Raw
190 lines · c
1/*2 * linux/include/video/neo_reg.h -- NeoMagic Framebuffer Driver3 *4 * Copyright (c) 2001  Denis Oliver Kropp <dok@convergence.de>5 *6 * This file is subject to the terms and conditions of the GNU General7 * Public License.  See the file COPYING in the main directory of this8 * archive for more details.9 */10 11#define NEO_BS0_BLT_BUSY        0x0000000112#define NEO_BS0_FIFO_AVAIL      0x0000000213#define NEO_BS0_FIFO_PEND       0x0000000414 15#define NEO_BC0_DST_Y_DEC       0x0000000116#define NEO_BC0_X_DEC           0x0000000217#define NEO_BC0_SRC_TRANS       0x0000000418#define NEO_BC0_SRC_IS_FG       0x0000000819#define NEO_BC0_SRC_Y_DEC       0x0000001020#define NEO_BC0_FILL_PAT        0x0000002021#define NEO_BC0_SRC_MONO        0x0000004022#define NEO_BC0_SYS_TO_VID      0x0000008023 24#define NEO_BC1_DEPTH8          0x0000010025#define NEO_BC1_DEPTH16         0x0000020026#define NEO_BC1_X_320           0x0000040027#define NEO_BC1_X_640           0x0000080028#define NEO_BC1_X_800           0x00000c0029#define NEO_BC1_X_1024          0x0000100030#define NEO_BC1_X_1152          0x0000140031#define NEO_BC1_X_1280          0x0000180032#define NEO_BC1_X_1600          0x00001c0033#define NEO_BC1_DST_TRANS       0x0000200034#define NEO_BC1_MSTR_BLT        0x0000400035#define NEO_BC1_FILTER_Z        0x0000800036 37#define NEO_BC2_WR_TR_DST       0x0080000038 39#define NEO_BC3_SRC_XY_ADDR     0x0100000040#define NEO_BC3_DST_XY_ADDR     0x0200000041#define NEO_BC3_CLIP_ON         0x0400000042#define NEO_BC3_FIFO_EN         0x0800000043#define NEO_BC3_BLT_ON_ADDR     0x1000000044#define NEO_BC3_SKIP_MAPPING    0x8000000045 46#define NEO_MODE1_DEPTH8        0x010047#define NEO_MODE1_DEPTH16       0x020048#define NEO_MODE1_DEPTH24       0x030049#define NEO_MODE1_X_320         0x040050#define NEO_MODE1_X_640         0x080051#define NEO_MODE1_X_800         0x0c0052#define NEO_MODE1_X_1024        0x100053#define NEO_MODE1_X_1152        0x140054#define NEO_MODE1_X_1280        0x180055#define NEO_MODE1_X_1600        0x1c0056#define NEO_MODE1_BLT_ON_ADDR   0x200057 58/* These are offseted in MMIO space by par->CursorOff */59#define NEOREG_CURSCNTL		0x0060#define NEOREG_CURSX		0x0461#define NEOREG_CURSY		0x0862#define NEOREG_CURSBGCOLOR	0x0C63#define NEOREG_CURSFGCOLOR	0x1064#define NEOREG_CURSMEMPOS	0x1465 66#define NEO_CURS_DISABLE	0x0000000067#define NEO_CURS_ENABLE		0x0000000168#define NEO_ICON64_ENABLE	0x0000000869#define NEO_ICON128_ENABLE	0x0000000C70#define NEO_ICON_BLANK		0x0000001071 72#define NEO_GR01_SUPPRESS_VSYNC 0x1073#define NEO_GR01_SUPPRESS_HSYNC 0x2074 75#ifdef __KERNEL__76 77#ifdef NEOFB_DEBUG78# define DBG(x)		printk (KERN_DEBUG "neofb: %s\n", (x));79#else80# define DBG(x)81#endif82 83#define PCI_CHIP_NM2070 0x000184#define PCI_CHIP_NM2090 0x000285#define PCI_CHIP_NM2093 0x000386#define PCI_CHIP_NM2097 0x008387#define PCI_CHIP_NM2160 0x000488#define PCI_CHIP_NM2200 0x000589#define PCI_CHIP_NM2230 0x002590#define PCI_CHIP_NM2360 0x000691#define PCI_CHIP_NM2380 0x001692 93/* --------------------------------------------------------------------- */94 95typedef volatile struct {96	__u32 bltStat;97	__u32 bltCntl;98	__u32 xpColor;99	__u32 fgColor;100	__u32 bgColor;101	__u32 pitch;102	__u32 clipLT;103	__u32 clipRB;104	__u32 srcBitOffset;105	__u32 srcStart;106	__u32 reserved0;107	__u32 dstStart;108	__u32 xyExt;109 110	__u32 reserved1[19];111 112	__u32 pageCntl;113	__u32 pageBase;114	__u32 postBase;115	__u32 postPtr;116	__u32 dataPtr;117} Neo2200;118 119#define MMIO_SIZE 0x200000120 121#define NEO_EXT_CR_MAX 0x85122#define NEO_EXT_GR_MAX 0xC7123 124struct neofb_par {125	struct vgastate state;126	unsigned int ref_count;127 128	unsigned char MiscOutReg;	/* Misc */129	unsigned char CRTC[25];		/* Crtc Controller */130	unsigned char Sequencer[5];	/* Video Sequencer */131	unsigned char Graphics[9];	/* Video Graphics */132	unsigned char Attribute[21];	/* Video Attribute */133 134	unsigned char GeneralLockReg;135	unsigned char ExtCRTDispAddr;136	unsigned char ExtCRTOffset;137	unsigned char SysIfaceCntl1;138	unsigned char SysIfaceCntl2;139	unsigned char ExtColorModeSelect;140	unsigned char biosMode;141 142	unsigned char PanelDispCntlReg1;143	unsigned char PanelDispCntlReg2;144	unsigned char PanelDispCntlReg3;145	unsigned char PanelDispCntlRegRead;146	unsigned char PanelVertCenterReg1;147	unsigned char PanelVertCenterReg2;148	unsigned char PanelVertCenterReg3;149	unsigned char PanelVertCenterReg4;150	unsigned char PanelVertCenterReg5;151	unsigned char PanelHorizCenterReg1;152	unsigned char PanelHorizCenterReg2;153	unsigned char PanelHorizCenterReg3;154	unsigned char PanelHorizCenterReg4;155	unsigned char PanelHorizCenterReg5;156 157	int ProgramVCLK;158	unsigned char VCLK3NumeratorLow;159	unsigned char VCLK3NumeratorHigh;160	unsigned char VCLK3Denominator;161	unsigned char VerticalExt;162	int wc_cookie;163	u8 __iomem *mmio_vbase;164	u8 cursorOff;165	u8 *cursorPad;		/* Must die !! */166 167	Neo2200 __iomem *neo2200;168 169	/* Panels size */170	int NeoPanelWidth;171	int NeoPanelHeight;172 173	int maxClock;174 175	int pci_burst;176	int lcd_stretch;177	int internal_display;178	int external_display;179	int libretto;180	u32 palette[16];181};182 183typedef struct {184	int x_res;185	int y_res;186	int mode;187} biosMode;188 189#endif190