Re: [PATCH net-next 1/3] gianfar: Add support for byte queue limits.

From
Paul Gortmaker <hidden>
Date
2012-03-18 21:04:08
Also in
linuxppc-dev
Reply to
Eric Dumazet, 2012-03-18
On Sun, Mar 18, 2012 at 4:20 PM, Eric Dumazet [off-list ref] wrote:
Le dimanche 18 mars 2012 à 12:56 -0400, Paul Gortmaker a écrit :

...
quoted
               * we add this skb back into the pool, if it's the right size
@@ -2557,13 +2568,15 @@ static int gfar_clean_tx_ring(struct gfar_priv_tx_q *tx_queue)
      }

      /* If we freed a buffer, we can restart transmission, if necessary */
-     if (__netif_subqueue_stopped(dev, tx_queue->qindex) && tx_queue->num_txbdfree)
-             netif_wake_subqueue(dev, tx_queue->qindex);
+     if (__netif_subqueue_stopped(dev, tqi) && tx_queue->num_txbdfree)
+             netif_wake_subqueue(dev, tqi);
You can use netif_tx_queue_stopped(txq) here instead of
__netif_subqueue_stopped(dev, tqi)
Yes, and it looks better too.  I will do it as a patch #4 since I think
there is some small value in leaving the above patch chunk alone,
since it makes it clear that it was just the introduction of a local
variable and the code was otherwise unchanged here.

Will resend shortly....

Thanks,
Paul.
---
quoted
      /* Update dirty indicators */
      tx_queue->skb_dirtytx = skb_dirtytx;
      tx_queue->dirty_tx = bdp;

+     netdev_tx_completed_queue(txq, howmany, bytes_sent);
+
      return howmany;
 }

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Thread (17 messages) 17 messages, 3 authors, 2012-03-19
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help