summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/freescale/gianfar.c
diff options
context:
space:
mode:
authorClaudiu Manoil <claudiu.manoil@freescale.com>2014-05-13 07:19:49 (GMT)
committerJose Rivera <German.Rivera@freescale.com>2014-05-16 13:05:07 (GMT)
commit57a768c25f3da98f21bef6c59f79319d501e7058 (patch)
tree314687f22901b273bf35793bb65be98fdcdc6575 /drivers/net/ethernet/freescale/gianfar.c
parentd042f86579445623a14f0b690d1b2ba9fa7427b2 (diff)
downloadlinux-fsl-qoriq-57a768c25f3da98f21bef6c59f79319d501e7058.tar.xz
gianfar: Revert BQL support in Gianfar
Remove BQL support from Gianfar. The original upstream commit that added BQL to Gianfar does not revert cleanly: "d8a0f1b gianfar: Add support for byte queue limits." BQL has been integrated in Gianfar by the upstream comunity with no clear reason why would it be required / how would it benefit to this particular driver. Only a few drivers have it integrated. BQL adds processing overhead to the Tx path and potential functional issues as it may stop the transmission, which could result in tx timeout. Change-Id: I71e0a99d9616bf86dd98c795a927c89f881b4b08 Signed-off-by: Claudiu Manoil <claudiu.manoil@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/12254 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Jianhua Xie <jianhua.xie@freescale.com> Reviewed-by: Jose Rivera <German.Rivera@freescale.com>
Diffstat (limited to 'drivers/net/ethernet/freescale/gianfar.c')
-rw-r--r--drivers/net/ethernet/freescale/gianfar.c15
1 files changed, 2 insertions, 13 deletions
diff --git a/drivers/net/ethernet/freescale/gianfar.c b/drivers/net/ethernet/freescale/gianfar.c
index e9e170c..5584c39 100644
--- a/drivers/net/ethernet/freescale/gianfar.c
+++ b/drivers/net/ethernet/freescale/gianfar.c
@@ -2123,7 +2123,6 @@ static void free_skb_resources(struct gfar_private *priv)
txq = netdev_get_tx_queue(tx_queue->dev, tx_queue->qindex);
if (tx_queue->tx_skbuff)
free_skb_tx_queue(tx_queue);
- netdev_tx_reset_queue(txq);
}
for (i = 0; i < priv->num_rx_queues; i++) {
@@ -2350,7 +2349,7 @@ static int gfar_start_xmit(struct sk_buff *skb, struct net_device *dev)
int i, rq = 0;
int do_tstamp, do_csum, do_vlan;
u32 bufaddr;
- unsigned int nr_frags, nr_txbds, bytes_sent, fcb_len = 0;
+ unsigned int nr_frags, nr_txbds, fcb_len = 0;
#ifdef CONFIG_AS_FASTPATH
return gfar_asf_start_xmit(skb, dev);
@@ -2413,10 +2412,7 @@ static int gfar_start_xmit(struct sk_buff *skb, struct net_device *dev)
}
/* Update transmit stats */
- bytes_sent = skb->len;
- tx_queue->stats.tx_bytes += bytes_sent;
- /* keep Tx bytes on wire for BQL accounting */
- GFAR_CB(skb)->bytes_sent = bytes_sent;
+ tx_queue->stats.tx_bytes += skb->len;
tx_queue->stats.tx_packets++;
txbdp = txbdp_start = tx_queue->cur_tx;
@@ -2533,8 +2529,6 @@ static int gfar_start_xmit(struct sk_buff *skb, struct net_device *dev)
lstatus |= BD_LFLAG(TXBD_CRC | TXBD_READY) | skb_headlen(skb);
}
- netdev_tx_sent_queue(txq, bytes_sent);
-
/* The powerpc-specific eieio() is used, as wmb() has too strong
* semantics (it requires synchronization between cacheable and
* uncacheable mappings, which eieio doesn't provide and which we
@@ -2706,7 +2700,6 @@ static void gfar_clean_tx_ring(struct gfar_priv_tx_q *tx_queue)
int i;
int howmany = 0;
int tqi = tx_queue->qindex;
- unsigned int bytes_sent = 0;
u32 lstatus;
size_t buflen;
@@ -2801,8 +2794,6 @@ static void gfar_clean_tx_ring(struct gfar_priv_tx_q *tx_queue)
bdp = next_txbd(bdp, base, tx_ring_size);
}
- bytes_sent += GFAR_CB(skb)->bytes_sent;
-
gfar_recycle_skb(skb);
tx_queue->tx_skbuff[skb_dirtytx] = NULL;
@@ -2825,8 +2816,6 @@ static void gfar_clean_tx_ring(struct gfar_priv_tx_q *tx_queue)
/* Update dirty indicators */
tx_queue->skb_dirtytx = skb_dirtytx;
tx_queue->dirty_tx = bdp;
-
- netdev_tx_completed_queue(txq, howmany, bytes_sent);
}
static struct sk_buff *gfar_alloc_skb(struct net_device *dev)