diff options
author | Mike Turquette <mturquette@linaro.org> | 2014-02-24 19:08:41 -0500 |
---|---|---|
committer | Mike Turquette <mturquette@linaro.org> | 2014-02-24 20:13:55 -0500 |
commit | 86bcfa2e87c42b8af77188e7a939e952199d4da1 (patch) | |
tree | 6a0e9bab07e4eb9a930a3a9b782b6a957f2ab3b4 /include/linux/clk.h | |
parent | 05135b4cb4e20a3f36f09e7e5c798eac30c49c21 (diff) |
clk: add pr_debug & kerneldoc around clk notifiers
Both the pr_err and the additional kerneldoc aim to help when debugging
errors thrown from within a clock rate-change notifier callback.
Reported-by: Sören Brinkmann <soren.brinkmann@xilinx.com>
Acked-by: Sören Brinkmann <soren.brinkmann@xilinx.com>
Signed-off-by: Mike Turquette <mturquette@linaro.org>
Diffstat (limited to 'include/linux/clk.h')
-rw-r--r-- | include/linux/clk.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/include/linux/clk.h b/include/linux/clk.h index 0dd91148165e..fb5e097d8f72 100644 --- a/include/linux/clk.h +++ b/include/linux/clk.h | |||
@@ -78,8 +78,22 @@ struct clk_notifier_data { | |||
78 | unsigned long new_rate; | 78 | unsigned long new_rate; |
79 | }; | 79 | }; |
80 | 80 | ||
81 | /** | ||
82 | * clk_notifier_register: register a clock rate-change notifier callback | ||
83 | * @clk: clock whose rate we are interested in | ||
84 | * @nb: notifier block with callback function pointer | ||
85 | * | ||
86 | * ProTip: debugging across notifier chains can be frustrating. Make sure that | ||
87 | * your notifier callback function prints a nice big warning in case of | ||
88 | * failure. | ||
89 | */ | ||
81 | int clk_notifier_register(struct clk *clk, struct notifier_block *nb); | 90 | int clk_notifier_register(struct clk *clk, struct notifier_block *nb); |
82 | 91 | ||
92 | /** | ||
93 | * clk_notifier_unregister: unregister a clock rate-change notifier callback | ||
94 | * @clk: clock whose rate we are no longer interested in | ||
95 | * @nb: notifier block which will be unregistered | ||
96 | */ | ||
83 | int clk_notifier_unregister(struct clk *clk, struct notifier_block *nb); | 97 | int clk_notifier_unregister(struct clk *clk, struct notifier_block *nb); |
84 | 98 | ||
85 | /** | 99 | /** |