summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuo-Fu Tseng <cooldavid@cooldavid.org>2010-03-17 00:09:29 +0000
committerGreg Kroah-Hartman <gregkh@suse.de>2010-04-01 15:58:39 -0700
commit7aa5e834a22b77dc16a992e8af54514021f05744 (patch)
tree52f347e12da093f81934284492ed828b49f993b6
parent70aba33f52d17490d8b0b5ba2d8b0ac17220ba03 (diff)
jme: Fix VLAN memory leak
commit 17da69b8bfbe441a33a873ad5dd7d3d85800bf2b upstream. Fix memory leak while receiving 8021q tagged packet which is not registered by user. Signed-off-by: Guo-Fu Tseng <cooldavid@cooldavid.org> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/net/jme.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/jme.c b/drivers/net/jme.c
index 1d2a32544ed2..577cae69f1cf 100644
--- a/drivers/net/jme.c
+++ b/drivers/net/jme.c
@@ -946,6 +946,8 @@ jme_alloc_and_feed_skb(struct jme_adapter *jme, int idx)
jme->jme_vlan_rx(skb, jme->vlgrp,
le16_to_cpu(rxdesc->descwb.vlan));
NET_STAT(jme).rx_bytes += 4;
+ } else {
+ dev_kfree_skb(skb);
}
} else {
jme->jme_rx(skb);