]> nv-tegra.nvidia Code Review - linux-2.6.git/blob - include/video/trident.h
9c3670b289062cfd32c2a9ab32a063308a1fc293
[linux-2.6.git] / include / video / trident.h
1
2 #ifndef TRIDENTFB_DEBUG
3 #define TRIDENTFB_DEBUG 0
4 #endif
5
6 #if TRIDENTFB_DEBUG
7 #define debug(f,a...)   printk("%s:" f,  __FUNCTION__ , ## a);mdelay(1000);
8 #else
9 #define debug(f,a...)
10 #endif
11
12 #define output(f, a...) pr_info("tridentfb: " f, ## a)
13
14 #define Kb      (1024)
15 #define Mb      (Kb*Kb)
16
17 /* PCI IDS of supported cards temporarily here */
18
19 #define CYBER9320       0x9320
20 #define CYBER9388       0x9388
21 #define CYBER9382       0x9382          /* the real PCI id for this is 9660 */
22 #define CYBER9385       0x9385          /* ditto */             
23 #define CYBER9397       0x9397
24 #define CYBER9397DVD    0x939A
25 #define CYBER9520       0x9520
26 #define CYBER9525DVD    0x9525
27 #define TGUI9660        0x9660
28 #define IMAGE975        0x9750
29 #define IMAGE985        0x9850
30 #define BLADE3D         0x9880
31 #define CYBERBLADEE4    0x9540
32 #define CYBERBLADEi7    0x8400
33 #define CYBERBLADEi7D   0x8420
34 #define CYBERBLADEi1    0x8500
35 #define CYBERBLADEi1D   0x8520
36 #define CYBERBLADEAi1   0x8600
37 #define CYBERBLADEAi1D  0x8620
38 #define CYBERBLADEXPAi1 0x8820
39 #define CYBERBLADEXPm8  0x9910
40 #define CYBERBLADEXPm16 0x9930
41
42 /* these defines are for 'lcd' variable */
43 #define LCD_STRETCH     0
44 #define LCD_CENTER      1
45 #define LCD_BIOS        2
46
47 /* General Registers */
48 #define SPR     0x1F            /* Software Programming Register (videoram) */
49
50 /* 3C4 */
51 #define RevisionID 0x09
52 #define OldOrNew 0x0B   
53 #define ConfPort1 0x0C
54 #define ConfPort2 0x0C
55 #define NewMode2 0x0D
56 #define NewMode1 0x0E
57 #define Protection 0x11
58 #define MCLKLow 0x16
59 #define MCLKHigh 0x17
60 #define ClockLow 0x18
61 #define ClockHigh 0x19
62 #define SSetup 0x20
63 #define SKey 0x37
64 #define SPKey 0x57
65
66 /* 0x3x4 */
67 #define CRTHTotal       0x00
68 #define CRTHDispEnd     0x01
69 #define CRTHBlankStart  0x02
70 #define CRTHBlankEnd    0x03
71 #define CRTHSyncStart   0x04
72 #define CRTHSyncEnd     0x05
73
74 #define CRTVTotal       0x06
75 #define CRTVDispEnd     0x12
76 #define CRTVBlankStart  0x15
77 #define CRTVBlankEnd    0x16
78 #define CRTVSyncStart   0x10
79 #define CRTVSyncEnd     0x11
80
81 #define CRTOverflow     0x07
82 #define CRTPRowScan     0x08
83 #define CRTMaxScanLine  0x09
84 #define CRTModeControl  0x17
85 #define CRTLineCompare  0x18
86
87 /* 3x4 */
88 #define StartAddrHigh 0x0C
89 #define StartAddrLow 0x0D
90 #define Offset 0x13
91 #define Underline 0x14
92 #define CRTCMode 0x17
93 #define CRTCModuleTest 0x1E
94 #define FIFOControl 0x20
95 #define LinearAddReg 0x21
96 #define DRAMTiming 0x23
97 #define New32 0x23
98 #define RAMDACTiming 0x25
99 #define CRTHiOrd 0x27
100 #define AddColReg 0x29
101 #define InterfaceSel 0x2A
102 #define HorizOverflow 0x2B
103 #define GETest 0x2D
104 #define Performance 0x2F
105 #define GraphEngReg 0x36
106 #define I2C 0x37
107 #define PixelBusReg 0x38
108 #define PCIReg 0x39
109 #define DRAMControl 0x3A
110 #define MiscContReg 0x3C
111 #define CursorXLow 0x40
112 #define CursorXHigh 0x41
113 #define CursorYLow 0x42
114 #define CursorYHigh 0x43
115 #define CursorLocLow 0x44
116 #define CursorLocHigh 0x45
117 #define CursorXOffset 0x46
118 #define CursorYOffset 0x47
119 #define CursorFG1 0x48
120 #define CursorFG2 0x49
121 #define CursorFG3 0x4A
122 #define CursorFG4 0x4B
123 #define CursorBG1 0x4C
124 #define CursorBG2 0x4D
125 #define CursorBG3 0x4E
126 #define CursorBG4 0x4F
127 #define CursorControl 0x50
128 #define PCIRetry 0x55
129 #define PreEndControl 0x56
130 #define PreEndFetch 0x57
131 #define PCIMaster 0x60
132 #define Enhancement0 0x62
133 #define NewEDO 0x64
134 #define TVinterface 0xC0
135 #define TVMode 0xC1
136 #define ClockControl 0xCF
137
138
139 /* 3CE */
140 #define MiscExtFunc 0x0F
141 #define PowerStatus 0x23
142 #define MiscIntContReg 0x2F
143 #define CyberControl 0x30
144 #define CyberEnhance 0x31
145 #define FPConfig     0x33
146 #define VertStretch  0x52
147 #define HorStretch   0x53
148 #define BiosMode     0x5c
149 #define BiosReg      0x5d
150