2020-08-05 16:44:15

by Stephen Rothwell

[permalink] [raw]
Subject: linux-next: build failure after merge of the net-next tree

Hi all,

After merging the net-next tree, today's linux-next build (s390 defconfig)
failed like this:

net/ipv4/ip_tunnel_core.c:335:2: error: implicit declaration of function 'csum_ipv6_magic' [-Werror=implicit-function-declaration]

Caused by commit

4cb47a8644cc ("tunnels: PMTU discovery support for directly bridged IP packets")

--
Cheers,
Stephen Rothwell


Attachments:
(No filename) (499.00 B)
OpenPGP digital signature

2020-08-05 19:53:28

by Stefano Brivio

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On Wed, 5 Aug 2020 15:21:44 +0200
Heiko Carstens <[email protected]> wrote:

> On Wed, Aug 05, 2020 at 03:06:27PM +0200, Stefano Brivio wrote:
> > On Wed, 5 Aug 2020 22:31:21 +1000
> > Stephen Rothwell <[email protected]> wrote:
> >
> > > Hi all,
> > >
> > > After merging the net-next tree, today's linux-next build (s390 defconfig)
> > > failed like this:
> > >
> > > net/ipv4/ip_tunnel_core.c:335:2: error: implicit declaration of function 'csum_ipv6_magic' [-Werror=implicit-function-declaration]
> > >
> > > Caused by commit
> > >
> > > 4cb47a8644cc ("tunnels: PMTU discovery support for directly bridged IP packets")
> >
> > Ouch, sorry for that.
> >
> > I'm getting a few of them by the way:
> >
> > ---
> > net/core/skbuff.o: In function `skb_checksum_setup_ipv6':
> > /home/sbrivio/net-next/net/core/skbuff.c:4980: undefined reference to `csum_ipv6_magic'
> > net/core/netpoll.o: In function `netpoll_send_udp':
> > /home/sbrivio/net-next/net/core/netpoll.c:419: undefined reference to `csum_ipv6_magic'
> > net/netfilter/utils.o: In function `nf_ip6_checksum':
> > /home/sbrivio/net-next/net/netfilter/utils.c:74: undefined reference to `csum_ipv6_magic'
> > /home/sbrivio/net-next/net/netfilter/utils.c:84: undefined reference to `csum_ipv6_magic'
> > net/netfilter/utils.o: In function `nf_ip6_checksum_partial':
> > /home/sbrivio/net-next/net/netfilter/utils.c:112: undefined reference to `csum_ipv6_magic'
> > net/ipv4/ip_tunnel_core.o:/home/sbrivio/net-next/net/ipv4/ip_tunnel_core.c:335: more undefined references to `csum_ipv6_magic' follow
> > ---
> >
> > ...checking how it should be fixed now.
> >
> > Heiko, by the way, do we want to provide a s390 version similar to the
> > existing csum_partial() implementation in
> > arch/s390/include/asm/checksum.h right away? Otherwise, I'll just take
> > care of the ifdeffery.
>
> You probably only need to include include/net/ip6_checksum.h which
> contains the default implementation.

Yes, patch already sent a couple of minutes ago, still waiting for it to
reach the lists. Thanks!

--
Stefano

2020-08-05 19:54:38

by Heiko Carstens

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On Wed, Aug 05, 2020 at 03:06:27PM +0200, Stefano Brivio wrote:
> On Wed, 5 Aug 2020 22:31:21 +1000
> Stephen Rothwell <[email protected]> wrote:
>
> > Hi all,
> >
> > After merging the net-next tree, today's linux-next build (s390 defconfig)
> > failed like this:
> >
> > net/ipv4/ip_tunnel_core.c:335:2: error: implicit declaration of function 'csum_ipv6_magic' [-Werror=implicit-function-declaration]
> >
> > Caused by commit
> >
> > 4cb47a8644cc ("tunnels: PMTU discovery support for directly bridged IP packets")
>
> Ouch, sorry for that.
>
> I'm getting a few of them by the way:
>
> ---
> net/core/skbuff.o: In function `skb_checksum_setup_ipv6':
> /home/sbrivio/net-next/net/core/skbuff.c:4980: undefined reference to `csum_ipv6_magic'
> net/core/netpoll.o: In function `netpoll_send_udp':
> /home/sbrivio/net-next/net/core/netpoll.c:419: undefined reference to `csum_ipv6_magic'
> net/netfilter/utils.o: In function `nf_ip6_checksum':
> /home/sbrivio/net-next/net/netfilter/utils.c:74: undefined reference to `csum_ipv6_magic'
> /home/sbrivio/net-next/net/netfilter/utils.c:84: undefined reference to `csum_ipv6_magic'
> net/netfilter/utils.o: In function `nf_ip6_checksum_partial':
> /home/sbrivio/net-next/net/netfilter/utils.c:112: undefined reference to `csum_ipv6_magic'
> net/ipv4/ip_tunnel_core.o:/home/sbrivio/net-next/net/ipv4/ip_tunnel_core.c:335: more undefined references to `csum_ipv6_magic' follow
> ---
>
> ...checking how it should be fixed now.
>
> Heiko, by the way, do we want to provide a s390 version similar to the
> existing csum_partial() implementation in
> arch/s390/include/asm/checksum.h right away? Otherwise, I'll just take
> care of the ifdeffery.

