From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: Djordje Todorovic <Djordje.Todorovic@htecgroup.com>,
"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Cc: "qemu-riscv@nongnu.org" <qemu-riscv@nongnu.org>,
"cfu@mips.com" <cfu@mips.com>
Subject: Re: [PATCH v2 3/9] target/riscv: Add MIPS P8700 CPU
Date: Tue, 10 Jun 2025 09:38:50 +0200 [thread overview]
Message-ID: <37f95977-5d4e-4c58-bff8-f808aeaead07@linaro.org> (raw)
In-Reply-To: <20250602131226.1137281-4-djordje.todorovic@htecgroup.com>
Hi,
On 2/6/25 15:12, Djordje Todorovic wrote:
> Introduce MIPS P8700 CPU and set reset vector to 0x1fc00000.
>
> Signed-off-by: Chao-ying Fu <cfu@mips.com>
> Signed-off-by: Djordje Todorovic <djordje.todorovic@htecgroup.com>
> ---
> target/riscv/cpu-qom.h | 1 +
> target/riscv/cpu.c | 16 ++++++++++++++++
> 2 files changed, 17 insertions(+)
>
> diff --git a/target/riscv/cpu-qom.h b/target/riscv/cpu-qom.h
> index 1ee05eb393..1e62b96094 100644
> --- a/target/riscv/cpu-qom.h
> +++ b/target/riscv/cpu-qom.h
> @@ -55,6 +55,7 @@
> #define TYPE_RISCV_CPU_VEYRON_V1 RISCV_CPU_TYPE_NAME("veyron-v1")
> #define TYPE_RISCV_CPU_TT_ASCALON RISCV_CPU_TYPE_NAME("tt-ascalon")
> #define TYPE_RISCV_CPU_XIANGSHAN_NANHU RISCV_CPU_TYPE_NAME("xiangshan-nanhu")
> +#define TYPE_RISCV_CPU_MIPS_P8700 RISCV_CPU_TYPE_NAME("mips-p8700")
> #define TYPE_RISCV_CPU_HOST RISCV_CPU_TYPE_NAME("host")
>
> OBJECT_DECLARE_CPU_TYPE(RISCVCPU, RISCVCPUClass, RISCV_CPU)
> diff --git a/target/riscv/cpu.c b/target/riscv/cpu.c
> index 629ac37501..519d2345b8 100644
> --- a/target/riscv/cpu.c
> +++ b/target/riscv/cpu.c
> @@ -3167,6 +3167,22 @@ static const TypeInfo riscv_cpu_type_infos[] = {
> .cfg.max_satp_mode = VM_1_10_SV39,
> ),
>
> + // NOTE: When specifying CPU, specify `resetvec` as:
> + // -cpu mips-p8700,resetvec=0x1fc00000
Do you think users will go read the code for comments before using QEMU?
(please respect QEMU coding style).
Maybe resetvec has to be added to RISCVCPUProfile?
> + DEFINE_RISCV_CPU(TYPE_RISCV_CPU_MIPS_P8700, TYPE_RISCV_VENDOR_CPU,
> + .misa_mxl_max = MXL_RV64,
> + .misa_ext = RVI | RVM | RVA | RVF | RVD | RVC | RVS | RVU,
> + .priv_spec = PRIV_VERSION_1_12_0,
> + .cfg.max_satp_mode = VM_1_10_SV48,
> + .cfg.ext_zifencei = true,
> + .cfg.ext_zicsr = true,
> + .cfg.mmu = true,
> + .cfg.pmp = true,
> + .cfg.ext_zba = true,
> + .cfg.ext_zbb = true,
> + .cfg.marchid = 0x8000000000000201,
> + ),
> +
> #if defined(CONFIG_TCG) && !defined(CONFIG_USER_ONLY)
> DEFINE_RISCV_CPU(TYPE_RISCV_CPU_BASE128, TYPE_RISCV_DYNAMIC_CPU,
> .cfg.max_satp_mode = VM_1_10_SV57,
next prev parent reply other threads:[~2025-06-10 7:39 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-02 13:12 [PATCH v2 0/9] riscv: Add support for MIPS P8700 CPU Djordje Todorovic
2025-06-02 13:12 ` [PATCH v2 1/9] hw/intc: Allow gaps in hartids for aclint and aplic Djordje Todorovic
2025-06-10 7:34 ` Philippe Mathieu-Daudé
2025-06-18 8:43 ` Djordje Todorovic
2025-06-02 13:12 ` [PATCH v2 4/9] target/riscv: Add MIPS P8700 CSRs Djordje Todorovic
2025-06-10 7:41 ` Philippe Mathieu-Daudé
2025-06-10 11:36 ` Alistair Francis
2025-06-02 13:12 ` [PATCH v2 2/9] target/riscv: Add cpu_set_exception_base Djordje Todorovic
2025-06-10 7:43 ` Philippe Mathieu-Daudé
2025-06-18 8:48 ` Djordje Todorovic
2025-06-10 11:29 ` Alistair Francis
2025-06-02 13:12 ` [PATCH v2 3/9] target/riscv: Add MIPS P8700 CPU Djordje Todorovic
2025-06-10 7:38 ` Philippe Mathieu-Daudé [this message]
2025-06-18 8:54 ` Djordje Todorovic
2025-06-02 13:12 ` [PATCH v2 5/9] target/riscv: Add mips.ccmov instruction Djordje Todorovic
2025-06-10 11:39 ` Alistair Francis
2025-06-18 8:56 ` Djordje Todorovic
2025-06-02 13:12 ` [PATCH v2 6/9] target/riscv: Add mips.pref instruction Djordje Todorovic
2025-06-02 13:12 ` [PATCH v2 7/9] target/riscv: Add Xmipslsp instructions Djordje Todorovic
2025-06-02 13:12 ` [PATCH v2 8/9] configs/devices: Add MIPS Boston-aia board model to RISC-V Djordje Todorovic
2025-06-10 7:46 ` Philippe Mathieu-Daudé
2025-06-02 13:12 ` [PATCH v2 9/9] hw/riscv: Add a network device e1000e to the boston-aia Djordje Todorovic
2025-06-10 11:41 ` Alistair Francis
2025-06-10 11:42 ` [PATCH v2 0/9] riscv: Add support for MIPS P8700 CPU Alistair Francis
2025-06-18 7:55 ` Djordje Todorovic
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=37f95977-5d4e-4c58-bff8-f808aeaead07@linaro.org \
--to=philmd@linaro.org \
--cc=Djordje.Todorovic@htecgroup.com \
--cc=cfu@mips.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-riscv@nongnu.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).