[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: cannot boot from microSD card on aarch64 machine

From: Ricardo Wurmus
Subject: Re: cannot boot from microSD card on aarch64 machine
Date: Tue, 29 Mar 2022 23:45:54 +0200
User-agent: mu4e 1.6.10; emacs 28.0.50

Hi Vagrant,

> On 2022-03-02, Ricardo Wurmus wrote:
>> I got myself a rockpro64 board.
> ...
>> So I then decided to build my own system and install a new u-boot onto
>> the microSD card.  Here’s the system I built:
> ...
>>   (bootloader (bootloader-configuration
>>                (bootloader u-boot-rockpro64-rk3399-bootloader)
>>                ;; SD card/eMMC (SD priority) storage
>>                (target "/dev/mmcblk1")))
> You need to leave a pretty generous gap at the partition table of your
> microSD, either a GPT partition table with various partitions for the
> various u-boot bits:
> or an MBR partition table with the first partition starting at sector
> 32768, and the previous sectors empty.
> Otherwise, the u-boot installation may clobber parts of your partition
> table or vice-versa.

Thank you, this was interesting.

I still don’t quite understand how the partition layout relates to what
Guix does when it writes the files to the offsets.  I tried building
this exact partition table (the default settings of partitioning tools
force some other sector alignment, which makes this impossible without
overriding alignment settings in expert mode) and then used dd to write
the u-boot files to the partitions, but I wasn’t successful as the
microsd card seemed not to work at all.

Using dd to copy the two files to the expected offsets did let me into
u-boot and allowed me to boot from USB.  I haven’t yet tried putting the
system on a partition on the microsd card, because I’m still confused
about how I should build the partition table.

> Also, if you have a different u-boot installed to SPI or eMMC, those
> will take priority over microSD on most rockchip platforms.

Good to know.  No u-boot has been installed to SPI yet.

>> Does it perhaps install the u-boot files at the wrong offsets?  How
>> would I begin to debug this?
> It is also entirely possible something is wrong with rockpro64 u-boot
> offsets or u-boot itself ... been a while since I've tested.

When I used the same offsets with dd it works fine.  So I’m clearly
missing some information about how to prepare the microsd card.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]