aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ramips
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2010-07-13 16:52:07 +0000
committerGabor Juhos <juhosg@openwrt.org>2010-07-13 16:52:07 +0000
commit5cce2b0a05147da39fcdaaf5f0a3c5aff376ab3f (patch)
treef4b60112cab5b2c6f9881343ff662a90cfa11937 /target/linux/ramips
parent33eba7e060b9dd02aefe59a9db800a122a6ea159 (diff)
downloadmaster-187ad058-5cce2b0a05147da39fcdaaf5f0a3c5aff376ab3f.tar.gz
master-187ad058-5cce2b0a05147da39fcdaaf5f0a3c5aff376ab3f.tar.bz2
master-187ad058-5cce2b0a05147da39fcdaaf5f0a3c5aff376ab3f.zip
ramips: Fix bridging in ramips ethernet driver
Bridging between the ramips ethernet driver and rt2800pci was somewhat broken. Frames received by the ethernet driver which were passed to the wifi driver for transmission were sometimes corrupted or sent out with huge delays. The reason for this is the missing assignment of skb->tail in the ramips ethernet driver's rx path resulting in skb->tail pointing to skb->data. Since skb->tail is used by mac80211 it writes into skb->data which messes up the frames content. Fix this by using skb_put to correctly set skb->len and skb->tail. Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22172 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/ramips')
-rw-r--r--target/linux/ramips/files/drivers/net/ramips.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/target/linux/ramips/files/drivers/net/ramips.c b/target/linux/ramips/files/drivers/net/ramips.c
index 5a728be028..4274c923bb 100644
--- a/target/linux/ramips/files/drivers/net/ramips.c
+++ b/target/linux/ramips/files/drivers/net/ramips.c
@@ -231,7 +231,7 @@ ramips_eth_rx_hw(unsigned long ptr)
max_rx--;
rx_skb = priv->rx_skb[rx];
- rx_skb->len = RX_DMA_PLEN0(priv->rx[rx].rxd2);
+ skb_put(rx_skb, RX_DMA_PLEN0(priv->rx[rx].rxd2));
rx_skb->dev = dev;
rx_skb->protocol = eth_type_trans(rx_skb, dev);
rx_skb->ip_summed = CHECKSUM_NONE;