On Fri, 3 Jun 2011 13:50:17 +0800, HP Teoh wrote: 

> On Fri, Jun 3, 2011 at 12:42 PM, Layne Edwards wrote:
> 
>> On Fri, 3 Jun 2011 12:01:55 +0800, HP Teoh wrote: 
>> 
>>> Hi Lanyne,
>>> 
>>> Thanks for the wifi led configuration. Any idea about the reset button not 
>>> working and method to insert 2nd mac for vlan?
>>> 
>>> Thanks and Regards.
>>> -Vincent
>> 
>> Vincent, 
>> 
>> For your MAC issue:
>> The current ethernet and switch drivers for the ramips target still need 
>> some work. The VLAN is hardcoded and the MAC address is not pulled from 
>> flash or eeprom, but hard-coded to 00:11:22:33:44:55. See the 
>> ramips_eth_data struct in 
>> linux/ramips/files/arch/mips/ralink/rt305x/devices.c. The ethernet driver 
>> (linux/ramips/files/driver/net/ramips.c needs to be updated to pull in the 
>> ethernet MAC instead of using the default hard-coded value.
> 
> Hi Layne,
> 
> I added some code to read and pull the MACs out of mtdblock3 (factory) and 
> write both addresses to 
> 
> static inline void
>
ramips_hw_set_macaddr(unsigned char *mac)
> {
> ramips_fe_wr((mac[0]

Vincent, 

If you're talking about WAN and LAN having different MACs... just remember that 
the WAN and LAN are on a VLAN and share the same interface (eth0), so they will 
have the same MAC (same as eth0). I think you can set the MACs for WAN and LAN 
independently in the configuration though. Something like: 

config 'interface' 'wan'
 option 'ifname' 'eth0.2'
 option 'proto' 'dhcp'
 option 'macaddr' '1234567890' 

See http://wiki.openwrt.org/doc/uci/network. 

Hope this helps. 

Layne 

Links:
------
[1] mailto:ledwa...@astrumtech.net
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to