Print this page
acpica-unix2-20130823
PANKOVs restructure

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/intel/io/acpica/dispatcher/dswstate.c
          +++ new/usr/src/common/acpica/components/dispatcher/dswstate.c
   1    1  /******************************************************************************
   2    2   *
   3    3   * Module Name: dswstate - Dispatcher parse tree walk management routines
   4    4   *
   5    5   *****************************************************************************/
   6    6  
   7    7  /*
   8      - * Copyright (C) 2000 - 2011, Intel Corp.
        8 + * Copyright (C) 2000 - 2013, Intel Corp.
   9    9   * All rights reserved.
  10   10   *
  11   11   * Redistribution and use in source and binary forms, with or without
  12   12   * modification, are permitted provided that the following conditions
  13   13   * are met:
  14   14   * 1. Redistributions of source code must retain the above copyright
  15   15   *    notice, this list of conditions, and the following disclaimer,
  16   16   *    without modification.
  17   17   * 2. Redistributions in binary form must reproduce at minimum a disclaimer
  18   18   *    substantially similar to the "NO WARRANTY" disclaimer below
↓ open down ↓ 359 lines elided ↑ open up ↑
 378  378  
 379  379  /*******************************************************************************
 380  380   *
 381  381   * FUNCTION:    AcpiDsObjStackPop
 382  382   *
 383  383   * PARAMETERS:  PopCount            - Number of objects/entries to pop
 384  384   *              WalkState           - Current Walk state
 385  385   *
 386  386   * RETURN:      Status
 387  387   *
 388      - * DESCRIPTION: Pop this walk's object stack.  Objects on the stack are NOT
      388 + * DESCRIPTION: Pop this walk's object stack. Objects on the stack are NOT
 389  389   *              deleted by this routine.
 390  390   *
 391  391   ******************************************************************************/
 392  392  
 393  393  ACPI_STATUS
 394  394  AcpiDsObjStackPop (
 395  395      UINT32                  PopCount,
 396  396      ACPI_WALK_STATE         *WalkState)
 397  397  {
 398  398      UINT32                  i;
↓ open down ↓ 143 lines elided ↑ open up ↑
 542  542  
 543  543  /*******************************************************************************
 544  544   *
 545  545   * FUNCTION:    AcpiDsPopWalkState
 546  546   *
 547  547   * PARAMETERS:  Thread      - Current thread state
 548  548   *
 549  549   * RETURN:      A WalkState object popped from the thread's stack
 550  550   *
 551  551   * DESCRIPTION: Remove and return the walkstate object that is at the head of
 552      - *              the walk stack for the given walk list.  NULL indicates that
      552 + *              the walk stack for the given walk list. NULL indicates that
 553  553   *              the list is empty.
 554  554   *
 555  555   ******************************************************************************/
 556  556  
 557  557  ACPI_WALK_STATE *
 558  558  AcpiDsPopWalkState (
 559  559      ACPI_THREAD_STATE       *Thread)
 560  560  {
 561  561      ACPI_WALK_STATE         *WalkState;
 562  562  
↓ open down ↓ 24 lines elided ↑ open up ↑
 587  587   *
 588  588   * FUNCTION:    AcpiDsCreateWalkState
 589  589   *
 590  590   * PARAMETERS:  OwnerId         - ID for object creation
 591  591   *              Origin          - Starting point for this walk
 592  592   *              MethodDesc      - Method object
 593  593   *              Thread          - Current thread state
 594  594   *
 595  595   * RETURN:      Pointer to the new walk state.
 596  596   *
 597      - * DESCRIPTION: Allocate and initialize a new walk state.  The current walk
      597 + * DESCRIPTION: Allocate and initialize a new walk state. The current walk
 598  598   *              state is set to this new state.
 599  599   *
 600  600   ******************************************************************************/
 601  601  
 602  602  ACPI_WALK_STATE *
 603  603  AcpiDsCreateWalkState (
 604  604      ACPI_OWNER_ID           OwnerId,
 605  605      ACPI_PARSE_OBJECT       *Origin,
 606  606      ACPI_OPERAND_OBJECT     *MethodDesc,
 607  607      ACPI_THREAD_STATE       *Thread)
↓ open down ↓ 115 lines elided ↑ open up ↑
 723  723          if (ACPI_FAILURE (Status))
 724  724          {
 725  725              return_ACPI_STATUS (Status);
 726  726          }
 727  727      }
 728  728      else
 729  729      {
 730  730          /*
 731  731           * Setup the current scope.
 732  732           * Find a Named Op that has a namespace node associated with it.
 733      -         * search upwards from this Op.  Current scope is the first
      733 +         * search upwards from this Op. Current scope is the first
 734  734           * Op with a namespace node.
 735  735           */
 736  736          ExtraOp = ParserState->StartOp;
 737  737          while (ExtraOp && !ExtraOp->Common.Node)
 738  738          {
 739  739              ExtraOp = ExtraOp->Common.Parent;
 740  740          }
 741  741  
 742  742          if (!ExtraOp)
 743  743          {
↓ open down ↓ 39 lines elided ↑ open up ↑
 783  783      ACPI_WALK_STATE         *WalkState)
 784  784  {
 785  785      ACPI_GENERIC_STATE      *State;
 786  786  
 787  787  
 788  788      ACPI_FUNCTION_TRACE_PTR (DsDeleteWalkState, WalkState);
 789  789  
 790  790  
 791  791      if (!WalkState)
 792  792      {
 793      -        return;
      793 +        return_VOID;
 794  794      }
 795  795  
 796  796      if (WalkState->DescriptorType != ACPI_DESC_TYPE_WALK)
 797  797      {
 798  798          ACPI_ERROR ((AE_INFO, "%p is not a valid walk state",
 799  799              WalkState));
 800      -        return;
      800 +        return_VOID;
 801  801      }
 802  802  
 803  803      /* There should not be any open scopes */
 804  804  
 805  805      if (WalkState->ParserState.Scope)
 806  806      {
 807  807          ACPI_ERROR ((AE_INFO, "%p walk still has a scope list",
 808  808              WalkState));
 809  809          AcpiPsCleanupScope (&WalkState->ParserState);
 810  810      }
↓ open down ↓ 24 lines elided ↑ open up ↑
 835  835      {
 836  836          State = WalkState->Results;
 837  837          WalkState->Results = State->Common.Next;
 838  838  
 839  839          AcpiUtDeleteGenericState (State);
 840  840      }
 841  841  
 842  842      ACPI_FREE (WalkState);
 843  843      return_VOID;
 844  844  }
 845      -
 846      -
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX