Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus
[linux-btrfs-devel.git] / drivers / staging / xgifb / vb_struct.h
blob377d27c0c332f4faff64f5cbd944c48547044e3d
1 #ifndef _VB_STRUCT_
2 #define _VB_STRUCT_
4 #ifdef _INITNEW_
5 #define EXTERN
6 #else
7 #define EXTERN extern
8 #endif
10 struct XGI_PanelDelayTblStruct {
11 unsigned char timer[2];
14 struct XGI_LCDDataStruct {
15 unsigned short RVBHCMAX;
16 unsigned short RVBHCFACT;
17 unsigned short VGAHT;
18 unsigned short VGAVT;
19 unsigned short LCDHT;
20 unsigned short LCDVT;
24 struct XGI_LVDSCRT1HDataStruct {
25 unsigned char Reg[8];
28 struct XGI_LVDSCRT1VDataStruct {
29 unsigned char Reg[7];
32 struct XGI_TVDataStruct {
33 unsigned short RVBHCMAX;
34 unsigned short RVBHCFACT;
35 unsigned short VGAHT;
36 unsigned short VGAVT;
37 unsigned short TVHDE;
38 unsigned short TVVDE;
39 unsigned short RVBHRS;
40 unsigned char FlickerMode;
41 unsigned short HALFRVBHRS;
42 unsigned char RY1COE;
43 unsigned char RY2COE;
44 unsigned char RY3COE;
45 unsigned char RY4COE;
48 struct XGI_LVDSDataStruct {
49 unsigned short VGAHT;
50 unsigned short VGAVT;
51 unsigned short LCDHT;
52 unsigned short LCDVT;
55 struct XGI_LVDSDesStruct {
56 unsigned short LCDHDES;
57 unsigned short LCDVDES;
60 struct XGI_LVDSCRT1DataStruct {
61 unsigned char CR[15];
64 /*add for LCDA*/
66 struct XGI_StStruct {
67 unsigned char St_ModeID;
68 unsigned short St_ModeFlag;
69 unsigned char St_StTableIndex;
70 unsigned char St_CRT2CRTC;
71 unsigned char St_CRT2CRTC2;
72 unsigned char St_ResInfo;
73 unsigned char VB_StTVFlickerIndex;
74 unsigned char VB_StTVEdgeIndex;
75 unsigned char VB_StTVYFilterIndex;
78 struct XGI_StandTableStruct {
79 unsigned char CRT_COLS;
80 unsigned char ROWS;
81 unsigned char CHAR_HEIGHT;
82 unsigned short CRT_LEN;
83 unsigned char SR[4];
84 unsigned char MISC;
85 unsigned char CRTC[0x19];
86 unsigned char ATTR[0x14];
87 unsigned char GRC[9];
90 struct XGI_ExtStruct {
91 unsigned char Ext_ModeID;
92 unsigned short Ext_ModeFlag;
93 unsigned short Ext_ModeInfo;
94 unsigned short Ext_Point;
95 unsigned short Ext_VESAID;
96 unsigned char Ext_VESAMEMSize;
97 unsigned char Ext_RESINFO;
98 unsigned char VB_ExtTVFlickerIndex;
99 unsigned char VB_ExtTVEdgeIndex;
100 unsigned char VB_ExtTVYFilterIndex;
101 unsigned char REFindex;
104 struct XGI_Ext2Struct {
105 unsigned short Ext_InfoFlag;
106 unsigned char Ext_CRT1CRTC;
107 unsigned char Ext_CRTVCLK;
108 unsigned char Ext_CRT2CRTC;
109 unsigned char Ext_CRT2CRTC2;
110 unsigned char ModeID;
111 unsigned short XRes;
112 unsigned short YRes;
113 /* unsigned short ROM_OFFSET; */
117 struct XGI_MCLKDataStruct {
118 unsigned char SR28, SR29, SR2A;
119 unsigned short CLOCK;
122 struct XGI_ECLKDataStruct {
123 unsigned char SR2E, SR2F, SR30;
124 unsigned short CLOCK;
127 struct XGI_VCLKDataStruct {
128 unsigned char SR2B, SR2C;
129 unsigned short CLOCK;
132 struct XGI_VBVCLKDataStruct {
133 unsigned char Part4_A, Part4_B;
134 unsigned short CLOCK;
137 struct XGI_StResInfoStruct {
138 unsigned short HTotal;
139 unsigned short VTotal;
142 struct XGI_ModeResInfoStruct {
143 unsigned short HTotal;
144 unsigned short VTotal;
145 unsigned char XChar;
146 unsigned char YChar;
149 struct XGI_LCDNBDesStruct {
150 unsigned char NB[12];
153 /*add for new UNIVGABIOS*/
154 struct XGI_LCDDesStruct {
155 unsigned short LCDHDES;
156 unsigned short LCDHRS;
157 unsigned short LCDVDES;
158 unsigned short LCDVRS;
161 struct XGI_LCDDataTablStruct {
162 unsigned char PANELID;
163 unsigned short MASK;
164 unsigned short CAP;
165 unsigned short DATAPTR;
168 struct XGI_TVTablDataStruct {
169 unsigned short MASK;
170 unsigned short CAP;
171 unsigned short DATAPTR;
174 struct XGI330_LCDDataDesStruct {
175 unsigned short LCDHDES;
176 unsigned short LCDHRS;
177 unsigned short LCDVDES;
178 unsigned short LCDVRS;
182 struct XGI330_LVDSDataStruct {
183 unsigned short VGAHT;
184 unsigned short VGAVT;
185 unsigned short LCDHT;
186 unsigned short LCDVT;
189 struct XGI330_LCDDataDesStruct2 {
190 unsigned short LCDHDES;
191 unsigned short LCDHRS;
192 unsigned short LCDVDES;
193 unsigned short LCDVRS;
194 unsigned short LCDHSync;
195 unsigned short LCDVSync;
198 struct XGI330_LCDDataStruct {
199 unsigned short RVBHCMAX;
200 unsigned short RVBHCFACT;
201 unsigned short VGAHT;
202 unsigned short VGAVT;
203 unsigned short LCDHT;
204 unsigned short LCDVT;
208 struct XGI330_TVDataStruct {
209 unsigned short RVBHCMAX;
210 unsigned short RVBHCFACT;
211 unsigned short VGAHT;
212 unsigned short VGAVT;
213 unsigned short TVHDE;
214 unsigned short TVVDE;
215 unsigned short RVBHRS;
216 unsigned char FlickerMode;
217 unsigned short HALFRVBHRS;
220 struct XGI330_LCDDataTablStruct {
221 unsigned char PANELID;
222 unsigned short MASK;
223 unsigned short CAP;
224 unsigned short DATAPTR;
227 struct XGI330_TVDataTablStruct {
228 unsigned short MASK;
229 unsigned short CAP;
230 unsigned short DATAPTR;
234 struct XGI330_CHTVDataStruct {
235 unsigned short VGAHT;
236 unsigned short VGAVT;
237 unsigned short LCDHT;
238 unsigned short LCDVT;
241 struct XGI_TimingHStruct {
242 unsigned char data[8];
245 struct XGI_TimingVStruct {
246 unsigned char data[7];
249 struct XGI_CH7007TV_TimingHStruct {
250 unsigned char data[10];
253 struct XGI_CH7007TV_TimingVStruct {
254 unsigned char data[10];
257 struct XGI_XG21CRT1Struct {
258 unsigned char ModeID, CR02, CR03, CR15, CR16;
261 struct XGI330_CHTVRegDataStruct {
262 unsigned char Reg[16];
265 struct XGI330_LCDCapStruct {
266 unsigned char LCD_ID;
267 unsigned short LCD_Capability;
268 unsigned char LCD_SetFlag;
269 unsigned char LCD_DelayCompensation;
270 unsigned char LCD_HSyncWidth;
271 unsigned char LCD_VSyncWidth;
272 unsigned char LCD_VCLK;
273 unsigned char LCDA_VCLKData1;
274 unsigned char LCDA_VCLKData2;
275 unsigned char LCUCHAR_VCLKData1;
276 unsigned char LCUCHAR_VCLKData2;
277 unsigned char PSC_S1;
278 unsigned char PSC_S2;
279 unsigned char PSC_S3;
280 unsigned char PSC_S4;
281 unsigned char PSC_S5;
282 unsigned char PWD_2B;
283 unsigned char PWD_2C;
284 unsigned char PWD_2D;
285 unsigned char PWD_2E;
286 unsigned char PWD_2F;
287 unsigned char Spectrum_31;
288 unsigned char Spectrum_32;
289 unsigned char Spectrum_33;
290 unsigned char Spectrum_34;
293 struct XGI21_LVDSCapStruct {
294 unsigned short LVDS_Capability;
295 unsigned short LVDSHT;
296 unsigned short LVDSVT;
297 unsigned short LVDSHDE;
298 unsigned short LVDSVDE;
299 unsigned short LVDSHFP;
300 unsigned short LVDSVFP;
301 unsigned short LVDSHSYNC;
302 unsigned short LVDSVSYNC;
303 unsigned char VCLKData1;
304 unsigned char VCLKData2;
305 unsigned char PSC_S1;
306 unsigned char PSC_S2;
307 unsigned char PSC_S3;
308 unsigned char PSC_S4;
309 unsigned char PSC_S5;
312 struct XGI_CRT1TableStruct {
313 unsigned char CR[16];
317 struct XGI330_VCLKDataStruct {
318 unsigned char SR2B, SR2C;
319 unsigned short CLOCK;
322 struct XGI301C_Tap4TimingStruct {
323 unsigned short DE;
324 unsigned char Reg[64]; /* C0-FF */
327 struct XGI_New_StandTableStruct {
328 unsigned char CRT_COLS;
329 unsigned char ROWS;
330 unsigned char CHAR_HEIGHT;
331 unsigned short CRT_LEN;
332 unsigned char SR[4];
333 unsigned char MISC;
334 unsigned char CRTC[0x19];
335 unsigned char ATTR[0x14];
336 unsigned char GRC[9];
339 struct vb_device_info {
340 unsigned char ISXPDOS;
341 unsigned long P3c4, P3d4, P3c0, P3ce, P3c2, P3cc;
342 unsigned long P3ca, P3c6, P3c7, P3c8, P3c9, P3da;
343 unsigned long Part0Port, Part1Port, Part2Port;
344 unsigned long Part3Port, Part4Port, Part5Port;
345 unsigned short RVBHCFACT, RVBHCMAX, RVBHRS;
346 unsigned short VGAVT, VGAHT, VGAVDE, VGAHDE;
347 unsigned short VT, HT, VDE, HDE;
348 unsigned short LCDHRS, LCDVRS, LCDHDES, LCDVDES;
350 unsigned short ModeType;
351 /* ,IF_DEF_FSTN; add for dstn */
352 unsigned short IF_DEF_LVDS, IF_DEF_TRUMPION, IF_DEF_DSTN;
353 unsigned short IF_DEF_CRT2Monitor, IF_DEF_VideoCapture;
354 unsigned short IF_DEF_LCDA, IF_DEF_CH7017, IF_DEF_YPbPr,
355 IF_DEF_ScaleLCD, IF_DEF_OEMUtil, IF_DEF_PWD;
356 unsigned short IF_DEF_ExpLink;
357 unsigned short IF_DEF_CH7005, IF_DEF_HiVision;
358 unsigned short IF_DEF_CH7007; /* Billy 2007/05/03 */
359 unsigned short LCDResInfo, LCDTypeInfo, VBType;/*301b*/
360 unsigned short VBInfo, TVInfo, LCDInfo, Set_VGAType;
361 unsigned short VBExtInfo;/*301lv*/
362 unsigned short SetFlag;
363 unsigned short NewFlickerMode;
364 unsigned short SelectCRT2Rate;
366 unsigned char *ROMAddr;
367 unsigned char *FBAddr;
368 unsigned long BaseAddr;
369 unsigned long RelIO;
371 unsigned char (*CR6B)[4];
372 unsigned char (*CR6E)[4];
373 unsigned char (*CR6F)[32];
374 unsigned char (*CR89)[2];
376 unsigned char (*SR15)[8];
377 unsigned char (*CR40)[8];
379 unsigned char *pSoftSetting;
380 unsigned char *pOutputSelect;
382 unsigned short *pRGBSenseData;
383 unsigned short *pRGBSenseData2; /*301b*/
384 unsigned short *pVideoSenseData;
385 unsigned short *pVideoSenseData2;
386 unsigned short *pYCSenseData;
387 unsigned short *pYCSenseData2;
389 unsigned char *pSR07;
390 unsigned char *CR49;
391 unsigned char *pSR1F;
392 unsigned char *AGPReg;
393 unsigned char *SR16;
394 unsigned char *pSR21;
395 unsigned char *pSR22;
396 unsigned char *pSR23;
397 unsigned char *pSR24;
398 unsigned char *SR25;
399 unsigned char *pSR31;
400 unsigned char *pSR32;
401 unsigned char *pSR33;
402 unsigned char *pSR36; /* alan 12/07/2006 */
403 unsigned char *pCRCF;
404 unsigned char *pCRD0; /* alan 12/07/2006 */
405 unsigned char *pCRDE; /* alan 12/07/2006 */
406 unsigned char *pCR8F; /* alan 12/07/2006 */
407 unsigned char *pSR40; /* alan 12/07/2006 */
408 unsigned char *pSR41; /* alan 12/07/2006 */
409 unsigned char *pDVOSetting;
410 unsigned char *pCR2E;
411 unsigned char *pCR2F;
412 unsigned char *pCR46;
413 unsigned char *pCR47;
414 unsigned char *pCRT2Data_1_2;
415 unsigned char *pCRT2Data_4_D;
416 unsigned char *pCRT2Data_4_E;
417 unsigned char *pCRT2Data_4_10;
418 struct XGI_MCLKDataStruct *MCLKData;
419 struct XGI_ECLKDataStruct *ECLKData;
421 unsigned char *XGI_TVDelayList;
422 unsigned char *XGI_TVDelayList2;
423 unsigned char *CHTVVCLKUNTSC;
424 unsigned char *CHTVVCLKONTSC;
425 unsigned char *CHTVVCLKUPAL;
426 unsigned char *CHTVVCLKOPAL;
427 unsigned char *NTSCTiming;
428 unsigned char *PALTiming;
429 unsigned char *HiTVExtTiming;
430 unsigned char *HiTVSt1Timing;
431 unsigned char *HiTVSt2Timing;
432 unsigned char *HiTVTextTiming;
433 unsigned char *YPbPr750pTiming;
434 unsigned char *YPbPr525pTiming;
435 unsigned char *YPbPr525iTiming;
436 unsigned char *HiTVGroup3Data;
437 unsigned char *HiTVGroup3Simu;
438 unsigned char *HiTVGroup3Text;
439 unsigned char *Ren525pGroup3;
440 unsigned char *Ren750pGroup3;
441 unsigned char *ScreenOffset;
442 unsigned char *pXGINew_DRAMTypeDefinition;
443 unsigned char *pXGINew_I2CDefinition ;
444 unsigned char *pXGINew_CR97 ;
446 struct XGI330_LCDCapStruct *LCDCapList;
447 struct XGI21_LVDSCapStruct *XG21_LVDSCapList;
449 struct XGI_TimingHStruct *TimingH;
450 struct XGI_TimingVStruct *TimingV;
452 struct XGI_StStruct *SModeIDTable;
453 struct XGI_StandTableStruct *StandTable;
454 struct XGI_ExtStruct *EModeIDTable;
455 struct XGI_Ext2Struct *RefIndex;
456 /* XGINew_CRT1TableStruct *CRT1Table; */
457 struct XGI_CRT1TableStruct *XGINEWUB_CRT1Table;
458 struct XGI_VCLKDataStruct *VCLKData;
459 struct XGI_VBVCLKDataStruct *VBVCLKData;
460 struct XGI_StResInfoStruct *StResInfo;
461 struct XGI_ModeResInfoStruct *ModeResInfo;
462 struct XGI_XG21CRT1Struct *UpdateCRT1;
463 }; /* _struct vb_device_info */
466 struct TimingInfo {
467 unsigned short Horizontal_ACTIVE;
468 unsigned short Horizontal_FP;
469 unsigned short Horizontal_SYNC;
470 unsigned short Horizontal_BP;
471 unsigned short Vertical_ACTIVE;
472 unsigned short Vertical_FP;
473 unsigned short Vertical_SYNC;
474 unsigned short Vertical_BP;
475 double DCLK;
476 unsigned char FrameRate;
477 unsigned char Interlace;
478 unsigned short Margin;
481 #define _VB_STRUCT_
482 #endif /* _VB_STRUCT_ */