You probably only need to include include/net/ip6_checksum.h which
contains the default implementation.

And yes, I put it on my todo list that we need to provide an s390
variant as well.

2020-08-05 20:03:45

by Stefano Brivio

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On Wed, 5 Aug 2020 22:31:21 +1000
Stephen Rothwell <[email protected]> wrote:

> Hi all,
>
> After merging the net-next tree, today's linux-next build (s390 defconfig)
> failed like this:
>
> net/ipv4/ip_tunnel_core.c:335:2: error: implicit declaration of function 'csum_ipv6_magic' [-Werror=implicit-function-declaration]
>
> Caused by commit
>
> 4cb47a8644cc ("tunnels: PMTU discovery support for directly bridged IP packets")

Ouch, sorry for that.

I'm getting a few of them by the way:

---
net/core/skbuff.o: In function `skb_checksum_setup_ipv6':
/home/sbrivio/net-next/net/core/skbuff.c:4980: undefined reference to `csum_ipv6_magic'
net/core/netpoll.o: In function `netpoll_send_udp':
/home/sbrivio/net-next/net/core/netpoll.c:419: undefined reference to `csum_ipv6_magic'
net/netfilter/utils.o: In function `nf_ip6_checksum':
/home/sbrivio/net-next/net/netfilter/utils.c:74: undefined reference to `csum_ipv6_magic'
/home/sbrivio/net-next/net/netfilter/utils.c:84: undefined reference to `csum_ipv6_magic'
net/netfilter/utils.o: In function `nf_ip6_checksum_partial':
/home/sbrivio/net-next/net/netfilter/utils.c:112: undefined reference to `csum_ipv6_magic'
net/ipv4/ip_tunnel_core.o:/home/sbrivio/net-next/net/ipv4/ip_tunnel_core.c:335: more undefined references to `csum_ipv6_magic' follow
---

...checking how it should be fixed now.

Heiko, by the way, do we want to provide a s390 version similar to the
existing csum_partial() implementation in
arch/s390/include/asm/checksum.h right away? Otherwise, I'll just take
care of the ifdeffery.

--
Stefano

2020-08-22 06:20:41

by Sven Joachim

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On 2020-08-21 09:23 -0700, Brian Vazquez wrote:

> Hi Sven,
>
> Sorry for the late reply, did you still see this after:
> https://patchwork.ozlabs.org/project/netdev/patch/[email protected]/
> ??

That patch is apparently already in 5.9-rc1 as commit 80fbbb1672e7, so
yes I'm still seeing it.

Cheers,
Sven

