AM335x-PSP 04.06.00.02 Features and Performance Guide

'''  Content is no longer maintained and is being kept for reference only! '''

= Document License =

This work is licensed under the Creative Commons Attribution-Share Alike 3.0 United States License. To view a copy of this license, visit http://creativecommons.org/licenses/by-sa/3.0/us/ or send a letter to Creative Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.

= Read This First = '''  Content is no longer maintained and is being kept for reference only!  All performance numbers provided in this document are gathered using AM335x BeagleBone Board with ARM running at 720MHz and DDR2 configured at 266MHz clock.'''

About This Manual
This document provides an overview and performance data for each of the device drivers which are part of the Linux PSP package supporting AM335x BeagleBone Board. Note that only a subset of the drivers may have actually been fully tested and verified in the package you are using. Please refer to the release notes provided with the package for information on which of the drivers have actually been verified. In the rest of the document, we will refer this setup as AM335x BeagleBone.

If You Need Assistance
For further information or to report any problems, contact http://community.ti.com/ or http://support.ti.com/

= Support Overview =

Boot Modes Supported
Green colored box in the table below means that the particular boot mode is supported on the device in the release.

NOTE These are supported boot modes in PSP software, the actual hardware may support many more boot modes than shown here. Please refer to hardware documentation for list of all supported boot modes.

U-Boot Support
U-Boot is the defacto bootloader for Linux kernel on ARM. The following features of U-Boot are supported in this release.

= Linux Kernel =

Kernel Virtual Memory Layout
The default AM335x kernel configuration, with "mem=128M" passed as boot argument, uses following Virtual Memory laout:  [   0.000000] Memory: 128MB = 128MB total [   0.000000] Memory: 124068k/124068k available, 7004k reserved, 0K highmem [   0.000000] Virtual kernel memory layout: [   0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB) [   0.000000]     fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB) [   0.000000]     DMA     : 0xffa00000 - 0xffe00000   (   4 MB) [   0.000000]     vmalloc : 0xc8800000 - 0xf8000000   ( 760 MB) [   0.000000]     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB) [   0.000000]     modules : 0xbf000000 - 0xc0000000   (  16 MB) [   0.000000]       .text : 0xc0008000 - 0xc0509000   (5124 kB) [   0.000000]       .init : 0xc0509000 - 0xc053e000   ( 212 kB) [   0.000000]       .data : 0xc053e000 - 0xc05887a0   ( 298 kB) [   0.000000]        .bss : 0xc05887c4 - 0xc05b4780   ( 176 kB)

= Boot-time measurement =

For boot-time measurement the following setup was used

The kernel image used had the following features enabled


 * NAND driver
 * Block devices
 * Network device support
 * I2C support
 * SPI support
 * GPIO support
 * WDT support
 * Sound card support
 * HID devices
 * USB support
 * MMC/SD/SDIO support
 * Loadable module support
 * Filesystem support for ext2, ext3, JFFS2 and NFS

The following was the kernel command line passed

console=ttyO0,115200n8 ip=dhcp earlyprink root=/dev/mmcblk0p2 rw rootfstype=ext3 rootwait

The total boot-time (ignoring the boot delays in the 2 stages of U-Boot) is ~21.74 secs

The break-up of the boot-time is as given below:


 * Booting the compressed kernel (calculated from the time U-Boot displays "## Booting..." to the prompt) : 21.24 secs
 * Reading the 2.3MB uImage from SD card : 0.4 secs
 * Misc time in U-Boot : 0.1 secs

= PSP Linux Drivers =

This section provides brief overview of the device drivers supported in the Linux PSP release.

Note: The constraints may vary across product releases. Please refer to the Release Notes accompanying the release for an updated list of constraints.

Device Driver List
The following table list the various device drivers supported and the device they are supported on. On detailed information on specific features or limitations of a pariticular driver, refer to the chapter catering to that driver in this document.

ALSA SoC Audio Driver
Abstract

This section an overview of the ALSA SoC audio driver features along with the throughput and CPU load numbers. For the architecture, installation, basic usage and sample applications (if any) please refer to the driver user guide.

