From: Drew Fustini <dfustini@baylibre.com>
To: linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org,
"Palmer Dabbelt" <palmer@dabbelt.com>,
"Paul Walmsley" <paul.walmsley@sifive.com>,
"Conor Dooley" <conor.dooley@microchip.com>,
"Ved Shanbhogue" <ved@rivosinc.com>,
"Kornel Dulęba" <mindal@semihalf.com>,
"Adrien Ricciardi" <aricciardi@baylibre.com>,
"Nicolas Pitre" <npitre@baylibre.com>,
"Fenghua Yu" <fenghua.yu@intel.com>,
"Reinette Chatre" <reinette.chatre@intel.com>,
"Babu Moger" <babu.moger@amd.com>,
"Peter Newman" <peternewman@google.com>,
x86@kernel.org, "Rob Herring" <robh+dt@kernel.org>,
"James Morse" <james.morse@arm.com>
Cc: Drew Fustini <dfustini@baylibre.com>
Subject: [RFC PATCH 20/21] DO_NOT_MERGE riscv: dts: qemu: add cbqri-capable controllers
Date: Wed, 19 Apr 2023 04:11:10 -0700 [thread overview]
Message-ID: <20230419111111.477118-21-dfustini@baylibre.com> (raw)
In-Reply-To: <20230419111111.477118-1-dfustini@baylibre.com>
Add nodes to for CBQRI-capable cache and memory controllers.
This is necessary as the qemu branch riscv-cbqri-rfc (based on
v8.0.0-rc4) does not yet support generating a dtb with the nodes and
properties needed for CBQRI controllers.
Thus, an external dtb (qemu-virt-cbqri.dtb) built by Linux is used when
invoking qemu-system-riscv64:
qemu-system-riscv64 \
-M virt \
-nographic \
-smp 8 \
-bios output/images/fw_jump.elf \
-kernel ${LINUX}/arch/riscv/boot/Image \
-dtb ${LINUX}/arch/riscv/boot/dts/qemu/qemu-virt-cbqri.dtb \
-append "root=/dev/vda ro" \
-drive file=output/images/rootfs.ext2,format=raw,id=hd0 \
-device virtio-blk-device,drive=hd0 \
Link: https://gitlab.baylibre.com/baylibre/qemu/-/tree/riscv-cbqri-rfc
Co-developed-by: Adrien Ricciardi <aricciardi@baylibre.com>
Signed-off-by: Adrien Ricciardi <aricciardi@baylibre.com>
Signed-off-by: Drew Fustini <dfustini@baylibre.com>
---
arch/riscv/boot/dts/qemu/qemu-virt-cbqri.dts | 59 ++++++++++++++++++++
1 file changed, 59 insertions(+)
diff --git a/arch/riscv/boot/dts/qemu/qemu-virt-cbqri.dts b/arch/riscv/boot/dts/qemu/qemu-virt-cbqri.dts
index 400ed48a06af..2c4ddc4271cc 100644
--- a/arch/riscv/boot/dts/qemu/qemu-virt-cbqri.dts
+++ b/arch/riscv/boot/dts/qemu/qemu-virt-cbqri.dts
@@ -367,5 +367,64 @@ clint@2000000 {
reg = <0x00 0x2000000 0x00 0x10000>;
compatible = "sifive,clint0\0riscv,clint0";
};
+
+ cluster0_l2: controller@4820000 {
+ compatible = "foobar,cache-controller";
+ reg = <0x0 0x4820000 0x0 0x1000>; /* 4KB at 0x04820000 */
+ cache-unified;
+ cache-line-size = <64>;
+ cache-level = <2>;
+ cache-sets = <1000>;
+ cache-size = <768000>; /* 750 KiB */
+ next-level-cache = <&shared_llc>;
+ riscv,cbqri-rcid = <64>;
+ riscv,cbqri-mcid = <256>;
+ };
+
+ cluster1_l2: controller@4821000 {
+ compatible = "foobar,cache-controller";
+ reg = <0x0 0x4821000 0x0 0x1000>; /* 4KB at 0x04821000 */
+ cache-unified;
+ cache-line-size = <64>;
+ cache-level = <2>;
+ cache-sets = <1000>;
+ cache-size = <768000>; /* 750 KiB */
+ next-level-cache = <&shared_llc>;
+ riscv,cbqri-rcid = <64>;
+ riscv,cbqri-mcid = <256>;
+ };
+
+ shared_llc: controller@482b000 {
+ compatible = "foobar,cache-controller";
+ reg = <0x0 0x482b000 0x0 0x1000>; /* 4KB at 0x0482B000 */
+ cache-unified;
+ cache-line-size = <64>;
+ cache-level = <3>;
+ cache-sets = <4096>;
+ cache-size = <3145728>; /* 3 MiB */
+ riscv,cbqri-rcid = <64>;
+ riscv,cbqri-mcid = <256>;
+ };
+
+ mem0: controller@4828000 {
+ compatible = "foobar,memory-controller";
+ reg = <0x0 0x4828000 0x0 0x1000>; /* 4KB at 0x04828000 */
+ riscv,cbqri-rcid = <64>;
+ riscv,cbqri-mcid = <256>;
+ };
+
+ mem1: controller@4829000 {
+ compatible = "foobar,memory-controller";
+ reg = <0x0 0x4829000 0x0 0x1000>; /* 4KB at 0x04829000 */
+ riscv,cbqri-rcid = <64>;
+ riscv,cbqri-mcid = <256>;
+ };
+
+ mem2: controller@482a000 {
+ compatible = "foobar,memory-controller";
+ reg = <0x0 0x482a000 0x0 0x1000>; /* 4KB at 0x0482A000 */
+ riscv,cbqri-rcid = <64>;
+ riscv,cbqri-mcid = <256>;
+ };
};
};
--
2.34.1
next prev parent reply other threads:[~2023-04-19 11:12 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-19 11:10 [RFC PATCH 00/21] RISC-V: QoS: add CBQRI resctrl interface Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 01/21] RISC-V: Detect the Ssqosid extension Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 02/21] RISC-V: Add support for sqoscfg CSR Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 03/21] RISC-V: QoS: define properties of CBQRI controllers Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 04/21] RISC-V: QoS: define CBQRI capacity and bandwidth capabilities Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 05/21] RISC-V: QoS: define prototypes for resctrl interface Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 06/21] RISC-V: QoS: define CBQRI resctrl resources and domains Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 07/21] RISC-V: QoS: add resctrl interface for CBQRI controllers Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 08/21] RISC-V: QoS: expose implementation to resctrl Drew Fustini
2023-04-19 11:10 ` [RFC PATCH 09/21] RISC-V: QoS: add late_initcall to setup resctrl interface Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 10/21] RISC-V: QoS: make CONFIG_RISCV_ISA_SSQOSID select resctrl Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 11/21] RISC-V: QoS: add to build when CONFIG_RISCV_ISA_SSQOSID set Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 12/21] dt-bindings: riscv: add riscv,cbqri bindings Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 13/21] DO_NOT_MERGE dt-bindings: add foobar vendor-prefix Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 14/21] DO_NOT_MERGE dt-bindings: soc: add Foobar SoC cache controller Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 15/21] DO_NOT_MERGE dt-bindings: soc: add Foobar SoC memory controller Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 16/21] DO_NOT_MERGE soc: add Foobar SoC cache controller driver Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 17/21] DO_NOT_MERGE soc: add Foobar SoC memory " Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 18/21] DO_NOT_MERGE soc: build Foobar SoC drivers Drew Fustini
2023-04-19 11:11 ` [RFC PATCH 19/21] DO_NOT_MERGE riscv: dts: qemu: add dump from riscv-cbqri-rfc Drew Fustini
2023-04-19 11:11 ` Drew Fustini [this message]
2023-04-19 11:11 ` [RFC PATCH 21/21] DO_NOT_MERGE riscv: dts: build qemu virt device tree Drew Fustini
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=20230419111111.477118-21-dfustini@baylibre.com \
--to=dfustini@baylibre.com \
--cc=aricciardi@baylibre.com \
--cc=babu.moger@amd.com \
--cc=conor.dooley@microchip.com \
--cc=fenghua.yu@intel.com \
--cc=james.morse@arm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=mindal@semihalf.com \
--cc=npitre@baylibre.com \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=peternewman@google.com \
--cc=reinette.chatre@intel.com \
--cc=robh+dt@kernel.org \
--cc=ved@rivosinc.com \
--cc=x86@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
Powered by JetHome