FS#62384 - [linux] Enable CONFIG_BPF_KPROBE_OVERRIDE by default

Attached to Project: Arch Linux
Opened by Adam (adam900710) - Thursday, 18 April 2019, 06:09 GMT
Last edited by Jan Alexander Steffens (heftig) - Tuesday, 08 September 2020, 16:11 GMT
Task Type Feature Request
Category Packages: Core
Status Closed
Assigned To Jan Alexander Steffens (heftig)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

Since Arch kernel has already enabled almost all kprobe events, it would be nice to support kprobe override to make it more developer friendly.

CONFIG_BPF_KPROBE_OVERRIDE is mainly used to inject error into the kernel to test the stability.
Normally I would use custom compiled kernel in VM to do such test, but it would be much nicer to be able to run the same bcc tool on Arch default kernel.

Additional info:
* package version(s)
linux 5.0.7.arch1-1

* config and/or log files etc.
Default arch kernel config:
...
CONFIG_FUNCTION_PROFILER=y
# CONFIG_BPF_KPROBE_OVERRIDE is not set
CONFIG_FTRACE_MCOUNT_RECORD=y
...

* link to upstream bug report, if any

Steps to reproduce:
- Install bcc from AUR or compile it
- Execute "tools/inject.py kmalloc -v 'mount_subtree() => btrfs_mount()'
It will fail due to missing bpf_override_return function, which needs CONFIG_BPF_KPROBE_OVERRIDE.
This task depends upon

Closed by  Jan Alexander Steffens (heftig)
Tuesday, 08 September 2020, 16:11 GMT
Reason for closing:  Implemented
Comment by loqs (loqs) - Monday, 07 September 2020, 19:17 GMT

Loading...