]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/openslug-init/openslug-init-0.10/initscripts/umountinitrd.sh
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / openslug-init / openslug-init-0.10 / initscripts / umountinitrd.sh
1 #!/bin/sh
2 #
3 # umount /mnt, which is where the initrd ends up mounted
4 # if the directory /initrd is not present, if this fails
5 # then the /initrd is mounted and we want to remount that
6 # ro - this works round the shutdown -r hang problem
7 umount /mnt 2>/dev/null || {
8         # need the device for a remount
9         . /etc/default/functions
10         ffspart=Flashdisk
11         ffsdev="$(mtblockdev $ffspart)"
12         if test -n "$ffsdev" -a -b "$ffsdev"
13         then
14                 mount -o remount,ro "$ffsdev" /initrd
15         else
16                 echo "Flashdisk: $ffsdev: flash device not found" >&2
17         fi
18 }