U-Boot on SPI flash - discussion
#1
After reading about the various issues on using the SPI flash for U-Boot, it comes down to 2 things;

 - Bricking when you write a new U-Boot that does not work as expected. But does not allow recovery.
 - Writing to the SPI flash reliably

I can't speak to the second issue directly, will have to accept what others have to say.

However, I have some thoughts on fault tolerance for the SPI flash image This is what I came up with;

 - Stage 1 code to select U-Boot image, that has recovery by looking at a special SD card
 - data to select image 1 or 2
 - U-Boot image 1
 - U-Boot image 2

So, under normal conditions, we have an old, working U-Boot, (maybe lacking a feature like NVMe boot), installed in one SPI U-Boot slot. And we want to install a new, less tested image into the second slot. We then run a program to install new U-Boot image and change the boot image selection to newest.

If the new U-Boot image fails in such a way we can't work around the problems easily, we install a SD card that has a special signature our stage 1 code recognizes. If stage 1 sees this, it changes the U-Boot image selection to the other one, (aka old U-Boot image), and proceeds to boot.

We can also have stage 1 look for a second signature on the SD card. If found, boot off the SD card. That way, we have a choice.

Since this is all open source, the exact location and data of these signatures would be well known and documented.


So, that's my solution to the SPI issue where we could "brick" our Pinebook Pros.


Discussion anyone?
--
Arwen Evenstar
Princess of Rivendale


Messages In This Thread
U-Boot on SPI flash - discussion - by Arwen - 11-29-2019, 04:18 PM
RE: U-Boot on SPI flash - discussion - by Arwen - 11-29-2019, 07:45 PM
RE: U-Boot on SPI flash - discussion - by zaius - 11-30-2019, 04:07 PM
RE: U-Boot on SPI flash - discussion - by Arwen - 11-30-2019, 04:25 PM
RE: U-Boot on SPI flash - discussion - by zaius - 12-01-2019, 11:21 AM
RE: U-Boot on SPI flash - discussion - by Arwen - 12-01-2019, 11:51 AM
RE: U-Boot on SPI flash - discussion - by zaius - 12-02-2019, 06:26 AM
RE: U-Boot on SPI flash - discussion - by Arwen - 12-02-2019, 10:34 AM
RE: U-Boot on SPI flash - discussion - by xalius - 12-02-2019, 11:09 AM
RE: U-Boot on SPI flash - discussion - by zaius - 12-02-2019, 02:01 PM
RE: U-Boot on SPI flash - discussion - by xalius - 12-02-2019, 02:17 PM
RE: U-Boot on SPI flash - discussion - by pcm720 - 12-02-2019, 10:12 PM
RE: U-Boot on SPI flash - discussion - by Wizzard - 12-03-2019, 12:48 AM
RE: U-Boot on SPI flash - discussion - by Arwen - 12-03-2019, 06:11 AM
RE: U-Boot on SPI flash - discussion - by pcm720 - 12-03-2019, 06:18 AM
RE: U-Boot on SPI flash - discussion - by Wizzard - 12-03-2019, 06:25 AM
RE: U-Boot on SPI flash - discussion - by hmuller - 01-06-2020, 08:53 PM
RE: U-Boot on SPI flash - discussion - by hmuller - 09-16-2020, 08:20 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  uboot wont boot to SD card after upgrade jbradley419 7 802 01-19-2024, 02:29 PM
Last Post: wdt
  Video Flashing/adjusting on boot and reboot jbradley419 0 286 01-16-2024, 09:17 AM
Last Post: jbradley419
  Brand new Pinebook Pro doesn't boot after Manjaro update johnboiles 8 2,210 12-15-2023, 02:11 PM
Last Post: wdt
  PBP won't boot after trying to reinstall Manjaro ARM soupgirl 3 686 12-13-2023, 08:17 PM
Last Post: trillobite
  Various freezes during boot & while running several Linux distros - hardware error? donuts 1 584 11-22-2023, 11:47 AM
Last Post: fxc
  Cannot boot to Kali SD card after uboot upgrade jbradley419 4 1,171 09-19-2023, 08:48 AM
Last Post: dachalife
  Does latest Tow-Boot install/work correctly for everyone? tophneal 4 1,863 08-03-2023, 03:30 PM
Last Post: tophneal
  Boot into NVME drive, no wifi, sound, buttons... PaulQ 0 795 07-13-2023, 01:50 PM
Last Post: PaulQ
  New Pinebook pro won’t boot Generaltuxenburg 4 1,924 06-14-2023, 07:20 AM
Last Post: KC9UDX
Tongue Yet another Pinebook Pro won't boot thread pinemouth 4 2,426 05-20-2023, 01:02 AM
Last Post: jackwilson

Forum Jump:


Users browsing this thread: 2 Guest(s)