• Home
  • History
  • Annotate
  • Line#
  • Navigate
  • Raw
  • Download
  • only in /barrelfish-2018-10-04/lib/acpica/tests/aslts/src/runtime/collections/functional/descriptor/
1/*
2 * Some or all of this work - Copyright (c) 2006 - 2016, 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/*
30 * Resource Descriptor macros
31 *
32 * DWord IO Resource Descriptor Macro
33 */
34
35Name (p418, Package() {
36
37	// Byte 4 (General Flags) of DWord Address Space Descriptor
38
39	ResourceTemplate () {
40		DWordIO (ResourceProducer, MinNotFixed, MaxNotFixed, PosDecode, ,
41			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
42	},
43	ResourceTemplate () {
44		DWordIO (ResourceProducer, MinNotFixed, MaxNotFixed, SubDecode, ,
45			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
46	},
47	ResourceTemplate () {
48		DWordIO (ResourceProducer, MinNotFixed, MaxFixed, PosDecode, ,
49			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
50	},
51	ResourceTemplate () {
52		DWordIO (ResourceProducer, MinNotFixed, MaxFixed, SubDecode, ,
53			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
54	},
55	ResourceTemplate () {
56		DWordIO (ResourceProducer, MinFixed, MaxNotFixed, PosDecode, ,
57			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
58	},
59	ResourceTemplate () {
60		DWordIO (ResourceProducer, MinFixed, MaxNotFixed, SubDecode, ,
61			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
62	},
63	ResourceTemplate () {
64		DWordIO (ResourceProducer, MinFixed, MaxFixed, PosDecode, ,
65			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
66	},
67	ResourceTemplate () {
68		DWordIO (ResourceProducer, MinFixed, MaxFixed, SubDecode, ,
69			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
70	},
71	ResourceTemplate () {
72		DWordIO (ResourceConsumer, MinNotFixed, MaxNotFixed, PosDecode, ,
73			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
74	},
75	ResourceTemplate () {
76		DWordIO (ResourceConsumer, MinNotFixed, MaxNotFixed, SubDecode, ,
77			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
78	},
79	ResourceTemplate () {
80		DWordIO (ResourceConsumer, MinNotFixed, MaxFixed, PosDecode, ,
81			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
82	},
83	ResourceTemplate () {
84		DWordIO (ResourceConsumer, MinNotFixed, MaxFixed, SubDecode, ,
85			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
86	},
87	ResourceTemplate () {
88		DWordIO (ResourceConsumer, MinFixed, MaxNotFixed, PosDecode, ,
89			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
90	},
91	ResourceTemplate () {
92		DWordIO (ResourceConsumer, MinFixed, MaxNotFixed, SubDecode, ,
93			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
94	},
95	ResourceTemplate () {
96		DWordIO (ResourceConsumer, MinFixed, MaxFixed, PosDecode, ,
97			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
98	},
99	ResourceTemplate () {
100		DWordIO (ResourceConsumer, MinFixed, MaxFixed, SubDecode, ,
101			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
102	},
103
104	// Byte 5 (Type Specific Flags) of DWord Address Space Descriptor
105
106	ResourceTemplate () {
107		DWordIO ( , , , , NonISAOnlyRanges,
108			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
109			 , , , TypeStatic, DenseTranslation)
110	},
111	ResourceTemplate () {
112		DWordIO ( , , , , NonISAOnlyRanges,
113			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
114			 , , , TypeStatic, SparseTranslation)
115	},
116	ResourceTemplate () {
117		DWordIO ( , , , , NonISAOnlyRanges,
118			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
119			 , , , TypeTranslation, DenseTranslation)
120	},
121	ResourceTemplate () {
122		DWordIO ( , , , , NonISAOnlyRanges,
123			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
124			 , , , TypeTranslation, SparseTranslation)
125	},
126	ResourceTemplate () {
127		DWordIO ( , , , , ISAOnlyRanges,
128			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
129			 , , , TypeStatic, DenseTranslation)
130	},
131	ResourceTemplate () {
132		DWordIO ( , , , , ISAOnlyRanges,
133			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
134			 , , , TypeStatic, SparseTranslation)
135	},
136	ResourceTemplate () {
137		DWordIO ( , , , , ISAOnlyRanges,
138			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
139			 , , , TypeTranslation, DenseTranslation)
140	},
141	ResourceTemplate () {
142		DWordIO ( , , , , ISAOnlyRanges,
143			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
144			 , , , TypeTranslation, SparseTranslation)
145	},
146	ResourceTemplate () {
147		DWordIO ( , , , , EntireRange,
148			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
149			 , , , TypeStatic, DenseTranslation)
150	},
151	ResourceTemplate () {
152		DWordIO ( , , , , EntireRange,
153			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
154			 , , , TypeStatic, SparseTranslation)
155	},
156	ResourceTemplate () {
157		DWordIO ( , , , , EntireRange,
158			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
159			 , , , TypeTranslation, DenseTranslation)
160	},
161	ResourceTemplate () {
162		DWordIO ( , , , , EntireRange,
163			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
164			 , , , TypeTranslation, SparseTranslation)
165	},
166
167	// Particular cases
168
169	ResourceTemplate () {
170		DWordIO ( , , , , ,
171			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff)
172	},
173	ResourceTemplate () {
174		DWordIO ( , , , , ,
175			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
176			, , , , )
177	},
178
179	// Resource Source
180
181	ResourceTemplate () {
182		DWordIO ( , , , , ,
183			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
184			0x01, "", , , )
185	},
186	ResourceTemplate () {
187		DWordIO ( , , , , ,
188			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
189			0x0f, "P", , , )
190	},
191	ResourceTemplate () {
192		DWordIO ( , , , , ,
193			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
194			0xf0, "PATH", , , )
195	},
196	ResourceTemplate () {
197		DWordIO ( , , , , ,
198			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
199			0xff,
200			"!\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ !\"#$%&'()*",
201			  , , )
202	},
203
204	// Particular cases
205
206	ResourceTemplate () {
207		DWordIO (ResourceConsumer, MinFixed, MaxFixed, SubDecode, EntireRange,
208			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
209			0xff, "PATHPATHPATH", DIO0, TypeTranslation, SparseTranslation)
210	},
211	ResourceTemplate () {
212		DWordIO (ResourceConsumer, MinFixed, MaxFixed, SubDecode, EntireRange,
213			0, 0, 0, 0, 0,
214			0xff, "PATHPATHPATH", , TypeTranslation, SparseTranslation)
215	},
216
217	// 20051021, relaxation for omitted ResourceSource (bug-fix 70 rejection)
218	ResourceTemplate () {
219		DWordIO ( , , , , ,
220			0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff,
221			0x0f)
222	},
223})
224
225/*
226ACPI Specification, Revision 3.0, September 2, 2004
2276.4.3.5.2   DWord Address Space Descriptor
228
229I/O DWord Address Space Descriptor layout:
230
231Byte 0 (Tag Bits): Value=10000111B (0x87) (Type = 1, Large item name = 0x7)
232Byte 1 (Length, bits[7:0]): Variable: Value = 23 (minimum)
233Byte 2 (Length, bits[15:8]): Variable: Value = 0 (minimum)
234Byte 3 (Resource Type):
235	1		I/O range
236Byte 4 (General Flags):
237	Bits[7:4] 	Reserved (must be 0)
238	Bit[3] 		Min Address Fixed, _MAF:
239			1	The specified maximum address is fixed
240			0	The specified maximum address is not fixed
241				and can be changed
242	Bit[2] 		Max Address Fixed,_MIF:
243			1	The specified minimum address is fixed
244			0	The specified minimum address is not fixed
245				and can be changed
246	Bit[1] 		Decode Type, _DEC:
247			1	This bridge subtractively decodes this address
248	 	 	 	(top level bridges only)
249			0	This bridge positively decodes this address
250	Bit[0] 		Consumer/Producer:
251			1-This device consumes this resource
252			0-This device produces and consumes this resource
253
254Byte 5 (Type Specific Flags):
255	Flags that are specific to each resource type. The meaning of the flags
256	in this field depends on the value of the Resource Type field (see above)
257	Bits[7:6]	Reserved (must be 0)
258	Bit[5]		Sparse Translation, _TRS. This bit is only meaningful if Bit[4] is set.
259			1	SparseTranslation: The primary-side memory address of any specific
260				I/O port within the secondary-side range can be found using
261				the following function.
262
263				address = (((port & 0xFFFc) << 10) || (port & 0xFFF)) + _TRA
264
265				In the address used to access the I/O port, bits[11:2] must be identical
266				to bits[21:12], this gives four bytes of I/O ports on each 4 KB page.
267			0	DenseTranslation: The primary-side memory address of any specific I/O port
268				within the secondary-side range can be found using the following function.
269
270				address = port + _TRA
271	Bit[4]		I/O to Memory Translation, _TTP
272			1	TypeTranslation: This resource, which is I/O on the secondary side of
273				the bridge, is memory on the primary side of the bridge.
274			0	TypeStatic: This resource, which is I/O on the secondary side of
275				the bridge, is also I/O on the primary side of the bridge.
276	Bit[3:2]	Reserved (must be 0)
277	Bit[1:0]	_RNG
278			3	Memory window covers the entire range
279			2	ISARangesOnly. This flag is for bridges on systems with multiple bridges.
280				Setting this bit means the memory window specified in this descriptor is
281				limited to the ISA I/O addresses that fall within the specified window.
282				The ISA I/O ranges are: n000-n0FF, n400-n4FF, n800-n8FF, nC00-nCFF. This
283				bit can only be set for bridges entirely configured through ACPI namespace.
284			1	NonISARangesOnly. This flag is for bridges on systems with multiple bridges.
285				Setting this bit means the memory window specified in this descriptor is
286				limited to the non-ISA I/O addresses that fall within the specified window.
287				The non-ISA I/O ranges are: n100-n3FF, n500-n7FF, n900-nBFF, nD00-nFFF.
288				This bit can only be set for bridges entirely configured through ACPI namespace.
289			0	Reserved
290
291Byte 6 (Address space granularity, _GRA bits[7:0]):
292	A set bit in this mask means that this bit is decoded. All bits less
293	significant than the most significant set bit must be set. (in other
294	words, the value of the full Address Space Granularity field (all 32
295	bits) must be a number (2**n-1).
296Byte 7 (Address space granularity, _GRA bits[15:8])
297Byte 8 (Address space granularity, _GRA bits[23:16])
298Byte 9 (Address space granularity, _GRA bits[31:24])
299Byte 10 (Address range minimum, _MIN bits [7:0]):
300	For bridges that translate addresses, this is the address space
301	on the secondary side of the bridge
302Byte 11 (Address range minimum, _MIN bits[15:8])
303Byte 12 (Address range minimum, _MIN bits[23:16])
304Byte 13 (Address range minimum, _MIN bits[31:24])
305Byte 14 (Address range maximum, _MAX bits [7:0]): See comment for _MIN
306Byte 15 (Address range maximum, _MAX bits[15:8])
307Byte 16 (Address range maximum, _MAX bits[23:16])
308Byte 17 (Address range maximum, _MAX bits[31:24])
309Byte 18 (Address Translation offset, _TRA bits [7:0]):
310	For bridges that translate addresses across the bridge, this is the
311	offset that must be added to the address on the secondary side to obtain
312	the address on the primary side. Non-bridge devices must list 0 for all
313	Address Translation offset bits
314Byte 19 (Address Translation offset, _TRA bits[15:8])
315Byte 20 (Address Translation offset, _TRA bits[23:16])
316Byte 21 (Address Translation offset, _TRA bits[31:24])
317Byte 22 (Address Length, _LEN bits [7:0])
318Byte 23 (Address Length, _LEN bits[15:8])
319Byte 24 (Address Length, _LEN bits[23:16])
320Byte 25 (Address Length, _LEN bits[31:24])
321Byte 26 (Resource Source Index):
322	(Optional) Only present if Resource Source (below) is present. This
323	field gives an index to the specific resource descriptor that this
324	device consumes from in the current resource template for the device
325	object pointed to in Resource Source
326String (Resource Source):
327	(Optional) If present, the device that uses this descriptor consumes
328	its resources from the resources produced by the named device object.
329	If not present, the device consumes its resources out of a global pool.
330	If not present, the device consumes this resource from its hierarchical
331	parent.
332*/
333
334Name (p419, Package() {
335
336	// Byte 4 (General Flags) of DWord Address Space Descriptor
337
338	Buffer () {0x87, 0x17, 0x00, 0x01, 0x00, 0x03, 0xef, 0xee, 0xed, 0xec,
339		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
340		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
341	Buffer () {0x87, 0x17, 0x00, 0x01, 0x02, 0x03, 0xef, 0xee, 0xed, 0xec,
342		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
343		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
344	Buffer () {0x87, 0x17, 0x00, 0x01, 0x08, 0x03, 0xef, 0xee, 0xed, 0xec,
345		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
346		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
347	Buffer () {0x87, 0x17, 0x00, 0x01, 0x0a, 0x03, 0xef, 0xee, 0xed, 0xec,
348		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
349		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
350	Buffer () {0x87, 0x17, 0x00, 0x01, 0x04, 0x03, 0xef, 0xee, 0xed, 0xec,
351		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
352		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
353	Buffer () {0x87, 0x17, 0x00, 0x01, 0x06, 0x03, 0xef, 0xee, 0xed, 0xec,
354		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
355		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
356	Buffer () {0x87, 0x17, 0x00, 0x01, 0x0c, 0x03, 0xef, 0xee, 0xed, 0xec,
357		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
358		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
359	Buffer () {0x87, 0x17, 0x00, 0x01, 0x0e, 0x03, 0xef, 0xee, 0xed, 0xec,
360		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
361		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
362	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
363		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
364		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
365	Buffer () {0x87, 0x17, 0x00, 0x01, 0x03, 0x03, 0xef, 0xee, 0xed, 0xec,
366		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
367		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
368	Buffer () {0x87, 0x17, 0x00, 0x01, 0x09, 0x03, 0xef, 0xee, 0xed, 0xec,
369		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
370		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
371	Buffer () {0x87, 0x17, 0x00, 0x01, 0x0b, 0x03, 0xef, 0xee, 0xed, 0xec,
372		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
373		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
374	Buffer () {0x87, 0x17, 0x00, 0x01, 0x05, 0x03, 0xef, 0xee, 0xed, 0xec,
375		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
376		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
377	Buffer () {0x87, 0x17, 0x00, 0x01, 0x07, 0x03, 0xef, 0xee, 0xed, 0xec,
378		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
379		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
380	Buffer () {0x87, 0x17, 0x00, 0x01, 0x0d, 0x03, 0xef, 0xee, 0xed, 0xec,
381		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
382		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
383	Buffer () {0x87, 0x17, 0x00, 0x01, 0x0f, 0x03, 0xef, 0xee, 0xed, 0xec,
384		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
385		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
386
387	// Byte 5 (Type Specific Flags) of DWord Address Space Descriptor
388
389	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x01, 0xef, 0xee, 0xed, 0xec,
390		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
391		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
392	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x21, 0xef, 0xee, 0xed, 0xec,
393		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
394		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
395	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x11, 0xef, 0xee, 0xed, 0xec,
396		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
397		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
398	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x31, 0xef, 0xee, 0xed, 0xec,
399		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
400		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
401	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x02, 0xef, 0xee, 0xed, 0xec,
402		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
403		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
404	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x22, 0xef, 0xee, 0xed, 0xec,
405		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
406		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
407	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x12, 0xef, 0xee, 0xed, 0xec,
408		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
409		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
410	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x32, 0xef, 0xee, 0xed, 0xec,
411		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
412		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
413	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
414		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
415		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
416	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x23, 0xef, 0xee, 0xed, 0xec,
417		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
418		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
419	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x13, 0xef, 0xee, 0xed, 0xec,
420		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
421		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
422	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x33, 0xef, 0xee, 0xed, 0xec,
423		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
424		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
425
426	// Particular cases
427
428	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
429		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
430		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
431	Buffer () {0x87, 0x17, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
432		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
433		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc, 0x79, 0x00},
434
435	// Resource Source
436
437	Buffer () {0x87, 0x19, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
438		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
439		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc,
440		0x01, 0x00, 0x79, 0x00},
441	Buffer () {0x87, 0x1a, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
442		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
443		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc,
444		0x0f, 0x50, 0x00, 0x79, 0x00},
445	Buffer () {0x87, 0x1d, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
446		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
447		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc,
448		0xf0, 0x50, 0x41, 0x54, 0x48, 0x00, 0x79, 0x00},
449	Buffer () {0x87, 0xe1, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
450		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
451		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc,
452		0xff,
453		0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28,
454		0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30,
455		0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38,
456		0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40,
457		0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48,
458		0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50,
459		0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58,
460		0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60,
461		0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68,
462		0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70,
463		0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78,
464		0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x20, 0x21,
465		0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29,
466		0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31,
467		0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39,
468		0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41,
469		0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49,
470		0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51,
471		0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59,
472		0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61,
473		0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69,
474		0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71,
475		0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79,
476		0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x20, 0x21, 0x22,
477		0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a,
478		0x00, 0x79, 0x00},
479
480	// Particular cases
481
482	Buffer () {0x87, 0x25, 0x00, 0x01, 0x0f, 0x33, 0xef, 0xee, 0xed, 0xec,
483		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
484		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc,
485		0xff, 0x50, 0x41, 0x54, 0x48, 0x50, 0x41, 0x54,
486		0x48, 0x50, 0x41, 0x54, 0x48, 0x00, 0x79, 0x00},
487	Buffer () {0x87, 0x25, 0x00, 0x01, 0x0f, 0x33, 0x00, 0x00, 0x00, 0x00,
488		0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
489		0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
490		0xff, 0x50, 0x41, 0x54, 0x48, 0x50, 0x41, 0x54,
491		0x48, 0x50, 0x41, 0x54, 0x48, 0x00, 0x79, 0x00},
492
493	// 20051021, relaxation for omitted ResourceSource (bug-fix 70 rejection)
494	Buffer () {0x87, 0x18, 0x00, 0x01, 0x01, 0x03, 0xef, 0xee, 0xed, 0xec,
495		0xf3, 0xf2, 0xf1, 0xf0, 0xf7, 0xf6, 0xf5, 0xf4,
496		0xfb, 0xfa, 0xf9, 0xf8, 0xff, 0xfe, 0xfd, 0xfc,
497		0x0f, 0x79, 0x00},
498})
499
500Method(RT0d,, Serialized)
501{
502	Name(ts, "RT0d")
503
504	// Emit test header, set the filename
505
506	THDR (ts, "DWordIo Resource Descriptor Macro", __FILE__)
507
508    // Main test case for packages above
509
510	m330(ts, 37, "p418", p418, p419)
511
512    // Check resource descriptor tag offsets
513
514	Store (
515		ResourceTemplate () {
516			DWordIO (ResourceProducer, MinNotFixed, MaxNotFixed, PosDecode, EntireRange,
517				0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff, , , DIO0)
518			DWordIO (ResourceConsumer, MinNotFixed, MaxNotFixed, PosDecode, EntireRange,
519				0xecedeeef, 0xf0f1f2f3, 0xf4f5f6f7, 0xf8f9fafb, 0xfcfdfeff, , , DIO1)
520		}, Local0)
521
522	m331(ts, 1,  DIO0._DEC, 0x21, DIO1._DEC, 0xf1, "_DEC")
523	m331(ts, 2,  DIO0._MIF, 0x22, DIO1._MIF, 0xf2, "_MIF")
524	m331(ts, 3,  DIO0._MAF, 0x23, DIO1._MAF, 0xf3, "_MAF")
525	m331(ts, 4,  DIO0._RNG, 0x28, DIO1._RNG, 0xf8, "_RNG")
526	m331(ts, 5,  DIO0._TTP, 0x2c, DIO1._TTP, 0xfc, "_TTP")
527	m331(ts, 6,  DIO0._TRS, 0x2d, DIO1._TRS, 0xfd, "_TRS")
528	m331(ts, 7,  DIO0._GRA, 0x30, DIO1._GRA, 0x100, "_GRA")
529	m331(ts, 8,  DIO0._MIN, 0x50, DIO1._MIN, 0x120, "_MIN")
530	m331(ts, 9,  DIO0._MAX, 0x70, DIO1._MAX, 0x140, "_MAX")
531	m331(ts, 10, DIO0._TRA, 0x90, DIO1._TRA, 0x160, "_TRA")
532	m331(ts, 11, DIO0._LEN, 0xB0, DIO1._LEN, 0x180, "_LEN")
533}
534
535
536