From d9076cac19db5169777871b4bf95acd1f6495280 Mon Sep 17 00:00:00 2001
From: Harald Hoyer <harald@redhat.com>
Date: Fri, 8 Feb 2013 14:14:10 +0100
Subject: [PATCH] btrfs/btrfs_finished.sh: use btrfs device ready for probing
---
modules.d/90btrfs/btrfs_finished.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/modules.d/90btrfs/btrfs_finished.sh b/modules.d/90btrfs/btrfs_finished.sh
index 5e7691a..19715f6 100755
--- a/modules.d/90btrfs/btrfs_finished.sh
+++ b/modules.d/90btrfs/btrfs_finished.sh
@@ -11,6 +11,7 @@ btrfs_check_complete() {
_rootinfo=$(udevadm info --query=env "--name=$_dev" 2>/dev/null)
if strstr "$_rootinfo" "ID_FS_TYPE=btrfs"; then
info "Checking, if btrfs device complete"
+ btrfs device ready "$_dev" >/dev/null 2>&1 && return 0
unset __btrfs_mount
mount -o ro "$_dev" /tmp >/dev/null 2>&1
__btrfs_mount=$?