# By Chih-Wei Huang <cwhuang@linux.org.tw>
# and Thorsten Glaser <tg@mirbsd.org>
#
-# Last updated 2017/10/06
+# Last updated 2018/01/12
#
# License: GNU Public License
# We explicitely grant the right to use the scripts
# for NFS roots, use nolock to avoid dependency to portmapper
RW="nolock,$RW"
fi
- # FIXME: any way to mount ntfs gracefully?
- mount -o $RW,noatime $@ || mount.ntfs-3g -o rw,force $@
+ case $(blkid $1) in
+ *TYPE=*ntfs*)
+ mount.ntfs-3g -o rw,force $@
+ ;;
+ *TYPE=*)
+ mount -o $RW,noatime $@
+ ;;
+ *)
+ return 1
+ ;;
+ esac
}
check_root()
blk=`basename $1`
[ ! -e /dev/block/$blk ] && ln $1 /dev/block
dev=/dev/block/$blk
- blkid $dev | grep -q TYPE || return 1
else
dev=$1
fi