All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v8 0/2] bpftool: Refactor config parsing and add CET symbol matching
@ 2025-08-29  6:11 chenyuan_fl
  2025-08-29  6:11 ` [PATCH v8 1/2] bpftool: Refactor kernel config reading into common helper chenyuan_fl
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: chenyuan_fl @ 2025-08-29  6:11 UTC (permalink / raw)
  To: qmo, ast, daniel, andrii
  Cc: yonghong.song, olsajiri, bpf, linux-kernel, chenyuan

From: Yuan CHen <chenyuan@kylinos.cn>

1. **Refactor kernel config parsing**  
   - Moves duplicate config file handling from feature.c to common.c  
   - Keeps all existing functionality while enabling code reuse  

2. **Add CET-aware symbol matching**  
   - Adjusts kprobe hook detection for x86_64 CET (endbr32/64 prefixes)  
   - Matches symbols at both original and CET-adjusted addresses  

Changed in PATCH v4:
* Refactor repeated code into a function.
* Add detection for the x86 architecture.

Changed int PATH v5:
* Remove detection for the x86 architecture.

 Changed in PATCH v6:
* Add new helper patch (1/2) to refactor kernel config reading
* Use the new read_kernel_config() in CET symbol matching (2/2) to check CONFIG_X86_KERNEL_IBT

Changed in PATCH v7:
* Display actual kprobe attachment addresses instead of symbol addresses

Yuan Chen (2):
  bpftool: Refactor kernel config reading into common helper
  bpftool: Add CET-aware symbol matching for x86_64 architectures

 tools/bpf/bpftool/common.c  | 93 +++++++++++++++++++++++++++++++++++++
 tools/bpf/bpftool/feature.c | 86 ++--------------------------------
 tools/bpf/bpftool/link.c    | 38 ++++++++++++++-
 tools/bpf/bpftool/main.h    |  9 ++++
 4 files changed, 142 insertions(+), 84 deletions(-)

-- 
2.39.5


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

end of thread, other threads:[~2025-09-02 15:30 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-29  6:11 [PATCH v8 0/2] bpftool: Refactor config parsing and add CET symbol matching chenyuan_fl
2025-08-29  6:11 ` [PATCH v8 1/2] bpftool: Refactor kernel config reading into common helper chenyuan_fl
2025-08-29  6:11 ` [PATCH v8 2/2] bpftool: Add CET-aware symbol matching for x86_64 architectures chenyuan_fl
2025-09-01  9:32 ` [PATCH v8 0/2] bpftool: Refactor config parsing and add CET symbol matching Quentin Monnet
2025-09-01  9:58   ` Quentin Monnet
2025-09-02 15:30 ` patchwork-bot+netdevbpf

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.