aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/marvell/mvneta.c
diff options
context:
space:
mode:
authorArnaud Ebalard <arno@natisbad.org>2014-01-16 02:20:18 -0500
committerDavid S. Miller <davem@davemloft.net>2014-01-16 18:15:43 -0500
commit0713a86a65ea4029f700633cb806c35c51b36af2 (patch)
treee9f6e6d669f09713408877410594d23119102f35 /drivers/net/ethernet/marvell/mvneta.c
parentf19fadfce8717d1da5e38c12d0dbe473bc3a7626 (diff)
net: mvneta: mvneta_tx_done_gbe() cleanups
mvneta_tx_done_gbe() return value and third parameter are no more used. This patch changes the function prototype and removes a useless variable where the function is called. Reviewed-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Arnaud Ebalard <arno@natisbad.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/marvell/mvneta.c')
-rw-r--r--drivers/net/ethernet/marvell/mvneta.c17
1 files changed, 4 insertions, 13 deletions
diff --git a/drivers/net/ethernet/marvell/mvneta.c b/drivers/net/ethernet/marvell/mvneta.c
index f5fc7a249880..8c5150124b5e 100644
--- a/drivers/net/ethernet/marvell/mvneta.c
+++ b/drivers/net/ethernet/marvell/mvneta.c
@@ -1704,30 +1704,23 @@ static void mvneta_txq_done_force(struct mvneta_port *pp,
1704/* Handle tx done - called in softirq context. The <cause_tx_done> argument 1704/* Handle tx done - called in softirq context. The <cause_tx_done> argument
1705 * must be a valid cause according to MVNETA_TXQ_INTR_MASK_ALL. 1705 * must be a valid cause according to MVNETA_TXQ_INTR_MASK_ALL.
1706 */ 1706 */
1707static u32 mvneta_tx_done_gbe(struct mvneta_port *pp, u32 cause_tx_done, 1707static void mvneta_tx_done_gbe(struct mvneta_port *pp, u32 cause_tx_done)
1708 int *tx_todo)
1709{ 1708{
1710 struct mvneta_tx_queue *txq; 1709 struct mvneta_tx_queue *txq;
1711 u32 tx_done = 0;
1712 struct netdev_queue *nq; 1710 struct netdev_queue *nq;
1713 1711
1714 *tx_todo = 0;
1715 while (cause_tx_done) { 1712 while (cause_tx_done) {
1716 txq = mvneta_tx_done_policy(pp, cause_tx_done); 1713 txq = mvneta_tx_done_policy(pp, cause_tx_done);
1717 1714
1718 nq = netdev_get_tx_queue(pp->dev, txq->id); 1715 nq = netdev_get_tx_queue(pp->dev, txq->id);
1719 __netif_tx_lock(nq, smp_processor_id()); 1716 __netif_tx_lock(nq, smp_processor_id());
1720 1717
1721 if (txq->count) { 1718 if (txq->count)
1722 tx_done += mvneta_txq_done(pp, txq); 1719 mvneta_txq_done(pp, txq);
1723 *tx_todo += txq->count;
1724 }
1725 1720
1726 __netif_tx_unlock(nq); 1721 __netif_tx_unlock(nq);
1727 cause_tx_done &= ~((1 << txq->id)); 1722 cause_tx_done &= ~((1 << txq->id));
1728 } 1723 }
1729
1730 return tx_done;
1731} 1724}
1732 1725
1733/* Compute crc8 of the specified address, using a unique algorithm , 1726/* Compute crc8 of the specified address, using a unique algorithm ,
@@ -1961,9 +1954,7 @@ static int mvneta_poll(struct napi_struct *napi, int budget)
1961 1954
1962 /* Release Tx descriptors */ 1955 /* Release Tx descriptors */
1963 if (cause_rx_tx & MVNETA_TX_INTR_MASK_ALL) { 1956 if (cause_rx_tx & MVNETA_TX_INTR_MASK_ALL) {
1964 int tx_todo = 0; 1957 mvneta_tx_done_gbe(pp, (cause_rx_tx & MVNETA_TX_INTR_MASK_ALL));
1965
1966 mvneta_tx_done_gbe(pp, (cause_rx_tx & MVNETA_TX_INTR_MASK_ALL), &tx_todo);
1967 cause_rx_tx &= ~MVNETA_TX_INTR_MASK_ALL; 1958 cause_rx_tx &= ~MVNETA_TX_INTR_MASK_ALL;
1968 } 1959 }
1969 1960