Make a raw, unconfigured, NSLU2 default to DHCP boot proto
authorJohn Bowler <jbowler@nslu2-linux.org>
Sun, 3 Jul 2005 18:35:01 +0000 (18:35 +0000)
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>
Sun, 3 Jul 2005 18:35:01 +0000 (18:35 +0000)
packages/openslug-init/openslug-init-0.10/initscripts/sysconfsetup
packages/openslug-init/openslug-init_0.10.bb

index 1940b00..31ff38d 100644 (file)
@@ -60,9 +60,11 @@ then
        # is removed (to be exact, the sed script selects only lines
        # which match one of the two above).  The lan interface, which
        # defaults to ixp0, is changed to the correct value for openslug,
-       # eth0
+       # eth0.  The bootproto, which LinkSys sets to static in manufacturing,
+       # is reset to dhcp if the IP is still the original (192.168.1.77)
        devio "<<$sysdev" cpb fb1,10 | sed -n '/^\[[^][]*\]$/p;
                s/^lan_interface=ixp0$/lan_interface=eth0/;
+               /^ip_addr=192\.168\.1\.77$/,/^bootproto/s/^bootproto=static$/bootproto=dhcp/;
                /^[-a-zA-Z0-9_][-a-zA-Z0-9_]*=/p' >/etc/default/sysconf
        #
        # The SysConf must have a hardware id, if it doesn't it has
index 76bd007..bf43759 100644 (file)
@@ -3,7 +3,7 @@ SECTION = "console/network"
 LICENSE = "GPL"
 DEPENDS = "base-files devio"
 RDEPENDS = "busybox devio"
-PR = "r31"
+PR = "r32"
 
 SRC_URI = "file://linuxrc \
           file://boot/flash \