X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/86154153a622f87b6cc6209e355351975c82efb4..1f5043d5ac8cd5cc89d1511b0545a2a17775f3a6:/tools/firmware-utils/src/mkzynfw.c diff --git a/tools/firmware-utils/src/mkzynfw.c b/tools/firmware-utils/src/mkzynfw.c index f3343df72..36c176f43 100644 --- a/tools/firmware-utils/src/mkzynfw.c +++ b/tools/firmware-utils/src/mkzynfw.c @@ -999,12 +999,13 @@ calc_block_offsets(int type, uint32_t *offset) continue; next_offs = ALIGN(*offset, block->align); - avail = board->flash_size - board->romio_offs - next_offs; + avail = board->flash_size - next_offs; if (block->file_size > avail) { ERR("file %s is too big, offset = %u, size=%u," - " align = %u", block->file_name, + " avail = %u, align = %u", block->file_name, (unsigned)next_offs, (unsigned)block->file_size, + (unsigned)avail, (unsigned)block->align); res = -1; break;