uboot-rock64-2020.07 always flashes to the /dev/mmcblk0

Problems with packages? Post here, using [tags] of the package name.

uboot-rock64-2020.07 always flashes to the /dev/mmcblk0

Postby mbakhterev » Fri Aug 21, 2020 10:37 pm

The install script of the aforementioned package unconditionally flashes uboot images to the /dev/mmcblk0, which may not be the boot block device. For instance, in my case it was an encrypted SD card with some sensitive data (so i hurt myself today very painfully), and the boot device is /dev/mmcblk1. May be, it will be better not to perform install automatically, but just provide some flashing script for the user in the /boot directory.
mbakhterev
 
Posts: 22
Joined: Mon Oct 14, 2019 4:45 pm

Re: uboot-rock64-2020.07 always flashes to the /dev/mmcblk0

Postby Kabbone » Sat Aug 22, 2020 7:27 am

but it isn't automatically flashing, there should a message ask you if you want to install it to this block device (mmcblk0) and you have to confirm, if you don't it shouldn't get flashed and gives you the instructions how you can do it manually.

This is from the package install:
$this->bbcode_second_pass_code('', '
flash_uboot() {
echo "A new U-Boot version needs to be flashed onto /dev/mmcblk0."
echo "Do you want to do this now? [y|N]"
read -r shouldwe
if [[ $shouldwe =~ ^([yY][eE][sS]|[yY])$ ]]; then
dd if=/boot/rksd_loader.img of=/dev/mmcblk0 seek=64 conv=notrunc
dd if=/boot/u-boot.itb of=/dev/mmcblk0 seek=16384 conv=notrunc
else
echo "You can do this later by running:"
echo "# dd if=/boot/rksd_loader.img of=/dev/mmcblk0 seek=64 conv=notrunc"
echo "# dd if=/boot/u-boot.itb of=/dev/mmcblk0 seek=16384 conv=notrunc"
fi
}
')
Kabbone
 
Posts: 155
Joined: Thu Jul 25, 2013 9:20 am


Return to Packages

Who is online

Users browsing this forum: No registered users and 14 guests