Go to most recent revision | Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
3254 | Serge | 1 | #ifndef INTEL_DRIVER_H |
2 | #define INTEL_DRIVER_H |
||
3 | |||
4 | #define INTEL_VERSION 4000 |
||
5 | #define INTEL_NAME "intel" |
||
6 | #define INTEL_DRIVER_NAME "intel" |
||
7 | |||
8 | #define INTEL_VERSION_MAJOR PACKAGE_VERSION_MAJOR |
||
9 | #define INTEL_VERSION_MINOR PACKAGE_VERSION_MINOR |
||
10 | #define INTEL_VERSION_PATCH PACKAGE_VERSION_PATCHLEVEL |
||
11 | |||
12 | #ifndef PCI_CHIP_I810 |
||
13 | #define PCI_CHIP_I810 0x7121 |
||
14 | #define PCI_CHIP_I810_DC100 0x7123 |
||
15 | #define PCI_CHIP_I810_E 0x7125 |
||
16 | #define PCI_CHIP_I815 0x1132 |
||
17 | #define PCI_CHIP_I810_BRIDGE 0x7120 |
||
18 | #define PCI_CHIP_I810_DC100_BRIDGE 0x7122 |
||
19 | #define PCI_CHIP_I810_E_BRIDGE 0x7124 |
||
20 | #define PCI_CHIP_I815_BRIDGE 0x1130 |
||
21 | #endif |
||
22 | |||
23 | #ifndef PCI_CHIP_I830_M |
||
24 | #define PCI_CHIP_I830_M 0x3577 |
||
25 | #define PCI_CHIP_I830_M_BRIDGE 0x3575 |
||
26 | #endif |
||
27 | |||
28 | #ifndef PCI_CHIP_845_G |
||
29 | #define PCI_CHIP_845_G 0x2562 |
||
30 | #define PCI_CHIP_845_G_BRIDGE 0x2560 |
||
31 | #endif |
||
32 | |||
33 | #ifndef PCI_CHIP_I854 |
||
34 | #define PCI_CHIP_I854 0x358E |
||
35 | #define PCI_CHIP_I854_BRIDGE 0x358C |
||
36 | #endif |
||
37 | |||
38 | #ifndef PCI_CHIP_I855_GM |
||
39 | #define PCI_CHIP_I855_GM 0x3582 |
||
40 | #define PCI_CHIP_I855_GM_BRIDGE 0x3580 |
||
41 | #endif |
||
42 | |||
43 | #ifndef PCI_CHIP_I865_G |
||
44 | #define PCI_CHIP_I865_G 0x2572 |
||
45 | #define PCI_CHIP_I865_G_BRIDGE 0x2570 |
||
46 | #endif |
||
47 | |||
48 | #ifndef PCI_CHIP_I915_G |
||
49 | #define PCI_CHIP_I915_G 0x2582 |
||
50 | #define PCI_CHIP_I915_G_BRIDGE 0x2580 |
||
51 | #endif |
||
52 | |||
53 | #ifndef PCI_CHIP_I915_GM |
||
54 | #define PCI_CHIP_I915_GM 0x2592 |
||
55 | #define PCI_CHIP_I915_GM_BRIDGE 0x2590 |
||
56 | #endif |
||
57 | |||
58 | #ifndef PCI_CHIP_E7221_G |
||
59 | #define PCI_CHIP_E7221_G 0x258A |
||
60 | /* Same as I915_G_BRIDGE */ |
||
61 | #define PCI_CHIP_E7221_G_BRIDGE 0x2580 |
||
62 | #endif |
||
63 | |||
64 | #ifndef PCI_CHIP_I945_G |
||
65 | #define PCI_CHIP_I945_G 0x2772 |
||
66 | #define PCI_CHIP_I945_G_BRIDGE 0x2770 |
||
67 | #endif |
||
68 | |||
69 | #ifndef PCI_CHIP_I945_GM |
||
70 | #define PCI_CHIP_I945_GM 0x27A2 |
||
71 | #define PCI_CHIP_I945_GM_BRIDGE 0x27A0 |
||
72 | #endif |
||
73 | |||
74 | #ifndef PCI_CHIP_I945_GME |
||
75 | #define PCI_CHIP_I945_GME 0x27AE |
||
76 | #define PCI_CHIP_I945_GME_BRIDGE 0x27AC |
||
77 | #endif |
||
78 | |||
79 | #ifndef PCI_CHIP_PINEVIEW_M |
||
80 | #define PCI_CHIP_PINEVIEW_M 0xA011 |
||
81 | #define PCI_CHIP_PINEVIEW_M_BRIDGE 0xA010 |
||
82 | #define PCI_CHIP_PINEVIEW_G 0xA001 |
||
83 | #define PCI_CHIP_PINEVIEW_G_BRIDGE 0xA000 |
||
84 | #endif |
||
85 | |||
86 | #ifndef PCI_CHIP_G35_G |
||
87 | #define PCI_CHIP_G35_G 0x2982 |
||
88 | #define PCI_CHIP_G35_G_BRIDGE 0x2980 |
||
89 | #endif |
||
90 | |||
91 | #ifndef PCI_CHIP_I965_Q |
||
92 | #define PCI_CHIP_I965_Q 0x2992 |
||
93 | #define PCI_CHIP_I965_Q_BRIDGE 0x2990 |
||
94 | #endif |
||
95 | |||
96 | #ifndef PCI_CHIP_I965_G |
||
97 | #define PCI_CHIP_I965_G 0x29A2 |
||
98 | #define PCI_CHIP_I965_G_BRIDGE 0x29A0 |
||
99 | #endif |
||
100 | |||
101 | #ifndef PCI_CHIP_I946_GZ |
||
102 | #define PCI_CHIP_I946_GZ 0x2972 |
||
103 | #define PCI_CHIP_I946_GZ_BRIDGE 0x2970 |
||
104 | #endif |
||
105 | |||
106 | #ifndef PCI_CHIP_I965_GM |
||
107 | #define PCI_CHIP_I965_GM 0x2A02 |
||
108 | #define PCI_CHIP_I965_GM_BRIDGE 0x2A00 |
||
109 | #endif |
||
110 | |||
111 | #ifndef PCI_CHIP_I965_GME |
||
112 | #define PCI_CHIP_I965_GME 0x2A12 |
||
113 | #define PCI_CHIP_I965_GME_BRIDGE 0x2A10 |
||
114 | #endif |
||
115 | |||
116 | #ifndef PCI_CHIP_G33_G |
||
117 | #define PCI_CHIP_G33_G 0x29C2 |
||
118 | #define PCI_CHIP_G33_G_BRIDGE 0x29C0 |
||
119 | #endif |
||
120 | |||
121 | #ifndef PCI_CHIP_Q35_G |
||
122 | #define PCI_CHIP_Q35_G 0x29B2 |
||
123 | #define PCI_CHIP_Q35_G_BRIDGE 0x29B0 |
||
124 | #endif |
||
125 | |||
126 | #ifndef PCI_CHIP_Q33_G |
||
127 | #define PCI_CHIP_Q33_G 0x29D2 |
||
128 | #define PCI_CHIP_Q33_G_BRIDGE 0x29D0 |
||
129 | #endif |
||
130 | |||
131 | #ifndef PCI_CHIP_GM45_GM |
||
132 | #define PCI_CHIP_GM45_GM 0x2A42 |
||
133 | #define PCI_CHIP_GM45_BRIDGE 0x2A40 |
||
134 | #endif |
||
135 | |||
136 | #ifndef PCI_CHIP_G45_E_G |
||
137 | #define PCI_CHIP_G45_E_G 0x2E02 |
||
138 | #define PCI_CHIP_G45_E_G_BRIDGE 0x2E00 |
||
139 | #endif |
||
140 | |||
141 | #ifndef PCI_CHIP_G45_G |
||
142 | #define PCI_CHIP_G45_G 0x2E22 |
||
143 | #define PCI_CHIP_G45_G_BRIDGE 0x2E20 |
||
144 | #endif |
||
145 | |||
146 | #ifndef PCI_CHIP_Q45_G |
||
147 | #define PCI_CHIP_Q45_G 0x2E12 |
||
148 | #define PCI_CHIP_Q45_G_BRIDGE 0x2E10 |
||
149 | #endif |
||
150 | |||
151 | #ifndef PCI_CHIP_G41_G |
||
152 | #define PCI_CHIP_G41_G 0x2E32 |
||
153 | #define PCI_CHIP_G41_G_BRIDGE 0x2E30 |
||
154 | #endif |
||
155 | |||
156 | #ifndef PCI_CHIP_B43_G |
||
157 | #define PCI_CHIP_B43_G 0x2E42 |
||
158 | #define PCI_CHIP_B43_G_BRIDGE 0x2E40 |
||
159 | #endif |
||
160 | |||
161 | #ifndef PCI_CHIP_B43_G1 |
||
162 | #define PCI_CHIP_B43_G1 0x2E92 |
||
163 | #define PCI_CHIP_B43_G1_BRIDGE 0x2E90 |
||
164 | #endif |
||
165 | |||
166 | #ifndef PCI_CHIP_IRONLAKE_D_G |
||
167 | #define PCI_CHIP_IRONLAKE_D_G 0x0042 |
||
168 | #define PCI_CHIP_IRONLAKE_D_G_BRIDGE 0x0040 |
||
169 | #endif |
||
170 | |||
171 | #ifndef PCI_CHIP_IRONLAKE_M_G |
||
172 | #define PCI_CHIP_IRONLAKE_M_G 0x0046 |
||
173 | #define PCI_CHIP_IRONLAKE_M_G_BRIDGE 0x0044 |
||
174 | #endif |
||
175 | |||
176 | #ifndef PCI_CHIP_SANDYBRIDGE_BRIDGE |
||
177 | #define PCI_CHIP_SANDYBRIDGE_BRIDGE 0x0100 /* Desktop */ |
||
178 | #define PCI_CHIP_SANDYBRIDGE_GT1 0x0102 |
||
179 | #define PCI_CHIP_SANDYBRIDGE_GT2 0x0112 |
||
180 | #define PCI_CHIP_SANDYBRIDGE_GT2_PLUS 0x0122 |
||
181 | #define PCI_CHIP_SANDYBRIDGE_BRIDGE_M 0x0104 /* Mobile */ |
||
182 | #define PCI_CHIP_SANDYBRIDGE_M_GT1 0x0106 |
||
183 | #define PCI_CHIP_SANDYBRIDGE_M_GT2 0x0116 |
||
184 | #define PCI_CHIP_SANDYBRIDGE_M_GT2_PLUS 0x0126 |
||
185 | #define PCI_CHIP_SANDYBRIDGE_BRIDGE_S 0x0108 /* Server */ |
||
186 | #define PCI_CHIP_SANDYBRIDGE_S_GT 0x010A |
||
187 | |||
188 | #define PCI_CHIP_IVYBRIDGE_M_GT1 0x0156 |
||
189 | #define PCI_CHIP_IVYBRIDGE_M_GT2 0x0166 |
||
190 | #define PCI_CHIP_IVYBRIDGE_D_GT1 0x0152 |
||
191 | #define PCI_CHIP_IVYBRIDGE_D_GT2 0x0162 |
||
192 | #define PCI_CHIP_IVYBRIDGE_S_GT1 0x015a |
||
193 | #define PCI_CHIP_IVYBRIDGE_S_GT2 0x016a |
||
194 | |||
195 | #define PCI_CHIP_HASWELL_D_GT1 0x0402 |
||
196 | #define PCI_CHIP_HASWELL_D_GT2 0x0412 |
||
197 | #define PCI_CHIP_HASWELL_D_GT2_PLUS 0x0422 |
||
198 | #define PCI_CHIP_HASWELL_M_GT1 0x0406 |
||
199 | #define PCI_CHIP_HASWELL_M_GT2 0x0416 |
||
200 | #define PCI_CHIP_HASWELL_M_GT2_PLUS 0x0426 |
||
201 | #define PCI_CHIP_HASWELL_S_GT1 0x040A |
||
202 | #define PCI_CHIP_HASWELL_S_GT2 0x041A |
||
203 | #define PCI_CHIP_HASWELL_S_GT2_PLUS 0x042A |
||
204 | #define PCI_CHIP_HASWELL_SDV_D_GT1 0x0C02 |
||
205 | #define PCI_CHIP_HASWELL_SDV_D_GT2 0x0C12 |
||
206 | #define PCI_CHIP_HASWELL_SDV_D_GT2_PLUS 0x0C22 |
||
207 | #define PCI_CHIP_HASWELL_SDV_M_GT1 0x0C06 |
||
208 | #define PCI_CHIP_HASWELL_SDV_M_GT2 0x0C16 |
||
209 | #define PCI_CHIP_HASWELL_SDV_M_GT2_PLUS 0x0C26 |
||
210 | #define PCI_CHIP_HASWELL_SDV_S_GT1 0x0C0A |
||
211 | #define PCI_CHIP_HASWELL_SDV_S_GT2 0x0C1A |
||
212 | #define PCI_CHIP_HASWELL_SDV_S_GT2_PLUS 0x0C2A |
||
213 | #define PCI_CHIP_HASWELL_ULT_D_GT1 0x0A02 |
||
214 | #define PCI_CHIP_HASWELL_ULT_D_GT2 0x0A12 |
||
215 | #define PCI_CHIP_HASWELL_ULT_D_GT2_PLUS 0x0A22 |
||
216 | #define PCI_CHIP_HASWELL_ULT_M_GT1 0x0A06 |
||
217 | #define PCI_CHIP_HASWELL_ULT_M_GT2 0x0A16 |
||
218 | #define PCI_CHIP_HASWELL_ULT_M_GT2_PLUS 0x0A26 |
||
219 | #define PCI_CHIP_HASWELL_ULT_S_GT1 0x0A0A |
||
220 | #define PCI_CHIP_HASWELL_ULT_S_GT2 0x0A1A |
||
221 | #define PCI_CHIP_HASWELL_ULT_S_GT2_PLUS 0x0A2A |
||
222 | #define PCI_CHIP_HASWELL_CRW_D_GT1 0x0D12 |
||
223 | #define PCI_CHIP_HASWELL_CRW_D_GT2 0x0D22 |
||
224 | #define PCI_CHIP_HASWELL_CRW_D_GT2_PLUS 0x0D32 |
||
225 | #define PCI_CHIP_HASWELL_CRW_M_GT1 0x0D16 |
||
226 | #define PCI_CHIP_HASWELL_CRW_M_GT2 0x0D26 |
||
227 | #define PCI_CHIP_HASWELL_CRW_M_GT2_PLUS 0x0D36 |
||
228 | #define PCI_CHIP_HASWELL_CRW_S_GT1 0x0D1A |
||
229 | #define PCI_CHIP_HASWELL_CRW_S_GT2 0x0D2A |
||
230 | #define PCI_CHIP_HASWELL_CRW_S_GT2_PLUS 0x0D3A |
||
231 | |||
232 | #define PCI_CHIP_VALLEYVIEW_PO 0x0f30 |
||
233 | #define PCI_CHIP_VALLEYVIEW_1 0x0f31 |
||
234 | #define PCI_CHIP_VALLEYVIEW_2 0x0f32 |
||
235 | #define PCI_CHIP_VALLEYVIEW_3 0x0f33 |
||
236 | |||
237 | #endif |
||
238 | |||
239 | #define I85X_CAPID 0x44 |
||
240 | #define I85X_VARIANT_MASK 0x7 |
||
241 | #define I85X_VARIANT_SHIFT 5 |
||
242 | #define I855_GME 0x0 |
||
243 | #define I855_GM 0x4 |
||
244 | #define I852_GME 0x2 |
||
245 | #define I852_GM 0x5 |
||
246 | |||
247 | #define I810_MEMBASE(p,n) (p)->regions[(n)].base_addr |
||
248 | #define VENDOR_ID(p) (p)->vendor_id |
||
249 | #define DEVICE_ID(p) (p)->device_id |
||
250 | #define SUBVENDOR_ID(p) (p)->subvendor_id |
||
251 | #define SUBSYS_ID(p) (p)->subdevice_id |
||
252 | #define CHIP_REVISION(p) (p)->revision |
||
253 | |||
254 | #define INTEL_INFO(intel) ((intel)->info) |
||
255 | #define IS_GENx(intel, X) (INTEL_INFO(intel)->gen >= 8*(X) && INTEL_INFO(intel)->gen < 8*((X)+1)) |
||
256 | #define IS_GEN1(intel) IS_GENx(intel, 1) |
||
257 | #define IS_GEN2(intel) IS_GENx(intel, 2) |
||
258 | #define IS_GEN3(intel) IS_GENx(intel, 3) |
||
259 | #define IS_GEN4(intel) IS_GENx(intel, 4) |
||
260 | #define IS_GEN5(intel) IS_GENx(intel, 5) |
||
261 | #define IS_GEN6(intel) IS_GENx(intel, 6) |
||
262 | #define IS_GEN7(intel) IS_GENx(intel, 7) |
||
263 | #define IS_HSW(intel) (INTEL_INFO(intel)->gen == 075) |
||
264 | |||
265 | /* Some chips have specific errata (or limits) that we need to workaround. */ |
||
266 | #define IS_I830(intel) (DEVICE_ID((intel)->PciInfo) == PCI_CHIP_I830_M) |
||
267 | #define IS_845G(intel) (DEVICE_ID((intel)->PciInfo) == PCI_CHIP_845_G) |
||
268 | #define IS_I865G(intel) (DEVICE_ID((intel)->PciInfo) == PCI_CHIP_I865_G) |
||
269 | |||
270 | #define IS_I915G(pI810) (DEVICE_ID(pI810->PciInfo) == PCI_CHIP_I915_G || DEVICE_ID(pI810->PciInfo) == PCI_CHIP_E7221_G) |
||
271 | #define IS_I915GM(pI810) (DEVICE_ID(pI810->PciInfo) == PCI_CHIP_I915_GM) |
||
272 | |||
273 | #define IS_965_Q(pI810) (DEVICE_ID(pI810->PciInfo) == PCI_CHIP_I965_Q) |
||
274 | |||
275 | /* supports Y tiled surfaces (pre-965 Mesa isn't ready yet) */ |
||
276 | #define SUPPORTS_YTILING(pI810) (INTEL_INFO(intel)->gen >= 040) |
||
277 | #define HAS_BLT(pI810) (INTEL_INFO(intel)->gen >= 060) |
||
278 | |||
279 | struct intel_device_info { |
||
280 | int gen; |
||
281 | }; |
||
282 | |||
283 | //void intel_detect_chipset(ScrnInfoPtr scrn, |
||
284 | // EntityInfoPtr ent, |
||
285 | // struct pci_device *pci); |
||
286 | |||
287 | |||
288 | #endif /* INTEL_DRIVER_H */> |