Table 204. Coherency Model For Method 1 - STMicroelectronics SPC572L series Reference Manual

Table of Contents

Advertisement

Enhanced Direct Memory Access (eDMA)
Note:
The user must clear the TCD.done bit before writing the TCD.major.e_link bit. The
TCD.done bit is cleared automatically by the eDMA engine after a channel begins
execution.
19.5.7.3
Dynamic scatter/gather
Dynamic scatter/gather is the process of setting the TCD.e_sg bit during channel execution.
This bit is read from the TCD local memory at the end of channel execution, thus allowing
the user to enable the feature during channel execution.
Because the user is allowed to change the configuration during execution, a coherency
model is needed. Consider the scenario where the user attempts to execute a dynamic
scatter/gather operation by enabling the TCD.e_sg bit at the same time the eDMA engine is
retiring the channel. The TCD.e_sg would be set in the programmer's model, but it would be
unclear whether the actual scatter/gather request was honored before the channel retired.
Two methods for this coherency model are shown in the following subsections. Method 1
has the advantage of reading the major.linkch field and the e_sg bit with a single read. For
both dynamic channel linking and scatter/gather requests, the TCD local memory controller
forces the TCD.major.e_link and TCD.e_sg bits to zero on any writes to a channel's
TCD.word7 if that channel's TCD.done bit is set indicating the major loop is complete.
Note:
The user must clear the TCD.done bit before writing the TCD.major.e_link or TCD.e_sg bits.
The TCD.done bit is cleared automatically by the eDMA engine after a channel begins
execution.
19.5.7.3.1 Method 1 (channel not using major loop channel linking)
For a channel not using major loop channel linking, the coherency model in
be used for a dynamic scatter/gather request.
When the TCD.major.e_link bit is zero, the TCD.major.linkch field is not used by the eDMA.
In this case, the TCD.major.linkch bits may be used for other purposes. This method uses
the TCD.major.linkch field as a TCD identification (ID).
Step
When the descriptors are built, write a unique TCD ID in the TCD.major.linkch field for each TCD associated
1
with a channel using dynamic scatter/gather.
Write 1b to theTCD.d_req bit.
Note: Should a dynamic scatter/gather attempt fail, setting the d_req bit will prevent a future hardware
2
activation of this channel. This stops the channel from executing with a destination address (daddr) that
was calculated using a scatter/gather address (written in the next step) instead of a dlast final offset
value.
3
Write theTCD.dlast_sga field with the scatter/gather address.
4
Write 1b to the TCD.e_sg bit.
448/2058

Table 204. Coherency model for method 1

DocID027809 Rev 4
Action
RM0400
Table 204
may

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the SPC572L series and is the answer not in the manual?

Questions and answers

Table of Contents