summaryrefslogtreecommitdiffstats
path: root/drivers/clk/clk-composite.c
diff options
context:
space:
mode:
authorStephen Boyd <sboyd@codeaurora.org>2016-04-21 14:43:56 -0700
committerStephen Boyd <sboyd@codeaurora.org>2016-04-21 14:43:56 -0700
commite9471c4ecf8a50169216e7232e12b23761ce3d15 (patch)
treed18d1acd815887025a835674e5805a4fdc9dbb82 /drivers/clk/clk-composite.c
parent624b5ea624f368e8755304bc63a5ee5d0a899dcb (diff)
parent92a39d9043ba5ff98adb1c31491f00c7bea5466e (diff)
downloadlinux-e9471c4ecf8a50169216e7232e12b23761ce3d15.tar.gz
linux-e9471c4ecf8a50169216e7232e12b23761ce3d15.tar.bz2
linux-e9471c4ecf8a50169216e7232e12b23761ce3d15.zip
Merge branch 'clk-composite-unregister' into clk-next
* clk-composite-unregister: clk: composite: Add unregister function
Diffstat (limited to 'drivers/clk/clk-composite.c')
-rw-r--r--drivers/clk/clk-composite.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/clk/clk-composite.c b/drivers/clk/clk-composite.c
index 4d4b5aba397d..8aec4b3d5859 100644
--- a/drivers/clk/clk-composite.c
+++ b/drivers/clk/clk-composite.c
@@ -319,3 +319,18 @@ err:
kfree(composite);
return clk;
}
+
+void clk_unregister_composite(struct clk *clk)
+{
+ struct clk_composite *composite;
+ struct clk_hw *hw;
+
+ hw = __clk_get_hw(clk);
+ if (!hw)
+ return;
+
+ composite = to_clk_composite(hw);
+
+ clk_unregister(clk);
+ kfree(composite);
+}