Attention is currently required from: Martin L Roth, Jakub Czapiga, Arthur Heymans, Patrick Rudolph, Elyes Haouas.
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/62181 )
Change subject: device/dram/ddr: Deduplicate enum spd_dimm_type_ddr{2,3,4} ......................................................................
Patch Set 8: Code-Review+1
(3 comments)
File src/device/dram/ddr3.c:
https://review.coreboot.org/c/coreboot/+/62181/comment/4f2914d0_6951521b PS7, Line 549: dimm->mod_type = SPD_UNDEFINED;
Given that `SPD_UNDEFINED == 0`, the whole `if` does the same as a simple […]
Done
File src/device/dram/ddr4.c:
https://review.coreboot.org/c/coreboot/+/62181/comment/e50e91db_a9f2180f PS7, Line 303: dimm->mod_type = SPD_UNDEFINED;
Same here.
Done
File src/include/device/dram/ddr4.h:
https://review.coreboot.org/c/coreboot/+/62181/comment/861e9dff_c6ed3082 PS7, Line 29: SPD_DDR4_DIMM_TYPE_EXTENDED = 0x0,
defined here: src/include/spd. […]
Don't know what you mean is defined there. This _TYPE_EXTENDED seems to be omitted there.
I looked into the spec now. A 0 in the SPD would mean the type is specified somewhere else (byte 15). We currently use the enum as if it's the only information needed. So I'd say it's ok to omit this special register value. However, we might want to remove the SPD_DDR*_DIMM_TYPE_MASK entries too, as those are also about register values. WDYT?