aboutsummaryrefslogtreecommitdiff
path: root/include/clk.h
diff options
context:
space:
mode:
authorSekhar Nori2019-08-01 19:12:55 +0530
committerTom Rini2019-08-12 13:33:38 -0400
commitacbb7cd4d34caec36ff6d044a8f55325fa27459f (patch)
tree5e6a7ce2f65e365a906d16b702f9493535811242 /include/clk.h
parent71cd80af863945e81f468c22e5e1afb06eba75cd (diff)
clk: add support for clk_is_match()
Add support for clk_is_match() which is required to know if two clock pointers point to the same exact physical clock. Also add a unit test for the new API. Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Diffstat (limited to 'include/clk.h')
-rw-r--r--include/clk.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/clk.h b/include/clk.h
index 2ebc905e04b..3ca2796b577 100644
--- a/include/clk.h
+++ b/include/clk.h
@@ -333,6 +333,18 @@ int clk_disable(struct clk *clk);
*/
int clk_disable_bulk(struct clk_bulk *bulk);
+/**
+ * clk_is_match - check if two clk's point to the same hardware clock
+ * @p: clk compared against q
+ * @q: clk compared against p
+ *
+ * Returns true if the two struct clk pointers both point to the same hardware
+ * clock node.
+ *
+ * Returns false otherwise. Note that two NULL clks are treated as matching.
+ */
+bool clk_is_match(const struct clk *p, const struct clk *q);
+
int soc_clk_dump(void);
/**