From 9523e3b7905a3c20214b8af4bacd50abe178eded Mon Sep 17 00:00:00 2001 From: Elyes Haouas Date: Tue, 8 Nov 2022 14:38:41 +0100 Subject: arch/x86: Use 'enum cb_err' Change-Id: I38e4b8c6adfaaa45377b2fbe0644285d21841cd1 Signed-off-by: Elyes Haouas Reviewed-on: https://review.coreboot.org/c/coreboot/+/68369 Tested-by: build bot (Jenkins) Reviewed-by: Martin L Roth Reviewed-by: Felix Singer --- src/arch/x86/postcar_loader.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/arch/x86/postcar_loader.c') diff --git a/src/arch/x86/postcar_loader.c b/src/arch/x86/postcar_loader.c index be4a235bf1..a8a77e0227 100644 --- a/src/arch/x86/postcar_loader.c +++ b/src/arch/x86/postcar_loader.c @@ -20,7 +20,7 @@ static size_t var_mtrr_ctx_size(void) return sizeof(struct var_mtrr_context) + mtrr_count * 2 * sizeof(msr_t); } -static int postcar_frame_init(struct postcar_frame *pcf) +static enum cb_err postcar_frame_init(struct postcar_frame *pcf) { memset(pcf, 0, sizeof(*pcf)); @@ -29,13 +29,13 @@ static int postcar_frame_init(struct postcar_frame *pcf) ctx = cbmem_add(CBMEM_ID_ROMSTAGE_RAM_STACK, var_mtrr_ctx_size()); if (ctx == NULL) { printk(BIOS_ERR, "Couldn't add var_mtrr_ctx setup in cbmem.\n"); - return -1; + return CB_ERR; } pcf->mtrr = ctx; var_mtrr_context_init(pcf->mtrr); - return 0; + return CB_SUCCESS; } void postcar_frame_add_mtrr(struct postcar_frame *pcf, -- cgit v1.2.3