summaryrefslogtreecommitdiff
path: root/src/arch/x86/acpi_device.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch/x86/acpi_device.c')
-rw-r--r--src/arch/x86/acpi_device.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/arch/x86/acpi_device.c b/src/arch/x86/acpi_device.c
index 2982999fe5..7cf292fbee 100644
--- a/src/arch/x86/acpi_device.c
+++ b/src/arch/x86/acpi_device.c
@@ -530,7 +530,12 @@ static void acpi_dp_write_array(const struct acpi_dp *array)
/* Package element count determined as it is populated */
pkg_count = acpigen_write_package(0);
- for (dp = array; dp; dp = dp->next) {
+ /*
+ * Only acpi_dp of type DP_TYPE_TABLE is allowed to be an array.
+ * DP_TYPE_TABLE does not have a value to be written. Thus, start
+ * the loop from next type in the array.
+ */
+ for (dp = array->next; dp; dp = dp->next) {
acpi_dp_write_value(dp);
(*pkg_count)++;
}