Print this page
update to acpica-unix2-20140114
acpica-unix2-20130823
PANKOVs restructure
*** 3,13 ****
* Module Name: utcopy - Internal to external object translation utilities
*
*****************************************************************************/
/*
! * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
--- 3,13 ----
* Module Name: utcopy - Internal to external object translation utilities
*
*****************************************************************************/
/*
! * Copyright (C) 2000 - 2014, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*** 170,180 ****
ACPI_MEMCPY ((void *) DataSpace,
(void *) InternalObject->String.Pointer,
(ACPI_SIZE) InternalObject->String.Length + 1);
break;
-
case ACPI_TYPE_BUFFER:
ExternalObject->Buffer.Pointer = DataSpace;
ExternalObject->Buffer.Length = InternalObject->Buffer.Length;
*BufferSpaceUsed = ACPI_ROUND_UP_TO_NATIVE_WORD (
--- 170,179 ----
*** 183,207 ****
ACPI_MEMCPY ((void *) DataSpace,
(void *) InternalObject->Buffer.Pointer,
InternalObject->Buffer.Length);
break;
-
case ACPI_TYPE_INTEGER:
ExternalObject->Integer.Value = InternalObject->Integer.Value;
break;
-
case ACPI_TYPE_LOCAL_REFERENCE:
/* This is an object reference. */
switch (InternalObject->Reference.Class)
{
case ACPI_REFCLASS_NAME:
-
/*
* For namepath, return the object handle ("reference")
* We are referring to the namespace node
*/
ExternalObject->Reference.Handle =
--- 182,203 ----
*** 216,226 ****
return_ACPI_STATUS (AE_TYPE);
}
break;
-
case ACPI_TYPE_PROCESSOR:
ExternalObject->Processor.ProcId =
InternalObject->Processor.ProcId;
ExternalObject->Processor.PblkAddress =
--- 212,221 ----
*** 227,247 ****
InternalObject->Processor.Address;
ExternalObject->Processor.PblkLength =
InternalObject->Processor.Length;
break;
-
case ACPI_TYPE_POWER:
ExternalObject->PowerResource.SystemLevel =
InternalObject->PowerResource.SystemLevel;
ExternalObject->PowerResource.ResourceOrder =
InternalObject->PowerResource.ResourceOrder;
break;
-
default:
/*
* There is no corresponding external object type
*/
ACPI_ERROR ((AE_INFO,
--- 222,240 ----
*** 289,299 ****
&((ACPI_OBJECT *)(State->Pkg.DestObject))->Package.Elements[ThisIndex];
switch (ObjectType)
{
case ACPI_COPY_TYPE_SIMPLE:
-
/*
* This is a simple or null object
*/
Status = AcpiUtCopyIsimpleToEsimple (SourceObject,
TargetObject, Info->FreeSpace, &ObjectSpace);
--- 282,291 ----
*** 301,313 ****
{
return (Status);
}
break;
-
case ACPI_COPY_TYPE_PACKAGE:
-
/*
* Build the package object
*/
TargetObject->Type = ACPI_TYPE_PACKAGE;
TargetObject->Package.Count = SourceObject->Package.Count;
--- 293,303 ----
*** 326,337 ****
ObjectSpace = ACPI_ROUND_UP_TO_NATIVE_WORD (
(ACPI_SIZE) TargetObject->Package.Count *
sizeof (ACPI_OBJECT));
break;
-
default:
return (AE_BAD_PARAMETER);
}
Info->FreeSpace += ObjectSpace;
Info->Length += ObjectSpace;
--- 316,327 ----
ObjectSpace = ACPI_ROUND_UP_TO_NATIVE_WORD (
(ACPI_SIZE) TargetObject->Package.Count *
sizeof (ACPI_OBJECT));
break;
default:
+
return (AE_BAD_PARAMETER);
}
Info->FreeSpace += ObjectSpace;
Info->Length += ObjectSpace;
*** 512,521 ****
--- 502,512 ----
*RetInternalObject = NULL;
return_ACPI_STATUS (AE_OK);
default:
+
/* All other types are not supported */
ACPI_ERROR ((AE_INFO,
"Unsupported object type, cannot convert to internal object: %s",
AcpiUtGetTypeName (ExternalObject->Type)));
*** 544,554 ****
ExternalObject->String.Length);
InternalObject->String.Length = ExternalObject->String.Length;
break;
-
case ACPI_TYPE_BUFFER:
InternalObject->Buffer.Pointer =
ACPI_ALLOCATE_ZEROED (ExternalObject->Buffer.Length);
if (!InternalObject->Buffer.Pointer)
--- 535,544 ----
*** 565,590 ****
/* Mark buffer data valid */
InternalObject->Buffer.Flags |= AOPOBJ_DATA_VALID;
break;
-
case ACPI_TYPE_INTEGER:
InternalObject->Integer.Value = ExternalObject->Integer.Value;
break;
case ACPI_TYPE_LOCAL_REFERENCE:
! /* TBD: should validate incoming handle */
! InternalObject->Reference.Class = ACPI_REFCLASS_NAME;
! InternalObject->Reference.Node = ExternalObject->Reference.Handle;
break;
default:
/* Other types can't get here */
break;
}
*RetInternalObject = InternalObject;
return_ACPI_STATUS (AE_OK);
--- 555,581 ----
/* Mark buffer data valid */
InternalObject->Buffer.Flags |= AOPOBJ_DATA_VALID;
break;
case ACPI_TYPE_INTEGER:
InternalObject->Integer.Value = ExternalObject->Integer.Value;
break;
case ACPI_TYPE_LOCAL_REFERENCE:
! /* An incoming reference is defined to be a namespace node */
! InternalObject->Reference.Class = ACPI_REFCLASS_REFOF;
! InternalObject->Reference.Object = ExternalObject->Reference.Handle;
break;
default:
+
/* Other types can't get here */
+
break;
}
*RetInternalObject = InternalObject;
return_ACPI_STATUS (AE_OK);
*** 853,863 ****
--- 844,856 ----
return (Status);
}
break;
default:
+
/* Nothing to do for other simple objects */
+
break;
}
return (AE_OK);
}
*** 927,939 ****
*ThisTargetPtr = NULL;
}
break;
-
case ACPI_COPY_TYPE_PACKAGE:
-
/*
* This object is a package - go down another nesting level
* Create and build the package object
*/
TargetObject = AcpiUtCreatePackageObject (SourceObject->Package.Count);
--- 920,930 ----
*** 951,962 ****
/* Store the object pointer in the parent package object */
*ThisTargetPtr = TargetObject;
break;
-
default:
return (AE_BAD_PARAMETER);
}
return (Status);
--- 942,953 ----
/* Store the object pointer in the parent package object */
*ThisTargetPtr = TargetObject;
break;
default:
+
return (AE_BAD_PARAMETER);
}
return (Status);
*** 1072,1078 ****
Status = AcpiUtCopySimpleObject (SourceDesc, *DestDesc);
}
return_ACPI_STATUS (Status);
}
-
-
--- 1063,1067 ----