diff options
author | Gabor Juhos <juhosg@openwrt.org> | 2009-10-26 17:17:37 +0000 |
---|---|---|
committer | Gabor Juhos <juhosg@openwrt.org> | 2009-10-26 17:17:37 +0000 |
commit | b227b3e3df9445bafe85a6a3ebb1e28835be2f5a (patch) | |
tree | 041d0b557f9b457a3014749d1e39db20b2ebfcd4 /target/linux/ramips/files/drivers/net | |
parent | 73e450ccedbb77c2878dbe44770e15676eb8aa08 (diff) | |
download | upstream-b227b3e3df9445bafe85a6a3ebb1e28835be2f5a.tar.gz upstream-b227b3e3df9445bafe85a6a3ebb1e28835be2f5a.tar.bz2 upstream-b227b3e3df9445bafe85a6a3ebb1e28835be2f5a.zip |
ramips: free allocated skbs in ramips_cleanup_dma
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@18171 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/ramips/files/drivers/net')
-rw-r--r-- | target/linux/ramips/files/drivers/net/ramips.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/target/linux/ramips/files/drivers/net/ramips.c b/target/linux/ramips/files/drivers/net/ramips.c index 30840965a6..43ccdfc1f7 100644 --- a/target/linux/ramips/files/drivers/net/ramips.c +++ b/target/linux/ramips/files/drivers/net/ramips.c @@ -54,6 +54,11 @@ static void ramips_cleanup_dma(struct net_device *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), priv->rx, priv->phy_rx); |