mdraid: always create need_shutdown, if we have assembled a raid
add back scsi_wait_scan
network: reintroduce rd.neednet

rd.neednet is used by anaconda and the network interfaces cannot
be known in advance.
fips: set /boot as symlink to /sysroot/boot if no boot= parameter

otherwise sha512hmac will error out with:

sha512hmac -c /sysroot/boot/.vmlinuz-2.6.32-220.el6.x86_64.hmac
Error opening "/boot/vmlinuz-2.6.32-220.el6.x86_64": No such file or directory.
install/dracut-install.c: Ensure deps are resolved when handling scripts

If we are doing lazy dep solving and happen to process a script with a
shebang on e.g. /bin/bash before we encounter the actual binary itself
we effectively ignore the fact that we've been asked to resolve the deps
and put the item in the 'seen' hashmap. Thus when we later really do try
and resolve deps, we short circuit and don't do anything.

Example test case:

$ cd
$ mkdir -p foo/bin
$ cp /bin/bash foo/bin
$ echo '#!/bin/bash' >foo/bin/script
$ dracut-install -D $HOME/foo -R $HOME/foo/bin/script $HOME/foo/bin/bash
install/dracut-install.c: Deal gracefully with paths containing double /'s

While such paths should not be included internally, we cannot
guarantee that external scripts with shebangs will not do this.

Some older versions of plymouth also resulted in double /'s
in some paths, so best deal with this gracefully.
install/dracut-install.c: No need to compare the NULL byte each time.
udev-rules: Pre usrmove systemd installs might not find udevd.

If users had switched to systemd-183+ but have not completed
the usrmove, then the variable ${systemdutildir} will likely
refer to /usr/lib/systemd NOT /lib/systemd and thus the
systemd-udevd daemon may not be found.

So let's try a little harder and add another hard coded path
and if we don't find it, then bail out hard.
mdraid: catch nested md raids

Thanks to Ian Dall!
znet: add some more kernel drivers
network: add ping and ping6

better for a quick debug
wait host devs in base module

each dev in host_devs[] should be waited in initqueue to make sure they
are oneline before initqueue finish.

Add a new wait_host_devs.sh in base module to make this a generic thing.
Because all the devs in fstab lines are also added to host_devs, so no need
do same wait in fstab-sys module anymore.

[v2->v3]: do not add slave devices to host_devs
          wait for persistent dev name in initramfs

Signed-off-by: Dave Young <dyoung@redhat.com>
Add for_each_host_dev_and_slaves for device only checking

For lvm, multipath, iscsi modules they do not care about the filesystem,
Also there could be devcie in host_devs but it does not get formated.

For these kind of modules, use for_each_host_dev_and_slaves will be better than use
for_each_host_dev_fs, here add a new function to iterate the host_devs and
their slave devices.

In original for_each_host_dev_fs, it will call check_block_and_slaves which
will return once helper function return 0, but this is not enough for kdump
iscsi setup. For kdump iscsi case, it need setup each slave devices so that
the iscsi target can be properly setuped in initramfs.

Thus, this patch also add new functions check_block_and_slaves_all and
for_each_host_dev_and_slaves_all.

Signed-off-by: Dave Young <dyoung@redhat.com>
Tested-by: WANG Chao <chaowang@redhat.com>
Add a dracut option --device to bring up a device in initramfs

Kdump support dump to raw device which could be on top of complex storage
such as multipath and iscsi which are standalone dracut modules.

Add a --device option to dracut which will add the device to host_devs so
dracut can add the dependent modules automaticlly and enable them in initramfs.

--device will accept device node name as the param.

Signed-off-by: Dave Young <dyoung@redhat.com>
Tested-by: Chao Wang <chaowang@redhat.com>
moved the /etc/host_devs write out to 99base

also removed some left-over debugging code
install/dracut-install.c: correct usage() for hmac
dracut-install: FIPS workaround for fipscheck dir

In recent Fedora distro are all hmac files located in /lib
(to avoid multiarch conflict).

When installing hmac file, also install files from these locations.

Signed-off-by: Milan Broz <mbroz@redhat.com>
Require fipscheck and libssl in FIPS module

To properly perform verification in FIPS mode,
we need to install fipscheck and libssl explicitly.

(cryptsetup seems to be the first user of this verification in ramdisk...)

Signed-off-by: Milan Broz <mbroz@redhat.com>
make splitsep preserve backslashes (RHBZ#851295)

splitsep() would drop escapes from its inputs. For example:

  splitsep ':' 'first:middle:\e\s\c\a\p\e\d' a b c

gave a='first', b='middle', c='escaped'. Even worse:

  splitsep ':' '\e\s\c\a\p\e\d:middle:last' a b c

gave a='escaped', b='escaped', c='escaped:middle:last'.

This fixes the quoting so both calls return the values you'd expect
(e.g. 'first', 'middle', '\e\s\c\a\p\e\d').
crypt: do not run systemd crypt generator

"systemctl daemon-reload" does it already for us