From: Nicolas Ferre Date: Thu, 9 Sep 2010 17:58:23 +0000 (+0200) Subject: AT91: clock: peripheral clocks can have other parent than mck X-Git-Tag: MMI-PSA29.97-13-9~22332^2~4 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5afddee415c829704d3a91031ae634008bc332e9;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git 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 Acked-by: Jean-Christophe PLAGNIOL-VILLARD Acked-by: Andrew Victor --- 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); }