[<prev] [next>] [day] [month] [year] [list]
Message-ID: <55A9367D.6040001@gmail.com>
Date: Fri, 17 Jul 2015 10:08:13 -0700
From: Florian Fainelli <f.fainelli@...il.com>
To: Nicholas Krause <xerofoify@...il.com>
CC: netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] bcmsysport:Fix error handling in the function bcm_sysport_init_rx_ring
On 17/07/15 05:13, Nicholas Krause wrote:
> This fixes the error handling in the function bcm_sysport_init_rx_ringi
> after calling the function rdma_enable_set to make sure the return value
> is equal to zero and if not print on the console failed to enable RDMA
> for the device and return the failed error code returned by
> rdma_enable_set.
Subject should be starting with "net: systemport: ", otherwise, this
looks good to me:
Reviewed-by: Florian Fainelli <f.fainelli@...il.com>
Tested-by: Florian Fainelli <f.fainelli@...il.com>
>
> Signed-off-by: Nicholas Krause <xerofoify@...il.com>
> ---
> drivers/net/ethernet/broadcom/bcmsysport.c | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/broadcom/bcmsysport.c b/drivers/net/ethernet/broadcom/bcmsysport.c
> index 4566cdf..27a7b36 100644
> --- a/drivers/net/ethernet/broadcom/bcmsysport.c
> +++ b/drivers/net/ethernet/broadcom/bcmsysport.c
> @@ -1365,7 +1365,12 @@ static int bcm_sysport_init_rx_ring(struct bcm_sysport_priv *priv)
> /* Initialize HW, ensure RDMA is disabled */
> reg = rdma_readl(priv, RDMA_STATUS);
> if (!(reg & RDMA_DISABLED))
> - rdma_enable_set(priv, 0);
> + ret = rdma_enable_set(priv, 0);
> +
> + if (ret) {
> + netif_err(priv, hw, priv->netdev, "failed to enable RDMA\n");
> + return ret;
> + }
>
> rdma_writel(priv, 0, RDMA_WRITE_PTR_LO);
> rdma_writel(priv, 0, RDMA_WRITE_PTR_HI);
>
--
Florian
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists