On 2/26/2025 6:41 AM, Johannes Berg wrote: > A very, very long time ago, when a lot of statistics were being added > (and required by Android?) I suggested that perhaps we should add way to > run BPF programs on incoming frames to keep track of these things > instead of having counters across the code for all kinds of things all > the time. I suspect that in the time since that has become much simpler, > since now BPF programs can be attached to tracepoints and adding a > tracepoint or a few could be very easily done. > In this case that'd really only require a TX and TX status tracepoint, > where the latter is getting the 'acked' indication, so that's basically > trace point definition + 2 lines of code. > > I wonder what you think about that. All of these counters add a pretty > large permanent memory (2 KiB here) and code cost, and having them in > debugfs _only_ can also be annoying for certain use cases. > > johannes I agree with the points opposing the use of only debugfs. Let me familiarize myself with BPF programs and get back to you with my input on your recommendation. I was wondering is there an existing feature/statistics that is a BPF program commonly used in wireless you would recommend to use as reference? Muna