2018-05-18 05:16:46

by kernel test robot

[permalink] [raw]
Subject: [net-next:master 1200/1233] net/ipv4/tcp_recovery.c:24:5: sparse: symbol 'tcp_rack_reo_wnd' was not declared. Should it be static?

tree: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master
head: 538e2de104cfb4ef1acb35af42427bff42adbe4d
commit: 20b654dfe1beaca60ab51894ff405a049248433d [1200/1233] tcp: support DUPACK threshold in RACK
reproduce:
# apt-get install sparse
git checkout 20b654dfe1beaca60ab51894ff405a049248433d
make ARCH=x86_64 allmodconfig
make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

net/ipv4/tcp_recovery.c:46:16: sparse: expression using sizeof(void)
net/ipv4/tcp_recovery.c:46:16: sparse: expression using sizeof(void)
>> net/ipv4/tcp_recovery.c:24:5: sparse: symbol 'tcp_rack_reo_wnd' was not declared. Should it be static?
include/net/tcp.h:738:16: sparse: expression using sizeof(void)
net/ipv4/tcp_recovery.c:102:40: sparse: expression using sizeof(void)
net/ipv4/tcp_recovery.c:102:40: sparse: expression using sizeof(void)
include/net/tcp.h:738:16: sparse: expression using sizeof(void)
net/ipv4/tcp_recovery.c:210:42: sparse: expression using sizeof(void)

Please review and possibly fold the followup patch.

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation


2018-05-18 05:16:39

by Fengguang Wu

[permalink] [raw]
Subject: [RFC PATCH net-next] tcp: tcp_rack_reo_wnd() can be static


Fixes: 20b654dfe1be ("tcp: support DUPACK threshold in RACK")
Signed-off-by: kbuild test robot <[email protected]>
---
tcp_recovery.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/ipv4/tcp_recovery.c b/net/ipv4/tcp_recovery.c
index 30cbfb6..71593e4 100644
--- a/net/ipv4/tcp_recovery.c
+++ b/net/ipv4/tcp_recovery.c
@@ -21,7 +21,7 @@ static bool tcp_rack_sent_after(u64 t1, u64 t2, u32 seq1, u32 seq2)
return t1 > t2 || (t1 == t2 && after(seq1, seq2));
}

-u32 tcp_rack_reo_wnd(const struct sock *sk)
+static u32 tcp_rack_reo_wnd(const struct sock *sk)
{
struct tcp_sock *tp = tcp_sk(sk);


2018-05-18 17:30:43

by David Miller

[permalink] [raw]
Subject: Re: [RFC PATCH net-next] tcp: tcp_rack_reo_wnd() can be static

From: kbuild test robot <[email protected]>
Date: Fri, 18 May 2018 13:14:23 +0800

> Fixes: 20b654dfe1be ("tcp: support DUPACK threshold in RACK")
> Signed-off-by: kbuild test robot <[email protected]>

Looks good, applied, thanks!