diff options
author | Sebastian Reichel <sebastian.reichel@collabora.com> | 2024-01-26 21:18:22 +0300 |
---|---|---|
committer | Heiko Stuebner <heiko@sntech.de> | 2024-02-27 19:04:58 +0300 |
commit | 2dc66a5ab2c6fb532fbb16107ee7efcb0effbfa5 (patch) | |
tree | d297a89151b6315f3282f92e202d3e5ed7e5949b /drivers/clk/rockchip/clk.h | |
parent | 6613476e225e090cc9aad49be7fa504e290dd33d (diff) | |
download | linux-2dc66a5ab2c6fb532fbb16107ee7efcb0effbfa5.tar.xz |
clk: rockchip: rk3588: fix CLK_NR_CLKS usage
CLK_NR_CLKS is not part of the DT bindings and needs to be removed
from it, just like it recently happened for other platforms. This
takes care of it by introducing a new function identifying the
maximum used clock ID at runtime.
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Link: https://lore.kernel.org/r/20240126182919.48402-2-sebastian.reichel@collabora.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Diffstat (limited to 'drivers/clk/rockchip/clk.h')
-rw-r--r-- | drivers/clk/rockchip/clk.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/clk/rockchip/clk.h b/drivers/clk/rockchip/clk.h index 758ebaf2236b..fd3b476dedda 100644 --- a/drivers/clk/rockchip/clk.h +++ b/drivers/clk/rockchip/clk.h @@ -973,6 +973,8 @@ struct rockchip_clk_provider *rockchip_clk_init(struct device_node *np, void __iomem *base, unsigned long nr_clks); void rockchip_clk_of_add_provider(struct device_node *np, struct rockchip_clk_provider *ctx); +unsigned long rockchip_clk_find_max_clk_id(struct rockchip_clk_branch *list, + unsigned int nr_clk); void rockchip_clk_register_branches(struct rockchip_clk_provider *ctx, struct rockchip_clk_branch *list, unsigned int nr_clk); |