summaryrefslogtreecommitdiffstats
path: root/sys/contrib/dev/acpica/components/executer/exconvrt.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/contrib/dev/acpica/components/executer/exconvrt.c')
-rw-r--r--sys/contrib/dev/acpica/components/executer/exconvrt.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/sys/contrib/dev/acpica/components/executer/exconvrt.c b/sys/contrib/dev/acpica/components/executer/exconvrt.c
index 50ccf26..871e1e3 100644
--- a/sys/contrib/dev/acpica/components/executer/exconvrt.c
+++ b/sys/contrib/dev/acpica/components/executer/exconvrt.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2015, Intel Corp.
+ * Copyright (C) 2000 - 2016, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -137,7 +137,8 @@ AcpiExConvertToInteger (
* of ACPI 3.0) is that the ToInteger() operator allows both decimal
* and hexadecimal strings (hex prefixed with "0x").
*/
- Status = AcpiUtStrtoul64 ((char *) Pointer, Flags, &Result);
+ Status = AcpiUtStrtoul64 ((char *) Pointer, Flags,
+ AcpiGbl_IntegerByteWidth, &Result);
if (ACPI_FAILURE (Status))
{
return_ACPI_STATUS (Status);
@@ -251,9 +252,7 @@ AcpiExConvertToBuffer (
/* Copy the integer to the buffer, LSB first */
NewBuf = ReturnDesc->Buffer.Pointer;
- ACPI_MEMCPY (NewBuf,
- &ObjDesc->Integer.Value,
- AcpiGbl_IntegerByteWidth);
+ memcpy (NewBuf, &ObjDesc->Integer.Value, AcpiGbl_IntegerByteWidth);
break;
case ACPI_TYPE_STRING:
@@ -266,8 +265,8 @@ AcpiExConvertToBuffer (
* ASL/AML code that depends on the null being transferred to the new
* buffer.
*/
- ReturnDesc = AcpiUtCreateBufferObject (
- (ACPI_SIZE) ObjDesc->String.Length + 1);
+ ReturnDesc = AcpiUtCreateBufferObject ((ACPI_SIZE)
+ ObjDesc->String.Length + 1);
if (!ReturnDesc)
{
return_ACPI_STATUS (AE_NO_MEMORY);
@@ -276,7 +275,7 @@ AcpiExConvertToBuffer (
/* Copy the string to the buffer */
NewBuf = ReturnDesc->Buffer.Pointer;
- ACPI_STRNCPY ((char *) NewBuf, (char *) ObjDesc->String.Pointer,
+ strncpy ((char *) NewBuf, (char *) ObjDesc->String.Pointer,
ObjDesc->String.Length);
break;
@@ -390,7 +389,8 @@ AcpiExConvertToAscii (
{
/* Get one hex digit, most significant digits first */
- String[k] = (UINT8) AcpiUtHexToAsciiChar (Integer, ACPI_MUL_4 (j));
+ String[k] = (UINT8)
+ AcpiUtHexToAsciiChar (Integer, ACPI_MUL_4 (j));
k++;
}
break;
@@ -491,8 +491,8 @@ AcpiExConvertToString (
/* Convert integer to string */
- StringLength = AcpiExConvertToAscii (ObjDesc->Integer.Value, Base,
- NewBuf, AcpiGbl_IntegerByteWidth);
+ StringLength = AcpiExConvertToAscii (
+ ObjDesc->Integer.Value, Base, NewBuf, AcpiGbl_IntegerByteWidth);
/* Null terminate at the correct place */
@@ -581,8 +581,7 @@ AcpiExConvertToString (
for (i = 0; i < ObjDesc->Buffer.Length; i++)
{
NewBuf += AcpiExConvertToAscii (
- (UINT64) ObjDesc->Buffer.Pointer[i], Base,
- NewBuf, 1);
+ (UINT64) ObjDesc->Buffer.Pointer[i], Base, NewBuf, 1);
*NewBuf++ = Separator; /* each separated by a comma or space */
}
@@ -673,6 +672,7 @@ AcpiExConvertToTargetType (
break;
case ARGI_TARGETREF:
+ case ARGI_STORE_TARGET:
switch (DestinationType)
{
@@ -684,8 +684,7 @@ AcpiExConvertToTargetType (
* These types require an Integer operand. We can convert
* a Buffer or a String to an Integer if necessary.
*/
- Status = AcpiExConvertToInteger (SourceDesc, ResultDesc,
- 16);
+ Status = AcpiExConvertToInteger (SourceDesc, ResultDesc, 16);
break;
case ACPI_TYPE_STRING:
@@ -694,7 +693,7 @@ AcpiExConvertToTargetType (
* Integer or Buffer if necessary
*/
Status = AcpiExConvertToString (SourceDesc, ResultDesc,
- ACPI_IMPLICIT_CONVERT_HEX);
+ ACPI_IMPLICIT_CONVERT_HEX);
break;
case ACPI_TYPE_BUFFER:
@@ -707,7 +706,8 @@ AcpiExConvertToTargetType (
default:
- ACPI_ERROR ((AE_INFO, "Bad destination type during conversion: 0x%X",
+ ACPI_ERROR ((AE_INFO,
+ "Bad destination type during conversion: 0x%X",
DestinationType));
Status = AE_AML_INTERNAL;
break;
OpenPOWER on IntegriCloud