diff options
author | David S. Miller <davem@davemloft.net> | 2016-12-07 05:33:19 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-12-07 05:33:19 +0300 |
commit | c63d352f053a788281eb90df0a71cd3a6b2c4040 (patch) | |
tree | ce0c6f0993100d3d8feda1d9d487dfba4abc5bd0 /drivers/net/ethernet/cirrus | |
parent | 862b3d2090ae3d8b10bb4ee9275fd932bc4d0d44 (diff) | |
parent | bc3913a5378cd0ddefd1dfec6917cc12eb23a946 (diff) | |
download | linux-c63d352f053a788281eb90df0a71cd3a6b2c4040.tar.xz |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'drivers/net/ethernet/cirrus')
-rw-r--r-- | drivers/net/ethernet/cirrus/ep93xx_eth.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/ethernet/cirrus/ep93xx_eth.c b/drivers/net/ethernet/cirrus/ep93xx_eth.c index 9119af088821..a1de0d12927d 100644 --- a/drivers/net/ethernet/cirrus/ep93xx_eth.c +++ b/drivers/net/ethernet/cirrus/ep93xx_eth.c @@ -468,6 +468,9 @@ static void ep93xx_free_buffers(struct ep93xx_priv *ep) struct device *dev = ep->dev->dev.parent; int i; + if (!ep->descs) + return; + for (i = 0; i < RX_QUEUE_ENTRIES; i++) { dma_addr_t d; @@ -490,6 +493,7 @@ static void ep93xx_free_buffers(struct ep93xx_priv *ep) dma_free_coherent(dev, sizeof(struct ep93xx_descs), ep->descs, ep->descs_dma_addr); + ep->descs = NULL; } static int ep93xx_alloc_buffers(struct ep93xx_priv *ep) |