ACPICA: Update error message for field beyond buffer case
authorBob Moore <robert.moore@intel.com>
Mon, 5 Jun 2017 08:40:08 +0000 (16:40 +0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 12 Jun 2017 12:58:41 +0000 (14:58 +0200)
ACPICA commit 7a6b9c0b31cfb1606a6348404fee670b2d18743c

Improve/clarify the problem of a field definition beyond the limit
of the target buffer.

Link: https://github.com/acpica/acpica/commit/7a6b9c0b
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/acpica/dsopcode.c

index 9a8f8a992b3e3f9409a1f35d68b4a1f907ac313c..dfc3c25a083dde54383e8d3dadb2e63eb42095de 100644 (file)
@@ -227,13 +227,12 @@ acpi_ds_init_buffer_field(u16 aml_opcode,
 
        /* Entire field must fit within the current length of the buffer */
 
-       if ((bit_offset + bit_count) > (8 * (u32) buffer_desc->buffer.length)) {
+       if ((bit_offset + bit_count) > (8 * (u32)buffer_desc->buffer.length)) {
                ACPI_ERROR((AE_INFO,
-                           "Field [%4.4s] at %u exceeds Buffer [%4.4s] size %u (bits)",
-                           acpi_ut_get_node_name(result_desc),
-                           bit_offset + bit_count,
-                           acpi_ut_get_node_name(buffer_desc->buffer.node),
-                           8 * (u32) buffer_desc->buffer.length));
+                           "Field [%4.4s] at bit offset/length %u/%u "
+                           "exceeds size of target Buffer (%u bits)",
+                           acpi_ut_get_node_name(result_desc), bit_offset,
+                           bit_count, 8 * (u32)buffer_desc->buffer.length));
                status = AE_AML_BUFFER_LIMIT;
                goto cleanup;
        }