public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Dragan Simic <dsimic@manjaro.org>
To: Anand Moon <linux.amoon@gmail.com>
Cc: Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Heiko Stuebner <heiko@sntech.de>,
	devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v1] arm64: dts: rockchip: Add cache information to the Rockchip RK3566 and RK3568 SoC
Date: Mon, 26 Feb 2024 20:09:26 +0100	[thread overview]
Message-ID: <8ceea100f2ef7cce296943ce1397161a@manjaro.org> (raw)
In-Reply-To: <20240226182310.4032-1-linux.amoon@gmail.com>

Hello Anand,

On 2024-02-26 19:23, Anand Moon wrote:
> As per RK3568 Datasheet and TRM add missing cache information to
> the Rockchip RK3566 and RK3568 SoC.
> 
> - Each Cortex-A55 core has 32KB of L1 instruction cache available and
> 	32KB of L1 data cache available with ECC.
> - Along with 512KB Unified L3 cache with ECC.
> 
> With adding instruction cache and data cache and a write buffer to
> reduce the effect of main memory bandwidth and latency on data
> access performance.
> 
> Signed-off-by: Anand Moon <linux.amoon@gmail.com>

I was about to send my own patch that adds the same missing cache
information, so please allow me to describe the proposed way to move
forward.

The way I see it, your commit summary and description need a rather
complete rewrite, to be more readable, more accurate, and to avoid
including an irrelevant (and slightly misleading) description of the
general role of caches.

Also, the changes to the dtsi file would benefit from small touch-ups
here and there, for improved consistency, etc.

With all that in mind, I propose that you withdraw your patch and let
me send my patch that will addresses all these issues, of course with
a proper tag that lists you as a co-developer.  I think that would
save us a fair amount of time going back and forth.

I hope you agree.


> ---
> [0] 
> http://www.rock-chips.com/uploads/pdf/2022.8.26/191/RK3568%20Brief%20Datasheet.pdf
> [1] 
> https://dl.radxa.com/rock3/docs/hw/datasheet/Rockchip%20RK3568%20TRM%20Part1%20V1.1-20210301.pdf
> ---
>  arch/arm64/boot/dts/rockchip/rk356x.dtsi | 37 ++++++++++++++++++++++++
>  1 file changed, 37 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> index c19c0f1b3778..49235efefb6b 100644
> --- a/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> +++ b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> @@ -56,6 +56,13 @@ cpu0: cpu@0 {
>  			clocks = <&scmi_clk 0>;
>  			#cooling-cells = <2>;
>  			enable-method = "psci";
> +			d-cache-line-size = <32>;
> +			d-cache-size = <0x8000>;
> +			d-cache-sets = <32>;
> +			i-cache-line-size = <32>;
> +			i-cache-size = <0x8000>;
> +			i-cache-sets = <32>;
> +			next-level-cache = <&l2>;
>  			operating-points-v2 = <&cpu0_opp_table>;
>  		};
> 
> @@ -65,6 +72,13 @@ cpu1: cpu@100 {
>  			reg = <0x0 0x100>;
>  			#cooling-cells = <2>;
>  			enable-method = "psci";
> +			d-cache-line-size = <32>;
> +			d-cache-size = <0x8000>;
> +			d-cache-sets = <32>;
> +			i-cache-line-size = <32>;
> +			i-cache-size = <0x8000>;
> +			i-cache-sets = <32>;
> +			next-level-cache = <&l2>;
>  			operating-points-v2 = <&cpu0_opp_table>;
>  		};
> 
> @@ -74,6 +88,13 @@ cpu2: cpu@200 {
>  			reg = <0x0 0x200>;
>  			#cooling-cells = <2>;
>  			enable-method = "psci";
> +			d-cache-line-size = <32>;
> +			d-cache-size = <0x8000>;
> +			d-cache-sets = <32>;
> +			i-cache-line-size = <32>;
> +			i-cache-size = <0x8000>;
> +			i-cache-sets = <32>;
> +			next-level-cache = <&l2>;
>  			operating-points-v2 = <&cpu0_opp_table>;
>  		};
> 
> @@ -83,8 +104,24 @@ cpu3: cpu@300 {
>  			reg = <0x0 0x300>;
>  			#cooling-cells = <2>;
>  			enable-method = "psci";
> +			d-cache-line-size = <32>;
> +			d-cache-size = <0x8000>;
> +			d-cache-sets = <32>;
> +			i-cache-line-size = <32>;
> +			i-cache-size = <0x8000>;
> +			i-cache-sets = <32>;
> +			next-level-cache = <&l2>;
>  			operating-points-v2 = <&cpu0_opp_table>;
>  		};
> +
> +		l2: l2-cache0 {
> +			compatible = "cache";
> +			cache-level = <3>;
> +			cache-unified;
> +			cache-size = <0x7d000>; /* L3. 512 KB */
> +			cache-line-size = <64>;
> +			cache-sets = <512>;
> +		};
>  	};
> 
>  	cpu0_opp_table: opp-table-0 {

  reply	other threads:[~2024-02-26 19:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-26 18:23 [PATCH v1] arm64: dts: rockchip: Add cache information to the Rockchip RK3566 and RK3568 SoC Anand Moon
2024-02-26 19:09 ` Dragan Simic [this message]
2024-02-27 12:49   ` Anand Moon
2024-02-27 14:58     ` Dragan Simic
2024-02-28 10:42       ` Dragan Simic
2024-02-28 17:50         ` Dragan Simic
2024-03-03 19:10           ` Dragan Simic

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=8ceea100f2ef7cce296943ce1397161a@manjaro.org \
    --to=dsimic@manjaro.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=heiko@sntech.de \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=linux.amoon@gmail.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