]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
iscsi/module-setup.sh: only install s390 driver on s390 arch
authorHarald Hoyer <harald@redhat.com>
Mon, 18 Jun 2012 11:26:55 +0000 (13:26 +0200)
committerHarald Hoyer <harald@redhat.com>
Mon, 18 Jun 2012 11:26:55 +0000 (13:26 +0200)
modules.d/95iscsi/module-setup.sh

index bfd9d7347416d91add32f43c0e329546f7876375..fefc240ae052f1ce19d0d5aa3b9b979faf107846 100755 (executable)
@@ -37,6 +37,8 @@ depends() {
 }
 
 installkernel() {
+    local _arch=$(uname -m)
+
     instmods iscsi_tcp iscsi_ibft crc32c bnx2i iscsi_boot_sysfs qla4xxx cxgb3i cxgb4i be2iscsi
     iscsi_module_filter() {
         local _iscsifuncs='iscsi_register_transport'
@@ -47,8 +49,9 @@ installkernel() {
             *.ko.xz) [[ $(xz -dc   <$_f) =~ $_iscsifuncs ]] && echo "$_f" ;;
             esac
         done
+        return 0;
     }
-    { find_kernel_modules_by_path drivers/scsi; find_kernel_modules_by_path drivers/s390/scsi; } \
+    { find_kernel_modules_by_path drivers/scsi; if [ "$_arch" = "s390" -o "$_arch" = "s390x" ]; then find_kernel_modules_by_path drivers/s390/scsi; fi;} \
     | iscsi_module_filter  |  instmods
 }