From 49d7e99fd9875ef3545682f03728539bdce651e3 Mon Sep 17 00:00:00 2001 From: Jean Delvare Date: Mon, 15 Apr 2013 09:14:06 +0000 Subject: [PATCH] DDR3: Fix --side-by-side when some modules lack manufacturer information that others have. git-svn-id: http://lm-sensors.org/svn/i2c-tools/trunk@6143 7894878c-1315-0410-8ee3-d5d059ff63e0 --- eeprom/decode-dimms | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/eeprom/decode-dimms b/eeprom/decode-dimms index a891be9..45971aa 100755 --- a/eeprom/decode-dimms +++ b/eeprom/decode-dimms @@ -1691,26 +1691,23 @@ sub decode_ddr3_mfg_data($) printl("Module Manufacturer", manufacturer_ddr3($bytes->[117], $bytes->[118])); - if (spd_written(@{$bytes}[148..149])) { - printl("DRAM Manufacturer", - manufacturer_ddr3($bytes->[148], $bytes->[149])); - } + printl_cond(spd_written(@{$bytes}[148..149]), + "DRAM Manufacturer", + manufacturer_ddr3($bytes->[148], $bytes->[149])); printl_mfg_location_code($bytes->[119]); - if (spd_written(@{$bytes}[120..121])) { - printl("Manufacturing Date", - manufacture_date($bytes->[120], $bytes->[121])); - } + printl_cond(spd_written(@{$bytes}[120..121]), + "Manufacturing Date", + manufacture_date($bytes->[120], $bytes->[121])); printl_mfg_assembly_serial(@{$bytes}[122..125]); printl("Part Number", part_number(@{$bytes}[128..145])); - if (spd_written(@{$bytes}[146..147])) { - printl("Revision Code", - sprintf("0x%02X%02X", $bytes->[146], $bytes->[147])); - } + printl_cond(spd_written(@{$bytes}[146..147]), + "Revision Code", + sprintf("0x%02X%02X", $bytes->[146], $bytes->[147])); } # Parameter: EEPROM bytes 0-127 (using 64-98)