public inbox for opensbi@lists.infradead.org
 help / color / mirror / Atom feed
From: Nick Hu <nick.hu@sifive.com>
To: opensbi@lists.infradead.org
Cc: Cyan Yang <cyan.yang@sifive.com>,
	Anup Patel <anup@brainfault.org>,  Nick Hu <nick.hu@sifive.com>
Subject: [PATCH v5 06/11] lib: sbi: Add SiFive proprietary xsfcease
Date: Tue, 02 Sep 2025 10:24:45 +0800	[thread overview]
Message-ID: <20250902-cache-upstream-v5-6-af60a067f47a@sifive.com> (raw)
In-Reply-To: <20250902-cache-upstream-v5-0-af60a067f47a@sifive.com>

Using ISA string "xsfcease" to detect the support of the custom
instruction "CEASE".

Reviewed-by: Cyan Yang <cyan.yang@sifive.com>
Reviewed-by: Anup Patel <anup@brainfault.org>
Signed-off-by: Nick Hu <nick.hu@sifive.com>
---
 include/sbi/sbi_hart.h | 2 ++
 lib/sbi/sbi_hart.c     | 1 +
 2 files changed, 3 insertions(+)

diff --git a/include/sbi/sbi_hart.h b/include/sbi/sbi_hart.h
index fdcf400aa8c494cd941c412294bd0c118c5ec2af..ff682fb4579291cd9e5fb36ca5ab392aa376d37f 100644
--- a/include/sbi/sbi_hart.h
+++ b/include/sbi/sbi_hart.h
@@ -83,6 +83,8 @@ enum sbi_hart_extensions {
 	SBI_HART_EXT_SSSTATEEN,
 	/** Hart has Xsfcflushdlone extension */
 	SBI_HART_EXT_XSIFIVE_CFLUSH_D_L1,
+	/** Hart has Xsfcease extension */
+	SBI_HART_EXT_XSIFIVE_CEASE,
 
 	/** Maximum index of Hart extension */
 	SBI_HART_EXT_MAX,
diff --git a/lib/sbi/sbi_hart.c b/lib/sbi/sbi_hart.c
index 4160ad6c3d8b31ff9f3d5ab5dbf55356140232a8..2519f3f003ce035289f6d5dd54ccec20b36c7667 100644
--- a/lib/sbi/sbi_hart.c
+++ b/lib/sbi/sbi_hart.c
@@ -716,6 +716,7 @@ const struct sbi_hart_ext_data sbi_hart_ext[] = {
 	__SBI_HART_EXT_DATA(ssctr, SBI_HART_EXT_SSCTR),
 	__SBI_HART_EXT_DATA(ssstateen, SBI_HART_EXT_SSSTATEEN),
 	__SBI_HART_EXT_DATA(xsfcflushdlone, SBI_HART_EXT_XSIFIVE_CFLUSH_D_L1),
+	__SBI_HART_EXT_DATA(xsfcease, SBI_HART_EXT_XSIFIVE_CEASE),
 };
 
 _Static_assert(SBI_HART_EXT_MAX == array_size(sbi_hart_ext),

-- 
2.34.1


-- 
opensbi mailing list
opensbi@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/opensbi

  parent reply	other threads:[~2025-09-02  2:19 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-02  2:24 [PATCH v5 00/11] Add SiFive TMC0 and SMC0 driver Nick Hu
2025-09-02  2:24 ` [PATCH v5 01/11] lib: utils: Add cache flush library Nick Hu
2025-09-02  2:24 ` [PATCH v5 02/11] lib: utils: Add FDT cache library Nick Hu
2025-09-02  2:24 ` [PATCH v5 03/11] utils: cache: Add SiFive ccache controller Nick Hu
2025-09-02  2:24 ` [PATCH v5 04/11] lib: utils/cache: Add fdt cmo helpers Nick Hu
2025-09-02  6:13   ` Anup Patel
2025-09-02  2:24 ` [PATCH v5 05/11] lib: sbi: Add SiFive proprietary xsfcflushdlone Nick Hu
2025-09-02  2:24 ` Nick Hu [this message]
2025-09-02  2:24 ` [PATCH v5 07/11] lib: utils/ipi: Exposing the ACLINT IPI device Nick Hu
2025-09-02  6:16   ` Anup Patel
2025-09-02  2:24 ` [PATCH v5 08/11] lib: utils/irqchip: Add APLIC restore function Nick Hu
2025-09-02  6:18   ` Anup Patel
2025-09-02  2:24 ` [PATCH v5 09/11] platform: sifive: Add SiFive TMC0 driver Nick Hu
2025-09-02 10:33   ` Anup Patel
2025-09-03  6:54     ` Nick Hu
2025-09-02  2:24 ` [PATCH v5 10/11] lib: utils/timer: Expose timer update function Nick Hu
2025-09-02  2:24 ` [PATCH v5 11/11] platform: sifive: Add SiFive SMC0 driver Nick Hu

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=20250902-cache-upstream-v5-6-af60a067f47a@sifive.com \
    --to=nick.hu@sifive.com \
    --cc=anup@brainfault.org \
    --cc=cyan.yang@sifive.com \
    --cc=opensbi@lists.infradead.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