From 612249dc8b2d61087588be0878f02f27ecc352c3 Mon Sep 17 00:00:00 2001 From: Angel Pons Date: Mon, 19 Apr 2021 14:59:23 +0200 Subject: mb/asus/am1i-a: Use read_int_option() Drop "error" (BIOS_DEBUG) messages as well. Change-Id: I61954f8f893c144bbeba1530a486b389bd855ec6 Signed-off-by: Angel Pons Reviewed-on: https://review.coreboot.org/c/coreboot/+/52510 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Rudolph --- src/mainboard/asus/am1i-a/BiosCallOuts.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/src/mainboard/asus/am1i-a/BiosCallOuts.c b/src/mainboard/asus/am1i-a/BiosCallOuts.c index bdaf7a730f..e20f4f4cf7 100644 --- a/src/mainboard/asus/am1i-a/BiosCallOuts.c +++ b/src/mainboard/asus/am1i-a/BiosCallOuts.c @@ -87,12 +87,7 @@ void board_FCH_InitReset(struct sysinfo *cb_NA, FCH_RESET_DATA_BLOCK *FchParams_ FchParams_reset->Mode = 6; /* Read SATA speed setting from CMOS */ - enum cb_err ret; - ret = get_option(&FchParams_reset->SataSetMaxGen2, "sata_speed"); - if (ret != CB_SUCCESS) { - FchParams_reset->SataSetMaxGen2 = 0; - printk(BIOS_DEBUG, "ERROR: cannot read CMOS setting, falling back to default. Error code: %x\n", (int)ret); - } + FchParams_reset->SataSetMaxGen2 = get_int_option("sata_speed", 0); printk(BIOS_DEBUG, "Force SATA 3Gbps mode = %x\n", FchParams_reset->SataSetMaxGen2); } @@ -107,12 +102,7 @@ void board_FCH_InitEnv(struct sysinfo *cb_NA, FCH_DATA_BLOCK *FchParams_env) FchParams_env->Hwm.HwmFchtsiAutoPoll = FALSE;/* 1 enable, 0 disable TSI Auto Polling */ /* Read SATA controller mode from CMOS */ - enum cb_err ret; - ret = get_option(&FchParams_env->Sata.SataClass, "sata_mode"); - if (ret != CB_SUCCESS) { - FchParams_env->Sata.SataClass = 0; - printk(BIOS_DEBUG, "ERROR: cannot read CMOS setting, falling back to default. Error code: %x\n", (int)ret); - } + FchParams_env->Sata.SataClass = get_int_option("sata_mode", 0); switch ((SATA_CLASS)FchParams_env->Sata.SataClass) { case SataLegacyIde: -- cgit v1.2.3