eth: mlx5: fix macsec dependency
Subsystems (4)
PATCH 1/1 eth: mlx5: fix macsec dependency
From: Arnd Bergmann <[email protected]>
Configurations with mlx5 built-in but macsec=m fail to link:
x86_64-linux-ld: drivers/infiniband/hw/mlx5/macsec.o: in function `mlx5r_add_gid_macsec_operations':
macsec.c:(.text+0x77d): undefined reference to `macsec_netdev_is_offloaded'
x86_64-linux-ld: drivers/infiniband/hw/mlx5/macsec.o: in function `mlx5r_del_gid_macsec_operations':
macsec.c:(.text+0xe81): undefined reference to `macsec_netdev_is_offloaded'
Fix the dependency so this configuration cannot happen.
---
First seen on next-20260615, but probably an old bug.
I could not figure out what caused this error to appear, I have not seen this combination in many years of randconfig builds that look like they had the bug. My best guess is that there are so many other dependencies that it is simply very unlikely.
--- drivers/net/ethernet/mellanox/mlx5/core/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/mellanox/mlx5/core/Kconfig +1 -1
@@ -144,7 +144,7 @@ config MLX5_CORE_IPOIB config MLX5_MACSEC bool "Connect-X support for MACSec offload" depends on MLX5_CORE_EN - depends on MACSEC + depends on MACSEC=y || MACSEC=MLX5_CORE default n help Build support for MACsec cryptography-offload acceleration in the NIC.
Signature · 1 line
2.39.5
Quoted 4 lines · Arnd Bergmann
From: Arnd Bergmann <[email protected]>
Configurations with mlx5 built-in but macsec=m fail to link:
Quoted 8 lines
x86_64-linux-ld:
drivers/infiniband/hw/mlx5/macsec.o: in function `mlx5r_add_gid_macsec_operations':
macsec.c:(.text+0x77d): undefined reference to `macsec_netdev_is_offloaded'
x86_64-linux-ld:drivers/infiniband/hw/mlx5/macsec.o: in function `mlx5r_del_gid_macsec_operations':
macsec.c:(.text+0xe81): undefined reference to `macsec_netdev_is_offloaded'Fix the dependency so this configuration cannot happen.
Signed-off-by Arnd Bergmann <[email protected]>
Quoted 2 lines
drivers/net/ethernet/mellanox/mlx5/core/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
...
drivers/net/ethernet/mellanox/mlx5/core/Kconfig config MLX5_CORE_IPOIB · line 147
Quoted 6 lines
drivers/net/ethernet/mellanox/mlx5/core/Kconfig +1
-1@@ -144,7 +144,7 @@ config MLX5_CORE_IPOIB config MLX5_MACSEC bool "Connect-X support for MACSec offload" depends on MLX5_CORE_EN - depends on MACSEC + depends on MACSEC=y || MACSEC=MLX5_CORE
I'd never seen this 'configA=configB' syntax, cool.
Signature · 1 line
Sabrina
This patch was applied to netdev/net.git (main) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <[email protected]>:
Quoted 10 lines · On Mon, 22 Jun 2026 14:41:07 +0200 you wrote:
From: Arnd Bergmann <[email protected]>
Configurations with mlx5 built-in but macsec=m fail to link:
x86_64-linux-ld:
drivers/infiniband/hw/mlx5/macsec.o: in function `mlx5r_add_gid_macsec_operations':
macsec.c:(.text+0x77d): undefined reference to `macsec_netdev_is_offloaded'
x86_64-linux-ld:drivers/infiniband/hw/mlx5/macsec.o: in function `mlx5r_del_gid_macsec_operations':
macsec.c:(.text+0xe81): undefined reference to `macsec_netdev_is_offloaded'[...]
Here is the summary with links:
- [net] eth: mlx5: fix macsec dependency
https://git.kernel.org/netdev/net/c/87ab8276ed24
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html