clk: bcm: rpi: Add variant structure
authorMaxime Ripard <maxime@cerno.tech>
Fri, 25 Feb 2022 14:35:30 +0000 (15:35 +0100)
committerStephen Boyd <sboyd@kernel.org>
Sat, 12 Mar 2022 03:15:03 +0000 (19:15 -0800)
commit12c90f3f27bb3ad0dd3fad1550fec87091aa3329
tree5da03f65971c73d67404298381b78529f97e41c9
parentc97448437847bd76116b3a077e44808e946bb1ae
clk: bcm: rpi: Add variant structure

We only export a bunch of firmware clocks, and some of them require
special treatment.

This has been do so far using some tests on the clock id in various
places, but this is fairly hard to extend and doesn't scale very well.

Since we'll need some more cases in the next patches, let's switch to a
variant structure that defines the behaviour we need to have for a given
clock.

Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://lore.kernel.org/r/20220225143534.405820-9-maxime@cerno.tech
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
drivers/clk/bcm/clk-raspberrypi.c