User Manual
BCM1250/BCM1125/BCM1125H
10/21/02
B r o a d c o m C o r p o r a t i o n
Document
1250_1125-UM100CB-R
Section 7: DMA Page
177
Channels of the Data Mover can be individually enabled and reset. The reset bit should only be written when
the channel is currently disabled or being disabled (i.e. it can be written with either the enable or disable
command). The act of writing the reset bit causes the current descriptor pointer to be reset to the ring base
address. Note that the reset bit for a channel should always be set to initialize the channel when it is enabled
for the first time. There are two ways to disable a channel. The first is to clear the enable bit, which causes the
engine to complete the transfer that is in progress and stop until re-enabled when it will continue with the next
descriptor (unless reset). The second method is to set the abort bit in the same write that clears the enable bit,
this causes the current transfer to be abandoned and the engine stops immediately. When re-enabled after
being aborted the Data Mover will start with the next descriptor, so the end of the transfer that was aborted will
be lost. The active status bit indicates that the channel is currently in use. If the enable bit is cleared the active
bit will remain set until the channel is has finished any transfer and is disabled.
The round robin weights are only used when more than one channel is busy. The data mover will service
requests from a channel until it has completed the number of transfers in the weight parameter for that channel
or there are no descriptors queued. The next channel is then serviced. Note that the weights are by transfer,
not by number of bytes transferred. To achieve true bandwidth sharing the transfer sizes need to be similar (as
do the latencies for the reads and writes). If it is important for system behavior to have a better sharing of the
data mover, software should break down large transfers into a series of smaller transfers to enable finer
granularity on the round robin.
The data mover descriptors include an interrupt bit. If this is set then when the transfer specified in the
descriptor is complete the interrupt bit will be set in the
dm_dscr_base
register and the channel interrupt will
be raised. If an error is flagged on any data read (either for descriptors or for data blocks) the error bit will be
set, the channel interrupt raised and channel will abort and disable. Both the error and interrupt bits are cleared
by reads to the
dm_dscr_base
register, clearing the interrupt.
A high load can be put on the system by the data mover. As soon as the data returns for one of its four
outstanding reads it will write the data and issue another read. To prevent this, data transfers can be throttled
on either the read or the write (or both), this is a parameter of the transfer set in the descriptor. When enabled
the data mover will check the blocking signal from the agent and will only request if the blocker has been clear
for the previous four ZBbus cycles. To avoid starvation there is a timeout, if the data mover is forced to backoff
16 times (e.g. the blocker deasserts but some other agent inserts a request causing the block to assert in less
than four cycles) it will request the next time the blocker is clear.
In parts with system revision indicating PERIPH_REV3 or greater the data mover will prefetch descriptors by
overlapping the descriptor fetch with the data transfer of the previous transaction. This improves performance
if small transactions are used. A side effect of this is that the current descriptor and count may be one ahead
of the transfer in progress (although the count will not go to zero until the channel is idle). If the channel is
disabled a prefetched transaction may be completed before the channel goes inactive. An abort will stop the
channel immediately and it is UNPREDICTABLE if it stops during the original or prefetched transaction.