Commit 879e9304 authored by David S. Miller's avatar David S. Miller

znet: Don't claim DMA lock around free_dma() calls.

It's not necessary and it's illegal too.
Reported-by: default avatarAlexander Strakh <strakh@ispras.ru>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent d308e38f
...@@ -169,7 +169,6 @@ static void znet_tx_timeout (struct net_device *dev); ...@@ -169,7 +169,6 @@ static void znet_tx_timeout (struct net_device *dev);
static int znet_request_resources (struct net_device *dev) static int znet_request_resources (struct net_device *dev)
{ {
struct znet_private *znet = netdev_priv(dev); struct znet_private *znet = netdev_priv(dev);
unsigned long flags;
if (request_irq (dev->irq, &znet_interrupt, 0, "ZNet", dev)) if (request_irq (dev->irq, &znet_interrupt, 0, "ZNet", dev))
goto failed; goto failed;
...@@ -187,13 +186,9 @@ static int znet_request_resources (struct net_device *dev) ...@@ -187,13 +186,9 @@ static int znet_request_resources (struct net_device *dev)
free_sia: free_sia:
release_region (znet->sia_base, znet->sia_size); release_region (znet->sia_base, znet->sia_size);
free_tx_dma: free_tx_dma:
flags = claim_dma_lock();
free_dma (znet->tx_dma); free_dma (znet->tx_dma);
release_dma_lock (flags);
free_rx_dma: free_rx_dma:
flags = claim_dma_lock();
free_dma (znet->rx_dma); free_dma (znet->rx_dma);
release_dma_lock (flags);
free_irq: free_irq:
free_irq (dev->irq, dev); free_irq (dev->irq, dev);
failed: failed:
...@@ -203,14 +198,11 @@ static int znet_request_resources (struct net_device *dev) ...@@ -203,14 +198,11 @@ static int znet_request_resources (struct net_device *dev)
static void znet_release_resources (struct net_device *dev) static void znet_release_resources (struct net_device *dev)
{ {
struct znet_private *znet = netdev_priv(dev); struct znet_private *znet = netdev_priv(dev);
unsigned long flags;
release_region (znet->sia_base, znet->sia_size); release_region (znet->sia_base, znet->sia_size);
release_region (dev->base_addr, znet->io_size); release_region (dev->base_addr, znet->io_size);
flags = claim_dma_lock();
free_dma (znet->tx_dma); free_dma (znet->tx_dma);
free_dma (znet->rx_dma); free_dma (znet->rx_dma);
release_dma_lock (flags);
free_irq (dev->irq, dev); free_irq (dev->irq, dev);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment