diff options
author | Martin Fuzzey <mfuzzey@parkeon.com> | 2012-11-22 20:15:05 +0100 |
---|---|---|
committer | Mike Turquette <mturquette@linaro.org> | 2012-11-26 11:14:45 -0800 |
commit | 1f61e5f143b578606389887887af549bc5554353 (patch) | |
tree | b49a23716e8896eac027f2730a4cf0d94983ec4f /drivers/clk/ux500 | |
parent | 45228ef32240957b1536fbba1ca12377cb2e587c (diff) | |
download | lwn-1f61e5f143b578606389887887af549bc5554353.tar.gz lwn-1f61e5f143b578606389887887af549bc5554353.zip |
clk: clock multiplexers may register out of order
When a clock, C is initialised any orphan clocks listing C as
a possible parent are reparented to it regardless of the
parent requested by the orphan's get_parent() operation.
This means that multiplexers registered before their parents
are reparented to the first parent subsequently declared,
regardless of the selection made by the hardware registers.
For example:
static const char *sel[] = { "srcA", "srcB", "dummy", "srcC" };
child = clk_register_mux(NULL, "child", sel, ARRAY_SIZE(sel), ...);
clk_register_fixed(NULL, "dummy", ...);
clk_register_fixed(NULL, "srcA", ...);
clk_register_fixed(NULL, "srcB", ...);
clk_register_fixed(NULL, "srcC", ...);
Causes child's parent to always be "dummy".
To fix this, when an orphanned clock has a get_parent() operation,
only reparent to the clock indicated by get_parent().
Signed-off-by: Martin Fuzzey <mfuzzey@parkeon.com>
Signed-off-by: Mike Turquette <mturquette@linaro.org>
[mturquette@linaro.org: improve $SUBJECT]
Diffstat (limited to 'drivers/clk/ux500')
0 files changed, 0 insertions, 0 deletions