mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v4 0/3] Move duplicated instructions macros into asm/insn.h
@ 2025-05-16 14:08 Alexandre Ghiti
  2025-05-16 14:08 ` [PATCH v4 1/3] riscv: Fix typo EXRACT -> EXTRACT Alexandre Ghiti
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Alexandre Ghiti @ 2025-05-16 14:08 UTC (permalink / raw)
  To: Paul Walmsley, Palmer Dabbelt, Alexandre Ghiti, Anup Patel,
	Atish Patra, linux-riscv, linux-kernel, kvm, kvm-riscv
  Cc: Alexandre Ghiti

The instructions parsing macros were duplicated and one of them had different
implementations, which is error prone.

So let's consolidate those macros in asm/insn.h.

v1: https://lore.kernel.org/linux-riscv/20250422082545.450453-1-alexghiti@rivosinc.com/
v2: https://lore.kernel.org/linux-riscv/20250508082215.88658-1-alexghiti@rivosinc.com/
v3: https://lore.kernel.org/linux-riscv/20250508125202.108613-1-alexghiti@rivosinc.com/

Changes in v4:
- Rebase on top of for-next (on top of 6.15-rc6)

Changes in v3:
- Fix patch 2 which caused build failures (linux riscv bot), but the
  patchset is exactly the same as v2

Changes in v2:
- Rebase on top of 6.15-rc5
- Add RB tags
- Define RV_X() using RV_X_mask() (Clément)
- Remove unused defines (Clément)
- Fix tabulations (Drew)

Alexandre Ghiti (3):
  riscv: Fix typo EXRACT -> EXTRACT
  riscv: Strengthen duplicate and inconsistent definition of RV_X()
  riscv: Move all duplicate insn parsing macros into asm/insn.h

 arch/riscv/include/asm/insn.h          | 206 ++++++++++++++++++++++---
 arch/riscv/kernel/machine_kexec_file.c |   2 +-
 arch/riscv/kernel/traps_misaligned.c   | 144 +----------------
 arch/riscv/kernel/vector.c             |   2 +-
 arch/riscv/kvm/vcpu_insn.c             | 128 +--------------
 5 files changed, 188 insertions(+), 294 deletions(-)

-- 
2.39.2


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

end of thread, other threads:[~2025-06-04 14:32 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-05-16 14:08 [PATCH v4 0/3] Move duplicated instructions macros into asm/insn.h Alexandre Ghiti
2025-05-16 14:08 ` [PATCH v4 1/3] riscv: Fix typo EXRACT -> EXTRACT Alexandre Ghiti
2025-05-16 14:08 ` [PATCH v4 2/3] riscv: Strengthen duplicate and inconsistent definition of RV_X() Alexandre Ghiti
2025-05-19 12:43   ` Clément Léger
2025-05-16 14:08 ` [PATCH v4 3/3] riscv: Move all duplicate insn parsing macros into asm/insn.h Alexandre Ghiti
2025-05-19 12:44   ` Clément Léger
2025-06-04 14:33 ` [PATCH v4 0/3] Move duplicated instructions " patchwork-bot+linux-riscv

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®