summaryrefslogtreecommitdiff
path: root/arch/arm/mach-bcm283x/bcm2711_acpi.c
diff options
context:
space:
mode:
authorHeinrich Schuchardt <heinrich.schuchardt@canonical.com>2025-03-22 00:21:20 +0100
committerTom Rini <trini@konsulko.com>2025-04-08 15:22:56 -0600
commitfecc50b0517d362b4db173b08a769f7b975d8255 (patch)
treee839be9055dfd981e6b7139eaf00caafe10c7275 /arch/arm/mach-bcm283x/bcm2711_acpi.c
parent5eca1696d25f61ad58582820f8477360c81b8b7b (diff)
arm: simplify updating ACPI table header checksum
Use acpi_update_checksum() to update table header. Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> Reviewed-by: Matthias Brugger <mbrugger@suse.com>
Diffstat (limited to 'arch/arm/mach-bcm283x/bcm2711_acpi.c')
-rw-r--r--arch/arm/mach-bcm283x/bcm2711_acpi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/mach-bcm283x/bcm2711_acpi.c b/arch/arm/mach-bcm283x/bcm2711_acpi.c
index 79b283353cf..58f8ee232b9 100644
--- a/arch/arm/mach-bcm283x/bcm2711_acpi.c
+++ b/arch/arm/mach-bcm283x/bcm2711_acpi.c
@@ -81,7 +81,7 @@ static int acpi_write_pptt(struct acpi_ctx *ctx, const struct acpi_writer *entry
}
header->length = ctx->current - ctx->tab_start;
- header->checksum = table_compute_checksum(header, header->length);
+ acpi_update_checksum(header);
acpi_inc(ctx, header->length);
acpi_add_table(ctx, header);
@@ -116,7 +116,7 @@ static int rpi_write_gtdt(struct acpi_ctx *ctx, const struct acpi_writer *entry)
gtdt->el2_flags = GTDT_FLAG_INT_ACTIVE_LOW;
gtdt->cnt_read_base = 0xffffffffffffffff;
- header->checksum = table_compute_checksum(header, header->length);
+ acpi_update_checksum(header);
acpi_add_table(ctx, gtdt);