]> git.baikalelectronics.ru Git - kernel.git/commit
clk: renesas: cpg-mssr: Add support for fixing up clock tables
authorGeert Uytterhoeven <geert+renesas@glider.be>
Thu, 29 Sep 2016 12:47:58 +0000 (14:47 +0200)
committerGeert Uytterhoeven <geert+renesas@glider.be>
Thu, 30 Mar 2017 11:25:24 +0000 (13:25 +0200)
commit92af40784338942660a8ed444a7dded28a8504cd
tree5212a15c00949b30e9f4a0a1e24709c0d0ff9a5e
parent7d42f75d3c8a8d32f4dcee83e7c4da53c3228496
clk: renesas: cpg-mssr: Add support for fixing up clock tables

The same SoC may have different clocks and/or module clock parents,
depending on SoC revision.  One option is to use different sets of clock
tables for each SoC revision.  However, if the differences are small, it
is much more space-efficient to have a single set of clock tables, and
fix those up at runtime instead.

Hence provide three helpers:
  - Two helpers to NULLify core and module clocks that do not exist on
    some revisions (NULLified clocks are skipped during the registration
    phase),
  - One helper to reparent module clocks that have different clock
    parents.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
drivers/clk/renesas/renesas-cpg-mssr.c
drivers/clk/renesas/renesas-cpg-mssr.h