diff options
author | Octav Zlatior <octav.zlatior@theobroma-systems.com> | 2015-06-08 15:47:42 +0200 |
---|---|---|
committer | Klaus Goger <klaus.goger@theobroma-systems.com> | 2015-07-30 18:53:02 +0200 |
commit | 726941494fa59b0a106d21fcad6770bb0ed79f66 (patch) | |
tree | 80fa82ef82616a24e750fd361dd2f3c44ce62c3a /include/linux | |
parent | 403a58de190ff1322270ee571a4b670793a28fdf (diff) |
clk: adds support for transition-clock property
The transition-clock property defines a parent clock to be used by
a clock consumer during frequency transitions in variable frequency
clocks. It is specified by referencing a clock (must be a parent clock).
The clock functions clk_set_transition_parent and clk_get_transition_parent
are defined to work with the transition parent in clocks.
The clock function clk_use_transition_mode sets the clock parent to
the specified transition parent.
Signed-off-by: Octav Zlatior <octav.zlatior@theobroma-systems.com>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/clk.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/include/linux/clk.h b/include/linux/clk.h index 68c16a6bedb3..4c2add0b4819 100644 --- a/include/linux/clk.h +++ b/include/linux/clk.h @@ -378,6 +378,33 @@ int clk_set_parent(struct clk *clk, struct clk *parent); struct clk *clk_get_parent(struct clk *clk); /** + * clk_get_transition_parent - return the transition parent to be used by + * a clock + * @clk: clock to get transition parent for + * + * Returns a pointer to the transition parent or NULL if not set + */ +struct clk *clk_get_transition_parent(struct clk *clk); + +/** + * clk_set_transition_parent - set the transition parent to be used by + * a clock + * @clk: clock to set transition parent for + * @parent: clock parent to set as transition parent + * + * Returns 0 on success or an error code otherwise + */ +int clk_set_transition_parent(struct clk *clk, struct clk *parent); + +/** + * clk_use_transition_mode - set the clock to "transition_mode" + * In transition mode, the clock will use the transition parent as parent + * + * Returns 0 on success or an error code otherwise + */ +int clk_use_transition_mode(struct clk *clk); + +/** * clk_get_sys - get a clock based upon the device name * @dev_id: device name * @con_id: connection ID |