[SRU][F:linux-bluefield][PATCH v1 1/1] UBUNTU: SAUCE: mlxbf-gige: autonegotiation fails to complete on BF2

Asmaa Mnebhi asmaa at nvidia.com
Mon Apr 29 19:31:48 UTC 2024


@Tim Gardner<mailto:tim.gardner at canonical.com> @Bartlomiej Zolnierkiewicz<mailto:bartlomiej.zolnierkiewicz at canonical.com>, could you also review this for Focal please?



Thanks.

Asmaa



++ at Vladimir Sokolovsky<mailto:vlad at nvidia.com>



> -----Original Message-----

> From: Asmaa Mnebhi <asmaa at nvidia.com>

> Sent: Thursday, April 18, 2024 5:11 PM

> To: kernel-team at lists.ubuntu.com

> Cc: Asmaa Mnebhi <asmaa at nvidia.com>; David Thompson

> <davthompson at nvidia.com>

> Subject: [SRU][F:linux-bluefield][PATCH v1 1/1] UBUNTU: SAUCE: mlxbf-gige:

> autonegotiation fails to complete on BF2

>

> BugLink: https://bugs.launchpad.net/bugs/2062384

>

> During their reboot test, QA found an intermittent issue where the OOB link is

> down.

> The link is down because the KSZ9031 PHY fails to complete autonegotiation.

> Even under "normal" circumstances where autonegotiation completes, it takes

> an abnormal time to do so (on average, at least 8 seconds).

>

> Hence, the hardware team and Microchip are involved in this debug but the root

> cause is still unknown.

> In the meantime, we need to provide a software workaround since customers are

> starting to see this issue as well.

>

> Signed-off-by: Asmaa Mnebhi <asmaa at nvidia.com<mailto:asmaa at nvidia.com>>

> Reviewed-by: David Thompson <davthompson at nvidia.com<mailto:davthompson at nvidia.com>>

> ---

>  .../mellanox/mlxbf_gige/mlxbf_gige_main.c         | 15 +++++++++++++++

>  1 file changed, 15 insertions(+)

>

> diff --git a/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c

> b/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c

> index d322d9fb06ba..635009a209d5 100644

> --- a/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c

> +++ b/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c

> @@ -138,6 +138,7 @@ static int mlxbf_gige_open(struct net_device *netdev)  {

>            struct mlxbf_gige *priv = netdev_priv(netdev);

>            struct phy_device *phydev = netdev->phydev;

> +         u8 timeout = 10;

>            u64 control;

>            u64 int_en;

>            int err;

> @@ -163,6 +164,20 @@ static int mlxbf_gige_open(struct net_device *netdev)

>

>            phy_start(phydev);

>

> +         /* On BlueField-2 systems, the KSZ9031 PHY hardware could fail

> +         * to complete autonegotiation and so the link remains down.

> +         * The software workaround is to restart autonegotiation.

> +         */

> +         while (timeout) {

> +                       if (phy_aneg_done(phydev))

> +                                      break;

> +                       msleep(1000);

> +                       timeout--;

> +         };

> +

> +         if (timeout == 0)

> +                       phy_restart_aneg(phydev);

> +

>            err = mlxbf_gige_tx_init(priv);

>            if (err)

>                           goto free_irqs;

> --

> 2.30.1


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/kernel-team/attachments/20240429/cd4c59db/attachment.html>


More information about the kernel-team mailing list