aboutsummaryrefslogtreecommitdiff
path: root/src/mainboard/system76/oryp5/romstage.c
blob: 455a2bb91968ec27c1d8e1cf8f45549726ee2132 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/* SPDX-License-Identifier: GPL-2.0-only */

#include <soc/cnl_memcfg_init.h>
#include <soc/romstage.h>

static const struct cnl_mb_cfg memcfg = {
	.spd[0] = {
		.read_type = READ_SMBUS,
		.spd_spec = {.spd_smbus_address = 0xa0},
	},
	.spd[2] = {
		.read_type = READ_SMBUS,
		.spd_spec = {.spd_smbus_address = 0xa4},
	},
	.rcomp_resistor = { 121, 75, 100 },
	.rcomp_targets = { 50, 25, 20, 20, 26 },
	.dq_pins_interleaved = 1,
	.vref_ca_config = 2,
};

void mainboard_memory_init_params(FSPM_UPD *memupd)
{
	// Allow memory speeds higher than 2666 MT/s
	memupd->FspmConfig.SaOcSupport = 1;

	cannonlake_memcfg_init(&memupd->FspmConfig, &memcfg);
}