- More empty commandline fixes * Add: 0074-More-empty-cmdline-fixes.patch - 95dasd_rules: enable parsing of rd.dasd= commandline parameter * Add: 0075-95dasd_rules-enable-parsing-of-rd.dasd-commandline-p.patch - Correctly set cio_ignore for dynamic s390 rules * Add: 0076-Correctly-set-cio_ignore-for-dynamic-s390-rules.patch - 90multipath: add missing 11-dm-mpath.rules file (bnc#883149) * Add: 0077-90multipath-add-missing-11-dm-mpath.rules-file.patch - Restore original IFS value (bnc#883770) * Add: 0078-Restore-original-IFS-value.patch - Fix non-export of journal dev boot options * Add: 0071-Fix-non-export-of-journal-dev-boot-options.patch - Also export root= boot param for hostonly-cmdline * Add: 0072-Also-export-root-boot-param-for-hostonly-cmdline-cas.patch - Don't create lots of empty cmdline files * Add: 0073-Don-t-create-lots-of-empty-cmdline-files-for-hostonl.patch OBS-URL: https://build.opensuse.org/request/show/238369 OBS-URL: https://build.opensuse.org/package/show/Base:System/dracut?expand=0&rev=164
97 lines
3.6 KiB
Diff
97 lines
3.6 KiB
Diff
From 706f28a7bc193455fcd0656f70adaee442f12ff8 Mon Sep 17 00:00:00 2001
|
|
From: Thorsten Behrens <tbehrens@suse.com>
|
|
Date: Wed, 18 Jun 2014 02:09:38 +0200
|
|
Subject: Don't create lots of empty cmdline files for hostonly-cmdline case
|
|
|
|
This aligns other places piping cmdline() output to cmdline.d files
|
|
with the earlier fix for 95rootfs-block.
|
|
|
|
Signed-off-by: Thorsten Behrens <tbehrens@suse.com>
|
|
---
|
|
modules.d/90crypt/module-setup.sh | 4 ++--
|
|
modules.d/90dmraid/module-setup.sh | 4 ++--
|
|
modules.d/90lvm/module-setup.sh | 4 ++--
|
|
modules.d/90mdraid/module-setup.sh | 4 ++--
|
|
modules.d/95resume/module-setup.sh | 5 ++---
|
|
5 files changed, 10 insertions(+), 11 deletions(-)
|
|
|
|
diff --git a/modules.d/90crypt/module-setup.sh b/modules.d/90crypt/module-setup.sh
|
|
index 5707404..e423a95 100755
|
|
--- a/modules.d/90crypt/module-setup.sh
|
|
+++ b/modules.d/90crypt/module-setup.sh
|
|
@@ -52,8 +52,8 @@ cmdline() {
|
|
install() {
|
|
|
|
if [[ $hostonly_cmdline == "yes" ]]; then
|
|
- cmdline >> "${initdir}/etc/cmdline.d/90crypt.conf"
|
|
- echo >> "${initdir}/etc/cmdline.d/90crypt.conf"
|
|
+ local _cryptconf=$(cmdline)
|
|
+ [[ $_cryptconf ]] && printf "%s\n" "$_cryptconf" >> "${initdir}/etc/cmdline.d/90crypt.conf"
|
|
fi
|
|
|
|
inst_multiple cryptsetup rmdir readlink umount
|
|
diff --git a/modules.d/90dmraid/module-setup.sh b/modules.d/90dmraid/module-setup.sh
|
|
index aebb28d..3769dd0 100755
|
|
--- a/modules.d/90dmraid/module-setup.sh
|
|
+++ b/modules.d/90dmraid/module-setup.sh
|
|
@@ -66,8 +66,8 @@ install() {
|
|
local _i
|
|
|
|
if [[ $hostonly_cmdline == "yes" ]]; then
|
|
- cmdline >> "${initdir}/etc/cmdline.d/90dmraid.conf"
|
|
- echo >> "${initdir}/etc/cmdline.d/90dmraid.conf"
|
|
+ local _raidconf=$(cmdline)
|
|
+ [[ $_raidconf ]] && printf "%s\n" "$_raidconf" >> "${initdir}/etc/cmdline.d/90dmraid.conf"
|
|
fi
|
|
|
|
inst_multiple dmraid
|
|
diff --git a/modules.d/90lvm/module-setup.sh b/modules.d/90lvm/module-setup.sh
|
|
index 5b810b9..2a5b392 100755
|
|
--- a/modules.d/90lvm/module-setup.sh
|
|
+++ b/modules.d/90lvm/module-setup.sh
|
|
@@ -51,8 +51,8 @@ install() {
|
|
inst lvm
|
|
|
|
if [[ $hostonly_cmdline == "yes" ]]; then
|
|
- cmdline >> "${initdir}/etc/cmdline.d/90lvm.conf"
|
|
- echo >> "${initdir}/etc/cmdline.d/90lvm.conf"
|
|
+ local _lvmconf=$(cmdline)
|
|
+ [[ $_lvmconf ]] && printf "%s\n" "$_lvmconf" >> "${initdir}/etc/cmdline.d/90lvm.conf"
|
|
fi
|
|
|
|
inst_rules "$moddir/64-lvm.rules"
|
|
diff --git a/modules.d/90mdraid/module-setup.sh b/modules.d/90mdraid/module-setup.sh
|
|
index 4963537..da464b8 100755
|
|
--- a/modules.d/90mdraid/module-setup.sh
|
|
+++ b/modules.d/90mdraid/module-setup.sh
|
|
@@ -73,8 +73,8 @@ install() {
|
|
inst $(command -v mdadm) /sbin/mdadm
|
|
|
|
if [[ $hostonly_cmdline == "yes" ]]; then
|
|
- cmdline >> "${initdir}/etc/cmdline.d/90mdraid.conf"
|
|
- echo >> "${initdir}/etc/cmdline.d/90mdraid.conf"
|
|
+ local _raidconf=$(cmdline)
|
|
+ [[ $_raidconf ]] && printf "%s\n" "$_raidconf" >> "${initdir}/etc/cmdline.d/90mdraid.conf"
|
|
fi
|
|
|
|
# <mdadm-3.3 udev rule
|
|
diff --git a/modules.d/95resume/module-setup.sh b/modules.d/95resume/module-setup.sh
|
|
index 7f3cf24..b1044ed 100755
|
|
--- a/modules.d/95resume/module-setup.sh
|
|
+++ b/modules.d/95resume/module-setup.sh
|
|
@@ -33,9 +33,8 @@ cmdline() {
|
|
# called by dracut
|
|
install() {
|
|
local _bin
|
|
-
|
|
- cmdline >> "${initdir}/etc/cmdline.d/95resume.conf"
|
|
- echo >> "${initdir}/etc/cmdline.d/95resume.conf"
|
|
+ local _resumeconf=$(cmdline)
|
|
+ [[ $_resumeconf ]] && printf "%s\n" "$_resumeconf" >> "${initdir}/etc/cmdline.d/95resume.conf"
|
|
|
|
# Optional uswsusp support
|
|
for _bin in /usr/sbin/resume /usr/lib/suspend/resume /usr/lib/uswsusp/resume
|
|
--
|
|
1.8.4.5
|
|
|