Skip to content
Snippets Groups Projects
Commit 0e6741f0 authored by Björn Töpel's avatar Björn Töpel Committed by Alexei Starovoitov
Browse files

libbpf: fix invalid munmap call


When unmapping the AF_XDP memory regions used for the rings, an
invalid address was passed to the munmap() calls. Instead of passing
the beginning of the memory region, the descriptor region was passed
to munmap.

When the userspace application tried to tear down an AF_XDP socket,
the operation failed and the application would still have a reference
to socket it wished to get rid of.

Reported-by: default avatarWilliam Tu <u9012063@gmail.com>
Fixes: 1cad0788 ("libbpf: add support for using AF_XDP sockets")
Signed-off-by: default avatarBjörn Töpel <bjorn.topel@intel.com>
Tested-by: default avatarWilliam Tu <u9012063@gmail.com>
Signed-off-by: default avatarAlexei Starovoitov <ast@kernel.org>
parent 6cea3370
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment