summaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
authorMason Huo <mason.huo@starfivetech.com>2023-03-09 10:59:28 +0300
committerMason Huo <mason.huo@starfivetech.com>2023-03-09 11:21:32 +0300
commit2f68eec8b4838ac03a07ee27fe0c1ebfe17fedb0 (patch)
tree570dae9cd5aac154dc5f5377de7a4ec45211b41a /board
parentf7261333cb0e3e0c55e025b3069d655d745ef878 (diff)
downloadu-boot-2f68eec8b4838ac03a07ee27fe0c1ebfe17fedb0.tar.xz
board: starfive: jh7110: Add 1.1 & 1.02v max cpu voltage
Add two more binning IC types, and set add their max cpu voltage accordingly. Signed-off-by: Mason Huo <mason.huo@starfivetech.com>
Diffstat (limited to 'board')
-rw-r--r--board/starfive/evb/starfive_evb.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/board/starfive/evb/starfive_evb.c b/board/starfive/evb/starfive_evb.c
index e1e3f2dbc4..c219252b09 100644
--- a/board/starfive/evb/starfive_evb.c
+++ b/board/starfive/evb/starfive_evb.c
@@ -26,9 +26,11 @@ enum chip_type_t {
};
enum cpu_voltage_type_t {
+ CPU_VOL_1020 = 0x0e,
CPU_VOL_1040 = 0xff,
CPU_VOL_1060 = 0xf0,
CPU_VOL_1080 = 0xf1,
+ CPU_VOL_1100 = 0xf2,
};
#define SYS_CLOCK_ENABLE(clk) \
@@ -209,14 +211,20 @@ static void get_cpu_voltage_type(struct udevice *dev)
if (ret != sizeof(buf))
printf("%s: error reading CPU vol from OTP\n", __func__);
else {
+ buf = 0x0e;
switch ((buf & 0xff)) {
+ case CPU_VOL_1100:
+ env_set("cpu_max_vol", "1100000");
+ break;
case CPU_VOL_1080:
env_set("cpu_max_vol", "1080000");
break;
case CPU_VOL_1060:
env_set("cpu_max_vol", "1060000");
break;
- case CPU_VOL_1040:
+ case CPU_VOL_1020:
+ env_set("cpu_max_vol", "1020000");
+ break;
default:
env_set("cpu_max_vol", "1040000");
break;