[coreboot-gerrit] Patch set updated for coreboot: soc/intel/apollolake: Gather microcode revision

John Zhao (john.zhao@intel.com) gerrit at coreboot.org
Wed Aug 24 03:31:40 CEST 2016


John Zhao (john.zhao at intel.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/16311

-gerrit

commit 31dfbda0beefdadea6b6996a8345aadce82dd299
Author: John Zhao <john.zhao at intel.com>
Date:   Tue Aug 23 16:38:05 2016 -0700

    soc/intel/apollolake: Gather microcode revision
    
    Expose get_microcode_info in cpu initialization. Microcode
    revision is retrieved and stored into log file at verstage.
    
    BUG=chrome-os-partner:56544
    BRANCH=None
    TEST=Built coreboot image and validate log file
    
    Change-Id: I1e792e70f1318df64b4b85a319700013f3757952
    Signed-off-by: John Zhao <john.zhao at intel.com>
---
 src/soc/intel/apollolake/cpu.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/src/soc/intel/apollolake/cpu.c b/src/soc/intel/apollolake/cpu.c
index 4f74def..3e639a3 100644
--- a/src/soc/intel/apollolake/cpu.c
+++ b/src/soc/intel/apollolake/cpu.c
@@ -20,6 +20,7 @@
 #include <cpu/cpu.h>
 #include <cpu/x86/cache.h>
 #include <cpu/x86/mp.h>
+#include <cpu/intel/microcode.h>
 #include <cpu/x86/msr.h>
 #include <cpu/x86/mtrr.h>
 #include <device/device.h>
@@ -42,6 +43,8 @@ static const struct cpu_driver driver __cpu_driver = {
 	.id_table = cpu_table,
 };
 
+/* MP initialization support. */
+static const void *microcode_patch;
 
 /*
  * MP and SMM loading initialization.
@@ -88,6 +91,13 @@ static int get_cpu_count(void)
 	return num_virt_cores;
 }
 
+static void get_microcode_info(const void **microcode, int *parallel)
+{
+	microcode_patch = intel_microcode_find();
+	*microcode = microcode_patch;
+	*parallel = 1;
+}
+
 static void get_smm_info(uintptr_t *perm_smbase, size_t *perm_smsize,
 				size_t *smm_save_state_size)
 {
@@ -135,6 +145,7 @@ static const struct mp_ops mp_ops = {
 	.pre_mp_init = pre_mp_init,
 	.get_cpu_count = get_cpu_count,
 	.get_smm_info = get_smm_info,
+	.get_microcode_info = get_microcode_info,
 	.pre_mp_smm_init = southbridge_smm_clear_state,
 	.relocation_handler = relocation_handler,
 	.post_mp_init = southbridge_smm_enable_smi,



More information about the coreboot-gerrit mailing list