FreeBSD for Edge / Edge-V

FreeBSD for Khadas Edge SBCs

Thankful appreciation to the efforts of @hyphop and @SleepWalker, who spent the last few weeks making FreeBSD compatible with the Edge and Edge-V!



  • Edge / Edge-V with at least 4GB of RAM
  • 8GB of larger micro SD card




An example of downloading and writing the image to an SD card.

cd /tmp
gzip -dc EDGE-FreeBSD-20191022-2342.img.gz | sudo dd bs=1M of=/dev/YOUR_SD_CARD_DEVICE

NOTE: Erase internal emmc before booting from the SD card!


  • FreeBSD 13.0-CURRENT
  • mainline uboot U-Boot TPL 2019.10-rc3
  • bootup from SD
  • eth OK
  • uart OK
  • emmc OK
  • sd OK
  • USB 2.0 OK


  • USB 3.0
  • HDMI
  • DRM
  • NVme m2
  • boot from eMMC


FreeBSD is a free and open-source Unix-like operating system descended from the Berkeley Software Distribution (BSD), which was based on Research Unix. The first version of FreeBSD was released in 1993. In 2005, FreeBSD was the most popular open-source BSD operating system, accounting for more than three-quarters of all installed BSD systems.

FreeBSD has similarities with Linux, with two major differences in scope and licensing: FreeBSD maintains a complete system, i.e. the project delivers a kernel, device drivers, userland utilities, and documentation, as opposed to Linux only delivering a kernel and drivers, and relying on third-parties for system software; and FreeBSD source code is generally released under a permissive BSD license, as opposed to the copyleft GPL used by Linux.

The FreeBSD project includes a security team overseeing all software shipped in the base distribution. A wide range of additional third-party applications may be installed using the pkg package management system or FreeBSD Ports, or by compiling source code.

Due to its licensing, much of FreeBSD’s codebase has become an integral part of other operating systems, such as Apple’s Darwin (the basis for macOS, iOS, watchOS, and tvOS), FreeNAS (an open-source NAS/SAN operating system), and the system software for Sony’s PlayStation 3 and PlayStation 4.



The original thread is over here: BSD for Khadas EDGE (RK3399)
Russian version: Поддержка русскоязычных пользователей

1 Like

Bravo Khadas community!! You are the first RK3399 board running FreeBSD although USB 3.0 and PCIE need to be done in order to do more useful work.
kudos to @SleepWalker 's continues effort to make the freebsd port work. This should be the headline for Freebsd community too and may be list on their coming 12.1 (November 1) release note to celebrate


This is good news @SleepWalker great work and effort.

1 Like

CHANGES: from @SleepWalker

  • usb 3.0 - fixed - OK (usb 3.0 card reader tested - works fine )



@hyphop thanks for the heads up. The SPI driver should works too, I think the next thing is NVMe driver

but not work yet :wink: may be on next build

1 Like

Any progress on the NVMe support? I have an EDGE-V Basic w/M2X expansion board & NVMe and am willing to help test. Would love to get FreeBSD up and running on this platform. Thank you for all the effort so far, great work.

1 Like

plz ask @SleepWalker! i think he have some news !!!


Hi All.

The latest FreeBSD 13.0-RELEASE install images for many SBCs,
and of course for Khadas-EDGE you can download from my site.

Unlike standard FreeBSD images,
they are based on a custom U-boot and allow you to start the system directly from
USB, NVMe or eMMC.

USB keyboard and mouse, HDMI-VIDEO and HDMI-AUDIO are working correctly in the system.

To boot from sd card, you must first clean eMMC, for example,
the dd command on Linux or from U-boot
boot# mmc erase 0 0x1000

If eMMC is empty, you will successfully boot from the SD card.

Please report successful installations or noticed bugs.
I need feedback.

I wish you success.


Very cool, I’ll check that out.

Is it possible to boot from NVMe?

System start possible from CD card, USB, NVMe or eMMC.

The boot order is determined by the value of the U-boot environment variable - boot_targets

The U-boot can be accessed by pressing the spacebar when the FreeBSD logo appears on the display screen.

Oh ok. How do you access the serial terminal? Or should it come up with DHCP? I didn’t realize HDMI was still on the TODO list and can’t tell if it’s booting. :slight_smile: I do see link on the ethernet…

1Gbit Ehternet works fine, dhcp is enabled by default.
Login is possible through the console (root without password).

Via ssh login is possible by
user: admin
with password: admin

Please test the work Ethernet at 100Mbit.


i put this image there

INFO: from @SleepWalker

While trying to find the cause of the unstable operation of USB and PCIE.

A thermal sensor driver has been added to the system and now the processor frequency decreases automatically when the load is high and the temperature rises.

The main players got their PINEBOOK PRO on RK3399 and now the debugging system will move faster. We expect drm driver to write from @manu, I hope a video appears, all my fixes are in the source tree and FreeBSD can be built for khadas just from mainline.

1 Like

Today I’m testing the img provide by @SleepWalker. The NVME drive on PCIE does crash randomly, but the SATA to PCIE card(based on Marvell 9235) working perfectly on 2 disk mirror zfs setup for 2 hour intensive writing test. So I assume the PCIE driver is working, the problem is the NVME part.

I’m going to buy another 2 hard drive to test 4 disks raidz1 zfs setup and report the NVME bug to FreeBSD

Just to check, to use this image, I write it to a microSD card and it will boot? Is there anything else I have to do? I’m not seeing any DHCP requests and don’t currently have access to a serial cable (I ordered one though!). I might try taking off the M2X board to see if that’s causing it to not boot or something.

Edit: no difference without the M2X board.

My another 2 Hard drive has arrived today, so I have 4 350G 3.5 inch drive for zfs benchmark. Here’s the results using iozone:

4 Stripe:

2 * 2 Mirrors

4 disk raidz1

The read result is good, but the write throughput in raidz setup hasn’t been doubled as it should.

More updates:
with @mmel’s RK808 regulator’s driver updates, the heat dissipation of RK3399 is vastly improved, only a passive heatsink required for a touchable temperature.

The NVME drive however has some problem, I’ve submit a Bug report

With a stable NVME drive RK3399 will be a powerful FreeBSD developing platform

1 Like