• Home
  • History
  • Annotate
  • Line#
  • Navigate
  • Raw
  • Download
  • only in /asuswrt-rt-n18u-9.0.0.4.380.2695/release/src-rt-6.x.4708/linux/linux-2.6/drivers/staging/xgifb/
1
2#ifndef _VGATYPES_
3#define _VGATYPES_
4
5#include <linux/ioctl.h>
6
7#ifndef VBIOS_VER_MAX_LENGTH
8#define VBIOS_VER_MAX_LENGTH    5
9#endif
10
11#ifndef XGI_VB_CHIP_TYPE
12enum XGI_VB_CHIP_TYPE {
13    VB_CHIP_Legacy = 0,
14    VB_CHIP_301,
15    VB_CHIP_301B,
16    VB_CHIP_301LV,
17    VB_CHIP_302,
18    VB_CHIP_302B,
19    VB_CHIP_302LV,
20    VB_CHIP_301C,
21    VB_CHIP_302ELV,
22    VB_CHIP_UNKNOWN, /* other video bridge or no video bridge */
23    MAX_VB_CHIP
24};
25#endif
26
27#ifndef XGI_LCD_TYPE
28enum XGI_LCD_TYPE {
29    LCD_INVALID = 0,
30    LCD_320x480,       /* FSTN, DSTN */
31    LCD_640x480,
32    LCD_640x480_2,     /* FSTN, DSTN */
33    LCD_640x480_3,     /* FSTN, DSTN */
34    LCD_800x600,
35    LCD_848x480,
36    LCD_1024x600,
37    LCD_1024x768,
38    LCD_1152x768,
39    LCD_1152x864,
40    LCD_1280x720,
41    LCD_1280x768,
42    LCD_1280x800,
43    LCD_1280x960,
44    LCD_1280x1024,
45    LCD_1400x1050,
46    LCD_1600x1200,
47    LCD_1680x1050,
48    LCD_1920x1440,
49    LCD_2048x1536,
50    LCD_CUSTOM,
51    LCD_UNKNOWN
52};
53#endif
54
55struct XGI_DSReg
56{
57  unsigned char  jIdx;
58  unsigned char  jVal;
59};
60
61struct xgi_hw_device_info
62{
63    unsigned long  ulExternalChip;       /* NO VB or other video bridge*/
64                                 /* if ujVBChipID = VB_CHIP_UNKNOWN, */
65
66    unsigned char *pjVirtualRomBase;    /* ROM image */
67
68    unsigned char UseROM;		 /* Use the ROM image if provided */
69
70    void *pDevice;
71
72    unsigned char *pjVideoMemoryAddress;/* base virtual memory address */
73                                 /* of Linear VGA memory */
74
75    unsigned long  ulVideoMemorySize;    /* size, in bytes, of the memory on the board */
76
77    unsigned char *pjIOAddress;          /* base I/O address of VGA ports (0x3B0) */
78
79    unsigned char *pjCustomizedROMImage;
80
81    unsigned char *pj2ndVideoMemoryAddress;
82    unsigned long  ul2ndVideoMemorySize;
83
84    unsigned char *pj2ndIOAddress;
85    unsigned char  jChipType;            /* Used to Identify Graphics Chip */
86                                 /* defined in the data structure type  */
87                                 /* "XGI_CHIP_TYPE" */
88
89    unsigned char  jChipRevision;        /* Used to Identify Graphics Chip Revision */
90
91    unsigned char  ujVBChipID;           /* the ID of video bridge */
92                                 /* defined in the data structure type */
93                                 /* "XGI_VB_CHIP_TYPE" */
94
95    unsigned char    bNewScratch;
96
97    unsigned long  ulCRT2LCDType;        /* defined in the data structure type */
98
99    unsigned long usExternalChip;       /* NO VB or other video bridge (other than  */
100                                 /*  video bridge) */
101
102    unsigned char bIntegratedMMEnabled;/* supporting integration MM enable */
103
104    unsigned char bSkipDramSizing;     /* True: Skip video memory sizing. */
105
106    unsigned char bSkipSense;
107
108    unsigned char bIsPowerSaving;     /* True: XGIInit() is invoked by power management,
109                                   otherwise by 2nd adapter's initialzation */
110
111    struct XGI_DSReg  *pSR;             /* restore SR registers in initial function. */
112                                 /* end data :(idx, val) =  (FF, FF). */
113                                 /* Note : restore SR registers if  */
114                                 /* bSkipDramSizing = 1 */
115
116    struct XGI_DSReg  *pCR;             /* restore CR registers in initial function. */
117                                 /* end data :(idx, val) =  (FF, FF) */
118                                 /* Note : restore cR registers if  */
119                                 /* bSkipDramSizing = 1 */
120
121	unsigned char(*pQueryVGAConfigSpace)(struct xgi_hw_device_info *,
122					    unsigned long, unsigned long,
123					    unsigned long *);
124
125	unsigned char(*pQueryNorthBridgeSpace)(struct xgi_hw_device_info *,
126					      unsigned long, unsigned long,
127					      unsigned long *);
128
129    unsigned char szVBIOSVer[VBIOS_VER_MAX_LENGTH];
130
131};
132
133/* Addtional IOCTL for communication xgifb <> X driver        */
134/* If changing this, xgifb.h must also be changed (for xgifb) */
135
136
137#endif
138