mirror of
https://github.com/Stichting-MINIX-Research-Foundation/u-boot.git
synced 2025-09-13 05:55:02 -04:00
S5PC2XX: clock: support pwm clock for evt1 (cpu revision 1)
The source of pwm clock is fixed at evt1. And some registers for pwm clock are removed. Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
This commit is contained in:
parent
68a8cbfad9
commit
b4f73910d9
@ -124,6 +124,7 @@ static unsigned long s5pc210_get_pwm_clk(void)
|
||||
unsigned int sel;
|
||||
unsigned int ratio;
|
||||
|
||||
if (s5p_get_cpu_rev() == 0) {
|
||||
/*
|
||||
* CLK_SRC_PERIL0
|
||||
* PWM_SEL [27:24]
|
||||
@ -146,6 +147,11 @@ static unsigned long s5pc210_get_pwm_clk(void)
|
||||
*/
|
||||
ratio = readl(&clk->div_peril3);
|
||||
ratio = ratio & 0xf;
|
||||
} else if (s5p_get_cpu_rev() == 1) {
|
||||
sclk = get_pll_clk(MPLL);
|
||||
ratio = 8;
|
||||
} else
|
||||
return 0;
|
||||
|
||||
pclk = sclk / (ratio + 1);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user