summaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
authorNicolas Ferre <nicolas.ferre@atmel.com>2010-09-09 19:58:23 +0200
committerNicolas Ferre <nicolas.ferre@atmel.com>2010-09-09 20:13:23 +0200
commit5afddee415c829704d3a91031ae634008bc332e9 (patch)
tree40dbd82e8596a03a07733ca796442da91ba0844b /arch/arm
parentAT91: change dma resource index (diff)
downloadlinux-5afddee415c829704d3a91031ae634008bc332e9.tar.xz
linux-5afddee415c829704d3a91031ae634008bc332e9.zip
AT91: clock: peripheral clocks can have other parent than mck
While registering clock allow to set parent clock other than mck. It is useful for clocks than can be seen as child clock of a peripheral. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Acked-by: Andrew Victor <linux@maxim.org.za>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mach-at91/clock.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/arm/mach-at91/clock.c b/arch/arm/mach-at91/clock.c
index 7f7da439341f..7525cee3983f 100644
--- a/arch/arm/mach-at91/clock.c
+++ b/arch/arm/mach-at91/clock.c
@@ -501,7 +501,8 @@ postcore_initcall(at91_clk_debugfs_init);
int __init clk_register(struct clk *clk)
{
if (clk_is_peripheral(clk)) {
- clk->parent = &mck;
+ if (!clk->parent)
+ clk->parent = &mck;
clk->mode = pmc_periph_mode;
list_add_tail(&clk->node, &clocks);
}