a7a4bd8ea2bba934f7a9e738585d5f81511dd551
[openwrt/openwrt.git] / target / linux / mediatek / patches-5.15 / 351-cpufreq-mediatek-don-t-request-unsupported-voltage.patch
1 From 20aad28ba5d62f1618408c264384d0b2ad7417db Mon Sep 17 00:00:00 2001
2 From: Daniel Golle <daniel@makrotopia.org>
3 Date: Mon, 22 May 2023 23:25:48 +0100
4 Subject: [PATCH] cpufreq: mediatek: don't request unsupported voltage
5
6 PMICs on MT7622 and MT7623 boards only support up to 1350000uV despite
7 the SoC's processor and SRAM voltage can be up to 1360000uV. As a
8 work-around specify max. processor and SRAM voltage as 1350000uV to
9 avoid requesting an unsupported voltage from the regulator.
10
11 Signed-off-by: Daniel Golle <daniel@makrotopia.org>
12 ---
13 drivers/cpufreq/mediatek-cpufreq.c | 4 ++--
14 1 file changed, 2 insertions(+), 2 deletions(-)
15
16 --- a/drivers/cpufreq/mediatek-cpufreq.c
17 +++ b/drivers/cpufreq/mediatek-cpufreq.c
18 @@ -696,9 +696,9 @@ static const struct mtk_cpufreq_platform
19 static const struct mtk_cpufreq_platform_data mt7622_platform_data = {
20 .min_volt_shift = 100000,
21 .max_volt_shift = 200000,
22 - .proc_max_volt = 1360000,
23 + .proc_max_volt = 1350000,
24 .sram_min_volt = 0,
25 - .sram_max_volt = 1360000,
26 + .sram_max_volt = 1350000,
27 .ccifreq_supported = false,
28 };
29