Furquan Shaikh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/35206 )
Change subject: lib/spd_bin: Extend DDR4 spd information ......................................................................
Patch Set 10:
(2 comments)
https://review.coreboot.org/c/coreboot/+/35206/10/src/lib/spd_bin.c File src/lib/spd_bin.c:
https://review.coreboot.org/c/coreboot/+/35206/10/src/lib/spd_bin.c@60 PS10, Line 60: if (is_memory_type_ddr4(dram_type)) { : if (index >= ARRAY_SIZE(ddr4_banks)) : return -1; : return ddr4_banks[index]; : } else { Just use switch case here and in functions below for dram_type rather than having a special is_memory_type_ddr4() helper?
https://review.coreboot.org/c/coreboot/+/35206/10/src/lib/spd_bin.c@146 PS10, Line 146: /* Module Part Number */ : switch (type) { : case SPD_DRAM_DDR3: : memcpy(spd_name, &spd[DDR3_SPD_PART_OFF], DDR3_SPD_PART_LEN); : spd_name[DDR3_SPD_PART_LEN] = 0; : break; : case SPD_DRAM_LPDDR3_INTEL: : case SPD_DRAM_LPDDR3_JEDEC: : memcpy(spd_name, &spd[LPDDR3_SPD_PART_OFF], : LPDDR3_SPD_PART_LEN); : spd_name[LPDDR3_SPD_PART_LEN] = 0; : break; : case SPD_DRAM_DDR4: : memcpy(spd_name, &spd[DDR4_SPD_PART_OFF], DDR4_SPD_PART_LEN); : spd_name[DDR4_SPD_PART_LEN] = 0; : break; : default: : break; : } Have a helper for Module Part number as well?