summaryrefslogtreecommitdiff
path: root/src/soc/mediatek/mt8192/pmif_spmi.c
diff options
context:
space:
mode:
authorHui Liu <hui.liu@mediatek.corp-partner.google.com>2022-07-05 14:53:22 +0800
committerFelix Held <felix-coreboot@felixheld.de>2022-07-13 10:43:36 +0000
commita5c96826333cd3e14064639b25c0d4574d6b9aea (patch)
treeac3c28689efa1331831ba7c0b560a5555782e0fd /src/soc/mediatek/mt8192/pmif_spmi.c
parent1ad10ee7a55303e4b7a32036d4ba94aae43bb397 (diff)
soc/mediatek: Move SPMI device table to SoC folder
The SPMI devices on MT8188 are different from previous SoCs, so we move them to SoC folder. We also move SoC-specific definitions to soc/pmif.h. TEST=build pass BUG=b:233720142 Signed-off-by: Hui Liu <hui.liu@mediatek.corp-partner.google.com> Change-Id: I666c2a8222a2bd8cd460e2225a7ae48b001da9d4 Reviewed-on: https://review.coreboot.org/c/coreboot/+/65757 Reviewed-by: Yidi Lin <yidilin@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Diffstat (limited to 'src/soc/mediatek/mt8192/pmif_spmi.c')
-rw-r--r--src/soc/mediatek/mt8192/pmif_spmi.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/soc/mediatek/mt8192/pmif_spmi.c b/src/soc/mediatek/mt8192/pmif_spmi.c
index a68f235382..1862af5408 100644
--- a/src/soc/mediatek/mt8192/pmif_spmi.c
+++ b/src/soc/mediatek/mt8192/pmif_spmi.c
@@ -21,6 +21,21 @@ DEFINE_BIT(PDN_SPMI_MST, 15)
/* TOPCKGEN, CLK_CFG_UPDATE2 */
DEFINE_BIT(SPMI_MST_CK_UPDATE, 30)
+const struct spmi_device spmi_dev[] = {
+ {
+ .slvid = SPMI_SLAVE_6,
+ .type = BUCK_CPU,
+ .type_id = BUCK_CPU_ID,
+ },
+ {
+ .slvid = SPMI_SLAVE_7,
+ .type = BUCK_GPU,
+ .type_id = BUCK_GPU_ID,
+ },
+};
+
+const size_t spmi_dev_cnt = ARRAY_SIZE(spmi_dev);
+
int spmi_config_master(void)
{
/* Software reset */