aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/tlan.c
diff options
context:
space:
mode:
authorSakari Ailus <sakari.ailus@iki.fi>2011-02-09 05:25:06 -0500
committerDavid S. Miller <davem@davemloft.net>2011-02-13 14:06:13 -0500
commitf45437efff460aa033978180da88229c5fc68455 (patch)
treedc74f6b039dd51aab0d5e4d9a66ae2178477a9eb /drivers/net/tlan.c
parent1765a575334f1a232c1478accdee5c7d19f4b3e3 (diff)
tlan: Fix bugs introduced by the last tlan cleanup patch
Fix two bugs introduced by the commit c659c38b2796578638548b77ef626d93609ec8ac ("tlan: Code cleanup: checkpatch.pl is relatively happy now.") In that change, TLAN_CSTAT_READY was considered as a bit mask containing a single bit set while it was actually had two set instead. Many thanks to Dan Carpenter for finding the mistake. Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tlan.c')
-rw-r--r--drivers/net/tlan.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/net/tlan.c b/drivers/net/tlan.c
index 0678e7e71f19..e48a80885343 100644
--- a/drivers/net/tlan.c
+++ b/drivers/net/tlan.c
@@ -1522,7 +1522,8 @@ static u32 tlan_handle_tx_eof(struct net_device *dev, u16 host_int)
1522 head_list = priv->tx_list + priv->tx_head; 1522 head_list = priv->tx_list + priv->tx_head;
1523 head_list_phys = priv->tx_list_dma 1523 head_list_phys = priv->tx_list_dma
1524 + sizeof(struct tlan_list)*priv->tx_head; 1524 + sizeof(struct tlan_list)*priv->tx_head;
1525 if (head_list->c_stat & TLAN_CSTAT_READY) { 1525 if ((head_list->c_stat & TLAN_CSTAT_READY)
1526 == TLAN_CSTAT_READY) {
1526 outl(head_list_phys, dev->base_addr + TLAN_CH_PARM); 1527 outl(head_list_phys, dev->base_addr + TLAN_CH_PARM);
1527 ack |= TLAN_HC_GO; 1528 ack |= TLAN_HC_GO;
1528 } else { 1529 } else {
@@ -1766,7 +1767,8 @@ static u32 tlan_handle_tx_eoc(struct net_device *dev, u16 host_int)
1766 head_list = priv->tx_list + priv->tx_head; 1767 head_list = priv->tx_list + priv->tx_head;
1767 head_list_phys = priv->tx_list_dma 1768 head_list_phys = priv->tx_list_dma
1768 + sizeof(struct tlan_list)*priv->tx_head; 1769 + sizeof(struct tlan_list)*priv->tx_head;
1769 if (head_list->c_stat & TLAN_CSTAT_READY) { 1770 if ((head_list->c_stat & TLAN_CSTAT_READY)
1771 == TLAN_CSTAT_READY) {
1770 netif_stop_queue(dev); 1772 netif_stop_queue(dev);
1771 outl(head_list_phys, dev->base_addr + TLAN_CH_PARM); 1773 outl(head_list_phys, dev->base_addr + TLAN_CH_PARM);
1772 ack |= TLAN_HC_GO; 1774 ack |= TLAN_HC_GO;