From: Mina Hui-Min Chou <minachou@andestech.com>
To: <pjw@kernel.org>, <palmer@dabbelt.com>, <aou@eecs.berkeley.edu>,
<alex@ghiti.fr>, <conor@kernel.org>, <jic23@kernel.org>,
<robh@kernel.org>, <krzk+dt@kernel.org>, <conor+dt@kernel.org>,
<geert+renesas@glider.be>, <magnus.damm@gmail.com>,
<prabhakar.mahadev-lad.rj@bp.renesas.com>,
<linux-riscv@lists.infradead.org>, <devicetree@vger.kernel.org>,
<linux-renesas-soc@vger.kernel.org>,
<linux-kernel@vger.kernel.org>
Cc: <randolph@andestech.com>, <cyyang772@andestech.com>,
<tim609@andestech.com>, <minachou@andestech.com>,
<az70021@gmail.com>
Subject: [PATCH v2 12/19] dt-bindings: cache: andestech: update schema for generic LLC support
Date: Fri, 13 Nov 2026 15:11:36 +0800 [thread overview]
Message-ID: <20261113071143.1446167-13-minachou@andestech.com> (raw)
In-Reply-To: <20261113071143.1446167-1-minachou@andestech.com>
The last level cache controller of Andes cores is not specific to
AX45MP. Other Andes cores, such as the A27L2, use the same controller
with the same register interface, but the binding only accepts
andestech,ax45mp-cache. Add andestech,llcache for them, and describe
the binding as an Andes last level cache rather than an AX45MP L2
cache.
The cache-level, cache-sets and cache-size constraints describe the
AX45MP L2 cache, so apply them to andestech,ax45mp-cache only. The LLC
of other Andes cores can be level 3 and have other geometries, so
allow cache-level 3 and require cache-sets only for AX45MP. Match
renesas,r9a07g043f-ax45mp-cache explicitly instead of through the else
branch, which would otherwise also apply to andestech,llcache.
Also add an example for andestech,llcache, and add myself as a
maintainer of the binding.
Signed-off-by: Mina Hui-Min Chou <minachou@andestech.com>
---
.../cache/andestech,ax45mp-cache.yaml | 71 ++++++++++++++-----
1 file changed, 54 insertions(+), 17 deletions(-)
diff --git a/Documentation/devicetree/bindings/cache/andestech,ax45mp-cache.yaml b/Documentation/devicetree/bindings/cache/andestech,ax45mp-cache.yaml
index b135ffa4ab6b..da9688cc95f7 100644
--- a/Documentation/devicetree/bindings/cache/andestech,ax45mp-cache.yaml
+++ b/Documentation/devicetree/bindings/cache/andestech,ax45mp-cache.yaml
@@ -5,14 +5,15 @@
$id: http://devicetree.org/schemas/cache/andestech,ax45mp-cache.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
-title: Andestech AX45MP L2 Cache Controller
+title: Andestech Last Level Cache Controller
maintainers:
- Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
+ - Mina Hui-Min Chou <minachou@andestech.com>
description:
- A level-2 cache (L2C) is used to improve the system performance by providing
- a large amount of cache line entries and reasonable access delays. The L2C
+ A last level cache (LLC) is used to improve the system performance by providing
+ a large amount of cache line entries and reasonable access delays. The LLC
is shared between cores, and a non-inclusive non-exclusive policy is used.
select:
@@ -21,18 +22,23 @@ select:
contains:
enum:
- andestech,ax45mp-cache
+ - andestech,llcache
required:
- compatible
properties:
compatible:
- items:
- - enum:
- - andestech,qilai-ax45mp-cache
- - renesas,r9a07g043f-ax45mp-cache
- - const: andestech,ax45mp-cache
- - const: cache
+ oneOf:
+ - items:
+ - enum:
+ - andestech,qilai-ax45mp-cache
+ - renesas,r9a07g043f-ax45mp-cache
+ - const: andestech,ax45mp-cache
+ - const: cache
+ - items:
+ - const: andestech,llcache
+ - const: cache
reg:
maxItems: 1
@@ -44,13 +50,11 @@ properties:
const: 64
cache-level:
- const: 2
+ enum: [2, 3]
- cache-sets:
- enum: [1024, 2048]
+ cache-sets: true
- cache-size:
- enum: [131072, 262144, 524288, 1048576, 2097152]
+ cache-size: true
cache-unified: true
@@ -64,7 +68,6 @@ required:
- interrupts
- cache-line-size
- cache-level
- - cache-sets
- cache-size
- cache-unified
@@ -73,15 +76,36 @@ allOf:
properties:
compatible:
contains:
- const: andestech,qilai-ax45mp-cache
+ const: andestech,ax45mp-cache
+ then:
+ properties:
+ cache-level:
+ const: 2
+ cache-sets:
+ enum: [1024, 2048]
+ cache-size:
+ enum: [131072, 262144, 524288, 1048576, 2097152]
+ required:
+ - cache-sets
+ - if:
+ properties:
+ compatible:
+ contains:
+ const: andestech,qilai-ax45mp-cache
then:
properties:
cache-sets:
const: 2048
cache-size:
const: 2097152
- else:
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ const: renesas,r9a07g043f-ax45mp-cache
+ then:
properties:
cache-sets:
const: 1024
@@ -101,3 +125,16 @@ examples:
cache-size = <262144>;
cache-unified;
};
+
+ - |
+ #include <dt-bindings/interrupt-controller/irq.h>
+
+ cache-controller@e0500000 {
+ compatible = "andestech,llcache", "cache";
+ reg = <0xe0500000 0x10000>;
+ interrupts = <16 IRQ_TYPE_LEVEL_HIGH>;
+ cache-line-size = <64>;
+ cache-level = <2>;
+ cache-size = <262144>;
+ cache-unified;
+ };
--
2.34.1
next prev parent reply other threads:[~2026-11-13 7:13 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-13 7:11 [PATCH v2 00/19] riscv: andes: make the LLC driver and cache errata generic Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 01/19] cache: ax45mp_cache: use __initconst for ax45mp_cmo_ops Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 02/19] cache: ax45mp_cache: rename AX45MP-specific identifiers to generic ANDES Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 03/19] cache: ax45mp_cache: rename L2 identifiers to LLC Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 04/19] cache: ax45mp_cache: add shared header for Andes CSRs Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 05/19] cache: ax45mp_cache: standardize macro naming for LLC and L1D registers Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 06/19] cache: ax45mp_cache: rename ax45mp_cache.c to andes_llcache.c Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 07/19] cache: andes_llcache: clean up cache inv/wback functions Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 08/19] cache: andes_llcache: use u32 and fix the cache-line-size error message Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 09/19] cache: andes_llcache: write the full physical address for CCTL Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 10/19] cache: andes_llcache: register cache ops only when the errata needs them Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 11/19] cache: andes_llcache: use the hart ID to index the CCTL registers Mina Hui-Min Chou
2026-11-13 7:11 ` Mina Hui-Min Chou [this message]
2026-11-13 7:11 ` [PATCH v2 13/19] dt-bindings: cache: rename andestech,ax45mp-cache to andestech,llcache Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 14/19] cache: andes_llcache: add generic andestech,llcache compatible Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 15/19] MAINTAINERS: Add maintainer for Andes cache driver Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 16/19] riscv: errata: andes: allow ERRATA_ANDES_CMO on all Andes SoCs Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 17/19] riscv: errata: andes: generalize cache errata for Andes cores Mina Hui-Min Chou
2026-11-13 7:11 ` [PATCH v2 18/19] riscv: errata: andes: limit the IOCP workaround to RZ/Five Mina Hui-Min Chou
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=20261113071143.1446167-13-minachou@andestech.com \
--to=minachou@andestech.com \
--cc=alex@ghiti.fr \
--cc=aou@eecs.berkeley.edu \
--cc=az70021@gmail.com \
--cc=conor+dt@kernel.org \
--cc=conor@kernel.org \
--cc=cyyang772@andestech.com \
--cc=devicetree@vger.kernel.org \
--cc=geert+renesas@glider.be \
--cc=jic23@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=magnus.damm@gmail.com \
--cc=palmer@dabbelt.com \
--cc=pjw@kernel.org \
--cc=prabhakar.mahadev-lad.rj@bp.renesas.com \
--cc=randolph@andestech.com \
--cc=robh@kernel.org \
--cc=tim609@andestech.com \
/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®