summaryrefslogtreecommitdiffstats
path: root/drivers/acpi
diff options
context:
space:
mode:
authorBob Moore <robert.moore@intel.com>2012-10-31 03:28:19 +0100
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2012-11-15 00:31:29 +0100
commit47abd13ccfa140ad34620b343bf0e6eca15ed8e8 (patch)
tree245e4fafdf7a6be655e97524ae13d0e29696eb13 /drivers/acpi
parentACPICA: Add starting offset parameter to common dump buffer routine (diff)
downloadlinux-47abd13ccfa140ad34620b343bf0e6eca15ed8e8.tar.xz
linux-47abd13ccfa140ad34620b343bf0e6eca15ed8e8.zip
ACPICA: Fix externalize name to complete migration to ACPI_MOVE_NAME
Fix for name segment copy and validation. 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>
Diffstat (limited to 'drivers/acpi')
-rw-r--r--drivers/acpi/acpica/nsutils.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/acpi/acpica/nsutils.c b/drivers/acpi/acpica/nsutils.c
index 0d3d481ce58e..b5b4cb72a8a8 100644
--- a/drivers/acpi/acpica/nsutils.c
+++ b/drivers/acpi/acpica/nsutils.c
@@ -557,8 +557,11 @@ acpi_ns_externalize_name(u32 internal_name_length,
(*converted_name)[j++] = '.';
}
- ACPI_MOVE_NAME(*converted_name, internal_name);
- acpi_ut_repair_name(*converted_name);
+ /* Copy and validate the 4-char name segment */
+
+ ACPI_MOVE_NAME(&(*converted_name)[j],
+ &internal_name[names_index]);
+ acpi_ut_repair_name(&(*converted_name)[j]);
j += ACPI_NAME_SIZE;
names_index += ACPI_NAME_SIZE;