From: Jonas Gorski Date: Wed, 4 Nov 2015 11:33:22 +0000 (+0000) Subject: brcm63xx: work around boot failures with squashfs on BCM6368 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=191dc96dc0d7edeed8db81f866b2ad5e74f9c7cb;p=project%2Ffirmware-utils.git brcm63xx: work around boot failures with squashfs on BCM6368 Due to the LWL/LWR SMP issue on BCM6368, booting with squash might fail if the rootfs is not word aligned. As a quick fix, work around it by ensuring this condition is always true. Reported-by: Álvaro Fernández Rojas Signed-off-by: Jonas Gorski SVN-Revision: 47380 --- diff --git a/src/imagetag.c b/src/imagetag.c index 6a46a7e..90fb7a4 100644 --- a/src/imagetag.c +++ b/src/imagetag.c @@ -164,6 +164,8 @@ int tagfile(const char *kernel, const char *rootfs, const char *bin, \ /* align the start if requested */ if (args->align_rootfs_flag) rootfsoff = (rootfsoff % block_size) > 0 ? (((rootfsoff / block_size) + 1) * block_size) : rootfsoff; + else + rootfsoff = (rootfsoff % 4) > 0 ? (((rootfsoff / 4) + 1) * 4) : rootfsoff; /* align the end */ rootfsend = rootfsoff + getlen(rootfsfile);