kernel: mount /sys before calling update-initramfs(8).

--HG--
extra : convert_revision : ff4322c1df549c7f87e13b24d7af0bb321775fa2
This commit is contained in:
Juan RP 2009-02-25 18:54:15 +01:00
parent 1c83b76888
commit cb4333e216

View file

@ -17,10 +17,16 @@ post)
mntproc_cmd="mount -t proc proc /proc"
umntproc_cmd="umount /proc"
fi
if $(mount|grep "^/sys" 2>&1 >/dev/null); then
mntsys_cmd="mount -t sysfs none /sys"
umntsys_cmd="umount /sys"
fi
initramfs_cmd="update-initramfs"
else
mntproc_cmd="chroot $1 mount -t proc proc ./proc"
umntproc_cmd="chroot $1 umount ./proc"
mntsys_cmd="chroot $1 mount -t sysfs none ./sys"
umntsys_cmd="chroot $1 umount ./sys"
initramfs_cmd="chroot $1 update-initramfs"
fi
@ -31,8 +37,10 @@ post)
fi
${mntproc_cmd}
${mntsys_cmd}
${initramfs_cmd}
${umntproc_cmd}
${umntsys_cmd}
;;
esac