diff options
author | Taniya Das <tdas@codeaurora.org> | 2016-11-14 11:26:02 +0530 |
---|---|---|
committer | Taniya Das <tdas@codeaurora.org> | 2016-11-16 09:16:51 +0530 |
commit | 770f204fbd1ded8c48a8441e55e86d77ad99d367 (patch) | |
tree | 9e313f4b25ad8897028214084c289681eef1b459 /include/linux | |
parent | 1e1700765225e4aa31d076f78c9937bd93509083 (diff) |
clk: add/modify debugfs support for clocks
Update clock debugfs to support the below functionalities.
- Allow enable/disable a clock.
- Allow set_rate on a clock.
- Display the list of enabled_clocks along with prepare_count,
enable_count and rate.
- Display the register contents of all the clocks which support
this clock operation.
Change-Id: Ib67b3a3409c9e7d8adb710bb524f54f543abf712
Signed-off-by: Taniya Das <tdas@codeaurora.org>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/clk-provider.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/clk-provider.h b/include/linux/clk-provider.h index 2a5acbdc6327..2a4047c049a8 100644 --- a/include/linux/clk-provider.h +++ b/include/linux/clk-provider.h @@ -177,6 +177,10 @@ struct clk_rate_request { * @set_flags: Set custom flags which deals with hardware specifics. Returns 0 * on success, -EEROR otherwise. * + * @list_registers: Queries the hardware to get the current register contents. + * This callback is optional and required clocks could + * add this callback. + * * The clk_enable/clk_disable and clk_prepare/clk_unprepare pairs allow * implementations to split any work between atomic (enable) and sleepable * (prepare) contexts. If enabling a clock requires code that might sleep, @@ -217,6 +221,8 @@ struct clk_ops { void (*init)(struct clk_hw *hw); int (*debug_init)(struct clk_hw *hw, struct dentry *dentry); int (*set_flags)(struct clk_hw *hw, unsigned flags); + void (*list_registers)(struct seq_file *f, + struct clk_hw *hw); }; /** |