Home > AMLogic, Android, Linux, Testing > Amlogic Releases Linux 3.14 Source Code for S905X, S905D, and S912 Processors, Has Started Working on Linux 4.4 / Android 7.0

Amlogic Releases Linux 3.14 Source Code for S905X, S905D, and S912 Processors, Has Started Working on Linux 4.4 / Android 7.0

Amlogic has just released buildroot with Linux 3.14 with support for Amlogic S905X (p212 board), S905D (p230 board), and S912 (Q200 board) processors, and the company appears to have started working on Linux 4.4 likely for future support for Android 7.0.

Amlogic_S912_Linux_BuildrootYou can check the source code as follows:

If you have the wrong toolchain the code won’t build (See comments section). So I installed several toolchains provided by Amlogic (all may not be needed) in /opt:

I also downloaded a shell script to add the toolchains to my path:

Once toolchains are setup, you can select one of three boards config (Q200 / S912 as example) and start building the code:

If you are interested in S905X or S905D instead, use respectively mesongxl_p212_release_defconfig or mesongxl_p230_release_defconfig.

I built both S912:

and S905X images successfully:

Separately, you can also find buildroot for Linux 4.4, but this is very likely very early work, and should be used together with Amlogic Android 7.0 SDK once it is released.

  1. Theguyuk
    August 19th, 2016 at 18:46 | #1

    Have they done anything to encourage Android updates for the S802, S805 S812 socs?

    It is also a shame they don’t use the 8 core GPU in their S905 line.

  2. abc
    August 19th, 2016 at 18:56 | #2

    They newer learn 🙁

    Dumping tarball with the code is NOT THE WAY to do it.

    The proper way is working with kernel.org community to upstream all the changes. So what is needed is a series of patches send to [email protected] mailing list that add all missing support.

    In few months that 3.X or 4.X code dump will be old, with security holes and basically unusable for serious worketc. Upstreaming changes and maintaining these upstream is the only working way.

  3. Ron
    August 19th, 2016 at 19:03 | #3

    When will AMLogic devices fully support the stock Kodi without modifications?

  4. rebeL
    August 19th, 2016 at 19:08 | #4

    Great! So some S905D linux sat-tv-mini-pc will come true, perhaps with android 7 (N)

  5. Theguyuk
    August 19th, 2016 at 19:22 | #5

    I use Kodi from the Android store on my miniM8s S905 ( I replaced the installed Kodi my TV box came with )

    I just watch online content like Filmon as Kodi buffers video better on my real garbage broadband speed, 1.2 mb is a good day!

    So I am curious what are the Kodi problems you refer to?

    I do find some content needs MX player and stock media player when playing high end samples.

  6. Massimo
    August 19th, 2016 at 19:41 | #6

    HD audio and auto-switch fps work??? I don’t think.
    Without this function kodi is only 40% used.

  7. Ron
    August 19th, 2016 at 19:42 | #7

    Apart from what Massimo wrote, this also concerns the video decoding.

    From what I know, this phenomena plagues most, if not all, Android TV boxes because of what SoC producers like Rockchip, AMLogic, Realtec (and all the rest) do – the way they act. I think that only nVidia is the only outstanding one in this matter.

    But there are other people here which could explain this issue much better than me, as my understanding of it is quite limited due to its technicality…

  8. Massimo
    August 19th, 2016 at 19:46 | #8

    Kodi use mediacodec (omx layer ) ,without it is impossible playback smooth any content.
    Without mediacodec support kodi is used at 0%.
    Amlogic codec are no more suport from kodi 16.

  9. Roel
    August 19th, 2016 at 19:48 | #9

    I thought hardkernel en amlogic where working together to mainline the 905 soc?

  10. August 20th, 2016 at 10:09 | #10

    A lot of effort has been done from crew at http://linux-meson.com/ in bringing Amlogic SoC support to mainline kernel and U-Boot.

    Mainline kernel repository:

  11. nobe
    August 20th, 2016 at 12:05 | #11

    here is the exact statement from hardkernel in march : http://forum.odroid.com/viewtopic.php?p=127189#p127189

    at that time they considered either going mainline or using a 4.4 fork
    since then, we have no information about their plan
    some community members asked them in forum here and there but never get any answer, which i guess can be interpreted as no mainline :p

  12. Billionaire Rich Man Trump
    August 20th, 2016 at 15:59 | #12

    Stane1983’s news is the best yet. Until they get the video stuff worked out, these boxes make terrific headless servers.

  13. August 20th, 2016 at 16:35 | #13

    @Billionaire Rich Man Trump
    I tried booting headless mainline 2 months ago I think, worked just fine Except there were missing some basic drivers (MMC eg).

  14. mdel
    August 20th, 2016 at 17:05 | #14

    Ron :
    When will AMLogic devices fully support the stock Kodi without modifications?

    Well open source allows Kodi project not be the only one to provide a Kodi version, so you can turn to Libreelec to get Kodi for amlogic devices.
    In fact their latest LE 8 alpha (Kodi Krypton), offers support for various amlogic chips and a bunch of patches already fix various kodi problems on amlogic in a stable LE 7 (kodi 16), like dynamic framerate or HD audio passthrough (s905 only i believe).

    So while amlogic still offers a very minimal linux support that definitely won’t help their cause, it will only delay the production of stable linux systems for those devices, as long as the community considers this hardware to be relevant of course.

  15. August 20th, 2016 at 17:07 | #15

    I think he was thinking about Android support which is correct. amlcodec as part of Kodi is in source for use in linux solutions.

  16. Theguyuk
    August 20th, 2016 at 19:05 | #16

    It is a shame all parties can not find common ground to work together, I would guess more Linux support would grow new markets for Amlogic?

    People should talk to Amlogic


  17. mdel
    August 20th, 2016 at 19:19 | #17

    okay yeah i never really think about android.

    Well you can always dual boot, and the good thing with those powerful socs, is that they boot very fast.
    My s905 nexbox A95x (cold) boots android from the emmc in something like 20 seconds and LE from the sdcard in about 25sec.

    Also it’s not been mentioned here but will the new Wetek Play 2 s905H bring something new to the table, kodi or linux wise ?
    Although only Android 5.1 is listed on their specs sheet at the moment, i’ve not browsed their forums to see if a linux OS has been rumored.

    Or should i understand the s905H is not part of the source release ?

  18. August 22nd, 2016 at 16:28 | #18

    After multiple attempts, and installed a Linaro toolchain for U-boot:

    It failed to build with the errors:

    and further below

    I’ve modified ./scp_remote.c, and it can carry on with the build, but further fails with:

  19. August 23rd, 2016 at 07:20 | #19

    Which U-Boot you tried to compile and which defconfig?

  20. August 23rd, 2016 at 09:18 | #20

    The one in arm-buildroot-2016-08-18-5aaca1b35f.tar.gz using mesongxm_q200_release_defconfig.
    Inside output/build/uboot-custom/Makefile it shows:

  21. August 23rd, 2016 at 09:32 | #21

    That is gxm_q200_v1_defconfig uboot defconfig. Try to build only that. If not working, use toolchains from http://openlinux.amlogic.com:8000/deploy/ (you also need arc-4.8 to build uboot).

    Here is my result:

    Creating “../fip/gxl/fip.bin”
    Firmware Image Package ToC:
    – SCP Firmware BL3-0: offset=0x4000, size=0xD400
    – EL3 Runtime Firmware BL3-1: offset=0x14000, size=0x140D0
    – Non-Trusted Firmware BL3-3: offset=0x2C000, size=0xA72E8
    ACS tool process done.
    11840+0 records in
    11840+0 records out
    11840 bytes (12 kB, 12 KiB) copied, 0.0128791 s, 919 kB/s
    5825+0 records in
    5825+0 records out
    5825 bytes (5.8 kB, 5.7 KiB) copied, 0.00590936 s, 986 kB/s
    ../fip/gxl/u-boot.bin build done!

  22. August 30th, 2016 at 13:41 | #22

    Toolchain issue. Removing gcc-arm-none-eabi fixed the issue:

    It failed in that BL3x thing that messes up with CPU freqs by the way… Evil thing that is 😉

  23. gary
    September 17th, 2016 at 19:03 | #23

    SSP support not available in this toolchain, please disable BR2_TOOLCHAIN_EXTERNAL_HAS_SSP
    package/pkg-generic.mk:185: recipe for target ‘/home/ub/alinux/buildroot/output/build/toolchain-external-undefined/.stamp_configured’ failed
    make[1]: *** [/home/ub/alinux/buildroot/output/build/toolchain-external-undefined/.stamp_configured] Error 1
    Makefile:36: recipe for target ‘_all’ failed

    I’ve got this error after make
    Do you have any advice?

  24. alopezinkt
    December 6th, 2016 at 19:30 | #24

    Thanks for these instructions, I followed them and succesfuly built kernel, rootfs and u-boot. However I can’t find instructions to burn the resulting files to a working SD card. Amlogic instructions on their pdf seem to be wrong or incomplete. I have a S912 device.

    I’ve looked at what libreelec and armbian do and this is what I did:
    * Enable SD boot with balbes method form armbian
    * create a bootable SD from libreelec for s905
    * Kernel: create a fat partition and copy boot.img from buildroot renamed as kernel.img
    * DTB copy gxl_p230_2g.dtb from buildroot to fat partition renamed as dtb.img
    * expand second partition on SD card to full size and untar rootfs.tar from buildroot

    With this, I can see on the serial port, that I can boot my kernel, many devices are detected and configured correctly. But at some point it gets stuck with this message:
    /dev/cardblksd1 is not ready. Waited for 30 second
    Failed to switch root, dropping to a shell
    [ [email protected]] meson_uart c81004c0.serial: ttyS0 use xtal(8M) 24000000 change 115200 to 115200
    mount: mounting proc on /proc failed: Device or resource busy

    I’m sure I’m mixing u-boot, kernel, dtb configurations, but without any other instructions this is as far as I got. I think it should be able to boot as I got the libreelec booting correctly (usb and ethernet working) to command line (no kodi as expected because of lack of linux support for the S912 gpu).

    By the way, there is a new version of the buildroot on amlogic site , which I compiled correctly following these instruactions.

    Thanks in advance,

  25. gnthibault
    March 29th, 2017 at 05:55 | #25

    Any news about those topic ? I just bought my h96 pro+ and I am willing to transform it into a headless server.

  26. March 29th, 2017 at 09:26 | #26

    If you’re going to use your TV box as a headless server, better use Linux mainline than Amlogic release: http://www.cnx-software.com/2017/03/06/mainline-linux-on-64-bit-arm-amlogic-socs-and-tv-boxes-such-as-wetek-hub-player-2-nexbox-a1-a95x-etc/

  1. No trackbacks yet.