U-Boot on SPI flash - discussion
#13
While it's not something you're really after, after a lot of frustration and head-scratching I was able to build a working SPI flash image for my fork of U-Boot:

[Image: nz86P8H.png]

I ended up using Rockchip's firmwareMerger with the following config to build the image:
Code:
[System] FwVersion=19.12.03 BLANK_GAP=1 FILL_BYTE=0 [UserPart1] Name=IDBlock Flag=0 Type=2 File=rkbin/bin/rk33/rk3399_ddr_933MHz_v1.24.bin,rkbin/bin/rk33/rk3399_miniloader_spinor_v1.14.bin PartOffset=0x40 PartSize=0x7C0 [UserPart2] Name=uboot Type=0x20 Flag=0 File=u-boot.img PartOffset=0x4000 PartSize=0x2000 [UserPart3] Name=trust Type=0x10 Flag=0 File=out/sd/trust.img PartOffset=0x6000 PartSize=0x2000

For some reason, firmwareMerger from Rockchip repository doesn't work properly, so I had to use the version from Radxa's repository to get proper image.
It should also be possible to use U-Boot TPL and SPL instead of Rockchip blobs, but haven't found any concrete answer on how to build the image using these. Documentation just isn't clear enough, and recovery process is too cumbersome and annoying.

dd is good enough for flashing the image to the SPI. Just make sure to use flash_erase beforehand.
In case something goes wrong and PBP gets stuck somewhere in early boot, the easiest recovery method I found is taking off the metal shield and shorting SPI clock to ground until ARM Trusted Firmware (BL31) initialization. After Linux boots, you can just use dd or flash_erase to reflash/erase the chip.

Overall, it works fine on my device, so there's no more eMMC in my Pinebook Pro Smile
You can find the image here. The build scripts for everything are here.


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
Sad What to can't boot from TF card, EMMC system broken - any advice?do guys? qingss0 1 2,509 12-18-2025, 01:05 AM
Last Post: qingss0
  Bonk to boot biketool 2 3,213 10-21-2025, 09:08 AM
Last Post: biketool
  3 days in, slow/stuck or no boot. lgmpbp2 34 34,255 06-11-2025, 08:53 AM
Last Post: lgmpbp2
  upgrading u-boot--what version? where to get it? bsammon 14 21,109 04-03-2025, 07:47 AM
Last Post: Tazdevl
Tongue Yet another Pinebook Pro won't boot thread pinemouth 5 13,120 12-27-2024, 11:38 AM
Last Post: akash3995
  broken tow-boot hashkeeper 1 4,694 12-25-2024, 10:12 PM
Last Post: jessipinkman
  Cant boot into an OS trashtendenz 3 6,096 10-23-2024, 03:49 AM
Last Post: chaylengordon
  Unable to boot? YossiS 4 4,822 09-04-2024, 10:35 AM
Last Post: wdt
  uboot wont boot to SD card after upgrade jbradley419 7 9,927 01-19-2024, 02:29 PM
Last Post: wdt
  Video Flashing/adjusting on boot and reboot jbradley419 0 3,015 01-16-2024, 09:17 AM
Last Post: jbradley419

Forum Jump:


Users browsing this thread: 1 Guest(s)