VirtualBox

source: vbox/trunk/src/VBox/Devices/PC/vbox.dsl@ 31768

Last change on this file since 31768 was 31519, checked in by vboxsync, 14 years ago

Audio: provide ACPI info for audio card to Mac guests

  • Property svn:eol-style set to LF
  • Property svn:keywords set to Id
File size: 45.6 KB
Line 
1// $Id: vbox.dsl 31519 2010-08-10 11:35:59Z vboxsync $
2/// @file
3//
4// VirtualBox ACPI
5//
6// Copyright (C) 2006-2007 Oracle Corporation
7//
8// This file is part of VirtualBox Open Source Edition (OSE), as
9// available from http://www.virtualbox.org. This file is free software;
10// you can redistribute it and/or modify it under the terms of the GNU
11// General Public License (GPL) as published by the Free Software
12// Foundation, in version 2 as it comes in the "COPYING" file of the
13// VirtualBox OSE distribution. VirtualBox OSE is distributed in the
14// hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
15
16DefinitionBlock ("DSDT.aml", "DSDT", 1, "VBOX ", "VBOXBIOS", 2)
17{
18 // Declare debugging ports withing SystemIO
19 OperationRegion(DBG0, SystemIO, 0x3000, 4)
20
21 // Writes to this field Will dump hex char
22 Field (DBG0, ByteAcc, NoLock, Preserve)
23 {
24 DHE1, 8,
25 }
26
27 // Writes to this field Will dump hex word
28 Field (DBG0, WordAcc, NoLock, Preserve)
29 {
30 DHE2, 16,
31 }
32
33 // Writes to this field Will dump hex double word
34 Field (DBG0, DWordAcc, NoLock, Preserve)
35 {
36 DHE4, 32,
37 }
38
39 // Writes to this field will dump ascii char
40 Field (DBG0, ByteAcc, NoLock, Preserve)
41 {
42 Offset (1),
43 DCHR, 8
44 }
45
46 // Shortcuts
47 Method(HEX, 1)
48 {
49 Store (Arg0, DHE1)
50 }
51
52 Method(HEX2, 1)
53 {
54 Store (Arg0, DHE2)
55 }
56
57 Method(HEX4, 1)
58 {
59 Store (Arg0, DHE4)
60 }
61
62 // Code from Microsoft sample
63 // http://www.microsoft.com/whdc/system/pnppwr/powermgmt/_OSI-method.mspx
64
65 //
66 // SLEN(Str) - Returns the length of Str (excluding NULL).
67 //
68 Method(SLEN, 1)
69 {
70 //
71 // Note: The caller must make sure that the argument is a string object.
72 //
73 Store(Arg0, Local0)
74 Return(Sizeof(Local0))
75 }
76
77 Method(S2BF, 1)
78 {
79 //
80 // Note: The caller must make sure that the argument is a string object.
81 //
82 // Local0 contains length of string + NULL.
83 //
84 Store(Arg0, Local0)
85 Add(SLEN(Local0), One, Local0)
86 //
87 // Convert the string object into a buffer object.
88 //
89 Name(BUFF, Buffer(Local0) {})
90 Store(Arg0, BUFF)
91 Return(BUFF)
92 }
93
94 // Convert ASCII string to buffer and store it's contents (char by
95 // char) into DCHR (thus possibly writing the string to console)
96 Method (\DBG, 1, NotSerialized)
97 {
98 Store(Arg0, Local0)
99 Store(S2BF (Local0), Local1)
100 Store(SizeOf (Local1), Local0)
101 Decrement (Local0)
102 Store(Zero, Local2)
103 While (Local0)
104 {
105 Decrement (Local0)
106 Store (DerefOf (Index (Local1, Local2)), DCHR)
107 Increment (Local2)
108 }
109 }
110
111 Name(PICM, 0)
112 Method(_PIC, 1)
113 {
114 DBG ("Pic mode: ")
115 HEX4 (Arg0)
116 Store (Arg0, PICM)
117 }
118
119 Scope (\_SB)
120 {
121 OperationRegion (SYSI, SystemIO, 0x4048, 0x08)
122 Field (SYSI, DwordAcc, NoLock, Preserve)
123 {
124 IDX0, 32,
125 DAT0, 32,
126 }
127
128 IndexField (IDX0, DAT0, DwordAcc, NoLock, Preserve)
129 {
130 MEML, 32,
131 UIOA, 32,
132 UHPT, 32,
133 USMC, 32,
134 UFDC, 32,
135 // UCP0-UCP3 no longer used and only kept here for saved state compatibilty
136 UCP0, 32,
137 UCP1, 32,
138 UCP2, 32,
139 UCP3, 32,
140 MEMH, 32,
141 URTC, 32,
142 CPUL, 32,
143 CPUC, 32,
144 CPET, 32,
145 CPEV, 32,
146 NICA, 32,
147 HDAA, 32,
148 Offset (0x80),
149 ININ, 32,
150 Offset (0x200),
151 VAIN, 32,
152 }
153
154 Method (_INI, 0, NotSerialized)
155 {
156 Store (0xbadc0de, VAIN)
157 DBG ("MEML: ")
158 HEX4 (MEML)
159 DBG ("UIOA: ")
160 HEX4 (UIOA)
161 DBG ("UHPT: ")
162 HEX4 (UHPT)
163 DBG ("USMC: ")
164 HEX4 (USMC)
165 DBG ("UFDC: ")
166 HEX4 (UFDC)
167 DBG ("MEMH: ")
168 HEX4 (MEMH)
169 }
170
171 // PCI PIC IRQ Routing table
172 // Must match pci.c:pci_slot_get_pirq
173 Name (PR00, Package ()
174 {
175 Package (0x04) {0x0002FFFF, 0x00, LNKB, 0x00,},
176 Package (0x04) {0x0002FFFF, 0x01, LNKC, 0x00,},
177 Package (0x04) {0x0002FFFF, 0x02, LNKD, 0x00,},
178 Package (0x04) {0x0002FFFF, 0x03, LNKA, 0x00,},
179
180 Package (0x04) {0x0003FFFF, 0x00, LNKC, 0x00,},
181 Package (0x04) {0x0003FFFF, 0x01, LNKD, 0x00,},
182 Package (0x04) {0x0003FFFF, 0x02, LNKA, 0x00,},
183 Package (0x04) {0x0003FFFF, 0x03, LNKB, 0x00,},
184
185 Package (0x04) {0x0004FFFF, 0x00, LNKD, 0x00,},
186 Package (0x04) {0x0004FFFF, 0x01, LNKA, 0x00,},
187 Package (0x04) {0x0004FFFF, 0x02, LNKB, 0x00,},
188 Package (0x04) {0x0004FFFF, 0x03, LNKC, 0x00,},
189
190 Package (0x04) {0x0005FFFF, 0x00, LNKA, 0x00,},
191 Package (0x04) {0x0005FFFF, 0x01, LNKB, 0x00,},
192 Package (0x04) {0x0005FFFF, 0x02, LNKC, 0x00,},
193 Package (0x04) {0x0005FFFF, 0x03, LNKD, 0x00,},
194
195 Package (0x04) {0x0006FFFF, 0x00, LNKB, 0x00,},
196 Package (0x04) {0x0006FFFF, 0x01, LNKC, 0x00,},
197 Package (0x04) {0x0006FFFF, 0x02, LNKD, 0x00,},
198 Package (0x04) {0x0006FFFF, 0x03, LNKA, 0x00,},
199
200 Package (0x04) {0x0007FFFF, 0x00, LNKC, 0x00,},
201 Package (0x04) {0x0007FFFF, 0x01, LNKD, 0x00,},
202 Package (0x04) {0x0007FFFF, 0x02, LNKA, 0x00,},
203 Package (0x04) {0x0007FFFF, 0x03, LNKB, 0x00,},
204
205 Package (0x04) {0x0008FFFF, 0x00, LNKD, 0x00,},
206 Package (0x04) {0x0008FFFF, 0x01, LNKA, 0x00,},
207 Package (0x04) {0x0008FFFF, 0x02, LNKB, 0x00,},
208 Package (0x04) {0x0008FFFF, 0x03, LNKC, 0x00,},
209
210 Package (0x04) {0x0009FFFF, 0x00, LNKA, 0x00,},
211 Package (0x04) {0x0009FFFF, 0x01, LNKB, 0x00,},
212 Package (0x04) {0x0009FFFF, 0x02, LNKC, 0x00,},
213 Package (0x04) {0x0009FFFF, 0x03, LNKD, 0x00,},
214
215 Package (0x04) {0x000AFFFF, 0x00, LNKB, 0x00,},
216 Package (0x04) {0x000AFFFF, 0x01, LNKC, 0x00,},
217 Package (0x04) {0x000AFFFF, 0x02, LNKD, 0x00,},
218 Package (0x04) {0x000AFFFF, 0x03, LNKA, 0x00,},
219
220 Package (0x04) {0x000BFFFF, 0x00, LNKC, 0x00,},
221 Package (0x04) {0x000BFFFF, 0x01, LNKD, 0x00,},
222 Package (0x04) {0x000BFFFF, 0x02, LNKA, 0x00,},
223 Package (0x04) {0x000BFFFF, 0x03, LNKB, 0x00,},
224
225 Package (0x04) {0x000CFFFF, 0x00, LNKD, 0x00,},
226 Package (0x04) {0x000CFFFF, 0x01, LNKA, 0x00,},
227 Package (0x04) {0x000CFFFF, 0x02, LNKB, 0x00,},
228 Package (0x04) {0x000CFFFF, 0x03, LNKC, 0x00,},
229
230 Package (0x04) {0x000DFFFF, 0x00, LNKA, 0x00,},
231 Package (0x04) {0x000DFFFF, 0x01, LNKB, 0x00,},
232 Package (0x04) {0x000DFFFF, 0x02, LNKC, 0x00,},
233 Package (0x04) {0x000DFFFF, 0x03, LNKD, 0x00,},
234
235 Package (0x04) {0x000EFFFF, 0x00, LNKB, 0x00,},
236 Package (0x04) {0x000EFFFF, 0x01, LNKC, 0x00,},
237 Package (0x04) {0x000EFFFF, 0x02, LNKD, 0x00,},
238 Package (0x04) {0x000EFFFF, 0x03, LNKA, 0x00,},
239
240 Package (0x04) {0x000FFFFF, 0x00, LNKC, 0x00,},
241 Package (0x04) {0x000FFFFF, 0x01, LNKD, 0x00,},
242 Package (0x04) {0x000FFFFF, 0x02, LNKA, 0x00,},
243 Package (0x04) {0x000FFFFF, 0x03, LNKB, 0x00,},
244
245 Package (0x04) {0x0010FFFF, 0x00, LNKD, 0x00,},
246 Package (0x04) {0x0010FFFF, 0x01, LNKA, 0x00,},
247 Package (0x04) {0x0010FFFF, 0x02, LNKB, 0x00,},
248 Package (0x04) {0x0010FFFF, 0x03, LNKC, 0x00,},
249
250 Package (0x04) {0x0011FFFF, 0x00, LNKA, 0x00,},
251 Package (0x04) {0x0011FFFF, 0x01, LNKB, 0x00,},
252 Package (0x04) {0x0011FFFF, 0x02, LNKC, 0x00,},
253 Package (0x04) {0x0011FFFF, 0x03, LNKD, 0x00,},
254
255 Package (0x04) {0x0012FFFF, 0x00, LNKB, 0x00,},
256 Package (0x04) {0x0012FFFF, 0x01, LNKC, 0x00,},
257 Package (0x04) {0x0012FFFF, 0x02, LNKD, 0x00,},
258 Package (0x04) {0x0012FFFF, 0x03, LNKA, 0x00,},
259
260 Package (0x04) {0x0013FFFF, 0x00, LNKC, 0x00,},
261 Package (0x04) {0x0013FFFF, 0x01, LNKD, 0x00,},
262 Package (0x04) {0x0013FFFF, 0x02, LNKA, 0x00,},
263 Package (0x04) {0x0013FFFF, 0x03, LNKB, 0x00,},
264
265 Package (0x04) {0x0014FFFF, 0x00, LNKD, 0x00,},
266 Package (0x04) {0x0014FFFF, 0x01, LNKA, 0x00,},
267 Package (0x04) {0x0014FFFF, 0x02, LNKB, 0x00,},
268 Package (0x04) {0x0014FFFF, 0x03, LNKC, 0x00,},
269
270 Package (0x04) {0x0015FFFF, 0x00, LNKA, 0x00,},
271 Package (0x04) {0x0015FFFF, 0x01, LNKB, 0x00,},
272 Package (0x04) {0x0015FFFF, 0x02, LNKC, 0x00,},
273 Package (0x04) {0x0015FFFF, 0x03, LNKD, 0x00,},
274
275 Package (0x04) {0x0016FFFF, 0x00, LNKB, 0x00,},
276 Package (0x04) {0x0016FFFF, 0x01, LNKC, 0x00,},
277 Package (0x04) {0x0016FFFF, 0x02, LNKD, 0x00,},
278 Package (0x04) {0x0016FFFF, 0x03, LNKA, 0x00,},
279
280 Package (0x04) {0x0017FFFF, 0x00, LNKC, 0x00,},
281 Package (0x04) {0x0017FFFF, 0x01, LNKD, 0x00,},
282 Package (0x04) {0x0017FFFF, 0x02, LNKA, 0x00,},
283 Package (0x04) {0x0017FFFF, 0x03, LNKB, 0x00,},
284
285 Package (0x04) {0x0018FFFF, 0x00, LNKD, 0x00,},
286 Package (0x04) {0x0018FFFF, 0x01, LNKA, 0x00,},
287 Package (0x04) {0x0018FFFF, 0x02, LNKB, 0x00,},
288 Package (0x04) {0x0018FFFF, 0x03, LNKC, 0x00,},
289
290 Package (0x04) {0x0019FFFF, 0x00, LNKA, 0x00,},
291 Package (0x04) {0x0019FFFF, 0x01, LNKB, 0x00,},
292 Package (0x04) {0x0019FFFF, 0x02, LNKC, 0x00,},
293 Package (0x04) {0x0019FFFF, 0x03, LNKD, 0x00,},
294
295 Package (0x04) {0x001AFFFF, 0x00, LNKB, 0x00,},
296 Package (0x04) {0x001AFFFF, 0x01, LNKC, 0x00,},
297 Package (0x04) {0x001AFFFF, 0x02, LNKD, 0x00,},
298 Package (0x04) {0x001AFFFF, 0x03, LNKA, 0x00,},
299
300 Package (0x04) {0x001BFFFF, 0x00, LNKC, 0x00,},
301 Package (0x04) {0x001BFFFF, 0x01, LNKD, 0x00,},
302 Package (0x04) {0x001BFFFF, 0x02, LNKA, 0x00,},
303 Package (0x04) {0x001BFFFF, 0x03, LNKB, 0x00,},
304
305 Package (0x04) {0x001CFFFF, 0x00, LNKD, 0x00,},
306 Package (0x04) {0x001CFFFF, 0x01, LNKA, 0x00,},
307 Package (0x04) {0x001CFFFF, 0x02, LNKB, 0x00,},
308 Package (0x04) {0x001CFFFF, 0x03, LNKC, 0x00,},
309
310 Package (0x04) {0x001DFFFF, 0x00, LNKA, 0x00,},
311 Package (0x04) {0x001DFFFF, 0x01, LNKB, 0x00,},
312 Package (0x04) {0x001DFFFF, 0x02, LNKC, 0x00,},
313 Package (0x04) {0x001DFFFF, 0x03, LNKD, 0x00,},
314
315 Package (0x04) {0x001EFFFF, 0x00, LNKB, 0x00,},
316 Package (0x04) {0x001EFFFF, 0x01, LNKC, 0x00,},
317 Package (0x04) {0x001EFFFF, 0x02, LNKD, 0x00,},
318 Package (0x04) {0x001EFFFF, 0x03, LNKA, 0x00,},
319
320 Package (0x04) {0x001FFFFF, 0x00, LNKC, 0x00,},
321 Package (0x04) {0x001FFFFF, 0x01, LNKD, 0x00,},
322 Package (0x04) {0x001FFFFF, 0x02, LNKA, 0x00,},
323 Package (0x04) {0x001FFFFF, 0x03, LNKB, 0x00,}
324 })
325
326 // PCI I/O APIC IRQ Routing table
327 // Must match pci.c:pci_slot_get_acpi_pirq
328 Name (PR01, Package ()
329 {
330 Package (0x04) {0x0002FFFF, 0x00, 0x00, 0x12,},
331 Package (0x04) {0x0002FFFF, 0x01, 0x00, 0x13,},
332 Package (0x04) {0x0002FFFF, 0x02, 0x00, 0x14,},
333 Package (0x04) {0x0002FFFF, 0x03, 0x00, 0x15,},
334
335 Package (0x04) {0x0003FFFF, 0x00, 0x00, 0x13,},
336 Package (0x04) {0x0003FFFF, 0x01, 0x00, 0x14,},
337 Package (0x04) {0x0003FFFF, 0x02, 0x00, 0x15,},
338 Package (0x04) {0x0003FFFF, 0x03, 0x00, 0x16,},
339
340 Package (0x04) {0x0004FFFF, 0x00, 0x00, 0x14,},
341 Package (0x04) {0x0004FFFF, 0x01, 0x00, 0x15,},
342 Package (0x04) {0x0004FFFF, 0x02, 0x00, 0x16,},
343 Package (0x04) {0x0004FFFF, 0x03, 0x00, 0x17,},
344
345 Package (0x04) {0x0005FFFF, 0x00, 0x00, 0x15,},
346 Package (0x04) {0x0005FFFF, 0x01, 0x00, 0x16,},
347 Package (0x04) {0x0005FFFF, 0x02, 0x00, 0x17,},
348 Package (0x04) {0x0005FFFF, 0x03, 0x00, 0x10,},
349
350 Package (0x04) {0x0006FFFF, 0x00, 0x00, 0x16,},
351 Package (0x04) {0x0006FFFF, 0x01, 0x00, 0x17,},
352 Package (0x04) {0x0006FFFF, 0x02, 0x00, 0x10,},
353 Package (0x04) {0x0006FFFF, 0x03, 0x00, 0x11,},
354
355 Package (0x04) {0x0007FFFF, 0x00, 0x00, 0x17,},
356 Package (0x04) {0x0007FFFF, 0x01, 0x00, 0x10,},
357 Package (0x04) {0x0007FFFF, 0x02, 0x00, 0x11,},
358 Package (0x04) {0x0007FFFF, 0x03, 0x00, 0x12,},
359
360 Package (0x04) {0x0008FFFF, 0x00, 0x00, 0x10,},
361 Package (0x04) {0x0008FFFF, 0x01, 0x00, 0x11,},
362 Package (0x04) {0x0008FFFF, 0x02, 0x00, 0x12,},
363 Package (0x04) {0x0008FFFF, 0x03, 0x00, 0x13,},
364
365 Package (0x04) {0x0009FFFF, 0x00, 0x00, 0x11,},
366 Package (0x04) {0x0009FFFF, 0x01, 0x00, 0x12,},
367 Package (0x04) {0x0009FFFF, 0x02, 0x00, 0x13,},
368 Package (0x04) {0x0009FFFF, 0x03, 0x00, 0x14,},
369
370 Package (0x04) {0x000AFFFF, 0x00, 0x00, 0x12,},
371 Package (0x04) {0x000AFFFF, 0x01, 0x00, 0x13,},
372 Package (0x04) {0x000AFFFF, 0x02, 0x00, 0x14,},
373 Package (0x04) {0x000AFFFF, 0x03, 0x00, 0x15,},
374
375 Package (0x04) {0x000BFFFF, 0x00, 0x00, 0x13,},
376 Package (0x04) {0x000BFFFF, 0x01, 0x00, 0x14,},
377 Package (0x04) {0x000BFFFF, 0x02, 0x00, 0x15,},
378 Package (0x04) {0x000BFFFF, 0x03, 0x00, 0x16,},
379
380 Package (0x04) {0x000CFFFF, 0x00, 0x00, 0x14,},
381 Package (0x04) {0x000CFFFF, 0x01, 0x00, 0x15,},
382 Package (0x04) {0x000CFFFF, 0x02, 0x00, 0x16,},
383 Package (0x04) {0x000CFFFF, 0x03, 0x00, 0x17,},
384
385 Package (0x04) {0x000DFFFF, 0x00, 0x00, 0x15,},
386 Package (0x04) {0x000DFFFF, 0x01, 0x00, 0x16,},
387 Package (0x04) {0x000DFFFF, 0x02, 0x00, 0x17,},
388 Package (0x04) {0x000DFFFF, 0x03, 0x00, 0x10,},
389
390 Package (0x04) {0x000EFFFF, 0x00, 0x00, 0x16,},
391 Package (0x04) {0x000EFFFF, 0x01, 0x00, 0x17,},
392 Package (0x04) {0x000EFFFF, 0x02, 0x00, 0x10,},
393 Package (0x04) {0x000EFFFF, 0x03, 0x00, 0x11,},
394
395 Package (0x04) {0x000FFFFF, 0x00, 0x00, 0x17,},
396 Package (0x04) {0x000FFFFF, 0x01, 0x00, 0x10,},
397 Package (0x04) {0x000FFFFF, 0x02, 0x00, 0x11,},
398 Package (0x04) {0x000FFFFF, 0x03, 0x00, 0x12,},
399
400 Package (0x04) {0x0010FFFF, 0x00, 0x00, 0x10,},
401 Package (0x04) {0x0010FFFF, 0x01, 0x00, 0x11,},
402 Package (0x04) {0x0010FFFF, 0x02, 0x00, 0x12,},
403 Package (0x04) {0x0010FFFF, 0x03, 0x00, 0x13,},
404
405 Package (0x04) {0x0011FFFF, 0x00, 0x00, 0x11,},
406 Package (0x04) {0x0011FFFF, 0x01, 0x00, 0x12,},
407 Package (0x04) {0x0011FFFF, 0x02, 0x00, 0x13,},
408 Package (0x04) {0x0011FFFF, 0x03, 0x00, 0x14,},
409
410 Package (0x04) {0x0012FFFF, 0x00, 0x00, 0x12,},
411 Package (0x04) {0x0012FFFF, 0x01, 0x00, 0x13,},
412 Package (0x04) {0x0012FFFF, 0x02, 0x00, 0x14,},
413 Package (0x04) {0x0012FFFF, 0x03, 0x00, 0x15,},
414
415 Package (0x04) {0x0013FFFF, 0x00, 0x00, 0x13,},
416 Package (0x04) {0x0013FFFF, 0x01, 0x00, 0x14,},
417 Package (0x04) {0x0013FFFF, 0x02, 0x00, 0x15,},
418 Package (0x04) {0x0013FFFF, 0x03, 0x00, 0x16,},
419
420 Package (0x04) {0x0014FFFF, 0x00, 0x00, 0x14,},
421 Package (0x04) {0x0014FFFF, 0x01, 0x00, 0x15,},
422 Package (0x04) {0x0014FFFF, 0x02, 0x00, 0x16,},
423 Package (0x04) {0x0014FFFF, 0x03, 0x00, 0x17,},
424
425 Package (0x04) {0x0015FFFF, 0x00, 0x00, 0x15,},
426 Package (0x04) {0x0015FFFF, 0x01, 0x00, 0x16,},
427 Package (0x04) {0x0015FFFF, 0x02, 0x00, 0x17,},
428 Package (0x04) {0x0015FFFF, 0x03, 0x00, 0x10,},
429
430 Package (0x04) {0x0016FFFF, 0x00, 0x00, 0x16,},
431 Package (0x04) {0x0016FFFF, 0x01, 0x00, 0x17,},
432 Package (0x04) {0x0016FFFF, 0x02, 0x00, 0x10,},
433 Package (0x04) {0x0016FFFF, 0x03, 0x00, 0x11,},
434
435 Package (0x04) {0x0017FFFF, 0x00, 0x00, 0x17,},
436 Package (0x04) {0x0017FFFF, 0x01, 0x00, 0x10,},
437 Package (0x04) {0x0017FFFF, 0x02, 0x00, 0x11,},
438 Package (0x04) {0x0017FFFF, 0x03, 0x00, 0x12,},
439
440 Package (0x04) {0x0018FFFF, 0x00, 0x00, 0x10,},
441 Package (0x04) {0x0018FFFF, 0x01, 0x00, 0x11,},
442 Package (0x04) {0x0018FFFF, 0x02, 0x00, 0x12,},
443 Package (0x04) {0x0018FFFF, 0x03, 0x00, 0x13,},
444
445 Package (0x04) {0x0019FFFF, 0x00, 0x00, 0x11,},
446 Package (0x04) {0x0019FFFF, 0x01, 0x00, 0x12,},
447 Package (0x04) {0x0019FFFF, 0x02, 0x00, 0x13,},
448 Package (0x04) {0x0019FFFF, 0x03, 0x00, 0x14,},
449
450 Package (0x04) {0x001AFFFF, 0x00, 0x00, 0x12,},
451 Package (0x04) {0x001AFFFF, 0x01, 0x00, 0x13,},
452 Package (0x04) {0x001AFFFF, 0x02, 0x00, 0x14,},
453 Package (0x04) {0x001AFFFF, 0x03, 0x00, 0x15,},
454
455 Package (0x04) {0x001BFFFF, 0x00, 0x00, 0x13,},
456 Package (0x04) {0x001BFFFF, 0x01, 0x00, 0x14,},
457 Package (0x04) {0x001BFFFF, 0x02, 0x00, 0x15,},
458 Package (0x04) {0x001BFFFF, 0x03, 0x00, 0x16,},
459
460 Package (0x04) {0x001CFFFF, 0x00, 0x00, 0x14,},
461 Package (0x04) {0x001CFFFF, 0x01, 0x00, 0x15,},
462 Package (0x04) {0x001CFFFF, 0x02, 0x00, 0x16,},
463 Package (0x04) {0x001CFFFF, 0x03, 0x00, 0x17,},
464
465 Package (0x04) {0x001DFFFF, 0x00, 0x00, 0x15,},
466 Package (0x04) {0x001DFFFF, 0x01, 0x00, 0x16,},
467 Package (0x04) {0x001DFFFF, 0x02, 0x00, 0x17,},
468 Package (0x04) {0x001DFFFF, 0x03, 0x00, 0x10,},
469
470 Package (0x04) {0x001EFFFF, 0x00, 0x00, 0x16,},
471 Package (0x04) {0x001EFFFF, 0x01, 0x00, 0x17,},
472 Package (0x04) {0x001EFFFF, 0x02, 0x00, 0x10,},
473 Package (0x04) {0x001EFFFF, 0x03, 0x00, 0x11,},
474
475 Package (0x04) {0x001FFFFF, 0x00, 0x00, 0x17,},
476 Package (0x04) {0x001FFFFF, 0x01, 0x00, 0x10,},
477 Package (0x04) {0x001FFFFF, 0x02, 0x00, 0x11,},
478 Package (0x04) {0x001FFFFF, 0x03, 0x00, 0x12,}
479 })
480
481 // Possible resource settings for PCI link A
482 Name (PRSA, ResourceTemplate ()
483 {
484 IRQ (Level, ActiveLow, Shared) {5,9,10,11}
485 })
486
487 // Possible resource settings for PCI link B
488 Name (PRSB, ResourceTemplate ()
489 {
490 IRQ (Level, ActiveLow, Shared) {5,9,10,11}
491 })
492
493 // Possible resource settings for PCI link C
494 Name (PRSC, ResourceTemplate ()
495 {
496 IRQ (Level, ActiveLow, Shared) {5,9,10,11}
497 })
498
499 // Possible resource settings for PCI link D
500 Name (PRSD, ResourceTemplate ()
501 {
502 IRQ (Level, ActiveLow, Shared) {5,9,10,11}
503 })
504
505 // PCI bus 0
506 Device (PCI0)
507 {
508 Name (_HID, EisaId ("PNP0A03"))
509 Name (_ADR, 0x00) // address
510 Name (_BBN, 0x00) // base bus adddress
511 Name (_UID, 0x00)
512
513 // Method that returns routing table; also opens PCI to I/O APIC
514 // interrupt routing backdoor by writing 0xdead 0xbeef signature
515 // to ISA bridge config space. See DevPCI.cpp/pciSetIrqInternal().
516 Method (_PRT, 0, NotSerialized)
517 {
518 if (LEqual (LAnd (PICM, UIOA), Zero)) {
519 DBG ("RETURNING PIC\n")
520 Store (0x00, \_SB.PCI0.SBRG.APDE)
521 Store (0x00, \_SB.PCI0.SBRG.APAD)
522 Return (PR00)
523 }
524 else {
525 DBG ("RETURNING APIC\n")
526 Store (0xbe, \_SB.PCI0.SBRG.APDE)
527 Store (0xef, \_SB.PCI0.SBRG.APAD)
528 Return (PR01)
529 }
530 }
531
532 Device (SBRG)
533 {
534 // Address of the PIIX3 (device 1 function 0)
535 Name (_ADR, 0x00010000)
536 OperationRegion (PCIC, PCI_Config, 0x00, 0xff)
537
538 Field (PCIC, ByteAcc, NoLock, Preserve)
539 {
540 Offset (0xad),
541 APAD, 8,
542 Offset (0xde),
543 APDE, 8,
544 }
545
546 // Keyboard device
547 Device (PS2K)
548 {
549 Name (_HID, EisaId ("PNP0303"))
550 Method (_STA, 0, NotSerialized)
551 {
552 Return (0x0F)
553 }
554
555 Name (_CRS, ResourceTemplate ()
556 {
557 IO (Decode16, 0x0060, 0x0060, 0x00, 0x01)
558 IO (Decode16, 0x0064, 0x0064, 0x00, 0x01)
559 IRQNoFlags () {1}
560 })
561 }
562
563 // DMA Controller
564 Device (DMAC)
565 {
566 Name (_HID, EisaId ("PNP0200"))
567 Name (_CRS, ResourceTemplate ()
568 {
569 IO (Decode16, 0x0000, 0x0000, 0x01, 0x10)
570 IO (Decode16, 0x0080, 0x0080, 0x01, 0x10)
571 IO (Decode16, 0x00C0, 0x00C0, 0x01, 0x20)
572 DMA (Compatibility, BusMaster, Transfer8_16) {4}
573 })
574 }
575
576 // Floppy disk controller
577 Device (FDC0)
578 {
579 Name (_HID, EisaId ("PNP0700"))
580
581 Method (_STA, 0, NotSerialized)
582 {
583 Return (UFDC)
584 }
585
586 // Current resource settings
587 Name (_CRS, ResourceTemplate ()
588 {
589 IO (Decode16, 0x03F0, 0x03F0, 0x01, 0x06)
590 IO (Decode16, 0x03F7, 0x03F7, 0x01, 0x01)
591 IRQNoFlags () {6}
592 DMA (Compatibility, NotBusMaster, Transfer8) {2}
593 })
594
595 // Possible resource settings
596 Name (_PRS, ResourceTemplate ()
597 {
598 IO (Decode16, 0x03F0, 0x03F0, 0x01, 0x06)
599 IO (Decode16, 0x03F7, 0x03F7, 0x01, 0x01)
600 IRQNoFlags () {6}
601 DMA (Compatibility, NotBusMaster, Transfer8) {2}
602 })
603
604 }
605
606 // Mouse device
607 Device (PS2M)
608 {
609 Name (_HID, EisaId ("PNP0F03"))
610 Method (_STA, 0, NotSerialized)
611 {
612 Return (0x0F)
613 }
614
615 Name (_CRS, ResourceTemplate ()
616 {
617 IRQNoFlags () {12}
618 })
619 }
620
621 // Parallel port
622 Device (LPT)
623 {
624 Name (_HID, EisaId ("PNP0400"))
625 Method (_STA, 0, NotSerialized)
626 {
627 Return (0x0F)
628 }
629 Name (_CRS, ResourceTemplate ()
630 {
631 IO (Decode16, 0x0378, 0x0378, 0x08, 0x08)
632 IO (Decode16, 0x0778, 0x0778, 0x08, 0x08)
633 IRQNoFlags () {7}
634 })
635 }
636
637 // Programmable Interval Timer (i8254)
638 Device (TIMR)
639 {
640 Name (_HID, EisaId ("PNP0100"))
641 Name (_CRS, ResourceTemplate ()
642 {
643 IO (Decode16,
644 0x0040, // Range Minimum
645 0x0040, // Range Maximum
646 0x00, // Alignment
647 0x04, // Length
648 )
649 IO (Decode16,
650 0x0050, // Range Minimum
651 0x0050, // Range Maximum
652 0x10, // Alignment
653 0x04, // Length
654 )
655 })
656 }
657
658 // Programmable Interrupt Controller (i8259)
659 Device (PIC)
660 {
661 Name (_HID, EisaId ("PNP0000"))
662 Name (_CRS, ResourceTemplate ()
663 {
664 IO (Decode16,
665 0x0020, // Range Minimum
666 0x0020, // Range Maximum
667 0x00, // Alignment
668 0x02, // Length
669 )
670 IO (Decode16,
671 0x00A0, // Range Minimum
672 0x00A0, // Range Maximum
673 0x00, // Alignment
674 0x02, // Length
675 )
676 // because in APIC configs PIC connected to pin 0,
677 // and ISA IRQ0 rerouted to pin 2
678 IRQNoFlags ()
679 {2}
680 })
681 }
682
683
684 // Real Time Clock and CMOS (MC146818)
685 Device (RTC)
686 {
687 Name (_HID, EisaId ("PNP0B00"))
688 Name (_CRS, ResourceTemplate ()
689 {
690 IO (Decode16,
691 0x0070, // Range Minimum
692 0x0070, // Range Maximum
693 0x01, // Alignment
694 0x02, // Length
695 )
696 })
697 Method (_STA, 0, NotSerialized)
698 {
699 Return (URTC)
700 }
701 }
702
703 // High Precision Event Timer
704 Device(HPET)
705 {
706 Name (_HID, EISAID("PNP0103"))
707 Name (_CID, EISAID("PNP0C01"))
708 Name(_UID, 0)
709
710 Method (_STA, 0, NotSerialized)
711 {
712 Return(UHPT)
713 }
714
715 Name(CRS, ResourceTemplate()
716 {
717 IRQNoFlags ()
718 {0}
719 IRQNoFlags ()
720 {8}
721 Memory32Fixed (ReadWrite,
722 0xFED00000, // Address Base
723 0x00000400 // Address Length
724 )
725 })
726
727 Method (_CRS, 0, NotSerialized)
728 {
729 Return (CRS)
730 }
731 }
732
733 // System Management Controller
734 Device (SMC)
735 {
736 Name (_HID, EisaId ("APP0001"))
737 Name (_CID, "smc-napa")
738
739 Method (_STA, 0, NotSerialized)
740 {
741 Return (USMC)
742 }
743 Name (CRS, ResourceTemplate ()
744 {
745 IO (Decode16,
746 0x0300, // Range Minimum
747 0x0300, // Range Maximum
748 0x01, // Alignment
749 0x20) // Length
750 IRQNoFlags ()
751 {6}
752
753 })
754 Method (_CRS, 0, NotSerialized)
755 {
756 Return (CRS)
757 }
758 }
759 }
760
761 // NIC
762 Device (GIGE)
763 {
764 /**
765 * Generic NIC, accoring to
766 * http://download.microsoft.com/download/1/6/1/161ba512-40e2-4cc9-843a-923143f3456c/devids.txt
767 * Needed by some Windows guests.
768 */
769 Name (_HID, EisaId ("PNP8390"))
770
771 Method(_ADR, 0, NotSerialized)
772 {
773 Return (NICA)
774 }
775 /* Name (_PRW, Package (0x02)
776 {
777 0x09,
778 0x04
779 }) */
780
781 /* Wake up on LAN? */
782 Method (EWOL, 1, NotSerialized)
783 {
784 Return (0x00)
785 }
786
787 Method (_STA, 0, NotSerialized)
788 {
789 if (LEqual (NICA, Zero)) {
790 Return (0x00)
791 }
792 else {
793 Return (0x0F)
794 }
795 }
796 }
797
798 // HDA Audio card
799 Device (HDEF)
800 {
801 Method(_ADR, 0, NotSerialized)
802 {
803 Return (HDAA)
804 }
805
806 Method (_STA, 0, NotSerialized)
807 {
808 if (LEqual (HDAA, Zero)) {
809 Return (0x00)
810 }
811 else {
812 Return (0x0F)
813 }
814 }
815 }
816
817 // Control method battery
818 Device (BAT0)
819 {
820 Name (_HID, EisaId ("PNP0C0A"))
821 Name (_UID, 0x00)
822
823 Scope (\_GPE)
824 {
825 // GPE bit 0 handler
826 // GPE.0 must be set and SCI raised when
827 // battery info changed and _BIF must be
828 // re-evaluated
829 Method (_L00, 0, NotSerialized)
830 {
831 Notify (\_SB.PCI0.BAT0, 0x81)
832 }
833 }
834
835 OperationRegion (CBAT, SystemIO, 0x4040, 0x08)
836 Field (CBAT, DwordAcc, NoLock, Preserve)
837 {
838 IDX0, 32,
839 DAT0, 32,
840 }
841
842 IndexField (IDX0, DAT0, DwordAcc, NoLock, Preserve)
843 {
844 STAT, 32,
845 PRAT, 32,
846 RCAP, 32,
847 PVOL, 32,
848
849 UNIT, 32,
850 DCAP, 32,
851 LFCP, 32,
852 BTEC, 32,
853 DVOL, 32,
854 DWRN, 32,
855 DLOW, 32,
856 GRN1, 32,
857 GRN2, 32,
858
859 BSTA, 32,
860 APSR, 32,
861 }
862
863 Method (_STA, 0, NotSerialized)
864 {
865 return (BSTA)
866 }
867
868 Name (PBIF, Package ()
869 {
870 0x01, // Power unit, 1 - mA
871 0x7fffffff, // Design capacity
872 0x7fffffff, // Last full charge capacity
873 0x00, // Battery technology
874 0xffffffff, // Design voltage
875 0x00, // Design capacity of Warning
876 0x00, // Design capacity of Low
877 0x04, // Battery capacity granularity 1
878 0x04, // Battery capacity granularity 2
879 "1", // Model number
880 "0", // Serial number
881 "VBOX", // Battery type
882 "innotek" // OEM Information
883 })
884
885 Name (PBST, Package () {
886 0, // Battery state
887 0x7fffffff, // Battery present rate
888 0x7fffffff, // Battery remaining capacity
889 0x7fffffff // Battery present voltage
890 })
891
892 // Battery information
893 Method (_BIF, 0, NotSerialized)
894 {
895 Store (UNIT, Index (PBIF, 0,))
896 Store (DCAP, Index (PBIF, 1,))
897 Store (LFCP, Index (PBIF, 2,))
898 Store (BTEC, Index (PBIF, 3,))
899 Store (DVOL, Index (PBIF, 4,))
900 Store (DWRN, Index (PBIF, 5,))
901 Store (DLOW, Index (PBIF, 6,))
902 Store (GRN1, Index (PBIF, 7,))
903 Store (GRN2, Index (PBIF, 8,))
904
905 DBG ("_BIF:\n")
906 HEX4 (DerefOf (Index (PBIF, 0,)))
907 HEX4 (DerefOf (Index (PBIF, 1,)))
908 HEX4 (DerefOf (Index (PBIF, 2,)))
909 HEX4 (DerefOf (Index (PBIF, 3,)))
910 HEX4 (DerefOf (Index (PBIF, 4,)))
911 HEX4 (DerefOf (Index (PBIF, 5,)))
912 HEX4 (DerefOf (Index (PBIF, 6,)))
913 HEX4 (DerefOf (Index (PBIF, 7,)))
914 HEX4 (DerefOf (Index (PBIF, 8,)))
915
916 return (PBIF)
917 }
918
919 // Battery status
920 Method (_BST, 0, NotSerialized)
921 {
922 Store (STAT, Index (PBST, 0,))
923 Store (PRAT, Index (PBST, 1,))
924 Store (RCAP, Index (PBST, 2,))
925 Store (PVOL, Index (PBST, 3,))
926/*
927 DBG ("_BST:\n")
928 HEX4 (DerefOf (Index (PBST, 0,)))
929 HEX4 (DerefOf (Index (PBST, 1,)))
930 HEX4 (DerefOf (Index (PBST, 2,)))
931 HEX4 (DerefOf (Index (PBST, 3,)))
932*/
933 return (PBST)
934 }
935 }
936
937 Device (AC)
938 {
939 Name (_HID, "ACPI0003")
940 Name (_UID, 0x00)
941 Name (_PCL, Package (0x01)
942 {
943 \_SB
944 })
945
946 Method (_PSR, 0, NotSerialized)
947 {
948 // DBG ("_PSR:\n")
949 // HEX4 (\_SB.PCI0.BAT0.APSR)
950 return (\_SB.PCI0.BAT0.APSR)
951 }
952
953 Method (_STA, 0, NotSerialized)
954 {
955 return (0x0f)
956 }
957 }
958 }
959 }
960
961 Scope (\_SB)
962 {
963 Scope (PCI0)
964 {
965 // PCI0 current resource settings
966 Name (CRS, ResourceTemplate ()
967 {
968 WordBusNumber (ResourceProducer, MinFixed, MaxFixed, PosDecode,
969 0x0000,
970 0x0000,
971 0x00FF,
972 0x0000,
973 0x0100)
974 IO (Decode16, 0x0CF8, 0x0CF8, 0x01, 0x08)
975 WordIO (ResourceProducer, MinFixed, MaxFixed,
976 PosDecode, EntireRange,
977 0x0000,
978 0x0000,
979 0x0CF7,
980 0x0000,
981 0x0CF8)
982 WordIO (ResourceProducer, MinFixed, MaxFixed,
983 PosDecode, EntireRange,
984 0x0000,
985 0x0D00,
986 0xFFFF,
987 0x0000,
988 0xF300)
989
990 /* Taken from ACPI faq (with some modifications) */
991 DwordMemory( // descriptor for video RAM behind ISA bus
992 ResourceProducer, // bit 0 of general flags is 0
993 PosDecode,
994 MinFixed, // Range is fixed
995 MaxFixed, // Range is Fixed
996 Cacheable,
997 ReadWrite,
998 0x00000000, // Granularity
999 0x000a0000, // Min
1000 0x000bffff, // Max
1001 0x00000000, // Translation
1002 0x00020000 // Range Length
1003 )
1004
1005 DwordMemory( // Consumed-and-produced resource
1006 // (all of low memory space)
1007 ResourceProducer, // bit 0 of general flags is 0
1008 PosDecode, // positive Decode
1009 MinNotFixed, // Range is not fixed
1010 MaxFixed, // Range is fixed
1011 Cacheable,
1012 ReadWrite,
1013 0x00000000, // Granularity
1014 0x00000000, // Min (calculated dynamically)
1015
1016 0xffdfffff, // Max = 4GB - 2MB
1017 0x00000000, // Translation
1018 0x00000000, // Range Length (calculated
1019 // dynamically)
1020 , // Optional field left blank
1021 , // Optional field left blank
1022 MEM3 // Name declaration for this
1023 // descriptor
1024 )
1025 })
1026
1027// Name (TOM, ResourceTemplate () // Memory above 4GB (aka high), appended when needed.
1028// {
1029// QWORDMemory(
1030// ResourceProducer, // bit 0 of general flags is 0
1031// PosDecode, // positive Decode
1032// MinFixed, // Range is fixed
1033// MaxFixed, // Range is fixed
1034// Cacheable,
1035// ReadWrite,
1036// 0x0000000000000000, // _GRA: Granularity.
1037// 0 /*0x0000000100000000*/, // _MIN: Min address, 4GB.
1038// 0 /*0x00000fffffffffff*/, // _MAX: Max possible address, 16TB.
1039// 0x0000000000000000, // _TRA: Translation
1040// 0x0000000000000000, // _LEN: Range length (calculated dynamically)
1041// , // ResourceSourceIndex: Optional field left blank
1042// , // ResourceSource: Optional field left blank
1043// MEM4 // Name declaration for this descriptor.
1044// )
1045// })
1046
1047 Method (_CRS, 0, NotSerialized)
1048 {
1049 CreateDwordField (CRS, \_SB.PCI0.MEM3._MIN, RAMT)
1050 CreateDwordField (CRS, \_SB.PCI0.MEM3._LEN, RAMR)
1051// CreateQwordField (TOM, \_SB.PCI0.MEM4._LEN, TM4L)
1052// CreateQwordField (TOM, \_SB.PCI0.MEM4._LEN, TM4N)
1053// CreateQwordField (TOM, \_SB.PCI0.MEM4._LEN, TM4X)
1054
1055 Store (MEML, RAMT)
1056 Subtract (0xffe00000, RAMT, RAMR)
1057
1058// If (LNotEqual (MEMH, 0x00000000))
1059// {
1060// //
1061// // Update the TOM resource template and append it to CRS.
1062// // This way old < 4GB guest doesn't see anything different.
1063// // (MEMH is the memory above 4GB specified in 64KB units.)
1064// //
1065// // Note: ACPI v2 doesn't do 32-bit integers. IASL may fail on
1066// // seeing 64-bit constants and the code probably wont work.
1067// //
1068// Store (1, TM4N)
1069// ShiftLeft (TM4N, 32, TM4N)
1070//
1071// Store (0x00000fff, TM4X)
1072// ShiftLeft (TM4X, 32, TM4X)
1073// Or (TM4X, 0xffffffff, TM4X)
1074//
1075// Store (MEMH, TM4L)
1076// ShiftLeft (TM4L, 16, TM4L)
1077//
1078// ConcatenateResTemplate (CRS, TOM, Local2)
1079// Return (Local2)
1080// }
1081
1082 Return (CRS)
1083 }
1084 }
1085 }
1086
1087 Scope (\_SB)
1088 {
1089 // Fields within PIIX3 configuration[0x60..0x63] with
1090 // IRQ mappings
1091 Field (\_SB.PCI0.SBRG.PCIC, ByteAcc, NoLock, Preserve)
1092 {
1093 Offset (0x60),
1094 PIRA, 8,
1095 PIRB, 8,
1096 PIRC, 8,
1097 PIRD, 8
1098 }
1099
1100 Name (BUFA, ResourceTemplate ()
1101 {
1102 IRQ (Level, ActiveLow, Shared) {15}
1103 })
1104 CreateWordField (BUFA, 0x01, ICRS)
1105
1106 // Generic status of IRQ routing entry
1107 Method (LSTA, 1, NotSerialized)
1108 {
1109 And (Arg0, 0x80, Local0)
1110// DBG ("LSTA: ")
1111// HEX (Arg0)
1112 If (Local0)
1113 {
1114 Return (0x09)
1115 }
1116 Else
1117 {
1118 Return (0x0B)
1119 }
1120 }
1121
1122 // Generic "current resource settings" for routing entry
1123 Method (LCRS, 1, NotSerialized)
1124 {
1125 And (Arg0, 0x0F, Local0)
1126 ShiftLeft (0x01, Local0, ICRS)
1127// DBG ("LCRS: ")
1128// HEX (ICRS)
1129 Return (BUFA)
1130 }
1131
1132 // Generic "set resource settings" for routing entry
1133 Method (LSRS, 1, NotSerialized)
1134 {
1135 CreateWordField (Arg0, 0x01, ISRS)
1136 FindSetRightBit (ISRS, Local0)
1137 Return (Decrement (Local0))
1138 }
1139
1140 // Generic "disable" for routing entry
1141 Method (LDIS, 1, NotSerialized)
1142 {
1143 Return (Or (Arg0, 0x80))
1144 }
1145
1146 // Link A
1147 Device (LNKA)
1148 {
1149 Name (_HID, EisaId ("PNP0C0F"))
1150 Name (_UID, 0x01)
1151
1152 // Status
1153 Method (_STA, 0, NotSerialized)
1154 {
1155 DBG ("LNKA._STA\n")
1156 Return (LSTA (PIRA))
1157 }
1158
1159 // Possible resource settings
1160 Method (_PRS, 0, NotSerialized)
1161 {
1162 DBG ("LNKA._PRS\n")
1163 Return (PRSA)
1164 }
1165
1166 // Disable
1167 Method (_DIS, 0, NotSerialized)
1168 {
1169 DBG ("LNKA._DIS\n")
1170 Store (LDIS (PIRA), PIRA)
1171 }
1172
1173 // Current resource settings
1174 Method (_CRS, 0, NotSerialized)
1175 {
1176 DBG ("LNKA._CRS\n")
1177 Return (LCRS (PIRA))
1178 }
1179
1180 // Set resource settings
1181 Method (_SRS, 1, NotSerialized)
1182 {
1183 DBG ("LNKA._SRS: ")
1184 HEX (LSRS (Arg0))
1185 Store (LSRS (Arg0), PIRA)
1186 }
1187 }
1188
1189 // Link B
1190 Device (LNKB)
1191 {
1192 Name (_HID, EisaId ("PNP0C0F"))
1193 Name (_UID, 0x02)
1194 Method (_STA, 0, NotSerialized)
1195 {
1196 // DBG ("LNKB._STA\n")
1197 Return (LSTA (PIRB))
1198 }
1199
1200 Method (_PRS, 0, NotSerialized)
1201 {
1202 // DBG ("LNKB._PRS\n")
1203 Return (PRSB)
1204 }
1205
1206 Method (_DIS, 0, NotSerialized)
1207 {
1208 // DBG ("LNKB._DIS\n")
1209 Store (LDIS (PIRB), PIRB)
1210 }
1211
1212 Method (_CRS, 0, NotSerialized)
1213 {
1214 // DBG ("LNKB._CRS\n")
1215 Return (LCRS (PIRB))
1216 }
1217
1218 Method (_SRS, 1, NotSerialized)
1219 {
1220 DBG ("LNKB._SRS: ")
1221 HEX (LSRS (Arg0))
1222 Store (LSRS (Arg0), PIRB)
1223 }
1224 }
1225
1226 // Link C
1227 Device (LNKC)
1228 {
1229 Name (_HID, EisaId ("PNP0C0F"))
1230 Name (_UID, 0x03)
1231 Method (_STA, 0, NotSerialized)
1232 {
1233 // DBG ("LNKC._STA\n")
1234 Return (LSTA (PIRC))
1235 }
1236
1237 Method (_PRS, 0, NotSerialized)
1238 {
1239 // DBG ("LNKC._PRS\n")
1240 Return (PRSC)
1241 }
1242
1243 Method (_DIS, 0, NotSerialized)
1244 {
1245 // DBG ("LNKC._DIS\n")
1246 Store (LDIS (PIRC), PIRC)
1247 }
1248
1249 Method (_CRS, 0, NotSerialized)
1250 {
1251 // DBG ("LNKC._CRS\n")
1252 Return (LCRS (PIRC))
1253 }
1254
1255 Method (_SRS, 1, NotSerialized)
1256 {
1257 DBG ("LNKC._SRS: ")
1258 HEX (LSRS (Arg0))
1259 Store (LSRS (Arg0), PIRC)
1260 }
1261 }
1262
1263 // Link D
1264 Device (LNKD)
1265 {
1266 Name (_HID, EisaId ("PNP0C0F"))
1267 Name (_UID, 0x04)
1268 Method (_STA, 0, NotSerialized)
1269 {
1270 // DBG ("LNKD._STA\n")
1271 Return (LSTA (PIRD))
1272 }
1273
1274 Method (_PRS, 0, NotSerialized)
1275 {
1276 // DBG ("LNKD._PRS\n")
1277 Return (PRSD)
1278 }
1279
1280 Method (_DIS, 0, NotSerialized)
1281 {
1282 // DBG ("LNKD._DIS\n")
1283 Store (LDIS (PIRA), PIRD)
1284 }
1285
1286 Method (_CRS, 0, NotSerialized)
1287 {
1288 // DBG ("LNKD._CRS\n")
1289 Return (LCRS (PIRD))
1290 }
1291
1292 Method (_SRS, 1, NotSerialized)
1293 {
1294 DBG ("LNKD._SRS: ")
1295 HEX (LSRS (Arg0))
1296 Store (LSRS (Arg0), PIRD)
1297 }
1298 }
1299 }
1300
1301 // Sx states
1302 Name (_S0, Package (2) {
1303 0x00,
1304 0x00,
1305 })
1306
1307 Name (_S5, Package (2) {
1308 0x05,
1309 0x05,
1310 })
1311
1312 Method (_PTS, 1, NotSerialized)
1313 {
1314 DBG ("Prepare to sleep: ")
1315 HEX (Arg0)
1316 }
1317}
1318
1319/*
1320 * Local Variables:
1321 * comment-start: "//"
1322 * End:
1323 */
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette