diff options
author | Huang Shijie <b32955@freescale.com> | 2010-09-14 09:48:16 +0800 |
---|---|---|
committer | Alan Tull <r80115@freescale.com> | 2010-09-25 09:52:25 -0500 |
commit | 099d710ba67a31b810844f2cd12ddc60d3f2671e (patch) | |
tree | 738083200a3eb3cc3b423bcd0feae8144cb0e44e /drivers/net | |
parent | a5209418ca08d5c1f3f7681285f3167420574cb3 (diff) |
ENGR00131401 ETHERNET:fix the logic error in TX
The origin code stop the TX queue when TX failed just the first time.
This is a wrong logic to handle the TX fails.
The right logic is to stop the TX queue and reset the card in the situation
that the fail number reachs the MAX_TX_RETRYCOUNT.
Signed-off-by: Huang Shijie <b32955@freescale.com>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/enc28j60.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/enc28j60.c b/drivers/net/enc28j60.c index 26bdc746b14a..b08d2d3c1ab3 100644 --- a/drivers/net/enc28j60.c +++ b/drivers/net/enc28j60.c @@ -1290,7 +1290,7 @@ static void enc28j60_irq_work_handler(struct work_struct *work) printk(KERN_DEBUG DRV_NAME ": LateCollision TXErr (%d)\n", priv->tx_retry_count); - if (priv->tx_retry_count++ < MAX_TX_RETRYCOUNT) + if (priv->tx_retry_count++ > MAX_TX_RETRYCOUNT) locked_reg_bfset(priv, ECON1, ECON1_TXRTS); else |