PERFORCE change 66228 for review

Peter Wemm peter at FreeBSD.org
Wed Dec 1 15:40:00 PST 2004


http://perforce.freebsd.org/chv.cgi?CH=66228

Change 66228 by peter at peter_overcee on 2004/12/01 23:39:01

	IFC @66227 (oops, this was the one I really wanted)

Affected files ...

.. //depot/projects/hammer/Makefile.inc1#80 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/acconfig.h#13 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/acenv.h#8 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/acpiosxf.h#7 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/acpixf.h#7 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/acutils.h#11 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/exfldio.c#12 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/exsystem.c#8 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/psparse.c#9 integrate
.. //depot/projects/hammer/sys/contrib/dev/acpica/tbget.c#9 integrate

Differences ...

==== //depot/projects/hammer/Makefile.inc1#80 (text+ko) ====

@@ -1,5 +1,5 @@
 #
-# $FreeBSD: src/Makefile.inc1,v 1.458 2004/11/23 09:09:47 ru Exp $
+# $FreeBSD: src/Makefile.inc1,v 1.459 2004/12/01 23:23:14 peter Exp $
 #
 # Make command line options:
 #	-DNO_DYNAMICROOT do not link /bin and /sbin dynamically
@@ -419,6 +419,10 @@
 	cd ${.CURDIR}/gnu/usr.bin/cc/include; \
 	    ${LIB32MAKE} DESTDIR=${LIB32TMP} ${_t}
 .endfor
+.for _dir in usr.sbin/pcvt/keycap usr.bin/lex/lib
+	cd ${.CURDIR}/${_dir}; \
+	    ${LIB32MAKE} DESTDIR=${LIB32TMP} obj
+.endfor
 .for _dir in lib/libncurses lib/libmagic
 	cd ${.CURDIR}/${_dir}; \
 	    MAKEOBJDIRPREFIX=${OBJTREE}/lib32 ${MAKE} build-tools

==== //depot/projects/hammer/sys/contrib/dev/acpica/acconfig.h#13 (text+ko) ====

@@ -1,7 +1,7 @@
 /******************************************************************************
  *
  * Name: acconfig.h - Global configuration constants
- *       $Revision: 158 $
+ *       $Revision: 169 $
  *
  *****************************************************************************/
 
@@ -137,12 +137,12 @@
 
 /* Version string */
 
-#define ACPI_CA_VERSION                 0x20040527
+#define ACPI_CA_VERSION                 0x20041119
 
 /*
  * OS name, used for the _OS object.  The _OS object is essentially obsolete,
  * but there is a large base of ASL/AML code in existing machines that check
- * for the string below.  The use of this string usually guarantees that 
+ * for the string below.  The use of this string usually guarantees that
  * the ASL will execute down the most tested code path.  Also, there is some
  * code that will not execute the _OSI method unless _OS matches the string
  * below.  Therefore, change this string at your own risk.

==== //depot/projects/hammer/sys/contrib/dev/acpica/acenv.h#8 (text+ko) ====

@@ -1,7 +1,7 @@
 /******************************************************************************
  *
  * Name: acenv.h - Generation environment specific items
- *       $Revision: 107 $
+ *       $Revision: 109 $
  *
  *****************************************************************************/
 
@@ -225,7 +225,7 @@
 #define COMPILER_DEPENDENT_INT64   long long
 #define COMPILER_DEPENDENT_UINT64  unsigned long long
 
