mb/google/nissa/var/rull: Add 6W and 15W DPTF parameters
[coreboot.git] / src / soc / mediatek / mt8195 / emi.c
blob55a6bab6abe36bc775c71206350e56a216c3d387
1 /* SPDX-License-Identifier: GPL-2.0-only OR MIT */
3 #include <console/console.h>
4 #include <emi.h>
5 #include <soc/emi.h>
7 size_t sdram_size(void)
9 int rank_num;
10 u64 rank_size[RANK_MAX];
11 static size_t dram_size = 0;
13 if (dram_size)
14 return dram_size;
16 get_rank_size_by_emi(rank_size);
17 rank_num = get_rank_nr_by_emi();
19 for (int i = 0; i < rank_num; i++)
20 dram_size += rank_size[i];
22 printk(BIOS_INFO, "dram size = %#lx\n", dram_size);
24 return dram_size;