Introduction
AM335x Audio driver complies to the Advanced Linux Sound Architecture (ALSA) System on Chip (SoC) framework (ASoC).

The ASoC framework splits an embedded audio system into three components:


 * Codec driver: The codec driver is generic and hardware independent code that configures the audio codec to provide audio capture and playback. It should contain no code that is specific to the target platform or machine.
 * Platform driver: The platform driver can be divided into audio DMA and SoC Digital Audio Interface (DAI) configuration and control. The platform driver only targets the SoC CPU and must have no board specific code.
 * Machine driver: The ASoC machine (or board) driver is the code that glues together the platform and codec drivers. It can contain codec and platform specific code. It registers the audio subsystem with the kernel as a platform device.

Following architecture diagram shows all the components and the interactions among them.



Driver Features
The driver supports the following features:


 * 1) Supports AIC3106 audio codec in ALSA SoC framework.
 * 2) Multiple sample rate support (8 KHz, 44.1 KHz and 48 KHz commonly used) for both capture and playback.
 * 3) Supports audio in stereo mode
 * 4) Supports simultaneous playback and record (full-duplex mode).
 * 5) Supports mixer interface for the audio codec

Features Not Supported

 * 1) OSS based applications, which use ALSA-OSS emulation layer, are not supported.
 * 2) Formats such as TDM, Left and Right Justified are currently not supported.
 * 3) Synthesizer and midi interfaces are not supported.

Constraints

 * 1) By default, codec is configured in master mode and McASP is used as slave. Testing of the audio sub-system is done in this configuration only.
 * 2) Sampling frequencies for playback and capture streams should be same.
 * 3) The audio driver does not allow opening the same stream (playback/capture) multiple times.

Supported System Calls
Refer ALSA project - the C library reference for API calls.

Supported IOCTLs
NA

Performance and Benchmarks
Performance and Benchmarks not available in this release.

Ethernet Driver
Abstract

This section provides an overview of the Ethernet driver features along with throughput and CPU load numbers. Ethernet driver follows standard Linux network interface Architecture.

Introduction
The Ethernet driver supports the Linux netdev interface.

Driver Features
The driver supports the following features:


 * 1) 10/100 Mbps mode of operation.
 * 2) Auto negotiation.
 * 3) Full duplex and half duplex mode of operation.
 * 4) Linux NAPI support
 * 5) Support for MII and RGMII interfaces to PHY
 * 6) This driver uses Timer 5 & 6 for CPSW Interrupt Pacing. Sharing this Timer with any other module will result in Ethernet pacing not working properly.

Features Not Supported

 * 1) Promiscuous mode of operation.
 * 2) Second switch port.
 * 3) IEEE 1588
 * 4) VLAN (Subscription common for all ports)
 * 5) Ethertool (Supports only Slave 0)
 * 6) Switch mode of operation
 * 7) 1G operation since PHY doesn't support.

Constraints
NA

Performance and Benchmarks
Supports the socket and related system calls in accordance with Linux architecture.

The performance numbers were captured using the iperf tool. Usage details are mentioned below:


 * iperf version 2.0.4
 * On PC Host invoke iperf in the server mode : "#iperf -s "
 * On the DUT iperf is invoked in client mode : "#iperf -c &lt;server ip&gt; -w &lt;window size&gt; -m -f M -d -t 60". This starts bi-directional traffic to the server for a duration of 60 seconds
 * The transfers are measured over a duration of 60Secs
 * Cross cable is used to measure performance.
 * Speed is set to 100Mbps

Graphical LCD (GLCD) Driver
Abstract

This chapter describes the GLCD driver architecture, driver features and performance numbers (throughput and CPU load).

Introduction
GLCD driver is based on Fbdev framework and it reuses da8xx-fb driver as LCDC IP is upgraded version of that found on OMAP-L138 SoC.

Driver Features
The driver supports the following features:


 * 1) Supports WVGA display through Fbdev framework.
 * 2) Supports display of ARGB:8888 images at max resolution 2048*2048, but pixel clock can be driven Max 150MHz.
 * 3) Supports getting and setting the variable screen information.
 * 4) Supports retrieving the fixed screen information.

