1.1.2Definitions, Acronyms, and Abbreviations........................................................................................................17
3.6.1.1API for GPIO.....................................................................................................................................37
5.3.7Enabling An EPDC Splash Screen.....................................................................................................................49
5.6.2Structures and Defines.......................................................................................................................................55
6.6.2Structures and Defines.......................................................................................................................................68
7.3.1Key Data Structs................................................................................................................................................71
10.3.1 Linux Menu Configuration Options...................................................................................................................83
10.4 Unit Test..........................................................................................................................................................................83
11.3.1 X Windows Acceleration Architecture..............................................................................................................86
11.3.2 i.MX 6 Driver for X-Windows System..............................................................................................................87
11.3.3 xorg.conf for i.MX 6..........................................................................................................................................89
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Freescale Semiconductor, Inc.7
Section numberTitlePage
11.3.4 Setup X-Windows System Acceleration............................................................................................................90
12.2.2 Video for Linux 2 (V4L2) APIs.........................................................................................................................94
12.4 Linux Menu Configuration Options................................................................................................................................96
13.4 Linux Menu Configuration Options................................................................................................................................98
14.1.3 Menu Configuration Options.............................................................................................................................100
14.1.5 Unit Test.............................................................................................................................................................101
15.4.3 Menu Configuration Options.............................................................................................................................107
16.2 Menu Configuration Options..........................................................................................................................................110
17.2 Menu Configuration Options..........................................................................................................................................114
18.3.2 Menu Configuration Options.............................................................................................................................116
18.4 Unit Test..........................................................................................................................................................................117
19.2.5 Menu Configuration Options.............................................................................................................................121
20.2.2 Keeping Alive in the Power Off State...............................................................................................................124
20.3.2 Menu Configuration Options.............................................................................................................................125
Chapter 21
Advanced Linux Sound Architecture (ALSA) System on a Chip (ASoC) Sound Driver
21.4.5 Menu Configuration Options.............................................................................................................................134
21.5 Unit Test..........................................................................................................................................................................134
21.5.1 Stereo CODEC Unit Test...................................................................................................................................134
Chapter 22
SPI NOR Flash Memory Technology Device (MTD) Driver
22.1.5 Menu Configuration Options.............................................................................................................................139
23.2.2 Menu Configuration Options.............................................................................................................................145
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
24.1.1 I2C Bus Driver Overview..................................................................................................................................149
24.3.2 Menu Configuration Options.............................................................................................................................152
25.2.1 SPI Sub-System in Linux...................................................................................................................................156
25.2.3 Standard Operations...........................................................................................................................................157
25.3.2 Menu Configuration Options.............................................................................................................................160
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
26.2.3 Menu Configuration Options.............................................................................................................................166
26.3 System WakeUp..............................................................................................................................................................169
26.3.1 USB Wakeup usage...........................................................................................................................................169
26.3.2 How to Enable USB WakeUp System Ability...................................................................................................169
26.3.3 WakeUp Events Supported by USB..................................................................................................................170
26.3.4 How to Close the USB Child Device Power......................................................................................................171
27.2.3 Menu Configuration Options.............................................................................................................................176
27.3.2 Getting a MAC Address.....................................................................................................................................178
28.3.1 Menu Configuration Options.............................................................................................................................182
29.1.6 Menu Configuration Options.............................................................................................................................188
30.2.2 Menu Configuration Options.............................................................................................................................190
31.2.1 Architecture Specific Components....................................................................................................................194
31.2.5 Post Profiling Tools...........................................................................................................................................196
31.3.2 Menu Configuration Options.............................................................................................................................196
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Freescale Semiconductor, Inc.15
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
16Freescale Semiconductor, Inc.
Chapter 1
About This Book
1.1Audience
This document is targeted to individuals who will port the i.MX Linux BSP to customerspecific products.
The audience is expected to have a working knowledge of the Linux 3.0 kernel internals,
driver models, and i.MX processors.
1.1.1Conventions
This document uses the following notational conventions:
• Courier monospaced type indicate commands, command parameters, code examples,
and file and directory names.
• Italic type indicates replaceable command or function parameters.
• Bold type indicates function names.
1.1.2Definitions, Acronyms, and Abbreviations
The following table defines the acronyms and abbreviations used in this document.
Definitions and Acronyms
TermDefinition
ADCAsynchronous Display Controller
address
translation
APIApplication Programming Interface
®
ARM
Freescale Semiconductor, Inc.17
Address conversion from virtual domain to physical domain
Advanced RISC Machines processor architecture
Table continues on the next page...
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Audience
TermDefinition
AUDMUXDigital audio MUX-provides a programmable interconnection for voice, audio, and synchronous data routing
between host serial interfaces and peripheral serial interfaces
BCDBinary Coded Decimal
busA path between several devices through data lines
bus loadThe percentage of time a bus is busy
CODECCoder/decoder or compression/decompression algorithm-used to encode and decode (or compress and
decompress) various types of data
CPUCentral Processing Unit-generic term used to describe a processing core
CRCCyclic Redundancy Check-Bit error protection method for data communication
CSICamera Sensor Interface
DFSDynamic Frequency Scaling
DMADirect Memory Access-an independent block that can initiate memory-to-memory data transfers
DPMDynamic Power Management
DRAMDynamic Random Access Memory
DVFSDynamic Voltage Frequency Scaling
EMIExternal Memory Interface-controls all IC external memory accesses (read/write/erase/program) from all the
masters in the system
EndianRefers to byte ordering of data in memory. Little endian means that the least significant byte of the data is
stored in a lower address than the most significant byte. In big endian, the order of the bytes is reversed
EPITEnhanced Periodic Interrupt Timer-a 32-bit set and forget timer capable of providing precise interrupts at
regular intervals with minimal processor intervention
FCSFrame Checker Sequence
FIFOFirst In First Out
FIPSFederal Information Processing Standards-United States Government technical standards published by the
National Institute of Standards and Technology (NIST). NIST develops FIPS when there are compelling
Federal government requirements such as for security and interoperability but no acceptable industry
standards
FIPS-140Security requirements for cryptographic modules-Federal Information Processing Standard 140-2(FIPS 140-2)
is a standard that describes US Federal government requirements that IT products should meet for Sensitive,
but Unclassified (SBU) use
FlashA non-volatile storage device similar to EEPROM, where erasing can be done only in blocks or the entire chip.
Flash pathPath within ROM bootstrap pointing to an executable Flash application
FlushProcedure to reach cache coherency. Refers to removing a data line from cache. This process includes
cleaning the line, invalidating its VBR and resetting the tag valid indicator. The flush is triggered by a software
command
GPIOGeneral Purpose Input/Output
hashHash values are produced to access secure data. A hash value (or simply hash), also called a message
digest, is a number generated from a string of text. The hash is substantially smaller than the text itself, and is
generated by a formula in such a way that it is extremely unlikely that some other text produces the same hash
value.
I/OInput/Output
ICEIn-Circuit Emulation
IPIntellectual Property
ISRInterrupt Service Routine
Table continues on the next page...
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
18Freescale Semiconductor, Inc.
Chapter 1 About This Book
TermDefinition
JTAGJTAG (IEEE Standard 1149.1) A standard specifying how to control and monitor the pins of compliant devices
on a printed circuit board
KillAbort a memory access
KPPKeyPad Port-16-bit peripheral used as a keypad matrix interface or as general purpose input/output (I/O)
lineRefers to a unit of information in the cache that is associated with a tag
LRULeast Recently Used-a policy for line replacement in the cache
MMUMemory Management Unit-a component responsible for memory protection and address translation
MPEGMoving Picture Experts Group-an ISO committee that generates standards for digital video compression and
audio. It is also the name of the algorithms used to compress moving pictures and video
MPEG
standards
MQSPIMultiple Queue Serial Peripheral Interface-used to perform serial programming operations necessary to
NAND Flash Flash ROM technology-NAND Flash architecture is one of two flash technologies (the other being NOR) used
NOR FlashSee NAND Flash
PCMCIAPersonal Computer Memory Card International Association-a multi-company organization that has developed
physical
address
PLLPhase Locked Loop-an electronic circuit controlling an oscillator so that it maintains a constant phase angle (a
RAMRandom Access Memory
RAM pathPath within ROM bootstrap leading to the downloading and the execution of a RAM application
RGBThe RGB color model is based on the additive model in which Red, Green, and Blue light are combined to
RGBARGBA color space stands for Red Green Blue Alpha. The alpha channel is the transparency channel, and is
RNGARandom Number Generator Accelerator-a security hardware module that produces 32-bit pseudo random
ROMRead Only Memory
ROM
bootstrap
RTICReal-Time Integrity Checker-a security hardware module
SCCSeCurity Controller-a security hardware module
SDMASmart Direct Memory Access
SDRAMSynchronous Dynamic Random Access Memory
SoCSystem on a Chip
SPBAShared Peripheral Bus Arbiter-a three-to-one IP-Bus arbiter, with a resource-locking mechanism
Several standards of compression for moving pictures and video:
• MPEG-1 is optimized for CD-ROM and is the basis for MP3
• MPEG-2 is defined for broadcast video in applications such as digital television set-top boxes and DVD
• MPEG-3 was merged into MPEG-2
• MPEG-4 is a standard for low-bandwidth video telephony and multimedia on the World-Wide Web
configure radio subsystems and selected peripherals
in memory cards such as the Compact Flash cards. NAND is best suited to flash devices requiring high
capacity data storage. NAND flash devices offer storage space up to 512-Mbyte and offers faster erase, write,
and read capabilities over NOR architecture
a standard for small, credit card-sized devices, called PC Cards. There are three types of PCMCIA cards that
have the same rectangular size (85.6 by 54 millimeters), but different widths
The address by which the memory in the system is physically accessed
lock) on the frequency of an input, or reference, signal
create other colors. The abbreviation RGB comes from the three primary colors in additive light models
unique to this color space. RGBA, like RGB, is an additive color space, so the more of a color placed, the
lighter the picture gets. PNG is the best known image format that uses the RGBA color space
numbers as part of the security module
Internal boot code encompassing the main boot flow as well as exception vectors
Table continues on the next page...
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Freescale Semiconductor, Inc.19
Audience
TermDefinition
SPISerial Peripheral Interface-a full-duplex synchronous serial interface for connecting low-/medium-bandwidth
external devices using four wires. SPI devices communicate using a master/slave relationship over two data
lines and two control lines: Also see SS, SCLK, MISO, and MOSI
SRAMStatic Random Access Memory
SSISynchronous-Serial Interface-standardized interface for serial data transfer
TBDTo Be Determined
UARTUniversal Asynchronous Receiver/Transmitter-asynchronous serial communication to external devices
UIDUnique ID-a field in the processor and CSF identifying a device or group of devices
USBUniversal Serial Bus-an external bus standard that supports high speed data transfers. The USB 1.1
specification supports data transfer rates of up to 12 Mb/s and USB 2.0 has a maximum transfer rate of 480
Mbps. A single USB port can be used to connect up to 127 peripheral devices, such as mice, modems, and
keyboards. USB also supports Plug-and-Play installation and hot plugging
USBOTGUSB On The Go-an extension of the USB 2.0 specification for connecting peripheral devices to each other.
USBOTG devices, also known as dual-role peripherals, can act as limited hosts or peripherals themselves
depending on how the cables are connected to the devices, and they also can connect to a host PC
wordA group of bits comprising 32-bits
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
20Freescale Semiconductor, Inc.
Chapter 2
Introduction
2.1Overview
The i.MX family Linux Board Support Package (BSP) supports the Linux Operating
System (OS) on the following processor:
• i.MX 6SoloLite Applications Processor
The purpose of this software package is to support Linux on the i.MX 6SoloLite family
of Integrated Circuits (ICs) and their associated platforms. It provides the necessary
software to interface the standard open-source Linux kernel to the i.MX hardware. The
goal is to enable Freescale customers to rapidly build products based on i.MX devices
that use the Linux OS.
The BSP is not a platform or product reference implementation. It does not contain all of
the product-specific drivers, hardware-independent software stacks, Graphical User
Interface (GUI) components, Java Virtual Machine (JVM), and applications required for
a product. Some of these are made available in their original open-source form as part of
the base kernel.
The BSP is not intended to be used for silicon verification. While it can play a role in
this, the BSP functionality and the tests run on the BSP do not have sufficient coverage to
replace traditional silicon verification test suites.
2.1.1Software Base
The i.MX BSP is based on version 3.0.35 of the Linux kernel from the official Linux
kernel web site (http://www.kernel.org ). It is enhanced with the features provided by
Freescale.
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Freescale Semiconductor, Inc.21
Overview
2.1.2Features
Table below describes the features supported by the Linux BSP for specific platforms.
Table 2-1. Linux BSP Supported Features
FeatureDescriptionChapter SourceApplicable
Platform
Machine Specific Layer
MSLMachine Specific Layer (MSL) supports interrupts,
Timer, Memory Map, GPIO/IOMUX, SPBA, SDMA.
• Interrupts GIC: The linux kernel contains common
ARM GIC interrupts handling code.
• Timer (GPT): The General Purpose Timer (GPT)
is set up to generate an interrupt as programmed
to provide OS ticks. Linux facilitates timer use
through various functions for timing delays,
measurement, events, alarms, high resolution
timer features, and so on. Linux defines the MSL
timer API required for the OS-tick timer and does
not expose it beyond the kernel tick
implementation.
• GPIO/EDIO/IOMUX: The GPIO and EDIO
components in the MSL provide an abstraction
layer between the various drivers and the
configuration and utilization of the system,
including GPIO, IOMUX, and external board I/O.
The IO software module is board-specific, and
resides in the MSL layer as a self-contained set
of files. I/O configuration changes are centralized
in the GPIO module so that changes are not
required in the various drivers.
• SPBA: The Shared Peripheral Bus Arbiter
(SPBA) provides an arbitration mechanism
among multiple masters to allow access to the
shared peripherals. The SPBA implementation
under MSL defines the API to allow different
masters to take or release ownership of a shared
peripheral.
SDMA APIThe Smart Direct Memory Access (SDMA) API driver
controls the SDMA hardware. It provides an API to
other drivers for transferring data between MCU, DSP
and peripherals. . The SDMA controller is responsible
for transferring data between the MCU memory space,
peripherals, and the DSP memory space. The SDMA
API allows other drivers to initialize the scripts, pass
parameters and control their execution. SDMA is based
on a microRISC engine that runs channel-specific
scripts.
Low-level PM
Drivers
The low-level power management driver is responsible
for implementing hardware-specific operations to meet
power requirements and also to conserve power on the
Table continues on the next page...
Machine Specific Layer (MSL)All
Smart Direct Memory Access
(SDMA) API
Low-level Power Management
(PM) Driver
i.MX
6SoloLite
i.MX
6SoloLite
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
22Freescale Semiconductor, Inc.
Chapter 2 Introduction
Table 2-1. Linux BSP Supported Features (continued)
FeatureDescriptionChapter SourceApplicable
development platforms. Driver implementations are
often different for different platforms. It is used by the
DPM layer.
CPU Frequency
Scaling
DVFSThe Dynamic Voltage Frequency Scaling (DVFS)
Multimedia Drivers
LCDThe LCD interface driver supports the Samsung
EPDCThe Electrophoretic Display Controller (EPDC) is a
SPDCSPDC is a direct-drive active matrix EPD controller
ALSA SoundThe Advanced Linux Sound Architecture (ALSA) is a
Memory Drivers
SPI NOR MTDThe SPI NOR MTD driver provides the support to the
Input Device Drivers
Networking Drivers
ENETThe ENET Driver performs the full set of IEEE 802.3/
The CPU frequency scaling device driver allows the
clock speed of the CPUs to be changed on the fly.
device driver allows simple dynamic voltage frequency
scaling. The frequency of the core clock domain and
the voltage of the core power domain can be changed
on the fly with all modules continuing their normal
operations.
LMS430xx 4.3" WQVGA LCD panel.
direct-drive active matrix EPD controller designed to
drive E Ink EPD panels supporting a wide variety of
TFT backplanes.
designed to drive Sipix panel for E-Book application.
The SPDC provides control signals for the source driver
and gate drivers. This IP provides a high performance,
low cost solution for SiPix EPDs (Electronic Paper
Display).
a unique API, which are implemented as a dmaengine
client that smooths over the details of different
hardware offload engine implementations.
sound driver that provides ALSA and OSS compatible
applications with the means to perform audio playback
and recording functions. ALSA has a user-space
component called ALSAlib that can extend the features
of audio hardware by emulating the same in software
(user space), such as resampling, software mixing,
snooping, and so on. The ASoC Sound driver supports
stereo CODEC playback and capture through SSI.
Atmel data Flash using the SPI interface.
Ethernet CSMA/CD media access control and channel
interface functions. The FEC requires an external
interface adaptor and transceiver function to complete
SPI NOR Flash Memory
Technology Device (MTD) Driver
Fast Ethernet Controller (FEC)
Driver
i.MX
6SoloLite
i.MX
6SoloLite
6SoloLite
i.MX
6SoloLite
i.MX
6SoloLite
6SoloLite
6SoloLite
i.MX
6SoloLite
i.MX
6SoloLite
Platform
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Freescale Semiconductor, Inc.23
Overview
Table 2-1. Linux BSP Supported Features (continued)
FeatureDescriptionChapter SourceApplicable
the interface to the Ethernet media. It supports half or
full-duplex operation on 10M\100M related Ethernet
networks.
Bus Drivers
I2CThe I2C bus driver is a low-level interface that is used
to interface with the I2C bus. This driver is invoked by
the I2C chip driver; it is not exposed to the user space.
The standard Linux kernel contains a core I2C module
that is used by the chip driver to access the bus driver
to transfer data over the I2C bus. This bus driver
supports:
• Compatibility with the I2C bus standard
• Bit rates up to 400 Kbps
• Standard I2C master mode
• Power management features by suspending and
resuming I2C.
CSPIThe low-level Enhanced Configurable Serial Peripheral
Interface (ECSPI) driver interfaces a custom, kernelspace API to both ECSPI modules. It supports the
following features:
USBThe USB driver implements a standard Linux driver
WatchDogThe Watchdog Timer module protects against system
MXC PWM driver The MXC PWM driver provides the interfaces to access
The MMC/SD/SDIO Host driver implements the
standard Linux driver interface to eSDHC.
(UART) driver interfaces the Linux serial driver API to
all of the UART ports. A kernel configuration parameter
gives the user the ability to choose the UART driver
and also to choose whether the UART should be used
as the system console.
interface to the ARC USB-OTG controller.
failures by providing an escape from unexpected hang
or infinite loop situations or programming errors. This
WDOG implements the following features:
• Generates a reset signal if it is enabled but not
serviced within a predefined time-out value
• Does not generate a reset signal if it is serviced
within a predefined time-out value
MXC PWM signals
Inter-IC (I2C) Driveri.MX
Enhanced Configurable Serial
Peripheral Interface (ECSPI) Driver
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
24Freescale Semiconductor, Inc.
Chapter 2 Introduction
Table 2-1. Linux BSP Supported Features (continued)
FeatureDescriptionChapter SourceApplicable
Thermal DriverThermal driver is a necessary driver for monitoring and
protecting the SoC. The thermal driver will monitor the
SoC's temperature in a certain frequency. It defines
three trip points: critical, hot, and active.
OProfileOProfile is a system-wide profiler for Linux systems,
capable of profiling all running code at low overhead.
Thermal Driveri.MX
6SoloLite
OProfilei.MX
6SoloLite
Platform
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Freescale Semiconductor, Inc.25
Overview
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
26Freescale Semiconductor, Inc.
Chapter 3
Machine Specific Layer (MSL)
3.1Introduction
The Machine Specific Layer (MSL) provides the Linux kernel with the following
machine-dependent components:
• Interrupts including GPIO and EDIO (only on certain platforms)
• Timer
• Memory map
• General Purpose Input/Output (GPIO) including IOMUX on certain platforms
• Shared Peripheral Bus Arbiter (SPBA)
• Smart Direct Memory Access (SDMA)
These modules are normally available in the following directory:
<ltib_dir>/rpm/BUILD/linux/arch/arm/mach-mx6 for i.MX 6 platform
The header files are implemented under the following directory:
The MSL layer contains not only the modules common to all the boards using the same
processor, such as the interrupts and timer, but it also contains modules specific to each
board, such as the memory map. The following sections describe the basic hardware and
software operations and the software interfaces for MSL modules. First, the common
modules, such as Interrupts and Timer are discussed. Next, the board-specific modules,
such as Memory Map and General Purpose Input/Output (GPIO) (including IOMUX on
some platforms) are detailed. Because of the complexity of the SDMA module, its design
is explained in SDMA relevant chapter.
Each of the following sections contains an overview of the hardware operation. For more
information, see the corresponding device documentation.
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Freescale Semiconductor, Inc.27
Interrupts (Operation)
3.2Interrupts (Operation)
This section explains the hardware and software operation of interrupts on the device.
3.2.1Interrupt Hardware Operation
The Interrupt Controller controls and prioritizes a maximum of 128 internal and external
interrupt sources.
Each source can be enabled or disabled by configuring the Interrupt Enable Register or
using the Interrupt Enable/Disable Number Registers. When an interrupt source is
enabled and the corresponding interrupt source is asserted, the Interrupt Controller asserts
a normal or a fast interrupt request depending on the associated Interrupt Type Register
settings.
Interrupt Controller registers can only be accessed in supervisor mode. The Interrupt
Controller interrupt requests are prioritized in the following order: fast interrupts and
normal interrupts for the highest priority level, then highest source number with the same
priority. There are 16 normal interrupt levels for all interrupt sources, with level zero
being the lowest priority. The interrupt levels are configurable through eight normal
interrupt priority level registers. Those registers, along with the Normal Interrupt Mask
Register, support software-controlled priority levels for normal interrupts and priority
masking.
3.2.2Interrupt Software Operation
For ARM-based processors, normal interrupt and fast interrupt are two different
exception types. The exception vector addresses can be configured to start at low address
(0x0) or high address (0xFFFF0000).
The ARM Linux implementation chooses the high vector address model.
The following file describes the ARM interrupt architecture.
The software provides a processor-specific interrupt structure with callback functions
defined in the irqchip structure and exports one initialization function, which is called
during system startup.
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
28Freescale Semiconductor, Inc.
Chapter 3 Machine Specific Layer (MSL)
3.2.3Interrupt Features
The interrupt implementation supports the following features:
• Interrupt Controller interrupt disable and enable
• Functions required by the Linux interrupt architecture as defined in the standard
ARM interrupt source code (mainly the <ltib_dir>/rpm/BUILD/linux/arch/arm/
kernel/irq.c file)
3.2.4Interrupt Source Code Structure
The interrupt module is implemented in the following file (located in the directory
<ltib_dir>/rpm/BUILD/linux/arch/arm/plat-mxc):
irq.c (If CONFIG_MXC_TZIC is not selected)
tzic.c (If CONFIG_MXC_TZIC is selected)
gic.c (If CONFIG_ARM_GIC is selected)
There are also two header files (located in the include directory specified at the beginning
of this chapter):
hardware.h
irqs.h
The following table lists the source files for interrupts.
Table 3-1. Interrupt Files
FileDescription
hardware.hRegister descriptions
irqs.hDeclarations for number of interrupts supported
gic.cActual interrupt functions for GIC modules
3.2.5Interrupt Programming Interface
The machine-specific interrupt implementation exports a single function.
This function initializes the Interrupt Controller hardware and registers functions for
interrupt enable and disable from each interrupt source.
This is done with the global structure irq_desc of type struct irqdesc. After the
initialization, the interrupt can be used by the drivers through the request_irq() function to
register device-specific interrupt handlers.
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
Freescale Semiconductor, Inc.29
Timer
In addition to the native interrupt lines supported by the Interrupt Controller, the number
of interrupts is also expanded to support GPIO interrupt and (on some platforms) EDIO
interrupts. This allows drivers to use the standard interrupt interface supported by ARM
Linux, such as the request_irq() and free_irq() functions.
3.3Timer
The Linux kernel relies on the underlying hardware to provide support for both the
system timer (which generates periodic interrupts) and the dynamic timers (to schedule
events).
After the system timer interrupt occurs, it performs the following operations:
• Updates the system uptime.
• Updates the time of day.
• Reschedules a new process if the current process has exhausted its time slice.
• Runs any dynamic timers that have expired.
• Updates resource usage and processor time statistics.
The timer hardware on most i.MX platforms consists of either Enhanced Periodic
Interrupt Timer (EPIT) or general purpose timer (GPT) or both. GPT is configured to
generate a periodic interrupt at a certain interval (every 10 ms) and is used by the Linux
kernel.
3.3.1Timer Software Operation
The timer software implementation provides an initialization function that initializes the
GPT with the proper clock source, interrupt mode and interrupt interval.
The timer then registers its interrupt service routine and starts timing. The interrupt
service routine is required to service the OS for the purposes mentioned in Timer.
Another function provides the time elapsed as the last timer interrupt.
3.3.2Timer Features
The timer implementation supports the following features:
• Functions required by Linux to provide the system timer and dynamic timers.
• Generates an interrupt every 10 ms.
i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013
30Freescale Semiconductor, Inc.
Loading...
+ 169 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.