Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · ·...
Transcript of Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · ·...
![Page 1: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/1.jpg)
Pete Graner – Ubuntu Kernel Manager&
David Mandala – Ubuntu ARM ManagerCanonical USA
Ubuntu on ARM
![Page 2: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/2.jpg)
Agenda
● Why ARM?● ARM Architecture Primer● Board Bring Up● Ubuntu on ARM● Native Building● Applications● Release Cycle● Questions
![Page 3: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/3.jpg)
Why ARM
● Very low power consumption● Day to multi-day
battery life
● Smaller designs● Lighter weight● Cooler● Simple Design
![Page 4: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/4.jpg)
Why ARM?
● With the advent of ARMv7 Cortex A8 and Cortex A9 devices there will be devices that can use Ubuntu Linux for ARM.● Computers: Notebooks – Netbooks – Servers● Smart Phones (Nokia N900, Apple iPhones)● Home Entertainment: Televisions with Internet
access (Sony devices and others)● Automotive Entertainment
![Page 5: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/5.jpg)
ARM Architecture
● 32-bit reduced instruction set computer (RISC) processor
● developed by ARM Holdings● ARM == Advanced RISC Machine || Acorn
RISC Machine● The ARM architecture is the most widely used
32-bit processor family● 98% of all mobile phones use at least one
processor
![Page 6: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/6.jpg)
ARM Background
● In 2009, ARM processors accounted for 90% of all embedded 32-bit RISC processors
● ARM processors are used in: PDAs, mobile phones, digital media, music players, hand-held game consoles, calculators, hard drives and routers
● The ARM architecture is licensable:● Apple Inc., Atmel, Broadcom, Cirrus Logic, Digital Equipment
Corporation, Freescale, Intel, LG, Marvell, NEC, NVIDIA, NXP, Oki, Qualcomm, Samsung, Sharp, ST Microelectronics, Symbios Logic, Texas Instruments, VLSI Technology, Yamaha ...
![Page 7: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/7.jpg)
ARM Background
● ARM processors are developed by ARM and by ARM licensees
● Prominent examples of ARM processor families include the ARM7, ARM9, ARM11 and Cortex
● Examples of ARM processors developed by major licensees include: ● Freescale's i.MX● Marvell (formerly Intel) Xscale & Dove● NVIDIA's Tegra● Qualcomm's Snapdragon● Texas Instruments OMAP
![Page 8: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/8.jpg)
Types of ARM Processors
● Most devices have multiple ARM processors● Application Processor
– general-purpose CPU with a memory-management unit (MMU) capable of supporting a high-level operating system
● Baseband Processor– performs the basic communications functions required to
connect to a cellular network.– contains a CPU that supervises the baseband functions,
using a DSP or hard-wired logic
![Page 9: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/9.jpg)
Types of ARM Processors (cont)
● Mobile Multimedia Processor (MMP)● coprocessor that offloads multimedia functions from
the host processor● Examples include: audio & video processing,
(camera) image processing, and 2D/3D/vector-graphics acceleration
![Page 10: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/10.jpg)
ARM in the Past
● ARMv1 – ARMv3
● Obsolete: Not powerful enough to run Linux● ARMv4
● Some very limited Linux BSP's and some level of support in Debian without X. Heavily used in the embedded space with RTOS's
● ARMv5-ARMv6
● Powerful enough for phones and some smart phones, Limited Linux, and other RTOS's used.
![Page 11: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/11.jpg)
ARM of Today
● ARMv7● Powerful enough for smart phones and general
purpose computing, Desktop, Note/Netbooks, and low power servers.
● Need a well supported general purpose operating system to support use cases.
![Page 12: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/12.jpg)
Generic Mobile Processor
Crossbar Interconnect
MainCPU
VideoEngine
2D/3DEngine
DisplayControl
Frame BufferL2
SystemI/O
AudioEngine
ImagingEngine
MemoryControl
USB, Serial Audio I/O Camera SD/MMC/ATA
SDRAM
FLASH
LCD
TV OUT
![Page 13: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/13.jpg)
ARM Fun Facts
● ARM Designs are called “System on Chip” or SoC
● ARM does not have BIOS
● Currently requires a custom kernel per SoC
● Uboot & Redboot are typical bootloaders
● No PCI bus or bridges (North or South)
![Page 14: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/14.jpg)
ARM Board Bring Up
● Involves 3 steps● Receive BSP from SoC Vendor● Merge/Forward/Backport SoC specific patch delta
into the Ubuntu kernel tree● Test/Bug Fix/
● Wash, rinse, repeat● Work with SoC vendor on upstreaming patches
![Page 15: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/15.jpg)
Challenges with ARM Bring Up
● No BIOS to do board set up● This leads SoC vendors to do board set up in
various “nonstandard ways”● Long term solution is Device Tree
● Device tree uses a config table that is passed to the kernel at boot time
● CPU feature sets are often broken in early silicon● Find workaround in the kernel● Or respin the silicon
![Page 16: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/16.jpg)
Ubuntu Architectures
● Ubuntu Supported● Amd64● Armel● I386
● Community Supported● Powerpc● Sparc● Ia64
![Page 17: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/17.jpg)
Ubuntu on ARM ● Started 18 months ago, supporting one
System on Chip (SoC): Freescale iMX51● 12 months ago expanded to two SoC's:
Freescale iMX51 and Marvell dove.● Releasing this month supporting three SoC's:
Freescale iMX51, Marvell Dove, and Texas Instruments OMAP 3530 and beyond.
![Page 18: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/18.jpg)
Ubuntu Flavours built for ARM
● Gnome Desktop – built for the first two releases of ARM, available in this release but not as an image.
● Netbook – Build for the first time for this release. Both 2D and 3D versions.● 2D uses the enlightenment foundation libraries● 3D requires Open GL accelerated drivers installed and
working
● Server images built but not tested.● Community supplied Kubuntu Netbook Remix.
![Page 19: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/19.jpg)
Native Building
● All versions of Ubuntu are native built, it's a “feature” of the Ubuntu build system
● Derived from the Debian build system that works the same way
– Many .deb packages are very hard to use cross compilation on, they either self generate code or have tests that have to be run on the actual hardware
● In order to build an architecture you need actual hardware for that architecture
![Page 20: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/20.jpg)
Compilation Issues
● Tool chain issues for the 10.04 release we are compiling ARMv7 with Thumb 2
● ARMv7 is new● Thumb 2 is new
– Applications with ARM Assembly code have needed touch ups.
● Ubuntu contains a mix of ARMv7 code and Thumb 2 this can cause issues.
● For a function return ARMv4 would be “MOV pc lr”, it not safe in a mixed ARM/Thumb 2 code base so “BX lr” is preferred
![Page 21: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/21.jpg)
Application Choices
● Most ARMv7 platforms to date have ~256M of RAM and no fast IO for hard disks.
● Easy to run out of RAM if using in a desktop context● Slow Swap
● Currently most ARMv7 images use a non-accelerated frame buffer. This leads to some issues.
● Slow scrolling● Slow screen update● No 3D
![Page 22: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/22.jpg)
Release Cycle – Ubuntu on ARM
● Releases take place every six months with the rest of Ubuntu
● Developer releases:
● Ideal for fast moving projects or developers, not always well tested but early cutting edge release, OMAP this cycle will be a developers release.
● Standard releases:
● Maintained with security patches for 18 months Free
● Long Term Supported releases:
● No ARM release has achieved LTS status yet, perhaps by next LTS cycle
![Page 23: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/23.jpg)
Release Cycle – Ubuntu on ARM
● Releases take place every six months with the rest of Ubuntu
● Developer releases:
● Ideal for fast moving projects or developers, not always well tested but early cutting edge release, OMAP this cycle will be a developers release.
● Standard releases:
● Maintained with security patches for 18 months Free
● Long Term Supported releases:
● No ARM release has achieved LTS status yet, perhaps by next LTS cycle
![Page 24: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/24.jpg)
Release Cycle
![Page 25: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/25.jpg)
Refereces
● https://wiki.ubuntu.com/● https://wiki.ubuntu.com/ARM/● https://wiki.ubuntu.com/ARM/Thumb2PortingHowto
![Page 26: Ubuntu on ARM - Canonicalpeople.canonical.com/~pgraner/talks/TLF-2010/Ubuntu … · · 2010-04-13use Ubuntu Linux for ARM. ... Device tree uses a config table that is passed to](https://reader036.fdocuments.net/reader036/viewer/2022062413/5afdf05a7f8b9a864d8e3a25/html5/thumbnails/26.jpg)
Questions?