diff options
author | Daniel Hellstrom <daniel@gaisler.com> | 2011-01-13 22:02:38 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-01-14 15:45:52 -0500 |
commit | bbe9e637330abe55442aebe799425e224086959f (patch) | |
tree | 3c8a574f01cda944e6664931476eec8e4101757d /drivers/net | |
parent | ad4650a89ac47bd153cbb76c3fd6eb1fa6f315b7 (diff) |
GRETH: fix opening/closing
When NAPI is disabled there is no point in having IRQs enabled, TX/RX
should be off before clearing the TX/RX descriptor rings.
Signed-off-by: Daniel Hellstrom <daniel@gaisler.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/greth.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/greth.c b/drivers/net/greth.c index 1c2dbdb43631..b307696e0f63 100644 --- a/drivers/net/greth.c +++ b/drivers/net/greth.c | |||
@@ -356,6 +356,8 @@ static int greth_open(struct net_device *dev) | |||
356 | dev_dbg(&dev->dev, " starting queue\n"); | 356 | dev_dbg(&dev->dev, " starting queue\n"); |
357 | netif_start_queue(dev); | 357 | netif_start_queue(dev); |
358 | 358 | ||
359 | GRETH_REGSAVE(greth->regs->status, 0xFF); | ||
360 | |||
359 | napi_enable(&greth->napi); | 361 | napi_enable(&greth->napi); |
360 | 362 | ||
361 | greth_enable_irqs(greth); | 363 | greth_enable_irqs(greth); |
@@ -371,7 +373,9 @@ static int greth_close(struct net_device *dev) | |||
371 | 373 | ||
372 | napi_disable(&greth->napi); | 374 | napi_disable(&greth->napi); |
373 | 375 | ||
376 | greth_disable_irqs(greth); | ||
374 | greth_disable_tx(greth); | 377 | greth_disable_tx(greth); |
378 | greth_disable_rx(greth); | ||
375 | 379 | ||
376 | netif_stop_queue(dev); | 380 | netif_stop_queue(dev); |
377 | 381 | ||