Features Not Supported

 * 1) Brightness and color control ioctls not supported.

Constraints

 * 1) There is limit on Max pixel clock of 150MHz.

Supported System Calls
open, close, read, mmap, ioctl

Performance Benchmarks
Performance and Benchmarks not available in this release.

NAND Driver
Abstract

This chapter describes the NAND flash driver architecture, driver features and performance numbers (throughput and CPU load).

Introduction
The NAND driver is implemented as a character and block driver, compliant with the Linux MTD subsystem interface. It supports various NAND Flash chips (see file drivers/mtd/nand/nand_ids.c in Linux kernel sources). The NAND driver creates the device nodes for user space access (/dev/mtdblock0, /dev/mtdblock1, /dev/mtd0,/dev/mtd1 and so on.).

This figure illustrates the stack diagram of NAND flash driver in Linux.

Driver Features
The driver supports the following features:


 * 1) JFFS2 file system support
 * 2) Supports Read, Write and Erase
 * 3) Bad Block Management
 * 4) Polled Prefetch mode of transfer (enabled by default)
 * 5) SLC NAND

Features Not Supported

 * 1) BCH4/8 is not supported
 * 2) DMA Mode of operation

Constraints
NA

Supported System Calls
Supports the system call support proivided by Linux MTD interface viz. open, close, read, write, ioctl

Performance Benchmarks
Please refer MTD Test Setup before proceeding.

NAND Write/Read Performance
Performance and Benchmarks not available in this release.

SPI Flash Driver
Abstract

This chapter describes the SPI flash driver architecture, driver features and performance numbers (throughput and CPU load).

Introduction
SPI Flash driver is implemented as block driver and compliant with standard MTD driver. It supports various flash devices. The SPI driver creates device node for user space access (example, /dev/mtd1).

Driver Features
The driver supports the following features:


 * 1) PIO Mode of Operation are supported.

Features Not Supported

 * 1) DMA Mode of Operation not supported.

Constraints
NA

Supported System Calls
Supports the system call support proivided by MTD interface viz. open, close, read, write, ioctl

Performance Benchmarks
Performance and Benchmarks not available in this release.

MMC/SD Driver
Abstract

This chapter provides details on MMC/SD driver along with throughput and CPU load numbers.

Introduction
The MMC controller provides an interface to external MMC cards that follow the MMC specification v4.0. The MMC driver is implemented as a block driver. Block device nodes(such as /dev/mmcblockp1, /dev/mmcblockp2) are created for user space access.

Driver Features
The driver supports the following features:


 * 1) MMC/SD native protocol command/response set
 * 2) Single/multiple block data transfers
 * 3) Linux file system and generic MMC layer abstract details of block devices (MMC)
 * 4) High-speed (SDv1.1) and High Capacity (SDv2.0) cards
 * 5) Support for 4 bit modes
 * 6) Support for card detect and Write protect features
 * 7) DMA and polled mode for data transfer operations

Features Not Supported

 * 1) Support for 1-bit, 8-bit mode of operation.
 * 2) SPI mode of operation

Constraints

 * 1) MMC/SD cards should not be removed when the mount operation is in progress. If done so, data integrity cannot be guaranteed.

Supported System Calls
open,close,read,write

Supported IOCTLs
None

Performance and Benchmarks
IMPORTANT The performance numbers can be severely affected if the media is mounted in sync mode. Hot plug scripts in the filesystem mount removable media in sync mode to ensure data integrity. For performance sensitive applications, umount the auto-mounted filesystem and re-mount in async mode.

Please refer MMC/SD Test Setup before proceeding.

EXT2 file system
The performance numbers were captured using the following:


 * SD Card (Sandisk, MicroSDHC, Class 4, 8GB)
 * File System: ext2
 * Partition was mounted with async option

VFAT file system
The performance numbers were captured using the following:


 * SD Card (Sandisk, MicroSDHC, Class 4, 8GB)
 * File System: vfat
 * Partition was mounted with async option

UART Driver
Abstract

This chapter provides details on UART driver.

