aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSowmini Varadhan <sowmini.varadhan@oracle.com>2014-08-12 10:27:24 -0400
committerDavid S. Miller <davem@davemloft.net>2014-08-13 23:04:46 -0400
commit1f6394e382f137f07136182c591ca8a7eeba6a06 (patch)
tree4271803a31d0e1a584709ac2c6bcd9035eaadf12
parent8356f9d564ed3da4f98e8c44cbd9f397ff9c49a5 (diff)
sunvnet: Do not ask for an ACK for every dring transmit
No need to ask for an ack with every vnet_start_xmit()- the single ACK with DRING_STOPPED is sufficient for the protocol, and we free the sk_buff in vnet_start_xmit itself, so we dont need an ACK back. Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Acked-by: Raghuram Kothakota <raghuram.kothakota@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/sun/sunvnet.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/drivers/net/ethernet/sun/sunvnet.c b/drivers/net/ethernet/sun/sunvnet.c
index d813bfb1a847..238434dcfe02 100644
--- a/drivers/net/ethernet/sun/sunvnet.c
+++ b/drivers/net/ethernet/sun/sunvnet.c
@@ -691,7 +691,15 @@ static int vnet_start_xmit(struct sk_buff *skb, struct net_device *dev)
691 memset(tx_buf+VNET_PACKET_SKIP+skb->len, 0, len - skb->len); 691 memset(tx_buf+VNET_PACKET_SKIP+skb->len, 0, len - skb->len);
692 } 692 }
693 693
694 d->hdr.ack = VIO_ACK_ENABLE; 694 /* We don't rely on the ACKs to free the skb in vnet_start_xmit(),
695 * thus it is safe to not set VIO_ACK_ENABLE for each transmission:
696 * the protocol itself does not require it as long as the peer
697 * sends a VIO_SUBTYPE_ACK for VIO_DRING_STOPPED.
698 *
699 * An ACK for every packet in the ring is expensive as the
700 * sending of LDC messages is slow and affects performance.
701 */
702 d->hdr.ack = VIO_ACK_DISABLE;
695 d->size = len; 703 d->size = len;
696 d->ncookies = port->tx_bufs[dr->prod].ncookies; 704 d->ncookies = port->tx_bufs[dr->prod].ncookies;
697 for (i = 0; i < d->ncookies; i++) 705 for (i = 0; i < d->ncookies; i++)