Architecture
1663
SPRUH82C – April 2013 – Revised September 2016
Copyright © 2013–2016, Texas Instruments Incorporated
Universal Serial Bus 2.0 (USB) Controller
34.2.8.11 USB 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.
34.2.8.11.1 Transparent DMA
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.
Transparent DMA Transfer Setup
The following will configure all four ports/channels for Transparent DMA Transfer type.
•
Make sure that RNDIS Mode is disabled globally. RNDIS bit in the control register (CTRLR) is cleared
to 0.
•
Configure the DMA Mode Register (MODE) for the Endpoint field in use is programmed for
Transparent Mode. MODE = 0000 0000h
34.2.8.11.2 RNDIS
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.
RNDIS DMA Transfer Setup
The following will configure all four ports/channels for RNDIS DMA Transfer type. If all endpoints are to be
configured with the same RNDIS DMA transfer type, then you can enable for RNDIS mode support from
the Control Register and the content of the Mode Register will be ignored.
If you need to enable RNDIS support globally.
•
Enable RNDIS Mode globally. RNDIS bit in the control register (CTRLR) is set to 1.
If you need to enable RNDIS support at the port/channel (endpoint) level.
•
Disable RNDIS Mode globally. RNDIS bit in the control register (CTRLR) is cleared to 0.
•
Configure the DMA Mode Register (MODE) for the Endpoint field in use is programmed for RNDIS
Mode. MODE = 1111 1111h
The above two setups yield the same result.