-/* 
+/*
  * This macro is used to tag functions as "printf-like" because
  * some compilers can catch printf format string problems. MSVC
  * doesn't, so this is proprocessed away.
@@ -305,6 +305,7 @@
 #define ACPI_STRCAT(d,s)        (void) strcat((d), (s))
 #define ACPI_STRNCAT(d,s,n)     strncat((d), (s), (ACPI_SIZE)(n))
 #define ACPI_STRTOUL(d,s,n)     strtoul((d), (s), (ACPI_SIZE)(n))
+#define ACPI_MEMCMP(s1,s2,n)    memcmp((s1), (s2), (ACPI_SIZE)(n))
 #define ACPI_MEMCPY(d,s,n)      (void) memcpy((d), (s), (ACPI_SIZE)(n))
 #define ACPI_MEMSET(d,s,n)      (void) memset((d), (s), (ACPI_SIZE)(n))
 
@@ -368,6 +369,7 @@
 #define ACPI_STRCAT(d,s)        (void) AcpiUtStrcat  ((d), (s))
 #define ACPI_STRNCAT(d,s,n)     AcpiUtStrncat ((d), (s), (ACPI_SIZE)(n))
 #define ACPI_STRTOUL(d,s,n)     AcpiUtStrtoul ((d), (s), (ACPI_SIZE)(n))
+#define ACPI_MEMCMP(s1,s2,n)    AcpiUtMemcmp((s1), (s2), (ACPI_SIZE)(n))
 #define ACPI_MEMCPY(d,s,n)      (void) AcpiUtMemcpy  ((d), (s), (ACPI_SIZE)(n))
 #define ACPI_MEMSET(d,v,n)      (void) AcpiUtMemset  ((d), (v), (ACPI_SIZE)(n))
 #define ACPI_TOUPPER            AcpiUtToUpper

==== //depot/projects/hammer/sys/contrib/dev/acpica/acpiosxf.h#7 (text+ko) ====

@@ -263,13 +263,13 @@
 ACPI_STATUS
 AcpiOsInstallInterruptHandler (
     UINT32                  InterruptNumber,
-    OSD_HANDLER             ServiceRoutine,
+    ACPI_OSD_HANDLER        ServiceRoutine,
     void                    *Context);
 
 ACPI_STATUS
 AcpiOsRemoveInterruptHandler (
     UINT32                  InterruptNumber,
-    OSD_HANDLER             ServiceRoutine);
+    ACPI_OSD_HANDLER        ServiceRoutine);
 
 
 /*
@@ -283,13 +283,16 @@
 ACPI_STATUS
 AcpiOsQueueForExecution (
     UINT32                  Priority,
-    OSD_EXECUTION_CALLBACK  Function,
+    ACPI_OSD_EXEC_CALLBACK  Function,
+    void                    *Context);
+
+void
+AcpiOsWaitEventsComplete (
     void                    *Context);
 
 void
 AcpiOsSleep (
-    UINT32                  Seconds,
-    UINT32                  Milliseconds);
+    ACPI_INTEGER            Milliseconds);
 
 void
 AcpiOsStall (
@@ -332,29 +335,32 @@
 
 /*
  * Platform and hardware-independent PCI configuration space access
+ * Note: Can't use "Register" as a parameter, changed to "Reg" --
+ * certain compilers complain.
  */
 
 ACPI_STATUS
 AcpiOsReadPciConfiguration (
     ACPI_PCI_ID             *PciId,
-    UINT32                  Register,
+    UINT32                  Reg,
     void                    *Value,
     UINT32                  Width);
 
 ACPI_STATUS
 AcpiOsWritePciConfiguration (
     ACPI_PCI_ID             *PciId,
-    UINT32                  Register,
+    UINT32                  Reg,
     ACPI_INTEGER            Value,
     UINT32                  Width);
 
 /*
  * Interim function needed for PCI IRQ routing
  */
+
 void
 AcpiOsDerivePciId(
-    ACPI_HANDLE             rhandle,
-    ACPI_HANDLE             chandle,
+    ACPI_HANDLE             Rhandle,
+    ACPI_HANDLE             Chandle,
     ACPI_PCI_ID             **PciId);
 
 /*
@@ -371,7 +377,7 @@
     void                    *Pointer,
     ACPI_SIZE               Length);
 
-UINT32
+UINT64
 AcpiOsGetTimer (
     void);
 

==== //depot/projects/hammer/sys/contrib/dev/acpica/acpixf.h#7 (text+ko) ====

@@ -372,6 +372,15 @@
     void                    *Context);
 
 ACPI_STATUS
+AcpiInstallExceptionHandler (
+    ACPI_EXCEPTION_HANDLER  Handler);
+
+
+/*
+ * Event interfaces
+ */
+
+ACPI_STATUS
 AcpiAcquireGlobalLock (
     UINT16                  Timeout,
     UINT32                  *Handle);

