2
0
mirror of https://opendev.org/x/pyghmi synced 2025-02-05 21:43:02 +00:00

Fix support for 3DS DIMM capacity

3DS dimms must have logical ranks by modifying ranks
with data from byte 6.

Change-Id: If1fe788302cac07998ca841851c645c8e4694b65
This commit is contained in:
Jarrod Johnson 2020-12-10 15:51:32 -05:00
parent d61f6d5e6e
commit a01cdc54b3

View File

@ -755,6 +755,8 @@ class SPD(object):
buswidth = ddr3_bus_width[spd[13] & 0b111]
sdramwidth = ddr3_dev_width[spd[12] & 0b111]
ranks = ddr3_ranks[(spd[12] & 0b111000) >> 3]
if spd[6] & 0b11 == 0b10:
ranks = ranks * (((spd[6] >> 4) & 0b111) + 1)
self.info['capacity_mb'] = sdramcap / 8 * buswidth / sdramwidth * ranks
self.info['manufacturer'] = decode_manufacturer(spd[320], spd[321])
self.info['manufacture_location'] = spd[322]