69rlq62d-f714peg4 * Memec (Headquar
ter
s) - Unique
Tec
h,
Insight,
Impact
MAR
VELL CONFIDENTIAL,
UNDER ND
A# 12101050
69rlq62d-f714peg4 * Memec (Headquar
ter
s) - Unique
Tec
h,
Insight,
Impact
MAR
VELL CONFIDENTIAL,
UNDER ND
A# 12101050
69r
lq62d-f714peg4 * Memec (Headquar
ters) - Unique
T
ech, Insight, Impact * UNDER ND
A# 12101050
MAR
VELL CONFIDENTIAL - UNA
UTHORIZED DISTRIB
UTION OR USE STRICTL
Y PR
OHIBITED
PXA300 Processor and PXA310 Processor
Vol. I: System and Timer Configuration Developers Manual
Doc. No. MV-TBD-00 Rev. A
CONFIDENTIAL
Copyright © 12/13/06 Marvell
Page 314
Document Classification: Proprietary Information
December 13, 2006
Not approved by Document Control. For review only.
11.3.7
Examples
Example 11-1. Setting Up and Starting a Channel
The following example of code shows how to set up and start a channel to transfer LEN words that start at the
address in the DSADRx register to peripheral address in the DTADRx register. In this example, the stop bit in the
DDADRx register is set so that the DMA channel stops after it completely transfers LEN bytes of data associated
with this descriptor.
// build real descriptor
desc[0].ddadr = STOP;
desc[0].dsadr = DSADR;
desc[0].dtadr = DTADR;
desc[0].dcmd = DCMD;
// start the channel
DMANEXT[CHAN] = &desc[0];
DRUN = 1;
Example 11-1. Creating a Zero-Length Descriptor
The following example of code shows how to initialize a descriptor list for a channel that is running:
// Allocate a new descriptor, and make it an End-
// Descriptor whose “ddadr” field points back at itself
newDesc = New Desc();
newDesc->ddadr = newDesc | STOP;
// make it a zero length descriptor
newDesc->dcmd = ZERO;
// Start the channel
DMANEXT[CHAN] = newDesc;
DRUN = 1;
The channel starts up, loads the descriptor into its registers, detects that the transfer length is zero and the stop bit
is set, and stops the channel. No data transfer occurs in this case. To restart the channel, write to its DDADRx
register, then set the DCSRx[RUN] bit.
Wireless
Trust
Module
(WTM)
Receive
0x43000008
4
11
8, 16, 32
Source
0x4000 111C
Transmit 1
0x43000000
4
11
8, 16, 32
Target
0x4000 1120
Transmit 2
0x43000004
4
11
8, 16, 32
Target
0x4000 1124
NAND IF
Receive and
transmit data
0x4310_0040
1, 2, or
4
01, 10, or 11
8, 16, 32 or trailing
Both
0x4000_1184
Command 0x4310_0030
4
11
16
Target
0x4000_118C
Table 11-8. DMA Quick Reference for On-Chip Peripherals (Sheet 5 of 5)
Unit
Function
FIFO Address
Width
(bytes)
DCMDx
Width
(binary)
Burst Size
(bytes)
Source or
Target
DRCMRx