Commit Graph

1 Commits (cbb2602c69411d6374b20eff83c59ba97a6f7e22)

Author SHA1 Message Date
Michal Rostecki cbb2602c69
ebpf: Call `bpf_probe_read` on `*const T` BTF arguments
It's necessary to call `bpf_probe_read` not only for pointers retrieved
from `PtRegs`, but also from BTF arguments.

`bpf_probe_read` might return an error, so the return type of `.arg()`
methods in contexts handling BTF arguments changes from `T` to
`Option<T>`. `None` is returned when `bpf_probe_read` call is not
successful.

Fixes: #542
5 months ago