[PATCH i2c-tools v4 4/8] decode-dimms: Decode DDR5 common module information

Stephen Horvath <[email protected]> Thu, 23 Jul 2026 13:40:14 +0000
Newsgroups org.kernel.vger.linux-i2c
Message-ID <[email protected]>
Decode the extra manufacturer information that was mentioned in a
previous patch, but only the info that is common between all DDR5 memory
modules.

The physical size is now implemented too.

Signed-off-by: Stephen Horvath <[email protected]>
---
 eeprom/decode-dimms | 36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)

diff --git a/eeprom/decode-dimms b/eeprom/decode-dimms
index cd0e2fd..d4553f5 100755
--- a/eeprom/decode-dimms
+++ b/eeprom/decode-dimms
@@ -2402,6 +2402,42 @@ sub decode_ddr5_sdram($)
 
 	printl("Thermal Sensor",
 	       $bytes->[14] & 0x08 ? "Supported" : "No");
+
+# common module information
+	prints("Common Information");
+
+	my $spd_info_rev = $bytes->[192];
+	printl("SPD Module Info Revision", ($spd_info_rev >> 4) . "." . ($spd_info_rev & 0xf));
+
+	printl_cond($bytes->[196] & 0x80,
+		    "SPD Manufacturer",
+		    manufacturer_ddr3($bytes->[194], $bytes->[195]));
+	printl_cond($bytes->[200] & 0x80,
+		    "PMIC0 Manufacturer",
+		    manufacturer_ddr3($bytes->[198], $bytes->[199]));
+	printl_cond($bytes->[204] & 0x80,
+		    "PMIC1 Manufacturer",
+		    manufacturer_ddr3($bytes->[202], $bytes->[203]));
+	printl_cond($bytes->[208] & 0x80,
+		    "PMIC2 Manufacturer",
+		    manufacturer_ddr3($bytes->[206], $bytes->[207]));
+	printl_cond($bytes->[212] & 0xC0,
+		    "Thermal Sensors Manufacturer",
+		    manufacturer_ddr3($bytes->[210], $bytes->[211]));
+
+	prints("Physical Characteristics");
+
+	my $height = $bytes->[230] & 0x1f;
+	printl("Module Height",
+		$height == 0x00 ? "15 mm or less" :
+		$height == 0x1f ? "more than 45 mm" :
+		sprintf("%u mm", $height + 15));
+	printl("Module Thickness",
+		sprintf("%d mm front, %d mm back",
+			($bytes->[231] & 0x0f) + 1,
+			(($bytes->[231] >> 4) & 15) + 1));
+	printl("Module Reference Card",
+		ddr3_reference_card($bytes->[232], $bytes->[232]));
 }
 
 # Parameter: EEPROM bytes 0-127 (using 4-5)

-- 
2.53.0