From: Harald Hoyer Date: Mon, 11 Apr 2011 11:34:34 +0000 (+0200) Subject: base/dracut-lib.sh: add ismounted() X-Git-Tag: 011~105 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6822764f251666dc47385a01e4146603519157ab;p=platform%2Fupstream%2Fdracut.git base/dracut-lib.sh: add ismounted() --- diff --git a/modules.d/99base/dracut-lib.sh b/modules.d/99base/dracut-lib.sh index e976351..6cb288b 100755 --- a/modules.d/99base/dracut-lib.sh +++ b/modules.d/99base/dracut-lib.sh @@ -330,6 +330,13 @@ udevproperty() { fi } +ismounted() { + while read a m a; do + [ "$m" = "$1" ] && return 0 + done < /proc/mounts + return 1 +} + wait_for_if_up() { local cnt=0 while [ $cnt -lt 20 ]; do