Rockchip RK3576 mainline support
rk3576 location on the flipper one mainboard we use the rockchip rk3576 system on chip for our main application processor, which includes cpu cores (4x arm cortex a72 and 4x arm cortex a53), gpu (arm mali g52 mc3), 6 tops npu, as well as a wide assortment of built in peripheral interfaces and controllers (storage, network, various i/o, etc ) it also includes a dedicated on chip low power mcu (cortex m0), which can be configured to control selected peripherals when the main os is not running (but there are no documented users of it yet, and we don't use it either) read the full rk3576 datasheet https //cdn flipper net/rk3576 brief datasheet v1 2 20240311 pdf and tech specs https //docs flipper net/one/general/tech specs#main cpu rk3576 why we chose rk3576 performance comparable to raspberry pi 5 energy efficiency <1w idle, around 4w under heavy load, stated tdp of 10w up to date architecture and peripheral standards ufs storage, vulkan support, built in neural engine, modern hdmi/dp display compatibility, etc existing support in upstream linux, u boot, and tf a at least at some usable level the support in upstream linux, u boot, and tf a is especially important for us, as we strive to make flipper one a mainline first device not tied to vendor bsp software what's that bsp thing about? bsp, short for board support package, is the traditional way hardware vendors provide software support for their devices in the embedded world it's usually a tightly coupled set of vendor specific packages of arbitrarily selected versions (usually outdated by years at the time of release), heavily modified by the vendor in incompatible ways, rarely (if ever) updated, and buildable only in an environment and with the tools the vendor used at the time of shipping in short, it's what a silicon vendor would give you to check all the boxes in terms of advertised hardware features, but which condemns you to using old, hastily assembled software of unknown quality, with limited realistic options to support new distros, use new peripheral hardware, etc rockchip also supports their chips by the means of a bsp, which is a multi gigabyte software download based around linux 6 1 (over 4 years old at the time of this writing), targeting debian 12 ("old stable" at the time of this writing), with a number of binary only parts (specifically, the ddr memory trainer, bl31 and bl32 bootloader stages) and rockchip specific incompatible interfaces (for video encoding/decoding, for npu, etc ) rockchip's software stack broadly comprises the following components boot rom โ pre burned into the soc itself, non updatable, runs unconditionally as soon as power is applied to the soc boost binary โ patches up some pointers in sram apparently an in field bug fix for the boot rom and initializes ufs power mode parameters ddr trainer โ configures the memory controller, sets ram frequency and timings u boot spl (heavily modified by rockchip based on an old version from 2017) โ runs early hardware initialization and loads the main system bootloader (u boot) via bl31+bl32 bl31 (binary only) โ heavily modified version of the arm trusted firmware controls cpu+gpu+npu clocks, low level power states, etc , keeps running in the highest arm exception level when the system is booted, and provides callable services for the os via the scmi interface bl32 (binary only) โ heavily modified version of the op tee controls "secure world" features, including crypto, device authentication (hardware unique keys, one time programmable hashes, and cryptographic signatures, etc ) for drm and verified boot functionality, among other things also keeps running when the system is booted and exposes "secure" scmi calls to the os and to bl31 services u boot (heavily modified by rockchip based on an old version from 2017) โ finds a linux kernel on the "main" boot device, loads it along with a dtb and initrd, and boots it linux kernel (heavily modified by rockchip based on an old 6 1 version from 2022) debian 12 userspace (or android 14) rockchip specific userspace libraries and drivers (which need rockchip patched end user software to be useful) to complicate matters further, the full bsp is only provided to hardware integrators via closed rockchip's gerrit repo, and not to end users parts of it contain code that puts limits on distribution mainline (a k a upstream) software the key alternative to bsp software (often called downstream) is the mainline linux ecosystem mainline here refers to the fresh linux kernel versions as released by linus torvalds on kernel org https //kernel org , u boot versions as released by the u boot project, etc each of the respective "original" projects is referred to as upstream upstream projects have rigorous peer review standards, with poorly written code regularly becoming the subject of colorful remarks by seasoned maintainers who serve as the ultimate gatekeepers they emphasize maintainability, compatibility across different platforms, stable user interfaces, and thorough testing this often means that getting new hardware supported upstream takes much more initial effort than cobbling together some piece of patched downstream software what mainline support brings as the upside though is substantial any distribution that ships a recent enough kernel version should work out of the box on flipper one any new hardware peripherals that have upstream drivers should work out of the box bugs are fixed regularly new software features are made available regularly mainline ecosystem aligns much better with what we want flipper one to be an open device that can be used in an unlimited number of ways with all sorts of hardware attachments and software configurations in fact, it is virtually impossible to achieve using vendor bsps furthermore, we strongly believe that open collaboration the way upstream projects work is great! current mainlining status mainline linux mostly works on rk3576, except npu, video encoding, csi camera, pcie suspend, and some niche peripherals mainline u boot fully works with a couple of in progress patches tf a (bl31) basic functions work well (clock scaling, suspend/resume) op tee (bl32) no support for rk3576 collabora has been working on mainline support for rk3588 and rk3576 for a long time, and maintains a more detailed status tracker for the support of individual hardware blocks https //gitlab collabora com/hardware enablement/rockchip 3588/notes for rockchip 3576/ /blob/main/mainline status md https //gitlab collabora com/hardware enablement/rockchip 3588/notes for rockchip 3576/ /blob/main/mainline status md how to contribute our main goal is to build a truly open hardware platform with full mainline support we invite anyone in the community who cares about this to get involved you can contribute at any level, from submitting code to advocacy with vendors read about our cpu software sub project https //docs flipper net/one/cpu software/about and how development is organized on our side take a look at the current open tasks https //docs flipper net/one/open tasks โ you may be able to help with specific issues in flipper one development explore collabora's kernel repository https //gitlab collabora com/hardware enablement/rockchip 3588/linux , where mainlining work for the rk3588 and rk3576 is ongoing
Have a question?
Our support team and an awesome community will get you an answer in a flash. Please leave your questions in English.
To ask a question or participate in discussions, you'll need to authenticate first.