summaryrefslogtreecommitdiff
path: root/src/soc/mediatek/common
diff options
context:
space:
mode:
Diffstat (limited to 'src/soc/mediatek/common')
-rw-r--r--src/soc/mediatek/common/include/soc/mt6359p.h3
-rw-r--r--src/soc/mediatek/common/mt6359p.c9
2 files changed, 12 insertions, 0 deletions
diff --git a/src/soc/mediatek/common/include/soc/mt6359p.h b/src/soc/mediatek/common/include/soc/mt6359p.h
index 996d2e86d9..5afac9f47a 100644
--- a/src/soc/mediatek/common/include/soc/mt6359p.h
+++ b/src/soc/mediatek/common/include/soc/mt6359p.h
@@ -18,6 +18,8 @@ enum {
PMIC_OTP_CON12 = 0x03a2,
PMIC_OTP_CON13 = 0x03a4,
PMIC_PWRHOLD = 0x0a08,
+ PMIC_VCORE_DBG0 = 0x1526,
+ PMIC_VCORE_ELR0 = 0x152c,
PMIC_VGPU11_DBG0 = 0x15a6,
PMIC_VGPU11_ELR0 = 0x15b4,
PMIC_VS2_VOTER = 0x18aa,
@@ -50,6 +52,7 @@ enum {
MT6359P_GPU11 = 0,
MT6359P_SRAM_PROC1,
MT6359P_SRAM_PROC2,
+ MT6359P_CORE,
MT6359P_MAX,
};
diff --git a/src/soc/mediatek/common/mt6359p.c b/src/soc/mediatek/common/mt6359p.c
index 8ebcfc6458..5a87c0d8e1 100644
--- a/src/soc/mediatek/common/mt6359p.c
+++ b/src/soc/mediatek/common/mt6359p.c
@@ -177,6 +177,10 @@ void mt6359p_buck_set_voltage(u32 buck_id, u32 buck_uv)
vol_offset = 500000;
vol_reg = PMIC_VSRAM_PROC2_ELR;
break;
+ case MT6359P_CORE:
+ vol_offset = 506250;
+ vol_reg = PMIC_VCORE_ELR0;
+ break;
default:
die("ERROR: Unknown buck_id %u", buck_id);
return;
@@ -209,6 +213,11 @@ u32 mt6359p_buck_get_voltage(u32 buck_id)
vol_offset = 500000;
vol_reg = PMIC_VSRAM_PROC2_VOSEL1;
break;
+ case MT6359P_CORE:
+ vol_shift = 0;
+ vol_offset = 506250;
+ vol_reg = PMIC_VCORE_DBG0;
+ break;
default:
die("ERROR: Unknown buck_id %u", buck_id);
return 0;