Changeset 5087

Show
Ignore:
Timestamp:
01/04/08 17:08:03 (11 months ago)
Author:
khali
Message:

Don't print anything by default if the checksum fails. There are many more
EEPROMs in modern computers than just SPD EEPROMs, and there's no reason
to include them in the output of decode-dimms.pl.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • i2c-tools/trunk/CHANGES

    r5073 r5087  
    55  decode-dimms: Fix DDR2 SDRAM module speed decoding 
    66                Update manufacturer IDs. 
     7                Don't print anything by default if checksum fails 
    78  decode-vaio: Private data might not be readable by non-root users 
    89               Print the asset tag 
  • i2c-tools/trunk/eeprom/decode-dimms.pl

    r5017 r5087  
    11121112        if (($use_sysfs && /^\d+-\d+$/) 
    11131113         || (!$use_sysfs && /^eeprom-/)) { 
     1114                my @bytes = readspd64(0, $dimm_list[$i]); 
     1115                my $dimm_checksum = 0; 
     1116                $dimm_checksum += $bytes[$_] foreach (0 .. 62); 
     1117                $dimm_checksum &= 0xff; 
     1118 
     1119                next unless $bytes[63] == $dimm_checksum || $opt_igncheck; 
     1120                $dimm_count++; 
     1121 
    11141122                print "<b><u>" if $opt_html; 
    11151123                printl2 "\n\nDecoding EEPROM", ($use_sysfs ? 
     
    11271135                prints "SPD EEPROM Information"; 
    11281136 
    1129                 my @bytes = readspd64(0, $dimm_list[$i]); 
    1130                 my $dimm_checksum = 0; 
    1131                 $dimm_checksum += $bytes[$_] foreach (0 .. 62); 
    1132                 $dimm_checksum &= 0xff; 
    1133  
    11341137                my $l = "EEPROM Checksum of bytes 0-62"; 
    11351138                printl $l, ($bytes[63] == $dimm_checksum ? 
     
    11381141                                $bytes[63], $dimm_checksum)); 
    11391142 
    1140                 unless ($bytes[63] == $dimm_checksum or $opt_igncheck) { 
    1141                         print "</table>\n" if $opt_html; 
    1142                         next; 
    1143                 } 
    1144                  
    1145                 $dimm_count++; 
    11461143                # Simple heuristic to detect Rambus 
    11471144                my $is_rambus = $bytes[0] < 4;