forked from Mirror/pmbootstrap
install: allow to use last block for embedding (MR 2069)
Devices such as ODROIDs have binaries use which every single block for embedding. Do not raise an error when binaries are touching, but not overlapping, each other when embedding these binaries during installation. Add a test for this scenario, which fails when reverting the change. Co-Authored-By: Oliver Smith <ollieparanoid@postmarketos.org>
This commit is contained in:
parent
e900ee169a
commit
834cc7f877
2 changed files with 22 additions and 2 deletions
|
@ -465,8 +465,8 @@ def generate_binary_list(args, suffix, step):
|
|||
binary_start = offset * step
|
||||
binary_end = binary_start + binary_size
|
||||
for start, end in binary_ranges.items():
|
||||
if ((binary_start >= start and binary_start <= end) or
|
||||
(binary_end >= start and binary_end <= end)):
|
||||
if ((binary_start >= start and binary_start < end) or
|
||||
(binary_end > start and binary_end <= end)):
|
||||
raise RuntimeError("The firmware overlaps with at least one "
|
||||
f"other firmware image: {binary}")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue