summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Szyprowski <m.szyprowski@samsung.com>2024-07-11 16:41:45 +0200
committerJaehoon Chung <jh80.chung@samsung.com>2024-08-20 13:06:24 +0900
commit455261dc71f1db53e458196bf6e00ff766b1b7b1 (patch)
tree11e075f34aefb218059bd68814f475e1279cb25d
parentf5c3319f3b9df90f30a1e7cc41585462081cd8b6 (diff)
downloadlinux-rpi-455261dc71f1db53e458196bf6e00ff766b1b7b1.tar.gz
linux-rpi-455261dc71f1db53e458196bf6e00ff766b1b7b1.tar.bz2
linux-rpi-455261dc71f1db53e458196bf6e00ff766b1b7b1.zip
This fixes booting with initramfs (cpio.gz based) with additional garbage added after the main initramfs image. The below message is displayed during booting. [ 0.546162] rootfs image is not initramfs (invalid magic at start of compressed archive); looks like an initrd Change-Id: Iddf10f6696c7d15ec68d29bc69614523c9fd9b65 Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
-rw-r--r--init/initramfs.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/init/initramfs.c b/init/initramfs.c
index 8d0fd946cdd2..828f7f4db67c 100644
--- a/init/initramfs.c
+++ b/init/initramfs.c
@@ -520,6 +520,7 @@ static char * __init unpack_to_rootfs(char *buf, unsigned long len)
&my_inptr, error);
if (res)
error("decompressor failed");
+ break;
} else if (compress_name) {
if (!message) {
snprintf(msg_buf, sizeof msg_buf,