diff options
author | Jianjun Wang <jianjun.wang@mediatek.com> | 2022-04-08 16:57:28 +0800 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2022-04-14 22:27:50 +0000 |
commit | b2537bdad552443aba58bda7c42af1f039a58c94 (patch) | |
tree | aac90b0d8e31c8986dd9be460199af7503a08263 /payloads/libpayload/libc | |
parent | 6f023ece0860a7988ef7f1f15bea5b54df0161ff (diff) |
coreboot_tables: Replace 'struct lb_uint64' with lb_uint64_t
Replace 'struct lb_uint64' with 'typedef __aligned(4) uint64_t
lb_uint64_t', and remove unpack_lb64/pack_lb64 functions since it's no
longer needed.
Also replace 'struct cbuint64' with 'cb_uint64_t' and remove
'cb_unpack64' in libpayload for compatible with lb_uint64_t.
Signed-off-by: Jianjun Wang <jianjun.wang@mediatek.com>
Change-Id: If6b037e4403a8000625f4a5fb8d20311fe76200a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/63494
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'payloads/libpayload/libc')
-rw-r--r-- | payloads/libpayload/libc/coreboot.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/payloads/libpayload/libc/coreboot.c b/payloads/libpayload/libc/coreboot.c index 2474df96fa..cdd6a437b6 100644 --- a/payloads/libpayload/libc/coreboot.c +++ b/payloads/libpayload/libc/coreboot.c @@ -61,12 +61,8 @@ static void cb_parse_memory(void *ptr, struct sysinfo_t *info) continue; #endif - info->memrange[info->n_memranges].base = - cb_unpack64(range->start); - - info->memrange[info->n_memranges].size = - cb_unpack64(range->size); - + info->memrange[info->n_memranges].base = range->start; + info->memrange[info->n_memranges].size = range->size; info->memrange[info->n_memranges].type = range->type; info->n_memranges++; @@ -121,7 +117,7 @@ static void cb_parse_mac_addresses(unsigned char *ptr, static void cb_parse_board_config(unsigned char *ptr, struct sysinfo_t *info) { struct cb_board_config *const config = (struct cb_board_config *)ptr; - info->fw_config = cb_unpack64(config->fw_config); + info->fw_config = config->fw_config; info->board_id = config->board_id; info->ram_code = config->ram_code; info->sku_id = config->sku_id; @@ -271,7 +267,7 @@ static void cb_parse_cbmem_entry(void *ptr, struct sysinfo_t *info) static void cb_parse_rsdp(void *ptr, struct sysinfo_t *info) { const struct cb_acpi_rsdp *cb_acpi_rsdp = ptr; - info->acpi_rsdp = cb_unpack64(cb_acpi_rsdp->rsdp_pointer); + info->acpi_rsdp = cb_acpi_rsdp->rsdp_pointer; } int cb_parse_header(void *addr, int len, struct sysinfo_t *info) |