diff options
-rw-r--r-- | drivers/net/bfin_mac.c | 7 | ||||
-rw-r--r-- | drivers/net/bfin_mac.h | 3 | ||||
-rw-r--r-- | include/linux/bfin_mac.h | 1 |
3 files changed, 11 insertions, 0 deletions
diff --git a/drivers/net/bfin_mac.c b/drivers/net/bfin_mac.c index e712be4a6433..0b9fc5173aef 100644 --- a/drivers/net/bfin_mac.c +++ b/drivers/net/bfin_mac.c | |||
@@ -588,6 +588,10 @@ static void setup_system_regs(struct net_device *dev) | |||
588 | 588 | ||
589 | bfin_write_EMAC_MMC_CTL(RSTC | CROLL); | 589 | bfin_write_EMAC_MMC_CTL(RSTC | CROLL); |
590 | 590 | ||
591 | /* Set vlan regs to let 1522 bytes long packets pass through */ | ||
592 | bfin_write_EMAC_VLAN1(lp->vlan1_mask); | ||
593 | bfin_write_EMAC_VLAN2(lp->vlan2_mask); | ||
594 | |||
591 | /* Initialize the TX DMA channel registers */ | 595 | /* Initialize the TX DMA channel registers */ |
592 | bfin_write_DMA2_X_COUNT(0); | 596 | bfin_write_DMA2_X_COUNT(0); |
593 | bfin_write_DMA2_X_MODIFY(4); | 597 | bfin_write_DMA2_X_MODIFY(4); |
@@ -1520,6 +1524,9 @@ static int __devinit bfin_mac_probe(struct platform_device *pdev) | |||
1520 | goto out_err_mii_probe; | 1524 | goto out_err_mii_probe; |
1521 | } | 1525 | } |
1522 | 1526 | ||
1527 | lp->vlan1_mask = ETH_P_8021Q | mii_bus_data->vlan1_mask; | ||
1528 | lp->vlan2_mask = ETH_P_8021Q | mii_bus_data->vlan2_mask; | ||
1529 | |||
1523 | /* Fill in the fields of the device structure with ethernet values. */ | 1530 | /* Fill in the fields of the device structure with ethernet values. */ |
1524 | ether_setup(ndev); | 1531 | ether_setup(ndev); |
1525 | 1532 | ||
diff --git a/drivers/net/bfin_mac.h b/drivers/net/bfin_mac.h index 692187da99f0..f8559ac9a403 100644 --- a/drivers/net/bfin_mac.h +++ b/drivers/net/bfin_mac.h | |||
@@ -82,6 +82,9 @@ struct bfin_mac_local { | |||
82 | struct timer_list tx_reclaim_timer; | 82 | struct timer_list tx_reclaim_timer; |
83 | struct net_device *ndev; | 83 | struct net_device *ndev; |
84 | 84 | ||
85 | /* Data for EMAC_VLAN1 regs */ | ||
86 | u16 vlan1_mask, vlan2_mask; | ||
87 | |||
85 | /* MII and PHY stuffs */ | 88 | /* MII and PHY stuffs */ |
86 | int old_link; /* used by bf537_adjust_link */ | 89 | int old_link; /* used by bf537_adjust_link */ |
87 | int old_speed; | 90 | int old_speed; |
diff --git a/include/linux/bfin_mac.h b/include/linux/bfin_mac.h index 904dec7d03a1..a69554ef8476 100644 --- a/include/linux/bfin_mac.h +++ b/include/linux/bfin_mac.h | |||
@@ -24,6 +24,7 @@ struct bfin_mii_bus_platform_data { | |||
24 | const unsigned short *mac_peripherals; | 24 | const unsigned short *mac_peripherals; |
25 | int phy_mode; | 25 | int phy_mode; |
26 | unsigned int phy_mask; | 26 | unsigned int phy_mask; |
27 | unsigned short vlan1_mask, vlan2_mask; | ||
27 | }; | 28 | }; |
28 | 29 | ||
29 | #endif | 30 | #endif |