From: Hannes Reinecke <hare-l3A5Bk7waGM@public.gmane.org>
To: Harald Hoyer <harald-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Cc: Thomas Renninger <trenn-l3A5Bk7waGM@public.gmane.org>,
initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Hannes Reinecke <hare-l3A5Bk7waGM@public.gmane.org>
Subject: [PATCH 03/10] 95dasd_mod: make dasd_cio_free optional
Date: Wed, 27 Nov 2013 16:44:14 +0100 [thread overview]
Message-ID: <1385567061-13247-4-git-send-email-hare@suse.de> (raw)
In-Reply-To: <1385567061-13247-1-git-send-email-hare-l3A5Bk7waGM@public.gmane.org>
dasd_cio_free is a RedHat-specific tool, so make it optional.
Signed-off-by: Hannes Reinecke <hare-l3A5Bk7waGM@public.gmane.org>
---
dracut-functions.sh | 9 +++++++++
modules.d/95dasd_mod/module-setup.sh | 3 ++-
modules.d/95dasd_mod/parse-dasd-mod.sh | 4 +++-
3 files changed, 14 insertions(+), 2 deletions(-)
diff --git a/dracut-functions.sh b/dracut-functions.sh
index 2872516..c2cf67a 100755
--- a/dracut-functions.sh
+++ b/dracut-functions.sh
@@ -741,6 +741,15 @@ inst_multiple() {
return $ret
}
+inst_multiple_optional() {
+ local ret
+ #dinfo "initdir=$initdir $DRACUT_INSTALL -l $@"
+ $DRACUT_INSTALL ${initdir:+-D "$initdir"} -o -a ${DRACUT_RESOLVE_DEPS:+-l} ${DRACUT_FIPS_MODE:+-H} "$@"
+ ret=$?
+ (($ret != 0)) && derror $DRACUT_INSTALL ${initdir:+-D "$initdir"} -o -a ${DRACUT_RESOLVE_DEPS:+-l} ${DRACUT_FIPS_MODE:+-H} "$@" || :
+ return $ret
+}
+
dracut_install() {
inst_multiple "$@"
}
diff --git a/modules.d/95dasd_mod/module-setup.sh b/modules.d/95dasd_mod/module-setup.sh
index 011010d..4546059 100755
--- a/modules.d/95dasd_mod/module-setup.sh
+++ b/modules.d/95dasd_mod/module-setup.sh
@@ -23,6 +23,7 @@ installkernel() {
# called by dracut
install() {
inst_hook cmdline 31 "$moddir/parse-dasd-mod.sh"
- inst_multiple dasd_cio_free grep sed seq
+ inst_multiple grep sed seq
+ inst_multiple_optional dasd_cio_free
}
diff --git a/modules.d/95dasd_mod/parse-dasd-mod.sh b/modules.d/95dasd_mod/parse-dasd-mod.sh
index 87c88ed..0236d12 100755
--- a/modules.d/95dasd_mod/parse-dasd-mod.sh
+++ b/modules.d/95dasd_mod/parse-dasd-mod.sh
@@ -15,4 +15,6 @@ if [ -n "$mod_args" ]; then
fi
unset dasd_arg
-dasd_cio_free
+if [ -x /sbin/dasd_cio_free ] ; then
+ dasd_cio_free
+fi
--
1.8.1.4
next prev parent reply other threads:[~2013-11-27 15:44 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-27 15:44 [PATCH 00/10] SUSE S/390 integration Hannes Reinecke
[not found] ` <1385567061-13247-1-git-send-email-hare-l3A5Bk7waGM@public.gmane.org>
2013-11-27 15:44 ` [PATCH 01/10] 95dasd: Install kernel modules only once Hannes Reinecke
2013-11-27 15:44 ` [PATCH 02/10] 95dasd: Only install module if normalize_dasd_arg is present Hannes Reinecke
2013-11-27 15:44 ` Hannes Reinecke [this message]
[not found] ` <1385567061-13247-4-git-send-email-hare-l3A5Bk7waGM@public.gmane.org>
2013-11-28 12:51 ` [PATCH 03/10] 95dasd_mod: make dasd_cio_free optional Harald Hoyer
[not found] ` <52973C68.8040504-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2013-11-28 12:53 ` Hannes Reinecke
2013-11-27 15:44 ` [PATCH 04/10] 95zfcp: Make installation optional Hannes Reinecke
2013-11-27 15:44 ` [PATCH 05/10] 95znet: " Hannes Reinecke
2013-11-27 15:44 ` [PATCH 06/10] Install /bin/mount Hannes Reinecke
[not found] ` <1385567061-13247-7-git-send-email-hare-l3A5Bk7waGM@public.gmane.org>
2013-11-28 13:23 ` Hannes Reinecke
[not found] ` <529743C7.80906-l3A5Bk7waGM@public.gmane.org>
2013-11-28 14:08 ` Harald Hoyer
2013-11-27 15:44 ` [PATCH 07/10] Fixup keymap setting for openSUSE Hannes Reinecke
2013-11-27 15:44 ` [PATCH 08/10] Check for plymouth lib directories Hannes Reinecke
2013-11-27 15:44 ` [PATCH 09/10] Add DASD configuration for SuSE Hannes Reinecke
2013-11-27 15:44 ` [PATCH 10/10] Add zfcp scripts for SUSE Hannes Reinecke
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1385567061-13247-4-git-send-email-hare@suse.de \
--to=hare-l3a5bk7wagm@public.gmane.org \
--cc=harald-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
--cc=initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=trenn-l3A5Bk7waGM@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox