diff options
author | Tomasz Figa <t.figa@samsung.com> | 2013-12-12 11:07:15 -0500 |
---|---|---|
committer | Mike Turquette <mturquette@linaro.org> | 2014-01-08 12:46:03 -0500 |
commit | cf7d4a6f845ea9e57fb6dacccf823b7c7eff4e8a (patch) | |
tree | 21cfb9283bb05221e86cc3b25cf6596fe3c8eae5 | |
parent | 21c8ed2dc05bc5477d55000c5e96a4f3e95f408e (diff) |
clk: max77686: Provide .recalc_rate() operation
It is usually nice to know frequency of a clock, so this patch adds a
.recalc_rate() callback returning rates of provided clocks.
Signed-off-by: Tomasz Figa <t.figa@samsung.com>
Acked-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mike Turquette <mturquette@linaro.org>
-rw-r--r-- | drivers/clk/clk-max77686.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/clk/clk-max77686.c b/drivers/clk/clk-max77686.c index 9e66115a326b..d050d0b156d3 100644 --- a/drivers/clk/clk-max77686.c +++ b/drivers/clk/clk-max77686.c | |||
@@ -81,10 +81,17 @@ static int max77686_clk_is_prepared(struct clk_hw *hw) | |||
81 | return val & max77686->mask; | 81 | return val & max77686->mask; |
82 | } | 82 | } |
83 | 83 | ||
84 | static unsigned long max77686_recalc_rate(struct clk_hw *hw, | ||
85 | unsigned long parent_rate) | ||
86 | { | ||
87 | return 32768; | ||
88 | } | ||
89 | |||
84 | static struct clk_ops max77686_clk_ops = { | 90 | static struct clk_ops max77686_clk_ops = { |
85 | .prepare = max77686_clk_prepare, | 91 | .prepare = max77686_clk_prepare, |
86 | .unprepare = max77686_clk_unprepare, | 92 | .unprepare = max77686_clk_unprepare, |
87 | .is_prepared = max77686_clk_is_prepared, | 93 | .is_prepared = max77686_clk_is_prepared, |
94 | .recalc_rate = max77686_recalc_rate, | ||
88 | }; | 95 | }; |
89 | 96 | ||
90 | static struct clk_init_data max77686_clks_init[MAX77686_CLKS_NUM] = { | 97 | static struct clk_init_data max77686_clks_init[MAX77686_CLKS_NUM] = { |