Texas Instruments TMS320C6A816 Series Technical Reference Manual page 1810

C6-integra dsp+arm processors
Table of Contents

Advertisement

Communications Port Programming Interface (CPPI) 4.1 DMA
20.4.7.2 Receive DMA State Registers
The Rx DMA State is a combination of control fields and protocol specific port scratchpad space used
to manipulate data structures in order to receive packets. Each receive channel has only one queue.
Each channel queue has one head descriptor pointer and one completion pointer. There are thirty Rx
DMA State registers; one for each port/channel.
The following information is stored in the Rx DMA State:
Rx Queue Head Descriptor Pointer
Rx Queue Completion Pointer
Rx Buffer Offset
20.4.8 CPPI DMA Protocols Supported
Four different type of DMA transfers are supported by the CPPI 4.1 DMA; Transparent, RNDIS, Generic
RNDIS, and Linux CDC. The following sections will outline the details on these DMA transfer types.
20.4.8.1 Transparent DMA Transfer
Transparent Mode DMA operation is the default DMA mode where DMA interrupt is generated
whenever a DMA packet is transferred. In the transparent mode, DMA packet size cannot be greater
than USB MaxPktSize for the endpoint. This transfer type is ideal for transfer (not packet) sizes that are
less than a max packet size.
20.4.8.1.1 Transparent DMA Transfer Setup
The following will configure all 30 ports/channels for Transparent DMA Transfer type.
Make sure that RNDIS Mode is disabled globally. This allows the application to configure the CPPI
DMA protocol in use to be configured per endpoint need. To disable RNDIS operation, clear RNDIS bit
in the USB Control Registers corresponding to the USB Module (default setting), i.e., CTRL0[RNDIS]=0
and CTRL1[RNDIS]=0.
Configure the USB0/1 Tx/Rx DMA Mode Registers (USB0/1 TX(RX)MODE0/1) for the Endpoint field in
use is programmed for Transparent Mode, i.e., TXMODE0/1[TXn_MODE] = 00b and
RXMODE0/1[RXn_MODE] = 00b.
20.4.8.2 RNDIS DMA Transfer
RNDIS mode DMA is used for large transfers (i.e., total data size to be transferred is greater than USB
MaxPktSize where the MzxPktSize is a multiple of 64 bytes) that requires multiple USB packets. This is
accomplished by breaking the larger packet into smaller packets, where each packet size being USB
MaxPktSize except the last packet where its size is less than USB MaxPktSize, including zero bytes.
This implies that multiple USB packets of MaxPktSize will be received and transferred together as a
single large DMA transfer and the DMA interrupt is generated only at the end of the complete reception
of DMA transfer. The protocol defines the end of the complete transfer by receiving a short USB packet
(smaller than USB MaxPktSize as mentioned in USB specification 2.0). If the DMA packet size is an
exact multiple of USB MaxPktSize, the DMA controller waits for a zero byte packet at the end of
complete transfer to signify the completion of the transfer.
NOTE: RNDIS Mode DMA is supported only when USB MaxPktSize is an integral multiple of 64 bytes.
20.4.8.2.1 RNDIS DMA Transfer Setup
If all endpoints in use are desired to operate in RNDIS mode, it is only suffix to configure RNDIS DMA
operation in RNDIS mode at the global level and application can ignore individual endpoint DMA mode
configuration. This is achieved by programming CTRLR0/1[RNDIS] with a '1.'
However if DMA mode is required to be configured at the endpoint level, it is required to disable the use
of RNDIS at the global level, this is achieved by clearing RNDIS bit field (CTRLR0/1[RNDIS]=0), since
global configuration over-rides endpoint configuration.
1810
Universal Serial Bus (USB)
Preliminary
© 2011, Texas Instruments Incorporated
www.ti.com
SPRUGX9 – 15 April 2011
Submit Documentation Feedback

Advertisement

Table of Contents
loading

Table of Contents