diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2009-05-25 08:35:46 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-05-25 08:35:46 -0400 |
commit | 9af5324a070e0b2dcb6e22c89e17424eba245fcc (patch) | |
tree | 6a41efb99c726e4cbceb9d8cd569ef0ce82238c8 /drivers/net | |
parent | 56a459314a982bae75b9bce64bcca853d378ca7e (diff) | |
parent | 9733bb8e9ce0078f55405ce470a62ec0a551fe99 (diff) |
Merge branch 'ixp4xx' of git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6 into devel
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/arm/ixp4xx_eth.c | 13 | ||||
-rw-r--r-- | drivers/net/wan/ixp4xx_hss.c | 9 |
2 files changed, 10 insertions, 12 deletions
diff --git a/drivers/net/arm/ixp4xx_eth.c b/drivers/net/arm/ixp4xx_eth.c index 672c9626b9ca..b6d188115caf 100644 --- a/drivers/net/arm/ixp4xx_eth.c +++ b/drivers/net/arm/ixp4xx_eth.c | |||
@@ -513,8 +513,8 @@ static int eth_poll(struct napi_struct *napi, int budget) | |||
513 | #endif | 513 | #endif |
514 | napi_complete(napi); | 514 | napi_complete(napi); |
515 | qmgr_enable_irq(rxq); | 515 | qmgr_enable_irq(rxq); |
516 | if (!qmgr_stat_nearly_empty(rxq) && | 516 | if (!qmgr_stat_below_low_watermark(rxq) && |
517 | napi_reschedule(napi)) { /* really empty in fact */ | 517 | napi_reschedule(napi)) { /* not empty again */ |
518 | #if DEBUG_RX | 518 | #if DEBUG_RX |
519 | printk(KERN_DEBUG "%s: eth_poll" | 519 | printk(KERN_DEBUG "%s: eth_poll" |
520 | " napi_reschedule successed\n", | 520 | " napi_reschedule successed\n", |
@@ -631,10 +631,9 @@ static void eth_txdone_irq(void *unused) | |||
631 | port->tx_buff_tab[n_desc] = NULL; | 631 | port->tx_buff_tab[n_desc] = NULL; |
632 | } | 632 | } |
633 | 633 | ||
634 | /* really empty in fact */ | 634 | start = qmgr_stat_below_low_watermark(port->plat->txreadyq); |
635 | start = qmgr_stat_nearly_empty(port->plat->txreadyq); | ||
636 | queue_put_desc(port->plat->txreadyq, phys, desc); | 635 | queue_put_desc(port->plat->txreadyq, phys, desc); |
637 | if (start) { | 636 | if (start) { /* TX-ready queue was empty */ |
638 | #if DEBUG_TX | 637 | #if DEBUG_TX |
639 | printk(KERN_DEBUG "%s: eth_txdone_irq xmit ready\n", | 638 | printk(KERN_DEBUG "%s: eth_txdone_irq xmit ready\n", |
640 | port->netdev->name); | 639 | port->netdev->name); |
@@ -710,14 +709,14 @@ static int eth_xmit(struct sk_buff *skb, struct net_device *dev) | |||
710 | queue_put_desc(TX_QUEUE(port->id), tx_desc_phys(port, n), desc); | 709 | queue_put_desc(TX_QUEUE(port->id), tx_desc_phys(port, n), desc); |
711 | dev->trans_start = jiffies; | 710 | dev->trans_start = jiffies; |
712 | 711 | ||
713 | if (qmgr_stat_nearly_empty(txreadyq)) { /* really empty in fact */ | 712 | if (qmgr_stat_below_low_watermark(txreadyq)) { /* empty */ |
714 | #if DEBUG_TX | 713 | #if DEBUG_TX |
715 | printk(KERN_DEBUG "%s: eth_xmit queue full\n", dev->name); | 714 | printk(KERN_DEBUG "%s: eth_xmit queue full\n", dev->name); |
716 | #endif | 715 | #endif |
717 | netif_stop_queue(dev); | 716 | netif_stop_queue(dev); |
718 | /* we could miss TX ready interrupt */ | 717 | /* we could miss TX ready interrupt */ |
719 | /* really empty in fact */ | 718 | /* really empty in fact */ |
720 | if (!qmgr_stat_nearly_empty(txreadyq)) { | 719 | if (!qmgr_stat_below_low_watermark(txreadyq)) { |
721 | #if DEBUG_TX | 720 | #if DEBUG_TX |
722 | printk(KERN_DEBUG "%s: eth_xmit ready again\n", | 721 | printk(KERN_DEBUG "%s: eth_xmit ready again\n", |
723 | dev->name); | 722 | dev->name); |
diff --git a/drivers/net/wan/ixp4xx_hss.c b/drivers/net/wan/ixp4xx_hss.c index 1e56e58c6605..a6dc317083d3 100644 --- a/drivers/net/wan/ixp4xx_hss.c +++ b/drivers/net/wan/ixp4xx_hss.c | |||
@@ -790,11 +790,10 @@ static void hss_hdlc_txdone_irq(void *pdev) | |||
790 | free_buffer_irq(port->tx_buff_tab[n_desc]); | 790 | free_buffer_irq(port->tx_buff_tab[n_desc]); |
791 | port->tx_buff_tab[n_desc] = NULL; | 791 | port->tx_buff_tab[n_desc] = NULL; |
792 | 792 | ||
793 | /* really empty in fact */ | 793 | start = qmgr_stat_below_low_watermark(port->plat->txreadyq); |
794 | start = qmgr_stat_nearly_empty(port->plat->txreadyq); | ||
795 | queue_put_desc(port->plat->txreadyq, | 794 | queue_put_desc(port->plat->txreadyq, |
796 | tx_desc_phys(port, n_desc), desc); | 795 | tx_desc_phys(port, n_desc), desc); |
797 | if (start) { | 796 | if (start) { /* TX-ready queue was empty */ |
798 | #if DEBUG_TX | 797 | #if DEBUG_TX |
799 | printk(KERN_DEBUG "%s: hss_hdlc_txdone_irq xmit" | 798 | printk(KERN_DEBUG "%s: hss_hdlc_txdone_irq xmit" |
800 | " ready\n", dev->name); | 799 | " ready\n", dev->name); |
@@ -869,13 +868,13 @@ static int hss_hdlc_xmit(struct sk_buff *skb, struct net_device *dev) | |||
869 | queue_put_desc(queue_ids[port->id].tx, tx_desc_phys(port, n), desc); | 868 | queue_put_desc(queue_ids[port->id].tx, tx_desc_phys(port, n), desc); |
870 | dev->trans_start = jiffies; | 869 | dev->trans_start = jiffies; |
871 | 870 | ||
872 | if (qmgr_stat_nearly_empty(txreadyq)) { /* really empty in fact */ | 871 | if (qmgr_stat_below_low_watermark(txreadyq)) { /* empty */ |
873 | #if DEBUG_TX | 872 | #if DEBUG_TX |
874 | printk(KERN_DEBUG "%s: hss_hdlc_xmit queue full\n", dev->name); | 873 | printk(KERN_DEBUG "%s: hss_hdlc_xmit queue full\n", dev->name); |
875 | #endif | 874 | #endif |
876 | netif_stop_queue(dev); | 875 | netif_stop_queue(dev); |
877 | /* we could miss TX ready interrupt */ | 876 | /* we could miss TX ready interrupt */ |
878 | if (!qmgr_stat_nearly_empty(txreadyq)) { | 877 | if (!qmgr_stat_below_low_watermark(txreadyq)) { |
879 | #if DEBUG_TX | 878 | #if DEBUG_TX |
880 | printk(KERN_DEBUG "%s: hss_hdlc_xmit ready again\n", | 879 | printk(KERN_DEBUG "%s: hss_hdlc_xmit ready again\n", |
881 | dev->name); | 880 | dev->name); |