util-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] lscpu: Print ISA information in summary
@ 2025-03-04 14:42 Sunil V L
  2025-03-05 12:29 ` Sunil V L
  0 siblings, 1 reply; 2+ messages in thread
From: Sunil V L @ 2025-03-04 14:42 UTC (permalink / raw)
  To: util-linux; +Cc: Sunil V L

The ISA information for RISC-V is an important information to understand
the different extensions supported by the CPU. Print this information in
the summary.

Signed-off-by: Sunil V L <sunilvl@ventanamicro.com>
---
 sys-utils/lscpu-cputype.c | 1 +
 sys-utils/lscpu.c         | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/sys-utils/lscpu-cputype.c b/sys-utils/lscpu-cputype.c
index 739dd99c5..bdb33ac78 100644
--- a/sys-utils/lscpu-cputype.c
+++ b/sys-utils/lscpu-cputype.c
@@ -233,6 +233,7 @@ static const struct cpuinfo_pattern type_patterns[] =
 	DEF_PAT_CPUTYPE( "family",		PAT_FAMILY,	family),
 	DEF_PAT_CPUTYPE( "features",		PAT_FEATURES,	flags),		/* s390 */
 	DEF_PAT_CPUTYPE( "flags",		PAT_FLAGS,	flags),		/* x86 */
+	DEF_PAT_CPUTYPE( "isa",			PAT_ISA,	isa),		/* riscv */
 	DEF_PAT_CPUTYPE( "marchid",		PAT_FAMILY,	family),	/* riscv */
 	DEF_PAT_CPUTYPE( "max thread id",	PAT_MAX_THREAD_ID, mtid),	/* s390 */
 	DEF_PAT_CPUTYPE( "mimpid",		PAT_MODEL,	model),		/* riscv */
diff --git a/sys-utils/lscpu.c b/sys-utils/lscpu.c
index ffec37206..9f00b1757 100644
--- a/sys-utils/lscpu.c
+++ b/sys-utils/lscpu.c
@@ -954,6 +954,9 @@ print_summary_cputype(struct lscpu_cxt *cxt,
 
 	if (ct->flags)
 		add_summary_s(tb, sec, _("Flags:"), ct->flags);
+
+	if (ct->isa)
+		add_summary_s(tb, sec, _("ISA:"), ct->isa);
 }
 
 /*
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] lscpu: Print ISA information in summary
  2025-03-04 14:42 [PATCH] lscpu: Print ISA information in summary Sunil V L
@ 2025-03-05 12:29 ` Sunil V L
  0 siblings, 0 replies; 2+ messages in thread
From: Sunil V L @ 2025-03-05 12:29 UTC (permalink / raw)
  To: util-linux; +Cc: Andrew Jones, Anup Patel

On Tue, Mar 04, 2025 at 08:12:10PM +0530, Sunil V L wrote:
> The ISA information for RISC-V is an important information to understand
> the different extensions supported by the CPU. Print this information in
> the summary.
> 

Hi,

I had some offline conversation with Drew and Anup regarding the
formatting of the ISA. I will send v2 of this patch to address the
feedback from them. So, please ignore this version for now.

Thanks,
Sunil

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-03-05 12:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-04 14:42 [PATCH] lscpu: Print ISA information in summary Sunil V L
2025-03-05 12:29 ` Sunil V L

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).