How-To¶
Finally suitable for experimented end users - but beware of bugs !¶
As we have a lot of work to do before we reach our goals, this website is not really suitable for end users yet - you will need a basic knowledge of Linux cross-compiling for ARM and embedded systems setup to use the information in this website towards using the latest linux Mainline kernel for supported Amlogic SoCs.
Instead, we use this website as an information archive for those developers who are working collaboratively to bring Amlogic support to the existing Linux/open-source codebases and communities.
You can find mainline Linux for Amlogic SoCs in these (non-exclusive) distributions list :
Armbian (https://www.armbian.com)
Switched to mainline Linux for all of the Amlogic SoC support images
Generic ArchLinux ARM (https://archlinuxarm.org/platforms/armv8/generic)
Uses mainline defconfig, thus enabling Amlogic SoC support, but you will need to tetup the boot yourself
Designed to run on the Odroid-N2(+)
Home Assistant OS has been optimized to run on Odroid-N2 (https://www.home-assistant.io/installation/odroid/)
Debian Testing (https://wiki.debian.org/DebianTesting)
Uses a fairly recent Linux release with most of the needed Linux config options to run on Amlogic SoCs, you will be able to use EFI boot or you will need to setup the boot yourself
openSUSE Tumbleweed (https://en.opensuse.org/HCL:LibreTech-CC)
Uses a fairly recent Linux release with most of the needed Linux config options to run on Amlogic SoCs, you will be able to use EFI boot or you will need to setup the boot yourself as described in the Wiki
Fedora Rawhide (https://fedoraproject.org/wiki/Architectures/ARM)
Uses mainline defconfig, thus enabling Amlogic SoC support, but you will need to setup the boot yourself
Yocto/OpenEmbedded meta-meson layer (https://layers.openembedded.org/layerindex/branch/master/layer/meta-meson/)
Enables linux on Amlogic SoCs, including boot support, with most of the Work-In-Progress patches
Buildroot (http://buildroot.org)
Can build a set of rootfs, kernel and bootloader using mainline projects, but you will need to setup the boot yourself (U-Boot build, FIP & flash to storage)
Some Board Vendors provide images with mainline linux :
Libre Computer images for AML-S905X-CC (http://share.loverpi.com/board/libre-computer-project/libre-computer-board-aml-s905x-cc/image)
Khadas VIM Mainline Images:
Sadly HardKernel doesn’t provide mainline based images themselves, but Armbian does.
Compile Commands¶
32-bit SoCs (Meson8b / S805 or older)¶
Download recent cross-toolchain Linaro Latest arm-linux-gnueabihf binaries
To compile the 32-bit mainline kernel:
# make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- multi_v7_defconfig
# make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- LOADADDR=0x00208000 uImage dtbs
# mkimage -A arm -O linux -C none -T kernel -a 0x00208000 -e 0x00208000 -n linux-next -d arch/arm/boot/zImage ../uImage
To boot the 32-bit kernel using the shipped U-Boot:
# mmcinfo
# fatload mmc 0:1 0x21000000 uImage
# fatload mmc 0:1 0x22000000 rootfs.cpio.uboot
# fatload mmc 0:1 0x21800000 meson8b-mxq.dtb
# setenv bootargs "console=ttyAML0,115200"
# bootm 0x21000000 0x22000000 0x21800000
64-bit SoCs (GXBB / S905 or newer)¶
Download recent cross-toolchain Linaro Latest aarch64-linux-gnu binaries
To compile the 64-bit mainline kernel:
# make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- defconfig
# make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- Image dtbs
# mkimage -A arm64 -O linux -T kernel -C none -a 0x1080000 -e 0x1080000 -n linux-next -d arch/arm64/boot/Image ../uImage
To boot the 64-bit kernel using the shipped U-Boot:
# fatload mmc 0:1 0x01080000 uImage
# fatload mmc 0:1 $dtb_mem_addr meson-gxbb-vega-s95-telos.dtb
# setenv bootargs "console=ttyAML0,115200"
# bootm 0x1080000 - $dtb_mem_addr