From: LIU Zhiwei <zhiwei_liu@linux.alibaba.com>
To: qemu-devel@nongnu.org
Cc: Alistair.Francis@wdc.com, palmer@dabbelt.com,
bin.meng@windriver.com, liwei1518@gmail.com,
dbarboza@ventanamicro.com, qemu-riscv@nongnu.org,
christoph.muellner@vrull.eu, bjorn@kernel.org,
LIU Zhiwei <zhiwei_liu@linux.alibaba.com>
Subject: [PATCH v2 0/2] target/riscv: Support mxstatus CSR for thead-c906
Date: Sun, 4 Feb 2024 13:42:26 +0800 [thread overview]
Message-ID: <20240204054228.651-1-zhiwei_liu@linux.alibaba.com> (raw)
This patch set fix the regression on kernel pointed by Björn Töpel in
https://www.mail-archive.com/qemu-devel@nongnu.org/msg1018232.html.
We first add a framework for vendor CSRs in patch 1. After that we add
one thead-c906 CSR mxstatus, which is used for mmu extension xtheadmaee.
thead-c906 uses some flags in pte [60-63] bits. It has history reasons that
SVPBMT didn't exist when thead-c906 came to wotrld. We named this feature as
xtheadmaee[1]. this feature is controlled by an custom CSR named mxstatus,
whose maee field encodes whether enable the pte [60-63] bits.
[1]:https://github.com/T-head-Semi/thead-extension-spec/blob/master/xtheadmaee.adoc
LIU Zhiwei (2):
target/riscv: Register vendors CSR
target/riscv: Support xtheadmaee for thead-c906
target/riscv/cpu.c | 9 ++++++
target/riscv/cpu.h | 9 ++++++
target/riscv/cpu_bits.h | 6 ++++
target/riscv/cpu_cfg.h | 4 ++-
target/riscv/cpu_helper.c | 25 ++++++++-------
target/riscv/meson.build | 1 +
target/riscv/tcg/tcg-cpu.c | 25 ++++++++++++++-
target/riscv/tcg/tcg-cpu.h | 1 +
target/riscv/xthead_csr.c | 65 ++++++++++++++++++++++++++++++++++++++
9 files changed, 132 insertions(+), 13 deletions(-)
create mode 100644 target/riscv/xthead_csr.c
--
2.25.1
next reply other threads:[~2024-02-04 5:44 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-04 5:42 LIU Zhiwei [this message]
2024-02-04 5:42 ` [PATCH v2 1/2] target/riscv: Register vendors CSR LIU Zhiwei
2024-02-04 5:42 ` [PATCH v2 2/2] target/riscv: Support xtheadmaee for thead-c906 LIU Zhiwei
2024-02-05 2:41 ` Alistair Francis
2024-02-05 8:36 ` Christoph Müllner
2024-02-15 4:24 ` Alistair Francis
2024-03-27 11:19 ` Conor Dooley
2024-03-28 1:18 ` Alistair Francis
2024-03-28 14:24 ` Christoph Müllner
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=20240204054228.651-1-zhiwei_liu@linux.alibaba.com \
--to=zhiwei_liu@linux.alibaba.com \
--cc=Alistair.Francis@wdc.com \
--cc=bin.meng@windriver.com \
--cc=bjorn@kernel.org \
--cc=christoph.muellner@vrull.eu \
--cc=dbarboza@ventanamicro.com \
--cc=liwei1518@gmail.com \
--cc=palmer@dabbelt.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).