diff options
author | Linas Vepstas <linas@austin.ibm.com> | 2007-06-11 14:26:50 -0400 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2007-06-20 19:09:33 -0400 |
commit | c3d1182a538fd99b6fe5effa1ab54521c0efb1d1 (patch) | |
tree | c81310d49a8f4efd3445daf861061226c6271841 | |
parent | 2bf27a0d4913a5f0ef38e3be510b1b3add2869ad (diff) |
spidernet: silence the ramfull messages
Although the previous patch resolved issues with hangs when the
RX ram full interrupt is encountered, there are still situations
where lots of RX ramfull interrupts arrive, resulting in a noisy
log in syslog. There is no need for this.
Signed-off-by: Linas Vepstas <linas@austin.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
-rw-r--r-- | drivers/net/spider_net.c | 20 | ||||
-rw-r--r-- | drivers/net/spider_net.h | 1 |
2 files changed, 12 insertions, 9 deletions
diff --git a/drivers/net/spider_net.c b/drivers/net/spider_net.c index f5ede5f6073c..0e79bacd7870 100644 --- a/drivers/net/spider_net.c +++ b/drivers/net/spider_net.c | |||
@@ -1172,7 +1172,7 @@ spider_net_decode_one_descr(struct spider_net_card *card) | |||
1172 | goto bad_desc; | 1172 | goto bad_desc; |
1173 | } | 1173 | } |
1174 | 1174 | ||
1175 | if (hwdescr->dmac_cmd_status & 0xfefe) { | 1175 | if (hwdescr->dmac_cmd_status & 0xfcf4) { |
1176 | pr_err("%s: bad status, cmd_status=x%08x\n", | 1176 | pr_err("%s: bad status, cmd_status=x%08x\n", |
1177 | card->netdev->name, | 1177 | card->netdev->name, |
1178 | hwdescr->dmac_cmd_status); | 1178 | hwdescr->dmac_cmd_status); |
@@ -1251,6 +1251,7 @@ spider_net_poll(struct net_device *netdev, int *budget) | |||
1251 | if (no_more_packets) { | 1251 | if (no_more_packets) { |
1252 | netif_rx_complete(netdev); | 1252 | netif_rx_complete(netdev); |
1253 | spider_net_rx_irq_on(card); | 1253 | spider_net_rx_irq_on(card); |
1254 | card->ignore_rx_ramfull = 0; | ||
1254 | return 0; | 1255 | return 0; |
1255 | } | 1256 | } |
1256 | 1257 | ||
@@ -1484,15 +1485,15 @@ spider_net_handle_error_irq(struct spider_net_card *card, u32 status_reg) | |||
1484 | case SPIDER_NET_GRFBFLLINT: /* fallthrough */ | 1485 | case SPIDER_NET_GRFBFLLINT: /* fallthrough */ |
1485 | case SPIDER_NET_GRFAFLLINT: /* fallthrough */ | 1486 | case SPIDER_NET_GRFAFLLINT: /* fallthrough */ |
1486 | case SPIDER_NET_GRMFLLINT: | 1487 | case SPIDER_NET_GRMFLLINT: |
1487 | if (netif_msg_intr(card) && net_ratelimit()) | ||
1488 | pr_err("Spider RX RAM full, incoming packets " | ||
1489 | "might be discarded!\n"); | ||
1490 | /* Could happen when rx chain is full */ | 1488 | /* Could happen when rx chain is full */ |
1491 | spider_net_resync_head_ptr(card); | 1489 | if (card->ignore_rx_ramfull == 0) { |
1492 | spider_net_refill_rx_chain(card); | 1490 | card->ignore_rx_ramfull = 1; |
1493 | spider_net_enable_rxdmac(card); | 1491 | spider_net_resync_head_ptr(card); |
1494 | card->num_rx_ints ++; | 1492 | spider_net_refill_rx_chain(card); |
1495 | netif_rx_schedule(card->netdev); | 1493 | spider_net_enable_rxdmac(card); |
1494 | card->num_rx_ints ++; | ||
1495 | netif_rx_schedule(card->netdev); | ||
1496 | } | ||
1496 | show_error = 0; | 1497 | show_error = 0; |
1497 | break; | 1498 | break; |
1498 | 1499 | ||
@@ -2265,6 +2266,7 @@ spider_net_setup_netdev(struct spider_net_card *card) | |||
2265 | 2266 | ||
2266 | netdev->irq = card->pdev->irq; | 2267 | netdev->irq = card->pdev->irq; |
2267 | card->num_rx_ints = 0; | 2268 | card->num_rx_ints = 0; |
2269 | card->ignore_rx_ramfull = 0; | ||
2268 | 2270 | ||
2269 | dn = pci_device_to_OF_node(card->pdev); | 2271 | dn = pci_device_to_OF_node(card->pdev); |
2270 | if (!dn) | 2272 | if (!dn) |
diff --git a/drivers/net/spider_net.h b/drivers/net/spider_net.h index b620f181227c..f457bce00e5c 100644 --- a/drivers/net/spider_net.h +++ b/drivers/net/spider_net.h | |||
@@ -462,6 +462,7 @@ struct spider_net_card { | |||
462 | atomic_t tx_timeout_task_counter; | 462 | atomic_t tx_timeout_task_counter; |
463 | wait_queue_head_t waitq; | 463 | wait_queue_head_t waitq; |
464 | int num_rx_ints; | 464 | int num_rx_ints; |
465 | int ignore_rx_ramfull; | ||
465 | 466 | ||
466 | /* for ethtool */ | 467 | /* for ethtool */ |
467 | int msg_enable; | 468 | int msg_enable; |