OpenCloudOS-Kernel/drivers/clk/sunxi-ng
Tobias Schramm 47e4dc4e63
clk: sunxi-ng: v3s: fix incorrect postdivider on pll-audio
Commit 46060be6d8 ("clk: sunxi-ng: v3s: use sigma-delta modulation for audio-pll")
changed the audio pll on the Allwinner V3s and V3 SoCs to use
sigma-delta modulation. In the process the declaration of fixed postdivider
providing "pll-audio" was adjusted to provide the desired clock rates from
the now sigma-delta modulated pll.
However, while the divider used for calculations by the clock framework
was adjusted the actual divider programmed into the hardware in
sun8i_v3_v3s_ccu_init was left at "divide by four". This broke the
"pll-audio" clock, now only providing quater the expected clock rate.
It would in general be desirable to program the postdivider for
"pll-audio" to four, such that a broader range of frequencies were
available on the pll outputs. But the clock for the integrated codec
"ac-dig" does not feature a mux that allows to select from all pll outputs
as it is just a simple clock gate connected to "pll-audio". Thus we need
to set the postdivider to one to be able to provide the 22.5792MHz and
24.576MHz rates required by the internal sun4i codec.

This patches fixes the incorrect clock rate by forcing the postdivider to
one in sun8i_v3_v3s_ccu_init.

Fixes: 46060be6d8 ("clk: sunxi-ng: v3s: use sigma-delta modulation for audio-pll")
Signed-off-by: Tobias Schramm <t.schramm@manjaro.org>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://lore.kernel.org/r/20210513131315.2059451-1-t.schramm@manjaro.org
2021-05-24 13:57:37 +02:00
..
Kconfig clk: sunxi-ng: Add support for the Allwinner H616 CCU 2021-01-28 11:14:35 +01:00
Makefile clk: sunxi-ng: Add support for the Allwinner H616 CCU 2021-01-28 11:14:35 +01:00
ccu-sun4i-a10.c This round of clk driver and framework updates is heavy on the driver update 2019-07-17 10:07:48 -07:00
ccu-sun4i-a10.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
ccu-sun5i.c This round of clk driver and framework updates is heavy on the driver update 2019-07-17 10:07:48 -07:00
ccu-sun5i.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
ccu-sun6i-a31.c This round of clk driver and framework updates is heavy on the driver update 2019-07-17 10:07:48 -07:00
ccu-sun6i-a31.h clk: sunxi: a31: Export the MIPI PLL 2020-01-04 09:45:09 +01:00
ccu-sun8i-a23-a33.h clk: sunxi: a23/a33: Export the MIPI PLL 2020-01-04 09:45:19 +01:00
ccu-sun8i-a23.c This round of clk driver and framework updates is heavy on the driver update 2019-07-17 10:07:48 -07:00
ccu-sun8i-a33.c This round of clk driver and framework updates is heavy on the driver update 2019-07-17 10:07:48 -07:00
ccu-sun8i-a83t.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu-sun8i-a83t.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
ccu-sun8i-de2.c clk: sunxi-ng: sun8i-de2: Sort structures 2020-02-12 19:01:16 +01:00
ccu-sun8i-de2.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
ccu-sun8i-h3.c clk: sunxi-ng: Make sure divider tables have sentinel 2020-12-19 15:54:02 -08:00
ccu-sun8i-h3.h clk: sunxi-ng: h3: Export MBUS clock 2019-11-05 11:34:41 +01:00
ccu-sun8i-r.c clk: sunxi-ng: sun8i-r: Fix divider on APB0 clock 2020-01-02 10:27:47 +01:00
ccu-sun8i-r.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
ccu-sun8i-r40.c clk: sunxi-ng: sun8i: r40: Use sigma delta modulation for audio PLL 2020-08-25 16:42:55 +02:00
ccu-sun8i-r40.h clk: sunxi-ng: r40: Export MBUS clock 2020-01-03 10:37:14 +01:00
ccu-sun8i-v3s.c clk: sunxi-ng: v3s: fix incorrect postdivider on pll-audio 2021-05-24 13:57:37 +02:00
ccu-sun8i-v3s.h clk: sunxi-ng: v3s: Fix incorrect number of hw_clks. 2019-12-09 08:49:31 +01:00
ccu-sun9i-a80-de.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu-sun9i-a80-de.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
ccu-sun9i-a80-usb.c This round of clk driver and framework updates is heavy on the driver update 2019-07-17 10:07:48 -07:00
ccu-sun9i-a80-usb.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
ccu-sun9i-a80.c clk: sunxi-ng: a80: fix the zero'ing of bits 16 and 18 2019-10-29 08:42:52 +01:00
ccu-sun9i-a80.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
ccu-sun50i-a64.c clk: sunxi-ng: Make sure divider tables have sentinel 2020-12-19 15:54:02 -08:00
ccu-sun50i-a64.h clk: sunxi-ng: a64: Export MBUS clock 2020-02-11 07:49:14 +01:00
ccu-sun50i-a100-r.c clk: sunxi-ng: add support for the Allwinner A100 CCU 2020-08-25 10:52:18 +02:00
ccu-sun50i-a100-r.h clk: sunxi-ng: add support for the Allwinner A100 CCU 2020-08-25 10:52:18 +02:00
ccu-sun50i-a100.c clk: sunxi-ng: add support for the Allwinner A100 CCU 2020-08-25 10:52:18 +02:00
ccu-sun50i-a100.h clk: sunxi-ng: add support for the Allwinner A100 CCU 2020-08-25 10:52:18 +02:00
ccu-sun50i-h6-r.c clk: sunxi-ng: Add support for the Allwinner H616 R-CCU 2021-01-28 11:14:30 +01:00
ccu-sun50i-h6-r.h clk: sunxi-ng: h6-r: Add R_APB2_RSB clock and reset 2021-01-06 19:34:29 +08:00
ccu-sun50i-h6.c clk: sunxi-ng: h6: Fix clock divider range on some clocks 2021-01-20 10:59:30 +01:00
ccu-sun50i-h6.h clk: sunxi-ng: Use the correct style for SPDX License Identifier 2019-05-01 13:01:26 -07:00
ccu-sun50i-h616.c clk: sunxi-ng: Add support for the Allwinner H616 CCU 2021-01-28 11:14:35 +01:00
ccu-sun50i-h616.h clk: sunxi-ng: Add support for the Allwinner H616 CCU 2021-01-28 11:14:35 +01:00
ccu-suniv-f1c100s.c clk: sunxi-ng: f1c100s: Use local parent references for CLK_FIXED_FACTOR 2019-06-22 10:13:16 +08:00
ccu-suniv-f1c100s.h clk: sunxi-ng: Use the correct style for SPDX License Identifier 2019-05-01 13:01:26 -07:00
ccu_common.c clk: sunxi: Don't call clk_hw_get_name() on a hw that isn't registered 2019-08-16 10:27:29 -07:00
ccu_common.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_div.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_div.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_frac.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_frac.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_gate.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_gate.h This round of clk driver and framework updates is heavy on the driver update 2019-07-17 10:07:48 -07:00
ccu_mmc_timing.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_mp.c clk: sunxi-ng: mp: fix parent rate change flag check 2021-02-11 19:02:24 -08:00
ccu_mp.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_mult.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_mult.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
ccu_mux.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_mux.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
ccu_nk.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_nk.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_nkm.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_nkm.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_nkmp.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_nkmp.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_nm.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_nm.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_phase.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_phase.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_reset.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_reset.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00
ccu_sdm.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ccu_sdm.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 282 2019-06-05 17:36:37 +02:00