==== //depot/projects/hammer/sys/contrib/dev/acpica/acutils.h#11 (text+ko) ====

@@ -1,7 +1,7 @@
 /******************************************************************************
  *
  * Name: acutils.h -- prototypes for the common (subsystem-wide) procedures
- *       $Revision: 161 $
+ *       $Revision: 164 $
  *
  *****************************************************************************/
 
@@ -252,6 +252,12 @@
     ACPI_SIZE               Count);
 
 int
+AcpiUtMemcmp (
+    const char              *Buffer1,
+    const char              *Buffer2,
+    ACPI_SIZE               Count);
+
+int
 AcpiUtStrncmp (
     const char              *String1,
     const char              *String2,
@@ -651,6 +657,10 @@
 AcpiUtCreateBufferObject (
     ACPI_SIZE               BufferSize);
 
+ACPI_OPERAND_OBJECT *
+AcpiUtCreateStringObject (
+    ACPI_SIZE               StringSize);
+
 
 /*
  * UtRefCnt - Object reference count management
@@ -764,14 +774,14 @@
 
 ACPI_STATUS
 AcpiUtDivide (
-    ACPI_INTEGER            *InDividend,
-    ACPI_INTEGER            *InDivisor,
+    ACPI_INTEGER            InDividend,
+    ACPI_INTEGER            InDivisor,
     ACPI_INTEGER            *OutQuotient,
     ACPI_INTEGER            *OutRemainder);
 
 ACPI_STATUS
 AcpiUtShortDivide (
-    ACPI_INTEGER            *InDividend,
+    ACPI_INTEGER            InDividend,
     UINT32                  Divisor,
     ACPI_INTEGER            *OutQuotient,
     UINT32                  *OutRemainder);
@@ -790,6 +800,10 @@
     UINT32                  Base,
     ACPI_INTEGER            *RetInteger);
 
+/* Values for Base above (16=Hex, 10=Decimal) */
+
+#define ACPI_ANY_BASE        0
+
 char *
 AcpiUtStrupr (
     char                    *SrcString);

==== //depot/projects/hammer/sys/contrib/dev/acpica/exfldio.c#12 (text+ko) ====

@@ -1,7 +1,7 @@
 /******************************************************************************
  *
  * Module Name: exfldio - Aml Field I/O
- *              $Revision: 106 $
+ *              $Revision: 111 $
  *
  *****************************************************************************/
 
@@ -212,6 +212,23 @@
                                     + FieldDatumByteOffset
                                     + ObjDesc->CommonField.AccessByteWidth))
     {
+        if (AcpiGbl_EnableInterpreterSlack)
+        {
+            /*
+             * Slack mode only:  We will go ahead and allow access to this
+             * field if it is within the region length rounded up to the next
+             * access width boundary.
+             */
+            if (ACPI_ROUND_UP (RgnDesc->Region.Length,
+                                ObjDesc->CommonField.AccessByteWidth) >=
+                (ObjDesc->CommonField.BaseByteOffset +
+                 (ACPI_NATIVE_UINT) ObjDesc->CommonField.AccessByteWidth +
+                 FieldDatumByteOffset))
+            {
+                return_ACPI_STATUS (AE_OK);
+            }
+        }
+
         if (RgnDesc->Region.Length < ObjDesc->CommonField.AccessByteWidth)
         {
             /*
@@ -237,25 +254,6 @@
             FieldDatumByteOffset, ObjDesc->CommonField.AccessByteWidth,
             AcpiUtGetNodeName (RgnDesc->Region.Node), RgnDesc->Region.Length));
 
-#ifndef ACPICA_PEDANTIC
-        {
-            /*
-             * Allow access to the field if it is within the region size
-             * rounded up to a multiple of the access byte width.  This
-             * overcomes "off-by-one" programming errors in the AML often
-             * found in Toshiba laptops.  These errors were allowed by
-             * the Microsoft ASL compiler.
-             */
-            UINT32 rounded_length = ACPI_ROUND_UP(RgnDesc->Region.Length,
-                ObjDesc->CommonField.AccessByteWidth);
-
-            if (rounded_length >= (ObjDesc->CommonField.BaseByteOffset +
-                                   FieldDatumByteOffset +
-                                   ObjDesc->CommonField.AccessByteWidth)) {
-                return_ACPI_STATUS (AE_OK);
-            }
-        }
-#endif
         return_ACPI_STATUS (AE_AML_REGION_LIMIT);
     }
 
