coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
romstage_fsp_params.c
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 
3 #include <baseboard/variants.h>
4 #include <soc/meminit.h>
5 #include <soc/romstage.h>
6 
7 void mainboard_memory_init_params(FSPM_UPD *memupd)
8 {
9  static struct spd_info ehlcrb_spd_info;
10  const struct mb_cfg *board_cfg = variant_memcfg_config();
11 
12  /* TODO: Read the resistor strap to get number of memory segments */
13  bool half_populated = false;
14  /* Initialize spd information for LPDDR4x board */
15  ehlcrb_spd_info.read_type = READ_SPD_CBFS;
16  ehlcrb_spd_info.spd_spec.spd_index = 0x00;
17 
18  /* Initialize variant specific configurations */
19  memcfg_init(&memupd->FspmConfig, board_cfg, &ehlcrb_spd_info, half_populated);
20 }
void memcfg_init(FSPM_UPD *memupd, const struct mb_cfg *mb_cfg, const struct mem_spd *spd_info, bool half_populated)
Definition: meminit.c:238
@ READ_SPD_CBFS
const struct mb_cfg * variant_memcfg_config(void)
Definition: memory.c:46
void mainboard_memory_init_params(FSPM_UPD *memupd)
static const struct mb_cfg board_cfg
Definition: romstage.c:8
Definition: meminit.h:71
Definition: spd.h:11
union spd_info::spd_data_by spd_spec
enum mem_info_read_type read_type