From 5aea588f693c476f95bfac53cc9e51695c9f4979 Mon Sep 17 00:00:00 2001 From: Furquan Shaikh Date: Sat, 30 Jul 2016 18:10:05 -0700 Subject: [PATCH] drivers/fsp2_0: Increment boot count for non-S3 boot If ELOG_BOOT_COUNT is enabled and the boot is not s3 resume, then increment boot count. BUG=chrome-os-partner:55473 Change-Id: Ib3e77180bd640ec0424978e73034d7c99cdcba95 Signed-off-by: Furquan Shaikh Reviewed-on: https://review.coreboot.org/15948 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel Reviewed-by: Aaron Durbin Reviewed-by: Brandon Breitenstein --- src/drivers/intel/fsp2_0/memory_init.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/drivers/intel/fsp2_0/memory_init.c b/src/drivers/intel/fsp2_0/memory_init.c index ada1c28c1f..7aaed3c20f 100644 --- a/src/drivers/intel/fsp2_0/memory_init.c +++ b/src/drivers/intel/fsp2_0/memory_init.c @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -296,6 +297,9 @@ enum fsp_status fsp_memory_init(bool s3wake) struct memranges memmap; struct range_entry freeranges[2]; + if (IS_ENABLED(CONFIG_ELOG_BOOT_COUNT) && !s3wake) + boot_count_increment(); + if (cbfs_boot_locate(&file_desc, name, NULL)) { printk(BIOS_ERR, "Could not locate %s in CBFS\n", name); return FSP_NOT_FOUND;