Skip to content

Conversation

@isi-lincoln
Copy link
Contributor

When the user runs rpi-eeprom-config to sign a bootloader image, if the image is not the correct size, the error message returns a tautology:

rpi-eeprom-config -c boot.conf -p /tmp/rpi-pubkey.pem -o pieeprom.upd /tmp/downloaded-boot.img
ERROR: /tmp/downloaded-boot.img: Expected size 62914560 bytes actual size 62914560 bytes

When it should be alerting the user that there are only two valid values for a bootloader size. My MR addresses this issue by returning the acceptable values for the bootloader size in the image.

./rpi-eeprom-config -c boot.conf -p /tmp/rpi-pubkey.pem  -o pieeprom.upd /tmp/downloaded-boot.img
ERROR: /tmp/downloaded-boot.img: Expected sizes [524288, 2097152] bytes, got actual size 62914560 bytes

When the user runs rpi-eeprom-config to sign a bootloader image,
if the image is not the correct size, the error message returns
a tautology:

rpi-eeprom-config -c boot.conf -p /tmp/rpi-pubkey.pem \
-o pieeprom.upd /tmp/downloaded-boot.img

ERROR: /tmp/downloaded-boot.img: \
Expected size 62914560 bytes actual size 62914560 bytes

When it should be alerting the user that there are only two
valid values for a bootloader size.  My MR addresses this issue
by returning the acceptable values for the bootloader size in the
image.

./rpi-eeprom-config -c boot.conf -p /tmp/rpi-pubkey.pem \
-o pieeprom.upd /tmp/downloaded-boot.img

ERROR: /tmp/downloaded-boot.img: \
Expected sizes [524288, 2097152] bytes, got actual size 62914560 bytes

Signed-off-by: Lincoln Thurlow <[email protected]>
@timg236
Copy link
Collaborator

timg236 commented Nov 11, 2025

LGTM

@timg236 timg236 merged commit 1c92bb9 into raspberrypi:master Nov 11, 2025
1 check passed
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