@@ -910,7 +908,7 @@
         return_ACPI_STATUS (AE_BUFFER_OVERFLOW);
     }
 
-    /* 
+    /*
      * Create "actual" field byte count (minimum number of bytes that
      * must be read), then convert to datum count (minimum number
      * of datum-sized units that must be read)

==== //depot/projects/hammer/sys/contrib/dev/acpica/exsystem.c#8 (text+ko) ====

@@ -2,7 +2,7 @@
 /******************************************************************************
  *
  * Module Name: exsystem - Interface to OS services
- *              $Revision: 80 $
+ *              $Revision: 81 $
  *
  *****************************************************************************/
 
@@ -246,7 +246,7 @@
 
 ACPI_STATUS
 AcpiExSystemDoSuspend (
-    UINT32                  HowLong)
+    ACPI_INTEGER            HowLong)
 {
     ACPI_STATUS             Status;
 
@@ -258,8 +258,7 @@
 
     AcpiExExitInterpreter ();
 
-    AcpiOsSleep ((UINT16) (HowLong / (UINT32) 1000),
-                 (UINT16) (HowLong % (UINT32) 1000));
+    AcpiOsSleep (HowLong);
 
     /* And now we must get the interpreter again */
 

==== //depot/projects/hammer/sys/contrib/dev/acpica/psparse.c#9 (text+ko) ====

@@ -1,7 +1,7 @@
 /******************************************************************************
  *
  * Module Name: psparse - Parser top level AML parse routines
- *              $Revision: 144 $
+ *              $Revision: 146 $
  *
  *****************************************************************************/
 
@@ -240,141 +240,143 @@
 
     /* Delete this op and the subtree below it if asked to */
 
-    if (((WalkState->ParseFlags & ACPI_PARSE_TREE_MASK) == ACPI_PARSE_DELETE_TREE) &&
-        (WalkState->OpInfo->Class != AML_CLASS_ARGUMENT))
+    if (((WalkState->ParseFlags & ACPI_PARSE_TREE_MASK) != ACPI_PARSE_DELETE_TREE) ||
+         (WalkState->OpInfo->Class == AML_CLASS_ARGUMENT))
+    {
+        return_VOID;
+    }
+
+    /* Make sure that we only delete this subtree */
+
+    if (Op->Common.Parent)
     {
-        /* Make sure that we only delete this subtree */
+        /*
+         * Check if we need to replace the operator and its subtree
+         * with a return value op (placeholder op)
+         */
+        ParentInfo  = AcpiPsGetOpcodeInfo (Op->Common.Parent->Common.AmlOpcode);
 
-        if (Op->Common.Parent)
+        switch (ParentInfo->Class)
         {
+        case AML_CLASS_CONTROL:
+            break;
+
+        case AML_CLASS_CREATE:
+
             /*
-             * Check if we need to replace the operator and its subtree
-             * with a return value op (placeholder op)
+             * These opcodes contain TermArg operands.  The current
+             * op must be replaced by a placeholder return op
              */
-            ParentInfo  = AcpiPsGetOpcodeInfo (Op->Common.Parent->Common.AmlOpcode);
-
-            switch (ParentInfo->Class)
+            ReplacementOp = AcpiPsAllocOp (AML_INT_RETURN_VALUE_OP);
+            if (!ReplacementOp)
             {
-            case AML_CLASS_CONTROL:
-                break;
+                goto Cleanup;
+            }
+            break;
 
-            case AML_CLASS_CREATE:
+        case AML_CLASS_NAMED_OBJECT:
 
-                /*
-                 * These opcodes contain TermArg operands.  The current
-                 * op must be replaced by a placeholder return op
-                 */
+            /*
+             * These opcodes contain TermArg operands.  The current
+             * op must be replaced by a placeholder return op
+             */
+            if ((Op->Common.Parent->Common.AmlOpcode == AML_REGION_OP)       ||
+                (Op->Common.Parent->Common.AmlOpcode == AML_DATA_REGION_OP)  ||
+                (Op->Common.Parent->Common.AmlOpcode == AML_BUFFER_OP)       ||
+                (Op->Common.Parent->Common.AmlOpcode == AML_PACKAGE_OP)      ||
+                (Op->Common.Parent->Common.AmlOpcode == AML_VAR_PACKAGE_OP))
+            {
                 ReplacementOp = AcpiPsAllocOp (AML_INT_RETURN_VALUE_OP);
                 if (!ReplacementOp)
                 {
-                    return_VOID;
+                    goto Cleanup;
                 }
-                break;
+            }
 
-            case AML_CLASS_NAMED_OBJECT:
+            if ((Op->Common.Parent->Common.AmlOpcode == AML_NAME_OP) &&
+                (WalkState->DescendingCallback != AcpiDsExecBeginOp))
 
-                /*
-                 * These opcodes contain TermArg operands.  The current
-                 * op must be replaced by a placeholder return op
-                 */
-                if ((Op->Common.Parent->Common.AmlOpcode == AML_REGION_OP)       ||
-                    (Op->Common.Parent->Common.AmlOpcode == AML_DATA_REGION_OP)  ||
-                    (Op->Common.Parent->Common.AmlOpcode == AML_BUFFER_OP)       ||
-                    (Op->Common.Parent->Common.AmlOpcode == AML_PACKAGE_OP)      ||
-                    (Op->Common.Parent->Common.AmlOpcode == AML_VAR_PACKAGE_OP))
+            {
+                if ((Op->Common.AmlOpcode == AML_BUFFER_OP) ||
+                    (Op->Common.AmlOpcode == AML_PACKAGE_OP) ||
+                    (Op->Common.AmlOpcode == AML_VAR_PACKAGE_OP))
                 {
-                    ReplacementOp = AcpiPsAllocOp (AML_INT_RETURN_VALUE_OP);
+                    ReplacementOp = AcpiPsAllocOp (Op->Common.AmlOpcode);
                     if (!ReplacementOp)
                     {
-                        return_VOID;
+                        goto Cleanup;
                     }
+
+                    ReplacementOp->Named.Data = Op->Named.Data;
+                    ReplacementOp->Named.Length = Op->Named.Length;
                 }
+            }
+            break;
 
-                if ((Op->Common.Parent->Common.AmlOpcode == AML_NAME_OP) &&
-                    (WalkState->DescendingCallback != AcpiDsExecBeginOp))
+        default:
+            ReplacementOp = AcpiPsAllocOp (AML_INT_RETURN_VALUE_OP);
+            if (!ReplacementOp)
+            {
+                goto Cleanup;
+            }
+        }
 
-                {
-                    if ((Op->Common.AmlOpcode == AML_BUFFER_OP) ||
-                        (Op->Common.AmlOpcode == AML_PACKAGE_OP) ||
-                        (Op->Common.AmlOpcode == AML_VAR_PACKAGE_OP))
-                    {
-                        ReplacementOp = AcpiPsAllocOp (Op->Common.AmlOpcode);
-                        if (!ReplacementOp)
-                        {
-                            return_VOID;
-                        }
+        /* We must unlink this op from the parent tree */
 
-                        ReplacementOp->Named.Data = Op->Named.Data;
-                        ReplacementOp->Named.Length = Op->Named.Length;
-                    }
-                }
-                break;
+        Prev = Op->Common.Parent->Common.Value.Arg;
+        if (Prev == Op)
+        {
+            /* This op is the first in the list */
 
-            default:
-                ReplacementOp = AcpiPsAllocOp (AML_INT_RETURN_VALUE_OP);
-                if (!ReplacementOp)
-                {
-                    return_VOID;
-                }
+            if (ReplacementOp)
+            {
+                ReplacementOp->Common.Parent        = Op->Common.Parent;
+                ReplacementOp->Common.Value.Arg     = NULL;
+                ReplacementOp->Common.Node          = Op->Common.Node;
+                Op->Common.Parent->Common.Value.Arg = ReplacementOp;
+                ReplacementOp->Common.Next          = Op->Common.Next;
+            }
+            else
+            {
+                Op->Common.Parent->Common.Value.Arg = Op->Common.Next;
             }
+        }
+
+        /* Search the parent list */
 
-            /* We must unlink this op from the parent tree */
+        else while (Prev)
+        {
+            /* Traverse all siblings in the parent's argument list */
 
-            Prev = Op->Common.Parent->Common.Value.Arg;
-            if (Prev == Op)
+            Next = Prev->Common.Next;
+            if (Next == Op)
             {
-                /* This op is the first in the list */
-
                 if (ReplacementOp)
                 {
-                    ReplacementOp->Common.Parent        = Op->Common.Parent;
-                    ReplacementOp->Common.Value.Arg     = NULL;
-                    ReplacementOp->Common.Node          = Op->Common.Node;
-                    Op->Common.Parent->Common.Value.Arg = ReplacementOp;
-                    ReplacementOp->Common.Next          = Op->Common.Next;
+                    ReplacementOp->Common.Parent    = Op->Common.Parent;
+                    ReplacementOp->Common.Value.Arg = NULL;
+                    ReplacementOp->Common.Node      = Op->Common.Node;
+                    Prev->Common.Next               = ReplacementOp;
+                    ReplacementOp->Common.Next      = Op->Common.Next;
+                    Next = NULL;
                 }
                 else
                 {
-                    Op->Common.Parent->Common.Value.Arg    = Op->Common.Next;
+                    Prev->Common.Next = Op->Common.Next;
+                    Next = NULL;
                 }
             }
 
-            /* Search the parent list */
-
-            else while (Prev)
-            {
-                /* Traverse all siblings in the parent's argument list */
-
-                Next = Prev->Common.Next;
-                if (Next == Op)
-                {
-                    if (ReplacementOp)
-                    {
-                        ReplacementOp->Common.Parent    = Op->Common.Parent;
-                        ReplacementOp->Common.Value.Arg = NULL;
-                        ReplacementOp->Common.Node      = Op->Common.Node;
-                        Prev->Common.Next               = ReplacementOp;
-                        ReplacementOp->Common.Next      = Op->Common.Next;
-                        Next = NULL;
-                    }
-                    else
-                    {
-                        Prev->Common.Next = Op->Common.Next;
-                        Next = NULL;
-                    }
-                }
-
-                Prev = Next;
-            }
+            Prev = Next;
         }
+    }
 
-        /* Now we can actually delete the subtree rooted at op */
 
-        AcpiPsDeleteParseTree (Op);
+Cleanup:
 
-        return_VOID;
-    }
+    /* Now we can actually delete the subtree rooted at op */
 
