[PATCH] net: wan/fsl_ucc_hdlc: cleanup ucc_hdlc_poll
Christophe Leroy (CS GROUP)
chleroy at kernel.org
Thu Mar 26 23:17:18 AEDT 2026
Le 26/03/2026 à 11:02, Tomas Alvarez Vanoli a écrit :
> Immediately after setting to 0 we are adding to it, and subtracting 0
> from budget. Replace with just assignment and no subtraction.
>
> Signed-off-by: Tomas Alvarez Vanoli <tomas.alvarez-vanoli at hitachienergy.com>
Reviewed-by: Christophe Leroy (CS GROUP) <chleroy at kernel.org>
> ---
> drivers/net/wan/fsl_ucc_hdlc.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/net/wan/fsl_ucc_hdlc.c b/drivers/net/wan/fsl_ucc_hdlc.c
> index b72ab9951875e..3bd57527b1be6 100644
> --- a/drivers/net/wan/fsl_ucc_hdlc.c
> +++ b/drivers/net/wan/fsl_ucc_hdlc.c
> @@ -628,8 +628,7 @@ static int ucc_hdlc_poll(struct napi_struct *napi, int budget)
> hdlc_tx_done(priv);
> spin_unlock(&priv->lock);
>
> - howmany = 0;
> - howmany += hdlc_rx_done(priv, budget - howmany);
> + howmany = hdlc_rx_done(priv, budget);
>
> if (howmany < budget) {
> napi_complete_done(napi, howmany);
> --
> 2.47.3
>
>
More information about the Linuxppc-dev
mailing list