Re: [PATCH v5 2/3] net: add kcov handle to skb extensions
From: Johannes Berg <johannes@sipsolutions.net>
Date: 2020-11-21 20:58:55
Also in:
linux-wireless, lkml
From: Johannes Berg <johannes@sipsolutions.net>
Date: 2020-11-21 20:58:55
Also in:
linux-wireless, lkml
On Sat, 2020-11-21 at 12:55 -0800, Jakub Kicinski wrote:
[snip] Ack, you have to figure out all the places anyway, the question is whether you put probes there or calls in the source code. Shifting the maintenance burden but also BPF is flexibility.
Yeah, true. Though I'd argue also visibility - this stuff is pretty simple now, if it gets into lots of lines of BPF code to track it that is maintained "elsewhere", we won't see the bugs in it :-) And it's kinda a thing that we as kernel developers _should_ be the ones looking at since it's testing our code.
Yup, the point is you can feed a raw skb pointer (and all other possible context you may want) to a BPF prog in kcov_remote_start() and let BPF/BTF give you the handle it recorded in its maps.
Yeah, it's possible. Personally, I don't think it's worth the complexity.
It is more complicated. We can go back to an skb field if this work is expected to yield results for mac80211. Would you mind sending a patch?
I can do that, but I'm not going to be able to do it now/tonight (GMT+1 here), so probably only Monday/Tuesday or so, sorry. johannes