> On Mon, Aug 17, 2020 at 12:21 AM Sven Joachim <[email protected]> wrote:
>
>> On 2020-07-29 21:27 +1000, Stephen Rothwell wrote:
>>
>> > Hi all,
>> >
>> > After merging the net-next tree, today's linux-next build (i386
>> defconfig)
>> > failed like this:
>> >
>> > x86_64-linux-gnu-ld: net/core/fib_rules.o: in function
>> `fib_rules_lookup':
>> > fib_rules.c:(.text+0x5c6): undefined reference to `fib6_rule_match'
>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x5d8): undefined reference to
>> `fib6_rule_match'
>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x64d): undefined reference to
>> `fib6_rule_action'
>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x662): undefined reference to
>> `fib6_rule_action'
>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x67a): undefined reference to
>> `fib6_rule_suppress'
>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x68d): undefined reference to
>> `fib6_rule_suppress'
>>
>> FWIW, I saw these errors in 5.9-rc1 today, so the fix in commit
>> 41d707b7332f ("fib: fix fib_rules_ops indirect calls wrappers") was
>> apparently not sufficient.
>>
>> ,----
>> | $ grep IPV6 .config
>> | CONFIG_IPV6=m
>> | # CONFIG_IPV6_ROUTER_PREF is not set
>> | # CONFIG_IPV6_OPTIMISTIC_DAD is not set
>> | # CONFIG_IPV6_MIP6 is not set
>> | # CONFIG_IPV6_ILA is not set
>> | # CONFIG_IPV6_VTI is not set
>> | CONFIG_IPV6_SIT=m
>> | # CONFIG_IPV6_SIT_6RD is not set
>> | CONFIG_IPV6_NDISC_NODETYPE=y
>> | CONFIG_IPV6_TUNNEL=m
>> | CONFIG_IPV6_MULTIPLE_TABLES=y
>> | # CONFIG_IPV6_SUBTREES is not set
>> | # CONFIG_IPV6_MROUTE is not set
>> | # CONFIG_IPV6_SEG6_LWTUNNEL is not set
>> | # CONFIG_IPV6_SEG6_HMAC is not set
>> | # CONFIG_IPV6_RPL_LWTUNNEL is not set
>> | # CONFIG_NF_SOCKET_IPV6 is not set
>> | # CONFIG_NF_TPROXY_IPV6 is not set
>> | # CONFIG_NF_DUP_IPV6 is not set
>> | # CONFIG_NF_REJECT_IPV6 is not set
>> | # CONFIG_NF_LOG_IPV6 is not set
>> | CONFIG_NF_DEFRAG_IPV6=m
>> `----
>>
>> > Caused by commit
>> >
>> > b9aaec8f0be5 ("fib: use indirect call wrappers in the most common
>> fib_rules_ops")
>> >
>> > # CONFIG_IPV6_MULTIPLE_TABLES is not set
>> >
>> > I have reverted that commit for today.
>>
>> Cheers,
>> Sven
>>

2020-08-24 08:09:57

by Sven Joachim

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree


>> On Mon, Aug 17, 2020 at 12:21 AM Sven Joachim <[email protected]> wrote:
>>
>>> On 2020-07-29 21:27 +1000, Stephen Rothwell wrote:
>>>
>>> > Hi all,
>>> >
>>> > After merging the net-next tree, today's linux-next build (i386
>>> defconfig)
>>> > failed like this:
>>> >
>>> > x86_64-linux-gnu-ld: net/core/fib_rules.o: in function
>>> `fib_rules_lookup':
>>> > fib_rules.c:(.text+0x5c6): undefined reference to `fib6_rule_match'
>>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x5d8): undefined reference to
>>> `fib6_rule_match'
>>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x64d): undefined reference to
>>> `fib6_rule_action'
>>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x662): undefined reference to
>>> `fib6_rule_action'
>>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x67a): undefined reference to
>>> `fib6_rule_suppress'
>>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x68d): undefined reference to
>>> `fib6_rule_suppress'
>>>
>>> FWIW, I saw these errors in 5.9-rc1 today, so the fix in commit
>>> 41d707b7332f ("fib: fix fib_rules_ops indirect calls wrappers") was
>>> apparently not sufficient.
>>>
>>> ,----
>>> | $ grep IPV6 .config
>>> | CONFIG_IPV6=m
>>> | # CONFIG_IPV6_ROUTER_PREF is not set
>>> | # CONFIG_IPV6_OPTIMISTIC_DAD is not set
>>> | # CONFIG_IPV6_MIP6 is not set
>>> | # CONFIG_IPV6_ILA is not set
>>> | # CONFIG_IPV6_VTI is not set
>>> | CONFIG_IPV6_SIT=m
>>> | # CONFIG_IPV6_SIT_6RD is not set
>>> | CONFIG_IPV6_NDISC_NODETYPE=y
>>> | CONFIG_IPV6_TUNNEL=m
>>> | CONFIG_IPV6_MULTIPLE_TABLES=y
>>> | # CONFIG_IPV6_SUBTREES is not set
>>> | # CONFIG_IPV6_MROUTE is not set
>>> | # CONFIG_IPV6_SEG6_LWTUNNEL is not set
>>> | # CONFIG_IPV6_SEG6_HMAC is not set
>>> | # CONFIG_IPV6_RPL_LWTUNNEL is not set
>>> | # CONFIG_NF_SOCKET_IPV6 is not set
>>> | # CONFIG_NF_TPROXY_IPV6 is not set
>>> | # CONFIG_NF_DUP_IPV6 is not set
>>> | # CONFIG_NF_REJECT_IPV6 is not set
>>> | # CONFIG_NF_LOG_IPV6 is not set
>>> | CONFIG_NF_DEFRAG_IPV6=m
>>> `----
>>>
>>> > Caused by commit
>>> >
>>> > b9aaec8f0be5 ("fib: use indirect call wrappers in the most common
>>> fib_rules_ops")
>>> >
>>> > # CONFIG_IPV6_MULTIPLE_TABLES is not set
>>> >
>>> > I have reverted that commit for today.
>>>
>>> Cheers,
>>> Sven
>>>


Attachments:
.config.xz (21.67 kB)

2020-08-27 18:14:11

by Brian Vazquez

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

Hi Sven,

I've been trying to reproduce it with your config but I didn't
succeed. I also looked at the file after the preprocessor and it
looked good:

ret = ({ __builtin_expect(!!(ops->match == fib6_rule_match), 1) ?
fib6_rule_match(rule, fl, flags) : ops->match(rule, fl, flags); })

Note that fib4_rule_match doesn't appear as the
CONFIG_IP_MULTIPLE_TABLES is not there.

Could you share more details on how you're compiling it and what
compiler you're using??

Thanks,
Brian



On Mon, Aug 24, 2020 at 1:08 AM Sven Joachim <[email protected]> wrote:
>
> On 2020-08-22 08:16 +0200, Sven Joachim wrote:
>
> > On 2020-08-21 09:23 -0700, Brian Vazquez wrote:
> >
> >> Hi Sven,
> >>
> >> Sorry for the late reply, did you still see this after:
> >> https://patchwork.ozlabs.org/project/netdev/patch/[email protected]/
> >> ??
> >
> > That patch is apparently already in 5.9-rc1 as commit 80fbbb1672e7, so
> > yes I'm still seeing it.
>
> Still present in 5.9-rc2 as of today, I have attached my .config for
> reference. Note that I have CONFIG_IPV6_MULTIPLE_TABLES=y, but
> CONFIG_IP_MULTIPLE_TABLES is not mentioned at all there.
>
> To build the kernel, I have now deselected IPV6_MULTIPLE_TABLES. Not
> sure why this was enabled in my .config which has grown organically over
> many years.
>
> Cheers,
> Sven
>
>
> >> On Mon, Aug 17, 2020 at 12:21 AM Sven Joachim <[email protected]> wrote:
> >>
> >>> On 2020-07-29 21:27 +1000, Stephen Rothwell wrote:
> >>>
> >>> > Hi all,
> >>> >
> >>> > After merging the net-next tree, today's linux-next build (i386
> >>> defconfig)
> >>> > failed like this:
> >>> >
> >>> > x86_64-linux-gnu-ld: net/core/fib_rules.o: in function
> >>> `fib_rules_lookup':
> >>> > fib_rules.c:(.text+0x5c6): undefined reference to `fib6_rule_match'
> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x5d8): undefined reference to
> >>> `fib6_rule_match'
> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x64d): undefined reference to
> >>> `fib6_rule_action'
> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x662): undefined reference to
> >>> `fib6_rule_action'
> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x67a): undefined reference to
> >>> `fib6_rule_suppress'
> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x68d): undefined reference to
> >>> `fib6_rule_suppress'
> >>>
> >>> FWIW, I saw these errors in 5.9-rc1 today, so the fix in commit
> >>> 41d707b7332f ("fib: fix fib_rules_ops indirect calls wrappers") was
> >>> apparently not sufficient.
> >>>
> >>> ,----
> >>> | $ grep IPV6 .config
> >>> | CONFIG_IPV6=m
> >>> | # CONFIG_IPV6_ROUTER_PREF is not set
> >>> | # CONFIG_IPV6_OPTIMISTIC_DAD is not set
> >>> | # CONFIG_IPV6_MIP6 is not set
> >>> | # CONFIG_IPV6_ILA is not set
> >>> | # CONFIG_IPV6_VTI is not set
> >>> | CONFIG_IPV6_SIT=m
> >>> | # CONFIG_IPV6_SIT_6RD is not set
> >>> | CONFIG_IPV6_NDISC_NODETYPE=y
> >>> | CONFIG_IPV6_TUNNEL=m
> >>> | CONFIG_IPV6_MULTIPLE_TABLES=y
> >>> | # CONFIG_IPV6_SUBTREES is not set
> >>> | # CONFIG_IPV6_MROUTE is not set
> >>> | # CONFIG_IPV6_SEG6_LWTUNNEL is not set
> >>> | # CONFIG_IPV6_SEG6_HMAC is not set
> >>> | # CONFIG_IPV6_RPL_LWTUNNEL is not set
> >>> | # CONFIG_NF_SOCKET_IPV6 is not set
> >>> | # CONFIG_NF_TPROXY_IPV6 is not set
> >>> | # CONFIG_NF_DUP_IPV6 is not set
> >>> | # CONFIG_NF_REJECT_IPV6 is not set
> >>> | # CONFIG_NF_LOG_IPV6 is not set
> >>> | CONFIG_NF_DEFRAG_IPV6=m
> >>> `----
> >>>
> >>> > Caused by commit
> >>> >
> >>> > b9aaec8f0be5 ("fib: use indirect call wrappers in the most common
> >>> fib_rules_ops")
> >>> >
> >>> > # CONFIG_IPV6_MULTIPLE_TABLES is not set
> >>> >
> >>> > I have reverted that commit for today.
> >>>
> >>> Cheers,
> >>> Sven
> >>>

2020-08-28 15:11:06

by Sven Joachim

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On 2020-08-27 11:12 -0700, Brian Vazquez wrote:

> I've been trying to reproduce it with your config but I didn't
> succeed. I also looked at the file after the preprocessor and it
> looked good:
>
> ret = ({ __builtin_expect(!!(ops->match == fib6_rule_match), 1) ?
> fib6_rule_match(rule, fl, flags) : ops->match(rule, fl, flags); })

However, in my configuration I have CONFIG_IPV6=m, and so
fib6_rule_match is not available as a builtin. I think that's why ld is
complaining about the undefined reference.

Changing the configuration to CONFIG_IPV6=y helps, FWIW.

> Note that fib4_rule_match doesn't appear as the
> CONFIG_IP_MULTIPLE_TABLES is not there.
>
> Could you share more details on how you're compiling it and what
> compiler you're using??

Tried with both gcc 9 and gcc 10 under Debian unstable, binutils 2.35.
I usually use "make bindebpkg", but just running "make" is sufficient to
reproduce the problem, as it happens when linking vmlinux.

Cheers,
Sven


> On Mon, Aug 24, 2020 at 1:08 AM Sven Joachim <[email protected]> wrote:
>>
>> On 2020-08-22 08:16 +0200, Sven Joachim wrote:
>>
>> > On 2020-08-21 09:23 -0700, Brian Vazquez wrote:
>> >
>> >> Hi Sven,
>> >>
>> >> Sorry for the late reply, did you still see this after:
>> >> https://patchwork.ozlabs.org/project/netdev/patch/[email protected]/
>> >> ??
>> >
>> > That patch is apparently already in 5.9-rc1 as commit 80fbbb1672e7, so
>> > yes I'm still seeing it.
>>
>> Still present in 5.9-rc2 as of today, I have attached my .config for
>> reference. Note that I have CONFIG_IPV6_MULTIPLE_TABLES=y, but
>> CONFIG_IP_MULTIPLE_TABLES is not mentioned at all there.
>>
>> To build the kernel, I have now deselected IPV6_MULTIPLE_TABLES. Not
>> sure why this was enabled in my .config which has grown organically over
>> many years.
>>
>> Cheers,
>> Sven
>>
>>
>> >> On Mon, Aug 17, 2020 at 12:21 AM Sven Joachim <[email protected]> wrote:
>> >>
>> >>> On 2020-07-29 21:27 +1000, Stephen Rothwell wrote:
>> >>>
>> >>> > Hi all,
>> >>> >
>> >>> > After merging the net-next tree, today's linux-next build (i386
>> >>> defconfig)
>> >>> > failed like this:
>> >>> >
>> >>> > x86_64-linux-gnu-ld: net/core/fib_rules.o: in function
>> >>> `fib_rules_lookup':
>> >>> > fib_rules.c:(.text+0x5c6): undefined reference to `fib6_rule_match'
>> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x5d8): undefined reference to
>> >>> `fib6_rule_match'
>> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x64d): undefined reference to
>> >>> `fib6_rule_action'
>> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x662): undefined reference to
>> >>> `fib6_rule_action'
>> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x67a): undefined reference to
>> >>> `fib6_rule_suppress'
>> >>> > x86_64-linux-gnu-ld: fib_rules.c:(.text+0x68d): undefined reference to
>> >>> `fib6_rule_suppress'
>> >>>
>> >>> FWIW, I saw these errors in 5.9-rc1 today, so the fix in commit
>> >>> 41d707b7332f ("fib: fix fib_rules_ops indirect calls wrappers") was
>> >>> apparently not sufficient.
>> >>>
>> >>> ,----
>> >>> | $ grep IPV6 .config
>> >>> | CONFIG_IPV6=m
>> >>> | # CONFIG_IPV6_ROUTER_PREF is not set
>> >>> | # CONFIG_IPV6_OPTIMISTIC_DAD is not set
>> >>> | # CONFIG_IPV6_MIP6 is not set
>> >>> | # CONFIG_IPV6_ILA is not set
>> >>> | # CONFIG_IPV6_VTI is not set
>> >>> | CONFIG_IPV6_SIT=m
>> >>> | # CONFIG_IPV6_SIT_6RD is not set
>> >>> | CONFIG_IPV6_NDISC_NODETYPE=y
>> >>> | CONFIG_IPV6_TUNNEL=m
>> >>> | CONFIG_IPV6_MULTIPLE_TABLES=y
>> >>> | # CONFIG_IPV6_SUBTREES is not set
>> >>> | # CONFIG_IPV6_MROUTE is not set
>> >>> | # CONFIG_IPV6_SEG6_LWTUNNEL is not set
>> >>> | # CONFIG_IPV6_SEG6_HMAC is not set
>> >>> | # CONFIG_IPV6_RPL_LWTUNNEL is not set
>> >>> | # CONFIG_NF_SOCKET_IPV6 is not set
>> >>> | # CONFIG_NF_TPROXY_IPV6 is not set
>> >>> | # CONFIG_NF_DUP_IPV6 is not set
>> >>> | # CONFIG_NF_REJECT_IPV6 is not set
>> >>> | # CONFIG_NF_LOG_IPV6 is not set
>> >>> | CONFIG_NF_DEFRAG_IPV6=m
>> >>> `----
>> >>>
>> >>> > Caused by commit
>> >>> >
>> >>> > b9aaec8f0be5 ("fib: use indirect call wrappers in the most common
>> >>> fib_rules_ops")
>> >>> >
>> >>> > # CONFIG_IPV6_MULTIPLE_TABLES is not set
>> >>> >
>> >>> > I have reverted that commit for today.
>> >>>
>> >>> Cheers,
>> >>> Sven
>> >>>

2020-08-28 15:13:35

by Randy Dunlap

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On 8/28/20 8:09 AM, Sven Joachim wrote:
> On 2020-08-27 11:12 -0700, Brian Vazquez wrote:
>
>> I've been trying to reproduce it with your config but I didn't
>> succeed. I also looked at the file after the preprocessor and it
>> looked good:
>>
>> ret = ({ __builtin_expect(!!(ops->match == fib6_rule_match), 1) ?
>> fib6_rule_match(rule, fl, flags) : ops->match(rule, fl, flags); })
>
> However, in my configuration I have CONFIG_IPV6=m, and so
> fib6_rule_match is not available as a builtin. I think that's why ld is
> complaining about the undefined reference.

Same here FWIW. CONFIG_IPV6=m.


> Changing the configuration to CONFIG_IPV6=y helps, FWIW.
>
>> Note that fib4_rule_match doesn't appear as the
>> CONFIG_IP_MULTIPLE_TABLES is not there.
>>
>> Could you share more details on how you're compiling it and what
>> compiler you're using??
>
> Tried with both gcc 9 and gcc 10 under Debian unstable, binutils 2.35.
> I usually use "make bindebpkg", but just running "make" is sufficient to
> reproduce the problem, as it happens when linking vmlinux.
>
> Cheers,
> Sven
>
>
>> On Mon, Aug 24, 2020 at 1:08 AM Sven Joachim <[email protected]> wrote:
>>>
>>> On 2020-08-22 08:16 +0200, Sven Joachim wrote:
>>>
>>>> On 2020-08-21 09:23 -0700, Brian Vazquez wrote:
>>>>
>>>>> Hi Sven,
>>>>>
>>>>> Sorry for the late reply, did you still see this after:
>>>>> https://patchwork.ozlabs.org/project/netdev/patch/[email protected]/
>>>>> ??
>>>>
>>>> That patch is apparently already in 5.9-rc1 as commit 80fbbb1672e7, so
>>>> yes I'm still seeing it.
>>>
>>> Still present in 5.9-rc2 as of today, I have attached my .config for
>>> reference. Note that I have CONFIG_IPV6_MULTIPLE_TABLES=y, but
>>> CONFIG_IP_MULTIPLE_TABLES is not mentioned at all there.
>>>
>>> To build the kernel, I have now deselected IPV6_MULTIPLE_TABLES. Not
>>> sure why this was enabled in my .config which has grown organically over
>>> many years.
>>>
>>> Cheers,
>>> Sven
>>>
>>>
>>>>> On Mon, Aug 17, 2020 at 12:21 AM Sven Joachim <[email protected]> wrote:
>>>>>
>>>>>> On 2020-07-29 21:27 +1000, Stephen Rothwell wrote:
>>>>>>
>>>>>>> Hi all,
>>>>>>>
>>>>>>> After merging the net-next tree, today's linux-next build (i386
>>>>>> defconfig)
>>>>>>> failed like this:
>>>>>>>
>>>>>>> x86_64-linux-gnu-ld: net/core/fib_rules.o: in function
>>>>>> `fib_rules_lookup':
>>>>>>> fib_rules.c:(.text+0x5c6): undefined reference to `fib6_rule_match'
>>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x5d8): undefined reference to
>>>>>> `fib6_rule_match'
>>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x64d): undefined reference to
>>>>>> `fib6_rule_action'
>>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x662): undefined reference to
>>>>>> `fib6_rule_action'
>>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x67a): undefined reference to
>>>>>> `fib6_rule_suppress'
>>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x68d): undefined reference to
>>>>>> `fib6_rule_suppress'
>>>>>>
>>>>>> FWIW, I saw these errors in 5.9-rc1 today, so the fix in commit
>>>>>> 41d707b7332f ("fib: fix fib_rules_ops indirect calls wrappers") was
>>>>>> apparently not sufficient.
>>>>>>
>>>>>> ,----
>>>>>> | $ grep IPV6 .config
>>>>>> | CONFIG_IPV6=m
>>>>>> | # CONFIG_IPV6_ROUTER_PREF is not set
>>>>>> | # CONFIG_IPV6_OPTIMISTIC_DAD is not set
>>>>>> | # CONFIG_IPV6_MIP6 is not set
>>>>>> | # CONFIG_IPV6_ILA is not set
>>>>>> | # CONFIG_IPV6_VTI is not set
>>>>>> | CONFIG_IPV6_SIT=m
>>>>>> | # CONFIG_IPV6_SIT_6RD is not set
>>>>>> | CONFIG_IPV6_NDISC_NODETYPE=y
>>>>>> | CONFIG_IPV6_TUNNEL=m
>>>>>> | CONFIG_IPV6_MULTIPLE_TABLES=y
>>>>>> | # CONFIG_IPV6_SUBTREES is not set
>>>>>> | # CONFIG_IPV6_MROUTE is not set
>>>>>> | # CONFIG_IPV6_SEG6_LWTUNNEL is not set
>>>>>> | # CONFIG_IPV6_SEG6_HMAC is not set
>>>>>> | # CONFIG_IPV6_RPL_LWTUNNEL is not set
>>>>>> | # CONFIG_NF_SOCKET_IPV6 is not set
>>>>>> | # CONFIG_NF_TPROXY_IPV6 is not set
>>>>>> | # CONFIG_NF_DUP_IPV6 is not set
>>>>>> | # CONFIG_NF_REJECT_IPV6 is not set
>>>>>> | # CONFIG_NF_LOG_IPV6 is not set
>>>>>> | CONFIG_NF_DEFRAG_IPV6=m
>>>>>> `----
>>>>>>
>>>>>>> Caused by commit
>>>>>>>
>>>>>>> b9aaec8f0be5 ("fib: use indirect call wrappers in the most common
>>>>>> fib_rules_ops")
>>>>>>>
>>>>>>> # CONFIG_IPV6_MULTIPLE_TABLES is not set
>>>>>>>
>>>>>>> I have reverted that commit for today.
>>>>>>
>>>>>> Cheers,
>>>>>> Sven


--
~Randy

2020-08-28 23:18:42

by Brian Vazquez

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On Fri, Aug 28, 2020 at 8:12 AM Randy Dunlap <[email protected]> wrote:
>
> On 8/28/20 8:09 AM, Sven Joachim wrote:
> > On 2020-08-27 11:12 -0700, Brian Vazquez wrote:
> >
> >> I've been trying to reproduce it with your config but I didn't
> >> succeed. I also looked at the file after the preprocessor and it
> >> looked good:
> >>
> >> ret = ({ __builtin_expect(!!(ops->match == fib6_rule_match), 1) ?
> >> fib6_rule_match(rule, fl, flags) : ops->match(rule, fl, flags); })
> >
> > However, in my configuration I have CONFIG_IPV6=m, and so
> > fib6_rule_match is not available as a builtin. I think that's why ld is
> > complaining about the undefined reference.
>
> Same here FWIW. CONFIG_IPV6=m.

Oh I see,
I tried this and it seems to work fine for me, does this also fix your
problem? if so, I'll prepare the patch, and thanks for helping!
diff --git a/net/core/fib_rules.c b/net/core/fib_rules.c
index 51678a528f85..40dfd1f55899 100644
--- a/net/core/fib_rules.c
+++ b/net/core/fib_rules.c
@@ -16,7 +16,7 @@
#include <net/ip_tunnels.h>
#include <linux/indirect_call_wrapper.h>

-#ifdef CONFIG_IPV6_MULTIPLE_TABLES
+#if defined(CONFIG_IPV6_MULTIPLE_TABLES) && defined(CONFIG_IPV6)

>
>
> > Changing the configuration to CONFIG_IPV6=y helps, FWIW.
> >
> >> Note that fib4_rule_match doesn't appear as the
> >> CONFIG_IP_MULTIPLE_TABLES is not there.
> >>
> >> Could you share more details on how you're compiling it and what
> >> compiler you're using??
> >
> > Tried with both gcc 9 and gcc 10 under Debian unstable, binutils 2.35.
> > I usually use "make bindebpkg", but just running "make" is sufficient to
> > reproduce the problem, as it happens when linking vmlinux.
> >
> > Cheers,
> > Sven
> >
> >
> >> On Mon, Aug 24, 2020 at 1:08 AM Sven Joachim <[email protected]> wrote:
> >>>
> >>> On 2020-08-22 08:16 +0200, Sven Joachim wrote:
> >>>
> >>>> On 2020-08-21 09:23 -0700, Brian Vazquez wrote:
> >>>>
> >>>>> Hi Sven,
> >>>>>
> >>>>> Sorry for the late reply, did you still see this after:
> >>>>> https://patchwork.ozlabs.org/project/netdev/patch/[email protected]/
> >>>>> ??
> >>>>
> >>>> That patch is apparently already in 5.9-rc1 as commit 80fbbb1672e7, so
> >>>> yes I'm still seeing it.
> >>>
> >>> Still present in 5.9-rc2 as of today, I have attached my .config for
> >>> reference. Note that I have CONFIG_IPV6_MULTIPLE_TABLES=y, but
> >>> CONFIG_IP_MULTIPLE_TABLES is not mentioned at all there.
> >>>
> >>> To build the kernel, I have now deselected IPV6_MULTIPLE_TABLES. Not
> >>> sure why this was enabled in my .config which has grown organically over
> >>> many years.
> >>>
> >>> Cheers,
> >>> Sven
> >>>
> >>>
> >>>>> On Mon, Aug 17, 2020 at 12:21 AM Sven Joachim <[email protected]> wrote:
> >>>>>
> >>>>>> On 2020-07-29 21:27 +1000, Stephen Rothwell wrote:
> >>>>>>
> >>>>>>> Hi all,
> >>>>>>>
> >>>>>>> After merging the net-next tree, today's linux-next build (i386
> >>>>>> defconfig)
> >>>>>>> failed like this:
> >>>>>>>
> >>>>>>> x86_64-linux-gnu-ld: net/core/fib_rules.o: in function
> >>>>>> `fib_rules_lookup':
> >>>>>>> fib_rules.c:(.text+0x5c6): undefined reference to `fib6_rule_match'
> >>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x5d8): undefined reference to
> >>>>>> `fib6_rule_match'
> >>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x64d): undefined reference to
> >>>>>> `fib6_rule_action'
> >>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x662): undefined reference to
> >>>>>> `fib6_rule_action'
> >>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x67a): undefined reference to
> >>>>>> `fib6_rule_suppress'
> >>>>>>> x86_64-linux-gnu-ld: fib_rules.c:(.text+0x68d): undefined reference to
> >>>>>> `fib6_rule_suppress'
> >>>>>>
> >>>>>> FWIW, I saw these errors in 5.9-rc1 today, so the fix in commit
> >>>>>> 41d707b7332f ("fib: fix fib_rules_ops indirect calls wrappers") was
> >>>>>> apparently not sufficient.
> >>>>>>
> >>>>>> ,----
> >>>>>> | $ grep IPV6 .config
> >>>>>> | CONFIG_IPV6=m
> >>>>>> | # CONFIG_IPV6_ROUTER_PREF is not set
> >>>>>> | # CONFIG_IPV6_OPTIMISTIC_DAD is not set
> >>>>>> | # CONFIG_IPV6_MIP6 is not set
> >>>>>> | # CONFIG_IPV6_ILA is not set
> >>>>>> | # CONFIG_IPV6_VTI is not set
> >>>>>> | CONFIG_IPV6_SIT=m
> >>>>>> | # CONFIG_IPV6_SIT_6RD is not set
> >>>>>> | CONFIG_IPV6_NDISC_NODETYPE=y
> >>>>>> | CONFIG_IPV6_TUNNEL=m
> >>>>>> | CONFIG_IPV6_MULTIPLE_TABLES=y
> >>>>>> | # CONFIG_IPV6_SUBTREES is not set
> >>>>>> | # CONFIG_IPV6_MROUTE is not set
> >>>>>> | # CONFIG_IPV6_SEG6_LWTUNNEL is not set
> >>>>>> | # CONFIG_IPV6_SEG6_HMAC is not set
> >>>>>> | # CONFIG_IPV6_RPL_LWTUNNEL is not set
> >>>>>> | # CONFIG_NF_SOCKET_IPV6 is not set
> >>>>>> | # CONFIG_NF_TPROXY_IPV6 is not set
> >>>>>> | # CONFIG_NF_DUP_IPV6 is not set
> >>>>>> | # CONFIG_NF_REJECT_IPV6 is not set
> >>>>>> | # CONFIG_NF_LOG_IPV6 is not set
> >>>>>> | CONFIG_NF_DEFRAG_IPV6=m
> >>>>>> `----
> >>>>>>
> >>>>>>> Caused by commit
> >>>>>>>
> >>>>>>> b9aaec8f0be5 ("fib: use indirect call wrappers in the most common
> >>>>>> fib_rules_ops")
> >>>>>>>
> >>>>>>> # CONFIG_IPV6_MULTIPLE_TABLES is not set
> >>>>>>>
> >>>>>>> I have reverted that commit for today.
> >>>>>>
> >>>>>> Cheers,
> >>>>>> Sven
>
>
> --
> ~Randy
>

2020-08-28 23:45:12

by Randy Dunlap

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On 8/28/20 4:16 PM, Brian Vazquez wrote:
> On Fri, Aug 28, 2020 at 8:12 AM Randy Dunlap <[email protected]> wrote:
>>
>> On 8/28/20 8:09 AM, Sven Joachim wrote:
>>> On 2020-08-27 11:12 -0700, Brian Vazquez wrote:
>>>
>>>> I've been trying to reproduce it with your config but I didn't
>>>> succeed. I also looked at the file after the preprocessor and it
>>>> looked good:
>>>>
>>>> ret = ({ __builtin_expect(!!(ops->match == fib6_rule_match), 1) ?
>>>> fib6_rule_match(rule, fl, flags) : ops->match(rule, fl, flags); })
>>>
>>> However, in my configuration I have CONFIG_IPV6=m, and so
>>> fib6_rule_match is not available as a builtin. I think that's why ld is
>>> complaining about the undefined reference.
>>
>> Same here FWIW. CONFIG_IPV6=m.
>
> Oh I see,
> I tried this and it seems to work fine for me, does this also fix your
> problem? if so, I'll prepare the patch, and thanks for helping!
> diff --git a/net/core/fib_rules.c b/net/core/fib_rules.c
> index 51678a528f85..40dfd1f55899 100644
> --- a/net/core/fib_rules.c
> +++ b/net/core/fib_rules.c
> @@ -16,7 +16,7 @@
> #include <net/ip_tunnels.h>
> #include <linux/indirect_call_wrapper.h>
>
> -#ifdef CONFIG_IPV6_MULTIPLE_TABLES
> +#if defined(CONFIG_IPV6_MULTIPLE_TABLES) && defined(CONFIG_IPV6)


Yes, that works for me.
You can add this to your patch:

Acked-by: Randy Dunlap <[email protected]> # build-tested

thanks.
--
~Randy

2020-08-29 06:52:13

by Sven Joachim

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the net-next tree

On 2020-08-28 16:42 -0700, Randy Dunlap wrote:

> On 8/28/20 4:16 PM, Brian Vazquez wrote:
>> On Fri, Aug 28, 2020 at 8:12 AM Randy Dunlap <[email protected]> wrote:
>>>
>>> On 8/28/20 8:09 AM, Sven Joachim wrote:
>>>> On 2020-08-27 11:12 -0700, Brian Vazquez wrote:
>>>>
>>>>> I've been trying to reproduce it with your config but I didn't
>>>>> succeed. I also looked at the file after the preprocessor and it
>>>>> looked good:
>>>>>
>>>>> ret = ({ __builtin_expect(!!(ops->match == fib6_rule_match), 1) ?
>>>>> fib6_rule_match(rule, fl, flags) : ops->match(rule, fl, flags); })
>>>>
>>>> However, in my configuration I have CONFIG_IPV6=m, and so
>>>> fib6_rule_match is not available as a builtin. I think that's why ld is
>>>> complaining about the undefined reference.
>>>
>>> Same here FWIW. CONFIG_IPV6=m.
>>
>> Oh I see,
>> I tried this and it seems to work fine for me, does this also fix your
>> problem? if so, I'll prepare the patch, and thanks for helping!
>> diff --git a/net/core/fib_rules.c b/net/core/fib_rules.c
>> index 51678a528f85..40dfd1f55899 100644
>> --- a/net/core/fib_rules.c
>> +++ b/net/core/fib_rules.c
>> @@ -16,7 +16,7 @@
>> #include <net/ip_tunnels.h>
>> #include <linux/indirect_call_wrapper.h>
>>
>> -#ifdef CONFIG_IPV6_MULTIPLE_TABLES
>> +#if defined(CONFIG_IPV6_MULTIPLE_TABLES) && defined(CONFIG_IPV6)
>
>
> Yes, that works for me.
> You can add this to your patch:
>
> Acked-by: Randy Dunlap <[email protected]> # build-tested

Works for me as well.

Cheers,
Sven