diff options
author | Tomasz Maciej Nowak <tomek_n@o2.pl> | 2019-05-11 19:37:32 +0200 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2019-05-11 23:11:04 +0200 |
commit | 30b5554411192415ce70f16c1b48b11ce013bbf2 (patch) | |
tree | 054b3a0f69db1ffb02f828b656fe7e8d8f5ff5f2 /target/linux/mvebu/image/gen_mvebu_sdcard_img.sh | |
parent | 9509a6df0bff483fc165bc5da98f03d2d736622f (diff) | |
download | upstream-30b5554411192415ce70f16c1b48b11ce013bbf2.tar.gz upstream-30b5554411192415ce70f16c1b48b11ce013bbf2.tar.bz2 upstream-30b5554411192415ce70f16c1b48b11ce013bbf2.zip |
mvebu: image: don't create unnecessarily shell variables
Use make syntax to pass the U-Boot image location and boot with root
partitions size, instead of relying on shell functions and variables.
Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
Diffstat (limited to 'target/linux/mvebu/image/gen_mvebu_sdcard_img.sh')
-rwxr-xr-x | target/linux/mvebu/image/gen_mvebu_sdcard_img.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/target/linux/mvebu/image/gen_mvebu_sdcard_img.sh b/target/linux/mvebu/image/gen_mvebu_sdcard_img.sh index 67416ed80c..e0230e48b6 100755 --- a/target/linux/mvebu/image/gen_mvebu_sdcard_img.sh +++ b/target/linux/mvebu/image/gen_mvebu_sdcard_img.sh @@ -18,7 +18,7 @@ # usage() { - echo "$0 <outfile> [<bootloader> <type_partitionN> <sectors_partitionN> <img_partitionN>]?" + echo "$0 <outfile> [<bootloader> <type_partitionN> <size_partitionN> <img_partitionN>]?" } # always require first 2 or 3 arguments @@ -46,7 +46,7 @@ dd if=/dev/zero of="$OUTFILE" bs=512 count=1 >/dev/null printf "Done\n" while [ "$#" -ge 3 ]; do - ptgen_args="$ptgen_args -t $1 -p $(($2 / 2 + 256))" + ptgen_args="$ptgen_args -t $1 -p $(($2 * 1024 + 256))" parts="$parts$3 " shift; shift; shift done |