• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #ifndef _LINUX_XGIFB
2 #define _LINUX_XGIFB
3 #include "vgatypes.h"
4 #include "vb_struct.h"
5 
6 enum xgifb_display_type {
7 	XGIFB_DISP_NONE = 0,
8 	XGIFB_DISP_CRT,
9 	XGIFB_DISP_LCD,
10 	XGIFB_DISP_TV,
11 };
12 
13 #define HASVB_NONE	    0x00
14 #define HASVB_301	    0x01
15 #define HASVB_LVDS	    0x02
16 #define HASVB_TRUMPION	    0x04
17 #define HASVB_LVDS_CHRONTEL 0x10
18 #define HASVB_302	    0x20
19 #define HASVB_CHRONTEL	    0x80
20 
21 enum XGI_CHIP_TYPE {
22 	XG40 = 32,
23 	XG42,
24 	XG20 = 48,
25 	XG21,
26 	XG27,
27 };
28 
29 enum xgi_tvtype {
30 	TVMODE_NTSC = 0,
31 	TVMODE_PAL,
32 	TVMODE_HIVISION,
33 	TVTYPE_PALM,
34 	TVTYPE_PALN,
35 	TVTYPE_NTSCJ,
36 	TVMODE_TOTAL
37 };
38 
39 enum xgi_tv_plug {
40 	TVPLUG_UNKNOWN = 0,
41 	TVPLUG_COMPOSITE = 1,
42 	TVPLUG_SVIDEO = 2,
43 	TVPLUG_COMPOSITE_AND_SVIDEO = 3,
44 	TVPLUG_SCART = 4,
45 	TVPLUG_YPBPR_525i = 5,
46 	TVPLUG_YPBPR_525P = 6,
47 	TVPLUG_YPBPR_750P = 7,
48 	TVPLUG_YPBPR_1080i = 8,
49 	TVPLUG_TOTAL
50 };
51 
52 struct xgifb_video_info {
53 	struct fb_info *fb_info;
54 	struct xgi_hw_device_info hw_info;
55 	struct vb_device_info dev_info;
56 
57 	int mode_idx;
58 	int rate_idx;
59 
60 	u32 pseudo_palette[17];
61 
62 	int           chip_id;
63 	unsigned int  video_size;
64 	phys_addr_t   video_base;
65 	void __iomem *video_vbase;
66 	phys_addr_t   mmio_base;
67 	unsigned long mmio_size;
68 	void __iomem *mmio_vbase;
69 	unsigned long vga_base;
70 	int mtrr;
71 
72 	int    video_bpp;
73 	int    video_cmap_len;
74 	int    video_width;
75 	int    video_height;
76 	int    video_vwidth;
77 	int    video_vheight;
78 	int    org_x;
79 	int    org_y;
80 	int    video_linelength;
81 	unsigned int refresh_rate;
82 
83 	enum xgifb_display_type display2; /* the second display output type */
84 	bool display2_force;
85 	unsigned char hasVB;
86 	unsigned char TV_type;
87 	unsigned char TV_plug;
88 
89 	struct XGI21_LVDSCapStruct lvds_data;
90 
91 	enum XGI_CHIP_TYPE chip;
92 	unsigned char revision_id;
93 
94 	unsigned short DstColor;
95 	unsigned long  XGI310_AccelDepth;
96 	unsigned long  CommandReg;
97 
98 	unsigned int   pcibus;
99 	unsigned int   pcislot;
100 	unsigned int   pcifunc;
101 
102 	unsigned short subsysvendor;
103 	unsigned short subsysdevice;
104 
105 	char reserved[236];
106 };
107 
108 #endif
109