Merge branch 'CR_1522_ssh_nfs_samin.guo' into 'jh7110-devel'

init: Added /dev/null to fix rootfs issues.

See merge request sdk/buildroot!22
This commit is contained in:
andy.hu
2022-07-07 05:53:31 +00:00
+5 -3
View File
@@ -19,7 +19,6 @@ for x in $(cat /proc/cmdline); do
done
if [ "x${ROOT}" = "x" ]; then
echo abcd
exec /sbin/init
fi
@@ -27,8 +26,8 @@ mount -t sysfs sysfs /sys
mdev -s
mkdir /dev/pts
mkdir /dev/shm
mkdir -p /dev/pts
mkdir -p /dev/shm
mount -t devpts devpts /dev/pts
mount -t tmpfs tmpfs /dev/shm
mount -t tmpfs tmpfs /tmp
@@ -45,6 +44,9 @@ else
if [ ! -e /rootfs/dev/console ]; then
/bin/mknod /rootfs/dev/console c 5 1
fi
if [ ! -e /rootfs/dev/null ]; then
/bin/mknod /rootfs/dev/null c 1 3
fi
fi
mount -n -o move /proc /rootfs/proc