On Fri, 5 Jan 2024 14:44:00 +0000
Madhuker Mythri <madhuker.myt...@oracle.com> wrote:

> Hi Stephen,
> 
> The BPF helper man pages implies in that way and the SKB data pointer access 
> was working till 5.4 kernel also, however from Kernel-5.15 version, we do see 
> eBPF verifier throws error when we use SKB data pointer access.
> So, I had used this helper functions and able to resolve the errors. This is 
> helper functions are safe to use and also protects from any non-linear skb 
> data buffer access also.
> 
> So, I think using helper functions is better and safe way to access the SKB 
> data, instead of pointer access.
> 
> Thanks,
> Madhuker.

Using the accessors may mean it won't work with older kernels, but that is not
a huge concern given how fragile this code is.

Reply via email to