Merge branch 'master' of github.com:haraldh/dracut
commit
cb6d49bc9d
|
@ -40,6 +40,8 @@ if [ -n "$NEEDBOOTDEV" ] && getargbool 1 rd.neednet; then
|
||||||
#[ -z "$BOOTDEV" ] && warn "Please supply bootdev argument for multiple ip= lines"
|
#[ -z "$BOOTDEV" ] && warn "Please supply bootdev argument for multiple ip= lines"
|
||||||
echo "rd.neednet=1" > /etc/cmdline.d/dracut-neednet.conf
|
echo "rd.neednet=1" > /etc/cmdline.d/dracut-neednet.conf
|
||||||
info "Multiple ip= arguments: assuming rd.neednet=1"
|
info "Multiple ip= arguments: assuming rd.neednet=1"
|
||||||
|
else
|
||||||
|
unset NEEDBOOTDEV
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Check ip= lines
|
# Check ip= lines
|
||||||
|
@ -48,17 +50,14 @@ for p in $(getargs ip=); do
|
||||||
ip_to_var $p
|
ip_to_var $p
|
||||||
|
|
||||||
# make first device specified the BOOTDEV
|
# make first device specified the BOOTDEV
|
||||||
if [ -z "$BOOTDEV" ] && [ -n "$dev" ]; then
|
if [ -n "$NEEDBOOTDEV" ] && [ -z "$BOOTDEV" ] && [ -n "$dev" ]; then
|
||||||
BOOTDEV="$dev"
|
BOOTDEV="$dev"
|
||||||
[ -n "$NEEDBOOTDEV" ] && info "Setting bootdev to '$BOOTDEV'"
|
info "Setting bootdev to '$BOOTDEV'"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# skip ibft since we did it above
|
# skip ibft since we did it above
|
||||||
[ "$autoconf" = "ibft" ] && continue
|
[ "$autoconf" = "ibft" ] && continue
|
||||||
|
|
||||||
# We need to have an ip= line for the specified bootdev
|
|
||||||
[ -n "$NEEDBOOTDEV" ] && [ "$dev" = "$BOOTDEV" ] && BOOTDEVOK=1
|
|
||||||
|
|
||||||
# Empty autoconf defaults to 'dhcp'
|
# Empty autoconf defaults to 'dhcp'
|
||||||
if [ -z "$autoconf" ] ; then
|
if [ -z "$autoconf" ] ; then
|
||||||
warn "Empty autoconf values default to dhcp"
|
warn "Empty autoconf values default to dhcp"
|
||||||
|
|
|
@ -39,15 +39,17 @@ installkernel() {
|
||||||
ehci-hcd ehci-pci ehci-platform \
|
ehci-hcd ehci-pci ehci-platform \
|
||||||
ohci-hcd ohci-pci \
|
ohci-hcd ohci-pci \
|
||||||
uhci-hcd \
|
uhci-hcd \
|
||||||
xhci-hcd xhci-pci xhci-plat-hcd
|
xhci-hcd xhci-pci xhci-plat-hcd \
|
||||||
|
|
||||||
hostonly='' instmods \
|
|
||||||
"=drivers/hid" \
|
"=drivers/hid" \
|
||||||
"=drivers/input/serio" \
|
"=drivers/input/serio" \
|
||||||
"=drivers/input/keyboard"
|
"=drivers/input/keyboard" \
|
||||||
|
"=drivers/usb/storage"
|
||||||
|
|
||||||
instmods yenta_socket scsi_dh_rdac scsi_dh_emc scsi_dh_alua \
|
instmods \
|
||||||
atkbd i8042 usbhid firewire-ohci pcmcia hv-vmbus
|
yenta_socket scsi_dh_rdac scsi_dh_emc scsi_dh_alua \
|
||||||
|
atkbd i8042 usbhid firewire-ohci pcmcia hv-vmbus \
|
||||||
|
virtio virtio_blk virtio_ring virtio_pci virtio_scsi \
|
||||||
|
"=drivers/pcmcia" =ide
|
||||||
|
|
||||||
if [[ "$(uname -p)" == arm* ]]; then
|
if [[ "$(uname -p)" == arm* ]]; then
|
||||||
# arm specific modules
|
# arm specific modules
|
||||||
|
@ -60,9 +62,6 @@ installkernel() {
|
||||||
${NULL}
|
${NULL}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# install virtual machine support
|
|
||||||
instmods virtio virtio_blk virtio_ring virtio_pci virtio_scsi \
|
|
||||||
"=drivers/pcmcia" =ide "=drivers/usb/storage"
|
|
||||||
|
|
||||||
find_kernel_modules | block_module_filter | instmods
|
find_kernel_modules | block_module_filter | instmods
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,8 @@ Before=dracut-cmdline.service
|
||||||
After=systemd-journald.socket
|
After=systemd-journald.socket
|
||||||
Wants=systemd-journald.socket
|
Wants=systemd-journald.socket
|
||||||
ConditionPathExists=/usr/lib/initrd-release
|
ConditionPathExists=/usr/lib/initrd-release
|
||||||
ConditionKernelCommandLine=rd.cmdline=ask
|
ConditionKernelCommandLine=|rd.cmdline=ask
|
||||||
|
ConditionPathExistsGlob=|/etc/cmdline.d/*.conf
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Environment=DRACUT_SYSTEMD=1
|
Environment=DRACUT_SYSTEMD=1
|
||||||
|
|
|
@ -1,5 +1,9 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
type getarg >/dev/null 2>&1 || . /lib/dracut-lib.sh
|
||||||
|
|
||||||
|
getarg "rd.cmdline=ask" || exit 0
|
||||||
|
|
||||||
sleep 0.5
|
sleep 0.5
|
||||||
echo
|
echo
|
||||||
sleep 0.5
|
sleep 0.5
|
||||||
|
|
|
@ -120,7 +120,9 @@ if getarg "rd.cmdline=ask"; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! getargbool 1 'rd.hostonly'; then
|
if ! getargbool 1 'rd.hostonly'; then
|
||||||
|
[ -f /etc/cmdline.d/99-cmdline-ask.conf ] && mv /etc/cmdline.d/99-cmdline-ask.conf /tmp/99-cmdline-ask.conf
|
||||||
remove_hostonly_files
|
remove_hostonly_files
|
||||||
|
[ -f /tmp/99-cmdline-ask.conf ] && mv /tmp/99-cmdline-ask.conf /etc/cmdline.d/99-cmdline-ask.conf
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# run scriptlets to parse the command line
|
# run scriptlets to parse the command line
|
||||||
|
|
Loading…
Reference in New Issue