[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <55B71E99.50807@ti.com>
Date: Tue, 28 Jul 2015 11:48:01 +0530
From: Mugunthan V N <mugunthanvnm@...com>
To: Francois Romieu <romieu@...zoreil.com>
CC: <netdev@...r.kernel.org>, <davem@...emloft.net>
Subject: Re: [net-next PATCH 2/2] drivers: net: cpsw: add separate napi for
tx packet handling for performance improvment
On Tuesday 28 July 2015 02:52 AM, Francois Romieu wrote:
> Mugunthan V N <mugunthanvnm@...com> :
> [...]
>> diff --git a/drivers/net/ethernet/ti/cpsw.c b/drivers/net/ethernet/ti/cpsw.c
>> index d68d759..4f98537 100644
>> --- a/drivers/net/ethernet/ti/cpsw.c
>> +++ b/drivers/net/ethernet/ti/cpsw.c
>> @@ -752,13 +753,22 @@ static irqreturn_t cpsw_tx_interrupt(int irq, void *dev_id)
>> struct cpsw_priv *priv = dev_id;
>>
>> cpdma_ctlr_eoi(priv->dma, CPDMA_EOI_TX);
>> - cpdma_chan_process(priv->txch, 128);
>> + writel(0, &priv->wr_regs->tx_en);
>> +
>> + if (netif_running(priv->ndev)) {
>> + napi_schedule(&priv->napi_tx);
>> + return IRQ_HANDLED;
>> + }
>
>
> cpsw_ndo_stop calls napi_disable: you can remove netif_running.
>
This netif_running check is to find which interface is up as the
interrupt is shared by both the interfaces. When first interface is down
and second interface is active then napi_schedule for first interface
will fail and second interface napi needs to be scheduled.
So I don't think netif_running needs to be removed.
Regards
Mugunthan V N
--
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