From 81f34604aae25e2392a1bca02246c18e3cbca641 Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Thu, 20 Mar 2014 13:45:30 +0100 Subject: [PATCH] dracut-037-3.git20140320 - fixed dracut-initramfs-restore with microcode --- ...-restore-fix-unpacking-with-early-mi.patch | 39 +++++++++++++++++++ ...stemd-add-systemd-gpt-auto-generator.patch | 21 ++++++++++ dracut.spec | 9 ++++- 3 files changed, 67 insertions(+), 2 deletions(-) create mode 100644 0001-dracut-initramfs-restore-fix-unpacking-with-early-mi.patch create mode 100644 0002-systemd-add-systemd-gpt-auto-generator.patch diff --git a/0001-dracut-initramfs-restore-fix-unpacking-with-early-mi.patch b/0001-dracut-initramfs-restore-fix-unpacking-with-early-mi.patch new file mode 100644 index 0000000..7e79db4 --- /dev/null +++ b/0001-dracut-initramfs-restore-fix-unpacking-with-early-mi.patch @@ -0,0 +1,39 @@ +From 0626cbe923732d45739ea6da4b816c78c44503ef Mon Sep 17 00:00:00 2001 +From: Harald Hoyer +Date: Thu, 20 Mar 2014 13:18:13 +0100 +Subject: [PATCH] dracut-initramfs-restore: fix unpacking with early microcode + +--- + dracut-initramfs-restore.sh | 10 +++++++--- + 1 file changed, 7 insertions(+), 3 deletions(-) + +diff --git a/dracut-initramfs-restore.sh b/dracut-initramfs-restore.sh +index f29c814..0dd1938 100644 +--- a/dracut-initramfs-restore.sh ++++ b/dracut-initramfs-restore.sh +@@ -6,6 +6,10 @@ set -e + + KERNEL_VERSION="$(uname -r)" + ++[[ $dracutbasedir ]] || dracutbasedir=/usr/lib/dracut ++SKIP="$dracutbasedir/skipcpio" ++[[ -x $SKIP ]] || SKIP=cat ++ + [[ -f /etc/machine-id ]] && read MACHINE_ID < /etc/machine-id + + if [[ $MACHINE_ID ]] && [[ -d /boot/${MACHINE_ID} || -L /boot/${MACHINE_ID} ]] ; then +@@ -16,11 +20,11 @@ fi + cd /run/initramfs + + [ -f .need_shutdown -a -f "$IMG" ] || exit 1 +-if zcat "$IMG" | cpio -id --quiet >/dev/null; then ++if $SKIP "$IMG" | zcat | cpio -id --no-absolute-filenames --quiet >/dev/null; then + rm -f -- .need_shutdown +-elif xzcat "$IMG" | cpio -id --quiet >/dev/null; then ++elif $SKIP "$IMG" | xzcat | cpio -id --no-absolute-filenames --quiet >/dev/null; then + rm -f -- .need_shutdown +-elif lz4 -d -c "$IMG" | cpio -id --quiet >/dev/null; then ++elif $SKIP "$IMG" | lz4 -d -c | cpio -id --no-absolute-filenames --quiet >/dev/null; then + rm -f -- .need_shutdown + else + # something failed, so we clean up diff --git a/0002-systemd-add-systemd-gpt-auto-generator.patch b/0002-systemd-add-systemd-gpt-auto-generator.patch new file mode 100644 index 0000000..199d293 --- /dev/null +++ b/0002-systemd-add-systemd-gpt-auto-generator.patch @@ -0,0 +1,21 @@ +From a9f4b9cdb015a06adc280dd51e5c3dda3e82f515 Mon Sep 17 00:00:00 2001 +From: Harald Hoyer +Date: Thu, 20 Mar 2014 13:42:08 +0100 +Subject: [PATCH] systemd: add systemd-gpt-auto-generator + +--- + modules.d/98systemd/module-setup.sh | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/modules.d/98systemd/module-setup.sh b/modules.d/98systemd/module-setup.sh +index c72aad4..e7bf73b 100755 +--- a/modules.d/98systemd/module-setup.sh ++++ b/modules.d/98systemd/module-setup.sh +@@ -44,6 +44,7 @@ install() { + $systemdutildir/systemd-modules-load \ + $systemdutildir/systemd-vconsole-setup \ + $systemdutildir/system-generators/systemd-fstab-generator \ ++ $systemdutildir/system-generators/systemd-gpt-auto-generator \ + \ + $systemdsystemunitdir/cryptsetup.target \ + $systemdsystemunitdir/emergency.target \ diff --git a/dracut.spec b/dracut.spec index 8632a05..422db30 100644 --- a/dracut.spec +++ b/dracut.spec @@ -11,7 +11,7 @@ Name: dracut Version: 037 -Release: 1%{?dist} +Release: 3.git20140320%{?dist} Summary: Initramfs generator using udev %if 0%{?fedora} || 0%{?rhel} @@ -30,6 +30,8 @@ URL: https://dracut.wiki.kernel.org/ # Source can be generated by # http://git.kernel.org/?p=boot/dracut/dracut.git;a=snapshot;h=%{version};sf=tgz Source0: http://www.kernel.org/pub/linux/utils/boot/dracut/dracut-%{version}.tar.xz +Patch1: 0001-dracut-initramfs-restore-fix-unpacking-with-early-mi.patch +Patch2: 0002-systemd-add-systemd-gpt-auto-generator.patch BuildRequires: bash git @@ -478,7 +480,10 @@ rm -rf -- $RPM_BUILD_ROOT %endif %changelog -* Wed Mar 19 2014 Harald Hoyer 037-1 +* Thu Mar 20 2014 Harald Hoyer 037-3.git20140320 +- fixed dracut-initramfs-restore with microcode + +* Thu Mar 20 2014 Harald Hoyer 037-1 - version 037 * Thu Feb 06 2014 Harald Hoyer 036-16.git20140206