[PATCH 2/2] ARM: nomadik: add the new clocks to the device tree
Bjorn Andersson
bjorn at kryo.se
Mon Jun 10 01:12:11 EDT 2013
While hacking on clock support for msm8960 the other day I did the
same thing; I figured that providing clocks with descriptive names
would be of great benefit while reading the dts.
I had my uart device setup with:
clocks = <&gsbi8_uart_clk>, <&gsbi8_p_clk>;
However, all currently present clock bindings follow the pattern
described by Arnd.
Following this pattern my uart would be setup as:
clocks = <&clks 42>, <&clks 44>;
Needless to say there is no way to make sense of this without
consulting the specific binding documentation. So, although your way
of setting up the clock binding is not the standard way I do prefer
it, but it comes with plenty extra nodes in the tree.
Regards,
Bjorn
On Sun, Jun 9, 2013 at 10:10 PM, Bjorn Andersson <bjorn at kryo.se> wrote:
> Linus,
>
> While hacking on clock support for msm8960 the other day I did the same
> thing; I figured that providing clocks with descriptive names would be of
> great benefit while reading the dts.
>
> I had my uart device setup with:
> clocks = <&gsbi8_uart_clk>, <&gsbi8_p_clk>;
>
> However, all currently present clock bindings seem to follow the pattern
> described by Arnd.
> Following this pattern my uart would be setup as:
> clocks = <&clks 42>, <&clks 44>;
>
> Needless to say there is no way to make sense of this without consulting the
> specific binding documentation. So, although your way of setting up the
> clock binding is not the standard way I do prefer it, but it comes with
> plenty extra nodes in the tree.
>
> Regards,
> Bjorn
>
>
> On Sun, Jun 9, 2013 at 7:21 AM, Arnd Bergmann <arnd at arndb.de> wrote:
>>
>> On Sunday 09 June 2013, Linus Walleij wrote:
>> > + /*
>> > + * IP AMBA bus clocks, driving the bus side of the
>> > + * peripheral clocking, clock gates.
>> > + */
>> > +
>> > + hclkdma0: hclkdma0 at 48M {
>> > + #clock-cells = <0>;
>> > + compatible = "st,nomadik-src-clock";
>> > + clock-id = <0>;
>> > + clocks = <&hclk>;
>> > + };
>> > + hclksmc: hclksmc at 48M {
>> > + #clock-cells = <0>;
>> > + compatible = "st,nomadik-src-clock";
>> > + clock-id = <1>;
>> > + clocks = <&hclk>;
>> > + };
>> > + hclksdram: hclksdram at 48M {
>> > + #clock-cells = <0>;
>> > + compatible = "st,nomadik-src-clock";
>> > + clock-id = <2>;
>> > + clocks = <&hclk>;
>> > + };
>> > + hclkdma1: hclkdma1 at 48M {
>> > + #clock-cells = <0>;
>> > + compatible = "st,nomadik-src-clock";
>> > + clock-id = <3>;
>> > + clocks = <&hclk>;
>> > + };
>>
>> Sorry if I'm being slow to understand how the clock bindings work, but if
>> you have 63 identical clocks that only differ in ther clock-id, can't you
>> just have a single DT node for them instead with #clock-cells=1 to pass
>> the
>> number from the device using it?
>>
>> Arnd
>>
>> _______________________________________________
>> linux-arm-kernel mailing list
>> linux-arm-kernel at lists.infradead.org
>> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
>
>
More information about the linux-arm-kernel
mailing list