aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/gianfar.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2009-08-12 20:44:53 -0400
committerDavid S. Miller <davem@davemloft.net>2009-08-12 20:44:53 -0400
commitaa11d958d1a6572eda08214d7c6a735804fe48a5 (patch)
treed025b05270ad1e010660d17eeadc6ac3c1abbd7d /drivers/net/gianfar.c
parent07f6642ee9418e962e54cbc07471cfe2e559c568 (diff)
parent9799218ae36910af50f002a5db1802d576fffb43 (diff)
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts: arch/microblaze/include/asm/socket.h
Diffstat (limited to 'drivers/net/gianfar.c')
-rw-r--r--drivers/net/gianfar.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c
index 056ba4625780..4544da4cf3ce 100644
--- a/drivers/net/gianfar.c
+++ b/drivers/net/gianfar.c
@@ -935,6 +935,7 @@ int startup_gfar(struct net_device *dev)
935 struct gfar __iomem *regs = priv->regs; 935 struct gfar __iomem *regs = priv->regs;
936 int err = 0; 936 int err = 0;
937 u32 rctrl = 0; 937 u32 rctrl = 0;
938 u32 tctrl = 0;
938 u32 attrs = 0; 939 u32 attrs = 0;
939 940
940 gfar_write(&regs->imask, IMASK_INIT_CLEAR); 941 gfar_write(&regs->imask, IMASK_INIT_CLEAR);
@@ -1110,11 +1111,19 @@ int startup_gfar(struct net_device *dev)
1110 rctrl |= RCTRL_PADDING(priv->padding); 1111 rctrl |= RCTRL_PADDING(priv->padding);
1111 } 1112 }
1112 1113
1114 /* keep vlan related bits if it's enabled */
1115 if (priv->vlgrp) {
1116 rctrl |= RCTRL_VLEX | RCTRL_PRSDEP_INIT;
1117 tctrl |= TCTRL_VLINS;
1118 }
1119
1113 /* Init rctrl based on our settings */ 1120 /* Init rctrl based on our settings */
1114 gfar_write(&priv->regs->rctrl, rctrl); 1121 gfar_write(&priv->regs->rctrl, rctrl);
1115 1122
1116 if (dev->features & NETIF_F_IP_CSUM) 1123 if (dev->features & NETIF_F_IP_CSUM)
1117 gfar_write(&priv->regs->tctrl, TCTRL_INIT_CSUM); 1124 tctrl |= TCTRL_INIT_CSUM;
1125
1126 gfar_write(&priv->regs->tctrl, tctrl);
1118 1127
1119 /* Set the extraction length and index */ 1128 /* Set the extraction length and index */
1120 attrs = ATTRELI_EL(priv->rx_stash_size) | 1129 attrs = ATTRELI_EL(priv->rx_stash_size) |
@@ -1449,7 +1458,6 @@ static void gfar_vlan_rx_register(struct net_device *dev,
1449 1458
1450 /* Enable VLAN tag extraction */ 1459 /* Enable VLAN tag extraction */
1451 tempval = gfar_read(&priv->regs->rctrl); 1460 tempval = gfar_read(&priv->regs->rctrl);
1452 tempval |= RCTRL_VLEX;
1453 tempval |= (RCTRL_VLEX | RCTRL_PRSDEP_INIT); 1461 tempval |= (RCTRL_VLEX | RCTRL_PRSDEP_INIT);
1454 gfar_write(&priv->regs->rctrl, tempval); 1462 gfar_write(&priv->regs->rctrl, tempval);
1455 } else { 1463 } else {