ACK: [SRU][F:linux-bluefield][PATCH v1 1/1] UBUNTU: SAUCE: mlxbf-gige: Enable the OOB port in mlxbf_gige_open
Bartlomiej Zolnierkiewicz
bartlomiej.zolnierkiewicz at canonical.com
Thu Sep 21 08:40:35 UTC 2023
Acked-by: Bartlomiej Zolnierkiewicz <bartlomiej.zolnierkiewicz at canonical.com>
Please remember to update the email titles when sending new patch
versions (this one was not updated to v2).
--
Best regards,
Bartlomiej
On Wed, Sep 20, 2023 at 7:39 PM Asmaa Mnebhi <asmaa at nvidia.com> wrote:
>
> BugLink: https://bugs.launchpad.net/bugs/2035128
>
> At the moment, the OOB port is enabled in the mlxbf_gige_probe
> function. If the mlxbf_gige_open is not executed, this could cause
> pause frames to increase in the case where there is high backgroud
> traffic. This results in clogging the BMC port as well.
> Move enabling the OOB port to mlxbf_gige_open.
>
> Signed-off-by: Asmaa Mnebhi <asmaa at nvidia.com>
> ---
> .../ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c | 12 ++++++------
> 1 file changed, 6 insertions(+), 6 deletions(-)
>
> 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 3dd60989512f..d322d9fb06ba 100644
> --- a/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c
> +++ b/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c
> @@ -138,9 +138,15 @@ static int mlxbf_gige_open(struct net_device *netdev)
> {
> struct mlxbf_gige *priv = netdev_priv(netdev);
> struct phy_device *phydev = netdev->phydev;
> + u64 control;
> u64 int_en;
> int err;
>
> + /* Perform general init of GigE block */
> + control = readq(priv->base + MLXBF_GIGE_CONTROL);
> + control |= MLXBF_GIGE_CONTROL_PORT_EN;
> + writeq(control, priv->base + MLXBF_GIGE_CONTROL);
> +
> err = mlxbf_gige_request_irqs(priv);
> if (err)
> return err;
> @@ -291,7 +297,6 @@ static int mlxbf_gige_probe(struct platform_device *pdev)
> void __iomem *base;
> int addr, phy_irq;
> u32 version;
> - u64 control;
> int err;
>
> version = 0;
> @@ -331,11 +336,6 @@ static int mlxbf_gige_probe(struct platform_device *pdev)
> if (IS_ERR(plu_base))
> return PTR_ERR(plu_base);
>
> - /* Perform general init of GigE block */
> - control = readq(base + MLXBF_GIGE_CONTROL);
> - control |= MLXBF_GIGE_CONTROL_PORT_EN;
> - writeq(control, base + MLXBF_GIGE_CONTROL);
> -
> netdev = devm_alloc_etherdev(&pdev->dev, sizeof(*priv));
> if (!netdev)
> return -ENOMEM;
More information about the kernel-team
mailing list