Home | History | Annotate | Line # | Download | only in compiler
aslrules.y revision 1.1
      1  1.1  christos NoEcho('
      2  1.1  christos /******************************************************************************
      3  1.1  christos  *
      4  1.1  christos  * Module Name: aslrules.y - Bison/Yacc production rules
      5  1.1  christos  *
      6  1.1  christos  *****************************************************************************/
      7  1.1  christos 
      8  1.1  christos /*
      9  1.1  christos  * Copyright (C) 2000 - 2014, Intel Corp.
     10  1.1  christos  * All rights reserved.
     11  1.1  christos  *
     12  1.1  christos  * Redistribution and use in source and binary forms, with or without
     13  1.1  christos  * modification, are permitted provided that the following conditions
     14  1.1  christos  * are met:
     15  1.1  christos  * 1. Redistributions of source code must retain the above copyright
     16  1.1  christos  *    notice, this list of conditions, and the following disclaimer,
     17  1.1  christos  *    without modification.
     18  1.1  christos  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
     19  1.1  christos  *    substantially similar to the "NO WARRANTY" disclaimer below
     20  1.1  christos  *    ("Disclaimer") and any redistribution must be conditioned upon
     21  1.1  christos  *    including a substantially similar Disclaimer requirement for further
     22  1.1  christos  *    binary redistribution.
     23  1.1  christos  * 3. Neither the names of the above-listed copyright holders nor the names
     24  1.1  christos  *    of any contributors may be used to endorse or promote products derived
     25  1.1  christos  *    from this software without specific prior written permission.
     26  1.1  christos  *
     27  1.1  christos  * Alternatively, this software may be distributed under the terms of the
     28  1.1  christos  * GNU General Public License ("GPL") version 2 as published by the Free
     29  1.1  christos  * Software Foundation.
     30  1.1  christos  *
     31  1.1  christos  * NO WARRANTY
     32  1.1  christos  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
     33  1.1  christos  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
     34  1.1  christos  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
     35  1.1  christos  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
     36  1.1  christos  * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
     37  1.1  christos  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
     38  1.1  christos  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
     39  1.1  christos  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
     40  1.1  christos  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
     41  1.1  christos  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
     42  1.1  christos  * POSSIBILITY OF SUCH DAMAGES.
     43  1.1  christos  */
     44  1.1  christos 
     45  1.1  christos ')
     46  1.1  christos 
     47  1.1  christos /*******************************************************************************
     48  1.1  christos  *
     49  1.1  christos  * Production rules start here
     50  1.1  christos  *
     51  1.1  christos  ******************************************************************************/
     52  1.1  christos 
     53  1.1  christos /*
     54  1.1  christos  * ASL Names
     55  1.1  christos  *
     56  1.1  christos  * Root rule. Allow multiple #line directives before the definition block
     57  1.1  christos  * to handle output from preprocessors
     58  1.1  christos  */
     59  1.1  christos ASLCode
     60  1.1  christos     : DefinitionBlockTerm
     61  1.1  christos     | error                         {YYABORT; $$ = NULL;}
     62  1.1  christos     ;
     63  1.1  christos 
     64  1.1  christos /*
     65  1.1  christos  * Blocks, Data, and Opcodes
     66  1.1  christos  */
     67  1.1  christos 
     68  1.1  christos /*
     69  1.1  christos  * Note concerning support for "module-level code".
     70  1.1  christos  *
     71  1.1  christos  * ACPI 1.0 allowed Type1 and Type2 executable opcodes outside of control
     72  1.1  christos  * methods (the so-called module-level code.) This support was explicitly
     73  1.1  christos  * removed in ACPI 2.0, but this type of code continues to be created by
     74  1.1  christos  * BIOS vendors. In order to support the disassembly and recompilation of
     75  1.1  christos  * such code (and the porting of ASL code to iASL), iASL supports this
     76  1.1  christos  * code in violation of the current ACPI specification.
     77  1.1  christos  *
     78  1.1  christos  * The grammar change to support module-level code is to revert the
     79  1.1  christos  * {ObjectList} portion of the DefinitionBlockTerm in ACPI 2.0 to the
     80  1.1  christos  * original use of {TermList} instead (see below.) This allows the use
     81  1.1  christos  * of Type1 and Type2 opcodes at module level.
     82  1.1  christos  */
     83  1.1  christos DefinitionBlockTerm
     84  1.1  christos     : PARSEOP_DEFINITIONBLOCK '('   {$<n>$ = TrCreateLeafNode (PARSEOP_DEFINITIONBLOCK);}
     85  1.1  christos         String ','
     86  1.1  christos         String ','
     87  1.1  christos         ByteConst ','
     88  1.1  christos         String ','
     89  1.1  christos         String ','
     90  1.1  christos         DWordConst
     91  1.1  christos         ')'                         {TrSetEndLineNumber ($<n>3);}
     92  1.1  christos             '{' TermList '}'        {$$ = TrLinkChildren ($<n>3,7,$4,$6,$8,$10,$12,$14,$18);}
     93  1.1  christos     ;
     94  1.1  christos 
     95  1.1  christos /* ACPI 3.0 -- allow semicolons between terms */
     96  1.1  christos 
     97  1.1  christos TermList
     98  1.1  christos     :                               {$$ = NULL;}
     99  1.1  christos     | TermList Term                 {$$ = TrLinkPeerNode (TrSetNodeFlags ($1, NODE_RESULT_NOT_USED),$2);}
    100  1.1  christos     | TermList Term ';'             {$$ = TrLinkPeerNode (TrSetNodeFlags ($1, NODE_RESULT_NOT_USED),$2);}
    101  1.1  christos     | TermList ';' Term             {$$ = TrLinkPeerNode (TrSetNodeFlags ($1, NODE_RESULT_NOT_USED),$3);}
    102  1.1  christos     | TermList ';' Term ';'         {$$ = TrLinkPeerNode (TrSetNodeFlags ($1, NODE_RESULT_NOT_USED),$3);}
    103  1.1  christos     ;
    104  1.1  christos 
    105  1.1  christos Term
    106  1.1  christos     : Object                        {}
    107  1.1  christos     | Type1Opcode                   {}
    108  1.1  christos     | Type2Opcode                   {}
    109  1.1  christos     | Type2IntegerOpcode            {}
    110  1.1  christos     | Type2StringOpcode             {}
    111  1.1  christos     | Type2BufferOpcode             {}
    112  1.1  christos     | Type2BufferOrStringOpcode     {}
    113  1.1  christos     | error                         {$$ = AslDoError(); yyclearin;}
    114  1.1  christos     ;
    115  1.1  christos 
    116  1.1  christos CompilerDirective
    117  1.1  christos     : IncludeTerm                   {}
    118  1.1  christos     | ExternalTerm                  {}
    119  1.1  christos     ;
    120  1.1  christos 
    121  1.1  christos ObjectList
    122  1.1  christos     :                               {$$ = NULL;}
    123  1.1  christos     | ObjectList Object             {$$ = TrLinkPeerNode ($1,$2);}
    124  1.1  christos     | error                         {$$ = AslDoError(); yyclearin;}
    125  1.1  christos     ;
    126  1.1  christos 
    127  1.1  christos Object
    128  1.1  christos     : CompilerDirective             {}
    129  1.1  christos     | NamedObject                   {}
    130  1.1  christos     | NameSpaceModifier             {}
    131  1.1  christos     ;
    132  1.1  christos 
    133  1.1  christos DataObject
    134  1.1  christos     : BufferData                    {}
    135  1.1  christos     | PackageData                   {}
    136  1.1  christos     | IntegerData                   {}
    137  1.1  christos     | StringData                    {}
    138  1.1  christos     ;
    139  1.1  christos 
    140  1.1  christos BufferData
    141  1.1  christos     : Type5Opcode                   {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST);}
    142  1.1  christos     | Type2BufferOrStringOpcode     {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST);}
    143  1.1  christos     | Type2BufferOpcode             {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST);}
    144  1.1  christos     | BufferTerm                    {}
    145  1.1  christos     ;
    146  1.1  christos 
    147  1.1  christos PackageData
    148  1.1  christos     : PackageTerm                   {}
    149  1.1  christos     ;
    150  1.1  christos 
    151  1.1  christos IntegerData
    152  1.1  christos     : Type2IntegerOpcode            {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST);}
    153  1.1  christos     | Type3Opcode                   {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST);}
    154  1.1  christos     | Integer                       {}
    155  1.1  christos     | ConstTerm                     {}
    156  1.1  christos     ;
    157  1.1  christos 
    158  1.1  christos StringData
    159  1.1  christos     : Type2StringOpcode             {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST);}
    160  1.1  christos     | String                        {}
    161  1.1  christos     ;
    162  1.1  christos 
    163  1.1  christos NamedObject
    164  1.1  christos     : BankFieldTerm                 {}
    165  1.1  christos     | CreateBitFieldTerm            {}
    166  1.1  christos     | CreateByteFieldTerm           {}
    167  1.1  christos     | CreateDWordFieldTerm          {}
    168  1.1  christos     | CreateFieldTerm               {}
    169  1.1  christos     | CreateQWordFieldTerm          {}
    170  1.1  christos     | CreateWordFieldTerm           {}
    171  1.1  christos     | DataRegionTerm                {}
    172  1.1  christos     | DeviceTerm                    {}
    173  1.1  christos     | EventTerm                     {}
    174  1.1  christos     | FieldTerm                     {}
    175  1.1  christos     | FunctionTerm                  {}
    176  1.1  christos     | IndexFieldTerm                {}
    177  1.1  christos     | MethodTerm                    {}
    178  1.1  christos     | MutexTerm                     {}
    179  1.1  christos     | OpRegionTerm                  {}
    180  1.1  christos     | PowerResTerm                  {}
    181  1.1  christos     | ProcessorTerm                 {}
    182  1.1  christos     | ThermalZoneTerm               {}
    183  1.1  christos     ;
    184  1.1  christos 
    185  1.1  christos NameSpaceModifier
    186  1.1  christos     : AliasTerm                     {}
    187  1.1  christos     | NameTerm                      {}
    188  1.1  christos     | ScopeTerm                     {}
    189  1.1  christos     ;
    190  1.1  christos 
    191  1.1  christos UserTerm
    192  1.1  christos     : NameString '('                {TrUpdateNode (PARSEOP_METHODCALL, $1);}
    193  1.1  christos         ArgList ')'                 {$$ = TrLinkChildNode ($1,$4);}
    194  1.1  christos     ;
    195  1.1  christos 
    196  1.1  christos ArgList
    197  1.1  christos     :                               {$$ = NULL;}
    198  1.1  christos     | TermArg
    199  1.1  christos     | ArgList ','                   /* Allows a trailing comma at list end */
    200  1.1  christos     | ArgList ','
    201  1.1  christos         TermArg                     {$$ = TrLinkPeerNode ($1,$3);}
    202  1.1  christos     ;
    203  1.1  christos 
    204  1.1  christos /*
    205  1.1  christos Removed from TermArg due to reduce/reduce conflicts
    206  1.1  christos     | Type2IntegerOpcode            {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    207  1.1  christos     | Type2StringOpcode             {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    208  1.1  christos     | Type2BufferOpcode             {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    209  1.1  christos     | Type2BufferOrStringOpcode     {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    210  1.1  christos 
    211  1.1  christos */
    212  1.1  christos 
    213  1.1  christos TermArg
    214  1.1  christos     : Type2Opcode                   {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    215  1.1  christos     | DataObject                    {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    216  1.1  christos     | NameString                    {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    217  1.1  christos     | ArgTerm                       {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    218  1.1  christos     | LocalTerm                     {$$ = TrSetNodeFlags ($1, NODE_IS_TERM_ARG);}
    219  1.1  christos     ;
    220  1.1  christos 
    221  1.1  christos Target
    222  1.1  christos     :                               {$$ = TrSetNodeFlags (TrCreateLeafNode (PARSEOP_ZERO), NODE_IS_TARGET | NODE_COMPILE_TIME_CONST);} /* Placeholder is a ZeroOp object */
    223  1.1  christos     | ','                           {$$ = TrSetNodeFlags (TrCreateLeafNode (PARSEOP_ZERO), NODE_IS_TARGET | NODE_COMPILE_TIME_CONST);} /* Placeholder is a ZeroOp object */
    224  1.1  christos     | ',' SuperName                 {$$ = TrSetNodeFlags ($2, NODE_IS_TARGET);}
    225  1.1  christos     ;
    226  1.1  christos 
    227  1.1  christos RequiredTarget
    228  1.1  christos     : ',' SuperName                 {$$ = TrSetNodeFlags ($2, NODE_IS_TARGET);}
    229  1.1  christos     ;
    230  1.1  christos 
    231  1.1  christos SimpleTarget
    232  1.1  christos     : NameString                    {}
    233  1.1  christos     | LocalTerm                     {}
    234  1.1  christos     | ArgTerm                       {}
    235  1.1  christos     ;
    236  1.1  christos 
    237  1.1  christos /* Rules for specifying the type of one method argument or return value */
    238  1.1  christos 
    239  1.1  christos ParameterTypePackage
    240  1.1  christos     :                               {$$ = NULL;}
    241  1.1  christos     | ObjectTypeKeyword             {$$ = $1;}
    242  1.1  christos     | ParameterTypePackage ','
    243  1.1  christos         ObjectTypeKeyword           {$$ = TrLinkPeerNodes (2,$1,$3);}
    244  1.1  christos     ;
    245  1.1  christos 
    246  1.1  christos ParameterTypePackageList
    247  1.1  christos     :                               {$$ = NULL;}
    248  1.1  christos     | ObjectTypeKeyword             {$$ = $1;}
    249  1.1  christos     | '{' ParameterTypePackage '}'  {$$ = $2;}
    250  1.1  christos     ;
    251  1.1  christos 
    252  1.1  christos OptionalParameterTypePackage
    253  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_DEFAULT_ARG);}
    254  1.1  christos     | ',' ParameterTypePackageList  {$$ = TrLinkChildren (TrCreateLeafNode (PARSEOP_DEFAULT_ARG),1,$2);}
    255  1.1  christos     ;
    256  1.1  christos 
    257  1.1  christos /* Rules for specifying the types for method arguments */
    258  1.1  christos 
    259  1.1  christos ParameterTypesPackage
    260  1.1  christos     : ParameterTypePackageList      {$$ = $1;}
    261  1.1  christos     | ParameterTypesPackage ','
    262  1.1  christos         ParameterTypePackageList    {$$ = TrLinkPeerNodes (2,$1,$3);}
    263  1.1  christos     ;
    264  1.1  christos 
    265  1.1  christos ParameterTypesPackageList
    266  1.1  christos     :                               {$$ = NULL;}
    267  1.1  christos     | ObjectTypeKeyword             {$$ = $1;}
    268  1.1  christos     | '{' ParameterTypesPackage '}' {$$ = $2;}
    269  1.1  christos     ;
    270  1.1  christos 
    271  1.1  christos OptionalParameterTypesPackage
    272  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_DEFAULT_ARG);}
    273  1.1  christos     | ',' ParameterTypesPackageList {$$ = TrLinkChildren (TrCreateLeafNode (PARSEOP_DEFAULT_ARG),1,$2);}
    274  1.1  christos     ;
    275  1.1  christos 
    276  1.1  christos 
    277  1.1  christos /* Opcode types */
    278  1.1  christos 
    279  1.1  christos Type1Opcode
    280  1.1  christos     : BreakTerm                     {}
    281  1.1  christos     | BreakPointTerm                {}
    282  1.1  christos     | ContinueTerm                  {}
    283  1.1  christos     | FatalTerm                     {}
    284  1.1  christos     | IfElseTerm                    {}
    285  1.1  christos     | LoadTerm                      {}
    286  1.1  christos     | NoOpTerm                      {}
    287  1.1  christos     | NotifyTerm                    {}
    288  1.1  christos     | ReleaseTerm                   {}
    289  1.1  christos     | ResetTerm                     {}
    290  1.1  christos     | ReturnTerm                    {}
    291  1.1  christos     | SignalTerm                    {}
    292  1.1  christos     | SleepTerm                     {}
    293  1.1  christos     | StallTerm                     {}
    294  1.1  christos     | SwitchTerm                    {}
    295  1.1  christos     | UnloadTerm                    {}
    296  1.1  christos     | WhileTerm                     {}
    297  1.1  christos     ;
    298  1.1  christos 
    299  1.1  christos Type2Opcode
    300  1.1  christos     : AcquireTerm                   {}
    301  1.1  christos     | CondRefOfTerm                 {}
    302  1.1  christos     | CopyObjectTerm                {}
    303  1.1  christos     | DerefOfTerm                   {}
    304  1.1  christos     | ObjectTypeTerm                {}
    305  1.1  christos     | RefOfTerm                     {}
    306  1.1  christos     | SizeOfTerm                    {}
    307  1.1  christos     | StoreTerm                     {}
    308  1.1  christos     | TimerTerm                     {}
    309  1.1  christos     | WaitTerm                      {}
    310  1.1  christos     | UserTerm                      {}
    311  1.1  christos     ;
    312  1.1  christos 
    313  1.1  christos /*
    314  1.1  christos  * Type 3/4/5 opcodes
    315  1.1  christos  */
    316  1.1  christos 
    317  1.1  christos Type2IntegerOpcode                  /* "Type3" opcodes */
    318  1.1  christos     : AddTerm                       {}
    319  1.1  christos     | AndTerm                       {}
    320  1.1  christos     | DecTerm                       {}
    321  1.1  christos     | DivideTerm                    {}
    322  1.1  christos     | FindSetLeftBitTerm            {}
    323  1.1  christos     | FindSetRightBitTerm           {}
    324  1.1  christos     | FromBCDTerm                   {}
    325  1.1  christos     | IncTerm                       {}
    326  1.1  christos     | IndexTerm                     {}
    327  1.1  christos     | LAndTerm                      {}
    328  1.1  christos     | LEqualTerm                    {}
    329  1.1  christos     | LGreaterTerm                  {}
    330  1.1  christos     | LGreaterEqualTerm             {}
    331  1.1  christos     | LLessTerm                     {}
    332  1.1  christos     | LLessEqualTerm                {}
    333  1.1  christos     | LNotTerm                      {}
    334  1.1  christos     | LNotEqualTerm                 {}
    335  1.1  christos     | LoadTableTerm                 {}
    336  1.1  christos     | LOrTerm                       {}
    337  1.1  christos     | MatchTerm                     {}
    338  1.1  christos     | ModTerm                       {}
    339  1.1  christos     | MultiplyTerm                  {}
    340  1.1  christos     | NAndTerm                      {}
    341  1.1  christos     | NOrTerm                       {}
    342  1.1  christos     | NotTerm                       {}
    343  1.1  christos     | OrTerm                        {}
    344  1.1  christos     | ShiftLeftTerm                 {}
    345  1.1  christos     | ShiftRightTerm                {}
    346  1.1  christos     | SubtractTerm                  {}
    347  1.1  christos     | ToBCDTerm                     {}
    348  1.1  christos     | ToIntegerTerm                 {}
    349  1.1  christos     | XOrTerm                       {}
    350  1.1  christos     ;
    351  1.1  christos 
    352  1.1  christos Type2StringOpcode                   /* "Type4" Opcodes */
    353  1.1  christos     : ToDecimalStringTerm           {}
    354  1.1  christos     | ToHexStringTerm               {}
    355  1.1  christos     | ToStringTerm                  {}
    356  1.1  christos     ;
    357  1.1  christos 
    358  1.1  christos Type2BufferOpcode                   /* "Type5" Opcodes */
    359  1.1  christos     : ToBufferTerm                  {}
    360  1.1  christos     | ConcatResTerm                 {}
    361  1.1  christos     ;
    362  1.1  christos 
    363  1.1  christos Type2BufferOrStringOpcode
    364  1.1  christos     : ConcatTerm                    {}
    365  1.1  christos     | MidTerm                       {}
    366  1.1  christos     ;
    367  1.1  christos 
    368  1.1  christos /*
    369  1.1  christos  * A type 3 opcode evaluates to an Integer and cannot have a destination operand
    370  1.1  christos  */
    371  1.1  christos 
    372  1.1  christos Type3Opcode
    373  1.1  christos     : EISAIDTerm                    {}
    374  1.1  christos     ;
    375  1.1  christos 
    376  1.1  christos /* Obsolete
    377  1.1  christos Type4Opcode
    378  1.1  christos     : ConcatTerm                    {}
    379  1.1  christos     | ToDecimalStringTerm           {}
    380  1.1  christos     | ToHexStringTerm               {}
    381  1.1  christos     | MidTerm                       {}
    382  1.1  christos     | ToStringTerm                  {}
    383  1.1  christos     ;
    384  1.1  christos */
    385  1.1  christos 
    386  1.1  christos 
    387  1.1  christos Type5Opcode
    388  1.1  christos     : ResourceTemplateTerm          {}
    389  1.1  christos     | UnicodeTerm                   {}
    390  1.1  christos     | ToUUIDTerm                    {}
    391  1.1  christos     ;
    392  1.1  christos 
    393  1.1  christos Type6Opcode
    394  1.1  christos     : RefOfTerm                     {}
    395  1.1  christos     | DerefOfTerm                   {}
    396  1.1  christos     | IndexTerm                     {}
    397  1.1  christos     | UserTerm                      {}
    398  1.1  christos     ;
    399  1.1  christos 
    400  1.1  christos IncludeTerm
    401  1.1  christos     : PARSEOP_INCLUDE '('           {$<n>$ = TrCreateLeafNode (PARSEOP_INCLUDE);}
    402  1.1  christos         String  ')'                 {TrLinkChildren ($<n>3,1,$4);FlOpenIncludeFile ($4);}
    403  1.1  christos         TermList
    404  1.1  christos         IncludeEndTerm              {$$ = TrLinkPeerNodes (3,$<n>3,$7,$8);}
    405  1.1  christos     ;
    406  1.1  christos 
    407  1.1  christos IncludeEndTerm
    408  1.1  christos     : PARSEOP_INCLUDE_END           {$$ = TrCreateLeafNode (PARSEOP_INCLUDE_END);}
    409  1.1  christos     ;
    410  1.1  christos 
    411  1.1  christos ExternalTerm
    412  1.1  christos     : PARSEOP_EXTERNAL '('
    413  1.1  christos         NameString
    414  1.1  christos         OptionalObjectTypeKeyword
    415  1.1  christos         OptionalParameterTypePackage
    416  1.1  christos         OptionalParameterTypesPackage
    417  1.1  christos         ')'                         {$$ = TrCreateNode (PARSEOP_EXTERNAL,4,$3,$4,$5,$6);}
    418  1.1  christos     | PARSEOP_EXTERNAL '('
    419  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    420  1.1  christos     ;
    421  1.1  christos 
    422  1.1  christos 
    423  1.1  christos /******* Named Objects *******************************************************/
    424  1.1  christos 
    425  1.1  christos 
    426  1.1  christos BankFieldTerm
    427  1.1  christos     : PARSEOP_BANKFIELD '('         {$<n>$ = TrCreateLeafNode (PARSEOP_BANKFIELD);}
    428  1.1  christos         NameString
    429  1.1  christos         NameStringItem
    430  1.1  christos         TermArgItem
    431  1.1  christos         ',' AccessTypeKeyword
    432  1.1  christos         ',' LockRuleKeyword
    433  1.1  christos         ',' UpdateRuleKeyword
    434  1.1  christos         ')' '{'
    435  1.1  christos             FieldUnitList '}'       {$$ = TrLinkChildren ($<n>3,7,$4,$5,$6,$8,$10,$12,$15);}
    436  1.1  christos     | PARSEOP_BANKFIELD '('
    437  1.1  christos         error ')' '{' error '}'     {$$ = AslDoError(); yyclearin;}
    438  1.1  christos     ;
    439  1.1  christos 
    440  1.1  christos FieldUnitList
    441  1.1  christos     :                               {$$ = NULL;}
    442  1.1  christos     | FieldUnit
    443  1.1  christos     | FieldUnitList ','             /* Allows a trailing comma at list end */
    444  1.1  christos     | FieldUnitList ','
    445  1.1  christos         FieldUnit                   {$$ = TrLinkPeerNode ($1,$3);}
    446  1.1  christos     ;
    447  1.1  christos 
    448  1.1  christos FieldUnit
    449  1.1  christos     : FieldUnitEntry                {}
    450  1.1  christos     | OffsetTerm                    {}
    451  1.1  christos     | AccessAsTerm                  {}
    452  1.1  christos     | ConnectionTerm                {}
    453  1.1  christos     ;
    454  1.1  christos 
    455  1.1  christos FieldUnitEntry
    456  1.1  christos     : ',' AmlPackageLengthTerm      {$$ = TrCreateNode (PARSEOP_RESERVED_BYTES,1,$2);}
    457  1.1  christos     | NameSeg ','
    458  1.1  christos         AmlPackageLengthTerm        {$$ = TrLinkChildNode ($1,$3);}
    459  1.1  christos     ;
    460  1.1  christos 
    461  1.1  christos OffsetTerm
    462  1.1  christos     : PARSEOP_OFFSET '('
    463  1.1  christos         AmlPackageLengthTerm
    464  1.1  christos         ')'                         {$$ = TrCreateNode (PARSEOP_OFFSET,1,$3);}
    465  1.1  christos     | PARSEOP_OFFSET '('
    466  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    467  1.1  christos     ;
    468  1.1  christos 
    469  1.1  christos AccessAsTerm
    470  1.1  christos     : PARSEOP_ACCESSAS '('
    471  1.1  christos         AccessTypeKeyword
    472  1.1  christos         OptionalAccessAttribTerm
    473  1.1  christos         ')'                         {$$ = TrCreateNode (PARSEOP_ACCESSAS,2,$3,$4);}
    474  1.1  christos     | PARSEOP_ACCESSAS '('
    475  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    476  1.1  christos     ;
    477  1.1  christos 
    478  1.1  christos ConnectionTerm
    479  1.1  christos     : PARSEOP_CONNECTION '('
    480  1.1  christos         NameString
    481  1.1  christos         ')'                         {$$ = TrCreateNode (PARSEOP_CONNECTION,1,$3);}
    482  1.1  christos     | PARSEOP_CONNECTION '('        {$<n>$ = TrCreateLeafNode (PARSEOP_CONNECTION);}
    483  1.1  christos         ResourceMacroTerm
    484  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3, 1,
    485  1.1  christos                                             TrLinkChildren (TrCreateLeafNode (PARSEOP_RESOURCETEMPLATE), 3,
    486  1.1  christos                                                 TrCreateLeafNode (PARSEOP_DEFAULT_ARG),
    487  1.1  christos                                                 TrCreateLeafNode (PARSEOP_DEFAULT_ARG),
    488  1.1  christos                                                 $4));}
    489  1.1  christos     | PARSEOP_CONNECTION '('
    490  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    491  1.1  christos     ;
    492  1.1  christos 
    493  1.1  christos CreateBitFieldTerm
    494  1.1  christos     : PARSEOP_CREATEBITFIELD '('    {$<n>$ = TrCreateLeafNode (PARSEOP_CREATEBITFIELD);}
    495  1.1  christos         TermArg
    496  1.1  christos         TermArgItem
    497  1.1  christos         NameStringItem
    498  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,TrSetNodeFlags ($6, NODE_IS_NAME_DECLARATION));}
    499  1.1  christos     | PARSEOP_CREATEBITFIELD '('
    500  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    501  1.1  christos     ;
    502  1.1  christos 
    503  1.1  christos CreateByteFieldTerm
    504  1.1  christos     : PARSEOP_CREATEBYTEFIELD '('   {$<n>$ = TrCreateLeafNode (PARSEOP_CREATEBYTEFIELD);}
    505  1.1  christos         TermArg
    506  1.1  christos         TermArgItem
    507  1.1  christos         NameStringItem
    508  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,TrSetNodeFlags ($6, NODE_IS_NAME_DECLARATION));}
    509  1.1  christos     | PARSEOP_CREATEBYTEFIELD '('
    510  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    511  1.1  christos     ;
    512  1.1  christos 
    513  1.1  christos CreateDWordFieldTerm
    514  1.1  christos     : PARSEOP_CREATEDWORDFIELD '('  {$<n>$ = TrCreateLeafNode (PARSEOP_CREATEDWORDFIELD);}
    515  1.1  christos         TermArg
    516  1.1  christos         TermArgItem
    517  1.1  christos         NameStringItem
    518  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,TrSetNodeFlags ($6, NODE_IS_NAME_DECLARATION));}
    519  1.1  christos     | PARSEOP_CREATEDWORDFIELD '('
    520  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    521  1.1  christos     ;
    522  1.1  christos 
    523  1.1  christos CreateFieldTerm
    524  1.1  christos     : PARSEOP_CREATEFIELD '('       {$<n>$ = TrCreateLeafNode (PARSEOP_CREATEFIELD);}
    525  1.1  christos         TermArg
    526  1.1  christos         TermArgItem
    527  1.1  christos         TermArgItem
    528  1.1  christos         NameStringItem
    529  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,4,$4,$5,$6,TrSetNodeFlags ($7, NODE_IS_NAME_DECLARATION));}
    530  1.1  christos     | PARSEOP_CREATEFIELD '('
    531  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    532  1.1  christos     ;
    533  1.1  christos 
    534  1.1  christos CreateQWordFieldTerm
    535  1.1  christos     : PARSEOP_CREATEQWORDFIELD '('  {$<n>$ = TrCreateLeafNode (PARSEOP_CREATEQWORDFIELD);}
    536  1.1  christos         TermArg
    537  1.1  christos         TermArgItem
    538  1.1  christos         NameStringItem
    539  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,TrSetNodeFlags ($6, NODE_IS_NAME_DECLARATION));}
    540  1.1  christos     | PARSEOP_CREATEQWORDFIELD '('
    541  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    542  1.1  christos     ;
    543  1.1  christos 
    544  1.1  christos CreateWordFieldTerm
    545  1.1  christos     : PARSEOP_CREATEWORDFIELD '('   {$<n>$ = TrCreateLeafNode (PARSEOP_CREATEWORDFIELD);}
    546  1.1  christos         TermArg
    547  1.1  christos         TermArgItem
    548  1.1  christos         NameStringItem
    549  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,TrSetNodeFlags ($6, NODE_IS_NAME_DECLARATION));}
    550  1.1  christos     | PARSEOP_CREATEWORDFIELD '('
    551  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    552  1.1  christos     ;
    553  1.1  christos 
    554  1.1  christos DataRegionTerm
    555  1.1  christos     : PARSEOP_DATATABLEREGION '('   {$<n>$ = TrCreateLeafNode (PARSEOP_DATATABLEREGION);}
    556  1.1  christos         NameString
    557  1.1  christos         TermArgItem
    558  1.1  christos         TermArgItem
    559  1.1  christos         TermArgItem
    560  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,4,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$5,$6,$7);}
    561  1.1  christos     | PARSEOP_DATATABLEREGION '('
    562  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    563  1.1  christos     ;
    564  1.1  christos 
    565  1.1  christos DeviceTerm
    566  1.1  christos     : PARSEOP_DEVICE '('            {$<n>$ = TrCreateLeafNode (PARSEOP_DEVICE);}
    567  1.1  christos         NameString
    568  1.1  christos         ')' '{'
    569  1.1  christos             ObjectList '}'          {$$ = TrLinkChildren ($<n>3,2,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$7);}
    570  1.1  christos     | PARSEOP_DEVICE '('
    571  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    572  1.1  christos     ;
    573  1.1  christos 
    574  1.1  christos EventTerm
    575  1.1  christos     : PARSEOP_EVENT '('             {$<n>$ = TrCreateLeafNode (PARSEOP_EVENT);}
    576  1.1  christos         NameString
    577  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION));}
    578  1.1  christos     | PARSEOP_EVENT '('
    579  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    580  1.1  christos     ;
    581  1.1  christos 
    582  1.1  christos FieldTerm
    583  1.1  christos     : PARSEOP_FIELD '('             {$<n>$ = TrCreateLeafNode (PARSEOP_FIELD);}
    584  1.1  christos         NameString
    585  1.1  christos         ',' AccessTypeKeyword
    586  1.1  christos         ',' LockRuleKeyword
    587  1.1  christos         ',' UpdateRuleKeyword
    588  1.1  christos         ')' '{'
    589  1.1  christos             FieldUnitList '}'       {$$ = TrLinkChildren ($<n>3,5,$4,$6,$8,$10,$13);}
    590  1.1  christos     | PARSEOP_FIELD '('
    591  1.1  christos         error ')' '{' error '}'     {$$ = AslDoError(); yyclearin;}
    592  1.1  christos     ;
    593  1.1  christos 
    594  1.1  christos FunctionTerm
    595  1.1  christos     : PARSEOP_FUNCTION '('          {$<n>$ = TrCreateLeafNode (PARSEOP_METHOD);}
    596  1.1  christos         NameString
    597  1.1  christos         OptionalParameterTypePackage
    598  1.1  christos         OptionalParameterTypesPackage
    599  1.1  christos         ')' '{'
    600  1.1  christos             TermList '}'            {$$ = TrLinkChildren ($<n>3,7,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),
    601  1.1  christos                                         TrCreateValuedLeafNode (PARSEOP_BYTECONST, 0),
    602  1.1  christos                                         TrCreateLeafNode (PARSEOP_SERIALIZERULE_NOTSERIAL),
    603  1.1  christos                                         TrCreateValuedLeafNode (PARSEOP_BYTECONST, 0),$5,$6,$9);}
    604  1.1  christos     | PARSEOP_FUNCTION '('
    605  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    606  1.1  christos     ;
    607  1.1  christos 
    608  1.1  christos IndexFieldTerm
    609  1.1  christos     : PARSEOP_INDEXFIELD '('        {$<n>$ = TrCreateLeafNode (PARSEOP_INDEXFIELD);}
    610  1.1  christos         NameString
    611  1.1  christos         NameStringItem
    612  1.1  christos         ',' AccessTypeKeyword
    613  1.1  christos         ',' LockRuleKeyword
    614  1.1  christos         ',' UpdateRuleKeyword
    615  1.1  christos         ')' '{'
    616  1.1  christos             FieldUnitList '}'       {$$ = TrLinkChildren ($<n>3,6,$4,$5,$7,$9,$11,$14);}
    617  1.1  christos     | PARSEOP_INDEXFIELD '('
    618  1.1  christos         error ')' '{' error '}'     {$$ = AslDoError(); yyclearin;}
    619  1.1  christos     ;
    620  1.1  christos 
    621  1.1  christos MethodTerm
    622  1.1  christos     : PARSEOP_METHOD  '('           {$<n>$ = TrCreateLeafNode (PARSEOP_METHOD);}
    623  1.1  christos         NameString
    624  1.1  christos         OptionalByteConstExpr       {UtCheckIntegerRange ($5, 0, 7);}
    625  1.1  christos         OptionalSerializeRuleKeyword
    626  1.1  christos         OptionalByteConstExpr
    627  1.1  christos         OptionalParameterTypePackage
    628  1.1  christos         OptionalParameterTypesPackage
    629  1.1  christos         ')' '{'
    630  1.1  christos             TermList '}'            {$$ = TrLinkChildren ($<n>3,7,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$5,$7,$8,$9,$10,$13);}
    631  1.1  christos     | PARSEOP_METHOD '('
    632  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    633  1.1  christos     ;
    634  1.1  christos 
    635  1.1  christos MutexTerm
    636  1.1  christos     : PARSEOP_MUTEX '('             {$<n>$ = TrCreateLeafNode (PARSEOP_MUTEX);}
    637  1.1  christos         NameString
    638  1.1  christos         ',' ByteConstExpr
    639  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$6);}
    640  1.1  christos     | PARSEOP_MUTEX '('
    641  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    642  1.1  christos     ;
    643  1.1  christos 
    644  1.1  christos OpRegionTerm
    645  1.1  christos     : PARSEOP_OPERATIONREGION '('   {$<n>$ = TrCreateLeafNode (PARSEOP_OPERATIONREGION);}
    646  1.1  christos         NameString
    647  1.1  christos         ',' OpRegionSpaceIdTerm
    648  1.1  christos         TermArgItem
    649  1.1  christos         TermArgItem
    650  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,4,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$6,$7,$8);}
    651  1.1  christos     | PARSEOP_OPERATIONREGION '('
    652  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    653  1.1  christos     ;
    654  1.1  christos 
    655  1.1  christos OpRegionSpaceIdTerm
    656  1.1  christos     : RegionSpaceKeyword            {}
    657  1.1  christos     | ByteConst                     {$$ = UtCheckIntegerRange ($1, 0x80, 0xFF);}
    658  1.1  christos     ;
    659  1.1  christos 
    660  1.1  christos PowerResTerm
    661  1.1  christos     : PARSEOP_POWERRESOURCE '('     {$<n>$ = TrCreateLeafNode (PARSEOP_POWERRESOURCE);}
    662  1.1  christos         NameString
    663  1.1  christos         ',' ByteConstExpr
    664  1.1  christos         ',' WordConstExpr
    665  1.1  christos         ')' '{'
    666  1.1  christos             ObjectList '}'          {$$ = TrLinkChildren ($<n>3,4,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$6,$8,$11);}
    667  1.1  christos     | PARSEOP_POWERRESOURCE '('
    668  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    669  1.1  christos     ;
    670  1.1  christos 
    671  1.1  christos ProcessorTerm
    672  1.1  christos     : PARSEOP_PROCESSOR '('         {$<n>$ = TrCreateLeafNode (PARSEOP_PROCESSOR);}
    673  1.1  christos         NameString
    674  1.1  christos         ',' ByteConstExpr
    675  1.1  christos         OptionalDWordConstExpr
    676  1.1  christos         OptionalByteConstExpr
    677  1.1  christos         ')' '{'
    678  1.1  christos             ObjectList '}'          {$$ = TrLinkChildren ($<n>3,5,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$6,$7,$8,$11);}
    679  1.1  christos     | PARSEOP_PROCESSOR '('
    680  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    681  1.1  christos     ;
    682  1.1  christos 
    683  1.1  christos ThermalZoneTerm
    684  1.1  christos     : PARSEOP_THERMALZONE '('       {$<n>$ = TrCreateLeafNode (PARSEOP_THERMALZONE);}
    685  1.1  christos         NameString
    686  1.1  christos         ')' '{'
    687  1.1  christos             ObjectList '}'          {$$ = TrLinkChildren ($<n>3,2,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$7);}
    688  1.1  christos     | PARSEOP_THERMALZONE '('
    689  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    690  1.1  christos     ;
    691  1.1  christos 
    692  1.1  christos 
    693  1.1  christos /******* Namespace modifiers *************************************************/
    694  1.1  christos 
    695  1.1  christos 
    696  1.1  christos AliasTerm
    697  1.1  christos     : PARSEOP_ALIAS '('             {$<n>$ = TrCreateLeafNode (PARSEOP_ALIAS);}
    698  1.1  christos         NameString
    699  1.1  christos         NameStringItem
    700  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,TrSetNodeFlags ($5, NODE_IS_NAME_DECLARATION));}
    701  1.1  christos     | PARSEOP_ALIAS '('
    702  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    703  1.1  christos     ;
    704  1.1  christos 
    705  1.1  christos NameTerm
    706  1.1  christos     : PARSEOP_NAME '('              {$<n>$ = TrCreateLeafNode (PARSEOP_NAME);}
    707  1.1  christos         NameString
    708  1.1  christos         ',' DataObject
    709  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$6);}
    710  1.1  christos     | PARSEOP_NAME '('
    711  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    712  1.1  christos     ;
    713  1.1  christos 
    714  1.1  christos ScopeTerm
    715  1.1  christos     : PARSEOP_SCOPE '('             {$<n>$ = TrCreateLeafNode (PARSEOP_SCOPE);}
    716  1.1  christos         NameString
    717  1.1  christos         ')' '{'
    718  1.1  christos             ObjectList '}'          {$$ = TrLinkChildren ($<n>3,2,TrSetNodeFlags ($4, NODE_IS_NAME_DECLARATION),$7);}
    719  1.1  christos     | PARSEOP_SCOPE '('
    720  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    721  1.1  christos     ;
    722  1.1  christos 
    723  1.1  christos 
    724  1.1  christos /******* Type 1 opcodes *******************************************************/
    725  1.1  christos 
    726  1.1  christos 
    727  1.1  christos BreakTerm
    728  1.1  christos     : PARSEOP_BREAK                 {$$ = TrCreateNode (PARSEOP_BREAK, 0);}
    729  1.1  christos     ;
    730  1.1  christos 
    731  1.1  christos BreakPointTerm
    732  1.1  christos     : PARSEOP_BREAKPOINT            {$$ = TrCreateNode (PARSEOP_BREAKPOINT, 0);}
    733  1.1  christos     ;
    734  1.1  christos 
    735  1.1  christos ContinueTerm
    736  1.1  christos     : PARSEOP_CONTINUE              {$$ = TrCreateNode (PARSEOP_CONTINUE, 0);}
    737  1.1  christos     ;
    738  1.1  christos 
    739  1.1  christos FatalTerm
    740  1.1  christos     : PARSEOP_FATAL '('             {$<n>$ = TrCreateLeafNode (PARSEOP_FATAL);}
    741  1.1  christos         ByteConstExpr
    742  1.1  christos         ',' DWordConstExpr
    743  1.1  christos         TermArgItem
    744  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$6,$7);}
    745  1.1  christos     | PARSEOP_FATAL '('
    746  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    747  1.1  christos     ;
    748  1.1  christos 
    749  1.1  christos IfElseTerm
    750  1.1  christos     : IfTerm ElseTerm               {$$ = TrLinkPeerNode ($1,$2);}
    751  1.1  christos     ;
    752  1.1  christos 
    753  1.1  christos IfTerm
    754  1.1  christos     : PARSEOP_IF '('                {$<n>$ = TrCreateLeafNode (PARSEOP_IF);}
    755  1.1  christos         TermArg
    756  1.1  christos         ')' '{'
    757  1.1  christos             TermList '}'            {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
    758  1.1  christos 
    759  1.1  christos     | PARSEOP_IF '('
    760  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    761  1.1  christos     ;
    762  1.1  christos 
    763  1.1  christos ElseTerm
    764  1.1  christos     :                               {$$ = NULL;}
    765  1.1  christos     | PARSEOP_ELSE '{'              {$<n>$ = TrCreateLeafNode (PARSEOP_ELSE);}
    766  1.1  christos         TermList '}'                {$$ = TrLinkChildren ($<n>3,1,$4);}
    767  1.1  christos 
    768  1.1  christos     | PARSEOP_ELSE '{'
    769  1.1  christos         error '}'                   {$$ = AslDoError(); yyclearin;}
    770  1.1  christos 
    771  1.1  christos     | PARSEOP_ELSE
    772  1.1  christos         error                       {$$ = AslDoError(); yyclearin;}
    773  1.1  christos 
    774  1.1  christos     | PARSEOP_ELSEIF '('            {$<n>$ = TrCreateLeafNode (PARSEOP_ELSE);}
    775  1.1  christos         TermArg                     {$<n>$ = TrCreateLeafNode (PARSEOP_IF);}
    776  1.1  christos         ')' '{'
    777  1.1  christos             TermList '}'            {TrLinkChildren ($<n>5,2,$4,$8);}
    778  1.1  christos         ElseTerm                    {TrLinkPeerNode ($<n>5,$11);}
    779  1.1  christos                                     {$$ = TrLinkChildren ($<n>3,1,$<n>5);}
    780  1.1  christos 
    781  1.1  christos     | PARSEOP_ELSEIF '('
    782  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    783  1.1  christos 
    784  1.1  christos     | PARSEOP_ELSEIF
    785  1.1  christos         error                       {$$ = AslDoError(); yyclearin;}
    786  1.1  christos     ;
    787  1.1  christos 
    788  1.1  christos LoadTerm
    789  1.1  christos     : PARSEOP_LOAD '('              {$<n>$ = TrCreateLeafNode (PARSEOP_LOAD);}
    790  1.1  christos         NameString
    791  1.1  christos         RequiredTarget
    792  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
    793  1.1  christos     | PARSEOP_LOAD '('
    794  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    795  1.1  christos     ;
    796  1.1  christos 
    797  1.1  christos NoOpTerm
    798  1.1  christos     : PARSEOP_NOOP                  {$$ = TrCreateNode (PARSEOP_NOOP, 0);}
    799  1.1  christos     ;
    800  1.1  christos 
    801  1.1  christos NotifyTerm
    802  1.1  christos     : PARSEOP_NOTIFY '('            {$<n>$ = TrCreateLeafNode (PARSEOP_NOTIFY);}
    803  1.1  christos         SuperName
    804  1.1  christos         TermArgItem
    805  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
    806  1.1  christos     | PARSEOP_NOTIFY '('
    807  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    808  1.1  christos     ;
    809  1.1  christos 
    810  1.1  christos ReleaseTerm
    811  1.1  christos     : PARSEOP_RELEASE '('           {$<n>$ = TrCreateLeafNode (PARSEOP_RELEASE);}
    812  1.1  christos         SuperName
    813  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
    814  1.1  christos     | PARSEOP_RELEASE '('
    815  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    816  1.1  christos     ;
    817  1.1  christos 
    818  1.1  christos ResetTerm
    819  1.1  christos     : PARSEOP_RESET '('             {$<n>$ = TrCreateLeafNode (PARSEOP_RESET);}
    820  1.1  christos         SuperName
    821  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
    822  1.1  christos     | PARSEOP_RESET '('
    823  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    824  1.1  christos     ;
    825  1.1  christos 
    826  1.1  christos ReturnTerm
    827  1.1  christos     : PARSEOP_RETURN '('            {$<n>$ = TrCreateLeafNode (PARSEOP_RETURN);}
    828  1.1  christos         OptionalReturnArg
    829  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
    830  1.1  christos     | PARSEOP_RETURN                {$$ = TrLinkChildren (TrCreateLeafNode (PARSEOP_RETURN),1,TrSetNodeFlags (TrCreateLeafNode (PARSEOP_ZERO), NODE_IS_NULL_RETURN));}
    831  1.1  christos     | PARSEOP_RETURN '('
    832  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    833  1.1  christos     ;
    834  1.1  christos 
    835  1.1  christos SignalTerm
    836  1.1  christos     : PARSEOP_SIGNAL '('            {$<n>$ = TrCreateLeafNode (PARSEOP_SIGNAL);}
    837  1.1  christos         SuperName
    838  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
    839  1.1  christos     | PARSEOP_SIGNAL '('
    840  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    841  1.1  christos     ;
    842  1.1  christos 
    843  1.1  christos SleepTerm
    844  1.1  christos     : PARSEOP_SLEEP '('             {$<n>$ = TrCreateLeafNode (PARSEOP_SLEEP);}
    845  1.1  christos         TermArg
    846  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
    847  1.1  christos     | PARSEOP_SLEEP '('
    848  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    849  1.1  christos     ;
    850  1.1  christos 
    851  1.1  christos StallTerm
    852  1.1  christos     : PARSEOP_STALL '('             {$<n>$ = TrCreateLeafNode (PARSEOP_STALL);}
    853  1.1  christos         TermArg
    854  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
    855  1.1  christos     | PARSEOP_STALL '('
    856  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    857  1.1  christos     ;
    858  1.1  christos 
    859  1.1  christos SwitchTerm
    860  1.1  christos     : PARSEOP_SWITCH '('            {$<n>$ = TrCreateLeafNode (PARSEOP_SWITCH);}
    861  1.1  christos         TermArg
    862  1.1  christos         ')' '{'
    863  1.1  christos             CaseDefaultTermList '}'
    864  1.1  christos                                     {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
    865  1.1  christos     | PARSEOP_SWITCH '('
    866  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    867  1.1  christos     ;
    868  1.1  christos 
    869  1.1  christos /*
    870  1.1  christos  * Case-Default list; allow only one Default term and unlimited Case terms
    871  1.1  christos  */
    872  1.1  christos 
    873  1.1  christos CaseDefaultTermList
    874  1.1  christos     :                               {$$ = NULL;}
    875  1.1  christos     | CaseTerm  {}
    876  1.1  christos     | DefaultTerm   {}
    877  1.1  christos     | CaseDefaultTermList
    878  1.1  christos         CaseTerm                    {$$ = TrLinkPeerNode ($1,$2);}
    879  1.1  christos     | CaseDefaultTermList
    880  1.1  christos         DefaultTerm                 {$$ = TrLinkPeerNode ($1,$2);}
    881  1.1  christos 
    882  1.1  christos /* Original - attempts to force zero or one default term within the switch */
    883  1.1  christos 
    884  1.1  christos /*
    885  1.1  christos CaseDefaultTermList
    886  1.1  christos     :                               {$$ = NULL;}
    887  1.1  christos     | CaseTermList
    888  1.1  christos         DefaultTerm
    889  1.1  christos         CaseTermList                {$$ = TrLinkPeerNode ($1,TrLinkPeerNode ($2, $3));}
    890  1.1  christos     | CaseTermList
    891  1.1  christos         CaseTerm                    {$$ = TrLinkPeerNode ($1,$2);}
    892  1.1  christos     ;
    893  1.1  christos 
    894  1.1  christos CaseTermList
    895  1.1  christos     :                               {$$ = NULL;}
    896  1.1  christos     | CaseTerm                      {}
    897  1.1  christos     | CaseTermList
    898  1.1  christos         CaseTerm                    {$$ = TrLinkPeerNode ($1,$2);}
    899  1.1  christos     ;
    900  1.1  christos */
    901  1.1  christos 
    902  1.1  christos CaseTerm
    903  1.1  christos     : PARSEOP_CASE '('              {$<n>$ = TrCreateLeafNode (PARSEOP_CASE);}
    904  1.1  christos         DataObject
    905  1.1  christos         ')' '{'
    906  1.1  christos             TermList '}'            {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
    907  1.1  christos     | PARSEOP_CASE '('
    908  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    909  1.1  christos     ;
    910  1.1  christos 
    911  1.1  christos DefaultTerm
    912  1.1  christos     : PARSEOP_DEFAULT '{'           {$<n>$ = TrCreateLeafNode (PARSEOP_DEFAULT);}
    913  1.1  christos         TermList '}'                {$$ = TrLinkChildren ($<n>3,1,$4);}
    914  1.1  christos     | PARSEOP_DEFAULT '{'
    915  1.1  christos         error '}'                   {$$ = AslDoError(); yyclearin;}
    916  1.1  christos     ;
    917  1.1  christos 
    918  1.1  christos UnloadTerm
    919  1.1  christos     : PARSEOP_UNLOAD '('            {$<n>$ = TrCreateLeafNode (PARSEOP_UNLOAD);}
    920  1.1  christos         SuperName
    921  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
    922  1.1  christos     | PARSEOP_UNLOAD '('
    923  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    924  1.1  christos     ;
    925  1.1  christos 
    926  1.1  christos WhileTerm
    927  1.1  christos     : PARSEOP_WHILE '('             {$<n>$ = TrCreateLeafNode (PARSEOP_WHILE);}
    928  1.1  christos         TermArg
    929  1.1  christos         ')' '{' TermList '}'
    930  1.1  christos                                     {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
    931  1.1  christos     | PARSEOP_WHILE '('
    932  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    933  1.1  christos     ;
    934  1.1  christos 
    935  1.1  christos 
    936  1.1  christos /******* Type 2 opcodes *******************************************************/
    937  1.1  christos 
    938  1.1  christos AcquireTerm
    939  1.1  christos     : PARSEOP_ACQUIRE '('           {$<n>$ = TrCreateLeafNode (PARSEOP_ACQUIRE);}
    940  1.1  christos         SuperName
    941  1.1  christos         ',' WordConstExpr
    942  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$6);}
    943  1.1  christos     | PARSEOP_ACQUIRE '('
    944  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    945  1.1  christos     ;
    946  1.1  christos 
    947  1.1  christos AddTerm
    948  1.1  christos     : PARSEOP_ADD '('               {$<n>$ = TrCreateLeafNode (PARSEOP_ADD);}
    949  1.1  christos         TermArg
    950  1.1  christos         TermArgItem
    951  1.1  christos         Target
    952  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
    953  1.1  christos     | PARSEOP_ADD '('
    954  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    955  1.1  christos     ;
    956  1.1  christos 
    957  1.1  christos AndTerm
    958  1.1  christos     : PARSEOP_AND '('               {$<n>$ = TrCreateLeafNode (PARSEOP_AND);}
    959  1.1  christos         TermArg
    960  1.1  christos         TermArgItem
    961  1.1  christos         Target
    962  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
    963  1.1  christos     | PARSEOP_AND '('
    964  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    965  1.1  christos     ;
    966  1.1  christos 
    967  1.1  christos ConcatTerm
    968  1.1  christos     : PARSEOP_CONCATENATE '('       {$<n>$ = TrCreateLeafNode (PARSEOP_CONCATENATE);}
    969  1.1  christos         TermArg
    970  1.1  christos         TermArgItem
    971  1.1  christos         Target
    972  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
    973  1.1  christos     | PARSEOP_CONCATENATE '('
    974  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    975  1.1  christos     ;
    976  1.1  christos 
    977  1.1  christos ConcatResTerm
    978  1.1  christos     : PARSEOP_CONCATENATERESTEMPLATE '('    {$<n>$ = TrCreateLeafNode (PARSEOP_CONCATENATERESTEMPLATE);}
    979  1.1  christos         TermArg
    980  1.1  christos         TermArgItem
    981  1.1  christos         Target
    982  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
    983  1.1  christos     | PARSEOP_CONCATENATERESTEMPLATE '('
    984  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    985  1.1  christos     ;
    986  1.1  christos 
    987  1.1  christos CondRefOfTerm
    988  1.1  christos     : PARSEOP_CONDREFOF '('         {$<n>$ = TrCreateLeafNode (PARSEOP_CONDREFOF);}
    989  1.1  christos         SuperName
    990  1.1  christos         Target
    991  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
    992  1.1  christos     | PARSEOP_CONDREFOF '('
    993  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
    994  1.1  christos     ;
    995  1.1  christos 
    996  1.1  christos CopyObjectTerm
    997  1.1  christos     : PARSEOP_COPYOBJECT '('        {$<n>$ = TrCreateLeafNode (PARSEOP_COPYOBJECT);}
    998  1.1  christos         TermArg
    999  1.1  christos         ',' SimpleTarget
   1000  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,TrSetNodeFlags ($6, NODE_IS_TARGET));}
   1001  1.1  christos     | PARSEOP_COPYOBJECT '('
   1002  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1003  1.1  christos     ;
   1004  1.1  christos 
   1005  1.1  christos DecTerm
   1006  1.1  christos     : PARSEOP_DECREMENT '('         {$<n>$ = TrCreateLeafNode (PARSEOP_DECREMENT);}
   1007  1.1  christos         SuperName
   1008  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
   1009  1.1  christos     | PARSEOP_DECREMENT '('
   1010  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1011  1.1  christos     ;
   1012  1.1  christos 
   1013  1.1  christos DerefOfTerm
   1014  1.1  christos     : PARSEOP_DEREFOF '('           {$<n>$ = TrCreateLeafNode (PARSEOP_DEREFOF);}
   1015  1.1  christos         TermArg
   1016  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
   1017  1.1  christos     | PARSEOP_DEREFOF '('
   1018  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1019  1.1  christos     ;
   1020  1.1  christos 
   1021  1.1  christos DivideTerm
   1022  1.1  christos     : PARSEOP_DIVIDE '('            {$<n>$ = TrCreateLeafNode (PARSEOP_DIVIDE);}
   1023  1.1  christos         TermArg
   1024  1.1  christos         TermArgItem
   1025  1.1  christos         Target
   1026  1.1  christos         Target
   1027  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,4,$4,$5,$6,$7);}
   1028  1.1  christos     | PARSEOP_DIVIDE '('
   1029  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1030  1.1  christos     ;
   1031  1.1  christos 
   1032  1.1  christos FindSetLeftBitTerm
   1033  1.1  christos     : PARSEOP_FINDSETLEFTBIT '('    {$<n>$ = TrCreateLeafNode (PARSEOP_FINDSETLEFTBIT);}
   1034  1.1  christos         TermArg
   1035  1.1  christos         Target
   1036  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1037  1.1  christos     | PARSEOP_FINDSETLEFTBIT '('
   1038  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1039  1.1  christos     ;
   1040  1.1  christos 
   1041  1.1  christos FindSetRightBitTerm
   1042  1.1  christos     : PARSEOP_FINDSETRIGHTBIT '('   {$<n>$ = TrCreateLeafNode (PARSEOP_FINDSETRIGHTBIT);}
   1043  1.1  christos         TermArg
   1044  1.1  christos         Target
   1045  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1046  1.1  christos     | PARSEOP_FINDSETRIGHTBIT '('
   1047  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1048  1.1  christos     ;
   1049  1.1  christos 
   1050  1.1  christos FromBCDTerm
   1051  1.1  christos     : PARSEOP_FROMBCD '('           {$<n>$ = TrCreateLeafNode (PARSEOP_FROMBCD);}
   1052  1.1  christos         TermArg
   1053  1.1  christos         Target
   1054  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1055  1.1  christos     | PARSEOP_FROMBCD '('
   1056  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1057  1.1  christos     ;
   1058  1.1  christos 
   1059  1.1  christos IncTerm
   1060  1.1  christos     : PARSEOP_INCREMENT '('         {$<n>$ = TrCreateLeafNode (PARSEOP_INCREMENT);}
   1061  1.1  christos         SuperName
   1062  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
   1063  1.1  christos     | PARSEOP_INCREMENT '('
   1064  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1065  1.1  christos     ;
   1066  1.1  christos 
   1067  1.1  christos IndexTerm
   1068  1.1  christos     : PARSEOP_INDEX '('             {$<n>$ = TrCreateLeafNode (PARSEOP_INDEX);}
   1069  1.1  christos         TermArg
   1070  1.1  christos         TermArgItem
   1071  1.1  christos         Target
   1072  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1073  1.1  christos     | PARSEOP_INDEX '('
   1074  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1075  1.1  christos     ;
   1076  1.1  christos 
   1077  1.1  christos LAndTerm
   1078  1.1  christos     : PARSEOP_LAND '('              {$<n>$ = TrCreateLeafNode (PARSEOP_LAND);}
   1079  1.1  christos         TermArg
   1080  1.1  christos         TermArgItem
   1081  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1082  1.1  christos     | PARSEOP_LAND '('
   1083  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1084  1.1  christos     ;
   1085  1.1  christos 
   1086  1.1  christos LEqualTerm
   1087  1.1  christos     : PARSEOP_LEQUAL '('            {$<n>$ = TrCreateLeafNode (PARSEOP_LEQUAL);}
   1088  1.1  christos         TermArg
   1089  1.1  christos         TermArgItem
   1090  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1091  1.1  christos     | PARSEOP_LEQUAL '('
   1092  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1093  1.1  christos     ;
   1094  1.1  christos 
   1095  1.1  christos LGreaterTerm
   1096  1.1  christos     : PARSEOP_LGREATER '('          {$<n>$ = TrCreateLeafNode (PARSEOP_LGREATER);}
   1097  1.1  christos         TermArg
   1098  1.1  christos         TermArgItem
   1099  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1100  1.1  christos     | PARSEOP_LGREATER '('
   1101  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1102  1.1  christos     ;
   1103  1.1  christos 
   1104  1.1  christos LGreaterEqualTerm
   1105  1.1  christos     : PARSEOP_LGREATEREQUAL '('     {$<n>$ = TrCreateLeafNode (PARSEOP_LLESS);}
   1106  1.1  christos         TermArg
   1107  1.1  christos         TermArgItem
   1108  1.1  christos         ')'                         {$$ = TrCreateNode (PARSEOP_LNOT, 1, TrLinkChildren ($<n>3,2,$4,$5));}
   1109  1.1  christos     | PARSEOP_LGREATEREQUAL '('
   1110  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1111  1.1  christos     ;
   1112  1.1  christos 
   1113  1.1  christos LLessTerm
   1114  1.1  christos     : PARSEOP_LLESS '('             {$<n>$ = TrCreateLeafNode (PARSEOP_LLESS);}
   1115  1.1  christos         TermArg
   1116  1.1  christos         TermArgItem
   1117  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1118  1.1  christos     | PARSEOP_LLESS '('
   1119  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1120  1.1  christos     ;
   1121  1.1  christos 
   1122  1.1  christos LLessEqualTerm
   1123  1.1  christos     : PARSEOP_LLESSEQUAL '('        {$<n>$ = TrCreateLeafNode (PARSEOP_LGREATER);}
   1124  1.1  christos         TermArg
   1125  1.1  christos         TermArgItem
   1126  1.1  christos         ')'                         {$$ = TrCreateNode (PARSEOP_LNOT, 1, TrLinkChildren ($<n>3,2,$4,$5));}
   1127  1.1  christos     | PARSEOP_LLESSEQUAL '('
   1128  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1129  1.1  christos     ;
   1130  1.1  christos 
   1131  1.1  christos LNotTerm
   1132  1.1  christos     : PARSEOP_LNOT '('              {$<n>$ = TrCreateLeafNode (PARSEOP_LNOT);}
   1133  1.1  christos         TermArg
   1134  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
   1135  1.1  christos     | PARSEOP_LNOT '('
   1136  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1137  1.1  christos     ;
   1138  1.1  christos 
   1139  1.1  christos LNotEqualTerm
   1140  1.1  christos     : PARSEOP_LNOTEQUAL '('         {$<n>$ = TrCreateLeafNode (PARSEOP_LEQUAL);}
   1141  1.1  christos         TermArg
   1142  1.1  christos         TermArgItem
   1143  1.1  christos         ')'                         {$$ = TrCreateNode (PARSEOP_LNOT, 1, TrLinkChildren ($<n>3,2,$4,$5));}
   1144  1.1  christos     | PARSEOP_LNOTEQUAL '('
   1145  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1146  1.1  christos     ;
   1147  1.1  christos 
   1148  1.1  christos LoadTableTerm
   1149  1.1  christos     : PARSEOP_LOADTABLE '('         {$<n>$ = TrCreateLeafNode (PARSEOP_LOADTABLE);}
   1150  1.1  christos         TermArg
   1151  1.1  christos         TermArgItem
   1152  1.1  christos         TermArgItem
   1153  1.1  christos         OptionalListString
   1154  1.1  christos         OptionalListString
   1155  1.1  christos         OptionalReference
   1156  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,6,$4,$5,$6,$7,$8,$9);}
   1157  1.1  christos     | PARSEOP_LOADTABLE '('
   1158  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1159  1.1  christos     ;
   1160  1.1  christos 
   1161  1.1  christos LOrTerm
   1162  1.1  christos     : PARSEOP_LOR '('               {$<n>$ = TrCreateLeafNode (PARSEOP_LOR);}
   1163  1.1  christos         TermArg
   1164  1.1  christos         TermArgItem
   1165  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1166  1.1  christos     | PARSEOP_LOR '('
   1167  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1168  1.1  christos     ;
   1169  1.1  christos 
   1170  1.1  christos MatchTerm
   1171  1.1  christos     : PARSEOP_MATCH '('             {$<n>$ = TrCreateLeafNode (PARSEOP_MATCH);}
   1172  1.1  christos         TermArg
   1173  1.1  christos         ',' MatchOpKeyword
   1174  1.1  christos         TermArgItem
   1175  1.1  christos         ',' MatchOpKeyword
   1176  1.1  christos         TermArgItem
   1177  1.1  christos         TermArgItem
   1178  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,6,$4,$6,$7,$9,$10,$11);}
   1179  1.1  christos     | PARSEOP_MATCH '('
   1180  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1181  1.1  christos     ;
   1182  1.1  christos 
   1183  1.1  christos MidTerm
   1184  1.1  christos     : PARSEOP_MID '('               {$<n>$ = TrCreateLeafNode (PARSEOP_MID);}
   1185  1.1  christos         TermArg
   1186  1.1  christos         TermArgItem
   1187  1.1  christos         TermArgItem
   1188  1.1  christos         Target
   1189  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,4,$4,$5,$6,$7);}
   1190  1.1  christos     | PARSEOP_MID '('
   1191  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1192  1.1  christos     ;
   1193  1.1  christos 
   1194  1.1  christos ModTerm
   1195  1.1  christos     : PARSEOP_MOD '('               {$<n>$ = TrCreateLeafNode (PARSEOP_MOD);}
   1196  1.1  christos         TermArg
   1197  1.1  christos         TermArgItem
   1198  1.1  christos         Target
   1199  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1200  1.1  christos     | PARSEOP_MOD '('
   1201  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1202  1.1  christos     ;
   1203  1.1  christos 
   1204  1.1  christos MultiplyTerm
   1205  1.1  christos     : PARSEOP_MULTIPLY '('          {$<n>$ = TrCreateLeafNode (PARSEOP_MULTIPLY);}
   1206  1.1  christos         TermArg
   1207  1.1  christos         TermArgItem
   1208  1.1  christos         Target
   1209  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1210  1.1  christos     | PARSEOP_MULTIPLY '('
   1211  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1212  1.1  christos     ;
   1213  1.1  christos 
   1214  1.1  christos NAndTerm
   1215  1.1  christos     : PARSEOP_NAND '('              {$<n>$ = TrCreateLeafNode (PARSEOP_NAND);}
   1216  1.1  christos         TermArg
   1217  1.1  christos         TermArgItem
   1218  1.1  christos         Target
   1219  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1220  1.1  christos     | PARSEOP_NAND '('
   1221  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1222  1.1  christos     ;
   1223  1.1  christos 
   1224  1.1  christos NOrTerm
   1225  1.1  christos     : PARSEOP_NOR '('               {$<n>$ = TrCreateLeafNode (PARSEOP_NOR);}
   1226  1.1  christos         TermArg
   1227  1.1  christos         TermArgItem
   1228  1.1  christos         Target
   1229  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1230  1.1  christos     | PARSEOP_NOR '('
   1231  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1232  1.1  christos     ;
   1233  1.1  christos 
   1234  1.1  christos NotTerm
   1235  1.1  christos     : PARSEOP_NOT '('               {$<n>$ = TrCreateLeafNode (PARSEOP_NOT);}
   1236  1.1  christos         TermArg
   1237  1.1  christos         Target
   1238  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1239  1.1  christos     | PARSEOP_NOT '('
   1240  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1241  1.1  christos     ;
   1242  1.1  christos 
   1243  1.1  christos ObjectTypeTerm
   1244  1.1  christos     : PARSEOP_OBJECTTYPE '('        {$<n>$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE);}
   1245  1.1  christos         ObjectTypeName
   1246  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
   1247  1.1  christos     | PARSEOP_OBJECTTYPE '('
   1248  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1249  1.1  christos     ;
   1250  1.1  christos 
   1251  1.1  christos OrTerm
   1252  1.1  christos     : PARSEOP_OR '('                {$<n>$ = TrCreateLeafNode (PARSEOP_OR);}
   1253  1.1  christos         TermArg
   1254  1.1  christos         TermArgItem
   1255  1.1  christos         Target
   1256  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1257  1.1  christos     | PARSEOP_OR '('
   1258  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1259  1.1  christos     ;
   1260  1.1  christos 
   1261  1.1  christos /*
   1262  1.1  christos  * In RefOf, the node isn't really a target, but we can't keep track of it after
   1263  1.1  christos  * we've taken a pointer to it. (hard to tell if a local becomes initialized this way.)
   1264  1.1  christos  */
   1265  1.1  christos RefOfTerm
   1266  1.1  christos     : PARSEOP_REFOF '('             {$<n>$ = TrCreateLeafNode (PARSEOP_REFOF);}
   1267  1.1  christos         SuperName
   1268  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,TrSetNodeFlags ($4, NODE_IS_TARGET));}
   1269  1.1  christos     | PARSEOP_REFOF '('
   1270  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1271  1.1  christos     ;
   1272  1.1  christos 
   1273  1.1  christos ShiftLeftTerm
   1274  1.1  christos     : PARSEOP_SHIFTLEFT '('         {$<n>$ = TrCreateLeafNode (PARSEOP_SHIFTLEFT);}
   1275  1.1  christos         TermArg
   1276  1.1  christos         TermArgItem
   1277  1.1  christos         Target
   1278  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1279  1.1  christos     | PARSEOP_SHIFTLEFT '('
   1280  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1281  1.1  christos     ;
   1282  1.1  christos 
   1283  1.1  christos ShiftRightTerm
   1284  1.1  christos     : PARSEOP_SHIFTRIGHT '('        {$<n>$ = TrCreateLeafNode (PARSEOP_SHIFTRIGHT);}
   1285  1.1  christos         TermArg
   1286  1.1  christos         TermArgItem
   1287  1.1  christos         Target
   1288  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1289  1.1  christos     | PARSEOP_SHIFTRIGHT '('
   1290  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1291  1.1  christos     ;
   1292  1.1  christos 
   1293  1.1  christos SizeOfTerm
   1294  1.1  christos     : PARSEOP_SIZEOF '('            {$<n>$ = TrCreateLeafNode (PARSEOP_SIZEOF);}
   1295  1.1  christos         SuperName
   1296  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,1,$4);}
   1297  1.1  christos     | PARSEOP_SIZEOF '('
   1298  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1299  1.1  christos     ;
   1300  1.1  christos 
   1301  1.1  christos StoreTerm
   1302  1.1  christos     : PARSEOP_STORE '('             {$<n>$ = TrCreateLeafNode (PARSEOP_STORE);}
   1303  1.1  christos         TermArg
   1304  1.1  christos         ',' SuperName
   1305  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,TrSetNodeFlags ($6, NODE_IS_TARGET));}
   1306  1.1  christos     | PARSEOP_STORE '('
   1307  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1308  1.1  christos     ;
   1309  1.1  christos 
   1310  1.1  christos SubtractTerm
   1311  1.1  christos     : PARSEOP_SUBTRACT '('          {$<n>$ = TrCreateLeafNode (PARSEOP_SUBTRACT);}
   1312  1.1  christos         TermArg
   1313  1.1  christos         TermArgItem
   1314  1.1  christos         Target
   1315  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1316  1.1  christos     | PARSEOP_SUBTRACT '('
   1317  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1318  1.1  christos     ;
   1319  1.1  christos 
   1320  1.1  christos TimerTerm
   1321  1.1  christos     : PARSEOP_TIMER '('             {$<n>$ = TrCreateLeafNode (PARSEOP_TIMER);}
   1322  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,0);}
   1323  1.1  christos     | PARSEOP_TIMER                 {$$ = TrLinkChildren (TrCreateLeafNode (PARSEOP_TIMER),0);}
   1324  1.1  christos     | PARSEOP_TIMER '('
   1325  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1326  1.1  christos     ;
   1327  1.1  christos 
   1328  1.1  christos ToBCDTerm
   1329  1.1  christos     : PARSEOP_TOBCD '('             {$<n>$ = TrCreateLeafNode (PARSEOP_TOBCD);}
   1330  1.1  christos         TermArg
   1331  1.1  christos         Target
   1332  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1333  1.1  christos     | PARSEOP_TOBCD '('
   1334  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1335  1.1  christos     ;
   1336  1.1  christos 
   1337  1.1  christos ToBufferTerm
   1338  1.1  christos     : PARSEOP_TOBUFFER '('          {$<n>$ = TrCreateLeafNode (PARSEOP_TOBUFFER);}
   1339  1.1  christos         TermArg
   1340  1.1  christos         Target
   1341  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1342  1.1  christos     | PARSEOP_TOBUFFER '('
   1343  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1344  1.1  christos     ;
   1345  1.1  christos 
   1346  1.1  christos ToDecimalStringTerm
   1347  1.1  christos     : PARSEOP_TODECIMALSTRING '('   {$<n>$ = TrCreateLeafNode (PARSEOP_TODECIMALSTRING);}
   1348  1.1  christos         TermArg
   1349  1.1  christos         Target
   1350  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1351  1.1  christos     | PARSEOP_TODECIMALSTRING '('
   1352  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1353  1.1  christos     ;
   1354  1.1  christos 
   1355  1.1  christos ToHexStringTerm
   1356  1.1  christos     : PARSEOP_TOHEXSTRING '('       {$<n>$ = TrCreateLeafNode (PARSEOP_TOHEXSTRING);}
   1357  1.1  christos         TermArg
   1358  1.1  christos         Target
   1359  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1360  1.1  christos     | PARSEOP_TOHEXSTRING '('
   1361  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1362  1.1  christos     ;
   1363  1.1  christos 
   1364  1.1  christos ToIntegerTerm
   1365  1.1  christos     : PARSEOP_TOINTEGER '('         {$<n>$ = TrCreateLeafNode (PARSEOP_TOINTEGER);}
   1366  1.1  christos         TermArg
   1367  1.1  christos         Target
   1368  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1369  1.1  christos     | PARSEOP_TOINTEGER '('
   1370  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1371  1.1  christos     ;
   1372  1.1  christos 
   1373  1.1  christos ToStringTerm
   1374  1.1  christos     : PARSEOP_TOSTRING '('          {$<n>$ = TrCreateLeafNode (PARSEOP_TOSTRING);}
   1375  1.1  christos         TermArg
   1376  1.1  christos         OptionalCount
   1377  1.1  christos         Target
   1378  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1379  1.1  christos     | PARSEOP_TOSTRING '('
   1380  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1381  1.1  christos     ;
   1382  1.1  christos 
   1383  1.1  christos ToUUIDTerm
   1384  1.1  christos     : PARSEOP_TOUUID '('
   1385  1.1  christos         StringData ')'              {$$ = TrUpdateNode (PARSEOP_TOUUID, $3);}
   1386  1.1  christos     | PARSEOP_TOUUID '('
   1387  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1388  1.1  christos     ;
   1389  1.1  christos 
   1390  1.1  christos WaitTerm
   1391  1.1  christos     : PARSEOP_WAIT '('              {$<n>$ = TrCreateLeafNode (PARSEOP_WAIT);}
   1392  1.1  christos         SuperName
   1393  1.1  christos         TermArgItem
   1394  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,$4,$5);}
   1395  1.1  christos     | PARSEOP_WAIT '('
   1396  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1397  1.1  christos     ;
   1398  1.1  christos 
   1399  1.1  christos XOrTerm
   1400  1.1  christos     : PARSEOP_XOR '('               {$<n>$ = TrCreateLeafNode (PARSEOP_XOR);}
   1401  1.1  christos         TermArg
   1402  1.1  christos         TermArgItem
   1403  1.1  christos         Target
   1404  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$5,$6);}
   1405  1.1  christos     | PARSEOP_XOR '('
   1406  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1407  1.1  christos     ;
   1408  1.1  christos 
   1409  1.1  christos 
   1410  1.1  christos /******* Keywords *************************************************************/
   1411  1.1  christos 
   1412  1.1  christos 
   1413  1.1  christos AccessAttribKeyword
   1414  1.1  christos     : PARSEOP_ACCESSATTRIB_BLOCK            {$$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_BLOCK);}
   1415  1.1  christos     | PARSEOP_ACCESSATTRIB_BLOCK_CALL       {$$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_BLOCK_CALL);}
   1416  1.1  christos     | PARSEOP_ACCESSATTRIB_BYTE             {$$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_BYTE);}
   1417  1.1  christos     | PARSEOP_ACCESSATTRIB_QUICK            {$$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_QUICK );}
   1418  1.1  christos     | PARSEOP_ACCESSATTRIB_SND_RCV          {$$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_SND_RCV);}
   1419  1.1  christos     | PARSEOP_ACCESSATTRIB_WORD             {$$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_WORD);}
   1420  1.1  christos     | PARSEOP_ACCESSATTRIB_WORD_CALL        {$$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_WORD_CALL);}
   1421  1.1  christos     | PARSEOP_ACCESSATTRIB_MULTIBYTE '('    {$<n>$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_MULTIBYTE);}
   1422  1.1  christos         ByteConst
   1423  1.1  christos         ')'                                 {$$ = TrLinkChildren ($<n>3,1,$4);}
   1424  1.1  christos     | PARSEOP_ACCESSATTRIB_RAW_BYTES '('    {$<n>$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_RAW_BYTES);}
   1425  1.1  christos         ByteConst
   1426  1.1  christos         ')'                                 {$$ = TrLinkChildren ($<n>3,1,$4);}
   1427  1.1  christos     | PARSEOP_ACCESSATTRIB_RAW_PROCESS '('  {$<n>$ = TrCreateLeafNode (PARSEOP_ACCESSATTRIB_RAW_PROCESS);}
   1428  1.1  christos         ByteConst
   1429  1.1  christos         ')'                                 {$$ = TrLinkChildren ($<n>3,1,$4);}
   1430  1.1  christos     ;
   1431  1.1  christos 
   1432  1.1  christos AccessTypeKeyword
   1433  1.1  christos     : PARSEOP_ACCESSTYPE_ANY                {$$ = TrCreateLeafNode (PARSEOP_ACCESSTYPE_ANY);}
   1434  1.1  christos     | PARSEOP_ACCESSTYPE_BYTE               {$$ = TrCreateLeafNode (PARSEOP_ACCESSTYPE_BYTE);}
   1435  1.1  christos     | PARSEOP_ACCESSTYPE_WORD               {$$ = TrCreateLeafNode (PARSEOP_ACCESSTYPE_WORD);}
   1436  1.1  christos     | PARSEOP_ACCESSTYPE_DWORD              {$$ = TrCreateLeafNode (PARSEOP_ACCESSTYPE_DWORD);}
   1437  1.1  christos     | PARSEOP_ACCESSTYPE_QWORD              {$$ = TrCreateLeafNode (PARSEOP_ACCESSTYPE_QWORD);}
   1438  1.1  christos     | PARSEOP_ACCESSTYPE_BUF                {$$ = TrCreateLeafNode (PARSEOP_ACCESSTYPE_BUF);}
   1439  1.1  christos     ;
   1440  1.1  christos 
   1441  1.1  christos AddressingModeKeyword
   1442  1.1  christos     : PARSEOP_ADDRESSINGMODE_7BIT           {$$ = TrCreateLeafNode (PARSEOP_ADDRESSINGMODE_7BIT);}
   1443  1.1  christos     | PARSEOP_ADDRESSINGMODE_10BIT          {$$ = TrCreateLeafNode (PARSEOP_ADDRESSINGMODE_10BIT);}
   1444  1.1  christos     ;
   1445  1.1  christos 
   1446  1.1  christos AddressKeyword
   1447  1.1  christos     : PARSEOP_ADDRESSTYPE_MEMORY            {$$ = TrCreateLeafNode (PARSEOP_ADDRESSTYPE_MEMORY);}
   1448  1.1  christos     | PARSEOP_ADDRESSTYPE_RESERVED          {$$ = TrCreateLeafNode (PARSEOP_ADDRESSTYPE_RESERVED);}
   1449  1.1  christos     | PARSEOP_ADDRESSTYPE_NVS               {$$ = TrCreateLeafNode (PARSEOP_ADDRESSTYPE_NVS);}
   1450  1.1  christos     | PARSEOP_ADDRESSTYPE_ACPI              {$$ = TrCreateLeafNode (PARSEOP_ADDRESSTYPE_ACPI);}
   1451  1.1  christos     ;
   1452  1.1  christos 
   1453  1.1  christos AddressSpaceKeyword
   1454  1.1  christos     : ByteConst                             {$$ = UtCheckIntegerRange ($1, 0x0A, 0xFF);}
   1455  1.1  christos     | RegionSpaceKeyword                    {}
   1456  1.1  christos     ;
   1457  1.1  christos 
   1458  1.1  christos BitsPerByteKeyword
   1459  1.1  christos     : PARSEOP_BITSPERBYTE_FIVE              {$$ = TrCreateLeafNode (PARSEOP_BITSPERBYTE_FIVE);}
   1460  1.1  christos     | PARSEOP_BITSPERBYTE_SIX               {$$ = TrCreateLeafNode (PARSEOP_BITSPERBYTE_SIX);}
   1461  1.1  christos     | PARSEOP_BITSPERBYTE_SEVEN             {$$ = TrCreateLeafNode (PARSEOP_BITSPERBYTE_SEVEN);}
   1462  1.1  christos     | PARSEOP_BITSPERBYTE_EIGHT             {$$ = TrCreateLeafNode (PARSEOP_BITSPERBYTE_EIGHT);}
   1463  1.1  christos     | PARSEOP_BITSPERBYTE_NINE              {$$ = TrCreateLeafNode (PARSEOP_BITSPERBYTE_NINE);}
   1464  1.1  christos     ;
   1465  1.1  christos 
   1466  1.1  christos ClockPhaseKeyword
   1467  1.1  christos     : PARSEOP_CLOCKPHASE_FIRST              {$$ = TrCreateLeafNode (PARSEOP_CLOCKPHASE_FIRST);}
   1468  1.1  christos     | PARSEOP_CLOCKPHASE_SECOND             {$$ = TrCreateLeafNode (PARSEOP_CLOCKPHASE_SECOND);}
   1469  1.1  christos     ;
   1470  1.1  christos 
   1471  1.1  christos ClockPolarityKeyword
   1472  1.1  christos     : PARSEOP_CLOCKPOLARITY_LOW             {$$ = TrCreateLeafNode (PARSEOP_CLOCKPOLARITY_LOW);}
   1473  1.1  christos     | PARSEOP_CLOCKPOLARITY_HIGH            {$$ = TrCreateLeafNode (PARSEOP_CLOCKPOLARITY_HIGH);}
   1474  1.1  christos     ;
   1475  1.1  christos 
   1476  1.1  christos DecodeKeyword
   1477  1.1  christos     : PARSEOP_DECODETYPE_POS                {$$ = TrCreateLeafNode (PARSEOP_DECODETYPE_POS);}
   1478  1.1  christos     | PARSEOP_DECODETYPE_SUB                {$$ = TrCreateLeafNode (PARSEOP_DECODETYPE_SUB);}
   1479  1.1  christos     ;
   1480  1.1  christos 
   1481  1.1  christos DevicePolarityKeyword
   1482  1.1  christos     : PARSEOP_DEVICEPOLARITY_LOW            {$$ = TrCreateLeafNode (PARSEOP_DEVICEPOLARITY_LOW);}
   1483  1.1  christos     | PARSEOP_DEVICEPOLARITY_HIGH           {$$ = TrCreateLeafNode (PARSEOP_DEVICEPOLARITY_HIGH);}
   1484  1.1  christos     ;
   1485  1.1  christos 
   1486  1.1  christos DMATypeKeyword
   1487  1.1  christos     : PARSEOP_DMATYPE_A                     {$$ = TrCreateLeafNode (PARSEOP_DMATYPE_A);}
   1488  1.1  christos     | PARSEOP_DMATYPE_COMPATIBILITY         {$$ = TrCreateLeafNode (PARSEOP_DMATYPE_COMPATIBILITY);}
   1489  1.1  christos     | PARSEOP_DMATYPE_B                     {$$ = TrCreateLeafNode (PARSEOP_DMATYPE_B);}
   1490  1.1  christos     | PARSEOP_DMATYPE_F                     {$$ = TrCreateLeafNode (PARSEOP_DMATYPE_F);}
   1491  1.1  christos     ;
   1492  1.1  christos 
   1493  1.1  christos EndianKeyword
   1494  1.1  christos     : PARSEOP_ENDIAN_LITTLE                 {$$ = TrCreateLeafNode (PARSEOP_ENDIAN_LITTLE);}
   1495  1.1  christos     | PARSEOP_ENDIAN_BIG                    {$$ = TrCreateLeafNode (PARSEOP_ENDIAN_BIG);}
   1496  1.1  christos     ;
   1497  1.1  christos 
   1498  1.1  christos FlowControlKeyword
   1499  1.1  christos     : PARSEOP_FLOWCONTROL_HW                {$$ = TrCreateLeafNode (PARSEOP_FLOWCONTROL_HW);}
   1500  1.1  christos     | PARSEOP_FLOWCONTROL_NONE              {$$ = TrCreateLeafNode (PARSEOP_FLOWCONTROL_NONE);}
   1501  1.1  christos     | PARSEOP_FLOWCONTROL_SW                {$$ = TrCreateLeafNode (PARSEOP_FLOWCONTROL_SW);}
   1502  1.1  christos     ;
   1503  1.1  christos 
   1504  1.1  christos InterruptLevel
   1505  1.1  christos     : PARSEOP_INTLEVEL_ACTIVEBOTH           {$$ = TrCreateLeafNode (PARSEOP_INTLEVEL_ACTIVEBOTH);}
   1506  1.1  christos     | PARSEOP_INTLEVEL_ACTIVEHIGH           {$$ = TrCreateLeafNode (PARSEOP_INTLEVEL_ACTIVEHIGH);}
   1507  1.1  christos     | PARSEOP_INTLEVEL_ACTIVELOW            {$$ = TrCreateLeafNode (PARSEOP_INTLEVEL_ACTIVELOW);}
   1508  1.1  christos     ;
   1509  1.1  christos 
   1510  1.1  christos InterruptTypeKeyword
   1511  1.1  christos     : PARSEOP_INTTYPE_EDGE                  {$$ = TrCreateLeafNode (PARSEOP_INTTYPE_EDGE);}
   1512  1.1  christos     | PARSEOP_INTTYPE_LEVEL                 {$$ = TrCreateLeafNode (PARSEOP_INTTYPE_LEVEL);}
   1513  1.1  christos     ;
   1514  1.1  christos 
   1515  1.1  christos IODecodeKeyword
   1516  1.1  christos     : PARSEOP_IODECODETYPE_16               {$$ = TrCreateLeafNode (PARSEOP_IODECODETYPE_16);}
   1517  1.1  christos     | PARSEOP_IODECODETYPE_10               {$$ = TrCreateLeafNode (PARSEOP_IODECODETYPE_10);}
   1518  1.1  christos     ;
   1519  1.1  christos 
   1520  1.1  christos IoRestrictionKeyword
   1521  1.1  christos     : PARSEOP_IORESTRICT_IN                 {$$ = TrCreateLeafNode (PARSEOP_IORESTRICT_IN);}
   1522  1.1  christos     | PARSEOP_IORESTRICT_OUT                {$$ = TrCreateLeafNode (PARSEOP_IORESTRICT_OUT);}
   1523  1.1  christos     | PARSEOP_IORESTRICT_NONE               {$$ = TrCreateLeafNode (PARSEOP_IORESTRICT_NONE);}
   1524  1.1  christos     | PARSEOP_IORESTRICT_PRESERVE           {$$ = TrCreateLeafNode (PARSEOP_IORESTRICT_PRESERVE);}
   1525  1.1  christos     ;
   1526  1.1  christos 
   1527  1.1  christos LockRuleKeyword
   1528  1.1  christos     : PARSEOP_LOCKRULE_LOCK                 {$$ = TrCreateLeafNode (PARSEOP_LOCKRULE_LOCK);}
   1529  1.1  christos     | PARSEOP_LOCKRULE_NOLOCK               {$$ = TrCreateLeafNode (PARSEOP_LOCKRULE_NOLOCK);}
   1530  1.1  christos     ;
   1531  1.1  christos 
   1532  1.1  christos MatchOpKeyword
   1533  1.1  christos     : PARSEOP_MATCHTYPE_MTR                 {$$ = TrCreateLeafNode (PARSEOP_MATCHTYPE_MTR);}
   1534  1.1  christos     | PARSEOP_MATCHTYPE_MEQ                 {$$ = TrCreateLeafNode (PARSEOP_MATCHTYPE_MEQ);}
   1535  1.1  christos     | PARSEOP_MATCHTYPE_MLE                 {$$ = TrCreateLeafNode (PARSEOP_MATCHTYPE_MLE);}
   1536  1.1  christos     | PARSEOP_MATCHTYPE_MLT                 {$$ = TrCreateLeafNode (PARSEOP_MATCHTYPE_MLT);}
   1537  1.1  christos     | PARSEOP_MATCHTYPE_MGE                 {$$ = TrCreateLeafNode (PARSEOP_MATCHTYPE_MGE);}
   1538  1.1  christos     | PARSEOP_MATCHTYPE_MGT                 {$$ = TrCreateLeafNode (PARSEOP_MATCHTYPE_MGT);}
   1539  1.1  christos     ;
   1540  1.1  christos 
   1541  1.1  christos MaxKeyword
   1542  1.1  christos     : PARSEOP_MAXTYPE_FIXED                 {$$ = TrCreateLeafNode (PARSEOP_MAXTYPE_FIXED);}
   1543  1.1  christos     | PARSEOP_MAXTYPE_NOTFIXED              {$$ = TrCreateLeafNode (PARSEOP_MAXTYPE_NOTFIXED);}
   1544  1.1  christos     ;
   1545  1.1  christos 
   1546  1.1  christos MemTypeKeyword
   1547  1.1  christos     : PARSEOP_MEMTYPE_CACHEABLE             {$$ = TrCreateLeafNode (PARSEOP_MEMTYPE_CACHEABLE);}
   1548  1.1  christos     | PARSEOP_MEMTYPE_WRITECOMBINING        {$$ = TrCreateLeafNode (PARSEOP_MEMTYPE_WRITECOMBINING);}
   1549  1.1  christos     | PARSEOP_MEMTYPE_PREFETCHABLE          {$$ = TrCreateLeafNode (PARSEOP_MEMTYPE_PREFETCHABLE);}
   1550  1.1  christos     | PARSEOP_MEMTYPE_NONCACHEABLE          {$$ = TrCreateLeafNode (PARSEOP_MEMTYPE_NONCACHEABLE);}
   1551  1.1  christos     ;
   1552  1.1  christos 
   1553  1.1  christos MinKeyword
   1554  1.1  christos     : PARSEOP_MINTYPE_FIXED                 {$$ = TrCreateLeafNode (PARSEOP_MINTYPE_FIXED);}
   1555  1.1  christos     | PARSEOP_MINTYPE_NOTFIXED              {$$ = TrCreateLeafNode (PARSEOP_MINTYPE_NOTFIXED);}
   1556  1.1  christos     ;
   1557  1.1  christos 
   1558  1.1  christos ObjectTypeKeyword
   1559  1.1  christos     : PARSEOP_OBJECTTYPE_UNK                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_UNK);}
   1560  1.1  christos     | PARSEOP_OBJECTTYPE_INT                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_INT);}
   1561  1.1  christos     | PARSEOP_OBJECTTYPE_STR                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_STR);}
   1562  1.1  christos     | PARSEOP_OBJECTTYPE_BUF                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_BUF);}
   1563  1.1  christos     | PARSEOP_OBJECTTYPE_PKG                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_PKG);}
   1564  1.1  christos     | PARSEOP_OBJECTTYPE_FLD                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_FLD);}
   1565  1.1  christos     | PARSEOP_OBJECTTYPE_DEV                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_DEV);}
   1566  1.1  christos     | PARSEOP_OBJECTTYPE_EVT                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_EVT);}
   1567  1.1  christos     | PARSEOP_OBJECTTYPE_MTH                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_MTH);}
   1568  1.1  christos     | PARSEOP_OBJECTTYPE_MTX                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_MTX);}
   1569  1.1  christos     | PARSEOP_OBJECTTYPE_OPR                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_OPR);}
   1570  1.1  christos     | PARSEOP_OBJECTTYPE_POW                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_POW);}
   1571  1.1  christos     | PARSEOP_OBJECTTYPE_PRO                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_PRO);}
   1572  1.1  christos     | PARSEOP_OBJECTTYPE_THZ                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_THZ);}
   1573  1.1  christos     | PARSEOP_OBJECTTYPE_BFF                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_BFF);}
   1574  1.1  christos     | PARSEOP_OBJECTTYPE_DDB                {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_DDB);}
   1575  1.1  christos     ;
   1576  1.1  christos 
   1577  1.1  christos ParityTypeKeyword
   1578  1.1  christos     : PARSEOP_PARITYTYPE_SPACE              {$$ = TrCreateLeafNode (PARSEOP_PARITYTYPE_SPACE);}
   1579  1.1  christos     | PARSEOP_PARITYTYPE_MARK               {$$ = TrCreateLeafNode (PARSEOP_PARITYTYPE_MARK);}
   1580  1.1  christos     | PARSEOP_PARITYTYPE_ODD                {$$ = TrCreateLeafNode (PARSEOP_PARITYTYPE_ODD);}
   1581  1.1  christos     | PARSEOP_PARITYTYPE_EVEN               {$$ = TrCreateLeafNode (PARSEOP_PARITYTYPE_EVEN);}
   1582  1.1  christos     | PARSEOP_PARITYTYPE_NONE               {$$ = TrCreateLeafNode (PARSEOP_PARITYTYPE_NONE);}
   1583  1.1  christos     ;
   1584  1.1  christos 
   1585  1.1  christos PinConfigByte
   1586  1.1  christos     : PinConfigKeyword                      {$$ = $1;}
   1587  1.1  christos     | ByteConstExpr                         {$$ = UtCheckIntegerRange ($1, 0x80, 0xFF);}
   1588  1.1  christos     ;
   1589  1.1  christos 
   1590  1.1  christos PinConfigKeyword
   1591  1.1  christos     : PARSEOP_PIN_NOPULL                    {$$ = TrCreateLeafNode (PARSEOP_PIN_NOPULL);}
   1592  1.1  christos     | PARSEOP_PIN_PULLDOWN                  {$$ = TrCreateLeafNode (PARSEOP_PIN_PULLDOWN);}
   1593  1.1  christos     | PARSEOP_PIN_PULLUP                    {$$ = TrCreateLeafNode (PARSEOP_PIN_PULLUP);}
   1594  1.1  christos     | PARSEOP_PIN_PULLDEFAULT               {$$ = TrCreateLeafNode (PARSEOP_PIN_PULLDEFAULT);}
   1595  1.1  christos     ;
   1596  1.1  christos 
   1597  1.1  christos RangeTypeKeyword
   1598  1.1  christos     : PARSEOP_RANGETYPE_ISAONLY             {$$ = TrCreateLeafNode (PARSEOP_RANGETYPE_ISAONLY);}
   1599  1.1  christos     | PARSEOP_RANGETYPE_NONISAONLY          {$$ = TrCreateLeafNode (PARSEOP_RANGETYPE_NONISAONLY);}
   1600  1.1  christos     | PARSEOP_RANGETYPE_ENTIRE              {$$ = TrCreateLeafNode (PARSEOP_RANGETYPE_ENTIRE);}
   1601  1.1  christos     ;
   1602  1.1  christos 
   1603  1.1  christos RegionSpaceKeyword
   1604  1.1  christos     : PARSEOP_REGIONSPACE_IO                {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_IO);}
   1605  1.1  christos     | PARSEOP_REGIONSPACE_MEM               {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_MEM);}
   1606  1.1  christos     | PARSEOP_REGIONSPACE_PCI               {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_PCI);}
   1607  1.1  christos     | PARSEOP_REGIONSPACE_EC                {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_EC);}
   1608  1.1  christos     | PARSEOP_REGIONSPACE_SMBUS             {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_SMBUS);}
   1609  1.1  christos     | PARSEOP_REGIONSPACE_CMOS              {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_CMOS);}
   1610  1.1  christos     | PARSEOP_REGIONSPACE_PCIBAR            {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_PCIBAR);}
   1611  1.1  christos     | PARSEOP_REGIONSPACE_IPMI              {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_IPMI);}
   1612  1.1  christos     | PARSEOP_REGIONSPACE_GPIO              {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_GPIO);}
   1613  1.1  christos     | PARSEOP_REGIONSPACE_GSBUS             {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_GSBUS);}
   1614  1.1  christos     | PARSEOP_REGIONSPACE_PCC               {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_PCC);}
   1615  1.1  christos     | PARSEOP_REGIONSPACE_FFIXEDHW          {$$ = TrCreateLeafNode (PARSEOP_REGIONSPACE_FFIXEDHW);}
   1616  1.1  christos     ;
   1617  1.1  christos 
   1618  1.1  christos ResourceTypeKeyword
   1619  1.1  christos     : PARSEOP_RESOURCETYPE_CONSUMER         {$$ = TrCreateLeafNode (PARSEOP_RESOURCETYPE_CONSUMER);}
   1620  1.1  christos     | PARSEOP_RESOURCETYPE_PRODUCER         {$$ = TrCreateLeafNode (PARSEOP_RESOURCETYPE_PRODUCER);}
   1621  1.1  christos     ;
   1622  1.1  christos 
   1623  1.1  christos SerializeRuleKeyword
   1624  1.1  christos     : PARSEOP_SERIALIZERULE_SERIAL          {$$ = TrCreateLeafNode (PARSEOP_SERIALIZERULE_SERIAL);}
   1625  1.1  christos     | PARSEOP_SERIALIZERULE_NOTSERIAL       {$$ = TrCreateLeafNode (PARSEOP_SERIALIZERULE_NOTSERIAL);}
   1626  1.1  christos     ;
   1627  1.1  christos 
   1628  1.1  christos ShareTypeKeyword
   1629  1.1  christos     : PARSEOP_SHARETYPE_SHARED              {$$ = TrCreateLeafNode (PARSEOP_SHARETYPE_SHARED);}
   1630  1.1  christos     | PARSEOP_SHARETYPE_EXCLUSIVE           {$$ = TrCreateLeafNode (PARSEOP_SHARETYPE_EXCLUSIVE);}
   1631  1.1  christos     | PARSEOP_SHARETYPE_SHAREDWAKE          {$$ = TrCreateLeafNode (PARSEOP_SHARETYPE_SHAREDWAKE);}
   1632  1.1  christos     | PARSEOP_SHARETYPE_EXCLUSIVEWAKE       {$$ = TrCreateLeafNode (PARSEOP_SHARETYPE_EXCLUSIVEWAKE);}
   1633  1.1  christos    ;
   1634  1.1  christos 
   1635  1.1  christos SlaveModeKeyword
   1636  1.1  christos     : PARSEOP_SLAVEMODE_CONTROLLERINIT      {$$ = TrCreateLeafNode (PARSEOP_SLAVEMODE_CONTROLLERINIT);}
   1637  1.1  christos     | PARSEOP_SLAVEMODE_DEVICEINIT          {$$ = TrCreateLeafNode (PARSEOP_SLAVEMODE_DEVICEINIT);}
   1638  1.1  christos     ;
   1639  1.1  christos 
   1640  1.1  christos StopBitsKeyword
   1641  1.1  christos     : PARSEOP_STOPBITS_TWO                  {$$ = TrCreateLeafNode (PARSEOP_STOPBITS_TWO);}
   1642  1.1  christos     | PARSEOP_STOPBITS_ONEPLUSHALF          {$$ = TrCreateLeafNode (PARSEOP_STOPBITS_ONEPLUSHALF);}
   1643  1.1  christos     | PARSEOP_STOPBITS_ONE                  {$$ = TrCreateLeafNode (PARSEOP_STOPBITS_ONE);}
   1644  1.1  christos     | PARSEOP_STOPBITS_ZERO                 {$$ = TrCreateLeafNode (PARSEOP_STOPBITS_ZERO);}
   1645  1.1  christos     ;
   1646  1.1  christos 
   1647  1.1  christos TranslationKeyword
   1648  1.1  christos     : PARSEOP_TRANSLATIONTYPE_SPARSE        {$$ = TrCreateLeafNode (PARSEOP_TRANSLATIONTYPE_SPARSE);}
   1649  1.1  christos     | PARSEOP_TRANSLATIONTYPE_DENSE         {$$ = TrCreateLeafNode (PARSEOP_TRANSLATIONTYPE_DENSE);}
   1650  1.1  christos     ;
   1651  1.1  christos 
   1652  1.1  christos TypeKeyword
   1653  1.1  christos     : PARSEOP_TYPE_TRANSLATION              {$$ = TrCreateLeafNode (PARSEOP_TYPE_TRANSLATION);}
   1654  1.1  christos     | PARSEOP_TYPE_STATIC                   {$$ = TrCreateLeafNode (PARSEOP_TYPE_STATIC);}
   1655  1.1  christos     ;
   1656  1.1  christos 
   1657  1.1  christos UpdateRuleKeyword
   1658  1.1  christos     : PARSEOP_UPDATERULE_PRESERVE           {$$ = TrCreateLeafNode (PARSEOP_UPDATERULE_PRESERVE);}
   1659  1.1  christos     | PARSEOP_UPDATERULE_ONES               {$$ = TrCreateLeafNode (PARSEOP_UPDATERULE_ONES);}
   1660  1.1  christos     | PARSEOP_UPDATERULE_ZEROS              {$$ = TrCreateLeafNode (PARSEOP_UPDATERULE_ZEROS);}
   1661  1.1  christos     ;
   1662  1.1  christos 
   1663  1.1  christos WireModeKeyword
   1664  1.1  christos     : PARSEOP_WIREMODE_FOUR                 {$$ = TrCreateLeafNode (PARSEOP_WIREMODE_FOUR);}
   1665  1.1  christos     | PARSEOP_WIREMODE_THREE                {$$ = TrCreateLeafNode (PARSEOP_WIREMODE_THREE);}
   1666  1.1  christos     ;
   1667  1.1  christos 
   1668  1.1  christos XferSizeKeyword
   1669  1.1  christos     : PARSEOP_XFERSIZE_8                    {$$ = TrCreateValuedLeafNode (PARSEOP_XFERSIZE_8,   0);}
   1670  1.1  christos     | PARSEOP_XFERSIZE_16                   {$$ = TrCreateValuedLeafNode (PARSEOP_XFERSIZE_16,  1);}
   1671  1.1  christos     | PARSEOP_XFERSIZE_32                   {$$ = TrCreateValuedLeafNode (PARSEOP_XFERSIZE_32,  2);}
   1672  1.1  christos     | PARSEOP_XFERSIZE_64                   {$$ = TrCreateValuedLeafNode (PARSEOP_XFERSIZE_64,  3);}
   1673  1.1  christos     | PARSEOP_XFERSIZE_128                  {$$ = TrCreateValuedLeafNode (PARSEOP_XFERSIZE_128, 4);}
   1674  1.1  christos     | PARSEOP_XFERSIZE_256                  {$$ = TrCreateValuedLeafNode (PARSEOP_XFERSIZE_256, 5);}
   1675  1.1  christos     ;
   1676  1.1  christos 
   1677  1.1  christos XferTypeKeyword
   1678  1.1  christos     : PARSEOP_XFERTYPE_8                    {$$ = TrCreateLeafNode (PARSEOP_XFERTYPE_8);}
   1679  1.1  christos     | PARSEOP_XFERTYPE_8_16                 {$$ = TrCreateLeafNode (PARSEOP_XFERTYPE_8_16);}
   1680  1.1  christos     | PARSEOP_XFERTYPE_16                   {$$ = TrCreateLeafNode (PARSEOP_XFERTYPE_16);}
   1681  1.1  christos     ;
   1682  1.1  christos 
   1683  1.1  christos 
   1684  1.1  christos /******* Miscellaneous Types **************************************************/
   1685  1.1  christos 
   1686  1.1  christos 
   1687  1.1  christos SuperName
   1688  1.1  christos     : NameString                    {}
   1689  1.1  christos     | ArgTerm                       {}
   1690  1.1  christos     | LocalTerm                     {}
   1691  1.1  christos     | DebugTerm                     {}
   1692  1.1  christos     | Type6Opcode                   {}
   1693  1.1  christos 
   1694  1.1  christos /* For ObjectType: SuperName except for UserTerm (method invocation) */
   1695  1.1  christos 
   1696  1.1  christos ObjectTypeName
   1697  1.1  christos     : NameString                    {}
   1698  1.1  christos     | ArgTerm                       {}
   1699  1.1  christos     | LocalTerm                     {}
   1700  1.1  christos     | DebugTerm                     {}
   1701  1.1  christos     | RefOfTerm                     {}
   1702  1.1  christos     | DerefOfTerm                   {}
   1703  1.1  christos     | IndexTerm                     {}
   1704  1.1  christos 
   1705  1.1  christos /*    | UserTerm                      {} */  /* Caused reduce/reduce with Type6Opcode->UserTerm */
   1706  1.1  christos     ;
   1707  1.1  christos 
   1708  1.1  christos ArgTerm
   1709  1.1  christos     : PARSEOP_ARG0                  {$$ = TrCreateLeafNode (PARSEOP_ARG0);}
   1710  1.1  christos     | PARSEOP_ARG1                  {$$ = TrCreateLeafNode (PARSEOP_ARG1);}
   1711  1.1  christos     | PARSEOP_ARG2                  {$$ = TrCreateLeafNode (PARSEOP_ARG2);}
   1712  1.1  christos     | PARSEOP_ARG3                  {$$ = TrCreateLeafNode (PARSEOP_ARG3);}
   1713  1.1  christos     | PARSEOP_ARG4                  {$$ = TrCreateLeafNode (PARSEOP_ARG4);}
   1714  1.1  christos     | PARSEOP_ARG5                  {$$ = TrCreateLeafNode (PARSEOP_ARG5);}
   1715  1.1  christos     | PARSEOP_ARG6                  {$$ = TrCreateLeafNode (PARSEOP_ARG6);}
   1716  1.1  christos     ;
   1717  1.1  christos 
   1718  1.1  christos LocalTerm
   1719  1.1  christos     : PARSEOP_LOCAL0                {$$ = TrCreateLeafNode (PARSEOP_LOCAL0);}
   1720  1.1  christos     | PARSEOP_LOCAL1                {$$ = TrCreateLeafNode (PARSEOP_LOCAL1);}
   1721  1.1  christos     | PARSEOP_LOCAL2                {$$ = TrCreateLeafNode (PARSEOP_LOCAL2);}
   1722  1.1  christos     | PARSEOP_LOCAL3                {$$ = TrCreateLeafNode (PARSEOP_LOCAL3);}
   1723  1.1  christos     | PARSEOP_LOCAL4                {$$ = TrCreateLeafNode (PARSEOP_LOCAL4);}
   1724  1.1  christos     | PARSEOP_LOCAL5                {$$ = TrCreateLeafNode (PARSEOP_LOCAL5);}
   1725  1.1  christos     | PARSEOP_LOCAL6                {$$ = TrCreateLeafNode (PARSEOP_LOCAL6);}
   1726  1.1  christos     | PARSEOP_LOCAL7                {$$ = TrCreateLeafNode (PARSEOP_LOCAL7);}
   1727  1.1  christos     ;
   1728  1.1  christos 
   1729  1.1  christos DebugTerm
   1730  1.1  christos     : PARSEOP_DEBUG                 {$$ = TrCreateLeafNode (PARSEOP_DEBUG);}
   1731  1.1  christos     ;
   1732  1.1  christos 
   1733  1.1  christos 
   1734  1.1  christos ByteConst
   1735  1.1  christos     : Integer                       {$$ = TrUpdateNode (PARSEOP_BYTECONST, $1);}
   1736  1.1  christos     ;
   1737  1.1  christos 
   1738  1.1  christos WordConst
   1739  1.1  christos     : Integer                       {$$ = TrUpdateNode (PARSEOP_WORDCONST, $1);}
   1740  1.1  christos     ;
   1741  1.1  christos 
   1742  1.1  christos DWordConst
   1743  1.1  christos     : Integer                       {$$ = TrUpdateNode (PARSEOP_DWORDCONST, $1);}
   1744  1.1  christos     ;
   1745  1.1  christos 
   1746  1.1  christos QWordConst
   1747  1.1  christos     : Integer                       {$$ = TrUpdateNode (PARSEOP_QWORDCONST, $1);}
   1748  1.1  christos     ;
   1749  1.1  christos 
   1750  1.1  christos Integer
   1751  1.1  christos     : PARSEOP_INTEGER               {$$ = TrCreateValuedLeafNode (PARSEOP_INTEGER, AslCompilerlval.i);}
   1752  1.1  christos     ;
   1753  1.1  christos 
   1754  1.1  christos String
   1755  1.1  christos     : PARSEOP_STRING_LITERAL        {$$ = TrCreateValuedLeafNode (PARSEOP_STRING_LITERAL, (ACPI_NATIVE_INT) AslCompilerlval.s);}
   1756  1.1  christos     ;
   1757  1.1  christos 
   1758  1.1  christos ConstTerm
   1759  1.1  christos     : ConstExprTerm                 {}
   1760  1.1  christos     | PARSEOP_REVISION              {$$ = TrCreateLeafNode (PARSEOP_REVISION);}
   1761  1.1  christos     ;
   1762  1.1  christos 
   1763  1.1  christos ConstExprTerm
   1764  1.1  christos     : PARSEOP_ZERO                  {$$ = TrCreateValuedLeafNode (PARSEOP_ZERO, 0);}
   1765  1.1  christos     | PARSEOP_ONE                   {$$ = TrCreateValuedLeafNode (PARSEOP_ONE, 1);}
   1766  1.1  christos     | PARSEOP_ONES                  {$$ = TrCreateValuedLeafNode (PARSEOP_ONES, ACPI_UINT64_MAX);}
   1767  1.1  christos     | PARSEOP___DATE__              {$$ = TrCreateConstantLeafNode (PARSEOP___DATE__);}
   1768  1.1  christos     | PARSEOP___FILE__              {$$ = TrCreateConstantLeafNode (PARSEOP___FILE__);}
   1769  1.1  christos     | PARSEOP___LINE__              {$$ = TrCreateConstantLeafNode (PARSEOP___LINE__);}
   1770  1.1  christos     | PARSEOP___PATH__              {$$ = TrCreateConstantLeafNode (PARSEOP___PATH__);}
   1771  1.1  christos     ;
   1772  1.1  christos 
   1773  1.1  christos /*
   1774  1.1  christos  * The NODE_COMPILE_TIME_CONST flag in the following constant expressions
   1775  1.1  christos  * enables compile-time constant folding to reduce the Type3Opcodes/Type2IntegerOpcodes
   1776  1.1  christos  * to simple integers. It is an error if these types of expressions cannot be
   1777  1.1  christos  * reduced, since the AML grammar for ****ConstExpr requires a simple constant.
   1778  1.1  christos  * Note: The required byte length of the constant is passed through to the
   1779  1.1  christos  * constant folding code in the node AmlLength field.
   1780  1.1  christos  */
   1781  1.1  christos ByteConstExpr
   1782  1.1  christos     : Type3Opcode                   {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST); TrSetNodeAmlLength ($1, 1);}
   1783  1.1  christos     | Type2IntegerOpcode            {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST); TrSetNodeAmlLength ($1, 1);}
   1784  1.1  christos     | ConstExprTerm                 {$$ = TrUpdateNode (PARSEOP_BYTECONST, $1);}
   1785  1.1  christos     | ByteConst                     {}
   1786  1.1  christos     ;
   1787  1.1  christos 
   1788  1.1  christos WordConstExpr
   1789  1.1  christos     : Type3Opcode                   {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST); TrSetNodeAmlLength ($1, 2);}
   1790  1.1  christos     | Type2IntegerOpcode            {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST); TrSetNodeAmlLength ($1, 2);}
   1791  1.1  christos     | ConstExprTerm                 {$$ = TrUpdateNode (PARSEOP_WORDCONST, $1);}
   1792  1.1  christos     | WordConst                     {}
   1793  1.1  christos     ;
   1794  1.1  christos 
   1795  1.1  christos DWordConstExpr
   1796  1.1  christos     : Type3Opcode                   {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST); TrSetNodeAmlLength ($1, 4);}
   1797  1.1  christos     | Type2IntegerOpcode            {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST); TrSetNodeAmlLength ($1, 4);}
   1798  1.1  christos     | ConstExprTerm                 {$$ = TrUpdateNode (PARSEOP_DWORDCONST, $1);}
   1799  1.1  christos     | DWordConst                    {}
   1800  1.1  christos     ;
   1801  1.1  christos 
   1802  1.1  christos QWordConstExpr
   1803  1.1  christos     : Type3Opcode                   {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST); TrSetNodeAmlLength ($1, 8);}
   1804  1.1  christos     | Type2IntegerOpcode            {$$ = TrSetNodeFlags ($1, NODE_COMPILE_TIME_CONST); TrSetNodeAmlLength ($1, 8);}
   1805  1.1  christos     | ConstExprTerm                 {$$ = TrUpdateNode (PARSEOP_QWORDCONST, $1);}
   1806  1.1  christos     | QWordConst                    {}
   1807  1.1  christos     ;
   1808  1.1  christos 
   1809  1.1  christos /* OptionalCount must appear before ByteList or an incorrect reduction will result */
   1810  1.1  christos 
   1811  1.1  christos OptionalCount
   1812  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_ONES);}       /* Placeholder is a OnesOp object */
   1813  1.1  christos     | ','                           {$$ = TrCreateLeafNode (PARSEOP_ONES);}       /* Placeholder is a OnesOp object */
   1814  1.1  christos     | ',' TermArg                   {$$ = $2;}
   1815  1.1  christos     ;
   1816  1.1  christos 
   1817  1.1  christos BufferTerm
   1818  1.1  christos     : PARSEOP_BUFFER '('            {$<n>$ = TrCreateLeafNode (PARSEOP_BUFFER);}
   1819  1.1  christos         OptionalTermArg
   1820  1.1  christos         ')' '{'
   1821  1.1  christos             BufferTermData '}'      {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
   1822  1.1  christos     | PARSEOP_BUFFER '('
   1823  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1824  1.1  christos     ;
   1825  1.1  christos 
   1826  1.1  christos BufferTermData
   1827  1.1  christos     : ByteList                      {}
   1828  1.1  christos     | StringData                    {}
   1829  1.1  christos     ;
   1830  1.1  christos 
   1831  1.1  christos ByteList
   1832  1.1  christos     :                               {$$ = NULL;}
   1833  1.1  christos     | ByteConstExpr
   1834  1.1  christos     | ByteList ','                  /* Allows a trailing comma at list end */
   1835  1.1  christos     | ByteList ','
   1836  1.1  christos         ByteConstExpr               {$$ = TrLinkPeerNode ($1,$3);}
   1837  1.1  christos     ;
   1838  1.1  christos 
   1839  1.1  christos DataBufferTerm
   1840  1.1  christos     : PARSEOP_DATABUFFER  '('       {$<n>$ = TrCreateLeafNode (PARSEOP_DATABUFFER);}
   1841  1.1  christos         OptionalWordConst
   1842  1.1  christos         ')' '{'
   1843  1.1  christos             ByteList '}'            {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
   1844  1.1  christos     | PARSEOP_DATABUFFER '('
   1845  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1846  1.1  christos     ;
   1847  1.1  christos 
   1848  1.1  christos DWordList
   1849  1.1  christos     :                               {$$ = NULL;}
   1850  1.1  christos     | DWordConstExpr
   1851  1.1  christos     | DWordList ','                 /* Allows a trailing comma at list end */
   1852  1.1  christos     | DWordList ','
   1853  1.1  christos         DWordConstExpr              {$$ = TrLinkPeerNode ($1,$3);}
   1854  1.1  christos     ;
   1855  1.1  christos 
   1856  1.1  christos PackageTerm
   1857  1.1  christos     : PARSEOP_PACKAGE '('           {$<n>$ = TrCreateLeafNode (PARSEOP_VAR_PACKAGE);}
   1858  1.1  christos         VarPackageLengthTerm
   1859  1.1  christos         ')' '{'
   1860  1.1  christos             PackageList '}'         {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
   1861  1.1  christos     | PARSEOP_PACKAGE '('
   1862  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1863  1.1  christos     ;
   1864  1.1  christos 
   1865  1.1  christos PackageList
   1866  1.1  christos     :                               {$$ = NULL;}
   1867  1.1  christos     | PackageElement
   1868  1.1  christos     | PackageList ','               /* Allows a trailing comma at list end */
   1869  1.1  christos     | PackageList ','
   1870  1.1  christos         PackageElement              {$$ = TrLinkPeerNode ($1,$3);}
   1871  1.1  christos     ;
   1872  1.1  christos 
   1873  1.1  christos PackageElement
   1874  1.1  christos     : DataObject                    {}
   1875  1.1  christos     | NameString                    {}
   1876  1.1  christos     ;
   1877  1.1  christos 
   1878  1.1  christos VarPackageLengthTerm
   1879  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_DEFAULT_ARG);}
   1880  1.1  christos     | TermArg                       {$$ = $1;}
   1881  1.1  christos     ;
   1882  1.1  christos 
   1883  1.1  christos 
   1884  1.1  christos /******* Macros ***********************************************/
   1885  1.1  christos 
   1886  1.1  christos 
   1887  1.1  christos EISAIDTerm
   1888  1.1  christos     : PARSEOP_EISAID '('
   1889  1.1  christos         StringData ')'              {$$ = TrUpdateNode (PARSEOP_EISAID, $3);}
   1890  1.1  christos     | PARSEOP_EISAID '('
   1891  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1892  1.1  christos     ;
   1893  1.1  christos 
   1894  1.1  christos UnicodeTerm
   1895  1.1  christos     : PARSEOP_UNICODE '('           {$<n>$ = TrCreateLeafNode (PARSEOP_UNICODE);}
   1896  1.1  christos         StringData
   1897  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,2,0,$4);}
   1898  1.1  christos     | PARSEOP_UNICODE '('
   1899  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1900  1.1  christos     ;
   1901  1.1  christos 
   1902  1.1  christos 
   1903  1.1  christos /******* Resources and Memory ***********************************************/
   1904  1.1  christos 
   1905  1.1  christos 
   1906  1.1  christos /*
   1907  1.1  christos  * Note: Create two default nodes to allow conversion to a Buffer AML opcode
   1908  1.1  christos  * Also, insert the EndTag at the end of the template.
   1909  1.1  christos  */
   1910  1.1  christos ResourceTemplateTerm
   1911  1.1  christos     : PARSEOP_RESOURCETEMPLATE '(' ')'
   1912  1.1  christos         '{'
   1913  1.1  christos         ResourceMacroList '}'       {$$ = TrCreateNode (PARSEOP_RESOURCETEMPLATE,4,
   1914  1.1  christos                                           TrCreateLeafNode (PARSEOP_DEFAULT_ARG),
   1915  1.1  christos                                           TrCreateLeafNode (PARSEOP_DEFAULT_ARG),
   1916  1.1  christos                                           $5,
   1917  1.1  christos                                           TrCreateLeafNode (PARSEOP_ENDTAG));}
   1918  1.1  christos     ;
   1919  1.1  christos 
   1920  1.1  christos ResourceMacroList
   1921  1.1  christos     :                               {$$ = NULL;}
   1922  1.1  christos     | ResourceMacroList
   1923  1.1  christos         ResourceMacroTerm           {$$ = TrLinkPeerNode ($1,$2);}
   1924  1.1  christos     ;
   1925  1.1  christos 
   1926  1.1  christos ResourceMacroTerm
   1927  1.1  christos     : DMATerm                       {}
   1928  1.1  christos     | DWordIOTerm                   {}
   1929  1.1  christos     | DWordMemoryTerm               {}
   1930  1.1  christos     | DWordSpaceTerm                {}
   1931  1.1  christos     | EndDependentFnTerm            {}
   1932  1.1  christos     | ExtendedIOTerm                {}
   1933  1.1  christos     | ExtendedMemoryTerm            {}
   1934  1.1  christos     | ExtendedSpaceTerm             {}
   1935  1.1  christos     | FixedDmaTerm                  {}
   1936  1.1  christos     | FixedIOTerm                   {}
   1937  1.1  christos     | GpioIntTerm                   {}
   1938  1.1  christos     | GpioIoTerm                    {}
   1939  1.1  christos     | I2cSerialBusTerm              {}
   1940  1.1  christos     | InterruptTerm                 {}
   1941  1.1  christos     | IOTerm                        {}
   1942  1.1  christos     | IRQNoFlagsTerm                {}
   1943  1.1  christos     | IRQTerm                       {}
   1944  1.1  christos     | Memory24Term                  {}
   1945  1.1  christos     | Memory32FixedTerm             {}
   1946  1.1  christos     | Memory32Term                  {}
   1947  1.1  christos     | QWordIOTerm                   {}
   1948  1.1  christos     | QWordMemoryTerm               {}
   1949  1.1  christos     | QWordSpaceTerm                {}
   1950  1.1  christos     | RegisterTerm                  {}
   1951  1.1  christos     | SpiSerialBusTerm              {}
   1952  1.1  christos     | StartDependentFnNoPriTerm     {}
   1953  1.1  christos     | StartDependentFnTerm          {}
   1954  1.1  christos     | UartSerialBusTerm             {}
   1955  1.1  christos     | VendorLongTerm                {}
   1956  1.1  christos     | VendorShortTerm               {}
   1957  1.1  christos     | WordBusNumberTerm             {}
   1958  1.1  christos     | WordIOTerm                    {}
   1959  1.1  christos     | WordSpaceTerm                 {}
   1960  1.1  christos     ;
   1961  1.1  christos 
   1962  1.1  christos DMATerm
   1963  1.1  christos     : PARSEOP_DMA '('               {$<n>$ = TrCreateLeafNode (PARSEOP_DMA);}
   1964  1.1  christos         DMATypeKeyword
   1965  1.1  christos         OptionalBusMasterKeyword
   1966  1.1  christos         ',' XferTypeKeyword
   1967  1.1  christos         OptionalNameString_Last
   1968  1.1  christos         ')' '{'
   1969  1.1  christos             ByteList '}'            {$$ = TrLinkChildren ($<n>3,5,$4,$5,$7,$8,$11);}
   1970  1.1  christos     | PARSEOP_DMA '('
   1971  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1972  1.1  christos     ;
   1973  1.1  christos 
   1974  1.1  christos DWordIOTerm
   1975  1.1  christos     : PARSEOP_DWORDIO '('           {$<n>$ = TrCreateLeafNode (PARSEOP_DWORDIO);}
   1976  1.1  christos         OptionalResourceType_First
   1977  1.1  christos         OptionalMinType
   1978  1.1  christos         OptionalMaxType
   1979  1.1  christos         OptionalDecodeType
   1980  1.1  christos         OptionalRangeType
   1981  1.1  christos         ',' DWordConstExpr
   1982  1.1  christos         ',' DWordConstExpr
   1983  1.1  christos         ',' DWordConstExpr
   1984  1.1  christos         ',' DWordConstExpr
   1985  1.1  christos         ',' DWordConstExpr
   1986  1.1  christos         OptionalByteConstExpr
   1987  1.1  christos         OptionalStringData
   1988  1.1  christos         OptionalNameString
   1989  1.1  christos         OptionalType
   1990  1.1  christos         OptionalTranslationType_Last
   1991  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,15,$4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$19,$20,$21,$22,$23);}
   1992  1.1  christos     | PARSEOP_DWORDIO '('
   1993  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   1994  1.1  christos     ;
   1995  1.1  christos 
   1996  1.1  christos DWordMemoryTerm
   1997  1.1  christos     : PARSEOP_DWORDMEMORY '('       {$<n>$ = TrCreateLeafNode (PARSEOP_DWORDMEMORY);}
   1998  1.1  christos         OptionalResourceType_First
   1999  1.1  christos         OptionalDecodeType
   2000  1.1  christos         OptionalMinType
   2001  1.1  christos         OptionalMaxType
   2002  1.1  christos         OptionalMemType
   2003  1.1  christos         ',' OptionalReadWriteKeyword
   2004  1.1  christos         ',' DWordConstExpr
   2005  1.1  christos         ',' DWordConstExpr
   2006  1.1  christos         ',' DWordConstExpr
   2007  1.1  christos         ',' DWordConstExpr
   2008  1.1  christos         ',' DWordConstExpr
   2009  1.1  christos         OptionalByteConstExpr
   2010  1.1  christos         OptionalStringData
   2011  1.1  christos         OptionalNameString
   2012  1.1  christos         OptionalAddressRange
   2013  1.1  christos         OptionalType_Last
   2014  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,16,$4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$20,$21,$22,$23,$24,$25);}
   2015  1.1  christos     | PARSEOP_DWORDMEMORY '('
   2016  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2017  1.1  christos     ;
   2018  1.1  christos 
   2019  1.1  christos DWordSpaceTerm
   2020  1.1  christos     : PARSEOP_DWORDSPACE '('        {$<n>$ = TrCreateLeafNode (PARSEOP_DWORDSPACE);}
   2021  1.1  christos         ByteConstExpr               {UtCheckIntegerRange ($4, 0xC0, 0xFF);}
   2022  1.1  christos         OptionalResourceType
   2023  1.1  christos         OptionalDecodeType
   2024  1.1  christos         OptionalMinType
   2025  1.1  christos         OptionalMaxType
   2026  1.1  christos         ',' ByteConstExpr
   2027  1.1  christos         ',' DWordConstExpr
   2028  1.1  christos         ',' DWordConstExpr
   2029  1.1  christos         ',' DWordConstExpr
   2030  1.1  christos         ',' DWordConstExpr
   2031  1.1  christos         ',' DWordConstExpr
   2032  1.1  christos         OptionalByteConstExpr
   2033  1.1  christos         OptionalStringData
   2034  1.1  christos         OptionalNameString_Last
   2035  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,14,$4,$6,$7,$8,$9,$11,$13,$15,$17,$19,$21,$22,$23,$24);}
   2036  1.1  christos     | PARSEOP_DWORDSPACE '('
   2037  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2038  1.1  christos     ;
   2039  1.1  christos 
   2040  1.1  christos 
   2041  1.1  christos EndDependentFnTerm
   2042  1.1  christos     : PARSEOP_ENDDEPENDENTFN '('
   2043  1.1  christos         ')'                         {$$ = TrCreateLeafNode (PARSEOP_ENDDEPENDENTFN);}
   2044  1.1  christos     | PARSEOP_ENDDEPENDENTFN '('
   2045  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2046  1.1  christos     ;
   2047  1.1  christos 
   2048  1.1  christos ExtendedIOTerm
   2049  1.1  christos     : PARSEOP_EXTENDEDIO '('        {$<n>$ = TrCreateLeafNode (PARSEOP_EXTENDEDIO);}
   2050  1.1  christos         OptionalResourceType_First
   2051  1.1  christos         OptionalMinType
   2052  1.1  christos         OptionalMaxType
   2053  1.1  christos         OptionalDecodeType
   2054  1.1  christos         OptionalRangeType
   2055  1.1  christos         ',' QWordConstExpr
   2056  1.1  christos         ',' QWordConstExpr
   2057  1.1  christos         ',' QWordConstExpr
   2058  1.1  christos         ',' QWordConstExpr
   2059  1.1  christos         ',' QWordConstExpr
   2060  1.1  christos         OptionalQWordConstExpr
   2061  1.1  christos         OptionalNameString
   2062  1.1  christos         OptionalType
   2063  1.1  christos         OptionalTranslationType_Last
   2064  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,14,$4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$19,$20,$21,$22);}
   2065  1.1  christos     | PARSEOP_EXTENDEDIO '('
   2066  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2067  1.1  christos     ;
   2068  1.1  christos 
   2069  1.1  christos ExtendedMemoryTerm
   2070  1.1  christos     : PARSEOP_EXTENDEDMEMORY '('    {$<n>$ = TrCreateLeafNode (PARSEOP_EXTENDEDMEMORY);}
   2071  1.1  christos         OptionalResourceType_First
   2072  1.1  christos         OptionalDecodeType
   2073  1.1  christos         OptionalMinType
   2074  1.1  christos         OptionalMaxType
   2075  1.1  christos         OptionalMemType
   2076  1.1  christos         ',' OptionalReadWriteKeyword
   2077  1.1  christos         ',' QWordConstExpr
   2078  1.1  christos         ',' QWordConstExpr
   2079  1.1  christos         ',' QWordConstExpr
   2080  1.1  christos         ',' QWordConstExpr
   2081  1.1  christos         ',' QWordConstExpr
   2082  1.1  christos         OptionalQWordConstExpr
   2083  1.1  christos         OptionalNameString
   2084  1.1  christos         OptionalAddressRange
   2085  1.1  christos         OptionalType_Last
   2086  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,15,$4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$20,$21,$22,$23,$24);}
   2087  1.1  christos     | PARSEOP_EXTENDEDMEMORY '('
   2088  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2089  1.1  christos     ;
   2090  1.1  christos 
   2091  1.1  christos ExtendedSpaceTerm
   2092  1.1  christos     : PARSEOP_EXTENDEDSPACE '('     {$<n>$ = TrCreateLeafNode (PARSEOP_EXTENDEDSPACE);}
   2093  1.1  christos         ByteConstExpr               {UtCheckIntegerRange ($4, 0xC0, 0xFF);}
   2094  1.1  christos         OptionalResourceType
   2095  1.1  christos         OptionalDecodeType
   2096  1.1  christos         OptionalMinType
   2097  1.1  christos         OptionalMaxType
   2098  1.1  christos         ',' ByteConstExpr
   2099  1.1  christos         ',' QWordConstExpr
   2100  1.1  christos         ',' QWordConstExpr
   2101  1.1  christos         ',' QWordConstExpr
   2102  1.1  christos         ',' QWordConstExpr
   2103  1.1  christos         ',' QWordConstExpr
   2104  1.1  christos         OptionalQWordConstExpr
   2105  1.1  christos         OptionalNameString_Last
   2106  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,13,$4,$6,$7,$8,$9,$11,$13,$15,$17,$19,$21,$22,$23);}
   2107  1.1  christos     | PARSEOP_EXTENDEDSPACE '('
   2108  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2109  1.1  christos     ;
   2110  1.1  christos 
   2111  1.1  christos FixedDmaTerm
   2112  1.1  christos     : PARSEOP_FIXEDDMA '('          {$<n>$ = TrCreateLeafNode (PARSEOP_FIXEDDMA);}
   2113  1.1  christos         WordConstExpr               /* 04: DMA RequestLines */
   2114  1.1  christos         ',' WordConstExpr           /* 06: DMA Channels */
   2115  1.1  christos         OptionalXferSize            /* 07: DMA TransferSize */
   2116  1.1  christos         OptionalNameString          /* 08: DescriptorName */
   2117  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,4,$4,$6,$7,$8);}
   2118  1.1  christos     | PARSEOP_FIXEDDMA '('
   2119  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2120  1.1  christos     ;
   2121  1.1  christos 
   2122  1.1  christos FixedIOTerm
   2123  1.1  christos     : PARSEOP_FIXEDIO '('           {$<n>$ = TrCreateLeafNode (PARSEOP_FIXEDIO);}
   2124  1.1  christos         WordConstExpr
   2125  1.1  christos         ',' ByteConstExpr
   2126  1.1  christos         OptionalNameString_Last
   2127  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,3,$4,$6,$7);}
   2128  1.1  christos     | PARSEOP_FIXEDIO '('
   2129  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2130  1.1  christos     ;
   2131  1.1  christos 
   2132  1.1  christos GpioIntTerm
   2133  1.1  christos     : PARSEOP_GPIO_INT '('          {$<n>$ = TrCreateLeafNode (PARSEOP_GPIO_INT);}
   2134  1.1  christos         InterruptTypeKeyword        /* 04: InterruptType */
   2135  1.1  christos         ',' InterruptLevel          /* 06: InterruptLevel */
   2136  1.1  christos         OptionalShareType           /* 07: SharedType */
   2137  1.1  christos         ',' PinConfigByte           /* 09: PinConfig */
   2138  1.1  christos         OptionalWordConstExpr       /* 10: DebounceTimeout */
   2139  1.1  christos         ',' StringData              /* 12: ResourceSource */
   2140  1.1  christos         OptionalByteConstExpr       /* 13: ResourceSourceIndex */
   2141  1.1  christos         OptionalResourceType        /* 14: ResourceType */
   2142  1.1  christos         OptionalNameString          /* 15: DescriptorName */
   2143  1.1  christos         OptionalBuffer_Last         /* 16: VendorData */
   2144  1.1  christos         ')' '{'
   2145  1.1  christos             DWordConstExpr '}'      {$$ = TrLinkChildren ($<n>3,11,$4,$6,$7,$9,$10,$12,$13,$14,$15,$16,$19);}
   2146  1.1  christos     | PARSEOP_GPIO_INT '('
   2147  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2148  1.1  christos     ;
   2149  1.1  christos 
   2150  1.1  christos GpioIoTerm
   2151  1.1  christos     : PARSEOP_GPIO_IO '('           {$<n>$ = TrCreateLeafNode (PARSEOP_GPIO_IO);}
   2152  1.1  christos         OptionalShareType_First     /* 04: SharedType */
   2153  1.1  christos         ',' PinConfigByte           /* 06: PinConfig */
   2154  1.1  christos         OptionalWordConstExpr       /* 07: DebounceTimeout */
   2155  1.1  christos         OptionalWordConstExpr       /* 08: DriveStrength */
   2156  1.1  christos         OptionalIoRestriction       /* 09: IoRestriction */
   2157  1.1  christos         ',' StringData              /* 11: ResourceSource */
   2158  1.1  christos         OptionalByteConstExpr       /* 12: ResourceSourceIndex */
   2159  1.1  christos         OptionalResourceType        /* 13: ResourceType */
   2160  1.1  christos         OptionalNameString          /* 14: DescriptorName */
   2161  1.1  christos         OptionalBuffer_Last         /* 15: VendorData */
   2162  1.1  christos         ')' '{'
   2163  1.1  christos             DWordList '}'           {$$ = TrLinkChildren ($<n>3,11,$4,$6,$7,$8,$9,$11,$12,$13,$14,$15,$18);}
   2164  1.1  christos     | PARSEOP_GPIO_IO '('
   2165  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2166  1.1  christos     ;
   2167  1.1  christos 
   2168  1.1  christos I2cSerialBusTerm
   2169  1.1  christos     : PARSEOP_I2C_SERIALBUS '('     {$<n>$ = TrCreateLeafNode (PARSEOP_I2C_SERIALBUS);}
   2170  1.1  christos         WordConstExpr               /* 04: SlaveAddress */
   2171  1.1  christos         OptionalSlaveMode           /* 05: SlaveMode */
   2172  1.1  christos         ',' DWordConstExpr          /* 07: ConnectionSpeed */
   2173  1.1  christos         OptionalAddressingMode      /* 08: AddressingMode */
   2174  1.1  christos         ',' StringData              /* 10: ResourceSource */
   2175  1.1  christos         OptionalByteConstExpr       /* 11: ResourceSourceIndex */
   2176  1.1  christos         OptionalResourceType        /* 12: ResourceType */
   2177  1.1  christos         OptionalNameString          /* 13: DescriptorName */
   2178  1.1  christos         OptionalBuffer_Last         /* 14: VendorData */
   2179  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,9,$4,$5,$7,$8,$10,$11,$12,$13,$14);}
   2180  1.1  christos     | PARSEOP_I2C_SERIALBUS '('
   2181  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2182  1.1  christos     ;
   2183  1.1  christos 
   2184  1.1  christos InterruptTerm
   2185  1.1  christos     : PARSEOP_INTERRUPT '('         {$<n>$ = TrCreateLeafNode (PARSEOP_INTERRUPT);}
   2186  1.1  christos         OptionalResourceType_First
   2187  1.1  christos         ',' InterruptTypeKeyword
   2188  1.1  christos         ',' InterruptLevel
   2189  1.1  christos         OptionalShareType
   2190  1.1  christos         OptionalByteConstExpr
   2191  1.1  christos         OptionalStringData
   2192  1.1  christos         OptionalNameString_Last
   2193  1.1  christos         ')' '{'
   2194  1.1  christos             DWordList '}'           {$$ = TrLinkChildren ($<n>3,8,$4,$6,$8,$9,$10,$11,$12,$15);}
   2195  1.1  christos     | PARSEOP_INTERRUPT '('
   2196  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2197  1.1  christos     ;
   2198  1.1  christos 
   2199  1.1  christos IOTerm
   2200  1.1  christos     : PARSEOP_IO '('                {$<n>$ = TrCreateLeafNode (PARSEOP_IO);}
   2201  1.1  christos         IODecodeKeyword
   2202  1.1  christos         ',' WordConstExpr
   2203  1.1  christos         ',' WordConstExpr
   2204  1.1  christos         ',' ByteConstExpr
   2205  1.1  christos         ',' ByteConstExpr
   2206  1.1  christos         OptionalNameString_Last
   2207  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,6,$4,$6,$8,$10,$12,$13);}
   2208  1.1  christos     | PARSEOP_IO '('
   2209  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2210  1.1  christos     ;
   2211  1.1  christos 
   2212  1.1  christos IRQNoFlagsTerm
   2213  1.1  christos     : PARSEOP_IRQNOFLAGS '('        {$<n>$ = TrCreateLeafNode (PARSEOP_IRQNOFLAGS);}
   2214  1.1  christos         OptionalNameString_First
   2215  1.1  christos         ')' '{'
   2216  1.1  christos             ByteList '}'            {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
   2217  1.1  christos     | PARSEOP_IRQNOFLAGS '('
   2218  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2219  1.1  christos     ;
   2220  1.1  christos 
   2221  1.1  christos IRQTerm
   2222  1.1  christos     : PARSEOP_IRQ '('               {$<n>$ = TrCreateLeafNode (PARSEOP_IRQ);}
   2223  1.1  christos         InterruptTypeKeyword
   2224  1.1  christos         ',' InterruptLevel
   2225  1.1  christos         OptionalShareType
   2226  1.1  christos         OptionalNameString_Last
   2227  1.1  christos         ')' '{'
   2228  1.1  christos             ByteList '}'            {$$ = TrLinkChildren ($<n>3,5,$4,$6,$7,$8,$11);}
   2229  1.1  christos     | PARSEOP_IRQ '('
   2230  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2231  1.1  christos     ;
   2232  1.1  christos 
   2233  1.1  christos Memory24Term
   2234  1.1  christos     : PARSEOP_MEMORY24 '('          {$<n>$ = TrCreateLeafNode (PARSEOP_MEMORY24);}
   2235  1.1  christos         OptionalReadWriteKeyword
   2236  1.1  christos         ',' WordConstExpr
   2237  1.1  christos         ',' WordConstExpr
   2238  1.1  christos         ',' WordConstExpr
   2239  1.1  christos         ',' WordConstExpr
   2240  1.1  christos         OptionalNameString_Last
   2241  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,6,$4,$6,$8,$10,$12,$13);}
   2242  1.1  christos     | PARSEOP_MEMORY24 '('
   2243  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2244  1.1  christos     ;
   2245  1.1  christos 
   2246  1.1  christos Memory32FixedTerm
   2247  1.1  christos     : PARSEOP_MEMORY32FIXED '('     {$<n>$ = TrCreateLeafNode (PARSEOP_MEMORY32FIXED);}
   2248  1.1  christos         OptionalReadWriteKeyword
   2249  1.1  christos         ',' DWordConstExpr
   2250  1.1  christos         ',' DWordConstExpr
   2251  1.1  christos         OptionalNameString_Last
   2252  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,4,$4,$6,$8,$9);}
   2253  1.1  christos     | PARSEOP_MEMORY32FIXED '('
   2254  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2255  1.1  christos     ;
   2256  1.1  christos 
   2257  1.1  christos Memory32Term
   2258  1.1  christos     : PARSEOP_MEMORY32 '('          {$<n>$ = TrCreateLeafNode (PARSEOP_MEMORY32);}
   2259  1.1  christos         OptionalReadWriteKeyword
   2260  1.1  christos         ',' DWordConstExpr
   2261  1.1  christos         ',' DWordConstExpr
   2262  1.1  christos         ',' DWordConstExpr
   2263  1.1  christos         ',' DWordConstExpr
   2264  1.1  christos         OptionalNameString_Last
   2265  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,6,$4,$6,$8,$10,$12,$13);}
   2266  1.1  christos     | PARSEOP_MEMORY32 '('
   2267  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2268  1.1  christos     ;
   2269  1.1  christos 
   2270  1.1  christos QWordIOTerm
   2271  1.1  christos     : PARSEOP_QWORDIO '('           {$<n>$ = TrCreateLeafNode (PARSEOP_QWORDIO);}
   2272  1.1  christos         OptionalResourceType_First
   2273  1.1  christos         OptionalMinType
   2274  1.1  christos         OptionalMaxType
   2275  1.1  christos         OptionalDecodeType
   2276  1.1  christos         OptionalRangeType
   2277  1.1  christos         ',' QWordConstExpr
   2278  1.1  christos         ',' QWordConstExpr
   2279  1.1  christos         ',' QWordConstExpr
   2280  1.1  christos         ',' QWordConstExpr
   2281  1.1  christos         ',' QWordConstExpr
   2282  1.1  christos         OptionalByteConstExpr
   2283  1.1  christos         OptionalStringData
   2284  1.1  christos         OptionalNameString
   2285  1.1  christos         OptionalType
   2286  1.1  christos         OptionalTranslationType_Last
   2287  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,15,$4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$19,$20,$21,$22,$23);}
   2288  1.1  christos     | PARSEOP_QWORDIO '('
   2289  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2290  1.1  christos     ;
   2291  1.1  christos 
   2292  1.1  christos QWordMemoryTerm
   2293  1.1  christos     : PARSEOP_QWORDMEMORY '('       {$<n>$ = TrCreateLeafNode (PARSEOP_QWORDMEMORY);}
   2294  1.1  christos         OptionalResourceType_First
   2295  1.1  christos         OptionalDecodeType
   2296  1.1  christos         OptionalMinType
   2297  1.1  christos         OptionalMaxType
   2298  1.1  christos         OptionalMemType
   2299  1.1  christos         ',' OptionalReadWriteKeyword
   2300  1.1  christos         ',' QWordConstExpr
   2301  1.1  christos         ',' QWordConstExpr
   2302  1.1  christos         ',' QWordConstExpr
   2303  1.1  christos         ',' QWordConstExpr
   2304  1.1  christos         ',' QWordConstExpr
   2305  1.1  christos         OptionalByteConstExpr
   2306  1.1  christos         OptionalStringData
   2307  1.1  christos         OptionalNameString
   2308  1.1  christos         OptionalAddressRange
   2309  1.1  christos         OptionalType_Last
   2310  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,16,$4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$20,$21,$22,$23,$24,$25);}
   2311  1.1  christos     | PARSEOP_QWORDMEMORY '('
   2312  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2313  1.1  christos     ;
   2314  1.1  christos 
   2315  1.1  christos QWordSpaceTerm
   2316  1.1  christos     : PARSEOP_QWORDSPACE '('        {$<n>$ = TrCreateLeafNode (PARSEOP_QWORDSPACE);}
   2317  1.1  christos         ByteConstExpr               {UtCheckIntegerRange ($4, 0xC0, 0xFF);}
   2318  1.1  christos         OptionalResourceType
   2319  1.1  christos         OptionalDecodeType
   2320  1.1  christos         OptionalMinType
   2321  1.1  christos         OptionalMaxType
   2322  1.1  christos         ',' ByteConstExpr
   2323  1.1  christos         ',' QWordConstExpr
   2324  1.1  christos         ',' QWordConstExpr
   2325  1.1  christos         ',' QWordConstExpr
   2326  1.1  christos         ',' QWordConstExpr
   2327  1.1  christos         ',' QWordConstExpr
   2328  1.1  christos         OptionalByteConstExpr
   2329  1.1  christos         OptionalStringData
   2330  1.1  christos         OptionalNameString_Last
   2331  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,14,$4,$6,$7,$8,$9,$11,$13,$15,$17,$19,$21,$22,$23,$24);}
   2332  1.1  christos     | PARSEOP_QWORDSPACE '('
   2333  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2334  1.1  christos     ;
   2335  1.1  christos 
   2336  1.1  christos RegisterTerm
   2337  1.1  christos     : PARSEOP_REGISTER '('          {$<n>$ = TrCreateLeafNode (PARSEOP_REGISTER);}
   2338  1.1  christos         AddressSpaceKeyword
   2339  1.1  christos         ',' ByteConstExpr
   2340  1.1  christos         ',' ByteConstExpr
   2341  1.1  christos         ',' QWordConstExpr
   2342  1.1  christos         OptionalAccessSize
   2343  1.1  christos         OptionalNameString_Last
   2344  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,6,$4,$6,$8,$10,$11,$12);}
   2345  1.1  christos     | PARSEOP_REGISTER '('
   2346  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2347  1.1  christos     ;
   2348  1.1  christos 
   2349  1.1  christos SpiSerialBusTerm
   2350  1.1  christos     : PARSEOP_SPI_SERIALBUS '('     {$<n>$ = TrCreateLeafNode (PARSEOP_SPI_SERIALBUS);}
   2351  1.1  christos         WordConstExpr               /* 04: DeviceSelection */
   2352  1.1  christos         OptionalDevicePolarity      /* 05: DevicePolarity */
   2353  1.1  christos         OptionalWireMode            /* 06: WireMode */
   2354  1.1  christos         ',' ByteConstExpr           /* 08: DataBitLength */
   2355  1.1  christos         OptionalSlaveMode           /* 09: SlaveMode */
   2356  1.1  christos         ',' DWordConstExpr          /* 11: ConnectionSpeed */
   2357  1.1  christos         ',' ClockPolarityKeyword    /* 13: ClockPolarity */
   2358  1.1  christos         ',' ClockPhaseKeyword       /* 15: ClockPhase */
   2359  1.1  christos         ',' StringData              /* 17: ResourceSource */
   2360  1.1  christos         OptionalByteConstExpr       /* 18: ResourceSourceIndex */
   2361  1.1  christos         OptionalResourceType        /* 19: ResourceType */
   2362  1.1  christos         OptionalNameString          /* 20: DescriptorName */
   2363  1.1  christos         OptionalBuffer_Last         /* 21: VendorData */
   2364  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,13,$4,$5,$6,$8,$9,$11,$13,$15,$17,$18,$19,$20,$21);}
   2365  1.1  christos     | PARSEOP_SPI_SERIALBUS '('
   2366  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2367  1.1  christos     ;
   2368  1.1  christos 
   2369  1.1  christos StartDependentFnNoPriTerm
   2370  1.1  christos     : PARSEOP_STARTDEPENDENTFN_NOPRI '('    {$<n>$ = TrCreateLeafNode (PARSEOP_STARTDEPENDENTFN_NOPRI);}
   2371  1.1  christos         ')' '{'
   2372  1.1  christos         ResourceMacroList '}'       {$$ = TrLinkChildren ($<n>3,1,$6);}
   2373  1.1  christos     | PARSEOP_STARTDEPENDENTFN_NOPRI '('
   2374  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2375  1.1  christos     ;
   2376  1.1  christos 
   2377  1.1  christos StartDependentFnTerm
   2378  1.1  christos     : PARSEOP_STARTDEPENDENTFN '('  {$<n>$ = TrCreateLeafNode (PARSEOP_STARTDEPENDENTFN);}
   2379  1.1  christos         ByteConstExpr
   2380  1.1  christos         ',' ByteConstExpr
   2381  1.1  christos         ')' '{'
   2382  1.1  christos         ResourceMacroList '}'       {$$ = TrLinkChildren ($<n>3,3,$4,$6,$9);}
   2383  1.1  christos     | PARSEOP_STARTDEPENDENTFN '('
   2384  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2385  1.1  christos     ;
   2386  1.1  christos 
   2387  1.1  christos UartSerialBusTerm
   2388  1.1  christos     : PARSEOP_UART_SERIALBUS '('    {$<n>$ = TrCreateLeafNode (PARSEOP_UART_SERIALBUS);}
   2389  1.1  christos         DWordConstExpr              /* 04: ConnectionSpeed */
   2390  1.1  christos         OptionalBitsPerByte         /* 05: BitsPerByte */
   2391  1.1  christos         OptionalStopBits            /* 06: StopBits */
   2392  1.1  christos         ',' ByteConstExpr           /* 08: LinesInUse */
   2393  1.1  christos         OptionalEndian              /* 09: Endianess */
   2394  1.1  christos         OptionalParityType          /* 10: Parity */
   2395  1.1  christos         OptionalFlowControl         /* 11: FlowControl */
   2396  1.1  christos         ',' WordConstExpr           /* 13: Rx BufferSize */
   2397  1.1  christos         ',' WordConstExpr           /* 15: Tx BufferSize */
   2398  1.1  christos         ',' StringData              /* 17: ResourceSource */
   2399  1.1  christos         OptionalByteConstExpr       /* 18: ResourceSourceIndex */
   2400  1.1  christos         OptionalResourceType        /* 19: ResourceType */
   2401  1.1  christos         OptionalNameString          /* 20: DescriptorName */
   2402  1.1  christos         OptionalBuffer_Last         /* 21: VendorData */
   2403  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,14,$4,$5,$6,$8,$9,$10,$11,$13,$15,$17,$18,$19,$20,$21);}
   2404  1.1  christos     | PARSEOP_UART_SERIALBUS '('
   2405  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2406  1.1  christos     ;
   2407  1.1  christos 
   2408  1.1  christos VendorLongTerm
   2409  1.1  christos     : PARSEOP_VENDORLONG '('        {$<n>$ = TrCreateLeafNode (PARSEOP_VENDORLONG);}
   2410  1.1  christos         OptionalNameString_First
   2411  1.1  christos         ')' '{'
   2412  1.1  christos             ByteList '}'            {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
   2413  1.1  christos     | PARSEOP_VENDORLONG '('
   2414  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2415  1.1  christos     ;
   2416  1.1  christos 
   2417  1.1  christos VendorShortTerm
   2418  1.1  christos     : PARSEOP_VENDORSHORT '('       {$<n>$ = TrCreateLeafNode (PARSEOP_VENDORSHORT);}
   2419  1.1  christos         OptionalNameString_First
   2420  1.1  christos         ')' '{'
   2421  1.1  christos             ByteList '}'            {$$ = TrLinkChildren ($<n>3,2,$4,$7);}
   2422  1.1  christos     | PARSEOP_VENDORSHORT '('
   2423  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2424  1.1  christos     ;
   2425  1.1  christos 
   2426  1.1  christos WordBusNumberTerm
   2427  1.1  christos     : PARSEOP_WORDBUSNUMBER '('     {$<n>$ = TrCreateLeafNode (PARSEOP_WORDBUSNUMBER);}
   2428  1.1  christos         OptionalResourceType_First
   2429  1.1  christos         OptionalMinType
   2430  1.1  christos         OptionalMaxType
   2431  1.1  christos         OptionalDecodeType
   2432  1.1  christos         ',' WordConstExpr
   2433  1.1  christos         ',' WordConstExpr
   2434  1.1  christos         ',' WordConstExpr
   2435  1.1  christos         ',' WordConstExpr
   2436  1.1  christos         ',' WordConstExpr
   2437  1.1  christos         OptionalByteConstExpr
   2438  1.1  christos         OptionalStringData
   2439  1.1  christos         OptionalNameString_Last
   2440  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,12,$4,$5,$6,$7,$9,$11,$13,$15,$17,$18,$19,$20);}
   2441  1.1  christos     | PARSEOP_WORDBUSNUMBER '('
   2442  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2443  1.1  christos     ;
   2444  1.1  christos 
   2445  1.1  christos WordIOTerm
   2446  1.1  christos     : PARSEOP_WORDIO '('            {$<n>$ = TrCreateLeafNode (PARSEOP_WORDIO);}
   2447  1.1  christos         OptionalResourceType_First
   2448  1.1  christos         OptionalMinType
   2449  1.1  christos         OptionalMaxType
   2450  1.1  christos         OptionalDecodeType
   2451  1.1  christos         OptionalRangeType
   2452  1.1  christos         ',' WordConstExpr
   2453  1.1  christos         ',' WordConstExpr
   2454  1.1  christos         ',' WordConstExpr
   2455  1.1  christos         ',' WordConstExpr
   2456  1.1  christos         ',' WordConstExpr
   2457  1.1  christos         OptionalByteConstExpr
   2458  1.1  christos         OptionalStringData
   2459  1.1  christos         OptionalNameString
   2460  1.1  christos         OptionalType
   2461  1.1  christos         OptionalTranslationType_Last
   2462  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,15,$4,$5,$6,$7,$8,$10,$12,$14,$16,$18,$19,$20,$21,$22,$23);}
   2463  1.1  christos     | PARSEOP_WORDIO '('
   2464  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2465  1.1  christos     ;
   2466  1.1  christos 
   2467  1.1  christos WordSpaceTerm
   2468  1.1  christos     : PARSEOP_WORDSPACE '('         {$<n>$ = TrCreateLeafNode (PARSEOP_WORDSPACE);}
   2469  1.1  christos         ByteConstExpr               {UtCheckIntegerRange ($4, 0xC0, 0xFF);}
   2470  1.1  christos         OptionalResourceType
   2471  1.1  christos         OptionalDecodeType
   2472  1.1  christos         OptionalMinType
   2473  1.1  christos         OptionalMaxType
   2474  1.1  christos         ',' ByteConstExpr
   2475  1.1  christos         ',' WordConstExpr
   2476  1.1  christos         ',' WordConstExpr
   2477  1.1  christos         ',' WordConstExpr
   2478  1.1  christos         ',' WordConstExpr
   2479  1.1  christos         ',' WordConstExpr
   2480  1.1  christos         OptionalByteConstExpr
   2481  1.1  christos         OptionalStringData
   2482  1.1  christos         OptionalNameString_Last
   2483  1.1  christos         ')'                         {$$ = TrLinkChildren ($<n>3,14,$4,$6,$7,$8,$9,$11,$13,$15,$17,$19,$21,$22,$23,$24);}
   2484  1.1  christos     | PARSEOP_WORDSPACE '('
   2485  1.1  christos         error ')'                   {$$ = AslDoError(); yyclearin;}
   2486  1.1  christos     ;
   2487  1.1  christos 
   2488  1.1  christos 
   2489  1.1  christos /******* Object References ***********************************************/
   2490  1.1  christos 
   2491  1.1  christos /* Allow IO, DMA, IRQ Resource macro names to also be used as identifiers */
   2492  1.1  christos 
   2493  1.1  christos NameString
   2494  1.1  christos     : NameSeg                       {}
   2495  1.1  christos     | PARSEOP_NAMESTRING            {$$ = TrCreateValuedLeafNode (PARSEOP_NAMESTRING, (ACPI_NATIVE_INT) AslCompilerlval.s);}
   2496  1.1  christos     | PARSEOP_IO                    {$$ = TrCreateValuedLeafNode (PARSEOP_NAMESTRING, (ACPI_NATIVE_INT) "IO");}
   2497  1.1  christos     | PARSEOP_DMA                   {$$ = TrCreateValuedLeafNode (PARSEOP_NAMESTRING, (ACPI_NATIVE_INT) "DMA");}
   2498  1.1  christos     | PARSEOP_IRQ                   {$$ = TrCreateValuedLeafNode (PARSEOP_NAMESTRING, (ACPI_NATIVE_INT) "IRQ");}
   2499  1.1  christos     ;
   2500  1.1  christos 
   2501  1.1  christos NameSeg
   2502  1.1  christos     : PARSEOP_NAMESEG               {$$ = TrCreateValuedLeafNode (PARSEOP_NAMESEG, (ACPI_NATIVE_INT) AslCompilerlval.s);}
   2503  1.1  christos     ;
   2504  1.1  christos 
   2505  1.1  christos 
   2506  1.1  christos /******* Helper rules ****************************************************/
   2507  1.1  christos 
   2508  1.1  christos 
   2509  1.1  christos AmlPackageLengthTerm
   2510  1.1  christos     : Integer                       {$$ = TrUpdateNode (PARSEOP_PACKAGE_LENGTH,(ACPI_PARSE_OBJECT *) $1);}
   2511  1.1  christos     ;
   2512  1.1  christos 
   2513  1.1  christos NameStringItem
   2514  1.1  christos     : ',' NameString                {$$ = $2;}
   2515  1.1  christos     | ',' error                     {$$ = AslDoError (); yyclearin;}
   2516  1.1  christos     ;
   2517  1.1  christos 
   2518  1.1  christos TermArgItem
   2519  1.1  christos     : ',' TermArg                   {$$ = $2;}
   2520  1.1  christos     | ',' error                     {$$ = AslDoError (); yyclearin;}
   2521  1.1  christos     ;
   2522  1.1  christos 
   2523  1.1  christos OptionalBusMasterKeyword
   2524  1.1  christos     : ','                                       {$$ = TrCreateLeafNode (PARSEOP_BUSMASTERTYPE_MASTER);}
   2525  1.1  christos     | ',' PARSEOP_BUSMASTERTYPE_MASTER          {$$ = TrCreateLeafNode (PARSEOP_BUSMASTERTYPE_MASTER);}
   2526  1.1  christos     | ',' PARSEOP_BUSMASTERTYPE_NOTMASTER       {$$ = TrCreateLeafNode (PARSEOP_BUSMASTERTYPE_NOTMASTER);}
   2527  1.1  christos     ;
   2528  1.1  christos 
   2529  1.1  christos OptionalAccessAttribTerm
   2530  1.1  christos     :                               {$$ = NULL;}
   2531  1.1  christos     | ','                           {$$ = NULL;}
   2532  1.1  christos     | ',' ByteConstExpr             {$$ = $2;}
   2533  1.1  christos     | ',' AccessAttribKeyword       {$$ = $2;}
   2534  1.1  christos     ;
   2535  1.1  christos 
   2536  1.1  christos OptionalAccessSize
   2537  1.1  christos     :                               {$$ = TrCreateValuedLeafNode (PARSEOP_BYTECONST, 0);}
   2538  1.1  christos     | ','                           {$$ = TrCreateValuedLeafNode (PARSEOP_BYTECONST, 0);}
   2539  1.1  christos     | ',' ByteConstExpr             {$$ = $2;}
   2540  1.1  christos     ;
   2541  1.1  christos 
   2542  1.1  christos OptionalAddressingMode
   2543  1.1  christos     : ','                           {$$ = NULL;}
   2544  1.1  christos     | ',' AddressingModeKeyword     {$$ = $2;}
   2545  1.1  christos     ;
   2546  1.1  christos 
   2547  1.1  christos OptionalAddressRange
   2548  1.1  christos     :                               {$$ = NULL;}
   2549  1.1  christos     | ','                           {$$ = NULL;}
   2550  1.1  christos     | ',' AddressKeyword            {$$ = $2;}
   2551  1.1  christos     ;
   2552  1.1  christos 
   2553  1.1  christos OptionalBitsPerByte
   2554  1.1  christos     : ','                           {$$ = NULL;}
   2555  1.1  christos     | ',' BitsPerByteKeyword        {$$ = $2;}
   2556  1.1  christos     ;
   2557  1.1  christos 
   2558  1.1  christos OptionalBuffer_Last
   2559  1.1  christos     :                               {$$ = NULL;}
   2560  1.1  christos     | ','                           {$$ = NULL;}
   2561  1.1  christos     | ',' DataBufferTerm            {$$ = $2;}
   2562  1.1  christos     ;
   2563  1.1  christos 
   2564  1.1  christos OptionalByteConstExpr
   2565  1.1  christos     :                               {$$ = NULL;}
   2566  1.1  christos     | ','                           {$$ = NULL;}
   2567  1.1  christos     | ',' ByteConstExpr             {$$ = $2;}
   2568  1.1  christos     ;
   2569  1.1  christos 
   2570  1.1  christos OptionalDecodeType
   2571  1.1  christos     : ','                           {$$ = NULL;}
   2572  1.1  christos     | ',' DecodeKeyword             {$$ = $2;}
   2573  1.1  christos     ;
   2574  1.1  christos 
   2575  1.1  christos OptionalDevicePolarity
   2576  1.1  christos     : ','                           {$$ = NULL;}
   2577  1.1  christos     | ',' DevicePolarityKeyword     {$$ = $2;}
   2578  1.1  christos     ;
   2579  1.1  christos 
   2580  1.1  christos OptionalDWordConstExpr
   2581  1.1  christos     :                               {$$ = NULL;}
   2582  1.1  christos     | ','                           {$$ = NULL;}
   2583  1.1  christos     | ',' DWordConstExpr            {$$ = $2;}
   2584  1.1  christos     ;
   2585  1.1  christos 
   2586  1.1  christos OptionalEndian
   2587  1.1  christos     : ','                           {$$ = NULL;}
   2588  1.1  christos     | ',' EndianKeyword             {$$ = $2;}
   2589  1.1  christos     ;
   2590  1.1  christos 
   2591  1.1  christos OptionalFlowControl
   2592  1.1  christos     : ','                           {$$ = NULL;}
   2593  1.1  christos     | ',' FlowControlKeyword        {$$ = $2;}
   2594  1.1  christos     ;
   2595  1.1  christos 
   2596  1.1  christos OptionalIoRestriction
   2597  1.1  christos     : ','                           {$$ = NULL;}
   2598  1.1  christos     | ',' IoRestrictionKeyword      {$$ = $2;}
   2599  1.1  christos     ;
   2600  1.1  christos 
   2601  1.1  christos OptionalListString
   2602  1.1  christos     :                               {$$ = TrCreateValuedLeafNode (PARSEOP_STRING_LITERAL, ACPI_TO_INTEGER (""));}   /* Placeholder is a NULL string */
   2603  1.1  christos     | ','                           {$$ = TrCreateValuedLeafNode (PARSEOP_STRING_LITERAL, ACPI_TO_INTEGER (""));}   /* Placeholder is a NULL string */
   2604  1.1  christos     | ',' TermArg                   {$$ = $2;}
   2605  1.1  christos     ;
   2606  1.1  christos 
   2607  1.1  christos OptionalMaxType
   2608  1.1  christos     : ','                           {$$ = NULL;}
   2609  1.1  christos     | ',' MaxKeyword                {$$ = $2;}
   2610  1.1  christos     ;
   2611  1.1  christos 
   2612  1.1  christos OptionalMemType
   2613  1.1  christos     : ','                           {$$ = NULL;}
   2614  1.1  christos     | ',' MemTypeKeyword            {$$ = $2;}
   2615  1.1  christos     ;
   2616  1.1  christos 
   2617  1.1  christos OptionalMinType
   2618  1.1  christos     : ','                           {$$ = NULL;}
   2619  1.1  christos     | ',' MinKeyword                {$$ = $2;}
   2620  1.1  christos     ;
   2621  1.1  christos 
   2622  1.1  christos OptionalNameString
   2623  1.1  christos     :                               {$$ = NULL;}
   2624  1.1  christos     | ','                           {$$ = NULL;}
   2625  1.1  christos     | ',' NameString                {$$ = $2;}
   2626  1.1  christos     ;
   2627  1.1  christos 
   2628  1.1  christos OptionalNameString_Last
   2629  1.1  christos     :                               {$$ = NULL;}
   2630  1.1  christos     | ','                           {$$ = NULL;}
   2631  1.1  christos     | ',' NameString                {$$ = $2;}
   2632  1.1  christos     ;
   2633  1.1  christos 
   2634  1.1  christos OptionalNameString_First
   2635  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_ZERO);}
   2636  1.1  christos     | NameString                    {$$ = $1;}
   2637  1.1  christos     ;
   2638  1.1  christos 
   2639  1.1  christos OptionalObjectTypeKeyword
   2640  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_OBJECTTYPE_UNK);}
   2641  1.1  christos     | ',' ObjectTypeKeyword         {$$ = $2;}
   2642  1.1  christos     ;
   2643  1.1  christos 
   2644  1.1  christos OptionalParityType
   2645  1.1  christos     : ','                           {$$ = NULL;}
   2646  1.1  christos     | ',' ParityTypeKeyword         {$$ = $2;}
   2647  1.1  christos     ;
   2648  1.1  christos 
   2649  1.1  christos OptionalQWordConstExpr
   2650  1.1  christos     :                               {$$ = NULL;}
   2651  1.1  christos     | ','                           {$$ = NULL;}
   2652  1.1  christos     | ',' QWordConstExpr            {$$ = $2;}
   2653  1.1  christos     ;
   2654  1.1  christos 
   2655  1.1  christos OptionalRangeType
   2656  1.1  christos     : ','                           {$$ = NULL;}
   2657  1.1  christos     | ',' RangeTypeKeyword          {$$ = $2;}
   2658  1.1  christos     ;
   2659  1.1  christos 
   2660  1.1  christos OptionalReadWriteKeyword
   2661  1.1  christos     :                                   {$$ = TrCreateLeafNode (PARSEOP_READWRITETYPE_BOTH);}
   2662  1.1  christos     | PARSEOP_READWRITETYPE_BOTH        {$$ = TrCreateLeafNode (PARSEOP_READWRITETYPE_BOTH);}
   2663  1.1  christos     | PARSEOP_READWRITETYPE_READONLY    {$$ = TrCreateLeafNode (PARSEOP_READWRITETYPE_READONLY);}
   2664  1.1  christos     ;
   2665  1.1  christos 
   2666  1.1  christos OptionalReference
   2667  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_ZERO);}       /* Placeholder is a ZeroOp object */
   2668  1.1  christos     | ','                           {$$ = TrCreateLeafNode (PARSEOP_ZERO);}       /* Placeholder is a ZeroOp object */
   2669  1.1  christos     | ',' TermArg                   {$$ = $2;}
   2670  1.1  christos     ;
   2671  1.1  christos 
   2672  1.1  christos OptionalResourceType_First
   2673  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_RESOURCETYPE_CONSUMER);}
   2674  1.1  christos     | ResourceTypeKeyword           {$$ = $1;}
   2675  1.1  christos     ;
   2676  1.1  christos 
   2677  1.1  christos OptionalResourceType
   2678  1.1  christos     :                               {$$ = TrCreateLeafNode (PARSEOP_RESOURCETYPE_CONSUMER);}
   2679  1.1  christos     | ','                           {$$ = TrCreateLeafNode (PARSEOP_RESOURCETYPE_CONSUMER);}
   2680  1.1  christos     | ',' ResourceTypeKeyword       {$$ = $2;}
   2681  1.1  christos     ;
   2682  1.1  christos 
   2683  1.1  christos OptionalReturnArg
   2684  1.1  christos     :                               {$$ = TrSetNodeFlags (TrCreateLeafNode (PARSEOP_ZERO), NODE_IS_NULL_RETURN);}       /* Placeholder is a ZeroOp object */
   2685  1.1  christos     | TermArg                       {$$ = $1;}
   2686  1.1  christos     ;
   2687  1.1  christos 
   2688  1.1  christos OptionalSerializeRuleKeyword
   2689  1.1  christos     :                               {$$ = NULL;}
   2690  1.1  christos     | ','                           {$$ = NULL;}
   2691  1.1  christos     | ',' SerializeRuleKeyword      {$$ = $2;}
   2692  1.1  christos     ;
   2693  1.1  christos 
   2694  1.1  christos OptionalSlaveMode
   2695  1.1  christos     : ','                           {$$ = NULL;}
   2696  1.1  christos     | ',' SlaveModeKeyword          {$$ = $2;}
   2697  1.1  christos     ;
   2698  1.1  christos 
   2699  1.1  christos OptionalShareType
   2700  1.1  christos     :                               {$$ = NULL;}
   2701  1.1  christos     | ','                           {$$ = NULL;}
   2702  1.1  christos     | ',' ShareTypeKeyword          {$$ = $2;}
   2703  1.1  christos     ;
   2704  1.1  christos 
   2705  1.1  christos OptionalShareType_First
   2706  1.1  christos     :                               {$$ = NULL;}
   2707  1.1  christos     | ShareTypeKeyword              {$$ = $1;}
   2708  1.1  christos     ;
   2709  1.1  christos 
   2710  1.1  christos OptionalStopBits
   2711  1.1  christos     : ','                           {$$ = NULL;}
   2712  1.1  christos     | ',' StopBitsKeyword           {$$ = $2;}
   2713  1.1  christos     ;
   2714  1.1  christos 
   2715  1.1  christos OptionalStringData
   2716  1.1  christos     :                               {$$ = NULL;}
   2717  1.1  christos     | ','                           {$$ = NULL;}
   2718  1.1  christos     | ',' StringData                {$$ = $2;}
   2719  1.1  christos     ;
   2720  1.1  christos 
   2721  1.1  christos OptionalTermArg
   2722  1.1  christos     :                               {$$ = NULL;}
   2723  1.1  christos     | TermArg                       {$$ = $1;}
   2724  1.1  christos     ;
   2725  1.1  christos 
   2726  1.1  christos OptionalType
   2727  1.1  christos     :                               {$$ = NULL;}
   2728  1.1  christos     | ','                           {$$ = NULL;}
   2729  1.1  christos     | ',' TypeKeyword               {$$ = $2;}
   2730  1.1  christos     ;
   2731  1.1  christos 
   2732  1.1  christos OptionalType_Last
   2733  1.1  christos     :                               {$$ = NULL;}
   2734  1.1  christos     | ','                           {$$ = NULL;}
   2735  1.1  christos     | ',' TypeKeyword               {$$ = $2;}
   2736  1.1  christos     ;
   2737  1.1  christos 
   2738  1.1  christos OptionalTranslationType_Last
   2739  1.1  christos     :                               {$$ = NULL;}
   2740  1.1  christos     | ','                           {$$ = NULL;}
   2741  1.1  christos     | ',' TranslationKeyword        {$$ = $2;}
   2742  1.1  christos     ;
   2743  1.1  christos 
   2744  1.1  christos OptionalWireMode
   2745  1.1  christos     : ','                           {$$ = NULL;}
   2746  1.1  christos     | ',' WireModeKeyword           {$$ = $2;}
   2747  1.1  christos     ;
   2748  1.1  christos 
   2749  1.1  christos OptionalWordConst
   2750  1.1  christos     :                               {$$ = NULL;}
   2751  1.1  christos     | WordConst                     {$$ = $1;}
   2752  1.1  christos     ;
   2753  1.1  christos 
   2754  1.1  christos OptionalWordConstExpr
   2755  1.1  christos     : ','                           {$$ = NULL;}
   2756  1.1  christos     | ',' WordConstExpr             {$$ = $2;}
   2757  1.1  christos     ;
   2758  1.1  christos 
   2759  1.1  christos OptionalXferSize
   2760  1.1  christos     :                               {$$ = TrCreateValuedLeafNode (PARSEOP_XFERSIZE_32, 2);}
   2761  1.1  christos     | ','                           {$$ = TrCreateValuedLeafNode (PARSEOP_XFERSIZE_32, 2);}
   2762  1.1  christos     | ',' XferSizeKeyword           {$$ = $2;}
   2763  1.1  christos     ;
   2764