summaryrefslogtreecommitdiffstats
path: root/drivers/clk/clk-fixed.c
Commit message (Collapse)AuthorAgeFilesLines
* clk: No-op CLK_OF_DECLARE if not enabledAndrey Smirnov2017-03-301-2/+0
| | | | | | | | | Instead of wrapping each defenition of CLK_OF_DECLARE hook with preprocessor guards, change the definition of CLK_OF_DECLARE to expand into no-op if COMMON_CLK_OF_PROVIDER is not enabled. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: Make COMMON_CLK_OF_PROVIDER depend on OFTREEAndrey Smirnov2017-03-091-1/+1
| | | | | | | | | | | | | Make COMMON_CLK_OF_PROVIDER depend on OFTREE, this way checking for: defined(CONFIG_OFTREE) && defined(CONFIG_COMMON_CLK_OF_PROVIDER) can be simplified to just: defined(CONFIG_COMMON_CLK_OF_PROVIDER) Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* drivers/clk/clk-fixed.c: Fix sparse warningAlexander Shiyan2014-02-171-1/+1
| | | | | | | drivers/clk/clk-fixed.c:35:16: warning: symbol 'clk_fixed_ops' was not declared. Should it be static? Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: fixed: add DT init functionSebastian Hesselbarth2013-11-111-0/+23
| | | | | | | This adds a DT init function to clk-fixed and corresponding CLK_OF_DECLARE to put it into the DT clock provider table. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: Add is_enabled callbackSascha Hauer2013-03-151-1/+1
| | | | | | | | | | | | | | | 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>
* clk: use the 'CLK_ALWAYS_ENABLED' flag for clk-fixed by defaultAntony Pavlov2012-12-071-0/+1
| | | | | Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: initial common clk supportSascha Hauer2012-10-041-0/+55
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>