diff options
author | Sebastian Reichel <sebastian.reichel@collabora.com> | 2022-10-18 17:14:06 +0200 |
---|---|---|
committer | Heiko Stuebner <heiko@sntech.de> | 2022-11-14 15:35:07 +0100 |
commit | ada8f95ba04e8fe07289b7de157ae99bb96bc8cb (patch) | |
tree | a2d2b8f242a76394777dad80de068ab38d4a5837 /drivers/clk/rockchip/clk.h | |
parent | clk: rockchip: simplify rockchip_clk_add_lookup (diff) | |
download | linux-ada8f95ba04e8fe07289b7de157ae99bb96bc8cb.tar.xz linux-ada8f95ba04e8fe07289b7de157ae99bb96bc8cb.zip |
clk: rockchip: add lookup table support
Add support for mapping reset IDs to register offsets
to support gapless continous platform reset IDs.
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Link: https://lore.kernel.org/r/20221018151407.63395-9-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 | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/drivers/clk/rockchip/clk.h b/drivers/clk/rockchip/clk.h index 6e84ab85b372..7ee231d9585d 100644 --- a/drivers/clk/rockchip/clk.h +++ b/drivers/clk/rockchip/clk.h @@ -958,15 +958,24 @@ struct clk *rockchip_clk_register_halfdiv(const char *name, spinlock_t *lock); #ifdef CONFIG_RESET_CONTROLLER -void rockchip_register_softrst(struct device_node *np, - unsigned int num_regs, - void __iomem *base, u8 flags); +void rockchip_register_softrst_lut(struct device_node *np, + const int *lookup_table, + unsigned int num_regs, + void __iomem *base, u8 flags); #else -static inline void rockchip_register_softrst(struct device_node *np, - unsigned int num_regs, - void __iomem *base, u8 flags) +static inline void rockchip_register_softrst_lut(struct device_node *np, + const int *lookup_table, + unsigned int num_regs, + void __iomem *base, u8 flags) { } #endif +static inline void rockchip_register_softrst(struct device_node *np, + unsigned int num_regs, + void __iomem *base, u8 flags) +{ + return rockchip_register_softrst_lut(np, NULL, num_regs, base, flags); +} + #endif |