nsaccess.c revision 67754
1/*******************************************************************************
2 *
3 * Module Name: nsaccess - Top-level functions for accessing ACPI namespace
4 *              $Revision: 111 $
5 *
6 ******************************************************************************/
7
8/******************************************************************************
9 *
10 * 1. Copyright Notice
11 *
12 * Some or all of this work - Copyright (c) 1999, Intel Corp.  All rights
13 * reserved.
14 *
15 * 2. License
16 *
17 * 2.1. This is your license from Intel Corp. under its intellectual property
18 * rights.  You may have additional license terms from the party that provided
19 * you this software, covering your right to use that party's intellectual
20 * property rights.
21 *
22 * 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a
23 * copy of the source code appearing in this file ("Covered Code") an
24 * irrevocable, perpetual, worldwide license under Intel's copyrights in the
25 * base code distributed originally by Intel ("Original Intel Code") to copy,
26 * make derivatives, distribute, use and display any portion of the Covered
27 * Code in any form, with the right to sublicense such rights; and
28 *
29 * 2.3. Intel grants Licensee a non-exclusive and non-transferable patent
30 * license (with the right to sublicense), under only those claims of Intel
31 * patents that are infringed by the Original Intel Code, to make, use, sell,
32 * offer to sell, and import the Covered Code and derivative works thereof
33 * solely to the minimum extent necessary to exercise the above copyright
34 * license, and in no event shall the patent license extend to any additions
35 * to or modifications of the Original Intel Code.  No other license or right
36 * is granted directly or by implication, estoppel or otherwise;
37 *
38 * The above copyright and patent license is granted only if the following
39 * conditions are met:
40 *
41 * 3. Conditions
42 *
43 * 3.1. Redistribution of Source with Rights to Further Distribute Source.
44 * Redistribution of source code of any substantial portion of the Covered
45 * Code or modification with rights to further distribute source must include
46 * the above Copyright Notice, the above License, this list of Conditions,
47 * and the following Disclaimer and Export Compliance provision.  In addition,
48 * Licensee must cause all Covered Code to which Licensee contributes to
49 * contain a file documenting the changes Licensee made to create that Covered
50 * Code and the date of any change.  Licensee must include in that file the
51 * documentation of any changes made by any predecessor Licensee.  Licensee
52 * must include a prominent statement that the modification is derived,
53 * directly or indirectly, from Original Intel Code.
54 *
55 * 3.2. Redistribution of Source with no Rights to Further Distribute Source.
56 * Redistribution of source code of any substantial portion of the Covered
57 * Code or modification without rights to further distribute source must
58 * include the following Disclaimer and Export Compliance provision in the
59 * documentation and/or other materials provided with distribution.  In
60 * addition, Licensee may not authorize further sublicense of source of any
61 * portion of the Covered Code, and must include terms to the effect that the
62 * license from Licensee to its licensee is limited to the intellectual
63 * property embodied in the software Licensee provides to its licensee, and
64 * not to intellectual property embodied in modifications its licensee may
65 * make.
66 *
67 * 3.3. Redistribution of Executable. Redistribution in executable form of any
68 * substantial portion of the Covered Code or modification must reproduce the
69 * above Copyright Notice, and the following Disclaimer and Export Compliance
70 * provision in the documentation and/or other materials provided with the
71 * distribution.
72 *
73 * 3.4. Intel retains all right, title, and interest in and to the Original
74 * Intel Code.
75 *
76 * 3.5. Neither the name Intel nor any other trademark owned or controlled by
77 * Intel shall be used in advertising or otherwise to promote the sale, use or
78 * other dealings in products derived from or relating to the Covered Code
79 * without prior written authorization from Intel.
80 *
81 * 4. Disclaimer and Export Compliance
82 *
83 * 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED
84 * HERE.  ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE
85 * IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT,  ASSISTANCE,
86 * INSTALLATION, TRAINING OR OTHER SERVICES.  INTEL WILL NOT PROVIDE ANY
87 * UPDATES, ENHANCEMENTS OR EXTENSIONS.  INTEL SPECIFICALLY DISCLAIMS ANY
88 * IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A
89 * PARTICULAR PURPOSE.
90 *
91 * 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES
92 * OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR
93 * COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT,
94 * SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY
95 * CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL
96 * HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES.  THESE LIMITATIONS
97 * SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY
98 * LIMITED REMEDY.
99 *
100 * 4.3. Licensee shall not export, either directly or indirectly, any of this
101 * software or system incorporating such software without first obtaining any
102 * required license or other approval from the U. S. Department of Commerce or
103 * any other agency or department of the United States Government.  In the
104 * event Licensee exports any such software from the United States or
105 * re-exports any such software from a foreign destination, Licensee shall
106 * ensure that the distribution and export/re-export of the software is in
107 * compliance with all laws, regulations, orders, or other restrictions of the
108 * U.S. Export Administration Regulations. Licensee agrees that neither it nor
109 * any of its subsidiaries will export/re-export any technical data, process,
110 * software, or service, directly or indirectly, to any country for which the
111 * United States government or any agency thereof requires an export license,
112 * other governmental approval, or letter of assurance, without first obtaining
113 * such license, approval or letter.
114 *
115 *****************************************************************************/
116
117#define __NSACCESS_C__
118
119#include "acpi.h"
120#include "amlcode.h"
121#include "acinterp.h"
122#include "acnamesp.h"
123#include "acdispat.h"
124
125
126#define _COMPONENT          NAMESPACE
127        MODULE_NAME         ("nsaccess")
128
129
130/*******************************************************************************
131 *
132 * FUNCTION:    AcpiNsRootInitialize
133 *
134 * PARAMETERS:  None
135 *
136 * RETURN:      Status
137 *
138 * DESCRIPTION: Allocate and initialize the default root named objects
139 *
140 * MUTEX:       Locks namespace for entire execution
141 *
142 ******************************************************************************/
143
144ACPI_STATUS
145AcpiNsRootInitialize (void)
146{
147    ACPI_STATUS             Status = AE_OK;
148    PREDEFINED_NAMES        *InitVal = NULL;
149    ACPI_NAMESPACE_NODE     *NewNode;
150    ACPI_OPERAND_OBJECT     *ObjDesc;
151
152
153    FUNCTION_TRACE ("NsRootInitialize");
154
155
156    AcpiCmAcquireMutex (ACPI_MTX_NAMESPACE);
157
158    /*
159     * The global root ptr is initially NULL, so a non-NULL value indicates
160     * that AcpiNsRootInitialize() has already been called; just return.
161     */
162
163    if (AcpiGbl_RootNode)
164    {
165        Status = AE_OK;
166        goto UnlockAndExit;
167    }
168
169
170    /*
171     * Tell the rest of the subsystem that the root is initialized
172     * (This is OK because the namespace is locked)
173     */
174
175    AcpiGbl_RootNode = &AcpiGbl_RootNodeStruct;
176
177
178    /* Enter the pre-defined names in the name table */
179
180    DEBUG_PRINT (ACPI_INFO,
181        ("Entering predefined name table entries into namespace\n"));
182
183    for (InitVal = AcpiGbl_PreDefinedNames; InitVal->Name; InitVal++)
184    {
185        Status = AcpiNsLookup (NULL, InitVal->Name,
186                                (OBJECT_TYPE_INTERNAL) InitVal->Type,
187                                IMODE_LOAD_PASS2, NS_NO_UPSEARCH,
188                                NULL, &NewNode);
189
190        if (ACPI_FAILURE (Status) ||
191            (!NewNode))
192        {
193            DEBUG_PRINT (ACPI_ERROR,
194                ("Could not create predefined name %s, %s\n",
195                InitVal->Name, AcpiCmFormatException (Status)));
196        }
197
198        /*
199         * Name entered successfully.
200         * If entry in PreDefinedNames[] specifies an
201         * initial value, create the initial value.
202         */
203
204        if (InitVal->Val)
205        {
206            /*
207             * Entry requests an initial value, allocate a
208             * descriptor for it.
209             */
210
211            ObjDesc = AcpiCmCreateInternalObject (
212                            (OBJECT_TYPE_INTERNAL) InitVal->Type);
213
214            if (!ObjDesc)
215            {
216                Status = AE_NO_MEMORY;
217                goto UnlockAndExit;
218            }
219
220            /*
221             * Convert value string from table entry to
222             * internal representation. Only types actually
223             * used for initial values are implemented here.
224             */
225
226            switch (InitVal->Type)
227            {
228
229            case ACPI_TYPE_NUMBER:
230
231                ObjDesc->Number.Value =
232                        (ACPI_INTEGER) STRTOUL (InitVal->Val, NULL, 10);
233                break;
234
235
236            case ACPI_TYPE_STRING:
237
238                ObjDesc->String.Length =
239                        (UINT16) STRLEN (InitVal->Val);
240
241                /*
242                 * Allocate a buffer for the string.  All
243                 * String.Pointers must be allocated buffers!
244                 * (makes deletion simpler)
245                 */
246                ObjDesc->String.Pointer = AcpiCmAllocate (
247                                                (ObjDesc->String.Length + 1));
248                if (!ObjDesc->String.Pointer)
249                {
250                    AcpiCmRemoveReference (ObjDesc);
251                    Status = AE_NO_MEMORY;
252                    goto UnlockAndExit;
253                }
254
255                STRCPY (ObjDesc->String.Pointer, InitVal->Val);
256                break;
257
258
259            case ACPI_TYPE_MUTEX:
260
261                ObjDesc->Mutex.SyncLevel =
262                        (UINT16) STRTOUL (InitVal->Val, NULL, 10);
263
264                if (STRCMP (InitVal->Name, "_GL_") == 0)
265                {
266                    /*
267                     * Create a counting semaphore for the
268                     * global lock
269                     */
270                    Status = AcpiOsCreateSemaphore (ACPI_NO_UNIT_LIMIT,
271                                            1, &ObjDesc->Mutex.Semaphore);
272
273                    if (ACPI_FAILURE (Status))
274                    {
275                        goto UnlockAndExit;
276                    }
277                    /*
278                     * We just created the mutex for the
279                     * global lock, save it
280                     */
281
282                    AcpiGbl_GlobalLockSemaphore = ObjDesc->Mutex.Semaphore;
283                }
284
285                else
286                {
287                    /* Create a mutex */
288
289                    Status = AcpiOsCreateSemaphore (1, 1,
290                                        &ObjDesc->Mutex.Semaphore);
291
292                    if (ACPI_FAILURE (Status))
293                    {
294                        goto UnlockAndExit;
295                    }
296                }
297                break;
298
299
300            default:
301                REPORT_ERROR (("Unsupported initial type value %X\n",
302                    InitVal->Type));
303                AcpiCmRemoveReference (ObjDesc);
304                ObjDesc = NULL;
305                continue;
306            }
307
308            /* Store pointer to value descriptor in the Node */
309
310            AcpiNsAttachObject (NewNode, ObjDesc,
311                                ObjDesc->Common.Type);
312        }
313    }
314
315
316UnlockAndExit:
317    AcpiCmReleaseMutex (ACPI_MTX_NAMESPACE);
318    return_ACPI_STATUS (Status);
319}
320
321
322/*******************************************************************************
323 *
324 * FUNCTION:    AcpiNsLookup
325 *
326 * PARAMETERS:  PrefixNode  - Search scope if name is not fully qualified
327 *              Pathname        - Search pathname, in internal format
328 *                                (as represented in the AML stream)
329 *              Type            - Type associated with name
330 *              InterpreterMode - IMODE_LOAD_PASS2 => add name if not found
331 *              Flags           - Flags describing the search restrictions
332 *              WalkState       - Current state of the walk
333 *              ReturnNode  - Where the Node is placed (if found
334 *                                or created successfully)
335 *
336 * RETURN:      Status
337 *
338 * DESCRIPTION: Find or enter the passed name in the name space.
339 *              Log an error if name not found in Exec mode.
340 *
341 * MUTEX:       Assumes namespace is locked.
342 *
343 ******************************************************************************/
344
345ACPI_STATUS
346AcpiNsLookup (
347    ACPI_GENERIC_STATE      *ScopeInfo,
348    NATIVE_CHAR             *Pathname,
349    OBJECT_TYPE_INTERNAL    Type,
350    OPERATING_MODE          InterpreterMode,
351    UINT32                  Flags,
352    ACPI_WALK_STATE         *WalkState,
353    ACPI_NAMESPACE_NODE     **ReturnNode)
354{
355    ACPI_STATUS             Status;
356    ACPI_NAMESPACE_NODE      *PrefixNode;
357    ACPI_NAMESPACE_NODE     *CurrentNode = NULL;
358    ACPI_NAMESPACE_NODE     *ScopeToPush = NULL;
359    ACPI_NAMESPACE_NODE     *ThisNode = NULL;
360    UINT32                  NumSegments;
361    ACPI_NAME               SimpleName;
362    BOOLEAN                 NullNamePath = FALSE;
363    OBJECT_TYPE_INTERNAL    TypeToCheckFor;
364    OBJECT_TYPE_INTERNAL    ThisSearchType;
365    DEBUG_EXEC              (UINT32 i)
366
367
368    FUNCTION_TRACE ("NsLookup");
369
370
371    if (!ReturnNode)
372    {
373        return_ACPI_STATUS (AE_BAD_PARAMETER);
374    }
375
376
377    AcpiGbl_NsLookupCount++;
378
379    *ReturnNode = ENTRY_NOT_FOUND;
380
381
382    if (!AcpiGbl_RootNode)
383    {
384        return (AE_NO_NAMESPACE);
385    }
386
387    /*
388     * Get the prefix scope.
389     * A null scope means use the root scope
390     */
391
392    if ((!ScopeInfo) ||
393        (!ScopeInfo->Scope.Node))
394    {
395        PrefixNode = AcpiGbl_RootNode;
396    }
397    else
398    {
399        PrefixNode = ScopeInfo->Scope.Node;
400    }
401
402
403    /*
404     * This check is explicitly split provide relax the TypeToCheckFor
405     * conditions for BankFieldDefn.  Originally, both BankFieldDefn and
406     * DefFieldDefn caused TypeToCheckFor to be set to ACPI_TYPE_REGION,
407     * but the BankFieldDefn may also check for a Field definition as well
408     * as an OperationRegion.
409     */
410
411    if (INTERNAL_TYPE_DEF_FIELD_DEFN == Type)
412    {
413        /* DefFieldDefn defines fields in a Region */
414
415        TypeToCheckFor = ACPI_TYPE_REGION;
416    }
417
418    else if (INTERNAL_TYPE_BANK_FIELD_DEFN == Type)
419    {
420        /* BankFieldDefn defines data fields in a Field Object */
421
422        TypeToCheckFor = ACPI_TYPE_ANY;
423    }
424
425    else
426    {
427        TypeToCheckFor = Type;
428    }
429
430
431    /* TBD: [Restructure] - Move the pathname stuff into a new procedure */
432
433    /* Examine the name pointer */
434
435    if (!Pathname)
436    {
437        /*  8-12-98 ASL Grammar Update supports null NamePath   */
438
439        NullNamePath = TRUE;
440        NumSegments = 0;
441        ThisNode = AcpiGbl_RootNode;
442
443        DEBUG_PRINT (TRACE_NAMES,
444            ("NsLookup: Null Pathname (Zero segments),  Flags=%x\n", Flags));
445    }
446
447    else
448    {
449        /*
450         * Valid name pointer (Internal name format)
451         *
452         * Check for prefixes.  As represented in the AML stream, a
453         * Pathname consists of an optional scope prefix followed by
454         * a segment part.
455         *
456         * If present, the scope prefix is either a RootPrefix (in
457         * which case the name is fully qualified), or zero or more
458         * ParentPrefixes (in which case the name's scope is relative
459         * to the current scope).
460         *
461         * The segment part consists of either:
462         *  - A single 4-byte name segment, or
463         *  - A DualNamePrefix followed by two 4-byte name segments, or
464         *  - A MultiNamePrefixOp, followed by a byte indicating the
465         *    number of segments and the segments themselves.
466         */
467
468        if (*Pathname == AML_ROOT_PREFIX)
469        {
470            /* Pathname is fully qualified, look in root name table */
471
472            CurrentNode = AcpiGbl_RootNode;
473
474            /* point to segment part */
475
476            Pathname++;
477
478            DEBUG_PRINT (TRACE_NAMES,
479                ("NsLookup: Searching from root [%p]\n",
480                CurrentNode));
481
482            /* Direct reference to root, "\" */
483
484            if (!(*Pathname))
485            {
486                ThisNode = AcpiGbl_RootNode;
487                goto CheckForNewScopeAndExit;
488            }
489        }
490
491        else
492        {
493            /* Pathname is relative to current scope, start there */
494
495            CurrentNode = PrefixNode;
496
497            DEBUG_PRINT (TRACE_NAMES,
498                ("NsLookup: Searching relative to pfx scope [%p]\n",
499                PrefixNode));
500
501            /*
502             * Handle up-prefix (carat).  More than one prefix
503             * is supported
504             */
505
506            while (*Pathname == AML_PARENT_PREFIX)
507            {
508                /* Point to segment part or next ParentPrefix */
509
510                Pathname++;
511
512                /*  Backup to the parent's scope  */
513
514                ThisNode = AcpiNsGetParentObject (CurrentNode);
515                if (!ThisNode)
516                {
517                    /* Current scope has no parent scope */
518
519                    REPORT_ERROR (("Too many parent prefixes (^) - reached root\n"));
520                    return_ACPI_STATUS (AE_NOT_FOUND);
521                }
522
523                CurrentNode = ThisNode;
524            }
525        }
526
527
528        /*
529         * Examine the name prefix opcode, if any,
530         * to determine the number of segments
531         */
532
533        if (*Pathname == AML_DUAL_NAME_PREFIX)
534        {
535            NumSegments = 2;
536
537            /* point to first segment */
538
539            Pathname++;
540
541            DEBUG_PRINT (TRACE_NAMES,
542                ("NsLookup: Dual Pathname (2 segments, Flags=%X)\n", Flags));
543        }
544
545        else if (*Pathname == AML_MULTI_NAME_PREFIX_OP)
546        {
547            NumSegments = (UINT32)* (UINT8 *) ++Pathname;
548
549            /* point to first segment */
550
551            Pathname++;
552
553            DEBUG_PRINT (TRACE_NAMES,
554                ("NsLookup: Multi Pathname (%d Segments, Flags=%X) \n",
555                NumSegments, Flags));
556        }
557
558        else
559        {
560            /*
561             * No Dual or Multi prefix, hence there is only one
562             * segment and Pathname is already pointing to it.
563             */
564            NumSegments = 1;
565
566            DEBUG_PRINT (TRACE_NAMES,
567                ("NsLookup: Simple Pathname (1 segment, Flags=%X)\n", Flags));
568        }
569
570#ifdef ACPI_DEBUG
571
572        /* TBD: [Restructure] Make this a procedure */
573
574        /* Debug only: print the entire name that we are about to lookup */
575
576        DEBUG_PRINT (TRACE_NAMES, ("NsLookup: ["));
577
578        for (i = 0; i < NumSegments; i++)
579        {
580            DEBUG_PRINT_RAW (TRACE_NAMES, ("%4.4s/", &Pathname[i * 4]));
581        }
582        DEBUG_PRINT_RAW (TRACE_NAMES, ("]\n"));
583#endif
584    }
585
586
587    /*
588     * Search namespace for each segment of the name.
589     * Loop through and verify/add each name segment.
590     */
591
592
593    while (NumSegments-- && CurrentNode)
594    {
595        /*
596         * Search for the current name segment under the current
597         * named object.  The Type is significant only at the last (topmost)
598         * level.  (We don't care about the types along the path, only
599         * the type of the final target object.)
600         */
601        ThisSearchType = ACPI_TYPE_ANY;
602        if (!NumSegments)
603        {
604            ThisSearchType = Type;
605        }
606
607        /* Pluck and ACPI name from the front of the pathname */
608
609        MOVE_UNALIGNED32_TO_32 (&SimpleName, Pathname);
610
611        /* Try to find the ACPI name */
612
613        Status = AcpiNsSearchAndEnter (SimpleName, WalkState,
614                                        CurrentNode, InterpreterMode,
615                                        ThisSearchType, Flags,
616                                        &ThisNode);
617
618        if (ACPI_FAILURE (Status))
619        {
620            if (Status == AE_NOT_FOUND)
621            {
622                /* Name not found in ACPI namespace  */
623
624                DEBUG_PRINT (TRACE_NAMES,
625                    ("NsLookup: Name [%4.4s] not found in scope %X\n",
626                    &SimpleName, CurrentNode));
627            }
628
629            return_ACPI_STATUS (Status);
630        }
631
632
633        /*
634         * If 1) This is the last segment (NumSegments == 0)
635         *    2) and looking for a specific type
636         *       (Not checking for TYPE_ANY)
637         *    3) Which is not an alias
638         *    4) which is not a local type (TYPE_DEF_ANY)
639         *    5) which is not a local type (TYPE_SCOPE)
640         *    6) which is not a local type (TYPE_INDEX_FIELD_DEFN)
641         *    7) and type of object is known (not TYPE_ANY)
642         *    8) and object does not match request
643         *
644         * Then we have a type mismatch.  Just warn and ignore it.
645         */
646        if ((NumSegments        == 0)                               &&
647            (TypeToCheckFor     != ACPI_TYPE_ANY)                   &&
648            (TypeToCheckFor     != INTERNAL_TYPE_ALIAS)             &&
649            (TypeToCheckFor     != INTERNAL_TYPE_DEF_ANY)           &&
650            (TypeToCheckFor     != INTERNAL_TYPE_SCOPE)             &&
651            (TypeToCheckFor     != INTERNAL_TYPE_INDEX_FIELD_DEFN)  &&
652            (ThisNode->Type     != ACPI_TYPE_ANY)                   &&
653            (ThisNode->Type     != TypeToCheckFor))
654        {
655            /* Complain about a type mismatch */
656
657            REPORT_WARNING (
658                ("NsLookup: %4.4s, type 0x%X, checking for type 0x%X\n",
659                &SimpleName, ThisNode->Type, TypeToCheckFor));
660        }
661
662        /*
663         * If this is the last name segment and we are not looking for a
664         * specific type, but the type of found object is known, use that type
665         * to see if it opens a scope.
666         */
667
668        if ((0 == NumSegments) && (ACPI_TYPE_ANY == Type))
669        {
670            Type = ThisNode->Type;
671        }
672
673        if ((NumSegments || AcpiNsOpensScope (Type)) &&
674            (ThisNode->Child == NULL))
675        {
676            /*
677             * More segments or the type implies enclosed scope,
678             * and the next scope has not been allocated.
679             */
680
681            DEBUG_PRINT (ACPI_INFO,
682                ("NsLookup: Load mode=%d  ThisNode=%x\n",
683                InterpreterMode, ThisNode));
684        }
685
686        CurrentNode = ThisNode;
687
688        /* point to next name segment */
689
690        Pathname += ACPI_NAME_SIZE;
691    }
692
693
694    /*
695     * Always check if we need to open a new scope
696     */
697
698CheckForNewScopeAndExit:
699
700    if (!(Flags & NS_DONT_OPEN_SCOPE) && (WalkState))
701    {
702        /*
703         * If entry is a type which opens a scope,
704         * push the new scope on the scope stack.
705         */
706
707        if (AcpiNsOpensScope (TypeToCheckFor))
708        {
709            /*  8-12-98 ASL Grammar Update supports null NamePath   */
710
711            if (NullNamePath)
712            {
713                /* TBD: [Investigate] - is this the correct thing to do? */
714
715                ScopeToPush = NULL;
716            }
717            else
718            {
719                ScopeToPush = ThisNode;
720            }
721
722            Status = AcpiDsScopeStackPush (ScopeToPush, Type,
723                                            WalkState);
724            if (ACPI_FAILURE (Status))
725            {
726                return_ACPI_STATUS (Status);
727            }
728
729            DEBUG_PRINT (ACPI_INFO,
730                ("NsLookup: Set global scope to %p\n", ScopeToPush));
731        }
732    }
733
734    *ReturnNode = ThisNode;
735    return_ACPI_STATUS (AE_OK);
736}
737
738