RockChip ARM SoCs

Introduction

The following SoCs are supported in 13 and -CURRENT:

Support is still under development so some features (video for example) might not work as intended and drivers might be missing however for "general" usage there shouldn't be any major issues at this point.

Images can be found here (13.0 and 14-CURRENT): http://ftp.freebsd.org/pub/FreeBSD/releases/ISO-IMAGES/13.0/ http://ftp.freebsd.org/pub/FreeBSD/snapshots/ISO-IMAGES/14.0/
Not all supported boards have a dedicated image generated, in most cases it is sufficient to overwrite u-boot with the correct one.
At this stage mainline u-boot support is a requirement, you might be able to use vendor u-boot but no support is guaranteed.

Planned support/in development

Early development stages, please use the (freebsd-)arm mailinst list and/or join #bsdmips on EFNet if interested. Primary target is Quartz64 Model A by PINE64.

SBCs / Boards

FriendlyELEC

NanoPC-T4

NanoPi R4S

Radxa

Rock Pi 4(a)

PINE64

Pinebook Pro

Rock64

RockPro64

FreeBSD Prebuilt Images

The image names are of the general form <FreeBSD-<identification>-arm64-aarch64-PINE64<datestamp>.img.xz.

Examples of <identification>:

You can download the most recent image for -CURRENT here

Please keep in mind that images based on -CURRENT have debugging enabled by default which will affect performance, see https://cgit.freebsd.org/src/tree/UPDATING for more information.
If you want to compile your own image (including instructions on how to disable debugging) you can use this tutorial

Serial / UART

Defaults to 1.5Mbaud which not all adapters may support, see USB/Peripherals/Serial for more information

Optimization for SoCs

Best matching setting for CPUTYPE in /etc/make.conf

Known issues

There are stability issues using more than one CPU cluster simultaneously due to kernel related bug(s).
Reference: https://svnweb.freebsd.org/base?view=revision&revision=360321
Help is wanted regarding this bug, please use arm mailinglist if interested.
As of r367268 testing is wanted.

Removed as of https://cgit.freebsd.org/src/commit/?id=183d6cc0e0db8bd4653245abc1ca30b34ed09d9f in main branch

dwmmc might stop working during certain operations (fsck is known to be broken)
Proposed patch: https://github.com/strejda/freebsd/commit/34116751f057524338e9b2fe9ea75ccb8070c7e7.patch

Fixed as of https://cgit.freebsd.org/src/commit/?id=8727c174b0fe44766bb7ea765dac6d5f82818103 in main branch
There are reports of an additional bug that triggers a panic using fsck on dwmmc devices, it's being looked into.
Proposed patch: https://reviews.freebsd.org/D30387

Fixed as of https://cgit.freebsd.org/src/commit/?id=dfb7360222856e7e4f5e0e5564281a25af63319c in main branch

PCIe card compatibility
Due to hardware limitations of the SoC some PCIe cards may not work such as ones using bifurcation.
Reference: https://www.freebsd.org/news/status/report-2019-10-2019-12.html#RockChip-Support

No HDMI output, you can use UART (serial) to obtain output using a baud rate of 1.5M which not all adapters may support. Expected support is to arrive in uboot-2020.07.
Reference: https://github.com/u-boot/u-boot/commit/1266ef105f671b41b7e3e77bf68c7564e355995e

As of 13-BETA1, HDMI is tested as working well on a RockPro64, both on console and X, on non-standard resolutions. (uboot-2020.10)
HDMI to VGA-adapters may not work (HAMA 54569 doesn't)
MarkLinimon notes no HDMI output on Rock64 13.0-RELEASE as of 20210603.

4K monitors will make boot halt due to framebuffer size
Reference: https://lists.freebsd.org/pipermail/freebsd-arm/2021-January/023078.html

Currently the kernel doesn't support running clusters (big.LITTLE) at different speeds, doing so will result in (silent) crashes.
Running powerd will change frequency on demand and keep both clusters in sync.

GPIO is broken on RK3399
Reference: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=269993

Fan Control on RockPro64

To control the fan you can install sysutils/fand. The full set of options can be found at fand(8), but the following rc.conf configuration seems to work well for the RockPro64:

fand_enable="YES"
fand_sensor="hw.temperature.CPU"
fand_device="pwmc1.0"
fand_temp="55"
fand_off_temp="35"
fand_period="50000"
fand_duty="25000"
fand_kelvin="YES"
fand_multiplier="0.1"
fand_flags="-T 70 -P 0 -D 0"

Alternatively, use the pwm(8) command.

Set video output as primary console

While this isn't specific to any SoC it can be a bit hard to find relevant information about this settings.
Change boot_serial="YES" to NO in /boot/loader.conf

Tested PCIe devices on RockPro64

Category

Brand - Model

Status

Branch + version hash

Additional Notes

Network adapter (Ethernet, Single port)

IBM NetXtreme II 1000 Express Adapter (FRU 39Y6070)

{X}

stable/13 - n245283-70a2e9a3d44

Doesn't get detected, BCM5708 controller

Network adapter (Ethernet, Single port)

Intel Gigabit CT Desktop Adapter

{X}

main/14 - n253065-8dc42f98047

Doesn't get detected, 82574L controller

Network adapter (Ethernet, Dual port)

Fujitsu D3035-A11

(./)

stable/13 - n245283-70a2e9a3d44

Intel I350-T2 variant, I350-AM2 controller [1]

Network adapter (Ethernet, Dual port)

Supermicro AOC-PG-I2+

(./)

releng/13.1-n250141-2e9ad6042be

Intel 82576EB controller

Network adapter (Ethernet, Dual port)

Supermicro AOC-SG-I2

{X}

releng/13.1-n250141-2e9ad6042be

Freezes during boot, Intel 82575EB controller

Network adapter (Ethernet, Quad port)

Fujitsu D2745-A11

(./)

stable/13 - n245283-70a2e9a3d44

Intel I340-T4 variant, 82580 controller

Network adapter (WiFi, 802.11ac)

Intel Dual Band Wireless-AC 8260 (M.2)

(./)

main/14 - n250752-756bb50b6a8

PCIe 1x adapter, only 11g works due to driver limitations

Storage adapter (SATA, 2-port)

Micro Connect MC-SATA3-T4

(./)

stable/13 - n245283-70a2e9a3d44

Sold under different names, ASM1061 controller

Storage adapter (SATA, 2-port)

SSU SU-SA3011

(./)

main/14 - c257339-g07564e176201

ASM1061 controller, unreliable at SATA-3 speed

Storage adapter (SATA, 6-port)

SilverStone ECS06

(./)

stable/13 - n247814-f9f5d846b72

ASM1166 controller, enumerates 32-ports (PR 259705)

Storage adapter (SATA, 6-port)

Startech 6P6G-PCIE-SATA

(./)

releng/13.1-n250141-2e9ad6042be

ASM1166 controller, enumerates 32-ports (PR 259705)

Storage adapter (SATA, 8-port)

SSU (Shenzen Suyou Technology Co) (SU_)SA3008

{X}

stable/13 - n245283-70a2e9a3d44

Sold under different names, 4xASM1061 controllers, Bifurcation

Storage adapter (SAS/SATA, 8-port)

Avago Technologies (LSI) SAS2008

{X}

main/14 - c257339-g07564e176201

Doesn't get detected. mps(4) device

Notes:
1. Disabling LSO, TSO and VLANHWTSO stops NIC from flapping (link status up/down) occasionally
This table is by no means complete

On RockPro64 PCIe training can sometimes be a bit sensitive which can lead to cards/devices not being detected, this is not common but can be troublesome. Below is a (hacky) script which reboots the device if a network device (igb0 in this case) is missing which you can put in a @reboot entry in crontab:

   1 #!/bin/sh
   2 # PCIe init can be a bit iffy, reboot device until igb0 shows up
   3 sleep 120
   4 ifconfig -l | grep -q igb0 || shutdown -r now

arm/RockChip (last edited 2024-04-04T07:22:04+0000 by MarkLinimon)