Thread (11 messages) 11 messages, 6 authors, 2020-03-20

Re: [PATCH bpf-next 1/2] bpf: tcp: Fix unused function warnings

From: Daniel Borkmann <daniel@iogearbox.net>
Date: 2020-03-20 15:01:49
Also in: bpf, lkml

On 3/20/20 5:21 AM, Yonghong Song wrote:
On 3/19/20 7:34 PM, YueHaibing wrote:
quoted
If BPF_STREAM_PARSER is not set, gcc warns:

net/ipv4/tcp_bpf.c:483:12: warning: 'tcp_bpf_sendpage' defined but not used [-Wunused-function]
net/ipv4/tcp_bpf.c:395:12: warning: 'tcp_bpf_sendmsg' defined but not used [-Wunused-function]
net/ipv4/tcp_bpf.c:13:13: warning: 'tcp_bpf_stream_read' defined but not used [-Wunused-function]

Moves the unused functions into the #ifdef
Maybe explicit "into the #ifdef CONFIG_BPF_STREAM_PARSER"?
quoted
Reported-by: Hulk Robot <redacted>
Fixes: f747632b608f ("bpf: sockmap: Move generic sockmap hooks from BPF TCP")
Signed-off-by: YueHaibing <redacted>
Reviewed-by: Lorenz Bauer <redacted>
Reviewed-by: Jakub Sitnicki <jakub@cloudflare.com>
Acked-by: Yonghong Song <redacted>
Both applied and addressed feedback from Yonghong, thanks!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help