mirror of
https://github.com/u-boot/u-boot.git
synced 2025-05-09 03:21:51 +00:00
clk: ccf: Add some helper functions for clock ops
Most CCF drivers follow a common pattern where their clock ops defer the actual operation to the backing CCF clock. Add some generic implementations of these functions to reduce duplication of code. Signed-off-by: Sean Anderson <seanga2@gmail.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Link: https://lore.kernel.org/r/20220320203446.740178-1-seanga2@gmail.com
This commit is contained in:
parent
e7075ff7b3
commit
3a11b5ae65
2 changed files with 73 additions and 0 deletions
|
@ -254,4 +254,12 @@ const char *clk_hw_get_name(const struct clk *hw);
|
|||
ulong clk_generic_get_rate(struct clk *clk);
|
||||
|
||||
struct clk *dev_get_clk_ptr(struct udevice *dev);
|
||||
|
||||
ulong ccf_clk_get_rate(struct clk *clk);
|
||||
ulong ccf_clk_set_rate(struct clk *clk, unsigned long rate);
|
||||
int ccf_clk_set_parent(struct clk *clk, struct clk *parent);
|
||||
int ccf_clk_enable(struct clk *clk);
|
||||
int ccf_clk_disable(struct clk *clk);
|
||||
extern const struct clk_ops ccf_clk_ops;
|
||||
|
||||
#endif /* __LINUX_CLK_PROVIDER_H */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue