aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomasz Maciej Nowak <tomek_n@o2.pl>2019-09-17 16:21:51 +0200
committerChristian Lamparter <chunkeey@gmail.com>2019-09-21 22:17:39 +0200
commit66b7c82bb1767d0c4c1e62ae8051154f182ed2d7 (patch)
tree693176f1d0674cba14c079f07e098cb79d945ea8
parentd1e3f32dcf63d19dcfe5cb4a1d8437e7a55cb96e (diff)
downloadupstream-66b7c82bb1767d0c4c1e62ae8051154f182ed2d7.tar.gz
upstream-66b7c82bb1767d0c4c1e62ae8051154f182ed2d7.tar.bz2
upstream-66b7c82bb1767d0c4c1e62ae8051154f182ed2d7.zip
ath79: image: pad kernel for Adtran/Bluesocket devices
It has been reported that using the sysupgrade-tar image will trigger "lzma_decode failed error". The RedBoot bootloader always loads data from flash till block size boundary, so if there's no padding it'll also load the beginning of rootfs, and it seems that lzma_decoder can't handle that garbage data. Previously the script creating combined-image silently padded the kernel and rootfs, but since sysupgrade-tar doesn't, pad the default kernel image. Fixes: 900330f ("ath79: image: retire combined-image for Adtran/Bluesocket devices") Cc: Brian Gonyer <bgonyer@gmail.com> Cc: Daniel Gimpelevich <daniel@gimpelevich.san-francisco.ca.us> Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
-rw-r--r--target/linux/ath79/image/generic.mk4
1 files changed, 2 insertions, 2 deletions
diff --git a/target/linux/ath79/image/generic.mk b/target/linux/ath79/image/generic.mk
index e1304a2166..9ffb724c5f 100644
--- a/target/linux/ath79/image/generic.mk
+++ b/target/linux/ath79/image/generic.mk
@@ -103,11 +103,11 @@ define Device/adtran_bsap1880
ATH_SOC := ar7161
DEVICE_VENDOR := Adtran/Bluesocket
DEVICE_PACKAGES += -swconfig -uboot-envtools fconfig
- KERNEL := kernel-bin | append-dtb | lzma
+ KERNEL := kernel-bin | append-dtb | lzma | pad-to $$(BLOCKSIZE)
KERNEL_INITRAMFS := kernel-bin | append-dtb
IMAGE_SIZE := 11200k
IMAGES += kernel.bin rootfs.bin
- IMAGE/kernel.bin := append-kernel | pad-to $$$$(BLOCKSIZE)
+ IMAGE/kernel.bin := append-kernel
IMAGE/rootfs.bin := append-rootfs | pad-rootfs
IMAGE/sysupgrade.bin := append-rootfs | pad-rootfs | check-size $$$$(IMAGE_SIZE) | sysupgrade-tar rootfs=$$$$@ | append-metadata
endef