1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2024-11-10 22:25:01 +02:00

ramips: free allocated skbs in ramips_cleanup_dma

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@18171 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
juhosg 2009-10-26 17:17:37 +00:00
parent 9f1a8f089c
commit 8fee1ed8aa

View File

@ -54,6 +54,11 @@ static void
ramips_cleanup_dma(struct net_device *dev) ramips_cleanup_dma(struct net_device *dev)
{ {
struct raeth_priv *priv = netdev_priv(dev); struct raeth_priv *priv = netdev_priv(dev);
int i;
for (i = 0; i < NUM_RX_DESC; i++)
if (priv->rx_skb[i])
dev_kfree_skb_any(priv->rx_skb[i]);
dma_free_coherent(NULL, NUM_RX_DESC * sizeof(struct ramips_rx_dma), dma_free_coherent(NULL, NUM_RX_DESC * sizeof(struct ramips_rx_dma),
priv->rx, priv->phy_rx); priv->rx, priv->phy_rx);