[coreboot-gerrit] Patch set updated for coreboot: x86: make bootblock size for C_ENVIRONMENT_BOOTBLOCK configurable

Aaron Durbin (adurbin@chromium.org) gerrit at coreboot.org
Fri Feb 12 19:08:04 CET 2016


Aaron Durbin (adurbin at chromium.org) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/13691

-gerrit

commit eed52ac0adb485630c391045950cfe8971fca5c1
Author: Aaron Durbin <adurbin at chromium.org>
Date:   Thu Feb 11 14:36:19 2016 -0600

    x86: make bootblock size for C_ENVIRONMENT_BOOTBLOCK configurable
    
    Certain platforms may need to limit their bootblock size to within
    a given size because specific constraints. Allow the size to be
    provided by the mainboard or chipset by way of the arch Kconfig
    being processed after those.
    
    Change-Id: I46cc6315918cde575070fa2d3e2514f28008f575
    Signed-off-by: Aaron Durbin <adurbin at chromium.org>
---
 src/arch/x86/Kconfig      | 5 +++++
 src/arch/x86/memlayout.ld | 3 ++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/arch/x86/Kconfig b/src/arch/x86/Kconfig
index 889e811..204a9be 100644
--- a/src/arch/x86/Kconfig
+++ b/src/arch/x86/Kconfig
@@ -146,3 +146,8 @@ config ID_SECTION_OFFSET
 config COMPILE_IN_DSDT
 	bool "compile in DSDT and use that over DSDT in CBFS"
 	default n
+
+# 64KiB default bootblock size when employing C_ENVIRONMENT_BOOTBLOCK.
+config C_ENV_BOOTBLOCK_SIZE
+	hex
+	default 0x10000
diff --git a/src/arch/x86/memlayout.ld b/src/arch/x86/memlayout.ld
index 1ecae8c..fb67575 100644
--- a/src/arch/x86/memlayout.ld
+++ b/src/arch/x86/memlayout.ld
@@ -45,7 +45,8 @@ SECTIONS
 #elif ENV_BOOTBLOCK
 	/* This is for C_ENVIRONMENT_BOOTBLOCK. arch/x86/bootblock.ld contains
 	 * the logic for the romcc linking. */
-	BOOTBLOCK(0xffff0000, 64K)
+	BOOTBLOCK(0xffffffff - CONFIG_C_ENV_BOOTBLOCK_SIZE + 1,
+			CONFIG_C_ENV_BOOTBLOCK_SIZE)
 
 	/* Pull in the cache-as-ram rules. */
 	#include "car.ld"



More information about the coreboot-gerrit mailing list