From: John Reiser <jreiser-Po6cBsTGB2ZWk0Htik3J/w@public.gmane.org>
To: initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: build initramfs: unclear _mpargs in instmods()
Date: Mon, 29 Aug 2011 14:42:15 -0700 [thread overview]
Message-ID: <4E5C07B7.4050907@bitwagon.com> (raw)
The local variable _mpargs in function instmods() in file dracut-functions
looks peculiar. The documentation is non-existent, but still ...
First, $_mpargs is not passed to modprobe via for_each_kmod_dep.
This is strange because my guess is that "_mpargs" means
"extra arguments for modprobe".
Second, the leading "--" will be lopped when a leading pathname
is stripped via
_mod=${_mod##*/}
It seems to me that a leading "--" should inhibit modification.
Here's the corresponding patch to current HEAD (from dracut-013.)
diff --git a/dracut-functions b/dracut-functions
index a3340e4..c28766e 100755
--- a/dracut-functions
+++ b/dracut-functions
@@ -919,7 +919,6 @@ instmods() {
fi
;;
--*)
- _mod=${_mod##*/}
_mpargs+=" $_mod";;
i2o_scsi) shift; continue;; # Do not load this diagnostic-only module
*) _mod=${_mod##*/}
@@ -942,7 +941,7 @@ instmods() {
# ok, load the module, all its dependencies, and any firmware
# it may require
for_each_kmod_dep install_kmod_with_fw $_mod \
- --set-version $kernel ${_moddirname}
+ --set-version $kernel ${_moddirname} $_mpargs
((_ret+=$?))
;;
esac
--
next reply other threads:[~2011-08-29 21:42 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-29 21:42 John Reiser [this message]
[not found] ` <4E5C07B7.4050907-Po6cBsTGB2ZWk0Htik3J/w@public.gmane.org>
2011-08-30 10:19 ` build initramfs: unclear _mpargs in instmods() Harald Hoyer
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=4E5C07B7.4050907@bitwagon.com \
--to=jreiser-po6cbstgb2zwk0htik3j/w@public.gmane.org \
--cc=initramfs-u79uwXL29TY76Z2rM5mHXA@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.