public inbox for linux-riscv@lists.infradead.org
 help / color / mirror / Atom feed
From: Andrew Jones <ajones@ventanamicro.com>
To: linux-riscv@lists.infradead.org
Cc: paul.walmsley@sifive.com, palmer@dabbelt.com,
	aou@eecs.berkeley.edu, evan@rivosinc.com,
	conor.dooley@microchip.com, apatel@ventanamicro.com
Subject: [PATCH v3 0/4] RISC-V: hwprobe: Introduce which-cpus
Date: Wed, 22 Nov 2023 17:47:01 +0100	[thread overview]
Message-ID: <20231122164700.127954-6-ajones@ventanamicro.com> (raw)

This series introduces a flag for the hwprobe syscall which effectively
reverses its behavior from getting the values of keys for a set of cpus
to getting the cpus for a set of key-value pairs.

Change since v2[1]:
 - Rebased on v6.7-rc1 to get green on patchwork (dropped a couple
   patches that were merged with [2])
 - Added an r-b from Conor

Changes since v1[3]:
 - Dropped copyrights when splitting hwprobe out of sys_riscv.c [Conor]
 - Improved documentation [Evan]
 - Fixed a bug where the set of cpus could get changed to the set of all
   online cpus [Evan]
 - Added check for empty set of cpus in the vdso function [Evan, drew]
 - Replaced memset with a for-loop in the vdso function because we don't
   have memset there [drew]
 - Added an r-b from Conor

Changes since the RFC[4]:
 - Split hwprobe out of sys_riscv.c into its own file [Palmer]
 - Split the which-cpus functionality out of do_riscv_hwprobe() [Palmer]
 - Rename hwprobe_key_is_map to hwprobe_key_is_bitmask [Evan]
 - Move the homogeneous_cpus logic into the vDSO function [Evan]
 - Rework logic to not need to allocate any memory
 - Honor cpu affinity in the which-cpus selftests utility
 - Picked up some r-b's

[1] https://lore.kernel.org/all/20231020130515.424577-8-ajones@ventanamicro.com/
[2] https://lore.kernel.org/all/20230918131518.56803-8-ajones@ventanamicro.com/
[3] https://lore.kernel.org/all/20231011135610.122850-8-ajones@ventanamicro.com/
[4] https://lore.kernel.org/all/20230921125518.175428-7-ajones@ventanamicro.com/

Andrew Jones (4):
  RISC-V: hwprobe: Clarify cpus size parameter
  RISC-V: Move the hwprobe syscall to its own file
  RISC-V: hwprobe: Introduce which-cpus flag
  RISC-V: selftests: Add which-cpus hwprobe test

 Documentation/arch/riscv/hwprobe.rst          |  28 +-
 arch/riscv/include/asm/hwprobe.h              |  24 ++
 arch/riscv/include/uapi/asm/hwprobe.h         |   3 +
 arch/riscv/kernel/Makefile                    |   1 +
 arch/riscv/kernel/sys_hwprobe.c               | 375 ++++++++++++++++++
 arch/riscv/kernel/sys_riscv.c                 | 285 -------------
 arch/riscv/kernel/vdso/hwprobe.c              |  86 +++-
 .../testing/selftests/riscv/hwprobe/Makefile  |   5 +-
 .../testing/selftests/riscv/hwprobe/hwprobe.c |   2 +-
 .../testing/selftests/riscv/hwprobe/hwprobe.h |   2 +-
 .../selftests/riscv/hwprobe/which-cpus.c      | 154 +++++++
 .../selftests/riscv/vector/vstate_prctl.c     |  10 +-
 12 files changed, 660 insertions(+), 315 deletions(-)
 create mode 100644 arch/riscv/kernel/sys_hwprobe.c
 create mode 100644 tools/testing/selftests/riscv/hwprobe/which-cpus.c

-- 
2.41.0


_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

             reply	other threads:[~2023-11-22 16:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-22 16:47 Andrew Jones [this message]
2023-11-22 16:47 ` [PATCH v3 1/4] RISC-V: hwprobe: Clarify cpus size parameter Andrew Jones
2023-11-22 16:47 ` [PATCH v3 2/4] RISC-V: Move the hwprobe syscall to its own file Andrew Jones
2023-11-22 16:47 ` [PATCH v3 3/4] RISC-V: hwprobe: Introduce which-cpus flag Andrew Jones
2023-11-22 19:09   ` Evan Green
2023-11-22 16:47 ` [PATCH v3 4/4] RISC-V: selftests: Add which-cpus hwprobe test Andrew Jones
2024-01-05 21:50 ` [PATCH v3 0/4] RISC-V: hwprobe: Introduce which-cpus patchwork-bot+linux-riscv

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=20231122164700.127954-6-ajones@ventanamicro.com \
    --to=ajones@ventanamicro.com \
    --cc=aou@eecs.berkeley.edu \
    --cc=apatel@ventanamicro.com \
    --cc=conor.dooley@microchip.com \
    --cc=evan@rivosinc.com \
    --cc=linux-riscv@lists.infradead.org \
    --cc=palmer@dabbelt.com \
    --cc=paul.walmsley@sifive.com \
    /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