[SOLVED] Problem booting from a USB pendrive

Hello,

First, congratulations and thank you Libre Computer people for such a good and affordable product (Le Potato).

In case someone is interested, I experienced problems booting from a USB pendrive. I was using a generic SD card with the bootloader installed on a Le Potato V1 board, and a very cheap but original Kingston Exodia M 64GB pendrive for the OS. I’m using Debian 12 distro from Libre Computer. Instructions for booting this way from the Libre Computer docs here.

As instructions are intended for an SSD and I’m using a pendrive, I guess, U-Boot didn’t recognize and won’t boot. However, I realized that using the console, if I ran usb reset, pendrive was then recognized (as storage) and able to boot. So, I added a small partition to the SD card (primary, offset=2048, size=4M) and created a FAT32 filesystem there. This was done in order to modify and persist preboot environment variable.

Using the U-Boot console (after partitioning and making FAT32 filesystem):
setenv preboot "run bootcmd_romusb; run bootcmd_usbdfu; sleep 1; usb start;"
saveenv

With this setup, U-Boot waits 1 second before usb start. That is all that’s needed for the pendrive to be recognized and boot seamlessly.

Now, I want to ask the Libre Computer team if this could be added to the U-Boot compilation, so there is no need to create a FAT32 partition and perform the rest of the steps.

Anyway, thank you very much. I hope this is useful for some of you. Have a great day!