+    AcpiPsDeleteParseTree (Op);
     return_VOID;
 }
 
@@ -661,7 +663,8 @@
                     PreOp = AcpiPsAllocOp (WalkState->Opcode);
                     if (!PreOp)
                     {
-                        return_ACPI_STATUS (AE_NO_MEMORY);
+                        Status = AE_NO_MEMORY;
+                        goto CloseThisOp;
                     }
                 }
 
@@ -690,7 +693,8 @@
 
                 if (!GET_CURRENT_ARG_TYPE (WalkState->ArgTypes))
                 {
-                    return_ACPI_STATUS (AE_AML_NO_OPERAND);
+                    Status = AE_AML_NO_OPERAND;
+                    goto CloseThisOp;
                 }
 
                 /* We know that this arg is a name, move to next arg */
@@ -757,7 +761,8 @@
                 Op = AcpiPsAllocOp (WalkState->Opcode);
                 if (!Op)
                 {
-                    return_ACPI_STATUS (AE_NO_MEMORY);
+                    Status = AE_NO_MEMORY;
+                    goto CloseThisOp;
                 }
 
                 if (WalkState->OpInfo->Flags & AML_CREATE)
@@ -936,7 +941,7 @@
                         WalkState->ArgTypes, WalkState->ArgCount);
             if (ACPI_FAILURE (Status))
             {
-                return_ACPI_STATUS (Status);
+                goto CloseThisOp;
             }
             Op = NULL;
             continue;
