ReactOS  0.4.15-dev-1201-gb2cf5a4
psloop.c
Go to the documentation of this file.
1 /******************************************************************************
2  *
3  * Module Name: psloop - Main AML parse loop
4  *
5  *****************************************************************************/
6 
7 /*
8  * Copyright (C) 2000 - 2020, Intel Corp.
9  * All rights reserved.
10  *
11  * Redistribution and use in source and binary forms, with or without
12  * modification, are permitted provided that the following conditions
13  * are met:
14  * 1. Redistributions of source code must retain the above copyright
15  * notice, this list of conditions, and the following disclaimer,
16  * without modification.
17  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
18  * substantially similar to the "NO WARRANTY" disclaimer below
19  * ("Disclaimer") and any redistribution must be conditioned upon
20  * including a substantially similar Disclaimer requirement for further
21  * binary redistribution.
22  * 3. Neither the names of the above-listed copyright holders nor the names
23  * of any contributors may be used to endorse or promote products derived
24  * from this software without specific prior written permission.
25  *
26  * Alternatively, this software may be distributed under the terms of the
27  * GNU General Public License ("GPL") version 2 as published by the Free
28  * Software Foundation.
29  *
30  * NO WARRANTY
31  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
32  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
33  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
34  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
35  * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
36  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
37  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
38  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
39  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
40  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
41  * POSSIBILITY OF SUCH DAMAGES.
42  */
43 
44 /*
45  * Parse the AML and build an operation tree as most interpreters, (such as
46  * Perl) do. Parsing is done by hand rather than with a YACC generated parser
47  * to tightly constrain stack and dynamic memory usage. Parsing is kept
48  * flexible and the code fairly compact by parsing based on a list of AML
49  * opcode templates in AmlOpInfo[].
50  */
51 
52 #include "acpi.h"
53 #include "accommon.h"
54 #include "acinterp.h"
55 #include "acparser.h"
56 #include "acdispat.h"
57 #include "amlcode.h"
58 #include "acconvert.h"
59 #include "acnamesp.h"
60 
61 #define _COMPONENT ACPI_PARSER
62  ACPI_MODULE_NAME ("psloop")
63 
64 
65 /* Local prototypes */
66 
67 static ACPI_STATUS
69  ACPI_WALK_STATE *WalkState,
70  UINT8 *AmlOpStart,
71  ACPI_PARSE_OBJECT *Op);
72 
73 
74 /*******************************************************************************
75  *
76  * FUNCTION: AcpiPsGetArguments
77  *
78  * PARAMETERS: WalkState - Current state
79  * AmlOpStart - Op start in AML
80  * Op - Current Op
81  *
82  * RETURN: Status
83  *
84  * DESCRIPTION: Get arguments for passed Op.
85  *
86  ******************************************************************************/
87 
88 static ACPI_STATUS
90  ACPI_WALK_STATE *WalkState,
91  UINT8 *AmlOpStart,
93 {
95  ACPI_PARSE_OBJECT *Arg = NULL;
96 
97 
98  ACPI_FUNCTION_TRACE_PTR (PsGetArguments, WalkState);
99 
100 
102  "Get arguments for opcode [%s]\n", Op->Common.AmlOpName));
103 
104  switch (Op->Common.AmlOpcode)
105  {
106  case AML_BYTE_OP: /* AML_BYTEDATA_ARG */
107  case AML_WORD_OP: /* AML_WORDDATA_ARG */
108  case AML_DWORD_OP: /* AML_DWORDATA_ARG */
109  case AML_QWORD_OP: /* AML_QWORDATA_ARG */
110  case AML_STRING_OP: /* AML_ASCIICHARLIST_ARG */
111 
112  /* Fill in constant or string argument directly */
113 
114  AcpiPsGetNextSimpleArg (&(WalkState->ParserState),
115  GET_CURRENT_ARG_TYPE (WalkState->ArgTypes), Op);
116  break;
117 
118  case AML_INT_NAMEPATH_OP: /* AML_NAMESTRING_ARG */
119 
120  Status = AcpiPsGetNextNamepath (WalkState,
121  &(WalkState->ParserState), Op, ACPI_POSSIBLE_METHOD_CALL);
122  if (ACPI_FAILURE (Status))
123  {
125  }
126 
127  WalkState->ArgTypes = 0;
128  break;
129 
130  default:
131  /*
132  * Op is not a constant or string, append each argument to the Op
133  */
134  while (GET_CURRENT_ARG_TYPE (WalkState->ArgTypes) &&
135  !WalkState->ArgCount)
136  {
137  WalkState->Aml = WalkState->ParserState.Aml;
138 
139  switch (Op->Common.AmlOpcode)
140  {
141  case AML_METHOD_OP:
142  case AML_BUFFER_OP:
143  case AML_PACKAGE_OP:
145  case AML_WHILE_OP:
146 
147  break;
148 
149  default:
150 
151  ASL_CV_CAPTURE_COMMENTS (WalkState);
152  break;
153  }
154 
155  Status = AcpiPsGetNextArg (WalkState, &(WalkState->ParserState),
156  GET_CURRENT_ARG_TYPE (WalkState->ArgTypes), &Arg);
157  if (ACPI_FAILURE (Status))
158  {
160  }
161 
162  if (Arg)
163  {
164  AcpiPsAppendArg (Op, Arg);
165  }
166 
167  INCREMENT_ARG_LIST (WalkState->ArgTypes);
168  }
169 
171  "Final argument count: %8.8X pass %u\n",
172  WalkState->ArgCount, WalkState->PassNumber));
173 
174  /* Special processing for certain opcodes */
175 
176  switch (Op->Common.AmlOpcode)
177  {
178  case AML_METHOD_OP:
179  /*
180  * Skip parsing of control method because we don't have enough
181  * info in the first pass to parse it correctly.
182  *
183  * Save the length and address of the body
184  */
185  Op->Named.Data = WalkState->ParserState.Aml;
186  Op->Named.Length = (UINT32)
187  (WalkState->ParserState.PkgEnd - WalkState->ParserState.Aml);
188 
189  /* Skip body of method */
190 
191  WalkState->ParserState.Aml = WalkState->ParserState.PkgEnd;
192  WalkState->ArgCount = 0;
193  break;
194 
195  case AML_BUFFER_OP:
196  case AML_PACKAGE_OP:
198 
199  if ((Op->Common.Parent) &&
200  (Op->Common.Parent->Common.AmlOpcode == AML_NAME_OP) &&
201  (WalkState->PassNumber <= ACPI_IMODE_LOAD_PASS2))
202  {
204  "Setup Package/Buffer: Pass %u, AML Ptr: %p\n",
205  WalkState->PassNumber, AmlOpStart));
206 
207  /*
208  * Skip parsing of Buffers and Packages because we don't have
209  * enough info in the first pass to parse them correctly.
210  */
211  Op->Named.Data = AmlOpStart;
212  Op->Named.Length = (UINT32)
213  (WalkState->ParserState.PkgEnd - AmlOpStart);
214 
215  /* Skip body */
216 
217  WalkState->ParserState.Aml = WalkState->ParserState.PkgEnd;
218  WalkState->ArgCount = 0;
219  }
220  break;
221 
222  case AML_WHILE_OP:
223 
224  if (WalkState->ControlState)
225  {
226  WalkState->ControlState->Control.PackageEnd =
227  WalkState->ParserState.PkgEnd;
228  }
229  break;
230 
231  default:
232 
233  /* No action for all other opcodes */
234 
235  break;
236  }
237 
238  break;
239  }
240 
242 }
243 
244 
245 /*******************************************************************************
246  *
247  * FUNCTION: AcpiPsParseLoop
248  *
249  * PARAMETERS: WalkState - Current state
250  *
251  * RETURN: Status
252  *
253  * DESCRIPTION: Parse AML (pointed to by the current parser state) and return
254  * a tree of ops.
255  *
256  ******************************************************************************/
257 
260  ACPI_WALK_STATE *WalkState)
261 {
263  ACPI_PARSE_OBJECT *Op = NULL; /* current op */
264  ACPI_PARSE_STATE *ParserState;
265  UINT8 *AmlOpStart = NULL;
266  UINT8 OpcodeLength;
267 
268 
269  ACPI_FUNCTION_TRACE_PTR (PsParseLoop, WalkState);
270 
271 
272  if (WalkState->DescendingCallback == NULL)
273  {
275  }
276 
277  ParserState = &WalkState->ParserState;
278  WalkState->ArgTypes = 0;
279 
280 #ifndef ACPI_CONSTANT_EVAL_ONLY
281 
282  if (WalkState->WalkType & ACPI_WALK_METHOD_RESTART)
283  {
284  /* We are restarting a preempted control method */
285 
286  if (AcpiPsHasCompletedScope (ParserState))
287  {
288  /*
289  * We must check if a predicate to an IF or WHILE statement
290  * was just completed
291  */
292  if ((ParserState->Scope->ParseScope.Op) &&
293  ((ParserState->Scope->ParseScope.Op->Common.AmlOpcode == AML_IF_OP) ||
294  (ParserState->Scope->ParseScope.Op->Common.AmlOpcode == AML_WHILE_OP)) &&
295  (WalkState->ControlState) &&
296  (WalkState->ControlState->Common.State ==
298  {
299  /*
300  * A predicate was just completed, get the value of the
301  * predicate and branch based on that value
302  */
303  WalkState->Op = NULL;
305  if (ACPI_FAILURE (Status) &&
307  {
309  {
311  "Invoked method did not return a value"));
312  }
313 
314  ACPI_EXCEPTION ((AE_INFO, Status, "GetPredicate Failed"));
316  }
317 
318  Status = AcpiPsNextParseState (WalkState, Op, Status);
319  }
320 
321  AcpiPsPopScope (ParserState, &Op,
322  &WalkState->ArgTypes, &WalkState->ArgCount);
323  ACPI_DEBUG_PRINT ((ACPI_DB_PARSE, "Popped scope, Op=%p\n", Op));
324  }
325  else if (WalkState->PrevOp)
326  {
327  /* We were in the middle of an op */
328 
329  Op = WalkState->PrevOp;
330  WalkState->ArgTypes = WalkState->PrevArgTypes;
331  }
332  }
333 #endif
334 
335  /* Iterative parsing loop, while there is more AML to process: */
336 
337  while ((ParserState->Aml < ParserState->AmlEnd) || (Op))
338  {
339  ASL_CV_CAPTURE_COMMENTS (WalkState);
340 
341  AmlOpStart = ParserState->Aml;
342  if (!Op)
343  {
344  Status = AcpiPsCreateOp (WalkState, AmlOpStart, &Op);
345  if (ACPI_FAILURE (Status))
346  {
347  /*
348  * ACPI_PARSE_MODULE_LEVEL means that we are loading a table by
349  * executing it as a control method. However, if we encounter
350  * an error while loading the table, we need to keep trying to
351  * load the table rather than aborting the table load. Set the
352  * status to AE_OK to proceed with the table load.
353  */
354  if ((WalkState->ParseFlags & ACPI_PARSE_MODULE_LEVEL) &&
356  {
357  Status = AE_OK;
358  }
360  {
361  continue;
362  }
363 
365  {
366  Status = AE_OK;
367  }
368 
369  if (Status == AE_CTRL_TERMINATE)
370  {
372  }
373 
374  Status = AcpiPsCompleteOp (WalkState, &Op, Status);
375  if (ACPI_FAILURE (Status))
376  {
378  }
379  if (AcpiNsOpensScope (
380  AcpiPsGetOpcodeInfo (WalkState->Opcode)->ObjectType))
381  {
382  /*
383  * If the scope/device op fails to parse, skip the body of
384  * the scope op because the parse failure indicates that
385  * the device may not exist.
386  */
387  ACPI_INFO (("Skipping parse of AML opcode: %s (0x%4.4X)",
388  AcpiPsGetOpcodeName (WalkState->Opcode), WalkState->Opcode));
389 
390  /*
391  * Determine the opcode length before skipping the opcode.
392  * An opcode can be 1 byte or 2 bytes in length.
393  */
394  OpcodeLength = 1;
395  if ((WalkState->Opcode & 0xFF00) == AML_EXTENDED_OPCODE)
396  {
397  OpcodeLength = 2;
398  }
399  WalkState->ParserState.Aml = WalkState->Aml + OpcodeLength;
400 
401  WalkState->ParserState.Aml =
403  WalkState->Aml = WalkState->ParserState.Aml;
404  }
405 
406  continue;
407  }
408 
409  AcpiExStartTraceOpcode (Op, WalkState);
410  }
411 
412  /*
413  * Start ArgCount at zero because we don't know if there are
414  * any args yet
415  */
416  WalkState->ArgCount = 0;
417 
418  switch (Op->Common.AmlOpcode)
419  {
420  case AML_BYTE_OP:
421  case AML_WORD_OP:
422  case AML_DWORD_OP:
423  case AML_QWORD_OP:
424 
425  break;
426 
427  default:
428 
429  ASL_CV_CAPTURE_COMMENTS (WalkState);
430  break;
431  }
432 
433  /* Are there any arguments that must be processed? */
434 
435  if (WalkState->ArgTypes)
436  {
437  /* Get arguments */
438 
439  Status = AcpiPsGetArguments (WalkState, AmlOpStart, Op);
440  if (ACPI_FAILURE (Status))
441  {
442  Status = AcpiPsCompleteOp (WalkState, &Op, Status);
443  if (ACPI_FAILURE (Status))
444  {
446  }
447  if ((WalkState->ControlState) &&
448  ((WalkState->ControlState->Control.Opcode == AML_IF_OP) ||
449  (WalkState->ControlState->Control.Opcode == AML_WHILE_OP)))
450  {
451  /*
452  * If the if/while op fails to parse, we will skip parsing
453  * the body of the op.
454  */
455  ParserState->Aml =
456  WalkState->ControlState->Control.AmlPredicateStart + 1;
457  ParserState->Aml =
458  AcpiPsGetNextPackageEnd (ParserState);
459  WalkState->Aml = ParserState->Aml;
460 
461  ACPI_ERROR ((AE_INFO, "Skipping While/If block"));
462  if (*WalkState->Aml == AML_ELSE_OP)
463  {
464  ACPI_ERROR ((AE_INFO, "Skipping Else block"));
465  WalkState->ParserState.Aml = WalkState->Aml + 1;
466  WalkState->ParserState.Aml =
467  AcpiPsGetNextPackageEnd (ParserState);
468  WalkState->Aml = ParserState->Aml;
469  }
471  }
472  Op = NULL;
473  continue;
474  }
475  }
476 
477  /* Check for arguments that need to be processed */
478 
480  "Parseloop: argument count: %8.8X\n", WalkState->ArgCount));
481 
482  if (WalkState->ArgCount)
483  {
484  /*
485  * There are arguments (complex ones), push Op and
486  * prepare for argument
487  */
488  Status = AcpiPsPushScope (ParserState, Op,
489  WalkState->ArgTypes, WalkState->ArgCount);
490  if (ACPI_FAILURE (Status))
491  {
492  Status = AcpiPsCompleteOp (WalkState, &Op, Status);
493  if (ACPI_FAILURE (Status))
494  {
496  }
497 
498  continue;
499  }
500 
501  Op = NULL;
502  continue;
503  }
504 
505  /*
506  * All arguments have been processed -- Op is complete,
507  * prepare for next
508  */
509  WalkState->OpInfo = AcpiPsGetOpcodeInfo (Op->Common.AmlOpcode);
510  if (WalkState->OpInfo->Flags & AML_NAMED)
511  {
512  if (Op->Common.AmlOpcode == AML_REGION_OP ||
513  Op->Common.AmlOpcode == AML_DATA_REGION_OP)
514  {
515  /*
516  * Skip parsing of control method or opregion body,
517  * because we don't have enough info in the first pass
518  * to parse them correctly.
519  *
520  * Completed parsing an OpRegion declaration, we now
521  * know the length.
522  */
523  Op->Named.Length = (UINT32) (ParserState->Aml - Op->Named.Data);
524  }
525  }
526 
527  if (WalkState->OpInfo->Flags & AML_CREATE)
528  {
529  /*
530  * Backup to beginning of CreateXXXfield declaration (1 for
531  * Opcode)
532  *
533  * BodyLength is unknown until we parse the body
534  */
535  Op->Named.Length = (UINT32) (ParserState->Aml - Op->Named.Data);
536  }
537 
538  if (Op->Common.AmlOpcode == AML_BANK_FIELD_OP)
539  {
540  /*
541  * Backup to beginning of BankField declaration
542  *
543  * BodyLength is unknown until we parse the body
544  */
545  Op->Named.Length = (UINT32) (ParserState->Aml - Op->Named.Data);
546  }
547 
548  /* This op complete, notify the dispatcher */
549 
550  if (WalkState->AscendingCallback != NULL)
551  {
552  WalkState->Op = Op;
553  WalkState->Opcode = Op->Common.AmlOpcode;
554 
555  Status = WalkState->AscendingCallback (WalkState);
556  Status = AcpiPsNextParseState (WalkState, Op, Status);
557  if (Status == AE_CTRL_PENDING)
558  {
559  Status = AE_OK;
560  }
561  else if ((WalkState->ParseFlags & ACPI_PARSE_MODULE_LEVEL) &&
563  Status == AE_NOT_FOUND))
564  {
565  /*
566  * ACPI_PARSE_MODULE_LEVEL flag means that we are currently
567  * loading a table by executing it as a control method.
568  * However, if we encounter an error while loading the table,
569  * we need to keep trying to load the table rather than
570  * aborting the table load (setting the status to AE_OK
571  * continues the table load). If we get a failure at this
572  * point, it means that the dispatcher got an error while
573  * trying to execute the Op.
574  */
575  Status = AE_OK;
576  }
577  }
578 
579  Status = AcpiPsCompleteOp (WalkState, &Op, Status);
580  if (ACPI_FAILURE (Status))
581  {
583  }
584 
585  } /* while ParserState->Aml */
586 
587  Status = AcpiPsCompleteFinalOp (WalkState, Op, Status);
589 }
#define ACPI_EXCEPTION(plist)
Definition: acoutput.h:239
#define AE_CODE_MASK
Definition: acexcep.h:60
#define ACPI_FREE(a)
Definition: actypes.h:386
#define AE_CTRL_PARSE_PENDING
Definition: acexcep.h:235
ACPI_PARSE_OBJ_COMMON Common
Definition: aclocal.h:1078
#define AML_NAMED
Definition: amlcode.h:323
#define AML_ELSE_OP
Definition: amlcode.h:135
ACPI_STATE_COMMON UINT16 Opcode
Definition: aclocal.h:725
const char * AcpiPsGetOpcodeName(UINT16 Opcode)
Definition: psopinfo.c:169
ACPI_PARSE_OBJECT * PrevOp
Definition: acstruct.h:125
#define AML_IF_OP
Definition: amlcode.h:134
#define AE_BAD_PARAMETER
Definition: acexcep.h:151
#define TRUE
Definition: types.h:120
#define AML_WHILE_OP
Definition: amlcode.h:136
#define AML_BYTE_OP
Definition: amlcode.h:55
ACPI_STATUS AcpiPsGetNextArg(ACPI_WALK_STATE *WalkState, ACPI_PARSE_STATE *ParserState, UINT32 ArgType, ACPI_PARSE_OBJECT **ReturnArg)
Definition: psargs.c:785
UINT8 ObjectType
Definition: aclocal.h:874
UINT32 ArgTypes
Definition: acstruct.h:92
const ACPI_OPCODE_INFO * AcpiPsGetOpcodeInfo(UINT16 Opcode)
Definition: psopinfo.c:72
#define ACPI_DB_PARSE
Definition: acoutput.h:162
UINT32 ParseFlags
Definition: acstruct.h:95
UINT32 ACPI_STATUS
Definition: actypes.h:460
#define AML_QWORD_OP
Definition: amlcode.h:59
ACPI_GENERIC_STATE * ControlState
Definition: acstruct.h:110
#define AML_VARIABLE_PACKAGE_OP
Definition: amlcode.h:63
#define AML_DWORD_OP
Definition: amlcode.h:57
#define AML_REGION_OP
Definition: amlcode.h:180
#define AML_INT_NAMEPATH_OP
Definition: amlcode.h:205
#define AE_CTRL_PENDING
Definition: acexcep.h:225
ACPI_GENERIC_STATE * AcpiUtPopGenericState(ACPI_GENERIC_STATE **ListHead)
Definition: utstate.c:93
#define AML_STRING_OP
Definition: amlcode.h:58
#define ASL_CV_CAPTURE_COMMENTS(a)
Definition: acmacros.h:526
void AcpiPsPopScope(ACPI_PARSE_STATE *ParserState, ACPI_PARSE_OBJECT **Op, UINT32 *ArgList, UINT32 *ArgCount)
Definition: psscope.c:219
ACPI_PARSE_UPWARDS AscendingCallback
Definition: acstruct.h:129
#define ACPI_TO_POINTER(i)
Definition: actypes.h:552
#define ACPI_FAILURE(a)
Definition: acexcep.h:95
#define AML_NAME_OP
Definition: amlcode.h:54
#define AML_CREATE
Definition: amlcode.h:320
#define AE_CTRL_TERMINATE
Definition: acexcep.h:226
#define ACPI_CONTROL_PREDICATE_EXECUTING
Definition: aclocal.h:671
unsigned int UINT32
ACPI_STATUS AcpiPsParseLoop(ACPI_WALK_STATE *WalkState)
Definition: psloop.c:259
#define AML_EXTENDED_OPCODE
Definition: amlcode.h:156
#define AML_WORD_OP
Definition: amlcode.h:56
UINT8 * AmlPredicateStart
Definition: aclocal.h:727
#define ACPI_MODULE_NAME(Name)
Definition: acoutput.h:216
#define AE_CTRL_PARSE_CONTINUE
Definition: acexcep.h:234
ACPI_STATUS AcpiPsNextParseState(ACPI_WALK_STATE *WalkState, ACPI_PARSE_OBJECT *Op, ACPI_STATUS CallbackStatus)
Definition: psparse.c:337
#define AE_INFO
Definition: acoutput.h:230
smooth NULL
Definition: ftsmooth.c:416
UINT8 WalkType
Definition: acstruct.h:77
#define ACPI_FUNCTION_TRACE_PTR(a, b)
Definition: acoutput.h:481
ACPI_STATUS AcpiPsPushScope(ACPI_PARSE_STATE *ParserState, ACPI_PARSE_OBJECT *Op, UINT32 RemainingArgs, UINT32 ArgCount)
Definition: psscope.c:157
UINT8 * AmlEnd
Definition: aclocal.h:1103
ACPI_PARSE_OBJ_NAMED Named
Definition: aclocal.h:1079
#define AE_AML_NO_RETURN_VALUE
Definition: acexcep.h:197
UINT32 AcpiNsOpensScope(ACPI_OBJECT_TYPE Type)
Definition: nsutils.c:736
ACPI_CONTROL_STATE Control
Definition: aclocal.h:823
#define AML_BANK_FIELD_OP
Definition: amlcode.h:187
void AcpiPsGetNextSimpleArg(ACPI_PARSE_STATE *ParserState, UINT32 ArgType, ACPI_PARSE_OBJECT *Arg)
Definition: psargs.c:428
static ACPI_STATUS AcpiPsGetArguments(ACPI_WALK_STATE *WalkState, UINT8 *AmlOpStart, ACPI_PARSE_OBJECT *Op)
Definition: psloop.c:89
ACPI_PARSE_OBJECT * Op
Definition: acstruct.h:118
BOOLEAN AcpiPsHasCompletedScope(ACPI_PARSE_STATE *ParserState)
Definition: psscope.c:88
#define AE_ALREADY_EXISTS
Definition: acexcep.h:115
#define ACPI_DEBUG_PRINT(pl)
Definition: acoutput.h:475
ACPI_STATUS AcpiPsCreateOp(ACPI_WALK_STATE *WalkState, UINT8 *AmlOpStart, ACPI_PARSE_OBJECT **NewOp)
Definition: psobject.c:344
UINT8 * AcpiPsGetNextPackageEnd(ACPI_PARSE_STATE *ParserState)
Definition: psargs.c:138
void AcpiPsAppendArg(ACPI_PARSE_OBJECT *op, ACPI_PARSE_OBJECT *arg)
Definition: pstree.c:138
#define AE_NOT_FOUND
Definition: acexcep.h:113
const ACPI_OPCODE_INFO * OpInfo
Definition: acstruct.h:119
Status
Definition: gdiplustypes.h:24
ACPI_PARSE_STATE ParserState
Definition: acstruct.h:97
#define ACPI_AML_EXCEPTION(Status)
Definition: acexcep.h:100
#define AML_METHOD_OP
Definition: amlcode.h:64
ACPI_COMMON_STATE Common
Definition: aclocal.h:822
#define ACPI_INFO(plist)
Definition: acoutput.h:237
ACPI_PARSE_DOWNWARDS DescendingCallback
Definition: acstruct.h:128
UINT32 ArgCount
Definition: acstruct.h:99
#define return_ACPI_STATUS(s)
Definition: acoutput.h:496
#define ACPI_PARSE_MODULE_LEVEL
Definition: acparser.h:67
union acpi_parse_object * Op
Definition: aclocal.h:749
#define GET_CURRENT_ARG_TYPE(List)
Definition: acmacros.h:450
#define AE_CODE_CONTROL
Definition: acexcep.h:57
#define INCREMENT_ARG_LIST(List)
Definition: acmacros.h:451
#define ACPI_ERROR(plist)
Definition: acoutput.h:240
ACPI_PSCOPE_STATE ParseScope
Definition: aclocal.h:826
#define AML_BUFFER_OP
Definition: amlcode.h:61
union acpi_generic_state * Scope
Definition: aclocal.h:1108
#define ACPI_POSSIBLE_METHOD_CALL
Definition: acparser.h:118
ACPI_STATUS AcpiDsGetPredicateValue(ACPI_WALK_STATE *WalkState, ACPI_OPERAND_OBJECT *ResultObj)
Definition: dswexec.c:94
UINT16 Opcode
Definition: acstruct.h:78
ACPI_STATUS AcpiPsCompleteOp(ACPI_WALK_STATE *WalkState, ACPI_PARSE_OBJECT **Op, ACPI_STATUS Status)
Definition: psobject.c:495
#define ACPI_WALK_METHOD_RESTART
Definition: acstruct.h:70
UINT32 PrevArgTypes
Definition: acstruct.h:98
ACPI_STATUS AcpiPsGetNextNamepath(ACPI_WALK_STATE *WalkState, ACPI_PARSE_STATE *ParserState, ACPI_PARSE_OBJECT *Arg, BOOLEAN PossibleMethodCall)
Definition: psargs.c:254
unsigned char UINT8
#define AML_DATA_REGION_OP
Definition: amlcode.h:188
#define AE_OK
Definition: acexcep.h:97
UINT16 Flags
Definition: aclocal.h:873
ACPI_STATUS AcpiPsCompleteFinalOp(ACPI_WALK_STATE *WalkState, ACPI_PARSE_OBJECT *Op, ACPI_STATUS Status)
Definition: psobject.c:705
#define AML_PACKAGE_OP
Definition: amlcode.h:62
void AcpiExStartTraceOpcode(ACPI_PARSE_OBJECT *Op, ACPI_WALK_STATE *WalkState)
Definition: extrace.c:353
UINT8 * Aml
Definition: acstruct.h:91