lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4FBB9A08.2050803@gmail.com>
Date:	Tue, 22 May 2012 08:52:08 -0500
From:	Rob Herring <robherring2@...il.com>
To:	Stephen Boyd <sboyd@...eaurora.org>
CC:	Shawn Guo <shawn.guo@...aro.org>,
	Mike Turquette <mturquette@...aro.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	Grant Likely <grant.likely@...retlab.ca>,
	"arm@...nel.org" <arm@...nel.org>,
	Shawn Guo <shawn.guo@...escale.com>,
	"linux-arm-kernel@...ts.infradead.org" 
	<linux-arm-kernel@...ts.infradead.org>,
	Saravana Kannan <skannan@...eaurora.org>
Subject: Re: [GIT PULL] DT clk binding support

On 05/21/2012 11:17 PM, Stephen Boyd wrote:
> On 05/21/12 19:15, Shawn Guo wrote:
>> On Mon, May 21, 2012 at 06:52:37PM -0500, Rob Herring wrote:
>>> As Grant states: "This proposed binding is only about one thing:
>>> attaching clock providers to clock consumers." This means you have to
>>> have at least a single provider and a single consumer defined in the DT.
>>>
>> I just read through Grant's comments over again.  I agree with the
>> statement which implicitly requires the clk provider defined in DT.
>> However, for some case, this provider in DT is just a skeleton which
>> is backed by clock driver where the provider is actually defined.
>>
>> Looking at Grant's comment below, the second option is also to match
>> the clock in driver just using name.  The only difference to my
>> proposal is the name here is given by the argument of phandle pointing
>> to that skeleton provider node.
>>
>> I'm fine with that.  So go ahead with your bindings.
>>
> 
> Can we do what the regulator framework has done and have a common
> binding of <connection_name>-clk = <&phandle>? Something like:
> 
>     core-clk = <&uart3_clk>
> 
> and then have clk_get() use the of node of the device passed in to find
> a property named %s-clk and find the clock with the matching phandle.

Sigh... That is what we had in previous versions from over a year ago
and we moved away from that approach. The current binding has been
reviewed multiple times in the last 6 months...

The current approach is aligned with how interrupts are handled (with
the addition of a phandle). I think not having per clock property names
is easier to parse and easier to document.

> This looks like it's trying to cover both the end consumers (uart uses
> uart3_clk) and the internal clock tree consumers (a crystal oscillator
> connects to a PLL or a mux has multiple parents). We can certainly use
> these bindings for muxes and internal parent-child relationships but I
> would prefer we use different bindings for consumer bindings that match
> what regulators do today.

The binding supports either defining every last internal clock or just
the leaf clocks. I took the former route on highbank since I don't have
a lot of clocks. If I was doing imx or omap for example, I'd probably
just define all the clock controller outputs.

Rob
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