Sync ACPICA with Intel's version 20161117.
[dragonfly.git] / sys / contrib / dev / acpica / source / compiler / aslresources.y
blob34ce47574bc82f4962ccdb488135be62aea02424
1 NoEcho('
2 /******************************************************************************
4 * Module Name: aslresources.y - Bison/Yacc production rules for resources
6 *****************************************************************************/
8 /*
9 * Copyright (C) 2000 - 2016, Intel Corp.
10 * All rights reserved.
12 * Redistribution and use in source and binary forms, with or without
13 * modification, are permitted provided that the following conditions
14 * are met:
15 * 1. Redistributions of source code must retain the above copyright
16 * notice, this list of conditions, and the following disclaimer,
17 * without modification.
18 * 2. Redistributions in binary form must reproduce at minimum a disclaimer
19 * substantially similar to the "NO WARRANTY" disclaimer below
20 * ("Disclaimer") and any redistribution must be conditioned upon
21 * including a substantially similar Disclaimer requirement for further
22 * binary redistribution.
23 * 3. Neither the names of the above-listed copyright holders nor the names
24 * of any contributors may be used to endorse or promote products derived
25 * from this software without specific prior written permission.
27 * Alternatively, this software may be distributed under the terms of the
28 * GNU General Public License ("GPL") version 2 as published by the Free
29 * Software Foundation.
31 * NO WARRANTY
32 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
33 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
34 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
35 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
36 * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
37 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
38 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
39 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
40 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
41 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
42 * POSSIBILITY OF SUCH DAMAGES.
48 /*******************************************************************************
50 * ASL Resource Template Terms
52 ******************************************************************************/
55 * Note: Create two default nodes to allow conversion to a Buffer AML opcode
56 * Also, insert the EndTag at the end of the template.
58 ResourceTemplateTerm
59 : PARSEOP_RESOURCETEMPLATE
60 OptionalParentheses
61 '{'
62 ResourceMacroList '}' {$$ = TrCreateNode (PARSEOP_RESOURCETEMPLATE,4,
63 TrCreateLeafNode (PARSEOP_DEFAULT_ARG),
64 TrCreateLeafNode (PARSEOP_DEFAULT_ARG),
65 $4,
66 TrCreateLeafNode (PARSEOP_ENDTAG));}
69 OptionalParentheses
70 : {$$ = NULL;}
71 | PARSEOP_OPEN_PAREN
72 PARSEOP_CLOSE_PAREN {$$ = NULL;}
75 ResourceMacroList
76 : {$$ = NULL;}
77 | ResourceMacroList
78 ResourceMacroTerm {$$ = TrLinkPeerNode ($1,$2);}
81 ResourceMacroTerm
82 : DMATerm {}
83 | DWordIOTerm {}
84 | DWordMemoryTerm {}
85 | DWordSpaceTerm {}
86 | EndDependentFnTerm {}
87 | ExtendedIOTerm {}
88 | ExtendedMemoryTerm {}
89 | ExtendedSpaceTerm {}
90 | FixedDmaTerm {}
91 | FixedIOTerm {}
92 | GpioIntTerm {}
93 | GpioIoTerm {}
94 | I2cSerialBusTerm {}
95 | I2cSerialBusTermV2 {}
96 | InterruptTerm {}
97 | IOTerm {}
98 | IRQNoFlagsTerm {}
99 | IRQTerm {}
100 | Memory24Term {}
101 | Memory32FixedTerm {}
102 | Memory32Term {}
103 | QWordIOTerm {}
104 | QWordMemoryTerm {}
105 | QWordSpaceTerm {}
106 | RegisterTerm {}
107 | SpiSerialBusTerm {}
108 | SpiSerialBusTermV2 {}
109 | StartDependentFnNoPriTerm {}
110 | StartDependentFnTerm {}
111 | UartSerialBusTerm {}
112 | UartSerialBusTermV2 {}
113 | VendorLongTerm {}
114 | VendorShortTerm {}
115 | WordBusNumberTerm {}
116 | WordIOTerm {}
117 | WordSpaceTerm {}
120 DMATerm
121 : PARSEOP_DMA
122 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_DMA);}
123 DMATypeKeyword
124 OptionalBusMasterKeyword
125 ',' XferTypeKeyword
126 OptionalNameString_Last
127 PARSEOP_CLOSE_PAREN '{'
128 ByteList '}' {$$ = TrLinkChildren ($<n>3,5,$4,$5,$7,$8,$11);}
129 | PARSEOP_DMA
130 PARSEOP_OPEN_PAREN
131 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
134 DWordIOTerm
135 : PARSEOP_DWORDIO
136 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_DWORDIO);}
137 OptionalResourceType_First
138 OptionalMinType
139 OptionalMaxType
140 OptionalDecodeType
141 OptionalRangeType
142 ',' DWordConstExpr
143 ',' DWordConstExpr
144 ',' DWordConstExpr
145 ',' DWordConstExpr
146 ',' DWordConstExpr
147 OptionalByteConstExpr
148 OptionalStringData
149 OptionalNameString
150 OptionalType
151 OptionalTranslationType_Last
152 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,15,
153 $4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$19,$20,$21,$22,$23);}
154 | PARSEOP_DWORDIO
155 PARSEOP_OPEN_PAREN
156 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
159 DWordMemoryTerm
160 : PARSEOP_DWORDMEMORY
161 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_DWORDMEMORY);}
162 OptionalResourceType_First
163 OptionalDecodeType
164 OptionalMinType
165 OptionalMaxType
166 OptionalMemType
167 ',' OptionalReadWriteKeyword
168 ',' DWordConstExpr
169 ',' DWordConstExpr
170 ',' DWordConstExpr
171 ',' DWordConstExpr
172 ',' DWordConstExpr
173 OptionalByteConstExpr
174 OptionalStringData
175 OptionalNameString
176 OptionalAddressRange
177 OptionalType_Last
178 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,16,
179 $4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$20,$21,$22,$23,$24,$25);}
180 | PARSEOP_DWORDMEMORY
181 PARSEOP_OPEN_PAREN
182 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
185 DWordSpaceTerm
186 : PARSEOP_DWORDSPACE
187 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_DWORDSPACE);}
188 ByteConstExpr {UtCheckIntegerRange ($4, 0xC0, 0xFF);}
189 OptionalResourceType
190 OptionalDecodeType
191 OptionalMinType
192 OptionalMaxType
193 ',' ByteConstExpr
194 ',' DWordConstExpr
195 ',' DWordConstExpr
196 ',' DWordConstExpr
197 ',' DWordConstExpr
198 ',' DWordConstExpr
199 OptionalByteConstExpr
200 OptionalStringData
201 OptionalNameString_Last
202 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,14,
203 $4,$6,$7,$8,$9,$11,$13,$15,$17,$19,$21,$22,$23,$24);}
204 | PARSEOP_DWORDSPACE
205 PARSEOP_OPEN_PAREN
206 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
209 EndDependentFnTerm
210 : PARSEOP_ENDDEPENDENTFN
211 PARSEOP_OPEN_PAREN
212 PARSEOP_CLOSE_PAREN {$$ = TrCreateLeafNode (PARSEOP_ENDDEPENDENTFN);}
213 | PARSEOP_ENDDEPENDENTFN
214 PARSEOP_OPEN_PAREN
215 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
218 ExtendedIOTerm
219 : PARSEOP_EXTENDEDIO
220 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_EXTENDEDIO);}
221 OptionalResourceType_First
222 OptionalMinType
223 OptionalMaxType
224 OptionalDecodeType
225 OptionalRangeType
226 ',' QWordConstExpr
227 ',' QWordConstExpr
228 ',' QWordConstExpr
229 ',' QWordConstExpr
230 ',' QWordConstExpr
231 OptionalQWordConstExpr
232 OptionalNameString
233 OptionalType
234 OptionalTranslationType_Last
235 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,14,
236 $4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$19,$20,$21,$22);}
237 | PARSEOP_EXTENDEDIO
238 PARSEOP_OPEN_PAREN
239 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
242 ExtendedMemoryTerm
243 : PARSEOP_EXTENDEDMEMORY
244 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_EXTENDEDMEMORY);}
245 OptionalResourceType_First
246 OptionalDecodeType
247 OptionalMinType
248 OptionalMaxType
249 OptionalMemType
250 ',' OptionalReadWriteKeyword
251 ',' QWordConstExpr
252 ',' QWordConstExpr
253 ',' QWordConstExpr
254 ',' QWordConstExpr
255 ',' QWordConstExpr
256 OptionalQWordConstExpr
257 OptionalNameString
258 OptionalAddressRange
259 OptionalType_Last
260 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,15,
261 $4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$20,$21,$22,$23,$24);}
262 | PARSEOP_EXTENDEDMEMORY
263 PARSEOP_OPEN_PAREN
264 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
267 ExtendedSpaceTerm
268 : PARSEOP_EXTENDEDSPACE PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_EXTENDEDSPACE);}
269 ByteConstExpr {UtCheckIntegerRange ($4, 0xC0, 0xFF);}
270 OptionalResourceType
271 OptionalDecodeType
272 OptionalMinType
273 OptionalMaxType
274 ',' ByteConstExpr
275 ',' QWordConstExpr
276 ',' QWordConstExpr
277 ',' QWordConstExpr
278 ',' QWordConstExpr
279 ',' QWordConstExpr
280 OptionalQWordConstExpr
281 OptionalNameString_Last
282 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,13,
283 $4,$6,$7,$8,$9,$11,$13,$15,$17,$19,$21,$22,$23);}
284 | PARSEOP_EXTENDEDSPACE
285 PARSEOP_OPEN_PAREN
286 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
289 FixedDmaTerm
290 : PARSEOP_FIXEDDMA
291 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_FIXEDDMA);}
292 WordConstExpr /* 04: DMA RequestLines */
293 ',' WordConstExpr /* 06: DMA Channels */
294 OptionalXferSize /* 07: DMA TransferSize */
295 OptionalNameString /* 08: DescriptorName */
296 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,4,$4,$6,$7,$8);}
297 | PARSEOP_FIXEDDMA
298 PARSEOP_OPEN_PAREN
299 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
302 FixedIOTerm
303 : PARSEOP_FIXEDIO
304 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_FIXEDIO);}
305 WordConstExpr
306 ',' ByteConstExpr
307 OptionalNameString_Last
308 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,3,$4,$6,$7);}
309 | PARSEOP_FIXEDIO
310 PARSEOP_OPEN_PAREN
311 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
314 GpioIntTerm
315 : PARSEOP_GPIO_INT
316 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_GPIO_INT);}
317 InterruptTypeKeyword /* 04: InterruptType */
318 ',' InterruptLevel /* 06: InterruptLevel */
319 OptionalShareType /* 07: SharedType */
320 ',' PinConfigByte /* 09: PinConfig */
321 OptionalWordConstExpr /* 10: DebounceTimeout */
322 ',' StringData /* 12: ResourceSource */
323 OptionalByteConstExpr /* 13: ResourceSourceIndex */
324 OptionalResourceType /* 14: ResourceType */
325 OptionalNameString /* 15: DescriptorName */
326 OptionalBuffer_Last /* 16: VendorData */
327 PARSEOP_CLOSE_PAREN '{'
328 DWordConstExpr '}' {$$ = TrLinkChildren ($<n>3,11,
329 $4,$6,$7,$9,$10,$12,$13,$14,$15,$16,$19);}
330 | PARSEOP_GPIO_INT
331 PARSEOP_OPEN_PAREN
332 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
335 GpioIoTerm
336 : PARSEOP_GPIO_IO
337 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_GPIO_IO);}
338 OptionalShareType_First /* 04: SharedType */
339 ',' PinConfigByte /* 06: PinConfig */
340 OptionalWordConstExpr /* 07: DebounceTimeout */
341 OptionalWordConstExpr /* 08: DriveStrength */
342 OptionalIoRestriction /* 09: IoRestriction */
343 ',' StringData /* 11: ResourceSource */
344 OptionalByteConstExpr /* 12: ResourceSourceIndex */
345 OptionalResourceType /* 13: ResourceType */
346 OptionalNameString /* 14: DescriptorName */
347 OptionalBuffer_Last /* 15: VendorData */
348 PARSEOP_CLOSE_PAREN '{'
349 DWordList '}' {$$ = TrLinkChildren ($<n>3,11,
350 $4,$6,$7,$8,$9,$11,$12,$13,$14,$15,$18);}
351 | PARSEOP_GPIO_IO
352 PARSEOP_OPEN_PAREN
353 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
356 I2cSerialBusTerm
357 : PARSEOP_I2C_SERIALBUS
358 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_I2C_SERIALBUS);}
359 WordConstExpr /* 04: SlaveAddress */
360 OptionalSlaveMode /* 05: SlaveMode */
361 ',' DWordConstExpr /* 07: ConnectionSpeed */
362 OptionalAddressingMode /* 08: AddressingMode */
363 ',' StringData /* 10: ResourceSource */
364 OptionalByteConstExpr /* 11: ResourceSourceIndex */
365 OptionalResourceType /* 12: ResourceType */
366 OptionalNameString /* 13: DescriptorName */
367 OptionalBuffer_Last /* 14: VendorData */
368 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,10,
369 $4,$5,$7,$8,$10,$11,$12,$13,
370 TrCreateLeafNode (PARSEOP_DEFAULT_ARG),$14);}
371 | PARSEOP_I2C_SERIALBUS
372 PARSEOP_OPEN_PAREN
373 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
376 I2cSerialBusTermV2
377 : PARSEOP_I2C_SERIALBUS_V2
378 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_I2C_SERIALBUS_V2);}
379 WordConstExpr /* 04: SlaveAddress */
380 OptionalSlaveMode /* 05: SlaveMode */
381 ',' DWordConstExpr /* 07: ConnectionSpeed */
382 OptionalAddressingMode /* 08: AddressingMode */
383 ',' StringData /* 10: ResourceSource */
384 OptionalByteConstExpr /* 11: ResourceSourceIndex */
385 OptionalResourceType /* 12: ResourceType */
386 OptionalNameString /* 13: DescriptorName */
387 OptionalShareType /* 14: Share */
388 OptionalBuffer_Last /* 15: VendorData */
389 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,10,
390 $4,$5,$7,$8,$10,$11,$12,$13,$14,$15);}
391 | PARSEOP_I2C_SERIALBUS_V2
392 PARSEOP_OPEN_PAREN
393 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
396 InterruptTerm
397 : PARSEOP_INTERRUPT
398 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_INTERRUPT);}
399 OptionalResourceType_First
400 ',' InterruptTypeKeyword
401 ',' InterruptLevel
402 OptionalShareType
403 OptionalByteConstExpr
404 OptionalStringData
405 OptionalNameString_Last
406 PARSEOP_CLOSE_PAREN '{'
407 DWordList '}' {$$ = TrLinkChildren ($<n>3,8,
408 $4,$6,$8,$9,$10,$11,$12,$15);}
409 | PARSEOP_INTERRUPT
410 PARSEOP_OPEN_PAREN
411 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
414 IOTerm
415 : PARSEOP_IO
416 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_IO);}
417 IODecodeKeyword
418 ',' WordConstExpr
419 ',' WordConstExpr
420 ',' ByteConstExpr
421 ',' ByteConstExpr
422 OptionalNameString_Last
423 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,6,$4,$6,$8,$10,$12,$13);}
424 | PARSEOP_IO
425 PARSEOP_OPEN_PAREN
426 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
429 IRQNoFlagsTerm
430 : PARSEOP_IRQNOFLAGS
431 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_IRQNOFLAGS);}
432 OptionalNameString_First
433 PARSEOP_CLOSE_PAREN '{'
434 ByteList '}' {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
435 | PARSEOP_IRQNOFLAGS
436 PARSEOP_OPEN_PAREN
437 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
440 IRQTerm
441 : PARSEOP_IRQ
442 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_IRQ);}
443 InterruptTypeKeyword
444 ',' InterruptLevel
445 OptionalShareType
446 OptionalNameString_Last
447 PARSEOP_CLOSE_PAREN '{'
448 ByteList '}' {$$ = TrLinkChildren ($<n>3,5,$4,$6,$7,$8,$11);}
449 | PARSEOP_IRQ
450 PARSEOP_OPEN_PAREN
451 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
454 Memory24Term
455 : PARSEOP_MEMORY24
456 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_MEMORY24);}
457 OptionalReadWriteKeyword
458 ',' WordConstExpr
459 ',' WordConstExpr
460 ',' WordConstExpr
461 ',' WordConstExpr
462 OptionalNameString_Last
463 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,6,$4,$6,$8,$10,$12,$13);}
464 | PARSEOP_MEMORY24
465 PARSEOP_OPEN_PAREN
466 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
469 Memory32FixedTerm
470 : PARSEOP_MEMORY32FIXED
471 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_MEMORY32FIXED);}
472 OptionalReadWriteKeyword
473 ',' DWordConstExpr
474 ',' DWordConstExpr
475 OptionalNameString_Last
476 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,4,$4,$6,$8,$9);}
477 | PARSEOP_MEMORY32FIXED
478 PARSEOP_OPEN_PAREN
479 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
482 Memory32Term
483 : PARSEOP_MEMORY32
484 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_MEMORY32);}
485 OptionalReadWriteKeyword
486 ',' DWordConstExpr
487 ',' DWordConstExpr
488 ',' DWordConstExpr
489 ',' DWordConstExpr
490 OptionalNameString_Last
491 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,6,$4,$6,$8,$10,$12,$13);}
492 | PARSEOP_MEMORY32
493 PARSEOP_OPEN_PAREN
494 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
497 QWordIOTerm
498 : PARSEOP_QWORDIO
499 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_QWORDIO);}
500 OptionalResourceType_First
501 OptionalMinType
502 OptionalMaxType
503 OptionalDecodeType
504 OptionalRangeType
505 ',' QWordConstExpr
506 ',' QWordConstExpr
507 ',' QWordConstExpr
508 ',' QWordConstExpr
509 ',' QWordConstExpr
510 OptionalByteConstExpr
511 OptionalStringData
512 OptionalNameString
513 OptionalType
514 OptionalTranslationType_Last
515 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,15,
516 $4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$19,$20,$21,$22,$23);}
517 | PARSEOP_QWORDIO
518 PARSEOP_OPEN_PAREN
519 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
522 QWordMemoryTerm
523 : PARSEOP_QWORDMEMORY
524 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_QWORDMEMORY);}
525 OptionalResourceType_First
526 OptionalDecodeType
527 OptionalMinType
528 OptionalMaxType
529 OptionalMemType
530 ',' OptionalReadWriteKeyword
531 ',' QWordConstExpr
532 ',' QWordConstExpr
533 ',' QWordConstExpr
534 ',' QWordConstExpr
535 ',' QWordConstExpr
536 OptionalByteConstExpr
537 OptionalStringData
538 OptionalNameString
539 OptionalAddressRange
540 OptionalType_Last
541 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,16,
542 $4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$20,$21,$22,$23,$24,$25);}
543 | PARSEOP_QWORDMEMORY
544 PARSEOP_OPEN_PAREN
545 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
548 QWordSpaceTerm
549 : PARSEOP_QWORDSPACE
550 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_QWORDSPACE);}
551 ByteConstExpr {UtCheckIntegerRange ($4, 0xC0, 0xFF);}
552 OptionalResourceType
553 OptionalDecodeType
554 OptionalMinType
555 OptionalMaxType
556 ',' ByteConstExpr
557 ',' QWordConstExpr
558 ',' QWordConstExpr
559 ',' QWordConstExpr
560 ',' QWordConstExpr
561 ',' QWordConstExpr
562 OptionalByteConstExpr
563 OptionalStringData
564 OptionalNameString_Last
565 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,14,
566 $4,$6,$7,$8,$9,$11,$13,$15,$17,$19,$21,$22,$23,$24);}
567 | PARSEOP_QWORDSPACE
568 PARSEOP_OPEN_PAREN
569 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
572 RegisterTerm
573 : PARSEOP_REGISTER
574 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_REGISTER);}
575 AddressSpaceKeyword
576 ',' ByteConstExpr
577 ',' ByteConstExpr
578 ',' QWordConstExpr
579 OptionalAccessSize
580 OptionalNameString_Last
581 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,6,$4,$6,$8,$10,$11,$12);}
582 | PARSEOP_REGISTER
583 PARSEOP_OPEN_PAREN
584 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
587 SpiSerialBusTerm
588 : PARSEOP_SPI_SERIALBUS
589 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_SPI_SERIALBUS);}
590 WordConstExpr /* 04: DeviceSelection */
591 OptionalDevicePolarity /* 05: DevicePolarity */
592 OptionalWireMode /* 06: WireMode */
593 ',' ByteConstExpr /* 08: DataBitLength */
594 OptionalSlaveMode /* 09: SlaveMode */
595 ',' DWordConstExpr /* 11: ConnectionSpeed */
596 ',' ClockPolarityKeyword /* 13: ClockPolarity */
597 ',' ClockPhaseKeyword /* 15: ClockPhase */
598 ',' StringData /* 17: ResourceSource */
599 OptionalByteConstExpr /* 18: ResourceSourceIndex */
600 OptionalResourceType /* 19: ResourceType */
601 OptionalNameString /* 20: DescriptorName */
602 OptionalBuffer_Last /* 21: VendorData */
603 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,14,
604 $4,$5,$6,$8,$9,$11,$13,$15,$17,$18,$19,$20,
605 TrCreateLeafNode (PARSEOP_DEFAULT_ARG),$21);}
606 | PARSEOP_SPI_SERIALBUS
607 PARSEOP_OPEN_PAREN
608 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
611 SpiSerialBusTermV2
612 : PARSEOP_SPI_SERIALBUS_V2
613 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_SPI_SERIALBUS_V2);}
614 WordConstExpr /* 04: DeviceSelection */
615 OptionalDevicePolarity /* 05: DevicePolarity */
616 OptionalWireMode /* 06: WireMode */
617 ',' ByteConstExpr /* 08: DataBitLength */
618 OptionalSlaveMode /* 09: SlaveMode */
619 ',' DWordConstExpr /* 11: ConnectionSpeed */
620 ',' ClockPolarityKeyword /* 13: ClockPolarity */
621 ',' ClockPhaseKeyword /* 15: ClockPhase */
622 ',' StringData /* 17: ResourceSource */
623 OptionalByteConstExpr /* 18: ResourceSourceIndex */
624 OptionalResourceType /* 19: ResourceType */
625 OptionalNameString /* 20: DescriptorName */
626 OptionalShareType /* 21: Share */
627 OptionalBuffer_Last /* 22: VendorData */
628 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,14,
629 $4,$5,$6,$8,$9,$11,$13,$15,$17,$18,$19,$20,$21,$22);}
630 | PARSEOP_SPI_SERIALBUS_V2
631 PARSEOP_OPEN_PAREN
632 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
635 StartDependentFnNoPriTerm
636 : PARSEOP_STARTDEPENDENTFN_NOPRI
637 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_STARTDEPENDENTFN_NOPRI);}
638 PARSEOP_CLOSE_PAREN '{'
639 ResourceMacroList '}' {$$ = TrLinkChildren ($<n>3,1,$6);}
640 | PARSEOP_STARTDEPENDENTFN_NOPRI
641 PARSEOP_OPEN_PAREN
642 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
645 StartDependentFnTerm
646 : PARSEOP_STARTDEPENDENTFN
647 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_STARTDEPENDENTFN);}
648 ByteConstExpr
649 ',' ByteConstExpr
650 PARSEOP_CLOSE_PAREN '{'
651 ResourceMacroList '}' {$$ = TrLinkChildren ($<n>3,3,$4,$6,$9);}
652 | PARSEOP_STARTDEPENDENTFN
653 PARSEOP_OPEN_PAREN
654 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
657 UartSerialBusTerm
658 : PARSEOP_UART_SERIALBUS
659 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_UART_SERIALBUS);}
660 DWordConstExpr /* 04: ConnectionSpeed */
661 OptionalBitsPerByte /* 05: BitsPerByte */
662 OptionalStopBits /* 06: StopBits */
663 ',' ByteConstExpr /* 08: LinesInUse */
664 OptionalEndian /* 09: Endianess */
665 OptionalParityType /* 10: Parity */
666 OptionalFlowControl /* 11: FlowControl */
667 ',' WordConstExpr /* 13: Rx BufferSize */
668 ',' WordConstExpr /* 15: Tx BufferSize */
669 ',' StringData /* 17: ResourceSource */
670 OptionalByteConstExpr /* 18: ResourceSourceIndex */
671 OptionalResourceType /* 19: ResourceType */
672 OptionalNameString /* 20: DescriptorName */
673 OptionalBuffer_Last /* 21: VendorData */
674 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,15,
675 $4,$5,$6,$8,$9,$10,$11,$13,$15,$17,$18,$19,$20,
676 TrCreateLeafNode (PARSEOP_DEFAULT_ARG),$21);}
677 | PARSEOP_UART_SERIALBUS
678 PARSEOP_OPEN_PAREN
679 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
682 UartSerialBusTermV2
683 : PARSEOP_UART_SERIALBUS_V2
684 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_UART_SERIALBUS_V2);}
685 DWordConstExpr /* 04: ConnectionSpeed */
686 OptionalBitsPerByte /* 05: BitsPerByte */
687 OptionalStopBits /* 06: StopBits */
688 ',' ByteConstExpr /* 08: LinesInUse */
689 OptionalEndian /* 09: Endianess */
690 OptionalParityType /* 10: Parity */
691 OptionalFlowControl /* 11: FlowControl */
692 ',' WordConstExpr /* 13: Rx BufferSize */
693 ',' WordConstExpr /* 15: Tx BufferSize */
694 ',' StringData /* 17: ResourceSource */
695 OptionalByteConstExpr /* 18: ResourceSourceIndex */
696 OptionalResourceType /* 19: ResourceType */
697 OptionalNameString /* 20: DescriptorName */
698 OptionalShareType /* 21: Share */
699 OptionalBuffer_Last /* 22: VendorData */
700 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,15,
701 $4,$5,$6,$8,$9,$10,$11,$13,$15,$17,$18,$19,$20,$21,$22);}
702 | PARSEOP_UART_SERIALBUS_V2
703 PARSEOP_OPEN_PAREN
704 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
707 VendorLongTerm
708 : PARSEOP_VENDORLONG
709 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_VENDORLONG);}
710 OptionalNameString_First
711 PARSEOP_CLOSE_PAREN '{'
712 ByteList '}' {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
713 | PARSEOP_VENDORLONG
714 PARSEOP_OPEN_PAREN
715 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
718 VendorShortTerm
719 : PARSEOP_VENDORSHORT
720 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_VENDORSHORT);}
721 OptionalNameString_First
722 PARSEOP_CLOSE_PAREN '{'
723 ByteList '}' {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
724 | PARSEOP_VENDORSHORT
725 PARSEOP_OPEN_PAREN
726 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
729 WordBusNumberTerm
730 : PARSEOP_WORDBUSNUMBER
731 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_WORDBUSNUMBER);}
732 OptionalResourceType_First
733 OptionalMinType
734 OptionalMaxType
735 OptionalDecodeType
736 ',' WordConstExpr
737 ',' WordConstExpr
738 ',' WordConstExpr
739 ',' WordConstExpr
740 ',' WordConstExpr
741 OptionalByteConstExpr
742 OptionalStringData
743 OptionalNameString_Last
744 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,12,
745 $4,$5,$6,$7,$9,$11,$13,$15,$17,$18,$19,$20);}
746 | PARSEOP_WORDBUSNUMBER
747 PARSEOP_OPEN_PAREN
748 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
751 WordIOTerm
752 : PARSEOP_WORDIO
753 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_WORDIO);}
754 OptionalResourceType_First
755 OptionalMinType
756 OptionalMaxType
757 OptionalDecodeType
758 OptionalRangeType
759 ',' WordConstExpr
760 ',' WordConstExpr
761 ',' WordConstExpr
762 ',' WordConstExpr
763 ',' WordConstExpr
764 OptionalByteConstExpr
765 OptionalStringData
766 OptionalNameString
767 OptionalType
768 OptionalTranslationType_Last
769 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,15,
770 $4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$19,$20,$21,$22,$23);}
771 | PARSEOP_WORDIO
772 PARSEOP_OPEN_PAREN
773 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}
776 WordSpaceTerm
777 : PARSEOP_WORDSPACE
778 PARSEOP_OPEN_PAREN {$<n>$ = TrCreateLeafNode (PARSEOP_WORDSPACE);}
779 ByteConstExpr {UtCheckIntegerRange ($4, 0xC0, 0xFF);}
780 OptionalResourceType
781 OptionalDecodeType
782 OptionalMinType
783 OptionalMaxType
784 ',' ByteConstExpr
785 ',' WordConstExpr
786 ',' WordConstExpr
787 ',' WordConstExpr
788 ',' WordConstExpr
789 ',' WordConstExpr
790 OptionalByteConstExpr
791 OptionalStringData
792 OptionalNameString_Last
793 PARSEOP_CLOSE_PAREN {$$ = TrLinkChildren ($<n>3,14,
794 $4,$6,$7,$8,$9,$11,$13,$15,$17,$19,$21,$22,$23,$24);}
795 | PARSEOP_WORDSPACE
796 PARSEOP_OPEN_PAREN
797 error PARSEOP_CLOSE_PAREN {$$ = AslDoError(); yyclearin;}