Felix Held has submitted this change. ( https://review.coreboot.org/c/coreboot/+/56312 )
Change subject: soc/amd/common/block/cpu/mca/mca: factor out mca_skip_check ......................................................................
soc/amd/common/block/cpu/mca/mca: factor out mca_skip_check
This will allow moving mca_check_all_banks to mca_common.c.
Change-Id: I58e100c1447907bab984a2fdff6c6e0181910c23 Signed-off-by: Felix Held felix-coreboot@felixheld.de Reviewed-on: https://review.coreboot.org/c/coreboot/+/56312 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Martin Roth martinroth@google.com --- M src/soc/amd/common/block/cpu/mca/mca.c 1 file changed, 6 insertions(+), 1 deletion(-)
Approvals: build bot (Jenkins): Verified Martin Roth: Looks good to me, approved
diff --git a/src/soc/amd/common/block/cpu/mca/mca.c b/src/soc/amd/common/block/cpu/mca/mca.c index b5fd6a2..1c3a30c 100644 --- a/src/soc/amd/common/block/cpu/mca/mca.c +++ b/src/soc/amd/common/block/cpu/mca/mca.c @@ -9,6 +9,11 @@ #include <types.h> #include "mca_common_defs.h"
+static bool mca_skip_check(void) +{ + return !is_warm_reset(); +} + static void mca_print_error(unsigned int bank) { msr_t msr; @@ -36,7 +41,7 @@ if (!mca_has_expected_bank_count()) printk(BIOS_WARNING, "CPU has an unexpected number of MCA banks!\n");
- if (!is_warm_reset()) + if (mca_skip_check()) return;
for (unsigned int i = 0 ; i < num_banks ; i++) {