Modify

Opened 12 years ago

Closed 12 years ago

#200 closed defect (fixed)

network autoconfiguration for WAP54G

Reported by: anonymous Owned by: developers
Priority: normal Milestone:
Component: base system Version: 2.0
Keywords: Cc: vanekt@…

Description

kamikaze r2907

eth0 iface is not connected to phy on WAP54G. So we should use eth1 and eth2 for lan.

We should also avoid configuring eth0 up, as b44 driver delays boot couple of seconds and gives bunch of errors:

b44: eth0: BUG!  Timeout waiting for bit 80000000 of register 428 to clear.

I’m not sure if configuring all existing interfaces in S10boot is the best thing we can do.
At least we have to define interfaces not to touch like that

/etc/config/network:

unused_ifnames="eth0"

Proposed patch:

Index: target/linux/package/base-files/files/brcm-2.6/etc/init.d/S05netconfig
===================================================================
--- target/linux/package/base-files/files/brcm-2.6/etc/init.d/S05netconfig      (revision 2907)
+++ target/linux/package/base-files/files/brcm-2.6/etc/init.d/S05netconfig      (working copy)
@@ -57,8 +57,9 @@
        # WAP54G
        if ((nvram["boardnum"] == "2") || \
                (nvram["boardnum"] == "1024")) {
-               c["lan_ifnames"]="eth0 eth1"
+               c["lan_ifnames"]="eth1 eth2"
                c["wan_ifname"]=""
+        c["unused_ifnames"]="eth0"
        }
 
        print "#### VLAN configuration "
@@ -78,6 +79,7 @@
        print "# lan_gateway=\"192.168.1.1\""
 
        print ""
+    p("unused_ifnames")
        print ""
 
        print "#### WAN configuration"
Index: package/base-files/default/etc/hotplug.d/net/10-net
===================================================================
--- package/base-files/default/etc/hotplug.d/net/10-net (revision 2907)
+++ package/base-files/default/etc/hotplug.d/net/10-net (working copy)
@@ -1,6 +1,9 @@
 #!/bin/sh
 setup_eth()
 {
+    for part in $(nvram get unused_ifnames); do
+        [ "$part" = "$INTERFACE" ] && return 0
+    done
        [ -f /proc/net/wl0 ] && {
                lsmod | grep wlcompat >&- || insmod wlcompat
        }

Attachments (0)

Change History (1)

comment:1 Changed 12 years ago by florian

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in r2912, thanks for submitting !

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.