Skip to content
Commit 9da93c74 authored by Stanislav Fomichev's avatar Stanislav Fomichev Committed by Greg Kroah-Hartman
Browse files

bpf: Clarify error expectations from bpf_clone_redirect



[ Upstream commit 7cb779a6 ]

Commit 151e887d ("veth: Fixing transmit return status for dropped
packets") exposed the fact that bpf_clone_redirect is capable of
returning raw NET_XMIT_XXX return codes.

This is in the conflict with its UAPI doc which says the following:
"0 on success, or a negative error in case of failure."

Update the UAPI to reflect the fact that bpf_clone_redirect can
return positive error numbers, but don't explicitly define
their meaning.

Reported-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
Signed-off-by: default avatarStanislav Fomichev <sdf@google.com>
Signed-off-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
Link: https://lore.kernel.org/bpf/20230911194731.286342-1-sdf@google.com


Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent e1a8b79a
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment