HomeFreeBSD

arm64: rockchip: rk3328_pll: Multiple improvement

Description

arm64: rockchip: rk3328_pll: Multiple improvement

RockChip clocks register have a write mask in the upper 16 bits, if a 1
is present the corresponding bit in the lower 16 ones is set.
Use this instead of always setting the mask to 0xFFFF0000.
This avoids a read of the register.
While here, when switching PLL frequency, first switch it to slow mode.
When set to slow mode the PLL clock will be the external oscillator.
Changing the PLL parameters while its output is used can cause hang (sometimes).

MFC after: 1 week

Details

Provenance
manuAuthored on
Parents
rS344577: arm64: rockchip: clk: ARM CLK improvement
Branches
Unknown
Tags
Unknown