Bug #322
Updated by Linus Lüssing almost 8 years ago
I suspect it might even be the compat code I provided with the last multicast patchset, but couldn't quite verify yet. The issue is the following, occuring when trying to build against a 4.5.0 kernel with a kernel config build via "make defconfig":
<pre>
/home/tux/dev/batman-adv-t_x/gen-compat-autoconf.sh /home/tux/dev/batman-adv-t_x/compat-autoconf.h
mkdir -p /home/tux/dev/batman-adv-t_x/build/net/batman-adv/
compat-patches/replacements.sh
touch /home/tux/dev/batman-adv-t_x/build/net/batman-adv/.compat-prepared
/usr/bin/make -C /home/tux/dev/linux/headers/usr/src/linux-headers-4.5.0+ M=/home/tux/dev/batman-adv-t_x/build PWD=/home/tux/dev/batman-adv-t_x/build REVISION=2016.5 CONFIG_BATMAN_ADV=m CONFIG_BATMAN_ADV_DEBUG=y CONFIG_BATMAN_ADV_DEBUGFS=y CONFIG_BATMAN_ADV_BLA=y CONFIG_BATMAN_ADV_DAT=y CONFIG_BATMAN_ADV_NC=n CONFIG_BATMAN_ADV_MCAST=y CONFIG_BATMAN_ADV_BATMAN_V=y INSTALL_MOD_DIR=updates/ modules
make[1]: Entering directory '/home/tux/dev/linux/headers/usr/src/linux-headers-4.5.0+'
CC [M] /home/tux/dev/batman-adv-t_x/build/net/batman-adv/../../../compat-sources/net/core/skbuff.o
In file included from include/linux/filter.h:16:0,
from include/net/sock.h:64,
from include/linux/tcp.h:22,
from include/linux/ipv6.h:72,
from /home/tux/dev/batman-adv-t_x/build/net/batman-adv/../../../compat-sources/net/core/skbuff.c:35:
include/net/sch_generic.h: In function ‘skb_at_tc_ingress’:
include/net/sch_generic.h:413:2: error: implicit declaration of function ‘G_TC_AT’ [-Werror=implicit-function-declaration]
return G_TC_AT(skb->tc_verd) & AT_INGRESS;
^
include/net/sch_generic.h:413:33: error: ‘AT_INGRESS’ undeclared (first use in this function)
return G_TC_AT(skb->tc_verd) & AT_INGRESS;
^
include/net/sch_generic.h:413:33: note: each undeclared identifier is reported only once for each function it appears in
cc1: all warnings being treated as errors
scripts/Makefile.build:258: recipe for target '/home/tux/dev/batman-adv-t_x/build/net/batman-adv/../../../compat-sources/net/core/skbuff.o' failed
make[3]: *** [/home/tux/dev/batman-adv-t_x/build/net/batman-adv/../../../compat-sources/net/core/skbuff.o] Error 1
scripts/Makefile.build:407: recipe for target '/home/tux/dev/batman-adv-t_x/build/net/batman-adv' failed
make[2]: *** [/home/tux/dev/batman-adv-t_x/build/net/batman-adv] Error 2
Makefile:1391: recipe for target '_module_/home/tux/dev/batman-adv-t_x/build' failed
make[1]: *** [_module_/home/tux/dev/batman-adv-t_x/build] Error 2
make[1]: Leaving directory '/home/tux/dev/linux/headers/usr/src/linux-headers-4.5.0+'
Makefile:90: recipe for target 'all' failed
make: *** [all] Error 2
</pre>
I can reproduce the error with v2016.3, v2016.4, v2016.5 and master. The issue does not occur with a kernel 4.6 to 4.9 - those versions have a CONFIG_NET_CLS_ACT set in their .config, too, and the includes of net/pkt_cls.h, uapi/linux/pkt_cls.h or net/sch_generic.h look the same to me compared to 4.5.0.
Although the includes do indeed look a little strange, I'm currently wondering why "include/net/pkt_cls.h" is not "include/linux/pkt_cls.h" which would match better to the uapi variant, I guess?
I will try to reproduce the issue with a v4.5.7 kernel.
**_Update:_**
* 4.5.7 does not work either
* 4.3.0 and 4.4.0 work fine