Archive

Posts Tagged ‘kernel’

Open Source Code Released for Hisilicon Kirin 960 Based Huawei Mate 9 and Huawei P10 Smartphones

June 7th, 2017 4 comments

Manufacturers of products using open source software are normally required to release the source code with their modifications to follow licenses such as the GPL, but not all comply with the license. Huawei has now released the source code with Linux and other open source libraries and programs for their Huawei Mate 9 / Mate 9 Pro and Huawei P10 / P10 Plus models powered by Hisilicon Kirin 960 processor.

With the release of Hikey 960 development board most of the source code for Kirin 960 should already be available, but it’s possible some drivers/modules specific to Huawei phones may be found instead of in the Huawei release.  You’ll find the download in Huawei’s open source page for:

I picked up the LON-NG_EMUI5.0_opensource.tar.gz tarball for Mate 9 Pro (442 MB), and it comes with three directories: external with various open source programs and libraries,  kernel with Linux 4.1.18, and vendor with ffmpeg.

The build instructions for the Linux kernel are also included in the tarball:

################################################################################

1. How to Build
– get Toolchain from android git server, codesourcery and etc ..
– aarch64-linux-android-4.9

– edit Makefile
edit CROSS_COMPILE to right toolchain path(You downloaded).
Ex)   export PATH=$PATH:$(android platform directory you download)/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin
Ex)   export CROSS_COMPILE=aarch64-linux-android-

$ mkdir ../out
$ make ARCH=arm64 O=../out merge_hi3660_defconfig
$ make ARCH=arm64 O=../out -j8

2. Output files
– Kernel : out/arch/arm64/boot/Image.gz
– module : out/drivers/*/*.ko

3. How to Clean
$ make ARCH=arm64 distclean
$ rm -rf out
################################################################################

Via XDA Developers

Linux 4.11 Release – Main Changes, ARM & MIPS Architecture

May 1st, 2017 9 comments

Linus Torvalds has just released Linux 4.11:

So after that extra week with an rc8, things were pretty calm, and I’m much happier releasing a final 4.11 now.

We still had various smaller fixes the last week, but nothing that made me go “hmm..”. Shortlog appended for people who want to peruse the details, but it’s a mix all over, with about half being drivers (networking dominates, but some sound fixlets too), with the rest being some arch updates, generic networking, and filesystem (nfs[d]) fixes. But it’s all really small, which is what I like to see the last week of the release cycle.

And with this, the merge window is obviously open. I already have two pull request for 4.12 in my inbox, I expect that overnight I’ll get a lot more.

Linux 4.10 added Virtual GPU support, perf c2c’ tool, improved writeback management, a faster initial WiFi connection (802.11ai), and more.

Some notable changes for Linux 4.11 include:

  • Pluggable IO schedulers framework in the multiqueue block layer – The Linux block layer is know to have different IO schedulers (deadline, cfq, noop, etc). In Linux 3.13, the block layer added a new multiqueue design that performs better with modern hardware (eg. SSD, NVM). However, this new multiqueue design didn’t include support for pluggable IO schedulers. This release solves that problem with the merge of a multiqueue-ready IO scheduling framework. A port of the deadline scheduler has also been added (more IO schedulers will be added in the future)
  • Support for OPAL drives – The Opal Storage Specification is a set of specifications for features of data storage devices that enhance their security. For example, it defines a way of encrypting the stored data so that an unauthorized person who gains possession of the device cannot see the data. This release adds Linux support for Opal nvme enabled controllers. It enables users to setup/unlock/lock locking ranges for SED devices using the Opal protocol.
  • Support for the SMC-R protocol (RFC7609) – This release includes the initial part of the implementation of the “Shared Memory Communications-RDMA” (SMC-R) protocol as defined in RFC7609. SMC-R is an IBM protocol that provides RDMA capabilities over RoCE transparently for applications exploiting TCP sockets. While SMC-R does not aim to replace TCP, it taps a wealth of existing data center TCP socket applications to become more efficient without the need for rewriting them. A new socket protocol family PF_SMC is introduced. There are no changes required to applications using the sockets API for TCP stream sockets other than the specification of the new socket family AF_SMC. Unmodified applications can be used by means of a dynamic preload shared library.
  • Intel Bay Trail (and Cherry Trail) improvements – Intel HDMI audio support, patchsets for AXP288 PMIC, I2C driver, and C-state support to avoid freezes.

New features and bug fixes specific to ARM architecture:

  • Allwinner:
    • Allwinner A23 –  Audio codec device tree changes
    • Allwinner A31 – SPDIF output support
    • Allwinner A33 – cpufreq support, Audio codec support
    • Allwinner A64 – MMC Support, USB support
    • Allwinner A80 – sunxi-ng style clock support
    • Allwinner H2+ – New SoC variant, similar to H3 (mostly with a different, lower end VPU)
    • Allwinner H3 – Audio codec device tree changes, SPDIF output support
    • Allwinner V3s – New SoC support, USB PHY driver, pinctrl driver, CCU driver
    • New boards & devices – LicheePi One, Orange Pi Zero, LicheePi Zero, Banana Pi M64, Beelink X2
  • Rockchip:
    • Renamed RK1108 to RV1108
    • Clock drivers – New driver for RK3328, and non-critical fixes and clk id additions
    • Tweaks for Rockchip GRF (General Register File) usage (kitchensink misc register range on the SoCs)
    • thermal, eDP, pinctrl enhancements
    • PCI – add Rockchip system power management support
    • Add machine driver for RK3288 boards that use analog/HDMI audio
  • Amlogic
    • Add support for Amlogic Meson I2C controller
    • Add SAR ADC driver
    • Add ADC laddered keys to meson-gxbb-p200 board
    • Add configurable RGMII TX delay to fix/improve Gigabit Ethernet performance on some boards
    • Add pinctrl nodes for HDMI HPD and DDC pins modes for Amlogic Meson GXL and GXBB SoCs
    • New hardware: WeTek TV boxes
  • Samsung
    • Add USB 3.0 support in Exynos 5433
    • Removed clock driver for Samsung Exynos4415 SoCs
    • TM2 touchkey, Exynos5433 HDMI and power management improvements
    • Added Samsung Exynos4412 Prime SoC
    • Removed Samsung Exynos 4412 SoC
    • Added audio on Odroid-X board
    • Samsung Device Tree updates:
      • Add necessary initial configuration for clocks of display subsystem. Till now it worked mostly thanks to bootloader.
      • Use macro definitions instead of hard-coded values for pinctrl on Exynos7.
      • Enable USB 3.0 (DWC3) on Exynos7.
      • Add descriptive user-friendly label names for power domains. This  makes debugging easier
      • Use proper drive strengths on Exynos7.
      • Use bigger reserved memory region for Multi Format Codec on all Exynos chipsets so it could decode FullHD easily
      • Cleanup from old MACHs in s5pv210.
      • Enable IP_MULTICAST for libnss-mdns
      • Add bus frequency and voltage scalling on Exynos5433 TM2 device (along with  necessary bus nodes and Platform Performance Monitoring Unit on Exynos5433).
      • Use macros for pinctrl settings on Exynos5433.
      • Create common DTSI between Exynos5433 TM2E and TM2E.
  • Qualcomm
    • Added coresight, gyro/accelerometer, hdmi to Qualcomm MSM8916 SoC
    • Clock drivers – Updates to Qualcomm IPQ4019 CPU clks and general PLL support, Qualcomm MSM8974 RPM
    • Errata workarounds for Qualcomm’s Falkor CPU
    • Qualcomm L2 Cache PMU driver
    • Qualcomm SMCCC firmware quirk
    • Qualcomm PM8xxx ADC bindings
    • Add USB HSIC and HS phy driver for Qualcomm’s SoC
    • Device Tree Changes:
      • Add Coresight components for APQ8064
      • Fixup PM8058 nodes
      • Add APQ8060 gyro and accel support
      • Enable SD600 HDMI support
      • Add RIVA supprort for Sony Yuga and SD600
      • Add PM8821 support
      • Add MSM8974 ADSP, USB gadget, SMD, and SMP2P support
      • Fix IPQ8064 clock frequencies
      • Enable APQ8060 Dragonboard related devices
      • Add Vol+ support for DB820C and APQ8016
      • Add HDMI audio support for APQ8016
      • Fix DB820C GPIO pinctrl name
      • etc…
  • Mediatek
    • Mediatek MT2701 – Added clocks, iommu, spi, nand, adc, thermal
    • Added Mediatek MT8173 thermal
    • Added Mediatek IR remote receiver
  • GPU – Add Mali Utgard bindings;  the ARM Mali Utgard GPU family is embedded into a number of SoCs from Allwinner, Amlogic, Mediatek or Rockchip
  • Other new ARM hardware platforms and SoCs:
    • Marvell – SolidRun MACCHIATOBin board, Marvell Prestera DX packet processors
    • Broadcom – BCM958712DxXMC NorthStar2 reference board
    • HiSilicon – Kirin960/Hi3660 SoC, and HiKey960 development board
    • NXP – LS1012a SoC with three reference board; SoMs: Is.IoT MX6UL, SavageBoard, Engicam i.Core; Liebherr (LWN) monitor 6;
    • Microchip/Atmel – SAMA5d36ek Reference platform
    • Texas Instruments – Beaglebone Green Wireless and Black Wireless, phyCORE-AM335x System on Module
    • Lego Mindstorms EV3
    • “Romulus” baseboard management controller for OpenPower
    • Axentia TSE-850 Data Radio Channel (DARC) encoder
    • Luxul XAP-1410 and XWR-1200 wireless access points
    • New revision of “vf610-zii” Zodiac Inflight Innovations board

Finally here are some of the change made to MIPS architecture in Linux 4.11:

  • PCI: Register controllers in the right order to avoid a PCI error
  • KGDB: Use kernel context for sleeping threads
  • smp-cps: Fix potentially uninitialised value of core
  • KASLR: Fix build
  • ELF: Fix BUG() warning in arch_check_elf
  • Fix modversioning of _mcount symbol
  • fix out-of-tree defconfig target builds
  • cevt-r4k: Fix out-of-bounds array access
  • perf: fix deadlock
  • Malta: Fix i8259 irqchip setup
  • Lantiq – Fix adding xbar resoures causing a panic
  • Loongson3
    • Some Loongson 3A don’t identify themselves as having an FTLB so hardwire that knowledge into CPU probing.
    • Handle Loongson 3 TLB peculiarities in the fast path of the RDHWR  emulation.
    • Fix invalid FTLB entries with huge page on VTLB+FTLB platforms
    • Add missing calculation of S-cache and V-cache cache-way size
  • Ralink – Fix typos in rt3883 pinctrl data
  • Generic:
    • Force o32 fp64 support on 32bit MIPS64r6 kernels
    • Yet another build fix after the linux/sched.h changes
    • Wire up statx system call
    • Fix stack unwinding after introduction of IRQ stack
    • Fix spinlock code to build even for microMIPS with recent binutils
  • SMP-CPS: Fix retrieval of VPE mask on big endian CPUs”

Read Linux 4.11 changelog – with comments only – generated using git log v4.10..v4.11 --stat, to get the full list of changes. You may also want to checkout Linux 4.11 changelog on kernelnewbies.org.

ODROID-XU4 Development Board Price Drops to $59, Now Supports Linux 4.9 LTS

February 23rd, 2017 77 comments

ODROID-XU4 development board powered by Samsung Exynos 5422 octa-core processor launched in summer 2015, but even after two years, it’s one of the fastest, if not the fastest, low cost development board on the market. It is also equipped with Gigabit Ethernet and USB 3.0 ports, but so far at $74, it was quite much expensive than slower peers. Hardkernel has now decided to lower the price to $59 plus shipping, which is really a good deal in terms of price/performance, and you’ll also benefit from close to two years development, as the board now supports Linux 4.9 with updates promised until early 2019.

Here’s a reminder of the technical specifications:

  • SoC – Samsung Exynos 5422 quad core ARM Cortex-A15 @ 2.0GHz + quad core ARM Cortex-A7 @ 1.4GHz with Mali-T628 MP6 GPU supporting OpenGL ES 3.0 / 2.0 / 1.1 and OpenCL 1.1 Full profile
  • System Memory – 2GB LPDDR3 RAM PoP (750 MHz, 12GB/s memory bandwidth, 2x32bit bus)
  • Storage – Micro SD slot (up to 64GB) + eMMC 5.0 module socket (16, 32, and 64GB modules available)
  • Video Output – HDMI 1.4a port up to 1080p
  • Audio Output – HDMI, optional S/PDIF out via USB module
  • Network Connectivity – Gigabit Ethernet, and optional USB Wi-Fi dongle with antenna
  • USB – 2x USB 3.0 host port, 1x USB 2.0 ports
  • Expansion – 30-pin header for access to GPIO, IRQ, SPI and ADC signals + 12-pin headers for GPIOs, I2S, and I2C
  • Debugging – Serial console header
  • Misc – Power and RGB LEDs, cooling fan header, power button, RTC
  • Power Supply – 5V/4A power adapter (recommended) using 5.5/2.1mm barrel.
  • Dimensions – 82 x 58 x 22 mm
  • Weight – 60 grams with fan; 38 grams without cooler

One reason why the price is cheaper, is that the 5V/4A power adapter is not included by default, and if you don’t have your own, it will add $5.50.You’ll also find a list of accessories such as eMMC modules, enclosure, Cloudshell NAS kit, expansion boards, displays, etc… on the product page linked in the introduction.

The board can run various official or community-developed operating systems such as Ubuntu 16.04 + OpenGL ES + OpenCL, Android 4.4 to Android 7.0, Debian Jessie, Kali Linux 2.0, Arch Linux ARM, etc… and it is also supported by the Yocto Project. You’ll find the images and documentation on the Wiki, the source code is available on Github, and support in the active odroid forums and/or #odroid IRC channel.

FOSDEM 2017 Open Source Meeting Schedule

January 31st, 2017 4 comments

FOSDEM (Free and Open Source Software Developers’ European Meeting) is a 2-day free event for software developers to meet, share ideas and collaborate that happens on the first week-end of February, meaning it will take place on February 4 & 5, 2017 this year. FOSDEM 2017 will features 608 speakers, 653 events, and 54 tracks, with 6 main tracks namely: Architectures, Building, Cloud, Documentation, Miscellaneous, and Security & Encryption.
I won’t be there, but it’s always interesting to look at the schedule, and I made my own virtual schedule focusing especially on talks from “Embedded, mobile and automotive” and “Internet of Things” devrooms.

Saturday 4, 2017

  • 11:00 – 11:25 – Does your coffee machine speaks Bocce; Teach your IoT thing to speak Modbus and it will not stop talking, by Yaacov Zamir

There are many IoT dashboards out on the web, most will require network connection to a server far far away, and use non standard protocols. We will show how to combine free software tools and protocols from the worlds of IT monitoring, Industrial control and IoT to create simple yet robust dashboards.

Modbus is a serial communication protocol developed in 1979 for use with programmable logic controllers (PLCs). In simple terms, it is a method used for transmitting information over serial lines between electronic devices., it’s openly published, royalty-free, simple and robust.

Many industrial controllers can speak Modbus, we can also teach “hobby” devices like Arduino boards and ESP8266 to speak Modbus. Reliable, robust and simple free software Modbus client will be used to acquire the metrics from our device, then the metrics will be collected and sent to Hawkular and Grafana to store and visualize our data.

  • 11:30 – 11:55 – Playing with the lights; Control LIFX WiFi-enabled light bulbs, by Louis Opter

In this talk we’ll take a close look at a one of the “smart” (WiFi-connected) light-bulbs available on the market today. The bulbs expose a small API over UDP that I used to run an interface on a programmable buttons array. We will see how topics like reverse engineering, security, licensing, “self-hosting” and user experience came into play.

monolight is an user interface to control LIFX WiFi-enabled light bulbs. monolight runs on a programmable button array; it is written in Python 3.6 (to have type annotations and asyncio), and it interfaces with the bulbs through a more complex daemon written in C: lightsd.

This talk will start with a live demo of the button grid remotely controlling the light bulbs. We will then explore how it works and some of the motivations behind it (network isolation, trying to not depend on the “cloud”, reliability, user-experience). Finally, we will look into what kind of opportunities even more open IoT products could bring, and open leave the place to Q&A and discussion.

  • 12:00 – 12:30 – Creating the open connected car with GENIVI, by Zeeshan Ali, GENIVI Development Platform (GDP) technical lead

A number of new components have matured in GENIVI to provide a true connected car experience. A couple of them are key connectivity components; namely SOTA (Software Over the Air) and RVI (Remote Vehicle Interface). This talk will discuss both these components, how they work together, the security work done on them and their integration into the GENIVI Development Platform.

This talk will also run down the overall status of GENIVI’s development platform and how it can enable an automotive stack to speak not just with the cloud, but with IoT devices via Iotivity interface.

  • 12:30 – 13:00 – Making Your Own Open Source Raspberry Pi HAT; A Story About Open Source Harware and Open Source Software, by Leon Anavi

This presentation will provide guidelines how to create an open source hardware add-on board for the most popular single board computer Raspberry Pi using free and open source tools from scratch. Specifications of Raspberry Pi Foundation for HAT (Hardware Attached on Top) will be revealed in details. Leon Anavi has been developing an open source Raspberry Pi HAT for IoT for more than a year and now he will share his experience, including the common mistakes for a software engineer getting involved in hardware design and manufacturing. The presentation is appropriate for anyone interested in building entirely open source products that feature open source hardware and open source software. No previous experience or hardware knowledge is required. The main audience are developers, hobbyists, makers, and students. Hopefully the presentation will encourage them to grab a soldering iron and start prototyping their DIY open source device.

  • 13:00 – 13:25 – Building distributed systems with Msgflo; Flow-based-programming over message queues, by Jon Nordby

MsgFlo is a tool to build systems that span multiple processes and devices, for instance IoT sensor networks. Each device acts as a black-box component with input and output ports, mapped to MQTT message queues. One then constructs a system by binding the queues of the components together. Focus on components exchanging data gives good composability and testability, both important in IoT. We will program a system with MsgFlo using Flowhub, a visual live-programming IDE, and test using fbp-spec.

In MsgFlo each process/device is an independent participant, receiving data on input queues, and sending data on output queues. A participant do not know where the data comes from, nor where (if anywhere) the data will go. This strong encapsulation gives good composability and testability. MsgFlo uses a standard message queue protocol (MQTT or AMQP). This makes it easy to use with existing software. As each participant is its own process and communicate over networks, they can be implemented in any programming language. Convenience libraries exist for C++, Python, Arduino, Node.js and Rust. On top of the message queue protocol, a simple discovery mechanism is added. For existing devices without native Msgflo support, the discovery messages can be sent by a dedicated tool.

  • 13:30 – 13:55 – 6LoWPAN in picoTCP, and how to support new Link Layer types, by Jelle De Vleeschouwer

6LoWPAN enables, as the name implies, IPv6-communication over Low-power Wireless Personal Area Networks, e.g. IEEE802.15.4. A lot of resources are available to allow 6LoWPAN over IEEE802.15.4, but how can one extend the 6LoWPAN feature-set for the use with other link layer types? This talk will cover the details about a generic implementation that should work with every link layer type and how one can provide support for ones own custom wireless network. The goal is to give quite a technical and detailed talk with finally a discussion about when 6LoWPAN is actually useful and when is it not.

Last year, as a summer project, a generic 6LoWPAN adaption layer was implemented into picoTCP, an open source embedded TCP/IP-stack developed by Altran Intelligent Systems, with an eye on the IoT. The layer should also be able to allow multiple link-layer extensions, for post-network-layer processing. This could be used for mesh-under routing, link layer security, whatever you want. This talk will cover how one can take advantage of these features and caveats that come with it.

  • 14:00 – 15:00 – Groking the Linux SPI Subsystem by Matt Porter

The Serial Peripheral Interconnect (SPI) bus is a ubiquitous de facto standard found in many embedded systems produced today. The Linux kernel has long supported this bus via a comprehensive framework which supports both SPI master and slave devices. The session will explore the abstractions that the framework provides to expose this hardware to both kernel and userspace clients. The talk will cover which classes of hardware supported and use cases outside the scope of the subsystem today. In addition, we will discuss subtle features of the SPI subsystem that may be used to satisfy hardware and performance requirements in an embedded Linux system.

  • 15:00 – 15:25 – Frosted Embedded POSIX OS; a free POSIX OS for Cortex-M embedded systems, by Brabo Silvius

FROSTED is an acronym that means “FRee Operating System for Tiny Embedded Devices”. The goal of this project is to provide a free kernel for embedded systems, which exposes a POSIX-compliant system call API. In this talk I aim to explain why we started this project, the approach we took to separate the kernel and user-space on Cortex-M CPU’s without MMU, and showcase the latest improvements on networking and supported applications.

  • 15:30 – 16:00 – How to Build an Open Source Embedded Video Player, by Michael Tretter

Video playback for embedded devices such as infotainment systems and media centers demands hardware accelerators to achieve reasonable performance. Unfortunately, vendors provide the drivers for the accelerators only as binary blobs. We demonstrate how we built a video playback system that uses hardware acceleration on i.MX6 by using solely open source software including Gstreamer, Qt QML, the etnaviv GPU driver, and the coda video decoder driver.

The Qt application receives the video streams from a Gstreamer pipeline (using playbin). The Gstreamer pipeline contains a v4l2 decoder element, which uses the coda v4l2 driver for the CODA 960 video encoder and decoder IP core (VPU in the Freescale/NXP Reference Manual), and a sink element to make the frames available to the Qt application. The entire pipeline including the Gstreamer to Qt handover uses dma_bufs to avoid copies in software.This example shows how to use open source drivers to ease the development of video and graphics applications on embedded systems.

  • 16:00 – 16:25 – Project Lighthouse: a low-cost device to help blind people live independently, by David Teller

The Word Health Organization estimates that more than 250 million people suffer from vision impairment, 36 millions of them being entirely blind. In many cases, their impairment prevents them from living independently. To complicate things further, about 90% of them are estimated to live in low-income situations.

Project Lighthouse was started by Mozilla to try and find low-cost technological solutions that can help vision-impaired people live and function on their own. To this date, we have produced several prototypes designed to aid users in a variety of situations. Let’s look at some of them. This will be a relatively low-tech presentation.

  • 16:30 – 16:55 – Scientific MicroPython for Microcontrollers and IoT, IoT programming with Python, by Roberto Colistete Jr

MicroPython is a implementation of Python 3 optimised to run on a microcontroller, created in 2013 by the Physicist Damien P. George. The MicroPython boards runs MicroPython on the bare metal and gives a low-level Python operating system running interactive prompt or scripts.

The MicroPython boards currently use 32 bit microcontrollers clocked at MHz and with RAM limited to tens or hundreds of Kbytes. These are the microcontroller boards with official MicroPython support currently in the beginning 2017 : Pyboard, Pyboard Lite, WiPy 1/2, ESP8266, BBC Micro:bit, LoPy, SiPy, FiPy. They cost between USD3-40, are very small and light, about some to tens of mm in each dimension and about 5-10 g, have low power consumption, so MicroPython boards are affordable and can be embedded in almost anything, almost anywhere.

Some hints will be given to the FOSS community to be open minded about MicroPython : be aware that MicroPython exists, MicroPython is a better programming option than Arduino in many ways, MicroPython boards are available and affordable, porting more Python 3 scientific modules to MicroPython, MicroPython combines well with IoT.

  • 17:00 – 17:25 – Iotivity from devices to cloud; how to make IoT ideas to real using FLOSS, by Philippe Coval & Ziran Sun (Samsung)

The OCF/IoTivity project aims to answer interoperability issues in the IoT world from many different contexts to accommodate a huge range devices from microcontrollers, to consumer electronics such as Tizen wearables or your powerful GNU/Linux system The vision of Iotivity is not restricted to ad hoc environment but also can be connected to Internet and make the service easily accessible by other parties. With cloud access in place, usage scenarios for IoT devices can be enriched immensely.

In this talk we walk through the steps on how to practically handle IoT use cases that tailored towards various topologies. To introduce the approach used in IoTivity, we first give a detailed background introduction on IoTivity framework. Then we will present a demo that shows a few examples, from setting up a basic smart home network to accessing the IoT resource via a third party online service. Challenges and solutions will be addressed from development and implementation aspects for each step of the demo.

We hope this talk will inspire developers to create new IoT prototypes using FLOSS.

  • 17:30 – 17:55 – Open Smart Grid Platform presentation, an Open source IoT platform for large infrastructures, by Jonas van den Bogaard

The Open Smart Grid Platform is an open source IoT platform. The open smart grid platform is a generic IoT platform, built for organizations that manage and/or control large-scale infrastructures. The following use cases are now readily available: smart lighting, smart metering, tariff switching, and microgrids. Furthermore the following use-cases are in development: distribution automation, load management and smart device management. The architecture of the open smart grid platform is modular and consists multiple layers.

The open smart grid platform is highly unique for embracing the open source approach and the following key features:

  • Suitable for scalable environments delivering high performance
  • High availability and multitenant architectures
  • Built with security by design and regularly tested.
  • It has a generic architecture. More use cases and domains are easily added to the platform.
  • The open smart grid platform is based on open standards where possible.

We believe the platform is interesting for developers who have interest in working on use-cases for Smart Cities, Utility Companies and other large-scale infrastructure companies.

  • 18:00 – 19:00 – AGL as a generic secured industrial embedded Linux; factory production line controllers requirements are not that special, by Dominig ar Foll

There is no de facto secured embedded Linux distro while the requirement is becoming more and more critical with the rise of IoT in Industrial domains. When looking under the hood of the Yocto built AGL project (Automotive Linux), it is obvious that it can fit 95% of the most common requirements as a Secured Embedded Linux. We will look how non Automotive industries can easily reuse the AGL code and tools to build their own industrial product and why it’s a safer bet than to build it internally.

Industrial IoT cannot be successful without a serious improvement of the security coverage. Unfortunately there is as today, no of-the-shelves offer and the skills required to create such solution, are at best rare, more often out of reach. AGL as created a customizable embedded Linux distro which is nicely designed for reuse in many domains outside of Automotive. During the presentation we will see how to: – start your development with boards readily available on the Net, – change the BSP and add peripherals using Yocto layers or project like MRAA, – integrate a secure boot in your platform, – add your middleware and your application without breaking the maintained Core OS – develop a UI on the integrated screen and/or an HTML remote browser – update the core OS and your add-ons. – get support and influence the project.

Sunday 5, 2017

  • 10:00 11:00 – How I survived to a SoC with a terrible Linux BSP, Working with jurassic vendor kernels, missing pieces and buggy code, by Luca Ceresoli

In this talk Luca will share some of his experiences with such vendor BSPs, featuring jurassic kernels, non-working drivers, non-existing bootloaders, code of appallingly bad quality, ineffective customer support and Windows-only tools. You will discover why he spent weeks in understanding, fixing and working around BSPs instead of just using them. The effects on the final product quality will be described as well. Luca will also discuss what the options are when you face such a BSP, and what both hackers and vendors can do to improve the situation for everybody’s benefit.

  • 11:00-12:00 – Open Source Car Control, by Josh Hartung

This fall my team launched the Open Source Car Control (OSCC) project, a by-wire control kit that makes autonomous vehicle development accessible and collaborative to developers at every level. In this presentation, we discuss the project and its implications on the development of autonomous cars in a vertically integrated and traditionally closed industry.

A primary barrier to entry in autonomous vehicle development is gaining access to a car that can be controlled with an off-the-shelf computer. Purchasing from an integrator can cost upwards of $100K, and DIY endeavors can result in unreliable and unsafe solutions. The OSCC project acts as a solution to these problems. OSCC is a kit of open hardware and software (based on Arduino) that can be used to take control of the throttle, brake, and steering in modern cars. The result is a fully by-wire test car that can be built for about $10K (USD), including the vehicle. In this discussion, we unpack the impetus and development of the OSCC project, challenges we encountered during development, and the role projects like OSCC have in a necessary “flattening” of the automotive industry.

  • 12:00 – 13:00 – Kernel DLC Metrics, Statistic Analysis and Bug-Patterns, by Nicholas Mc Guire

SIL2LinuxMP strives to qualify a defined GNU/Linux subset for the use in safety-related systems by “assessment of non-compliant development”. To demonstrate that the kernel has achieved suitable reliability and correctness properties basic metrics of such properties and their statistic analysis can be used as part of the argument. Linux has a wealth of analytical tools built-in to it which allow to extract information on compliance, robustness of development, as well as basic metrics on complexity or correctness with respect to defined properties. While IEC 61508 Ed 2 always pairs testing and analysis, we believe that for a high complexity system traditional testing is of relatively low effectiveness and analytical methods need to be the primary path. To this ends we outline some approaches taken:

  • Bug-age analysis
  • Bug-rates and trend analysis
  • Code-complexity/bug relationship
  • Brain-dead correctness analysis
  • Interface and type-correctness analysis
  • API compliance analysis
  • Analysis of build-bot data

While much of the data points to robust and mature code there also are some areas where problems popped up. In this talk we outline the used methods and give examples as well as key findings. FLOSS development has reached a quite impressive maturity, to substantially go beyond we think it will need the use of quantitative process and code metrics – these results from SIL2LinuxMP may be a starting point.

  • 13:00 – 14:00 – Loco Positioning: An OpenSource Local Positioning System for robotics, presentation with a demo of autonomous Crazyflie 2.0 quadcopter, by Arnaud Taffanel

Positioning in robotics has alway been a challenge. For outdoor, robots GPS is solving most of the practical problems, but indoor, precise localization is still done using expensive proprietary systems mainly based on an array of cameras.

In this talk, I will present the loco positioning system: an open source Ultra Wide Band radio-based local positioning system, why we need it and how it works. I will also speak about its usage with the Crazyflie 2.0 open source nano quadcopter, of course ending with an autonomous flying demo.

  • 14:00 14:50 – Free Software For The Machine, by Keith Packard

The Machine is a hardware project at Hewlett Packard Enterprise which takes a new look at computer architecture. With many processors and large amounts of directly addressable storage, The Machine program has offered an equally large opportunity for developing new system software. Our team at HPE has spent the better part of two years writing new software and adapting existing software to expose the capabilities of the hardware to application developers.

As directly addressable storage is such a large part of the new hardware, this presentation will focus on a couple of important bits of free software which expose that to applications, including our Librarian File System and Managed Data Structures libraries. Managed Data Structures introduces a new application programming paradigm where the application works directly on the stable storage form for data structures, eliminating serialization and de-serialization operations.

Finally, the presentation will describe how the hardware is managed, from sequencing power to a rack full of high-performance computing hardware, through constructing custom Linux operating systems for each processor and managing all of them as parts of a single computing platform.

  • 15:00 – 15:25 – Diving into the KiCad source code, by Maciej Sumiński

Let’s be sincere, all of us would love to change something in KiCad. I bet you have an idea for a new tool or another killer feature that would make your life so much easier.

You know what? You are free to do so! Even more, you are welcome to contribute to the project, and it is not that difficult as one may think. Those who have browsed the source code might find it overwhelming at first, but the truth is: you do not have to know everything to create useful extensions.

I would like to invite you for a walk through the KiCad source code to demonstrate how easy it is to add this tool you have always been dreaming about.

  • 15:30 – 16:00 – Testing with volcanoes – Fuego+LAVA, embedded testing going distributed, by Jan-Simon Möller

LAVA and Fuego are great tools individually already. Combining and extending them allows for a much broader test coverage than each tool alone can provide.

The focus of this talk is to share the experiences made and lessons learned so people can integrate such tools better in their own environment. It also raises the pain-points and open issues when setting up a distributed environment.

Especially for Automotive, Long-Term-Support, CIP or Consumer Electronics, advancing the Test-harness is essential to raise the bar and strengthen the confidence in our embedded platforms. Automated testing can improve our ecosystem from two sides: during development (feature does work and does not break things) and during maintenance (no regressions through backports).

  • 16:00 – 16:30 – Adding IEEE 802.15.4 and 6LoWPAN to an Embedded Linux Device, by Stefan Schmidt

Adding support for IEEE 802.15.4 and 6LoWPAN to an embedded Linux board opens up new possibilities to communicate with tiny, IoT type of, devices.

Bringing IP connectivity to devices, like sensors, with just a few kilobytes of RAM and limited battery power is an interesting IoT challenge. With the Linux-wpan and 6LoWPAN subsystems we get Linux ready to support the needed wireless standards as well as protocols that connect these tiny devices into the wider Internet. To make Linux a practical border router or smart home hub for such networks.

This talk will show how to add the needed transceiver hardware to an existing hardware and how to enable and configure the Linux-wpan and 6LoWPAN mainline subsystems to use it. The demonstration will include setting up the communication between Linux and other popular IoT operating systems like RIOT or Contiki as well.

  • 16:30 – 17:00 – OpenPowerlink over Xenomai, by Pierre Ficheux

Industrial Ethernet is a successor of classic field bus such as CAN, MODBUS or PROFIBUS. POWERLINK was created by B&R Automation and provides performance and real­-time capabilities based on standard Ethernet hardware. openPOWERLINK is open source and runs on lots of platforms such as Linux, Windows, various RTOS and dedicated hardware (FPGA). We will explain how to use openPOWERLINK on top of Xenomai 3, a powerful real-time extension for Linux kernel based on co-­kernel technology.

FOSDEM 2017 will take place at the ULB Solbosch Campus in Brussels, Belgium, and no registration is required, you just need to show up in order to attend the event.

Canonical Livepatch Service Automatically Updates Ubuntu 16.04 LTS (and later) with the Latest Kernel without Rebooting

October 25th, 2016 15 comments

Installing or upgrading packages in Linux distributions does not normally require rebooting your system, except for the Linux kernel and drivers. But since Linux 4.0 kernel, Live Kernel patching is possible, meaning Linux kernel updates can be performed without having to reboot your server or computer. Canonical is now taking advantage of this new feature with their Livepatch Service available for Ubuntu 16.04 LTS and greater.

canonical_livepatchIf you want to enable it on your machine, you’ll have to authenticate to Livepatch portal to get a key / token for the service as shown in the screenshot above.

Now you can install the service:

and enable it with your token:

That’s it. Your can check Livepatch service status with the command:

In my case, an update was not necessary, but if there’s one you should see something like:

That way you can make sure your system always have the latest security patchsets. This is mostly useful for servers, but it might not be a bad idea to enabled for your computer too, especially it’s free for end-users for up to 3 machines. Companies need to apply to Ubuntu Advantage for business to support more machines.

Linux 4.8 Release – Main Changes, ARM & MIPS Architectures

October 4th, 2016 4 comments

Linus Torvalds has officially released Linux 4.8 last Sunday:

So the last week was really quiet, which maybe means that I could probably just have skipped rc8 after all. Oh well, no real harm done.

This obviously means that the merge window for 4.9 is open, and I appreciate the people who already sent in some pull requests early due to upcoming travel or other reasons. I’ll start pulling things tomorrow, and have even the most eager developers and testers hopefully test the final 4.8 release before the next development kernels start coming 😉

Anyway, there’s a few stragging fixes since rc8 listed below: it’s a mixture of arch fixes (arm, mips, sparc, x86), drivers (networking, nvdimm, gpu) and generic code (some core networking, with a few filesystem, cgroup and and vm things).

All of it pretty small, and there really aren’t that many of them. Go forth and test,
Linus

Linux 4.7 introduced support for AMD Radeon RX480 GPUs, parallel directory lookups, the new “schedutil” frequency governor with lower latency, EFI ‘Capsule’ firmware updates, and much more.

linux-4-8-changelogSome notable Linux 4.8 changes include:

  • HDMI-CEC framework
  • Kernel documentation system is now based on Sphinx
  • GPIO subsystem has a new user-space ABI for the management of general-purpose I/O lines; it is based on char devices and replaces the long-deprecated sysfs interface. You can check out tools/gpio/ directory with lsgpio, gpio-hammer, and gpio-event-mon for examples
  • Various file systems improvements for Btrfs, EXT-4 (unified encryption), OrangeFS (better in-kernel caching), Ceph (RADOS namespace support), XFS (Reverse-mapping support), etc…

Some improvements and new features specific to the ARM architecture and corresponding hardware platforms:

  • Allwinner:
    • Allwinner A10/A20 – Display engine clocks (TCON, FE, DE), I2S audio interface (ASoC) driver, added NFC node to DTS
    • Allwinner H3 – Clocks (through sunxi-ng), USB multi-reset lines support
    • AXP2xx driver – External drivebus support, AXP223 USB power supply support, AXP809 PMIC support
    • Broadcom BCM53125 support as it’s used in Lamobo / Banana Pi R1 router board.
    • New boards – Polaroid MID2407PXE03 & inet86dz (Allwinner A23 tablets), Banana Pi M1+, Banana Pi M2+, Allwinner Parrot (Allwinner R16 EVB)
  • Rockchip:
    • Many new peripherals added to RK3399 (eDP, clock controller, etc…)
    • Preparations to use generic DMA mapping code in the Rockchip IOMMU driver
    • Fixes for eMMC controller, SPI controller, eDP controller, and I2C
  • Amlogic
    • AmLogic meson8b clock controller (rewritten)
    • AmLogic gxbb clock controller
    • Reset controller driver for Amlogic Meson
    • New watchdog driver for Amlogic Meson GXBB (S905) SoC
    • Added support for Amlogic Meson RNG in crypto drivers
    • Some Amlogic ARM64 DTS updates
  • Samsung
    • Enable drivers for Exynos7 and Exynos5433 based boards: S2MPS clock driver, SoC: RTC, SPI, watchdog, EHCI, OHCI, DWC3, ADC and PWM, Enable Samsung SoC sound
    • Samsung ARM64 DTS Changes – Adjust the voltage of CPU buck regulator so scaling could work.
    • Samsung DTS changes
      • Add missing async bridge for MFC power domain on Exynos5420. This fixes imprecise abort on s5p-mfc re-bind.
      • Define regulator supplies for MMC nodes on Exynos4412 Odroid boards and for TMU on Exynos542x Peach boards.
      • Thermal cleanups on Odroid XU3-family (Exynos5422).
      • Enable AX88760 USB hub on Origen board (Exynos4412)
      • Disable big.LITTLE switcher so the cpufreq-dt could be enabled.
      • Enable Samsung media platform drivers.
      • Enable some board-specific drivers for boards: Trats2, Universal C210.
      • Enable Virtual Video Test Driver on nulti_v7 and exynos defconfigs. Useful for testing
    • Samsung drivers/soc updates:
      • Move the power domain driver from arm/mach-exynos and prepare for supporting ARMv8.
      • Add COMPILE_TEST.
      • Make SROMC driver explicitly non-module.
      • Endian-friendly fixes.
      • Fix size of allocation for Exynos SROM registers (too much was allocated)
    • Add CEC interface driver present in the Samsung Exynos SoCs
    • Added support for Exynos 5410 Odroid XU board
  • Qualcomm
    • Added MDM9615 support
    • Qualcomm ARM Based Driver Updates:
      • Rework of SCM driver
      • Add file patterns for Qualcomm Maintainers entry
      • Add worker for wcnss_ctrl signaling
      • Fixes for smp2p
      • Update smem_state properties to match documentation
      • Add SCM Peripheral Authentication service
      • Expose SCM PAS command 10 as a reset controller
      • Fix probe order issue in SCM
      • Add missing qcom_scm_is_available() API
    • Qualcomm ARM64 Updates
      •  Enable assorted peripherals on APQ8016 SBC
      • Update reserved memory on MSM8916
      • Add MSM8996 peripheral support
      • Add SCM firmware node on MSM8916
      • Add PMU node on MSM8916
      • Add PSCI cpuidle support on MSM8916
    • Qualcomm Device Tree Changes:
      • Reverse BAM dma node reverts
      • Add BAM remote control options for affected platforms
      • Enable peripherals on APQ8074 dragonboard
      • Enable PMA8084 pwrky
      • Fix PMIC reg entries by removing unnecessary size element
      • Add SCM binding and support for all currently supported boards
      • Add Qualcomm WCNSS binding documentation
      • Rename db600c to SD_600eval and add peripheral nodes
      • Remove gpio key entry from Nexus7
      • Add APQ8060 based dragonboard and associated peripherals
      • Add ARMv7 PMU for IPQ4019
      • Update smem state cells to match documentation
    • ARM64 defconfig: Enable PM8xxx pwrkey support, enable MSM8996 support
    • ARM defconfig: Enable MSM9615 board support, enable MSM8660 pinctrl support
  • Mediatek
    • Added Mediatek MT6755
    • Display subsystem added to MT8173
    • Support for Mediatek generation one IOMMU hardware
    • New drivers for Mediatek MT6323 regulator
    • new encoding codec driver for Mediatek SoC (linux-media): H.264/VP8/V4L2 video encoder drivers for MT8173
  • ARM64 – arm64 architecture has gained support for the kexec mechanism (allowing one kernel to boot directly into another) and kernel probes.
  • Other new ARM hardware or SoCs – NXP i.MX 7Solo, Broadcom BCM23550, Cirrus Logic EP7209 and EP7211 (clps711x platforms), Hisilicon HI3519, Renesas R8A7792, Apalis Tegra K1 board, LG LG1313, Renesas r8a7796, Broadcom BCM2837 (used in Raspberry Pi 3)

MIPS architecture changelog:

  • Fix memory regions reaching top of physical
  • MAAR: Fix address alignment
  • vDSO: Fix Malta EVA mapping to vDSO page structs
  • uprobes: fix incorrect uprobe brk handling, select HAVE_REGS_AND_STACK_ACCESS_API
  • Avoid a BUG warning during PR_SET_FP_MODE prctl
  • SMP: Fix possibility of deadlock when bringing CPUs online
  • R6: Remove compact branch policy Kconfig entries
  • Fix size calc when avoiding IPIs for small icache flushes
  • Fix pre-r6 emulation FPU initialisation
  • Fix delay slot emulation count in debugfs
  • CM: Fix mips_cm_max_vp_width for non-MT kernels on MT systems
  • CPS: Avoid BUG() when offlining pre-r6 CPUs
  • DEC: Avoid gas warnings due to suspicious instruction scheduling by manually expanding assembler macros.
  • FTLB: Fix configuration by moving configuration after probing, clear execution hazard after changing FTLB enable
  • Highmem: Fix detection of unsupported highmem with cache aliases
  • I6400: Don’t touch FTLBP chicken bits
  • microMIPS: Fix BUILD_ROLLBACK_PROLOGUE
  • Malta: Fix IOCU disable switch read for MIPS64
  • Octeon: Fix probing of devices attached to GPIO lines, fix kernel header to work for VDSO build, fix initialization of platform device probing.

You can find the full list of changes in Linux 4.8 changelog with comments only generated using git log v4.7..v4.8 --stat. A list of changes for Linux 4.8 will also soon be found on kernelnewbies.org.

Linux 4.7 Release – Main Changes, ARM and MIPS Architectures

July 25th, 2016 7 comments

Linux 4.7 is out:

So, after a slight delay due to my travels, I’m back, and 4.7 is out.

Despite it being two weeks since rc7, the final patch wasn’t all that big, and much of it is trivial one- and few-liners. There’s a couple of network drivers that got a bit more loving. Appended is the shortlog since rc7 for people who care: it’s fairly spread out, with networking and some intel Kabylake GPU fixes being the most noticeable ones. But there’s random small noise spread all over.

And obviously, this means that the merge window for 4.8 is open.Judging by the linux-next contents, that’s going to be a bigger release than the current one (4.7 really was fairly calm, I blame at least partly summer in the northern hemisphere).

Linus

Linux 4.6 brought USB 3.1 superspeed, OrangeFS distributed file system, 802.1AE MAC-level encryption (MACsec), and BATMAN V protocol support, improved the reliability of OOM task killer, and more.

Linux_4.7_Changelog

Linux 4.7 most noticeable changes include:

  • Support for Radeon RX480 GPUs
  • Parallel directory lookups –  The directory cache caches information about path names to make them quickly available for pathname lookup. This cache uses a mutex to serialize lookup of names in the same directory.  The serializing mutex has been switched to a read-write semaphore in Linux 4.7, allowing for parallel pathname lookups in the same directory. Most filesystems have been converted to allow this feature.
  • New “schedutil” frequency governor –  There are two main differences between it and the existing governors. First, it uses information provided by the scheduler directly for making its decisions. Second, it can invoke cpufreq drivers and change the frequency to adjust CPU performance right away, without having to spawn work items to be executed in process context or similar, leading to lower latency to make frequency changes.
  • Histograms of events in ftrace –  . This release adds the “hist” command, which provides the ability to build “histograms” of events by aggregating event hits. As an example, let’s say a user needs to get a list of bytes read from files from each process. You can get this information using hist triggers, with the following command command:

    other data can also be retrieve by using fields found in /sys/kernel/debug/tracing/events/syscalls/sys_enter_read/format. The output will look like:

    More more details check ftrace documentation and related LWN article.
  • EFI ‘Capsule’ firmware updates –  The EFI Capsule mechanism allows to pass data blobs to the EFI firmware. The firmware then parses them and makes some decision based upon their contents. The most common use case is to bundle a flashable firmware image into a capsule that the firmware can use to upgrade in the next boot the existing version in the flash. Users can upload capsule by writing the firmware to the /dev/efi_capsule_loader device
  • Support for creating virtual USB Device Controllers in USB/IP – USB/IP allows to share real USB devices over the network. Linux 4.7 brings the ability to create virtual USB Device Controllers without needing any physical USB device, using the USB gadget subsystem. For what purpose? For example, for improving phone emulation in development environments, for testing USB and for educational purposes.

Some of ARM specific improvements and new features include:

  • Allwinner:
    • Allwinner A13/R8 – Display Engine support
    • Allwinner A10/A20 – S/PDIF Support
    • Allwinner A31/A23/H3 – DMAengine improvements for H3 audio support
    • Allwinner H3 – USB support (multi-reset line support delayed til 4.8)
    • New hardware supported
      • Tablets – Dserve DSRV9703C, Polaroid MID2809PXE4, Colorfly e708 q1, Difrence DIT4350
      • Boards – Olimex A20 OLinuXino LIME2, Xunlong Orange Pi 2, Orange Pi One, and Orange Pi PC
  • Rockchip:
    • Thermal management – Rockchip driver support for RK3399, RK3366
    • Added Rockchip RK3399 clock and reset controller
    • Pinctrl – Support the .get_direction() callback in the GPIO portions
    • New RK3399 device tree support
    • Added Rockchip DisplayPort PHY support
    • Added Geekbuying GeekBox, RK3399 Evaluation Board, mqmaker MiQi SBC
  • Amlogic
    • Added Meson GXBB (S905) pinctrl support
    • Fixed memory nodes on Vega S95 DTS
    • Added Hardkernel ODROID-C2, Amlogic Meson GXBB P200 and P201 development systems
  • Samsung
    • Added Samsung ARTIK5 evaluation board
    • Added generic exynos bus frequency driver
    • Added pinctrl driver for Samsung EXYNOS5440 SoC
    • DTS updates & fixes:
      • Fix s5p-mfc driver probe on Exynos542x Peach boards (need to provide MFC memory banks). On these boards this was broken for long time but apparently no one enabled this driver till now.
      • Fix creation of debugfs entries for one regulator on Exynos4210 Trats board.
      • Fix probing of max8997 MFD driver (and its children) because of missing interrupt. Actually the current version of the driver probes (just without interrupts) but after switching to regmap and regmap-irq, the interrupt will be mandatory.
      • Cleanup regulator bindings on Exynos5420 boards.
      • Support MIC bypass in display path for Exynos5420.
      • Enable PRNG and SSS for all Exynos4 devices.
      • Add PL330 DMA controller and Thermal Management Unit to Exynos 7
      • Enable accelerated AES (Security SubSystem) on Exynos4412-based boards
      • Enable HDMI CEC on Exynos4412-based Odroid.
      • Add regulator supplies for eMMC/SD on Odroid XU3/XU4.
      • Fix DTC unit name warnings.
  • Qualcomm
    • Qualcomm IPQ4019 support in pinctrl
    • Change SMD callback parameters
    • 96Boards HiKey based on the Hisilicon Hi6220 (Kirin 620) gets an overhaul with a lot of devices enabled in the DT.
    • Added Qualcomm IPQ4019 “Internet processor”,  Arrow DragonBoard 600c (96boards) with APQ8064 Snapdragon 600
    • Device tree changes:
      • Add additional nodes for APQ8064
      • Fix APQ8064 pinctrls for i2c/spi
      • Add MSM8974 nodes for smp2p and smd
      • Modify MSM8974 memory reserve for rfsa and rmtfs
      • Add support for BQ27541 on Nexus7
  • Mediatek
    • Added  CPU power cooling model to Mediatek thermal driver
    • Added Mediatek MT8173 display driver, DRM driver, and thermal controller
    • Added MIPI DSI sub driver
    • 4GB mode support for Mediatek IOMMU driver
    • DTS updates:
      • add pinctrl node for mt2701
      • add mt2701 pmic wrapper binding
      • add auxadc binding document
  • Other new ARM hardware or SoCs – LG1312 TV SoC, Hisilicon Hip06/D03, Google Pixel C, NXP Layerscape 1043A QDS development board, Aspeed AST2400/AST2500, Oxnas 810SE (WD My Book World Edition), ARM MPS2 (AN385 Cortex-M3 & AN399 Cortex-M7), Ka-Ro electronics industrial SoM modules, Embest MarS Board, Boundary Devices i.MX6 Quad Plus Nitrogen6_MAX and SoloX Nitrogen6sx embedded boards, Technexion Pico i.MX6UL compute module, ZII VF610 Development Board, Linksys Viper (E4200v2 / EA4500) WiFi router, Buffalo Kurobox Pro NAS, samtec VIN|ING 1000 vehicle communication interface, Amazon Kindle Fire first generation tablet and ebook reader,  OnRISC Baltos iR 2110 and 3220 embedded industrial PCs, TI AM5728 IDK, TI AM3359 ICE-V2, and TI DRA722 Rev C EVM development systems.

MIPS architecture changelog:

  • Add support for relocatable kernel so it can be loaded someplace besides the default 1MB.
  • Add KASLR support using relocatable support
  • Add perf counter feature
  • Add support for extending builtin cmdline
  • seccomp: Support compat with both O32 and N32
  • ath79: Add support for DTB passed using the UHI boot protocol, remove the builtin DTB support, add zboot debug serial support, add initial support for DPT-Module, Dragino MS14 (Dragino 2), and Onion Omega
  • BMIPS: Add BCM6358 support, add Whirlwind (BMIPS5200) initialization code, add support for BCM63268
  • Lantiq: Add support for device tree file from boot loader
  • Add basic Loongson 3A support
  • Add support for CN73xx, CN75xx and CN78xx
  • Octeon: Add DTS for D-Link DSR-1000N
  • Detect DSP v3 support
  • Detect MIPSr6 Virtual Processor support
  • Enable ptrace hw watchpoints on MIPS R6
  • Probe the M6250 CPUand the P6600 core
  • Support sending SIG_SYS to 32bit userspace from 64bit kernel
  • qca: introduce AR9331 devicetree
  • ralink: add MT7628 EPHY LEDs pinmux support
  • smp-cps: Add nothreads kernel parameter
  • smp-cps: Support MIPSr6 Virtual Processors
  • MIPS64: Support a maximum at least 48 bits of application virtual

For even much more details, you can check out Linux 4.7 changelog with comments only generated using git log v4.6..v4.7 --stat. Alternatively, and much easier to read, you can head to kernelnewbies.org to learn more about Linux 4.7 changes.

Updating Star Cloud PCG02U to Ubuntu 16.04 with WiFi and HDMI Audio Support

May 26th, 2016 21 comments

I completed my review of PCG02U Ubuntu TV stick a few days ago, and I was quite satisfied with the device, but since Ubuntu 16.04 was released last month, I thought it might be fun to upgrade to the latest version of Ubuntu. I’m go through the complete steps including building a new kernel for HDMI audio, and the drivers for WiFi, but you should be able to install Ubuntu 16.04 for Bay Trail and Cherry Trail processor with the image made by Linuxium and a USB stick.

Star Cloud PCG02U OS Support and Warranty

Before I go through the instructions, you may want to read the conditions on MeLE’s Aliexpress PCG02U page.

PCG02U_Linux_OS_WarningThey meant Ubuntu 14.04 instead of 14.0.4, but the important part is that if something goes wrong trying alternative OS, you may lose your warranty.

Upgrade Ubuntu 14.04 to Ubuntu 16.04

Upgrading from one LTS version to the next should be easy using the update manager…

… or doing it through the terminal entirely:

However, it did not work for me, as it quickly ended with the message:

I noticed that PCG02U was still stuck on Ubuntu 14.04.3 LTS, despite running dist-upgrade:

After trying several solutions, I eventually changed the Ubuntu mirror, and the steps above completed successfully with Ubuntu 16.04 running.

Click to Enlarge

Click to Enlarge

At least two little problems though: I lost HDMI audio with only Dummy Output available, and while Ethernet was still working after the update, WiFi support was gone… But if you don’t need either you’re good to go.

Enabling HDMI audio in PCG02U

Luckily we already have the instructions to enable HDMI audio for Bay Trail and Cherry Trail processors, all we need is a Linux 4.5 kernel and patch it. I’ll do everything inside PCG02U, and I have not used a separate build machine, which would likely be faster. Tip: you’ll need gcc 4.9 or greater. I used the instruction here and there.

First let’s build the dependencies required to build the kernel in Ubuntu.

Now let’s get the patches in a working directory

as well as the Linux 4.5.1 kernel patched for Ubuntu and the Intel Atom HDMI audio support:

Now we can configure the build:

This will ask which config files to configure for AMD64, i386, ARM and so on. We only need to edit the first one (AMD64). Once you are in the config menu, use menuconfig search function to locate SUPPORT_HDMI option and enable it. Exit and save.
CONFIG_SUPPORT_HDMI

Before starting the build add something like “+some_string” to the end of the first version number in the debian.master/changelog> file. I added +hdmi_audio string:

You can now start the build with:

However, the build did not complete for me, with the error:

I followed the instructions on askubuntu, and disabled set do_zfs = false in debian.master/rules.d/amd64.mk, and completed the build with the same command line. It took around 2 to 3 to complete the build on PCG02U, and I had a bunch of deb packages…

.. and I installed the headers and image:

Rebooted the system, which booted successfully, and I could confirm HDMI audio was back. Yes!

Click to Enlarge

Click to Enlarge

But still no WiFi… and space was running now, so I did some cleaning which gave me a few gigabytes to play with:

Building Realtek RTL8723BS WiFi Driver in Ubuntu/Linux

Star Cloud PCG02U uses  a WiFi and Bluetooth module with the common Realtek RTL8723BS chip, but the driver is not currently in mainline, so it needs to be compiled separately. That part is straightforward, and only take 2 minutes or less:

That’s all and now the Wireless network is enabled:

Click to Enlarge

Click to Enlarge

I had no problems connecting to my wireless router, and the module is automatically loaded at boot time. So now we have the same level of support as in Ubuntu 14.04 with HDMI audio and WiFi.

Realtek RTL8732BS Bluetooth in Linux

However, the hardware also supports Bluetooth, so it would be nice to have this enabled too, and again RTL8723BS Linux Bluetooth driver is available thanks to one independent developer (lwfinger).

In theory, it’s pretty easy:

But this did not work for me, despite Bluetooth apparently being located on /dev/ttyS4:

But the log would show a connection timeout:

Sadly, I haven’t been able to find a solution in a reasonable amount of time, and changing the baudrate from 115200 in the script to 2764800 (as shown in dmesg) does not help.

Of course everything would be so much easier if HDMI audio Cherry Trial and Bay Trial and RTL8723BS drivers would be in mainline linux, as all you would have to do would be to install Mainline linux in Ubuntu, and everything would just work. This does require some work however, but if you are motivated, lwfinger is ready to submit the RTL8723BS WiFi code to mainline if somebody takes care of all the errors and warnings generated by checkpatch.pl.