summaryrefslogtreecommitdiffstats
path: root/target/linux/generic
diff options
context:
space:
mode:
authornbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-05-06 17:08:30 +0000
committernbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-05-06 17:08:30 +0000
commitf31721e174ce5a585785e2800fb6ff6d7496682f (patch)
treeaa22705e5a4838bff72a5494264b029c95760059 /target/linux/generic
parentee6dea474f253067ac8c2712ee8b71501a6bb70d (diff)
atheros: update to 3.3.4 (based on work by acoul), fix mvswitch driver for newer kernels
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@31625 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/generic')
-rw-r--r--target/linux/generic/files/drivers/net/phy/mvswitch.c18
1 files changed, 3 insertions, 15 deletions
diff --git a/target/linux/generic/files/drivers/net/phy/mvswitch.c b/target/linux/generic/files/drivers/net/phy/mvswitch.c
index f3a9c74e3..1324a80a6 100644
--- a/target/linux/generic/files/drivers/net/phy/mvswitch.c
+++ b/target/linux/generic/files/drivers/net/phy/mvswitch.c
@@ -43,7 +43,6 @@ MODULE_LICENSE("GPL");
struct mvswitch_priv {
const struct net_device_ops *ndo_old;
struct net_device_ops ndo;
- struct vlan_group *grp;
u8 vlans[16];
};
@@ -162,9 +161,6 @@ mvswitch_mangle_rx(struct sk_buff *skb, int napi)
if (!priv)
goto error;
- if (!priv->grp)
- goto error;
-
#ifdef HEADER_MODE
buf = skb->data;
skb_pull(skb, MV_HEADER_SIZE);
@@ -185,10 +181,11 @@ mvswitch_mangle_rx(struct sk_buff *skb, int napi)
skb->protocol = eth_type_trans(skb, skb->dev);
+ __vlan_hwaccel_put_tag(skb, vlan);
if (napi)
- return vlan_hwaccel_receive_skb(skb, priv->grp, vlan);
+ return netif_receive_skb(skb);
else
- return vlan_hwaccel_rx(skb, priv->grp, vlan);
+ return netif_rx(skb);
error:
/* no vlan? eat the packet! */
@@ -210,14 +207,6 @@ mvswitch_netif_receive_skb(struct sk_buff *skb)
}
-static void
-mvswitch_vlan_rx_register(struct net_device *dev, struct vlan_group *grp)
-{
- struct mvswitch_priv *priv = dev->phy_ptr;
- priv->grp = grp;
-}
-
-
static int
mvswitch_wait_mask(struct phy_device *pdev, int addr, int reg, u16 mask, u16 val)
{
@@ -346,7 +335,6 @@ mvswitch_config_init(struct phy_device *pdev)
priv->ndo_old = dev->netdev_ops;
memcpy(&priv->ndo, priv->ndo_old, sizeof(struct net_device_ops));
priv->ndo.ndo_start_xmit = mvswitch_mangle_tx;
- priv->ndo.ndo_vlan_rx_register = mvswitch_vlan_rx_register;
dev->netdev_ops = &priv->ndo;
pdev->pkt_align = 2;