summaryrefslogtreecommitdiffstats
path: root/include/linux/clk.h
Commit message (Collapse)AuthorAgeFilesLines
* clk: of: introduce of_clk_src_simple_getSascha Hauer2013-09-231-0/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: provide static inline wrappersSascha Hauer2013-07-231-1/+38
| | | | | | | So that drivers can use clk_* functions without having to ifdef them away. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: allow to instanciate clk mux without registering itLucas Stach2013-07-021-0/+4
| | | | | | | Allows to reuse clk mux code within other clocks. Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: allow to instanciate clk gate without registering itLucas Stach2013-07-021-0/+4
| | | | | | | Allows to reuse the clk gate code within other clocks. Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: add clock lookup from devicetreeLucas Stach2013-07-021-0/+33
| | | | | | | Taken from the Linuxkernel with some small adjustments for barebox. Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: add prototype for clk_is_enabledSascha Hauer2013-06-201-0/+1
| | | | | | | | On MXS we need to poll the busy bit when changing a clock rate, but only when the parent clocks are enabled. This exposes the already present function clk_is_enabled which is suitable for this job. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: gate: Add inverted gate supportSascha Hauer2013-06-201-0/+2
| | | | | | This adds support for gates which need 0 to enable. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: divider: Add onebased divider supportSascha Hauer2013-06-201-0/+15
| | | | | | | In some dividers the register value matches the divider value. This patch adds support for them. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: Add is_enabled callbackSascha Hauer2013-03-151-2/+2
| | | | | | | | | | | | | | | This allows us to better detect whether a clk is enabled or not. - If we can ask a clk, ask it. If it's enabled, go on and ask parents - If we can't ask it, but it can be enabled, depend on the enable_count. if it's positive, go on and ask parents - If we can't ask it and it cannot be enabled, assume it is enabled and ask parents. This makes the CLK_ALWAYS_ENABLED unnecessary, since the fixed clk now always returns 1 in its is_enabled callback. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'pu/clk' into for-next/clkSascha Hauer2012-12-071-0/+8
|\ | | | | | | | | Conflicts: include/linux/clk.h
| * clk: Add clk table based divider supportSascha Hauer2012-12-061-0/+10
| | | | | | | | | | | | For easy support of table based dividers. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | clk: add always enabled clocksAntony Pavlov2012-12-031-0/+3
|/ | | | | | | | | | | | | Current barebox clk framework allow disable any clock and there is no means to prevent that. But there are the clocks that can't be disabled by software at all. This patch allow registration of a clock immune to clk_disable(). Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: Add clk gate supportSascha Hauer2012-10-101-0/+2
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: initial common clk supportSascha Hauer2012-10-041-0/+42
| | | | | | | | | | | | | | | | | | | | | | This adds barebox common clk support loosely based on the Kernel common clk support. differences are: - barebox does not need prepare/unprepare - no parent rate propagation for set_rate - struct clk is not really encapsulated from the drivers Along with the clk support we have support for some basic clk building blocks: - clk-fixed - clk-fixed-factor - clk-mux - clk-divider clk-fixed and clk-fixed-factor are completely generic, clk-mux and clk-divider are currently the way i.MX muxes/dividers are implemented. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clock: Introduce clock framework from LinuxJean-Christophe PLAGNIOL-VILLARD2010-08-061-0/+158
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>