summaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2009-06-12 03:00:35 +0000
committerDavid S. Miller <davem@davemloft.net>2009-06-13 01:18:32 -0700
commit3790c8cdb99f23824b23cb16df608281b335ee91 (patch)
treec437f801a709cefcf1210eb1e9f8306e52f42ca6 /drivers/misc
parentda6782927de809d9d427bd4bd6a4024243e41f13 (diff)
downloadlinux-stable-3790c8cdb99f23824b23cb16df608281b335ee91.tar.gz
linux-stable-3790c8cdb99f23824b23cb16df608281b335ee91.tar.bz2
linux-stable-3790c8cdb99f23824b23cb16df608281b335ee91.zip
net: fix network driver ndo_start_xmit() return values (part 1)
Fix up drivers that return an errno value to qdisc_restart(), causing qdisc_restart() to print a warning and requeue/retransmit the skb. - xpnet: memory allocation error, intention is to drop - ethoc: oversized packet, packet must be dropped - ibmlana: skb freed: use after free - rrunner: skb freed: use after free Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/sgi-xp/xpnet.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/misc/sgi-xp/xpnet.c b/drivers/misc/sgi-xp/xpnet.c
index 6faefcffcb53..8d1c60a3f0df 100644
--- a/drivers/misc/sgi-xp/xpnet.c
+++ b/drivers/misc/sgi-xp/xpnet.c
@@ -450,7 +450,8 @@ xpnet_dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev)
"packet\n", sizeof(struct xpnet_pending_msg));
dev->stats.tx_errors++;
- return -ENOMEM;
+ dev_kfree_skb(skb);
+ return NETDEV_TX_OK;
}
/* get the beginning of the first cacheline and end of last */