From: Vignesh Raghavendra <vigneshr@ti.com>
To: Matthias Schiffer <matthias.schiffer@ew.tq-group.com>,
Nishanth Menon <nm@ti.com>, Tero Kristo <kristo@kernel.org>
Cc: Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
<linux-arm-kernel@lists.infradead.org>,
<devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] arm64: dts: ti: k3-am64-mcu: explicitly assign UART base clock rates
Date: Fri, 15 Apr 2022 13:10:51 +0530 [thread overview]
Message-ID: <83d5773d-d699-59e1-4d7d-e1ce85286702@ti.com> (raw)
In-Reply-To: <20220411121108.63436-1-matthias.schiffer@ew.tq-group.com>
On 11/04/22 5:41 pm, Matthias Schiffer wrote:
> We found that (at least some versions of) the sci-fw do not assign the
> expected base clock rate of 48 MHz for the UARTs in the MCU domain,
> leading to incorrect baud rates when used from Linux. Use
> assigned-clock-rates to fix this issue.
>
> Fixes: 8abae9389bdb ("arm64: dts: ti: Add support for AM642 SoC")
> Signed-off-by: Matthias Schiffer <matthias.schiffer@ew.tq-group.com>
> ---
>
> I'm not sure if this is the best fix. Should the clock-frequency
> property simply be removed, so the frequency is queried from the clock
> driver instead?
>
I think its better to drop clock-frequency. Driver can setup DLL/DLH to
get appropriate baudrate as per frequency queried from clock driver
> arch/arm64/boot/dts/ti/k3-am64-mcu.dtsi | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/arch/arm64/boot/dts/ti/k3-am64-mcu.dtsi b/arch/arm64/boot/dts/ti/k3-am64-mcu.dtsi
> index 2bb5c9ff172c..69b0f127eea5 100644
> --- a/arch/arm64/boot/dts/ti/k3-am64-mcu.dtsi
> +++ b/arch/arm64/boot/dts/ti/k3-am64-mcu.dtsi
> @@ -15,6 +15,8 @@ mcu_uart0: serial@4a00000 {
> power-domains = <&k3_pds 149 TI_SCI_PD_EXCLUSIVE>;
> clocks = <&k3_clks 149 0>;
> clock-names = "fclk";
> + assigned-clocks = <&k3_clks 149 0>;
> + assigned-clock-rates = <48000000>;
> };
>
> mcu_uart1: serial@4a10000 {
> @@ -26,6 +28,8 @@ mcu_uart1: serial@4a10000 {
> power-domains = <&k3_pds 160 TI_SCI_PD_EXCLUSIVE>;
> clocks = <&k3_clks 160 0>;
> clock-names = "fclk";
> + assigned-clocks = <&k3_clks 160 0>;
> + assigned-clock-rates = <48000000>;
> };
>
> mcu_i2c0: i2c@4900000 {
prev parent reply other threads:[~2022-04-15 7:41 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-11 12:11 Matthias Schiffer
2022-04-15 7:40 ` Vignesh Raghavendra [this message]
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=83d5773d-d699-59e1-4d7d-e1ce85286702@ti.com \
--to=vigneshr@ti.com \
--cc=devicetree@vger.kernel.org \
--cc=kristo@kernel.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matthias.schiffer@ew.tq-group.com \
--cc=nm@ti.com \
--cc=robh+dt@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
all inboxes | Powered by JetHome®