summaryrefslogtreecommitdiff
path: root/source/compiler/aslopcodes.c
diff options
context:
space:
mode:
Diffstat (limited to 'source/compiler/aslopcodes.c')
-rw-r--r--source/compiler/aslopcodes.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/source/compiler/aslopcodes.c b/source/compiler/aslopcodes.c
index 8445ca1d0..aecd37c8b 100644
--- a/source/compiler/aslopcodes.c
+++ b/source/compiler/aslopcodes.c
@@ -361,7 +361,7 @@ OpcSetOptimalIntegerSize (
Op->Asl.AmlOpcode = AML_DWORD_OP;
return (4);
}
- else
+ else /* 64-bit integer */
{
if (AcpiGbl_IntegerByteWidth == 4)
{
@@ -371,8 +371,12 @@ OpcSetOptimalIntegerSize (
if (!Gbl_IgnoreErrors)
{
/* Truncate the integer to 32-bit */
- Op->Asl.AmlOpcode = AML_DWORD_OP;
- return (4);
+
+ Op->Asl.Value.Integer &= ACPI_UINT32_MAX;
+
+ /* Now set the optimal integer size */
+
+ return (OpcSetOptimalIntegerSize (Op));
}
}