diff options
author | Dimitris Michailidis <dm@chelsio.com> | 2010-05-10 11:58:07 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-05-13 02:31:15 -0400 |
commit | f8f5aafa960883bc3f1b8f85f1cf8199d0c85879 (patch) | |
tree | 1b8fbf1aaed6fc2ad2bf91a2a3e3221fe127715d /drivers/net/cxgb4/cxgb4_main.c | |
parent | 10df0b9116e2039d5585a196753e5f36d7afcba2 (diff) |
cxgb4: configure HW VLAN extraction through FW
HW VLAN extraction needs to be configured through FW to work correctly in
virtualization environments. Remove the direct register manipulation and
rely on FW.
Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cxgb4/cxgb4_main.c')
-rw-r--r-- | drivers/net/cxgb4/cxgb4_main.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/net/cxgb4/cxgb4_main.c b/drivers/net/cxgb4/cxgb4_main.c index 1bad5004142..a73cda9c9de 100644 --- a/drivers/net/cxgb4/cxgb4_main.c +++ b/drivers/net/cxgb4/cxgb4_main.c | |||
@@ -290,7 +290,7 @@ static int set_rxmode(struct net_device *dev, int mtu, bool sleep_ok) | |||
290 | if (ret == 0) | 290 | if (ret == 0) |
291 | ret = t4_set_rxmode(pi->adapter, 0, pi->viid, mtu, | 291 | ret = t4_set_rxmode(pi->adapter, 0, pi->viid, mtu, |
292 | (dev->flags & IFF_PROMISC) ? 1 : 0, | 292 | (dev->flags & IFF_PROMISC) ? 1 : 0, |
293 | (dev->flags & IFF_ALLMULTI) ? 1 : 0, 1, | 293 | (dev->flags & IFF_ALLMULTI) ? 1 : 0, 1, -1, |
294 | sleep_ok); | 294 | sleep_ok); |
295 | return ret; | 295 | return ret; |
296 | } | 296 | } |
@@ -311,7 +311,7 @@ static int link_start(struct net_device *dev) | |||
311 | * that step explicitly. | 311 | * that step explicitly. |
312 | */ | 312 | */ |
313 | ret = t4_set_rxmode(pi->adapter, 0, pi->viid, dev->mtu, -1, -1, -1, | 313 | ret = t4_set_rxmode(pi->adapter, 0, pi->viid, dev->mtu, -1, -1, -1, |
314 | true); | 314 | pi->vlan_grp != NULL, true); |
315 | if (ret == 0) { | 315 | if (ret == 0) { |
316 | ret = t4_change_mac(pi->adapter, 0, pi->viid, | 316 | ret = t4_change_mac(pi->adapter, 0, pi->viid, |
317 | pi->xact_addr_filt, dev->dev_addr, true, | 317 | pi->xact_addr_filt, dev->dev_addr, true, |
@@ -2614,7 +2614,7 @@ static int cxgb_change_mtu(struct net_device *dev, int new_mtu) | |||
2614 | 2614 | ||
2615 | if (new_mtu < 81 || new_mtu > MAX_MTU) /* accommodate SACK */ | 2615 | if (new_mtu < 81 || new_mtu > MAX_MTU) /* accommodate SACK */ |
2616 | return -EINVAL; | 2616 | return -EINVAL; |
2617 | ret = t4_set_rxmode(pi->adapter, 0, pi->viid, new_mtu, -1, -1, -1, | 2617 | ret = t4_set_rxmode(pi->adapter, 0, pi->viid, new_mtu, -1, -1, -1, -1, |
2618 | true); | 2618 | true); |
2619 | if (!ret) | 2619 | if (!ret) |
2620 | dev->mtu = new_mtu; | 2620 | dev->mtu = new_mtu; |
@@ -2645,7 +2645,8 @@ static void vlan_rx_register(struct net_device *dev, struct vlan_group *grp) | |||
2645 | struct port_info *pi = netdev_priv(dev); | 2645 | struct port_info *pi = netdev_priv(dev); |
2646 | 2646 | ||
2647 | pi->vlan_grp = grp; | 2647 | pi->vlan_grp = grp; |
2648 | t4_set_vlan_accel(pi->adapter, 1 << pi->tx_chan, grp != NULL); | 2648 | t4_set_rxmode(pi->adapter, 0, pi->viid, -1, -1, -1, -1, grp != NULL, |
2649 | true); | ||
2649 | } | 2650 | } |
2650 | 2651 | ||
2651 | #ifdef CONFIG_NET_POLL_CONTROLLER | 2652 | #ifdef CONFIG_NET_POLL_CONTROLLER |