aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Baker <mbm@openwrt.org>2006-04-08 21:11:49 +0000
committerMike Baker <mbm@openwrt.org>2006-04-08 21:11:49 +0000
commitaf55dd1eb9aaf0a6331faf316a75d1544d3ac4d0 (patch)
tree65944f2325e7625de3d5e40e1d32893c8c17abfb
parentdedb205f4aa975f4407cbc58bce08aaa770e1d11 (diff)
downloadupstream-af55dd1eb9aaf0a6331faf316a75d1544d3ac4d0.tar.gz
upstream-af55dd1eb9aaf0a6331faf316a75d1544d3ac4d0.tar.bz2
upstream-af55dd1eb9aaf0a6331faf316a75d1544d3ac4d0.zip
fix a bug that prevents the wgt634u from initializing the filesystem properly
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@3601 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rwxr-xr-xopenwrt/package/base-files/default/bin/firstboot2
-rwxr-xr-xopenwrt/package/base-files/default/sbin/mount_root8
2 files changed, 8 insertions, 2 deletions
diff --git a/openwrt/package/base-files/default/bin/firstboot b/openwrt/package/base-files/default/bin/firstboot
index 1d9b658b699..5d3d9677ee1 100755
--- a/openwrt/package/base-files/default/bin/firstboot
+++ b/openwrt/package/base-files/default/bin/firstboot
@@ -37,6 +37,8 @@ pivot() { # <new_root> <old_root>
pivot_root $1 $1$2 && {
mount -o move $2/dev /dev
mount -o move $2/tmp /tmp
+ mount -o move $2/sys /sys
+ return 0
}
}
diff --git a/openwrt/package/base-files/default/sbin/mount_root b/openwrt/package/base-files/default/sbin/mount_root
index 38252e83fe5..88a836c808f 100755
--- a/openwrt/package/base-files/default/sbin/mount_root
+++ b/openwrt/package/base-files/default/sbin/mount_root
@@ -22,9 +22,13 @@ if [ "$1" != "failsafe" ]; then
. /bin/firstboot
is_dirty
[ $? != 0 ] && {
- mount /dev/mtdblock/4 /jffs
+ echo "switching to jffs2"
+ mount /dev/mtdblock/4 /jffs -t jffs2
pivot /jffs /rom
- } || ramoverlay
+ } || {
+ echo "jffs2 unusable; using ramdisk"
+ ramoverlay
+ }
fi
fi