On 06/04/2018 01:04 PM, Jesper Dangaard Brouer via iovisor-dev wrote:
On Fri, 1 Jun 2018 14:15:58 +0200 Sebastiano Miano via iovisor-dev <iovisor-dev@...> wrote:
Dear all,
We have noticed that the bpf_redirect_map returns an error when it is called after a tail call. The xdp_redirect_map program (under sample/bpf) works fine, but if we modify it as shown in the following diff, it doesn't work anymore. I have debugged it with the xdp_monitor application and the error returned is EFAULT. Is this a known issue? Am I doing something wrong?
Argh, this is likely an issue/bug due to the check xdp_map_invalid(), that was introduced in commit 7c3001313396 ("bpf: fix ri->map_owner pointer on bpf_prog_realloc").
To Daniel, I don't know how to solve this, could you give some advice?