tree:
https://android.googlesource.com/kernel/common android12-5.4
head: bbf5a2eaba8de3602c3bc903f2477739ff89c631
commit: 48b03352a3bd46c2aec1804fd36fc78b4270e3d0 [16/24] ANDROID: GKI: net: add vendor
hooks for 'struct sock' lifecycle
config: x86_64-randconfig-s021-20210720 (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
git remote add android-common
https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android12-5.4
git checkout 48b03352a3bd46c2aec1804fd36fc78b4270e3d0
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
net/core/sock.c: note: in included file:
> include/trace/hooks/net.h:26:1: sparse: sparse: incorrect type in
assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr
@@ got struct tracepoint_func [noderef] <asn:4> *funcs @@
include/trace/hooks/net.h:26:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/net.h:26:1: sparse: got struct tracepoint_func [noderef]
<asn:4> *funcs
include/trace/hooks/net.h:28:1: sparse: sparse: incorrect type in assignment (different
address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct
tracepoint_func [noderef] <asn:4> *funcs @@
include/trace/hooks/net.h:28:1: sparse: expected struct tracepoint_func
*it_func_ptr
include/trace/hooks/net.h:28:1: sparse: got struct tracepoint_func [noderef]
<asn:4> *funcs
include/trace/hooks/net.h:28:1: sparse: sparse: incorrect type in assignment (different
address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct
tracepoint_func [noderef] <asn:4> *funcs @@
include/trace/hooks/net.h:28:1: sparse: expected struct tracepoint_func
*it_func_ptr
include/trace/hooks/net.h:28:1: sparse: got struct tracepoint_func [noderef]
<asn:4> *funcs
net/core/sock.c:1910:9: sparse: sparse: context imbalance in 'sk_clone_lock' -
wrong count at exit
net/core/sock.c:1914:6: sparse: sparse: context imbalance in
'sk_free_unlock_clone' - unexpected unlock
net/core/sock.c:3003:6: sparse: sparse: context imbalance in 'lock_sock_fast' -
different lock contexts for basic block
net/core/sock.c:3502:13: sparse: sparse: context imbalance in 'proto_seq_start'
- wrong count at exit
net/core/sock.c:3514:13: sparse: sparse: context imbalance in 'proto_seq_stop'
- wrong count at exit
vim +26 include/trace/hooks/net.h
11
12 struct packet_type;
13 struct list_head;
14 struct sk_buff;
15 struct nf_conn;
16 struct sock;
17 DECLARE_HOOK(android_vh_ptype_head,
18 TP_PROTO(const struct packet_type *pt, struct list_head *vendor_pt),
19 TP_ARGS(pt, vendor_pt));
20 DECLARE_HOOK(android_vh_kfree_skb,
21 TP_PROTO(struct sk_buff *skb), TP_ARGS(skb));
22 DECLARE_RESTRICTED_HOOK(android_rvh_nf_conn_alloc,
23 TP_PROTO(struct nf_conn *nf_conn), TP_ARGS(nf_conn), 1);
24 DECLARE_RESTRICTED_HOOK(android_rvh_nf_conn_free,
25 TP_PROTO(struct nf_conn *nf_conn), TP_ARGS(nf_conn), 1);
26 DECLARE_RESTRICTED_HOOK(android_rvh_sk_alloc,
27 TP_PROTO(struct sock *sock), TP_ARGS(sock), 1);
28 DECLARE_RESTRICTED_HOOK(android_rvh_sk_free,
29 TP_PROTO(struct sock *sock), TP_ARGS(sock), 1);
30
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org