bcm53xx: sysupgrade: optimize building UBI image
authorRafał Miłecki <rafal@milecki.pl>
Thu, 20 Feb 2020 12:40:55 +0000 (13:40 +0100)
committerRafał Miłecki <rafal@milecki.pl>
Sat, 21 Mar 2020 21:31:35 +0000 (22:31 +0100)
commit8abefc8896e7138a101fbb3d228946c43321503e
treef71f2ca74fc2d6f7a881c68792ce822ff62ba46b
parent547f1ec25af59f9e69ae3cb69d1312e63138d4bf
bcm53xx: sysupgrade: optimize building UBI image

Use "truncate" to adjust size of existing file instead of "dd" which
required creating a copy. This saves space on tmpfs. It may be as low
as 2.1 MiB when using OpenWrt default user space and way more (20+ MiB)
when flashing vendor firmware.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
target/linux/bcm53xx/base-files/lib/upgrade/platform.sh