Skip to content

elbepack: finetuning: fix losetup usage for command in losetup element - #472

Open
koalo wants to merge 2 commits into
Linutronix:masterfrom
koalo:devel/koalo/fix-losetup-command
Open

elbepack: finetuning: fix losetup usage for command in losetup element#472
koalo wants to merge 2 commits into
Linutronix:masterfrom
koalo:devel/koalo/fix-losetup-command

Conversation

@koalo

@koalo koalo commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

needs_loop_device listed partition-command (which is actually the type of the
element) instead of command. This leads to commands in losetup no longer
having access to a mounted image and thus fail.

Fixes: d2d5925 ("elbepack: finetuning: avoid losetup where possible")

Also add unit test that fails without the bug fix.

koalo added 2 commits July 27, 2026 07:25
needs_loop_device listed partition-command (which is actually the type of the
element) instead of command. This leads to commands in losetup no longer
having access to a mounted image and thus fail.

Fixes: d2d5925 ("elbepack: finetuning: avoid losetup where possible")
Signed-off-by: Florian Kauer <florian.kauer@linutronix.de>
Add a unit test to verify that elements that really need losetup get
proper losetup and vice versa.

Signed-off-by: Florian Kauer <florian.kauer@linutronix.de>
@t-8ch

t-8ch commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Thanks!

I picked up the bugfix.
For the new test I dislike that it relies on all kinds of internal implementation details.
If there is no nice way to have a unittest, instead we can add the project finetuning to tests/simple-validation-image.xml and validate the results in tests/simple-validation-image-test.py.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants