summaryrefslogtreecommitdiffstats
path: root/arch/blackfin
diff options
context:
space:
mode:
authorSylwester Nawrocki <s.nawrocki@samsung.com>2013-08-24 20:10:41 +0200
committerSylwester Nawrocki <s.nawrocki@samsung.com>2013-12-04 17:19:44 +0100
commitac2df527fb407b61f9c812a99035b62a75a77d6d (patch)
tree87b9b90703c654b5359749bd48eb87bb5dd0b118 /arch/blackfin
parent3a3d2b0551d79ef476ef57424beeb8f68789fbcd (diff)
downloadop-kernel-dev-ac2df527fb407b61f9c812a99035b62a75a77d6d.zip
op-kernel-dev-ac2df527fb407b61f9c812a99035b62a75a77d6d.tar.gz
clk: Add common __clk_get(), __clk_put() implementations
This patch adds common __clk_get(), __clk_put() clkdev helpers that replace their platform specific counterparts when the common clock API is used. The owner module pointer field is added to struct clk so a reference to the clock supplier module can be taken by the clock consumers. The owner module is assigned while the clock is being registered, in functions _clk_register() and __clk_register(). Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/blackfin')
-rw-r--r--arch/blackfin/include/asm/clkdev.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/blackfin/include/asm/clkdev.h b/arch/blackfin/include/asm/clkdev.h
index 9053bed..7ac2436 100644
--- a/arch/blackfin/include/asm/clkdev.h
+++ b/arch/blackfin/include/asm/clkdev.h
@@ -8,7 +8,9 @@ static inline struct clk_lookup_alloc *__clkdev_alloc(size_t size)
return kzalloc(size, GFP_KERNEL);
}
+#ifndef CONFIG_COMMON_CLK
#define __clk_put(clk)
#define __clk_get(clk) ({ 1; })
+#endif
#endif
OpenPOWER on IntegriCloud