Re: FreeBSD13.0 on Pine ROCK64

roboman <[email protected]>
Newsgroups gmane.os.freebsd.devel.arm
Message-ID <[email protected]>
Petru,

	I have 4 Rock64 devices.  I'm just using sdcards instead of
eMMC (FYI).  I followed a similar path to yours below.  I "burned" an
image for device #1.  It didn't boot immediately.  There is a lot of
online documentation on creating a serial console to view the boot
output; but they all require more than what I had available at my house
(custom USB cables, messing with wires, etc.).  At the time, I was
accustomed to single board computers outputing to HDMI during boot but
came to realize from my research that the Rock64 devices do not output
to HDMI until/unless the kernel boots 3/4 of the way.  

  I followed some documentation to flash the U-boot code to the SPI
flash.  U-boot appears to be similar to Linux "Grub" and the SPI is
similar to an old fashioned BIOS.  After messing with it several times,
it worked on device#1.  I flashed the SPI and the FreeBSD 13 boot image
worked fine.  I used the same 'dd' command you did below.  What you did
is correct.

	Then I moved on to Rock64 device #2.  On this device I tried
burning an SDCard just like the 1st device.  Wouldn't boot.... no
surprise... I didn't "flash" the SPI yet; but I wanted to test it 1st. 
I then proceeded to 'flash' the SPI with U-boot....  still didn't boot.
At this point I switched sdcards between working device #1 and device
#2.  Still didn't work.  I switched the sdcards back to their original
device and verified device #1 booted fine with either microSD card. I
assumed it MUST be that SPI, so I proceeded to "factory wipe" and
reload the FreeBSD-13 'friendly' U-boot code.  no luck.  I moved device
#2 to a troubleshooting bench of my basement which happened to have a
older 100 MB switch instead of a 1 GB switch.  To my surprise, the
device started pinging on the network!!!!

Here's where I accidentally found something weird!!!

	Turns-out, some (not all) of these Rock64s will not connect to
a 1 gig switch port.  If I hard-code my primary switch port to 100 MB,
the Rock64 booted to the network no problem.  If I switch the switch
port back to "auto" [10/100/1000], it won't connect.

	I proceeded to "U-boot" flash the SPI of the other two devices
(3 &4) and create sdcards for all of them.

My result:
Device 1	works perfectly
Device 2	only works 100 MB
Device 3	only works 100 MB
Device 4	only works 100 MB

I reloaded devices 2-4 w/Armbian and they all work fine at 1 GB.  It
appears to be a FreeBSD NIC driver-related issue.  I posted details on
this forum and didn't get any solutions.  I ended up moving to Armbian
for all 4 devices due to this problem being unresolved.

Recommend: Test on a 100 MB switch port and see if you are having the
same problem.  If yes, see attached response I received from a fellow
FreeBSD-ARM member.
-Jeff

On Mon, 2021-12-27 at 22:40 -0500, petru garstea wrote:
> Greetings,
> 
> Hope all is well.
> 
> I burned on emmc drive a FBSD13 version for pine rock64 SOC however
> the 
> system doesn't boot.
> 
> The command I used
> 
> dd if=FreeBSD-13.0-RELEASE-arm64-aarch64-ROCK64.img of=/dev/da0
> bs=1m 
> conv=sync status=progress
> 
> Then I validate the partition tables
> 
> gpart show
> =>     40  6291376  da0  GPT  (29G) [CORRUPT]
>         40    32728       - free -  (16M)
>      32768   102400    1  efi  (50M)
>     135168  6156160    2  freebsd-ufs  (2.9G)
>    6291328       88       - free -  (44K)
> 
> 
> I tried to boot as is but no luck, then since the GPT is corrupted I
> ran
> 
> gpt recover da0
> 
> But the result is the same, the system doesnt boot.
> 
> 
> I tested an armbian image and that worked well.
> 
> 
> Please advise.
> 
> 
> Cheers,
> 
> Petru
> 
>
(unnamed) (message/rfc822, 5.5 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.