From: Esben Haabendal <esben@geanix.com>
To: Alexander Stein <alexander.stein@ew.tq-group.com>
Cc: Shawn Guo <shawnguo@kernel.org>, Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
linux-arm-kernel@lists.infradead.org,
Rasmus Villemoes <linux@rasmusvillemoes.dk>,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ARM: dts: ls1021a: add QUICC Engine node
Date: Fri, 31 May 2024 16:40:29 +0200 [thread overview]
Message-ID: <87ttiem4de.fsf@geanix.com> (raw)
In-Reply-To: <5987259.31r3eYUQgx@steina-w> (Alexander Stein's message of "Fri, 31 May 2024 15:09:05 +0200")
Alexander Stein <alexander.stein@ew.tq-group.com> writes:
> Hi Esben,
>
> Am Freitag, 31. Mai 2024, 14:20:02 CEST schrieb Esben Haabendal:
>> Alexander Stein <alexander.stein@ew.tq-group.com> writes:
>> >> + brg-frequency = <150000000>;
>> >> + bus-frequency = <300000000>;
>> >
>> > Mh, aren't these values depending on your actual RCW configuration?
>>
>> Yes, you are right. The QE bus-frequency comes from platform_clk which
>> is controlled by various bits in RCW and sys_ref_clk.
>>
>> So I guess it should be possible to derive bus-frequency from sysclk
>> clock-frequency attribute and RCW. But fsl,qe bus-frequency is a
>> required property...
>>
>> Max bus-frequency for LS1021A is 300 MHz. But it should be possible to
>> set it lower, although I suspect that many/most/everyone is running it
>> at 300 MHz.
>
> Thanks for confirmation. I'll let DT maintainer decide how to deal with this.
For reference.
The existing DTS with fsl,qe have the following bus-frequency property values:
arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi: bus-frequency = <200000000>
arch/powerpc/boot/dts/fsl/mpc8568si-post.dtsi: bus-frequency = <396000000>
arch/powerpc/boot/dts/fsl/mpc8569si-post.dtsi: bus-frequency = <0>
arch/powerpc/boot/dts/fsl/p1021si-post.dtsi: missing!
arch/powerpc/boot/dts/fsl/t1024si-post.dtsi: bus-frequency = <0>
arch/powerpc/boot/dts/fsl/t1040si-post.dtsi: missing!
arch/powerpc/boot/dts/kmeter1.dts: bus-frequency = <0>
arch/powerpc/boot/dts/mpc836x_rdk.dts: bus-frequency = <0>
arch/powerpc/boot/dts/mpc832x_rdb.dts: bus-frequency = <198000000>
The 3 non-zero values are most likely also not guaranteed by SoC design
to always be the right values. But I haven't checked.
>> >> + fsl,qe-num-riscs = <1>;
>> >> + fsl,qe-num-snums = <28>;
>> >
>> > Current bindings defines:
>> >> fsl,qe-snums: This property has to be specified as '/bits/ 8' value,
>> >> defining the array of serial number (SNUM) values for the virtual
>> >> threads.
>> >
>> > So '/bits/ 8' is missing.
>>
>> Ok, so you want me to add an array for fs,qe-snums attribute?
>> None of the existing fsl,qe devices has a fsl,qe-snums.
>> And qe_snums_init() has a fallback, so I don't think it is correct to
>> specify fsl,qe-snums to be a required property in the bindings. It
>> should be listed as optional.
>
> fsl,qe-num-snums is a deprecated property, so IMHO the replacement
> fsl,qe-snums should be used instead for new device tree entries.
> qe_snums_init() supporting 'fsl,qe-num-snums' is just to support
> "legacy bindings" as stated in the comment.
Figuring out the correct array values for fsl,qe-snums for ls1021a is
not so easy. It is not so clear from the reference manual, what it
should be. And the default array used for fsl,qe-num-snums = <28> does
not look right in any way, but seems to work.
It would not feel right to just copy those values and put into DTS, as
it would imply that the values are truly a correct description for the
LS1021A hardware.
>>
>> >> + };
>> >> +
>> >> + muram@10000 {
>> >> + #address-cells = <1>;
>> >> + #size-cells = <1>;
>> >> + compatible = "fsl,qe-muram", "fsl,cpm-muram";
>> >> + ranges = <0x0 0x10000 0x6000>;
>> >
>> > Node address but no 'reg' property? I have no idea if this is okay.
>> > Also compatible (and possibly reg) first.
>>
>> It is done in the same way for all existing fsl,qe-muram devices. So if
>> it is not okay, a tree-wide fixup would be in place.
>
> I can't finally say if this is okay, but at least the compatible shall be
> listed first.
Done.
/Esben
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2024-05-31 14:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-30 14:22 [PATCH] ARM: dts: ls1021a: add QUICC Engine node Esben Haabendal
2024-05-31 6:32 ` Alexander Stein
2024-05-31 12:20 ` Esben Haabendal
2024-05-31 13:09 ` Alexander Stein
2024-05-31 14:40 ` Esben Haabendal [this message]
2024-06-04 11:38 ` Alexander Stein
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ttiem4de.fsf@geanix.com \
--to=esben@geanix.com \
--cc=alexander.stein@ew.tq-group.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@rasmusvillemoes.dk \
--cc=robh@kernel.org \
--cc=shawnguo@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).