* [PATCH] [net-next] net/mlx5e: fix ip6_dst_lookup link failure
@ 2026-02-04 13:00 Arnd Bergmann
2026-02-06 2:09 ` Jakub Kicinski
2026-02-06 9:56 ` [PATCH] " Jianbo Liu
0 siblings, 2 replies; 5+ messages in thread
From: Arnd Bergmann @ 2026-02-04 13:00 UTC (permalink / raw)
To: Saeed Mahameed, Leon Romanovsky, Tariq Toukan, Mark Bloch,
Andrew Lunn, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Jianbo Liu
Cc: Arnd Bergmann, Cosmin Ratiu, Raed Salem, netdev, linux-rdma,
linux-kernel
From: Arnd Bergmann <arnd@arndb.de>
Changing mlx5 to call ip6_dst_lookup() means it now fails to link
when IPv6 is a loadable module but ipsec support is built-in:
ipsec.c:(.text+0x1061): undefined reference to `ip6_dst_lookup'
Add a Kconfig dependency that removes avoids this configuration.
Fixes: e35d7da8dd9e ("net/mlx5e: Use ip6_dst_lookup instead of ipv6_dst_lookup_flow for MAC init")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/net/ethernet/mellanox/mlx5/core/Kconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
index 9cf394c66939..c298efe93f97 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
+++ b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
@@ -154,6 +154,7 @@ config MLX5_EN_IPSEC
depends on MLX5_CORE_EN
depends on XFRM_OFFLOAD
depends on INET_ESP_OFFLOAD || INET6_ESP_OFFLOAD
+ depends on IPV6!=m || MLX5_CORE=m
help
Build support for IPsec cryptography-offload acceleration in the NIC.
--
2.39.5
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [net-next] net/mlx5e: fix ip6_dst_lookup link failure
2026-02-04 13:00 [PATCH] [net-next] net/mlx5e: fix ip6_dst_lookup link failure Arnd Bergmann
@ 2026-02-06 2:09 ` Jakub Kicinski
2026-02-06 9:56 ` [PATCH] " Jianbo Liu
1 sibling, 0 replies; 5+ messages in thread
From: Jakub Kicinski @ 2026-02-06 2:09 UTC (permalink / raw)
To: arnd
Cc: Jakub Kicinski, arnd, tariqt, leon, mbloch, jianbol, linux-kernel,
pabeni, saeedm, davem, andrew+netdev, raeds, edumazet, linux-rdma,
netdev, cratiu
This is an AI-generated review of your patch. The human sending this
email has considered the AI review valid, or at least plausible.
For local reproduction steps see https://netdev-ai.bots.linux.dev/ai-local.html
---
net/mlx5e: fix ip6_dst_lookup link failure
This commit adds a Kconfig dependency to prevent a link failure when IPv6
is a loadable module but mlx5 ipsec support is built-in.
Fixes: e35d7da8dd9e ("net/mlx5e: Use ip6_dst_lookup instead of ipv6_dst_lookup_flow for MAC init")
> Add a Kconfig dependency that removes avoids this configuration.
This isn't a bug, but "removes avoids" appears to be an editing artifact
where two verbs were left in place of one.
--
pw-bot: cr
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] [net-next] net/mlx5e: fix ip6_dst_lookup link failure
2026-02-04 13:00 [PATCH] [net-next] net/mlx5e: fix ip6_dst_lookup link failure Arnd Bergmann
2026-02-06 2:09 ` Jakub Kicinski
@ 2026-02-06 9:56 ` Jianbo Liu
2026-02-06 10:00 ` Arnd Bergmann
1 sibling, 1 reply; 5+ messages in thread
From: Jianbo Liu @ 2026-02-06 9:56 UTC (permalink / raw)
To: Arnd Bergmann, Saeed Mahameed, Leon Romanovsky, Tariq Toukan,
Mark Bloch, Andrew Lunn, David S. Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni
Cc: Arnd Bergmann, Cosmin Ratiu, Raed Salem, netdev, linux-rdma,
linux-kernel
On 2/4/2026 9:00 PM, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
>
> Changing mlx5 to call ip6_dst_lookup() means it now fails to link
> when IPv6 is a loadable module but ipsec support is built-in:
>
> ipsec.c:(.text+0x1061): undefined reference to `ip6_dst_lookup'
>
> Add a Kconfig dependency that removes avoids this configuration.
>
> Fixes: e35d7da8dd9e ("net/mlx5e: Use ip6_dst_lookup instead of ipv6_dst_lookup_flow for MAC init")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> drivers/net/ethernet/mellanox/mlx5/core/Kconfig | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
> index 9cf394c66939..c298efe93f97 100644
> --- a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
> +++ b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
> @@ -154,6 +154,7 @@ config MLX5_EN_IPSEC
> depends on MLX5_CORE_EN
> depends on XFRM_OFFLOAD
> depends on INET_ESP_OFFLOAD || INET6_ESP_OFFLOAD
> + depends on IPV6!=m || MLX5_CORE=m
Thanks for the fix.
I received a report for this same error here:
https://lore.kernel.org/oe-kbuild-all/202512261850.P5Jp5BSz-lkp@intel.com/
We were about to send a fix ourselves, it is to simply add:
depends on IPV6 || !IPV6
Is there a specific reason to prefer "depends on IPV6!=m ||
MLX5_CORE=m"? To me, the IPV6 || !IPV6 syntax seems a bit cleaner.
Thanks!
Jianbo
> help
> Build support for IPsec cryptography-offload acceleration in the NIC.
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] [net-next] net/mlx5e: fix ip6_dst_lookup link failure
2026-02-06 9:56 ` [PATCH] " Jianbo Liu
@ 2026-02-06 10:00 ` Arnd Bergmann
2026-02-06 11:45 ` Jianbo Liu
0 siblings, 1 reply; 5+ messages in thread
From: Arnd Bergmann @ 2026-02-06 10:00 UTC (permalink / raw)
To: Jianbo Liu, Arnd Bergmann, Saeed Mahameed, Leon Romanovsky,
Tariq Toukan, Mark Bloch, Andrew Lunn, David S . Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni
Cc: Cosmin Ratiu, Raed Salem, Netdev, linux-rdma, linux-kernel
On Fri, Feb 6, 2026, at 10:56, Jianbo Liu wrote:
> On 2/4/2026 9:00 PM, Arnd Bergmann wrote:
>> diff --git a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
>> index 9cf394c66939..c298efe93f97 100644
>> --- a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
>> +++ b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
>> @@ -154,6 +154,7 @@ config MLX5_EN_IPSEC
>> depends on MLX5_CORE_EN
>> depends on XFRM_OFFLOAD
>> depends on INET_ESP_OFFLOAD || INET6_ESP_OFFLOAD
>> + depends on IPV6!=m || MLX5_CORE=m
>
> Thanks for the fix.
> I received a report for this same error here:
> https://lore.kernel.org/oe-kbuild-all/202512261850.P5Jp5BSz-lkp@intel.com/
>
> We were about to send a fix ourselves, it is to simply add:
> depends on IPV6 || !IPV6
> Is there a specific reason to prefer "depends on IPV6!=m ||
> MLX5_CORE=m"? To me, the IPV6 || !IPV6 syntax seems a bit cleaner.
MLX5_EN_IPSEC needs the dependency, but this is a 'bool' symbols.
The "IPV6 || !IPV6" syntax only works on tristate symbols, so you'd
have to put it into CONFIG_MLX5_CORE itself, but MLX5_CORE does
not actually have the IPV6 dependency unless MLX5_EN_IPSEC is
enabled.
Arnd
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] [net-next] net/mlx5e: fix ip6_dst_lookup link failure
2026-02-06 10:00 ` Arnd Bergmann
@ 2026-02-06 11:45 ` Jianbo Liu
0 siblings, 0 replies; 5+ messages in thread
From: Jianbo Liu @ 2026-02-06 11:45 UTC (permalink / raw)
To: Arnd Bergmann, Arnd Bergmann, Saeed Mahameed, Leon Romanovsky,
Tariq Toukan, Mark Bloch, Andrew Lunn, David S . Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni
Cc: Cosmin Ratiu, Raed Salem, Netdev, linux-rdma, linux-kernel
On 2/6/2026 6:00 PM, Arnd Bergmann wrote:
> On Fri, Feb 6, 2026, at 10:56, Jianbo Liu wrote:
>> On 2/4/2026 9:00 PM, Arnd Bergmann wrote:
>>> diff --git a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
>>> index 9cf394c66939..c298efe93f97 100644
>>> --- a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
>>> +++ b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
>>> @@ -154,6 +154,7 @@ config MLX5_EN_IPSEC
>>> depends on MLX5_CORE_EN
>>> depends on XFRM_OFFLOAD
>>> depends on INET_ESP_OFFLOAD || INET6_ESP_OFFLOAD
>>> + depends on IPV6!=m || MLX5_CORE=m
>>
>> Thanks for the fix.
>> I received a report for this same error here:
>> https://lore.kernel.org/oe-kbuild-all/202512261850.P5Jp5BSz-lkp@intel.com/
>>
>> We were about to send a fix ourselves, it is to simply add:
>> depends on IPV6 || !IPV6
>> Is there a specific reason to prefer "depends on IPV6!=m ||
>> MLX5_CORE=m"? To me, the IPV6 || !IPV6 syntax seems a bit cleaner.
>
> MLX5_EN_IPSEC needs the dependency, but this is a 'bool' symbols.
>
> The "IPV6 || !IPV6" syntax only works on tristate symbols, so you'd
> have to put it into CONFIG_MLX5_CORE itself, but MLX5_CORE does
> not actually have the IPV6 dependency unless MLX5_EN_IPSEC is
> enabled.
>
Right, I meant moving the dependency to CONFIG_MLX5_CORE.
Your patch restricts only MLX5_EN_IPSEC, which causes the link error,
even if it silently disables IPsec in that specific config.
Acked-by: Jianbo Liu <jianbol@nvidia.com>
> Arnd
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2026-02-06 11:45 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-04 13:00 [PATCH] [net-next] net/mlx5e: fix ip6_dst_lookup link failure Arnd Bergmann
2026-02-06 2:09 ` Jakub Kicinski
2026-02-06 9:56 ` [PATCH] " Jianbo Liu
2026-02-06 10:00 ` Arnd Bergmann
2026-02-06 11:45 ` Jianbo Liu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox