Bringing display and 3D to the C.H.I.P computer

Similar documents
Bringing display and 3D to the C.H.I.P computer

Supporting a new ARM platform: the Allwinner example

Supporting a new ARM platform: the Allwinner example

An Overview of the DMAEngine Subsystem

Modernizing the NAND framework: The big picture

DRM(Direct Rendering Manager) of Tizen Kernel Joonyoung Shim

Display and Kernel Review and Future

Graphics Stack Update

Free Electrons Company profile Kernel, drivers, embedded Linux and Android development, consulting, training and support

Kodi and Embedded Linux

Running Android on the Mainline Graphics Stack. Robert

Building X 2D rendering acceleration with OpenGL. Eric Anholt Intel Open Source Technology Center

Marek Szyprowski Samsung R&D Institute Poland

Methods to protect proprietary components in device drivers

F28HS Hardware-Software Interface: Systems Programming

Device Tree as a stable ABI: a fairy tale?

Linux DRM Developer s Guide

ARM support in the Linux kernel

SMP bring up on ARM SoCs

PRIME Synchronization. XDC 2016 Alex Goins, Andy Ritger

Linux DRM Developer s Guide

ARM: Allwinner sunxi SoC's and the community behind it

Status Report 2015/09. Alexandre Courbot Martin Peres. Logo by Valeria Aguilera, CC BY-ND

The DRM/KMS subsystem from a newbie s point of view

ARM support in the Linux kernel

Understand your NAND and drive it within Linux

#jsnight, Gianpaolo Macario (C) 2016 Gianpaolo Macario - License: CC BY-SA 4.0

Porting Tizen-IVI 3.0 to an ARM based SoC Platform

Overview. Technology Details. D/AVE NX Preliminary Product Brief

Multimedia SoC System Solutions

Mainline Explicit Fencing

I + I2C = I3C, what s hiding in this additional I

ARM64 + FPGA and more: Linux on the Xilinx ZynqMP

Two years of ARM SoC support mainlining: lessons learned

Porting Tizen-IVI 3.0 to an ARM based SoC Platform. Damian Hobson-Garcia, IGEL Co., Ltd.

The Linux graphics stack, Optimus and the Nouveau driver

Vulkan: Scaling to Multiple Threads. Kevin sun Lead Developer Support Engineer, APAC PowerVR Graphics

SFO15-100: 96Boards & the course upstream

Media Controller (MC) and OMAP2+ Display Subsystem (DSS) Embedded Linux Conference, SFO, 2011 Sumit Semwal

Bringing it all together: The challenge in delivering a complete graphics system architecture. Chris Porthouse

Mobile Graphics Ecosystem. Tom Olson OpenGL ES working group chair

PCIe driver development for Exynos SoC

OP-TEE Using TrustZone to Protect Our Own Secrets

Memory Management in Tizen. SW Platform Team, SW R&D Center

Expose NVIDIA s performance counters to the userspace for NV50/Tesla

FPGA Manager. State of the Union. Moritz Fischer, National Instruments

SD/eMMC: new speed modes and their support in Linux

Embedded Linux system development training 5-day session

Introduction to creating 3D UI with BeagleBoard. ESC-341 Presented by Diego Dompe

Embedded Linux kernel and driver development training 5-day session

A tour of the ARM architecture and its Linux support

Rootfs made easy with Buildroot

Profiling and Debugging OpenCL Applications with ARM Development Tools. October 2014

Efficient Video Processing on Embedded GPU

Freescale i.mx6 Architecture

Xen Automotive Hypervisor Automotive Linux Summit 1-2 July, Tokyo

Pushing The Limits Of Linux On ARM

OK335x Products Guide. Contents

Wayland IVI Extension

Designing with NXP i.mx8m SoC

Multimedia in Mobile Phones. Architectures and Trends Lund

Matrix. Get Started Guide

A brief overview of DRM/KMS and its status in NetBSD

Speeding AM335x Programmable Realtime Unit (PRU) Application Development Through Improved Debug Tools

Applications and Implementations

Embedded Linux UI Comparison. Tim Bird Senior Staff Software Engineer Sony Electronics

Development of Real-Time Systems with Embedded Linux. Brandon Shibley Senior Solutions Architect Toradex Inc.

Vulkan: Architecture positive How Vulkan maps to PowerVR GPUs Kevin sun Lead Developer Support Engineer, APAC PowerVR Graphics.

Unleashing the benefits of GPU Computing with ARM Mali TM Practical applications and use-cases. Steve Steele, ARM

Android System Development Training 4-day session

Patrick Doyle Principal Software Engineer, irobot 2017 Embedded Linux Conference, Portland OR

Cut Power Consumption by 5x Without Losing Performance

Power Management Integrated Circuits: Keep the power in your hands

Porting Nouveau to Tegra K1

MultiDroid: A Novel Solution to Consolidate Interactive Physical Android Clients on One Single Computing Platform

POWER-AWARE SOFTWARE ON ARM. Paul Fox

! Readings! ! Room-level, on-chip! vs.!

NXP-Freescale i.mx6 MicroSoM i2. Dual Core SoM (System-On-Module) Rev 1.3

4K HEVC Video Processing with GPU Optimization on Jetson TX1

Next Generation OpenGL Neil Trevett Khronos President NVIDIA VP Mobile Copyright Khronos Group Page 1

SD/eMMC: new speed modes and their support in Linux Embedded Linux Experts

BlazePPS (Blaze Packet Processing System) CSEE W4840 Project Design

System-on-Chip Architecture for Mobile Applications. Sabyasachi Dey

Lecture 25: Board Notes: Threads and GPUs

Mali-400 MP: A Scalable GPU for Mobile Devices Tom Olson

Kernel maintainership: an oral tradition

A Linux multimedia platform for SH-Mobile processors

Status of the Embedded GPU Space

NXP-Freescale i.mx6 MicroSoM i4pro. Quad Core SoM (System-On-Module) Rev 1.3

Applications and Implementations

From the Ethernet MAC to the link partner

Embedded Linux Conference San Diego 2016

4K Video Processing and Streaming Platform on TX1

The Mobile Internet: The Potential of Handhelds to Bring Internet to the Masses. April 2008

GRATE LIBERATING NVIDIA'S TEGRA GPU. February Erik "kusma" Faye-Lund.

The Benefits of GPU Compute on ARM Mali GPUs

Generic Buffer Sharing Mechanism for Mediated Devices

ARM Trusted Firmware ARM UEFI SCT update

IO virtualization. Michael Kagan Mellanox Technologies

DRI Memory Management

Transcription:

Embedded Linux Conference 2016 Bringing display and 3D to the C.H.I.P computer Maxime Ripard maxime@bootlin.com Copyright 2004-2018, Bootlin. Creative Commons BY-SA 3.0 license. embedded Linux and kernel engineering Corrections, suggestions, contributions and translations are welcome! - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 1/1

Maxime Ripard Embedded Linux engineer and trainer at Bootlin Embedded Linux development: kernel and driver development, system integration, boot time and power consumption optimization, consulting, etc. Embedded Linux training, Linux driver development training and Android system development training, with materials freely available under a Creative Commons license. http://bootlin.com Contributions Co-maintainer for the sunxi SoCs from Allwinner Contributor to a couple of other open-source projects, Buildroot, U-Boot, Barebox Living in Toulouse, south west of France - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 2/1

Bringing display and 3D to the C.H.I.P computer Introduction - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 3/1

C.H.I.P.? 9$ SBC Based on an Allwinner R8 (equivalent to A13) 1GHz Cortex-A8 CPU Mali 400 GPU Plenty of GPIOs to bitbang stuff (and real controllers too!) Running mainline-ish Linux kernel (4.3, soon to be 4.4) - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 4/1

Development effort A significant part of the work already done But key features for a desktop-like application were missing Audio NAND support Display Plus board specific developments Wifi regulators DIP - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 5/1

Bringing display and 3D to the C.H.I.P computer How to display things in Linux? - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 6/1

Doing display things Different solutions, provided by different subsystems: FBDEV: Framebuffer Device DRM/KMS: Direct Rendering Manager / Kernel Mode Setting More exotic ones: V4L2, auxdisplay How to choose one: it depends on your needs Each subsytem provides its own set of features Different levels of complexity Different levels of activity - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 7/1

Which one to choose? DRM Actively maintained Provides fine grained control on the display pipeline Widely used by user-space graphic stacks Provides a full set of advanced features FBDEV Deprecated? Does not provides all the features found in the modern display controllers (overlays, sprites, hw cursor,...) - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 8/1

Bringing display and 3D to the C.H.I.P computer DRM/KMS - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 9/1

DRM/KMS: Definition DRM stands for Direct Rendering Manager and was introduced to deal with graphic cards embedding GPUs KMS stands for Kernel Mode Setting and is a sub-part of the DRM API Though rendering and mode setting are now split in two different APIs (accessible through /dev/dri/renderx and /dev/dri/controldx) KMS provide a way to configure the display pipeline of a graphic card (or an embedded system) KMS is what we re interested in when looking for an FBDEV alternative - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 10/1

DRM/KMS pipeline - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 11/1

KMS components Planes Image source Associated with one (or more!) framebuffers Holds a resized version of that framebuffer CRTCs Take the planes, and does the composition Contains the display mode and parameters Encoders Take the raw data from the CRTC and convert it to a particular format Connectors Outputs the encoded data to an external display Handles hotplug events Reads EDIDs - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 12/1

Allwinner display pipeline - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 13/1

DRM vs SoC pipeline - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 14/1

DRM Stack: KMS - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 15/1

DRM Stack: GEM - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 16/1

DRM Stack: CMA - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 17/1

DRM Stack: PRIME - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 18/1

Bringing display and 3D to the C.H.I.P computer GPU integration - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 19/1

Solutions The GPU found in most Allwinner SoCs is the Mali-400 from ARM (with a variable number of cores) There are two options to support that GPU: Lima Reversed engineered proof-of-concept Triggered the reverse engineering effort of the GPUs (freedreno, etnaviv, etc.) Development (closed to?) stopped two years ago ARM-Provided support Featureful Two parts: GPL kernel driver and proprietary OpenGL ES implementation - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 20/1

DRM Stack: GPU - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 21/1

Development Everything is provided by ARM on their website (if you re lucky) On the userspace side, you just need to put the library they provided on your system On the driver side, you need to create a platform glue that will deal with: Memory mapping Interrupts Clocks Reset lines Power Domains Basically everything needed for the GPU to operate properly on your SoC - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 22/1

X11 integration We need a DDX (Device Dependent X) driver xf86-video-modesetting is working on top of KMS and MESA (Gallium3D) ARM developped xf86-video-armsoc for SoC using a 3rd party GPU (Mali, PowerVR, Vivante, etc.) Relies on KMS for the display configuration, driver-specific ioctl for buffer allocations and vendor-provided OpenGL ES implementation Just have to write a small glue to use your driver allocator, and give some hints to X about what your hardware support (hw cursor, vblank, etc.) - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 23/1

Questions? Suggestions? Comments? Maxime Ripard maxime@bootlin.com Slides under CC-BY-SA 3.0 http://bootlin.com/pub/conferences/2016/elc/ripard-drm - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 24/1