[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <155025643198.115909.9355230466710329335@swboyd.mtv.corp.google.com>
Date: Fri, 15 Feb 2019 10:47:11 -0800
From: Stephen Boyd <sboyd@...nel.org>
To: Jeffrey Hugo <jhugo@...eaurora.org>,
Michael Turquette <mturquette@...libre.com>
Cc: linux-kernel@...r.kernel.org, linux-clk@...r.kernel.org,
Miquel Raynal <miquel.raynal@...tlin.com>,
Jerome Brunet <jbrunet@...libre.com>,
Russell King <linux@...linux.org.uk>
Subject: Re: [PATCH 2/9] clk: Introduce get_parent_hw clk op
Quoting Jeffrey Hugo (2019-02-11 08:09:00)
> On 1/28/2019 11:10 PM, Stephen Boyd wrote:
>
> > +static int clk_init_parent(struct clk_core *core)
> > +{
> > + core->parent = __clk_init_parent(core, true);
> > + if (IS_ERR(core->parent))
> > + return PTR_ERR(core->parent);
> > +
> > + /*
> > + * Populate core->parent if parent has already been clk_core_init'd. If
> > + * parent has not yet been clk_core_init'd then place clk in the orphan
> > + * list. If clk doesn't have any parents then place it in the root
> > + * clk list.
> > + *
> > + * Every time a new clk is clk_init'd then we walk the list of orphan
> > + * clocks and re-parent any that are children of the clock currently
> > + * being clk_init'd.
> > + */
> > + if (core->parent) {
> > + hlist_add_head(&core->child_node,
> > + &core->parent->children);
> > + core->orphan = core->parent->orphan;
> > + } else if (!core->num_parents) {
> > + hlist_add_head(&core->child_node, &clk_root_list);
> > + core->orphan = false;
> > + } else {
> > + hlist_add_head(&core->child_node, &clk_orphan_list);
>
> Missing "core->orphan = true;"?
> The snippet below had that line. Its not clear why it appears to be
> dropped here.
>
Hmm. Weird. I think I may have been getting ahead of myself and moving
the orphan updating code into __clk_init_parent(). I can't remember why
though, so I guess I'll go all the way and move it all into
__clk_init_parent() now. Thanks for pointing it out.
Powered by blists - more mailing lists