]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
x86: acpi: Remove the unnecessary checksum calculation of DSDT
authorBin Meng <bmeng.cn@gmail.com>
Wed, 11 May 2016 14:45:04 +0000 (07:45 -0700)
committerBin Meng <bmeng.cn@gmail.com>
Mon, 23 May 2016 07:18:00 +0000 (15:18 +0800)
The generated AmlCode[] from IASL already has the calculated DSDT
table checksum in place. No need for us to calculate it again.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
arch/x86/lib/acpi_table.c

index 855d4a05aef1f649b3cc52c63501c4f066c23b7e..1c57094f0fe01e595217be4803e710245b97abb0 100644 (file)
@@ -382,12 +382,6 @@ u32 write_acpi_tables(u32 start)
                        (char *)&AmlCode + sizeof(struct acpi_table_header),
                        dsdt->length - sizeof(struct acpi_table_header));
                current += dsdt->length - sizeof(struct acpi_table_header);
-
-               /* (Re)calculate length and checksum */
-               dsdt->length = current - (u32)dsdt;
-               dsdt->checksum = 0;
-               dsdt->checksum = table_compute_checksum((void *)dsdt,
-                               dsdt->length);
        }
        current = ALIGN(current, 16);