1    /*
2     * Some or all of this work - Copyright (c) 2006 - 2021, Intel Corp.
3     * All rights reserved.
4     *
5     * Redistribution and use in source and binary forms, with or without modification,
6     * are permitted provided that the following conditions are met:
7     *
8     * Redistributions of source code must retain the above copyright notice,
9     * this list of conditions and the following disclaimer.
10     * Redistributions in binary form must reproduce the above copyright notice,
11     * this list of conditions and the following disclaimer in the documentation
12     * and/or other materials provided with the distribution.
13     * Neither the name of Intel Corporation nor the names of its contributors
14     * may be used to endorse or promote products derived from this software
15     * without specific prior written permission.
16     *
17     * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
18     * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19     * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20     * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
21     * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22     * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
23     * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24     * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
25     * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
26     * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27     */
28    /*
29     * Resource Descriptor macros
30     *
31     * QWord Space Resource Descriptor Macro
32     */
33    Name (P42C, Package (0x1B)
34    {
35        ResourceTemplate ()
36        {
37            QWordSpace (0xC0, ResourceProducer, PosDecode, MinNotFixed, MaxNotFixed, 0x0A,
38                0xD8D9DADBDCDDDEDF, // Granularity
39                0xE0E1E2E3E4E5E6E7, // Range Minimum
40                0xE8E9EAEBECEDEEEF, // Range Maximum
41                0xF0F1F2F3F4F5F6F7, // Translation Offset
42                0xF8F9FAFBFCFDFEFF, // Length
43                ,, )
44        },
45
46        ResourceTemplate ()
47        {
48            QWordSpace (0xC1, ResourceProducer, PosDecode, MinNotFixed, MaxFixed, 0x1A,
49                0xD8D9DADBDCDDDEDF, // Granularity
50                0xE0E1E2E3E4E5E6E7, // Range Minimum
51                0xE8E9EAEBECEDEEEF, // Range Maximum
52                0xF0F1F2F3F4F5F6F7, // Translation Offset
53                0xF8F9FAFBFCFDFEFF, // Length
54                ,, )
55        },
56
57        ResourceTemplate ()
58        {
59            QWordSpace (0xC2, ResourceProducer, PosDecode, MinFixed, MaxNotFixed, 0x2A,
60                0xD8D9DADBDCDDDEDF, // Granularity
61                0xE0E1E2E3E4E5E6E7, // Range Minimum
62                0xE8E9EAEBECEDEEEF, // Range Maximum
63                0xF0F1F2F3F4F5F6F7, // Translation Offset
64                0xF8F9FAFBFCFDFEFF, // Length
65                ,, )
66        },
67
68        ResourceTemplate ()
69        {
70            QWordSpace (0xC3, ResourceProducer, PosDecode, MinFixed, MaxFixed, 0x3A,
71                0xD8D9DADBDCDDDEDF, // Granularity
72                0xE0E1E2E3E4E5E6E7, // Range Minimum
73                0xE8E9EAEBECEDEEEF, // Range Maximum
74                0xF0F1F2F3F4F5F6F7, // Translation Offset
75                0xF8F9FAFBFCFDFEFF, // Length
76                ,, )
77        },
78
79        ResourceTemplate ()
80        {
81            QWordSpace (0xC4, ResourceProducer, SubDecode, MinNotFixed, MaxNotFixed, 0x4A,
82                0xD8D9DADBDCDDDEDF, // Granularity
83                0xE0E1E2E3E4E5E6E7, // Range Minimum
84                0xE8E9EAEBECEDEEEF, // Range Maximum
85                0xF0F1F2F3F4F5F6F7, // Translation Offset
86                0xF8F9FAFBFCFDFEFF, // Length
87                ,, )
88        },
89
90        ResourceTemplate ()
91        {
92            QWordSpace (0xC5, ResourceProducer, SubDecode, MinNotFixed, MaxFixed, 0x5A,
93                0xD8D9DADBDCDDDEDF, // Granularity
94                0xE0E1E2E3E4E5E6E7, // Range Minimum
95                0xE8E9EAEBECEDEEEF, // Range Maximum
96                0xF0F1F2F3F4F5F6F7, // Translation Offset
97                0xF8F9FAFBFCFDFEFF, // Length
98                ,, )
99        },
100
101        ResourceTemplate ()
102        {
103            QWordSpace (0xC6, ResourceProducer, SubDecode, MinFixed, MaxNotFixed, 0x6A,
104                0xD8D9DADBDCDDDEDF, // Granularity
105                0xE0E1E2E3E4E5E6E7, // Range Minimum
106                0xE8E9EAEBECEDEEEF, // Range Maximum
107                0xF0F1F2F3F4F5F6F7, // Translation Offset
108                0xF8F9FAFBFCFDFEFF, // Length
109                ,, )
110        },
111
112        ResourceTemplate ()
113        {
114            QWordSpace (0xC7, ResourceProducer, SubDecode, MinFixed, MaxFixed, 0x7A,
115                0xD8D9DADBDCDDDEDF, // Granularity
116                0xE0E1E2E3E4E5E6E7, // Range Minimum
117                0xE8E9EAEBECEDEEEF, // Range Maximum
118                0xF0F1F2F3F4F5F6F7, // Translation Offset
119                0xF8F9FAFBFCFDFEFF, // Length
120                ,, )
121        },
122
123        ResourceTemplate ()
124        {
125            QWordSpace (0xC8, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x8A,
126                0xD8D9DADBDCDDDEDF, // Granularity
127                0xE0E1E2E3E4E5E6E7, // Range Minimum
128                0xE8E9EAEBECEDEEEF, // Range Maximum
129                0xF0F1F2F3F4F5F6F7, // Translation Offset
130                0xF8F9FAFBFCFDFEFF, // Length
131                ,, )
132        },
133
134        ResourceTemplate ()
135        {
136            QWordSpace (0xC9, ResourceConsumer, PosDecode, MinNotFixed, MaxFixed, 0x9A,
137                0xD8D9DADBDCDDDEDF, // Granularity
138                0xE0E1E2E3E4E5E6E7, // Range Minimum
139                0xE8E9EAEBECEDEEEF, // Range Maximum
140                0xF0F1F2F3F4F5F6F7, // Translation Offset
141                0xF8F9FAFBFCFDFEFF, // Length
142                ,, )
143        },
144
145        ResourceTemplate ()
146        {
147            QWordSpace (0xCA, ResourceConsumer, PosDecode, MinFixed, MaxNotFixed, 0xAA,
148                0xD8D9DADBDCDDDEDF, // Granularity
149                0xE0E1E2E3E4E5E6E7, // Range Minimum
150                0xE8E9EAEBECEDEEEF, // Range Maximum
151                0xF0F1F2F3F4F5F6F7, // Translation Offset
152                0xF8F9FAFBFCFDFEFF, // Length
153                ,, )
154        },
155
156        ResourceTemplate ()
157        {
158            QWordSpace (0xCB, ResourceConsumer, PosDecode, MinFixed, MaxFixed, 0xBA,
159                0xD8D9DADBDCDDDEDF, // Granularity
160                0xE0E1E2E3E4E5E6E7, // Range Minimum
161                0xE8E9EAEBECEDEEEF, // Range Maximum
162                0xF0F1F2F3F4F5F6F7, // Translation Offset
163                0xF8F9FAFBFCFDFEFF, // Length
164                ,, )
165        },
166
167        ResourceTemplate ()
168        {
169            QWordSpace (0xCC, ResourceConsumer, SubDecode, MinNotFixed, MaxNotFixed, 0xCA,
170                0xD8D9DADBDCDDDEDF, // Granularity
171                0xE0E1E2E3E4E5E6E7, // Range Minimum
172                0xE8E9EAEBECEDEEEF, // Range Maximum
173                0xF0F1F2F3F4F5F6F7, // Translation Offset
174                0xF8F9FAFBFCFDFEFF, // Length
175                ,, )
176        },
177
178        ResourceTemplate ()
179        {
180            QWordSpace (0xCD, ResourceConsumer, SubDecode, MinNotFixed, MaxFixed, 0xDA,
181                0xD8D9DADBDCDDDEDF, // Granularity
182                0xE0E1E2E3E4E5E6E7, // Range Minimum
183                0xE8E9EAEBECEDEEEF, // Range Maximum
184                0xF0F1F2F3F4F5F6F7, // Translation Offset
185                0xF8F9FAFBFCFDFEFF, // Length
186                ,, )
187        },
188
189        ResourceTemplate ()
190        {
191            QWordSpace (0xCE, ResourceConsumer, SubDecode, MinFixed, MaxNotFixed, 0xEA,
192                0xD8D9DADBDCDDDEDF, // Granularity
193                0xE0E1E2E3E4E5E6E7, // Range Minimum
194                0xE8E9EAEBECEDEEEF, // Range Maximum
195                0xF0F1F2F3F4F5F6F7, // Translation Offset
196                0xF8F9FAFBFCFDFEFF, // Length
197                ,, )
198        },
199
200        ResourceTemplate ()
201        {
202            QWordSpace (0xFF, ResourceConsumer, SubDecode, MinFixed, MaxFixed, 0xFA,
203                0xD8D9DADBDCDDDEDF, // Granularity
204                0xE0E1E2E3E4E5E6E7, // Range Minimum
205                0xE8E9EAEBECEDEEEF, // Range Maximum
206                0xF0F1F2F3F4F5F6F7, // Translation Offset
207                0xF8F9FAFBFCFDFEFF, // Length
208                ,, )
209        },
210
211        ResourceTemplate ()
212        {
213            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x00,
214                0xD8D9DADBDCDDDEDF, // Granularity
215                0xE0E1E2E3E4E5E6E7, // Range Minimum
216                0xE8E9EAEBECEDEEEF, // Range Maximum
217                0xF0F1F2F3F4F5F6F7, // Translation Offset
218                0xF8F9FAFBFCFDFEFF, // Length
219                ,, )
220        },
221
222        ResourceTemplate ()
223        {
224            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0xFF,
225                0xD8D9DADBDCDDDEDF, // Granularity
226                0xE0E1E2E3E4E5E6E7, // Range Minimum
227                0xE8E9EAEBECEDEEEF, // Range Maximum
228                0xF0F1F2F3F4F5F6F7, // Translation Offset
229                0xF8F9FAFBFCFDFEFF, // Length
230                ,, )
231        },
232
233        ResourceTemplate ()
234        {
235            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
236                0xD8D9DADBDCDDDEDF, // Granularity
237                0xE0E1E2E3E4E5E6E7, // Range Minimum
238                0xE8E9EAEBECEDEEEF, // Range Maximum
239                0xF0F1F2F3F4F5F6F7, // Translation Offset
240                0xF8F9FAFBFCFDFEFF, // Length
241                ,, )
242        },
243
244        ResourceTemplate ()
245        {
246            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
247                0xD8D9DADBDCDDDEDF, // Granularity
248                0xE0E1E2E3E4E5E6E7, // Range Minimum
249                0xE8E9EAEBECEDEEEF, // Range Maximum
250                0xF0F1F2F3F4F5F6F7, // Translation Offset
251                0xF8F9FAFBFCFDFEFF, // Length
252                ,, )
253        },
254
255        ResourceTemplate ()
256        {
257            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
258                0xD8D9DADBDCDDDEDF, // Granularity
259                0xE0E1E2E3E4E5E6E7, // Range Minimum
260                0xE8E9EAEBECEDEEEF, // Range Maximum
261                0xF0F1F2F3F4F5F6F7, // Translation Offset
262                0xF8F9FAFBFCFDFEFF, // Length
263                0x01, "", )
264        },
265
266        ResourceTemplate ()
267        {
268            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
269                0xD8D9DADBDCDDDEDF, // Granularity
270                0xE0E1E2E3E4E5E6E7, // Range Minimum
271                0xE8E9EAEBECEDEEEF, // Range Maximum
272                0xF0F1F2F3F4F5F6F7, // Translation Offset
273                0xF8F9FAFBFCFDFEFF, // Length
274                0x0F, "P", )
275        },
276
277        ResourceTemplate ()
278        {
279            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
280                0xD8D9DADBDCDDDEDF, // Granularity
281                0xE0E1E2E3E4E5E6E7, // Range Minimum
282                0xE8E9EAEBECEDEEEF, // Range Maximum
283                0xF0F1F2F3F4F5F6F7, // Translation Offset
284                0xF8F9FAFBFCFDFEFF, // Length
285                0xF0, "PATH", )
286        },
287
288        ResourceTemplate ()
289        {
290            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
291                0xD8D9DADBDCDDDEDF, // Granularity
292                0xE0E1E2E3E4E5E6E7, // Range Minimum
293                0xE8E9EAEBECEDEEEF, // Range Maximum
294                0xF0F1F2F3F4F5F6F7, // Translation Offset
295                0xF8F9FAFBFCFDFEFF, // Length
296                0xFF, "!\"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ !\"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ !\"#$%&\'()*", )
297        },
298
299        ResourceTemplate ()
300        {
301            QWordSpace (0xC0, ResourceConsumer, SubDecode, MinFixed, MaxFixed, 0x5A,
302                0xD8D9DADBDCDDDEDF, // Granularity
303                0xE0E1E2E3E4E5E6E7, // Range Minimum
304                0xE8E9EAEBECEDEEEF, // Range Maximum
305                0xF0F1F2F3F4F5F6F7, // Translation Offset
306                0xF8F9FAFBFCFDFEFF, // Length
307                0xFF, "PATHPATHPATH", )
308        },
309
310        ResourceTemplate ()
311        {
312            QWordSpace (0xC0, ResourceConsumer, SubDecode, MinFixed, MaxFixed, 0x00,
313                0x0000000000000000, // Granularity
314                0x0000000000000000, // Range Minimum
315                0x0000000000000000, // Range Maximum
316                0x0000000000000000, // Translation Offset
317                0x0000000000000000, // Length
318                0xFF, "PATHPATHPATH", )
319        },
320
321        ResourceTemplate ()
322        {
323            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
324                0xD8D9DADBDCDDDEDF, // Granularity
325                0xE0E1E2E3E4E5E6E7, // Range Minimum
326                0xE8E9EAEBECEDEEEF, // Range Maximum
327                0xF0F1F2F3F4F5F6F7, // Translation Offset
328                0xF8F9FAFBFCFDFEFF, // Length
329                0x0F,, )
330        }
331    })
332    /*
333     ACPI Specification, Revision 3.0, September 2, 2004
334     6.4.3.5.1   QWord Address Space Descriptor
335     Memory QWord Address Space Descriptor layout:
336     Byte 0 (Tag Bits): Value=10001010B (0x8a) (Type = 1, Large item name = 0xA)
337     Byte 1 (Length, bits[7:0]): Variable: Value = 43 (minimum)
338     Byte 2 (Length, bits[15:8]): Variable: Value = 0 (minimum)
339     Byte 3 (Resource Type):
340     192-255	Hardware Vendor Defined
341     Byte 4 (General Flags):
342     Bits[7:4] 	Reserved (must be 0)
343     Bit[3] 		Min Address Fixed, _MAF:
344     1	The specified maximum address is fixed
345     0	The specified maximum address is not fixed
346     and can be changed
347     Bit[2] 		Max Address Fixed,_MIF:
348     1	The specified minimum address is fixed
349     0	The specified minimum address is not fixed
350     and can be changed
351     Bit[1] 		Decode Type, _DEC:
352     1	This bridge subtractively decodes this address
353     (top level bridges only)
354     0	This bridge positively decodes this address
355     Bit[0] 		Consumer/Producer:
356     1-This device consumes this resource
357     0-This device produces and consumes this resource
358     Byte 5 (Type Specific Flags):
359     Flags that are specific to each resource type. The meaning of the flags
360     in this field depends on the value of the Resource Type field (see above)
361     Byte 6 (Address space granularity, _GRA bits[7:0]):
362     A set bit in this mask means that this bit is decoded. All bits less
363     significant than the most significant set bit must be set. (in other
364     words, the value of the full Address Space Granularity field (all 32
365     bits) must be a number (2**n-1).
366     Byte 7 (Address space granularity, _GRA bits[15:8])
367     Byte 8 (Address space granularity, _GRA bits[23:16])
368     Byte 9 (Address space granularity, _GRA bits[31:24])
369     Byte 10 (Address space granularity, _GRA bits[39:32])
370     Byte 11 (Address space granularity, _GRA bits[47:40])
371     Byte 12 (Address space granularity, _GRA bits[55:48])
372     Byte 13 (Address space granularity, _GRA bits[63:56])
373     Byte 14 (Address range minimum, _MIN bits [7:0]):
374     For bridges that translate addresses, this is the address space
375     on the secondary side of the bridge
376     Byte 15 (Address range minimum, _MIN bits[15:8])
377     Byte 16 (Address range minimum, _MIN bits[23:16])
378     Byte 17 (Address range minimum, _MIN bits[31:24])
379     Byte 18 (Address range minimum, _MIN bits[39:32])
380     Byte 19 (Address range minimum, _MIN bits[47:40])
381     Byte 20 (Address range minimum, _MIN bits[55:48])
382     Byte 21 (Address range minimum, _MIN bits[63:56])
383     Byte 22 (Address range maximum, _MAX bits [7:0]): See comment for _MIN
384     Byte 23 (Address range maximum, _MAX bits[15:8])
385     Byte 24 (Address range maximum, _MAX bits[23:16])
386     Byte 25 (Address range maximum, _MAX bits[31:24])
387     Byte 26 (Address range maximum, _MAX bits[39:32])
388     Byte 27 (Address range maximum, _MAX bits[47:40])
389     Byte 28 (Address range maximum, _MAX bits[55:48])
390     Byte 29 (Address range maximum, _MAX bits[63:56])
391     Byte 30 (Address Translation offset, _TRA bits [7:0]):
392     For bridges that translate addresses across the bridge, this is the
393     offset that must be added to the address on the secondary side to obtain
394     the address on the primary side. Non-bridge devices must list 0 for all
395     Address Translation offset bits
396     Byte 31 (Address Translation offset, _TRA bits[15:8])
397     Byte 32 (Address Translation offset, _TRA bits[23:16])
398     Byte 33 (Address Translation offset, _TRA bits[31:24])
399     Byte 34 (Address Translation offset, _TRA bits[39:32])
400     Byte 35 (Address Translation offset, _TRA bits[47:40])
401     Byte 36 (Address Translation offset, _TRA bits[55:48])
402     Byte 37 (Address Translation offset, _TRA bits[63:56])
403     Byte 38 (Address Length, _LEN bits [7:0])
404     Byte 39 (Address Length, _LEN bits[15:8])
405     Byte 40 (Address Length, _LEN bits[23:16])
406     Byte 41 (Address Length, _LEN bits[31:24])
407     Byte 42 (Address Length, _LEN bits[39:32])
408     Byte 43 (Address Length, _LEN bits[47:40])
409     Byte 44 (Address Length, _LEN bits[55:48])
410     Byte 45 (Address Length, _LEN bits[63:56])
411     Byte 46 (Resource Source Index):
412     (Optional) Only present if Resource Source (below) is present. This
413     field gives an index to the specific resource descriptor that this
414     device consumes from in the current resource template for the device
415     object pointed to in Resource Source
416     String (Resource Source):
417     (Optional) If present, the device that uses this descriptor consumes
418     its resources from the resources produced by the named device object.
419     If not present, the device consumes its resources out of a global pool.
420     If not present, the device consumes this resource from its hierarchical
421     parent.
422     */
423    Name (P42D, Package (0x1B)
424    {
425        /* Byte 4 (General Flags) of QWord Address Space Descriptor */
426
427        ResourceTemplate ()
428        {
429            QWordSpace (0xC0, ResourceProducer, PosDecode, MinNotFixed, MaxNotFixed, 0x0A,
430                0xD8D9DADBDCDDDEDF, // Granularity
431                0xE0E1E2E3E4E5E6E7, // Range Minimum
432                0xE8E9EAEBECEDEEEF, // Range Maximum
433                0xF0F1F2F3F4F5F6F7, // Translation Offset
434                0xF8F9FAFBFCFDFEFF, // Length
435                ,, )
436        },
437
438        ResourceTemplate ()
439        {
440            QWordSpace (0xC1, ResourceProducer, PosDecode, MinNotFixed, MaxFixed, 0x1A,
441                0xD8D9DADBDCDDDEDF, // Granularity
442                0xE0E1E2E3E4E5E6E7, // Range Minimum
443                0xE8E9EAEBECEDEEEF, // Range Maximum
444                0xF0F1F2F3F4F5F6F7, // Translation Offset
445                0xF8F9FAFBFCFDFEFF, // Length
446                ,, )
447        },
448
449        ResourceTemplate ()
450        {
451            QWordSpace (0xC2, ResourceProducer, PosDecode, MinFixed, MaxNotFixed, 0x2A,
452                0xD8D9DADBDCDDDEDF, // Granularity
453                0xE0E1E2E3E4E5E6E7, // Range Minimum
454                0xE8E9EAEBECEDEEEF, // Range Maximum
455                0xF0F1F2F3F4F5F6F7, // Translation Offset
456                0xF8F9FAFBFCFDFEFF, // Length
457                ,, )
458        },
459
460        ResourceTemplate ()
461        {
462            QWordSpace (0xC3, ResourceProducer, PosDecode, MinFixed, MaxFixed, 0x3A,
463                0xD8D9DADBDCDDDEDF, // Granularity
464                0xE0E1E2E3E4E5E6E7, // Range Minimum
465                0xE8E9EAEBECEDEEEF, // Range Maximum
466                0xF0F1F2F3F4F5F6F7, // Translation Offset
467                0xF8F9FAFBFCFDFEFF, // Length
468                ,, )
469        },
470
471        ResourceTemplate ()
472        {
473            QWordSpace (0xC4, ResourceProducer, SubDecode, MinNotFixed, MaxNotFixed, 0x4A,
474                0xD8D9DADBDCDDDEDF, // Granularity
475                0xE0E1E2E3E4E5E6E7, // Range Minimum
476                0xE8E9EAEBECEDEEEF, // Range Maximum
477                0xF0F1F2F3F4F5F6F7, // Translation Offset
478                0xF8F9FAFBFCFDFEFF, // Length
479                ,, )
480        },
481
482        ResourceTemplate ()
483        {
484            QWordSpace (0xC5, ResourceProducer, SubDecode, MinNotFixed, MaxFixed, 0x5A,
485                0xD8D9DADBDCDDDEDF, // Granularity
486                0xE0E1E2E3E4E5E6E7, // Range Minimum
487                0xE8E9EAEBECEDEEEF, // Range Maximum
488                0xF0F1F2F3F4F5F6F7, // Translation Offset
489                0xF8F9FAFBFCFDFEFF, // Length
490                ,, )
491        },
492
493        ResourceTemplate ()
494        {
495            QWordSpace (0xC6, ResourceProducer, SubDecode, MinFixed, MaxNotFixed, 0x6A,
496                0xD8D9DADBDCDDDEDF, // Granularity
497                0xE0E1E2E3E4E5E6E7, // Range Minimum
498                0xE8E9EAEBECEDEEEF, // Range Maximum
499                0xF0F1F2F3F4F5F6F7, // Translation Offset
500                0xF8F9FAFBFCFDFEFF, // Length
501                ,, )
502        },
503
504        ResourceTemplate ()
505        {
506            QWordSpace (0xC7, ResourceProducer, SubDecode, MinFixed, MaxFixed, 0x7A,
507                0xD8D9DADBDCDDDEDF, // Granularity
508                0xE0E1E2E3E4E5E6E7, // Range Minimum
509                0xE8E9EAEBECEDEEEF, // Range Maximum
510                0xF0F1F2F3F4F5F6F7, // Translation Offset
511                0xF8F9FAFBFCFDFEFF, // Length
512                ,, )
513        },
514
515        ResourceTemplate ()
516        {
517            QWordSpace (0xC8, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x8A,
518                0xD8D9DADBDCDDDEDF, // Granularity
519                0xE0E1E2E3E4E5E6E7, // Range Minimum
520                0xE8E9EAEBECEDEEEF, // Range Maximum
521                0xF0F1F2F3F4F5F6F7, // Translation Offset
522                0xF8F9FAFBFCFDFEFF, // Length
523                ,, )
524        },
525
526        ResourceTemplate ()
527        {
528            QWordSpace (0xC9, ResourceConsumer, PosDecode, MinNotFixed, MaxFixed, 0x9A,
529                0xD8D9DADBDCDDDEDF, // Granularity
530                0xE0E1E2E3E4E5E6E7, // Range Minimum
531                0xE8E9EAEBECEDEEEF, // Range Maximum
532                0xF0F1F2F3F4F5F6F7, // Translation Offset
533                0xF8F9FAFBFCFDFEFF, // Length
534                ,, )
535        },
536
537        ResourceTemplate ()
538        {
539            QWordSpace (0xCA, ResourceConsumer, PosDecode, MinFixed, MaxNotFixed, 0xAA,
540                0xD8D9DADBDCDDDEDF, // Granularity
541                0xE0E1E2E3E4E5E6E7, // Range Minimum
542                0xE8E9EAEBECEDEEEF, // Range Maximum
543                0xF0F1F2F3F4F5F6F7, // Translation Offset
544                0xF8F9FAFBFCFDFEFF, // Length
545                ,, )
546        },
547
548        ResourceTemplate ()
549        {
550            QWordSpace (0xCB, ResourceConsumer, PosDecode, MinFixed, MaxFixed, 0xBA,
551                0xD8D9DADBDCDDDEDF, // Granularity
552                0xE0E1E2E3E4E5E6E7, // Range Minimum
553                0xE8E9EAEBECEDEEEF, // Range Maximum
554                0xF0F1F2F3F4F5F6F7, // Translation Offset
555                0xF8F9FAFBFCFDFEFF, // Length
556                ,, )
557        },
558
559        ResourceTemplate ()
560        {
561            QWordSpace (0xCC, ResourceConsumer, SubDecode, MinNotFixed, MaxNotFixed, 0xCA,
562                0xD8D9DADBDCDDDEDF, // Granularity
563                0xE0E1E2E3E4E5E6E7, // Range Minimum
564                0xE8E9EAEBECEDEEEF, // Range Maximum
565                0xF0F1F2F3F4F5F6F7, // Translation Offset
566                0xF8F9FAFBFCFDFEFF, // Length
567                ,, )
568        },
569
570        ResourceTemplate ()
571        {
572            QWordSpace (0xCD, ResourceConsumer, SubDecode, MinNotFixed, MaxFixed, 0xDA,
573                0xD8D9DADBDCDDDEDF, // Granularity
574                0xE0E1E2E3E4E5E6E7, // Range Minimum
575                0xE8E9EAEBECEDEEEF, // Range Maximum
576                0xF0F1F2F3F4F5F6F7, // Translation Offset
577                0xF8F9FAFBFCFDFEFF, // Length
578                ,, )
579        },
580
581        ResourceTemplate ()
582        {
583            QWordSpace (0xCE, ResourceConsumer, SubDecode, MinFixed, MaxNotFixed, 0xEA,
584                0xD8D9DADBDCDDDEDF, // Granularity
585                0xE0E1E2E3E4E5E6E7, // Range Minimum
586                0xE8E9EAEBECEDEEEF, // Range Maximum
587                0xF0F1F2F3F4F5F6F7, // Translation Offset
588                0xF8F9FAFBFCFDFEFF, // Length
589                ,, )
590        },
591
592        ResourceTemplate ()
593        {
594            QWordSpace (0xFF, ResourceConsumer, SubDecode, MinFixed, MaxFixed, 0xFA,
595                0xD8D9DADBDCDDDEDF, // Granularity
596                0xE0E1E2E3E4E5E6E7, // Range Minimum
597                0xE8E9EAEBECEDEEEF, // Range Maximum
598                0xF0F1F2F3F4F5F6F7, // Translation Offset
599                0xF8F9FAFBFCFDFEFF, // Length
600                ,, )
601        },
602
603        /* Byte 5 (Type Specific Flags) of QWord Address Space Descriptor */
604
605        ResourceTemplate ()
606        {
607            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x00,
608                0xD8D9DADBDCDDDEDF, // Granularity
609                0xE0E1E2E3E4E5E6E7, // Range Minimum
610                0xE8E9EAEBECEDEEEF, // Range Maximum
611                0xF0F1F2F3F4F5F6F7, // Translation Offset
612                0xF8F9FAFBFCFDFEFF, // Length
613                ,, )
614        },
615
616        ResourceTemplate ()
617        {
618            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0xFF,
619                0xD8D9DADBDCDDDEDF, // Granularity
620                0xE0E1E2E3E4E5E6E7, // Range Minimum
621                0xE8E9EAEBECEDEEEF, // Range Maximum
622                0xF0F1F2F3F4F5F6F7, // Translation Offset
623                0xF8F9FAFBFCFDFEFF, // Length
624                ,, )
625        },
626
627        /* Particular cases */
628
629        ResourceTemplate ()
630        {
631            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
632                0xD8D9DADBDCDDDEDF, // Granularity
633                0xE0E1E2E3E4E5E6E7, // Range Minimum
634                0xE8E9EAEBECEDEEEF, // Range Maximum
635                0xF0F1F2F3F4F5F6F7, // Translation Offset
636                0xF8F9FAFBFCFDFEFF, // Length
637                ,, )
638        },
639
640        ResourceTemplate ()
641        {
642            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
643                0xD8D9DADBDCDDDEDF, // Granularity
644                0xE0E1E2E3E4E5E6E7, // Range Minimum
645                0xE8E9EAEBECEDEEEF, // Range Maximum
646                0xF0F1F2F3F4F5F6F7, // Translation Offset
647                0xF8F9FAFBFCFDFEFF, // Length
648                ,, )
649        },
650
651        /* Resource Source */
652
653        ResourceTemplate ()
654        {
655            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
656                0xD8D9DADBDCDDDEDF, // Granularity
657                0xE0E1E2E3E4E5E6E7, // Range Minimum
658                0xE8E9EAEBECEDEEEF, // Range Maximum
659                0xF0F1F2F3F4F5F6F7, // Translation Offset
660                0xF8F9FAFBFCFDFEFF, // Length
661                0x01, "", )
662        },
663
664        ResourceTemplate ()
665        {
666            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
667                0xD8D9DADBDCDDDEDF, // Granularity
668                0xE0E1E2E3E4E5E6E7, // Range Minimum
669                0xE8E9EAEBECEDEEEF, // Range Maximum
670                0xF0F1F2F3F4F5F6F7, // Translation Offset
671                0xF8F9FAFBFCFDFEFF, // Length
672                0x0F, "P", )
673        },
674
675        ResourceTemplate ()
676        {
677            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
678                0xD8D9DADBDCDDDEDF, // Granularity
679                0xE0E1E2E3E4E5E6E7, // Range Minimum
680                0xE8E9EAEBECEDEEEF, // Range Maximum
681                0xF0F1F2F3F4F5F6F7, // Translation Offset
682                0xF8F9FAFBFCFDFEFF, // Length
683                0xF0, "PATH", )
684        },
685
686        ResourceTemplate ()
687        {
688            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
689                0xD8D9DADBDCDDDEDF, // Granularity
690                0xE0E1E2E3E4E5E6E7, // Range Minimum
691                0xE8E9EAEBECEDEEEF, // Range Maximum
692                0xF0F1F2F3F4F5F6F7, // Translation Offset
693                0xF8F9FAFBFCFDFEFF, // Length
694                0xFF, "!\"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ !\"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ !\"#$%&\'()*", )
695        },
696
697        /* Particular cases */
698
699        ResourceTemplate ()
700        {
701            QWordSpace (0xC0, ResourceConsumer, SubDecode, MinFixed, MaxFixed, 0x5A,
702                0xD8D9DADBDCDDDEDF, // Granularity
703                0xE0E1E2E3E4E5E6E7, // Range Minimum
704                0xE8E9EAEBECEDEEEF, // Range Maximum
705                0xF0F1F2F3F4F5F6F7, // Translation Offset
706                0xF8F9FAFBFCFDFEFF, // Length
707                0xFF, "PATHPATHPATH", )
708        },
709
710        ResourceTemplate ()
711        {
712            QWordSpace (0xC0, ResourceConsumer, SubDecode, MinFixed, MaxFixed, 0x00,
713                0x0000000000000000, // Granularity
714                0x0000000000000000, // Range Minimum
715                0x0000000000000000, // Range Maximum
716                0x0000000000000000, // Translation Offset
717                0x0000000000000000, // Length
718                0xFF, "PATHPATHPATH", )
719        },
720
721        /* 20051021, relaxation for omitted ResourceSource (bug-fix 70 rejection) */
722
723        ResourceTemplate ()
724        {
725            QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
726                0xD8D9DADBDCDDDEDF, // Granularity
727                0xE0E1E2E3E4E5E6E7, // Range Minimum
728                0xE8E9EAEBECEDEEEF, // Range Maximum
729                0xF0F1F2F3F4F5F6F7, // Translation Offset
730                0xF8F9FAFBFCFDFEFF, // Length
731                0x0F,, )
732        }
733    })
734    Method (RT14, 0, Serialized)
735    {
736        /* Emit test header, set the filename */
737
738        THDR (__METHOD__, "QWordSpace Resource Descriptor Macro", "qwordspace.asl")
739        /* Main test case for packages above */
740
741        M330 (__METHOD__, 0x1B, "p42c", P42C, P42D)
742        /* Check resource descriptor tag offsets */
743
744        Local0 = ResourceTemplate ()
745            {
746                QWordSpace (0xC0, ResourceProducer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
747                    0xD8D9DADBDCDDDEDF, // Granularity
748                    0xE0E1E2E3E4E5E6E7, // Range Minimum
749                    0xE8E9EAEBECEDEEEF, // Range Maximum
750                    0xF0F1F2F3F4F5F6F7, // Translation Offset
751                    0xF8F9FAFBFCFDFEFF, // Length
752                    ,, )
753                QWordSpace (0xC0, ResourceConsumer, PosDecode, MinNotFixed, MaxNotFixed, 0x5A,
754                    0xD8D9DADBDCDDDEDF, // Granularity
755                    0xE0E1E2E3E4E5E6E7, // Range Minimum
756                    0xE8E9EAEBECEDEEEF, // Range Maximum
757                    0xF0F1F2F3F4F5F6F7, // Translation Offset
758                    0xF8F9FAFBFCFDFEFF, // Length
759                    ,, )
760            }
761        M331 (__METHOD__, 0x01, 0x21, 0x21, 0x0191, 0x0191, "_DEC")
762        M331 (__METHOD__, 0x02, 0x22, 0x22, 0x0192, 0x0192, "_MIF")
763        M331 (__METHOD__, 0x03, 0x23, 0x23, 0x0193, 0x0193, "_MAF")
764        M331 (__METHOD__, 0x07, 0x30, 0x30, 0x01A0, 0x01A0, "_GRA")
765        M331 (__METHOD__, 0x08, 0x70, 0x70, 0x01E0, 0x01E0, "_MIN")
766        M331 (__METHOD__, 0x09, 0xB0, 0xB0, 0x0220, 0x0220, "_MAX")
767        M331 (__METHOD__, 0x0A, 0xF0, 0xF0, 0x0260, 0x0260, "_TRA")
768        M331 (__METHOD__, 0x0B, 0x0130, 0x0130, 0x02A0, 0x02A0, "_LEN")
769    }
770