linux-stable/tools
Donglin Peng 8478cca1e3 tracing/probe: add a char type to show the character value of traced arguments
There are scenes that we want to show the character value of traced
arguments other than a decimal or hexadecimal or string value for debug
convinience. I add a new type named 'char' to do it and a new test case
file named 'kprobe_args_char.tc' to do selftest for char type.

For example:

The to be traced function is 'void demo_func(char type, char *name);', we
can add a kprobe event as follows to show argument values as we want:

echo  'p:myprobe demo_func $arg1:char +0($arg2):char[5]' > kprobe_events

we will get the following trace log:

... myprobe: (demo_func+0x0/0x29) arg1='A' arg2={'b','p','f','1',''}

Link: https://lore.kernel.org/all/20221219110613.367098-1-dolinux.peng@gmail.com/

Signed-off-by: Donglin Peng <dolinux.peng@gmail.com>
Acked-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
2023-02-21 08:52:42 +09:00
..
accounting tools/accounting/procacct: remove some unused variables 2022-11-18 13:55:09 -08:00
arch tools headers arm64: Sync arm64's cputype.h with the kernel sources 2023-01-18 10:07:42 -03:00
bootconfig
bpf bpftool: Fix linkage with statically built libllvm 2022-12-22 20:09:43 +01:00
build
certs
cgroup
counter
debugging
edid
firewire
firmware
gpio tools: gpio: fix -c option of gpio-event-mon 2023-01-27 14:05:46 +01:00
hv
iio
include tools headers: Syncronize linux/build_bug.h with the kernel sources 2023-01-18 10:31:11 -03:00
io_uring
kvm/kvm_stat
laptop
leds
lib libperf: Fix install_pkgconfig target 2022-12-16 10:04:06 -03:00
memory-model
objtool objtool: Tolerate STT_NOTYPE symbols at end of section 2023-01-09 17:53:46 +01:00
pci
pcmcia
perf perf test build-id: Fix test check for PE file 2023-01-18 10:52:06 -03:00
power ACPI updates for 6.2-rc1 2022-12-12 13:38:17 -08:00
rcu
scripts
spi
testing tracing/probe: add a char type to show the character value of traced arguments 2023-02-21 08:52:42 +09:00
thermal
time
tracing rtla: Fix exit status when returning from calls to usage() 2022-12-09 18:06:24 -05:00
usb
verification Tracing fix for 6.2: 2022-12-21 19:03:42 -08:00
virtio tools/virtio: fix the vringh test for virtio ring changes 2023-01-27 06:18:41 -05:00
vm MM patches for 6.2-rc1. 2022-12-13 19:29:45 -08:00
wmi
Makefile