Skip to content

clk: meson: pll fixes

Jerome Brunet linux-amlogic linux-clk lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest9 patches 1 replyIn review
  2. v19 patches 1 replySuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9clk: meson: check pll rate param table before using itdrivers/clk/meson/clk-pll.c+10 -00 replies
2/9clk: meson: remove useless pll rate params tablesdrivers/clk/meson/axg.c drivers/clk/meson/gxbb.c+0 -1880 replies
3/9clk: meson: remove unnecessary rounding in the pll clockdrivers/clk/meson/clk-pll.c+9 -80 replies
4/9clk: meson: use the frac parameter width instead of a constantdrivers/clk/meson/clk-pll.c+1 -10 replies
5/9clk: meson: add od3 to the pll driverdrivers/clk/meson/clk-pll.c drivers/clk/meson/clkc.h drivers/clk/meson/gxbb.c+23 -30 replies
6/9clk: meson: add the gxl hdmi plldrivers/clk/meson/gxbb.c+48 -20 replies
7/9clk: meson: fix rate calculation of plls with a fractional partdrivers/clk/meson/clk-pll.c drivers/clk/meson/gxbb.c drivers/clk/meson/gxbb.h+15 -30 replies
8/9clk: meson: gxbb: add the fractional part of the fixed_plldrivers/clk/meson/gxbb.c+5 -00 replies
9/9clk: meson: axg: add the fractional part of the fixed_plldrivers/clk/meson/axg.c+5 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/9] clk: meson: pll fixes

This changeset is a collection of fixes and clean-up around the pll clock provider. This has been triggered by the discussion around the ethernet clock on the axg [0].

On the axg the rate reported by the fixed_pll is off by 8Mhz, which leads the internal mux of the ethernet driver to pick an mpll2 instead of the fdiv4.

With this series applied, the fixed_pll of the axg now reports 1999998046 Hz, which is coherent with measurements (~2GHz)

While debugging this, we uncovered quite a mess around the hdmi_pll of the gxbb and gxl family. This is also fixed by this series.

Last, the parameters table provided to the read-only sys_plls have been removed, saving a bit of memory

There is still work to be done on this clock provider. Someday, I hope to see the parameter tables go away completely. This pll is just a (quite complex) fractional divider, we sould be able to figure something out at runtime.

Changes since v1: [1]
* fix several typos in the comments
* fix arm32 u64 math in patch 3 (Thanks a lot Martin!!)

[0]: https://lkml.kernel.org/r/1516095424.2608.36.camel at baylibre.com [1]: https://lkml.kernel.org/r/20180118184532.6856-1-jbrunet at baylibre.com

Jerome Brunet (9):
clk: meson: check pll rate param table before using it
clk: meson: remove useless pll rate params tables
clk: meson: remove unnecessary rounding in the pll clock
clk: meson: use the frac parameter width instead of a constant
clk: meson: add od3 to the pll driver
clk: meson: add the gxl hdmi pll
clk: meson: fix rate calculation of plls with a fractional part
clk: meson: gxbb: add the fractional part of the fixed_pll
clk: meson: axg: add the fractional part of the fixed_pll

 drivers/clk/meson/axg.c     |  99 ++------------------------
 drivers/clk/meson/clk-pll.c |  41 ++++++++---
 drivers/clk/meson/clkc.h    |   2 +
 drivers/clk/meson/gxbb.c    | 166 +++++++++++++++++++-------------------------
 drivers/clk/meson/gxbb.h    |   3 +-
 5 files changed, 111 insertions(+), 200 deletions(-)
Signature · 1 line
2.14.3