]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
RDMA/mlx5: Add support for 200Gbps per lane speeds
authorPatrisious Haddad <phaddad@nvidia.com>
Tue, 13 May 2025 11:03:41 +0000 (14:03 +0300)
committerLeon Romanovsky <leon@kernel.org>
Sun, 18 May 2025 07:52:21 +0000 (03:52 -0400)
Add support for 200Gbps per lane speeds speed when querying PTYS and
report it back correctly when needed.

Signed-off-by: Patrisious Haddad <phaddad@nvidia.com>
Reviewed-by: Maor Gottlieb <maorg@nvidia.com>
Link: https://patch.msgid.link/b842d2f523e9b82e221378c444ebd5860d612959.1747134197.git.leon@kernel.org
Signed-off-by: Leon Romanovsky <leon@kernel.org>
drivers/infiniband/hw/mlx5/main.c

index 32ad066c3c4a995b48fdb028f77c0c734ccfb738..ce7610740412a41a9f5090928c613cd796db81f9 100644 (file)
@@ -485,6 +485,10 @@ static int translate_eth_ext_proto_oper(u32 eth_proto_oper, u16 *active_speed,
                *active_width = IB_WIDTH_2X;
                *active_speed = IB_SPEED_NDR;
                break;
+       case MLX5E_PROT_MASK(MLX5E_200GAUI_1_200GBASE_CR1_KR1):
+               *active_width = IB_WIDTH_1X;
+               *active_speed = IB_SPEED_XDR;
+               break;
        case MLX5E_PROT_MASK(MLX5E_400GAUI_8_400GBASE_CR8):
                *active_width = IB_WIDTH_8X;
                *active_speed = IB_SPEED_HDR;
@@ -493,10 +497,18 @@ static int translate_eth_ext_proto_oper(u32 eth_proto_oper, u16 *active_speed,
                *active_width = IB_WIDTH_4X;
                *active_speed = IB_SPEED_NDR;
                break;
+       case MLX5E_PROT_MASK(MLX5E_400GAUI_2_400GBASE_CR2_KR2):
+               *active_width = IB_WIDTH_2X;
+               *active_speed = IB_SPEED_XDR;
+               break;
        case MLX5E_PROT_MASK(MLX5E_800GAUI_8_800GBASE_CR8_KR8):
                *active_width = IB_WIDTH_8X;
                *active_speed = IB_SPEED_NDR;
                break;
+       case MLX5E_PROT_MASK(MLX5E_800GAUI_4_800GBASE_CR4_KR4):
+               *active_width = IB_WIDTH_4X;
+               *active_speed = IB_SPEED_XDR;
+               break;
        default:
                return -EINVAL;
        }