@@ -1227,10 +1232,6 @@
     ACPI_THREAD_STATE       *Thread;
     ACPI_THREAD_STATE       *PrevWalkList = AcpiGbl_CurrentWalkList;
     ACPI_WALK_STATE         *PreviousWalkState;
-#ifndef ACPICA_PEDANTIC
-    ACPI_OPERAND_OBJECT     **CallerReturnDesc = WalkState->CallerReturnDesc;
-    ACPI_OPERAND_OBJECT     *EffectiveReturnDesc = NULL;
-#endif
 
 
     ACPI_FUNCTION_TRACE ("PsParseAml");
@@ -1297,7 +1298,7 @@
         {
             Status = AE_OK;
         }
-        else if (Status != AE_OK)
+        else if ((Status != AE_OK) && (WalkState->MethodDesc))
         {
             ACPI_REPORT_METHOD_ERROR ("Method execution failed",
                 WalkState->MethodNode, NULL, Status);
@@ -1331,17 +1332,6 @@
 
         WalkState = AcpiDsPopWalkState (Thread);
 
-#ifndef ACPICA_PEDANTIC
-        /* Save the last effective return value */
-
-        if (CallerReturnDesc && WalkState->ReturnDesc)
-        {
-            AcpiUtRemoveReference (EffectiveReturnDesc);
-            EffectiveReturnDesc = WalkState->ReturnDesc;
-            AcpiUtAddReference (EffectiveReturnDesc);
-        }
-#endif
-
         /* Reset the current scope to the beginning of scope stack */
 
         AcpiDsScopeStackClear (WalkState);
@@ -1404,19 +1394,6 @@
          */
         else if (PreviousWalkState->CallerReturnDesc)
         {
-#ifndef ACPICA_PEDANTIC
-            /*
-             * Some AML code expects a return value without a ReturnOp.
-             * Return the saved effective return value instead.
-             */
-
-            if (PreviousWalkState->ReturnDesc == NULL && EffectiveReturnDesc != NULL)
-            {
-                PreviousWalkState->ReturnDesc = EffectiveReturnDesc;
-                AcpiUtAddReference (PreviousWalkState->ReturnDesc);
-            }
-#endif
-
             *(PreviousWalkState->CallerReturnDesc) = PreviousWalkState->ReturnDesc; /* NULL if no return value */
         }
         else if (PreviousWalkState->ReturnDesc)
@@ -1431,9 +1408,6 @@
 
     /* Normal exit */
 
-#ifndef ACPICA_PEDANTIC
-    AcpiUtRemoveReference (EffectiveReturnDesc);
-#endif
     AcpiExReleaseAllMutexes (Thread);
     AcpiUtDeleteGenericState (ACPI_CAST_PTR (ACPI_GENERIC_STATE, Thread));
     AcpiGbl_CurrentWalkList = PrevWalkList;

==== //depot/projects/hammer/sys/contrib/dev/acpica/tbget.c#9 (text+ko) ====

@@ -1,7 +1,7 @@
 /******************************************************************************
  *
  * Module Name: tbget - ACPI Table get* routines
- *              $Revision: 88 $
+ *              $Revision: 90 $
  *
  *****************************************************************************/
 
@@ -245,6 +245,9 @@
         return_ACPI_STATUS (AE_BAD_PARAMETER);
     }
 
+    ACPI_DEBUG_PRINT ((ACPI_DB_TABLES, "Table Signature: [%4.4s]\n",
+        ReturnHeader->Signature));
+
     return_ACPI_STATUS (AE_OK);
 }
 


More information about the p4-projects mailing list