Changeset 14981


Ignore:
Timestamp:
2009-03-22T21:19:23+01:00 (7 years ago)
Author:
nbd
Message:

atheros: in later kernels, vlan 0 no longer works as expected, switch to (1,2) instead of (0,1) for lan/wan

Location:
trunk/target/linux
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/atheros/base-files/etc/preinit.arch

    r14980 r14981  
    55                vconfig set_name_type DEV_PLUS_VID_NO_PAD 
    66                ifconfig eth0 up 
    7                 vconfig add eth0 0 
    8                 ifname=eth0.0 
     7                vconfig add eth0 1 
     8                ifname=eth0.1 
    99        else 
    1010                ifname=eth0 
     
    1616        if [ -e "/sys/bus/mdio_bus/drivers/Infineon ADM6996/0:00" -o \ 
    1717             -e "/sys/bus/mdio_bus/drivers/Marvell 88E6060/0:10" ]; then 
    18                 vconfig rem eth0.0 
     18                vconfig rem eth0.1 
    1919                ifconfig eth0 down 
    2020        fi 
  • trunk/target/linux/atheros/base-files/etc/uci-defaults/network

    r14980 r14981  
    33     -e "/sys/bus/mdio_bus/drivers/Marvell 88E6060/0:10" ]; then 
    44        uci batch <<EOF 
    5 set network.lan.ifname=eth0.0 
     5set network.lan.ifname=eth0.1 
    66set network.wan=interface 
    7 set network.wan.ifname=eth0.1 
     7set network.wan.ifname=eth0.2 
    88set network.wan.proto=dhcp 
    99commit network 
  • trunk/target/linux/generic-2.6/files/drivers/net/phy/mvswitch.c

    r14977 r14981  
    3333/* Undefine this to use trailer mode instead. 
    3434 * I don't know if header mode works with all chips */ 
    35 #define HEADER_MODE     1 
     35//#define HEADER_MODE   1 
    3636 
    3737MODULE_DESCRIPTION("Marvell 88E6060 Switch driver"); 
     
    252252        /* initialize default vlans */ 
    253253        for (i = 0; i < MV_PORTS; i++) 
    254                 priv->vlans[(i == MV_WANPORT ? 1 : 0)] |= (1 << i); 
     254                priv->vlans[(i == MV_WANPORT ? 2 : 1)] |= (1 << i); 
    255255 
    256256        /* before entering reset, disable all ports */ 
     
    423423        u16 reg; 
    424424 
    425         /* look for the switch on the bus */ 
     425        if (dev->addr != 0x10) 
     426                return 0; 
     427 
    426428        reg = dev->bus->read(dev->bus, MV_PORTREG(IDENT, 0)) & MV_IDENT_MASK; 
    427429        if (reg != MV_IDENT_VALUE) 
Note: See TracChangeset for help on using the changeset viewer.