summaryrefslogtreecommitdiff
path: root/src/drivers/intel/fsp2_0
diff options
context:
space:
mode:
authorDavid Hendricks <david.hendricks@gmail.com>2023-01-29 17:56:23 -0800
committerElyes Haouas <ehaouas@noos.fr>2023-01-31 04:04:49 +0000
commit69b81949462c5a7d16067ab086fb7d9826bb963f (patch)
tree6735e077a41bfe84ecf60eb058856729b22d357a /src/drivers/intel/fsp2_0
parent9aebc19182971deb5dbade7b5e0c5e1f62ac718b (diff)
drivers/intel/fsp2_0: Simplify check for CONFIG_SAVE_MRC_AFTER_FSPS
This uses a simpler form of #if to check if CONFIG_SAVE_MRC_AFTER_FSPS is enabled, referencing the Kconfig variable only once and defaulting to the original behavior if not. Change-Id: I4711c1474d9a3a5c685dd31561619c568fab075c Signed-off-by: David Hendricks <david.hendricks@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/72587 Reviewed-by: Elyes Haouas <ehaouas@noos.fr> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/drivers/intel/fsp2_0')
-rw-r--r--src/drivers/intel/fsp2_0/save_mrc_data.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/drivers/intel/fsp2_0/save_mrc_data.c b/src/drivers/intel/fsp2_0/save_mrc_data.c
index 8742c24bc5..8550b68cb7 100644
--- a/src/drivers/intel/fsp2_0/save_mrc_data.c
+++ b/src/drivers/intel/fsp2_0/save_mrc_data.c
@@ -43,8 +43,8 @@ static void save_mrc_data(void *unused)
* Should be done before ramstage_cse_fw_sync() to avoid traning memory twice on
* a cold boot after a full firmware update.
*/
-#if !CONFIG(SAVE_MRC_AFTER_FSPS)
-BOOT_STATE_INIT_ENTRY(BS_PRE_DEVICE, BS_ON_ENTRY, save_mrc_data, NULL);
-#elif CONFIG(SAVE_MRC_AFTER_FSPS)
+#if CONFIG(SAVE_MRC_AFTER_FSPS)
BOOT_STATE_INIT_ENTRY(BS_DEV_INIT_CHIPS, BS_ON_EXIT, save_mrc_data, NULL);
+#else
+BOOT_STATE_INIT_ENTRY(BS_PRE_DEVICE, BS_ON_ENTRY, save_mrc_data, NULL);
#endif