[PATCH 5/6] ddr_spd: provide common SPD type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Provide a common struct type for the different SPD EEPROM types. Can be
used to pass around SPD data without specifying the DDR type.

Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>
---
 include/ddr_spd.h | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/include/ddr_spd.h b/include/ddr_spd.h
index 95d0eb04b6..6e63d90e5e 100644
--- a/include/ddr_spd.h
+++ b/include/ddr_spd.h
@@ -499,6 +499,16 @@ struct ddr4_spd_eeprom {
 	uint8_t user[512-384];		/* 384~511 End User Programmable */
 };
 
+struct spd_eeprom {
+	union {
+		struct ddr1_spd_eeprom ddr1;
+		struct ddr2_spd_eeprom ddr2;
+		struct ddr3_spd_eeprom ddr3;
+		struct ddr4_spd_eeprom ddr4;
+		uint8_t data[512];
+	};
+};
+
 /*
  * Byte 2 Fundamental Memory Types.
  */
-- 
2.20.1


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux