[coreboot-gerrit] Change in coreboot[master]: mb/lenovo/x1_carbon_gen1: add support for hynix memory

Alexander Couzens (Code Review) gerrit at coreboot.org
Wed Aug 1 20:46:34 CEST 2018


Alexander Couzens has uploaded this change for review. ( https://review.coreboot.org/27781


Change subject: mb/lenovo/x1_carbon_gen1: add support for hynix memory
......................................................................

mb/lenovo/x1_carbon_gen1: add support for hynix memory

All different memory configuration should be supported by now.
Thanks to Igor Lee.

Change-Id: Ib93c0e3cbdc29cbf6cff26292df4fbbb8208082f
Signed-off-by: Alexander Couzens <lynxis at fe80.eu>
Tested-by: Igor Lee <gerun at gmail.com>
---
M src/mainboard/lenovo/x1_carbon_gen1/romstage.c
M src/mainboard/lenovo/x1_carbon_gen1/spd/Makefile.inc
A src/mainboard/lenovo/x1_carbon_gen1/spd/hynix.hex
3 files changed, 20 insertions(+), 6 deletions(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/81/27781/1

diff --git a/src/mainboard/lenovo/x1_carbon_gen1/romstage.c b/src/mainboard/lenovo/x1_carbon_gen1/romstage.c
index 029d867..87fca34 100644
--- a/src/mainboard/lenovo/x1_carbon_gen1/romstage.c
+++ b/src/mainboard/lenovo/x1_carbon_gen1/romstage.c
@@ -98,7 +98,7 @@
 
 	/* 4gb model = 0, 8gb model = 1 */
 	/* int extended_memory_version = get_gpio(44); */
-	/* TODO: how do they differ? Guess only one slot is connected */
+	/* TODO: how do they differ? 4GB with hynix has to slot populated */
 
 	/*
 	 * GPIO45 GPIO25
@@ -108,10 +108,8 @@
 	 * 1      1       reserved
 	 */
 
-	/* We only support elpida and samsung.
-           Because the spd data is missing. */
-	if (spd_index != 0 && spd_index != 2)
-		die("Unsupported Memory. Please add your SPD dump to coreboot.");
+	if (spd_index == 3)
+		die("Unsupported Memory. (detected 'reserved' memory configuration).");
 
 	memory = get_spd_data(spd_index);
 	memcpy(&spd[0], memory, 256);
diff --git a/src/mainboard/lenovo/x1_carbon_gen1/spd/Makefile.inc b/src/mainboard/lenovo/x1_carbon_gen1/spd/Makefile.inc
index 0c90826..f5c233a 100644
--- a/src/mainboard/lenovo/x1_carbon_gen1/spd/Makefile.inc
+++ b/src/mainboard/lenovo/x1_carbon_gen1/spd/Makefile.inc
@@ -16,7 +16,7 @@
 SPD_BIN = $(obj)/spd.bin
 
 SPD_SOURCES  = elpida.hex    # 0b0000 Single Channel 2GB
-SPD_SOURCES  += samsung.hex  # 0b0001 placeholder
+SPD_SOURCES  += hynix.hex    # 0b0001 2GiB
 SPD_SOURCES  += samsung.hex  # 0b0010 4GiB
 SPD_DEPS := $(foreach f, $(SPD_SOURCES), src/mainboard/$(MAINBOARDDIR)/spd/$(f))
 
diff --git a/src/mainboard/lenovo/x1_carbon_gen1/spd/hynix.hex b/src/mainboard/lenovo/x1_carbon_gen1/spd/hynix.hex
new file mode 100644
index 0000000..111745c
--- /dev/null
+++ b/src/mainboard/lenovo/x1_carbon_gen1/spd/hynix.hex
@@ -0,0 +1,16 @@
+92 11 0b 03 04 00 00 02 03 52 01 08 0c 00 20 00
+6c 78 6c 3c 6c 11 20 81 28 08 3c 3c 01 68 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 65 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 ae ea
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

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

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib93c0e3cbdc29cbf6cff26292df4fbbb8208082f
Gerrit-Change-Number: 27781
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Couzens <lynxis at fe80.eu>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20180801/e291bff7/attachment-0001.html>


More information about the coreboot-gerrit mailing list