public inbox for linux-riscv@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH 00/11] riscv: kprobes: Clean up instruction simulation
@ 2025-05-11 21:17 Nam Cao
  2025-05-11 21:17 ` [PATCH 01/11] riscv: kprobes: Move branch_rs2_idx to insn.h Nam Cao
                   ` (11 more replies)
  0 siblings, 12 replies; 16+ messages in thread
From: Nam Cao @ 2025-05-11 21:17 UTC (permalink / raw)
  To: Paul Walmsley, Palmer Dabbelt, Albert Ou, Alexandre Ghiti,
	linux-riscv, linux-kernel
  Cc: Nam Cao

Hi,

There is some instruction-processing code in kprobes simulate code. These
code should be insn.h. In fact, most of them is duplicating insn.h.

This series remove the duplicated bits and make use of macros already
defined in insn.h. The non-duplicated bits are moved into insn.h.

Nam Cao (11):
  riscv: kprobes: Move branch_rs2_idx to insn.h
  riscv: kprobes: Move branch_funct3 to insn.h
  riscv: kprobes: Remove duplication of RV_EXTRACT_JTYPE_IMM
  riscv: kprobes: Remove duplication of RV_EXTRACT_RS1_REG
  riscv: kprobes: Remove duplication of RV_EXTRACT_BTYPE_IMM
  riscv: kproves: Remove duplication of RVC_EXTRACT_JTYPE_IMM
  riscv: kprobes: Remove duplication of RVC_EXTRACT_C2_RS1_REG
  riscv: kprobes: Remove duplication of RVC_EXTRACT_BTYPE_IMM
  riscv: kprobes: Remove duplication of RV_EXTRACT_RD_REG
  riscv: kprobes: Remove duplication of RV_EXTRACT_UTYPE_IMM
  riscv: kprobes: Remove duplication of RV_EXTRACT_ITYPE_IMM

 arch/riscv/include/asm/insn.h            |  9 +++
 arch/riscv/kernel/probes/simulate-insn.c | 94 +++++-------------------
 2 files changed, 28 insertions(+), 75 deletions(-)

-- 
2.39.5


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

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

end of thread, other threads:[~2025-05-14  8:19 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-05-11 21:17 [PATCH 00/11] riscv: kprobes: Clean up instruction simulation Nam Cao
2025-05-11 21:17 ` [PATCH 01/11] riscv: kprobes: Move branch_rs2_idx to insn.h Nam Cao
2025-05-14  7:24   ` Alexandre Ghiti
2025-05-14  7:32     ` Nam Cao
2025-05-14  7:35       ` Alexandre Ghiti
2025-05-11 21:17 ` [PATCH 02/11] riscv: kprobes: Move branch_funct3 " Nam Cao
2025-05-11 21:17 ` [PATCH 03/11] riscv: kprobes: Remove duplication of RV_EXTRACT_JTYPE_IMM Nam Cao
2025-05-11 21:17 ` [PATCH 04/11] riscv: kprobes: Remove duplication of RV_EXTRACT_RS1_REG Nam Cao
2025-05-11 21:17 ` [PATCH 05/11] riscv: kprobes: Remove duplication of RV_EXTRACT_BTYPE_IMM Nam Cao
2025-05-11 21:17 ` [PATCH 06/11] riscv: kproves: Remove duplication of RVC_EXTRACT_JTYPE_IMM Nam Cao
2025-05-11 21:17 ` [PATCH 07/11] riscv: kprobes: Remove duplication of RVC_EXTRACT_C2_RS1_REG Nam Cao
2025-05-11 21:18 ` [PATCH 08/11] riscv: kprobes: Remove duplication of RVC_EXTRACT_BTYPE_IMM Nam Cao
2025-05-11 21:18 ` [PATCH 09/11] riscv: kprobes: Remove duplication of RV_EXTRACT_RD_REG Nam Cao
2025-05-11 21:18 ` [PATCH 10/11] riscv: kprobes: Remove duplication of RV_EXTRACT_UTYPE_IMM Nam Cao
2025-05-11 21:18 ` [PATCH 11/11] riscv: kprobes: Remove duplication of RV_EXTRACT_ITYPE_IMM Nam Cao
2025-05-14  8:05 ` [PATCH 00/11] riscv: kprobes: Clean up instruction simulation Alexandre Ghiti

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