]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
95zfcp: Make installation optional
authorHannes Reinecke <hare@suse.de>
Fri, 29 Nov 2013 12:13:45 +0000 (13:13 +0100)
committerHarald Hoyer <harald@redhat.com>
Thu, 5 Dec 2013 14:13:29 +0000 (15:13 +0100)
zfcp_cio_free is a RedHat-specific tool, so do not install this
module if the program isn't present.

Signed-off-by: Hannes Reinecke <hare@suse.de>
modules.d/95zfcp/module-setup.sh

index 5d9b506dc6cf27dc2d55e8d826961fe04310f42e..dfbeed5b6be9b53d30de581baa63c02581fc2c7b 100755 (executable)
@@ -5,6 +5,7 @@
 # called by dracut
 check() {
     arch=$(uname -m)
+    [ -x /sbin/zfcp_cio_free ] || return 1
     [ "$arch" = "s390" -o "$arch" = "s390x" ] || return 1
 
     return 0
@@ -12,9 +13,6 @@ check() {
 
 # called by dracut
 depends() {
-    arch=$(uname -m)
-    [ "$arch" = "s390" -o "$arch" = "s390x" ] || return 1
-
     return 0
 }