Introduction
The UART driver is implemented as a serial driver, and can be accessed from user space as /dev/ttyOX(X=0-5)

Driver Features

 * None

Features Not Supported

 * None

Constraints
NA

Supported System Calls
open,close,read,write,ioctl

Performance and Benchmarks
Performance and Benchmarks not available in this release.

I2C Driver
Abstract

This chapter provides details on I2C driver.

Introduction
The I2C peripheral is compliant with the Philips Semiconductor I2C-bus specification version 2.1. The I2C driver is implemented as a serial driver. The I2C driver can be accessed from the user space as /dev/i2c/0.

Driver Features
The driver supports the following features:


 * 1) 7-bit addressing mode
 * 2) Fast mode
 * 3) Interrupt mode

Features Not Supported

 * 1) 7-bit and 10-bit addressing combined format is not supported
 * 2) DMA mode is not supported

Constraints
NA

Supported System Calls
open,close,read,write,ioctl

Performance and Benchmarks
Performance and Benchmarks not available in this release.

EDMA Driver
Abstract

This chapter provides details on EDMA driver along with throughput and CPU load numbers.

Introduction
The EDMA controller handles all data transfers between the level-two (L2) cache/memory controller and the device peripherals. On AM335x EDMA has has one instance of Channel controller. Each EDMA instance supports up to 32-dma channels and 8 QDMA channels. The EDMA consists of a scalable Parameter RAM (PaRAM) that supports flexible ping-pong, circular buffering, channel-chaining, auto-reloading, and memory protection. The EDMA allows movement of data to/from any addressable memory spaces, including internal memory (L2 SRAM), peripherals, and external memory.

The EDMA driver exposes only the kernel level API's. This driver is used as a utility by other drivers for data transfer.

Driver Features
The driver supports the following features:


 * 1) Request and Free DMA channel
 * 2) Programs DMA channel
 * 3) Start and Synchronize with DMA transfers
 * 4) Provides DMA transaction completion callback to applications
 * 5) Multiple instances of EDMA driver on a single processor

Features Not Supported

 * 1) QDMA is not supported.
 * 2) Reservation of resources (channels and PaRAMs) for usage from other masters is not supported.

Constraints
NA

Supported System Calls
None

Supported IOCTLs
None

Performance and Benchmarks
NA

Introduction
Touchscreen controller on AM335x is an 8 channel general purpose ADC, with optional support for interleaving Touch Screen conversions for a 4-wire, 5-wire, or 8-wire resistive panel. A resistive touchscreen operates by applying a volatge across a resistive network and measuring the change in resistance at a given point on the matrix where the screen is touched by an input (stylus or finger). The change in the resistance ratio marks the location on the touchscreen.

Driver Features
The driver supports the following features:


 * Resistive touchscreen
 * Hardware synchronized one shot mode
 * Programmable Open delay/Sampling delay before sampling each channel
 * Programmable averaging of input samples - 16
 * Support for servicing FIFOs via CPU.
 * ADC sampled data is 12-bit wide.

Features Not Supported

 * DMA Request event.
 * Pressure(z) measurements not reported.

Constraints
NA

Supported System Calls
None

Supported IOCTLs
None

Performance and Benchmarks
NA

Watchdog(WDT) Driver
Abstract

This chapter provides details on Watchdog timer driver.

Introduction
AM335x has a 32-bit watchdog timer which can be used to reset the hardware in case of a software fault. Once the /dev/watchdog is opened, it will reboot the system unless a user space daemon resets the timer at regular intervals within a certain timeout period. If watchdog device node is closed before timeout also reboot won't happen. The WDT driver is registered as a misc device. Default timeout of this driver is 60 seconds.

Driver Features
The driver supports the following features:


 * 1) Supports IOCTLs to set/get the timeout value, ping the watchdog &amp; query the watchdog structure info.
 * 2) Driver can be built as a loadable module and inserted dynamically.

Supported System Calls
open, close, write, ioctl, read

Performance and Benchmarks
NA

USB Driver
Abstract

This chapter provides details on MUSB drivers along with throughput and CPU load numbers.

This chapter describes the MUSB driver architecture, features supported/not supported, constraints and performance numbers.

Description
The MUSB driver is implemented on top of Mentor OTG IP version 2.0 which supports all the speeds (High, Full and Low (host mode only)). On AM335x, MUSB uses CPPI 4.1 DMA for all the transfers.

Driver Features
The driver supports the following features:

Host Mode


 * 1) Human Interface Class (HID)
 * 2) Mass Storage Class (MSC)
 * 3) Hub Class
 * 4) USB Video Class (UVC)
 * 5) USB Audio Class (UAC)
 * 6) USB CDC HOST (USBNET)

Gadget mode


 * 1) Mass Storage Class (MSC)
 * 2) USB Networking - RNDIS/CDC

Features Not Supported
OTG

Driver Features
The driver supports the following features:


 * 1) DMA mode
 * 2) PIO mode

Features Not Supported
None

Constraints
NA

Supported System Calls
open, close, read, write, ioctl

Supported IOCTLS
None

Performance Benchmarks
IMPORTANT For Mass-storage applications, the performance numbers can be severely affected if the media is mounted in sync mode. Hot plug scripts in the filesystem mount removable media in sync mode to ensure data integrity. For performance sensitive applications, umount the auto-mounted filesystem and re-mount in async mode.

USB MSC (MUSB) Host mode DMA EXT2 File System Performance
The performance numbers are captured using the following.


 * 1) Hard disk: Mobile Disk
 * 2) File format: ext2

USB MSC (MUSB) Host mode DMA VFAT File System Performance
The performance numbers are captured using the following.


 * 1) Hard disk: IOMEGA USB HDD
 * 2) File format: VFAT

Description
This figure illustrates the stack diagram of the system with USB File Storage Gadget driver

Driver Features
The driver supports the following features:


 * 1) DMA mode
 * 2) PIO mode
 * 3) File backed storage driver was tested with SD media as the storage medium

Features Not Supported
None

Constraints
NA

Supported System Calls
NA

Supported IOCTLS
NA

Performance Benchmarks
The performance numbers are captured in DMA Mode using SATA HDD as file storage gadget media exposing as removable media to windows-xp over USB. The SATA HDD is formatted using the NTFS on windows-xp. SATA HDD used - Western Digital 500GB drive
 * 1) insmod g_mass_storage.ko file=/dev/sda

For test setup details refer to msc-device setup

Description
The CDC RNDIS gadget driver that is used to send standard Ethernet frames using USB. The driver will create an Ethernet device by the name usb0.

Driver Features
The driver supports the following features:


 * 1) DMA mode
 * 2) PIO mode
 * 3) 10/100 Mbps speed.

Features Not Supported
None

Constraints
NA

Supported System Calls
open, close, read, write, ioctl

Supported IOCTLS
None

Performance Benchmarks
Performance benchmarks were collected using the Iperf tool and default options were used to collect the throughput numbers.

Description
The event sub system creates /dev/input/event* devices with the help of mdev.

Driver Features
The driver supports the following features:


 * 1) DMA mode
 * 2) PIO mode
 * 3) USB Mouse and Keyboards that conform to the USB HID specifications

Features Not Supported
None

Constraint
NA

Supported System Calls
NA

Supported IOCTLS
NA

Performance Benchmarks
NA

Description
USB camera, speaker and mic uses isochronouse transfers. USB Video Class (UVC) is used by most of the USB cameras to capture image.

Driver Features
The driver supports the following features:


 * 1) DMA mode
 * 2) PIO mode
 * 3) Support for USB Audio and video class(UVC class)

Features Not Supported
None

Constraint
NA

Supported System Calls
NA

Supported IOCTLS
NA

Performance Benchmarks
NA

Description
MUSB controller on DaVinci supports USB On The Go (OTG). OTG protocol enables runtime role switch between USB host and device. This is achived using Session Request Protocol (SRP) and Host Negotiation Protocol (HNP). OTG driver is tested with OPT (OTG Protocol Tester).

Driver Features
The driver supports the following features:

Features Not Supported
OTG

Constraint
NA

Supported System Calls
NA

Supported IOCTLS
NA

Performance Benchmarks
NA