![]() |
coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
|
Utilities for decoding DDR4 SPDs. More...
Go to the source code of this file.
Data Structures | |
struct | dimm_attr_ddr4_st |
DIMM characteristics. More... | |
Macros | |
#define | SPD_DDR4_PART_OFF 329 |
#define | SPD_DDR4_PART_LEN 20 |
Typedefs | |
typedef u8 | spd_raw_data[512] |
Enumerations | |
enum | spd_dimm_type_ddr4 { SPD_DDR4_DIMM_TYPE_EXTENDED = 0x0 , SPD_DDR4_DIMM_TYPE_RDIMM = 0x1 , SPD_DDR4_DIMM_TYPE_UDIMM = 0x2 , SPD_DDR4_DIMM_TYPE_SO_DIMM = 0x3 , SPD_DDR4_DIMM_TYPE_LRDIMM = 0x4 , SPD_DDR4_DIMM_TYPE_MINI_RDIMM = 0x5 , SPD_DDR4_DIMM_TYPE_MINI_UDIMM = 0x6 , SPD_DDR4_DIMM_TYPE_72B_SO_RDIMM = 0x8 , SPD_DDR4_DIMM_TYPE_72B_SO_UDIMM = 0x9 , SPD_DDR4_DIMM_TYPE_16B_SO_DIMM = 0xc , SPD_DDR4_DIMM_TYPE_32B_SO_DIMM = 0xd , SPD_DDR4_DIMM_TYPE_MASK = 0xf } |
Functions | |
int | spd_decode_ddr4 (struct dimm_attr_ddr4_st *dimm, spd_raw_data spd) |
Decode the raw SPD data. More... | |
enum cb_err | spd_add_smbios17_ddr4 (const u8 channel, const u8 slot, const u16 selected_freq, const struct dimm_attr_ddr4_st *info) |
uint16_t | ddr4_speed_mhz_to_reported_mts (uint16_t speed_mhz) |
Converts DDR4 clock speed in MHz to the standard reported speed in MT/s. More... | |
Utilities for decoding DDR4 SPDs.
Definition in file ddr4.h.
enum spd_dimm_type_ddr4 |
Converts DDR4 clock speed in MHz to the standard reported speed in MT/s.
Definition at line 137 of file ddr4.c.
References ARRAY_SIZE, BIOS_ERR, ddr4_speeds, ddr4_speed_attr::max_clock_mhz, ddr4_speed_attr::min_clock_mhz, printk, and ddr4_speed_attr::reported_mts.
Referenced by ddr_speed_mhz_to_reported_mts().
enum cb_err spd_add_smbios17_ddr4 | ( | const u8 | channel, |
const u8 | slot, | ||
const u16 | selected_freq, | ||
const struct dimm_attr_ddr4_st * | info | ||
) |
Definition at line 166 of file ddr4.c.
References ARRAY_SIZE, BIOS_ERR, BIOS_WARNING, block_exists(), dimm_attr_ddr4_st::bus_width, dimm_attr_ddr4_st::cap_per_die_mbit, dimm_attr_ddr4_st::dimm_type, dimm_attr_ddr4_st::dram_type, dimm_attr_ddr4_st::manufacturer_id, memcpy(), dimm_attr_ddr4_st::part_number, printk, dimm_attr_ddr4_st::ranks, dimm_attr_ddr4_st::sdram_width, dimm_attr_ddr4_st::serial_number, dimm_attr_ddr4_st::size_mb, spd_blocks, SPD_DDR4_PART_LEN, SPD_MEMORY_TYPE_DDR4_SDRAM, SPD_MEMORY_TYPE_UNDEFINED, SPD_STATUS_CRC_ERROR, SPD_STATUS_INVALID, SPD_STATUS_OK, type, dimm_attr_ddr4_st::vdd_voltage, and verify_block().
int spd_decode_ddr4 | ( | struct dimm_attr_ddr4_st * | dimm, |
spd_raw_data | spd | ||
) |
Decode the raw SPD data.
Decodes a raw SPD data from a DDR4 DIMM, and organizes it into a dimm_attr structure. The SPD data must first be read in a contiguous array, and passed to this function.
dimm | pointer to dimm_attr structure where the decoded data is to be stored |
spd | array of raw data previously read from the SPD. |