Skip to content
Commit f4bf0b90 authored by Maksim Kiselev's avatar Maksim Kiselev Committed by Stephen Boyd
Browse files

clk: thead: Fix TH1520 emmc and shdci clock rate

In accordance with LicheePi 4A BSP the clock that comes to emmc/sdhci
is 198Mhz which is got through frequency division of source clock
VIDEO PLL by 4 [1].

But now the AP_SUBSYS driver sets the CLK EMMC SDIO to the same
frequency as the VIDEO PLL, equal to 792 MHz. This causes emmc/sdhci
to work 4 times slower.

Let's fix this issue by adding fixed factor clock that divides
VIDEO PLL by 4 for emmc/sdhci.

Link: https://github.com/revyos/thead-kernel/blob/7563179071a314f41cdcdbfd8cf6e101e73707f3/drivers/clk/thead/clk-light-fm.c#L454



Fixes: ae81b69f ("clk: thead: Add support for T-Head TH1520 AP_SUBSYS clocks")
Signed-off-by: default avatarMaksim Kiselev <bigunclemax@gmail.com>
Link: https://lore.kernel.org/r/20241210083029.92620-1-bigunclemax@gmail.com


Tested-by: default avatarXi Ruoyao <xry111@xry111.site>
Reviewed-by: default avatarDrew Fustini <dfustini@tenstorrent.com>
Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
parent 52fd1709
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment