diff options
author | Andrew Lunn <andrew@lunn.ch> | 2011-12-15 11:15:07 +0400 |
---|---|---|
committer | Mike Turquette <mturquette@linaro.org> | 2012-05-09 03:33:39 +0400 |
commit | 2f129bf4aab684bef1e82e747b709a5025ecb698 (patch) | |
tree | 4be6e04fc306cfad25b3b86f831cd4d462c10f44 /arch/arm/mach-orion5x | |
parent | f0948f59dbc8e725a96ba16da666e8f5cdd43ba8 (diff) | |
download | linux-2f129bf4aab684bef1e82e747b709a5025ecb698.tar.xz |
ARM: Orion: Add clocks using the generic clk infrastructure.
Add tclk as a fixed rate clock for all platforms. In addition, on
kirkwood, add a gated clock for most of the clocks which can be gated.
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Tested-by: Jamie Lentin <jm@lentin.co.uk>
[mturquette@linaro.org: removed redundant CLKDEV_LOOKUP from Kconfig]
[mturquette@linaro.org: removed redundant clk.h from mach-dove/common.c]
Signed-off-by: Mike Turquette <mturquette@linaro.org>
Diffstat (limited to 'arch/arm/mach-orion5x')
-rw-r--r-- | arch/arm/mach-orion5x/common.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/arch/arm/mach-orion5x/common.c b/arch/arm/mach-orion5x/common.c index 24481666d2cd..81660522c6b4 100644 --- a/arch/arm/mach-orion5x/common.c +++ b/arch/arm/mach-orion5x/common.c @@ -18,6 +18,7 @@ #include <linux/mv643xx_i2c.h> #include <linux/ata_platform.h> #include <linux/delay.h> +#include <linux/clk-provider.h> #include <net/dsa.h> #include <asm/page.h> #include <asm/setup.h> @@ -70,6 +71,17 @@ void __init orion5x_map_io(void) /***************************************************************************** + * CLK tree + ****************************************************************************/ +static struct clk *tclk; + +static void __init clk_init(void) +{ + tclk = clk_register_fixed_rate(NULL, "tclk", NULL, CLK_IS_ROOT, + orion5x_tclk); +} + +/***************************************************************************** * EHCI0 ****************************************************************************/ void __init orion5x_ehci0_init(void) @@ -276,6 +288,9 @@ void __init orion5x_init(void) */ orion5x_setup_cpu_mbus_bridge(); + /* Setup root of clk tree */ + clk_init(); + /* * Don't issue "Wait for Interrupt" instruction if we are * running on D0 5281 silicon. |