* [PATCH 1/4] common/sfc_efx/base: fix autoneg detection with netport MCDI
[not found] <20250905144514.11698-1-ivan.malov@arknetworks.am>
@ 2025-09-05 14:45 ` Ivan Malov
2025-09-05 14:45 ` [PATCH 2/4] common/sfc_efx/base: default to auto fcntl " Ivan Malov
2025-09-05 14:45 ` [PATCH 3/4] common/sfc_efx/base: fix auto FEC selection for " Ivan Malov
2 siblings, 0 replies; 3+ messages in thread
From: Ivan Malov @ 2025-09-05 14:45 UTC (permalink / raw)
To: dev
Cc: Andrew Rybchenko, Andy Moreton, Pieter Jansen Van Vuuren,
Viacheslav Galaktionov, stable
Currently, the code consults both local AN support status, which is stable,
and the dynamic AN status on the link partner, which is flaky. Exclude the
latter, as the client should have the opportunity to re-initiate AN afresh.
Fixes: 2a5cf77e6de8 ("common/sfc_efx/base: provide PHY link get method on Medford4")
Cc: stable@dpdk.org
Signed-off-by: Ivan Malov <ivan.malov@arknetworks.am>
Reviewed-by: Andy Moreton <andy.moreton@amd.com>
---
drivers/common/sfc_efx/base/efx_np.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/common/sfc_efx/base/efx_np.c b/drivers/common/sfc_efx/base/efx_np.c
index a19c986691..599daa7a60 100644
--- a/drivers/common/sfc_efx/base/efx_np.c
+++ b/drivers/common/sfc_efx/base/efx_np.c
@@ -397,8 +397,7 @@ efx_np_link_state(
v3_flags = MCDI_OUT_DWORD(req, LINK_STATE_OUT_V3_FLAGS);
memset(lsp, 0, sizeof (*lsp));
- if (status_flags & (1U << MC_CMD_LINK_STATUS_FLAGS_AN_ABLE) &&
- MCDI_OUT_DWORD(req, LINK_STATE_OUT_V2_LOCAL_AN_SUPPORT) !=
+ if (MCDI_OUT_DWORD(req, LINK_STATE_OUT_V2_LOCAL_AN_SUPPORT) !=
MC_CMD_AN_NONE)
lsp->enls_an_supported = B_TRUE;
@@ -437,7 +436,7 @@ efx_np_link_state(
MCDI_OUT2(req, const uint8_t, LINK_STATE_OUT_ADVERTISED_ABILITIES),
&lsp->enls_adv_cap_mask);
- if (lsp->enls_an_supported != B_FALSE)
+ if (status_flags & (1U << MC_CMD_LINK_STATUS_FLAGS_AN_ABLE))
lsp->enls_lp_cap_mask |= 1U << EFX_PHY_CAP_AN;
efx_np_cap_hw_data_to_sw_mask(
--
2.47.2
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH 2/4] common/sfc_efx/base: default to auto fcntl with netport MCDI
[not found] <20250905144514.11698-1-ivan.malov@arknetworks.am>
2025-09-05 14:45 ` [PATCH 1/4] common/sfc_efx/base: fix autoneg detection with netport MCDI Ivan Malov
@ 2025-09-05 14:45 ` Ivan Malov
2025-09-05 14:45 ` [PATCH 3/4] common/sfc_efx/base: fix auto FEC selection for " Ivan Malov
2 siblings, 0 replies; 3+ messages in thread
From: Ivan Malov @ 2025-09-05 14:45 UTC (permalink / raw)
To: dev
Cc: Andrew Rybchenko, Andy Moreton, Pieter Jansen Van Vuuren,
Viacheslav Galaktionov, stable
Doing so helps to avoid lengthy link renegotiation at start of day.
Fixes: 8e79cd30230d ("common/sfc_efx/base: implement PHY link control for Medford4")
Cc: stable@dpdk.org
Signed-off-by: Ivan Malov <ivan.malov@arknetworks.am>
Reviewed-by: Andy Moreton <andy.moreton@amd.com>
---
drivers/common/sfc_efx/base/efx_np.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/common/sfc_efx/base/efx_np.c b/drivers/common/sfc_efx/base/efx_np.c
index 599daa7a60..69a5a75b6c 100644
--- a/drivers/common/sfc_efx/base/efx_np.c
+++ b/drivers/common/sfc_efx/base/efx_np.c
@@ -1023,6 +1023,9 @@ efx_np_attach(
epp->ep_mac_pdu = ms.enms_pdu;
+ /* For faster link up, use autoneg. flow control by default. */
+ epp->ep_fcntl_autoneg = B_TRUE;
+
/* Subscribe to link change events. */
rc = efx_np_set_event_mask(enp, epp->ep_np_handle, B_TRUE);
if (rc != 0)
--
2.47.2
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH 3/4] common/sfc_efx/base: fix auto FEC selection for netport MCDI
[not found] <20250905144514.11698-1-ivan.malov@arknetworks.am>
2025-09-05 14:45 ` [PATCH 1/4] common/sfc_efx/base: fix autoneg detection with netport MCDI Ivan Malov
2025-09-05 14:45 ` [PATCH 2/4] common/sfc_efx/base: default to auto fcntl " Ivan Malov
@ 2025-09-05 14:45 ` Ivan Malov
2 siblings, 0 replies; 3+ messages in thread
From: Ivan Malov @ 2025-09-05 14:45 UTC (permalink / raw)
To: dev
Cc: Andrew Rybchenko, Andy Moreton, Pieter Jansen Van Vuuren,
Viacheslav Galaktionov, stable
Currently, the driver's request to have automatic FEC is ignored. Fix that.
Fixes: 8e79cd30230d ("common/sfc_efx/base: implement PHY link control for Medford4")
Cc: stable@dpdk.org
Signed-off-by: Ivan Malov <ivan.malov@arknetworks.am>
Reviewed-by: Andy Moreton <andy.moreton@amd.com>
---
drivers/common/sfc_efx/base/efx_np.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/common/sfc_efx/base/efx_np.c b/drivers/common/sfc_efx/base/efx_np.c
index 69a5a75b6c..54305ee61e 100644
--- a/drivers/common/sfc_efx/base/efx_np.c
+++ b/drivers/common/sfc_efx/base/efx_np.c
@@ -1368,8 +1368,10 @@ efx_np_link_ctrl(
}
}
- /* The software mask may have no requested FEC bits. Default is NONE. */
- cap_enum_hw = MC_CMD_FEC_NONE;
+ if ((cap_mask_sw & EFX_PHY_CAP_FEC_MASK) == 0)
+ cap_enum_hw = MC_CMD_FEC_NONE;
+ else
+ cap_enum_hw = MC_CMD_FEC_AUTO;
/*
* Compared to older EF10 interface, in netport MCDI, FEC mode is a
--
2.47.2
^ permalink raw reply [flat|nested] 3+ messages in thread