summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/console/post.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/console/post.c b/src/console/post.c
index b17a819d97..0719e5e7df 100644
--- a/src/console/post.c
+++ b/src/console/post.c
@@ -81,7 +81,7 @@ void cmos_post_log(void)
default:
printk(BIOS_WARNING, "POST: Unexpected post code "
"in previous boot: 0x%02x\n", code);
-#if CONFIG(ELOG)
+#if CONFIG(ELOG) && (ENV_RAMSTAGE || CONFIG(ELOG_PRERAM))
elog_add_event_word(ELOG_TYPE_LAST_POST_CODE, code);
#if CONFIG(CMOS_POST_EXTRA)
if (extra)