summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2017-03-03 07:25:02 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2018-07-19 16:36:01 +0000
commit6efbfea98fb3722748de20eb411462c202fa935a (patch)
tree2bde6542485ebb5f558e8bd67292b278b32db9a9
parentMaking module loading quiet. (diff)
downloadinitramfs-tools-6efbfea98fb3722748de20eb411462c202fa935a.zip
initramfs-tools-6efbfea98fb3722748de20eb411462c202fa935a.tar.xz
Only warn about missing firmware if not in a chroot.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
-rw-r--r--debian/patches/progress-linux/0002-quiet-firmware-chroot.patch20
-rw-r--r--debian/patches/series1
2 files changed, 21 insertions, 0 deletions
diff --git a/debian/patches/progress-linux/0002-quiet-firmware-chroot.patch b/debian/patches/progress-linux/0002-quiet-firmware-chroot.patch
new file mode 100644
index 0000000..092f167
--- /dev/null
+++ b/debian/patches/progress-linux/0002-quiet-firmware-chroot.patch
@@ -0,0 +1,20 @@
+Author: Baumann <daniel.baumann@progress-linux.org>
+Description: Only warn about missing firmware if not in a chroot.
+
+diff -Naurp initramfs-tools.orig/hook-functions initramfs-tools/hook-functions
+--- initramfs-tools.orig/hook-functions
++++ initramfs-tools/hook-functions
+@@ -90,6 +90,13 @@ manual_add_modules()
+ continue
+ fi
+
++ # Only warn about missing firmware if
++ # not in a chroot
++ if [ "${verbose}" != "y" ] \
++ && [ "$(stat -c %d/%i /)" != "$(stat -Lc %d/%i /proc/1/root 2>/dev/null)" ]; then
++ continue
++ fi
++
+ kmod_modname="${kmod##*/}"
+ kmod_modname="${kmod_modname%.ko}"
+ if grep -q "^$kmod_modname\\>" /proc/modules "${CONFDIR}/modules"; then
diff --git a/debian/patches/series b/debian/patches/series
index 548c952..465232e 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
progress-linux/0001-quiet-modules.patch
+progress-linux/0002-quiet-firmware-chroot.patch