[coreboot-gerrit] Change in coreboot[master]: stoneyridge: Enable IO CF9 in bootblock

Patrick Georgi (Code Review) gerrit at coreboot.org
Mon Jul 2 09:35:05 CEST 2018


Patrick Georgi has submitted this change and it was merged. ( https://review.coreboot.org/27267 )

Change subject: stoneyridge: Enable IO CF9 in bootblock
......................................................................

stoneyridge: Enable IO CF9 in bootblock

If IO CF9 is not enabled, hard_reset() won't do anything in bootblock or
verstage.

BUG=b:110817463
TEST=built on grunt and made sure that hard_reset() reboots.

Change-Id: I5f091077a17db3dfe5b8e8367163312db6828360
Signed-off-by: Raul E Rangel <rrangel at chromium.org>
Reviewed-on: https://review.coreboot.org/27267
Reviewed-by: Martin Roth <martinroth at google.com>
Tested-by: build bot (Jenkins) <no-reply at coreboot.org>
---
M src/soc/amd/stoneyridge/include/soc/southbridge.h
M src/soc/amd/stoneyridge/southbridge.c
2 files changed, 10 insertions(+), 0 deletions(-)

Approvals:
  build bot (Jenkins): Verified
  Martin Roth: Looks good to me, approved



diff --git a/src/soc/amd/stoneyridge/include/soc/southbridge.h b/src/soc/amd/stoneyridge/include/soc/southbridge.h
index 06ef898..9f8a7d2 100644
--- a/src/soc/amd/stoneyridge/include/soc/southbridge.h
+++ b/src/soc/amd/stoneyridge/include/soc/southbridge.h
@@ -32,6 +32,8 @@
 #define  PSP_MAILBOX_BAR_EN		0x10
 
 /* Power management registers:  0xfed80300 or index/data at IO 0xcd6/cd7 */
+#define PM_DECODE_EN			0x00
+#define   CF9_IO_EN			BIT(1)
 #define PM_ISA_CONTROL			0x04
 #define   MMIO_EN			BIT(1)
 #define PM_PCI_CTRL			0x08
diff --git a/src/soc/amd/stoneyridge/southbridge.c b/src/soc/amd/stoneyridge/southbridge.c
index c46bcb4..591a8f7 100644
--- a/src/soc/amd/stoneyridge/southbridge.c
+++ b/src/soc/amd/stoneyridge/southbridge.c
@@ -368,6 +368,13 @@
 	outb(byte, PM_DATA);
 }
 
+static void sb_enable_cf9_io(void)
+{
+	uint32_t reg = pm_read32(PM_DECODE_EN);
+
+	pm_write32(PM_DECODE_EN, reg | CF9_IO_EN);
+}
+
 void sb_clk_output_48Mhz(void)
 {
 	u32 ctrl;
@@ -542,6 +549,7 @@
 	sb_spibase();
 	sb_disable_4dw_burst(); /* Must be disabled on CZ(ST) */
 	sb_acpi_mmio_decode();
+	sb_enable_cf9_io();
 	enable_aoac_devices();
 }
 

-- 
To view, visit https://review.coreboot.org/27267
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I5f091077a17db3dfe5b8e8367163312db6828360
Gerrit-Change-Number: 27267
Gerrit-PatchSet: 3
Gerrit-Owner: Raul Rangel <rrangel at chromium.org>
Gerrit-Reviewer: Martin Roth <martinroth at google.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi at google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply at coreboot.org>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20180702/79994674/attachment.html>


More information about the coreboot-gerrit mailing list