On 08/16/2017 02:35 PM, David Ahern wrote: > On 8/16/17 1:34 PM, John Fastabend wrote: >>> I also have a build error. >>> >>> $ git grep -n __sock_map_lookup_elem >>> include/linux/bpf.h:316:struct sock *__sock_map_lookup_elem(struct bpf_map >>> *map, u32 key); >>> kernel/bpf/sockmap.c:558:struct sock *__sock_map_lookup_elem(struct >>> bpf_map *map, u32 key) >>> net/core/filter.c:1881: sk = __sock_map_lookup_elem(ri->map, >>> ri->ifindex); >>> >>> >>> >>> $ make ... >>> ... >>> net/core/filter.c: In function ‘do_sk_redirect_map’: >>> net/core/filter.c:1881:3: error: implicit declaration of function >>> ‘__sock_map_lookup_elem’ [-Werror=implicit-function-declaration] >>> sk = __sock_map_lookup_elem(ri->map, ri->ifindex); >>> ^ >>> net/core/filter.c:1881:6: warning: assignment makes pointer from integer >>> without a cast [enabled by default] >>> sk = __sock_map_lookup_elem(ri->map, ri->ifindex); >>> ^ >>> cc1: some warnings being treated as errors >>> make[2]: *** [net/core/filter.o] Error 1 >>> make[2]: *** Waiting for unfinished jobs.... >>> >>> >> >> Thanks Eric, I'll have a fix shortly. >> > > And I have a different build error: > > $ make O=kbuild/rcu-lock-debug/ -j24 -s > scripts/Makefile.kasan:25: CONFIG_KASAN: compiler does not support all > options. Trying minimal configuration > scripts/Makefile.kasan:25: CONFIG_KASAN: compiler does not support all > options. Trying minimal configuration > kernel/bpf/sockmap.o: In function `smap_stop_sock': > /home/dsa/kernel-2.git/kernel/bpf/sockmap.c:297: undefined reference to > `strp_stop' > kernel/bpf/sockmap.o: In function `smap_gc_work': > /home/dsa/kernel-2.git/kernel/bpf/sockmap.c:419: undefined reference to > `strp_done' > kernel/bpf/sockmap.o: In function `smap_data_ready': > /home/dsa/kernel-2.git/kernel/bpf/sockmap.c:216: undefined reference to > `strp_data_ready' > kernel/bpf/sockmap.o: In function `smap_init_sock': > /home/dsa/kernel-2.git/kernel/bpf/sockmap.c:373: undefined reference to > `strp_init' > /home/dsa/kernel-2.git/Makefile:1000: recipe for target 'vmlinux' failed > make[1]: *** [vmlinux] Error 1 > Makefile:145: recipe for target 'sub-make' failed > make: *** [sub-make] Error 2 > > I'm guessing a missing CONFIG tie in. >
Yep those two are related we have the fix now just running a couple extra build tests now to be sure. For the future I think we will tie into kbuild bot earlier. Thanks, John