12.6. DMA

The RP2350 Direct Memory Access (DMA) controller performs bulk data transfers on a processor’s behalf. This leaves processors free to attend to other tasks or enter low-power sleep states. The DMA dual bus manager ports can issue one read and one write access per cycle. The data throughput is therefore far greater than one of RP2350’s processors.

Figure 122. DMA Architecture Overview. The read manager can read data from some address every clock cycle. Likewise, the write manager can write to another address. The address generator produces matched pairs of read and write addresses, which the managers consume through the address FIFOs. The DMA can run up to 16 transfer sequences simultaneously, supervised by software via the control and status registers.

Figure 122: DMA Architecture Overview. This block diagram illustrates the internal components and data flow of the DMA. On the left, 'From System' and 'To System' labels indicate the external data paths. The 'From System' path leads to the 'AHB5 Read Manager' (yellow box), which connects to the 'Transfer Data FIFO' (blue box). The 'To System' path leads from the 'Transfer Data FIFO' to the 'AHB5 Write Manager' (yellow box). The 'AHB5 Read Manager' is connected to the 'Read Address FIFO' (blue box), and the 'AHB5 Write Manager' is connected to the 'Write Address FIFO' (blue box). An 'Address Generator' (purple box) provides addresses to both the 'Read Address FIFO' and the 'Write Address FIFO'. The 'Address Generator' is bidirectionally connected to the 'Control/Status Registers' (blue box), which in turn are bidirectionally connected to the 'AHB5 Subordinate Interface' on the right.
Figure 122: DMA Architecture Overview. This block diagram illustrates the internal components and data flow of the DMA. On the left, 'From System' and 'To System' labels indicate the external data paths. The 'From System' path leads to the 'AHB5 Read Manager' (yellow box), which connects to the 'Transfer Data FIFO' (blue box). The 'To System' path leads from the 'Transfer Data FIFO' to the 'AHB5 Write Manager' (yellow box). The 'AHB5 Read Manager' is connected to the 'Read Address FIFO' (blue box), and the 'AHB5 Write Manager' is connected to the 'Write Address FIFO' (blue box). An 'Address Generator' (purple box) provides addresses to both the 'Read Address FIFO' and the 'Write Address FIFO'. The 'Address Generator' is bidirectionally connected to the 'Control/Status Registers' (blue box), which in turn are bidirectionally connected to the 'AHB5 Subordinate Interface' on the right.

The DMA can perform one read access and one write access, up to 32 bits in size, every clock cycle. There are 16 independent channels, each of which supervises a sequence of bus transfers in one of the following scenarios:

Memory-to-peripheral

a peripheral signals the DMA when it needs more data to transmit. The DMA reads data from an array in RAM or flash, and writes to the peripheral's data FIFO.

Peripheral-to-memory

a peripheral signals the DMA when it has received data. The DMA reads this data from the peripheral's data FIFO, and writes it to an array in RAM.

Memory-to-memory

the DMA transfers data between two buffers in RAM, as fast as possible.

Each channel has its own control and status registers (CSRs) that software can use to program and monitor the channel's progress. When multiple channels are active at the same time, the DMA shares bandwidth evenly between the channels, with round-robin over all channels that are currently requesting data transfers.

The transfer size can be either 32, 16, or 8 bits. This is configured once for each channel: source transfer size and destination transfer size are the same. The DMA performs byte lane replication on narrow writes, so byte data is available in all 4 bytes of the databus, and halfword data in both halfwords.

Channels can be combined in varied ways for more sophisticated behaviour and greater autonomy. For example, one channel can configure another, loading configuration data from a sequence of control blocks in memory, and the second can then call back to the first via the CHAIN_TO option when it needs to be reconfigured.

Making the DMA more autonomous means that much less processor supervision is required: overall this allows the system to do more at once, or to dissipate less power.

12.6.1. Changes from RP2040

The following new features have been added:

Some existing behaviour has been refined:

12.6.2. Configuring channels

Each channel has four control/status registers:

To directly instruct the DMA channel to perform a data transfer, software writes to these four registers, and then triggers the channel ( Section 12.6.3 ). To make the DMA more autonomous, you can also program one DMA channel to write to another channel's configuration registers, queueing up many transfer sequences in advance.

All four are live registers; they update their status continuously as the channel progresses.

12.6.2.1. Read and write addresses

READ_ADDR and WRITE_ADDR contain the address the channel will next read from, and write to, respectively. These registers update automatically after each read/write access, incrementing to the next read/write address as required. The size of the increment varies according to:

Software should generally program these registers with new start addresses each time a new transfer sequence starts. If READ_ADDR and WRITE_ADDR are not reprogrammed, the DMA will use the current values as start addresses for the next transfer. For example:

By not programming all four CSRs for each transfer sequence, software can use shorter interrupt handlers, and more compact control block formats when used with channel chaining (see register aliases in Section 12.6.3.1 , chaining in Section 12.6.3.2 ).

12.6.2.1.1. Address alignment

READ_ADDR and WRITE_ADDR must be aligned to the transfer size, specified in CH0_CTRL_TRIG.DATA_SIZE. For 32-bit transfers, the address must be a multiple of four, and for 16-bit transfers, the address must be a multiple of two. Software is responsible for correctly aligning addresses written to READ_ADDR and WRITE_ADDR: the DMA does not enforce alignment.

If software initially writes a correctly aligned address, the address will remain correctly aligned throughout the transfer sequence, because the DMA always increments READ_ADDR and WRITE_ADDR by a multiple of the transfer size. Specifically, it increments by transfer size times -1, 0, 1 or 2, depending on the values of CH0_CTRL_TRIG.INCR_READ, CH0_CTRL_TRIG.INCR_WRITE, CH0_CTRL_TRIG.INCR_READ_REV and CH0_CTRL_TRIG.INCR_WRITE_REV.

The DMA MPU and system-level bus security filters perform protection checks on the lowest byte address of all bytes transferred on a given cycle (i.e. to the present value of READ_ADDR/WRITE_ADDR). RP2350 memory hardware ensures unaligned bus accesses do not cause data to be read/written from the other side of a protection boundary. This means that unaligned access can not be used to violate the memory protection model. Other than this, the result of an unaligned access is unspecified.

12.6.2.2. Transfer count

Reading TRANS_COUNT( CH0_TRANS_COUNT) returns the number of transfers remaining in the current transfer sequence. This value updates continuously as the channel progresses. Writing to TRANS_COUNT sets the length of the next transfer sequence. Up to \( 2^{28}-1 \) transfers can be performed in one sequence ( 0xffffffff, approximately 256 million).

Each time the channel starts a new transfer sequence, the most recent value written to TRANS_COUNT is copied to the live transfer counter, which will then start to decrement again as the new transfer sequence makes progress. For debugging purposes, the DBG_TCR( TRANS_COUNT reload value) registers display the last value written to each channel's TRANS_COUNT.

If the channel is triggered multiple times without intervening writes to TRANS_COUNT, it performs the same number of transfers each time. For example, when chained to, one channel might load a fixed-size control block into another channel's CSRs. TRANS_COUNT would be programmed once by software, and then reload automatically every time.

Alternatively, TRANS_COUNT can be written with a new value before starting each transfer sequence. If TRANS_COUNT is the channel trigger (see Section 12.6.3.1 ), the channel will start immediately, and the value just written will be used, not the value currently in the reload register.

NOTE

The TRANS_COUNT is the number of transfers to be performed. The total number of bytes transferred is TRANS_COUNT times the size of each transfer in bytes, given by CTRL.DATA_SIZE.

12.6.2.2.1. Count modes

The four most-significant bits of TRANS_COUNT contain the MODE field ( CHO_TRANS_COUNT.MODE), which modifies the counting behaviour of TRANS_COUNT. Mode 0x0 is the default: TRANS_COUNT decrements once for every bus transfer, and the channel halts once TRANS_COUNT reaches zero and all in-flight transfers have finished. The value of 0x0 is chosen for backward-compatibility with RP2040 software, which expects the TRANS_COUNT register to contain a 32-bit count rather than a 4-bit mode and a 28-bit count. There are few use cases for a finite number of transfers greater than \( 2^{28} \) , which is why the four most-significant bits have been reallocated for use with endless transfers.

Mode 0x1, TRIGGER_SELF, behaves the same as mode 0x0, except that rather than halting upon completion, the channel immediately re-triggers itself. This is equivalent to a trigger performed by any other mechanism (Section 12.6.3): TRANS_COUNT is reloaded, and the channel resumes from the current READ_ADDR and WRITE_ADDR addresses. A completion interrupt is still raised (if CTRL.IRQ_QUIET is not set) and the specified CHAIN_TO operation is still performed. The main use for this mode is streaming through SRAM ring buffers, where some action is required at regular intervals, for example requesting the processor to refill an audio buffer once it is half-empty.

Mode 0xf, ENDLESS, disables the decrement of TRANS_COUNT. This means a channel will generally run indefinitely without pause, though triggering a channel with a mode of 0xf and a count of 0x0 will result in the channel halting immediately.

All other values are reserved for future use and their effect is unspecified.

12.6.2.3. Control/Status

The CTRL register ( CHO_CTRL_TRIG) has more, smaller fields than the other 3 registers. Among other things, CTRL is used to:

12.6.3. Triggering channels

After a channel has been correctly configured, you must trigger it. This instructs the channel to begin scheduling bus accesses, either paced by a peripheral data request signal (DREQ) or as fast as possible. The following events can trigger a channel:

Each trigger mechanism covers different use cases. For example, trigger registers are simple and efficient when

configuring and starting a channel in an interrupt service routine because the channel is triggered by the last configuration write. CHAIN_TO allows one channel to callback to another channel, which can then reconfigure the first channel. MULTI_CHAN_TRIGGER allows software to simply start a channel without touching any of its configuration registers.

When triggered, the channel sets its CTRL.BUSY flag to indicate it is actively scheduling transfers. This remains set until the transfer count reaches zero, or the channel is aborted via the CHAN_ABORT register (Section 12.6.8.3).

When a channel is already running, indicated by BUSY = 1, it ignores additional triggers. A channel that is disabled ( CTRL.EN is clear) also ignores triggers.

12.6.3.1. Aliases and triggers

Table 1145. Control register aliases. Each channel has four control/status registers. Each register can be accessed at multiple different addresses. In each naturally-aligned group of four, all four registers appear, in different orders.

Offset+0x0+0x4+0x8+0xc (Trigger)
0x00 (Alias 0)READ_ADDRWRITE_ADDRTRANS_COUNTCTRL_TRIG
0x10 (Alias 1)CTRLREAD_ADDRWRITE_ADDRTRANS_COUNT_TRIG
0x20 (Alias 2)CTRLTRANS_COUNTREAD_ADDRWRITE_ADDR_TRIG
0x30 (Alias 3)CTRLWRITE_ADDRTRANS_COUNTREAD_ADDR_TRIG

The four CSRs are aliased multiple times in memory. Each of the four aliases exposes the same four physical registers, but in a different order. The final register in each alias (at offset +0xc, highlighted) is a trigger register. Writing to the trigger register starts the channel.

Often, only alias 0 is used, and aliases 1 through 3 can be ignored. To configure and start the channel, write READ_ADDR, WRITE_ADDR, TRANS_COUNT, and finally CTRL. Since CTRL is the trigger register in alias 0, this starts the channel.

The other aliases allow more compact control block lists when using one channel to configure another, and more efficient reconfiguration and launch in interrupt handlers:

Trigger registers do not start the channel if:

12.6.3.2. Chaining

When a channel completes, it can name a different channel to immediately be triggered. This can be used as a callback for the second channel to reconfigure and restart the first.

This feature is configured through the CHAIN_TO field in the channel CTRL register. This 4-bit value selects a channel that will start when this one finishes. A channel cannot chain to itself. Setting CHAIN_TO to a channel's own index prevents chaining.

Chain triggers behave the same as triggers from other sources, such as trigger registers. For example, they cause TRANS_COUNT to reload, and they are ignored if the targeted channel is already running.

One application for CHAIN_TO is for a channel to request reconfiguration by another channel from a sequence of control blocks in memory. Channel A is configured to perform a wrapped transfer from memory to channel B's control registers (including a trigger register), and channel B is configured to chain back to channel A when it completes each transfer sequence. This is shown explicitly in the DMA control blocks example ( Section 12.6.9.2 ).

Use of the register aliases ( Section 12.6.3.1 ) enables compact formats for DMA control blocks: as little as one word, in some cases.

Another use of chaining is a ping-pong configuration, where two channels each trigger one another. The processor can respond to the channel completion interrupts and reconfigure each channel after it completes. However, the chained channel, which has already been configured, starts immediately. In other words, channel configuration and channel operation are pipelined. This can improve performance dramatically when a usage pattern requires many short transfer sequences.

The Section 12.6.9 goes into more detail on the possibilities of chain triggers in the real world.

12.6.3.3. Null triggers and chain interrupts

As mentioned in Section 12.6.3.1 , writing all-zeroes to a trigger register does not start the channel. This is called a null trigger, and it has two purposes:

By default, channels generate an interrupt each time they finish a transfer sequence, unless that channel's IRQ is masked in INTE0 through INTE3. The rate of interrupts can be excessive, particularly as processor attention is generally not required while a sequence of control blocks are in progress. However, processor attention is required at the end of a chain.

The channel CTRL register has a field called IRQ_QUIET. Its default value is 0. When this set to 1, channels generate an interrupt when they receive a null trigger, but not on normal completion of a transfer sequence. The interrupt is generated by the channel that receives the trigger.

12.6.4. Data request (DREQ)

Peripherals produce or consume data at their own pace. If the DMA transferred data as fast as possible, loss or corruption of data would ensue. DREQs are a communication channel between peripherals and the DMA that enables the DMA to pace transfers according to the needs of the peripheral.

The CTRL.TREQ_SEL(transfer request) field selects an external DREQ. It can also be used to select one of the internal pacing timers, or select no TREQ at all (the transfer proceeds as fast as possible), e.g. for memory-to-memory transfers.

12.6.4.1. System DREQ table

DREQ numbers use the following global assignment to peripheral DREQ channels:

Table 1146. DREQs

DREQDREQ ChannelDREQDREQ ChannelDREQDREQ ChannelDREQDREQ Channel
0DREQ_PIO0_TX014DREQ_PIO1_RX228DREQ_UART0_TX42DREQ_PWM_WRAP10
1DREQ_PIO0_TX115DREQ_PIO1_RX329DREQ_UART0_RX43DREQ_PWM_WRAP11
2DREQ_PIO0_TX216DREQ_PIO2_TX030DREQ_UART1_TX44DREQ_I2C0_TX
3DREQ_PIO0_TX317DREQ_PIO2_TX131DREQ_UART1_RX45DREQ_I2C0_RX
4DREQ_PIO0_RX018DREQ_PIO2_TX232DREQ_PWM_WRAP046DREQ_I2C1_TX
5DREQ_PIO0_RX119DREQ_PIO2_TX333DREQ_PWM_WRAP147DREQ_I2C1_RX
6DREQ_PIO0_RX220DREQ_PIO2_RX034DREQ_PWM_WRAP248DREQ_ADC
7DREQ_PIO0_RX321DREQ_PIO2_RX135DREQ_PWM_WRAP349DREQ_XIP_STREAM
8DREQ_PIO1_TX022DREQ_PIO2_RX236DREQ_PWM_WRAP450DREQ_XIP_QMITX
9DREQ_PIO1_TX123DREQ_PIO2_RX337DREQ_PWM_WRAP551DREQ_XIP_QMIRX
10DREQ_PIO1_TX224DREQ_SPI0_TX38DREQ_PWM_WRAP652DREQ_HSTX
11DREQ_PIO1_TX325DREQ_SPI0_RX39DREQ_PWM_WRAP753DREQ_CORESIGHT
12DREQ_PIO1_RX026DREQ_SPI1_TX40DREQ_PWM_WRAP854DREQ_SHA256
13DREQ_PIO1_RX127DREQ_SPI1_RX41DREQ_PWM_WRAP9

12.6.4.2. Credit-based DREQ Scheme

The RP2350 DMA is designed for systems where:

In addition, the DMA's transfer FIFOs and dual-manager-port structure permit multiple accesses to the same peripheral to be in-flight at once to improve throughput. Choice of DREQ mechanism is therefore critical:

The RP2350 DMA uses a credit-based DREQ mechanism. For each peripheral, the DMA attempts to keep as many transfers in-flight as the peripheral has capacity for. This enables full bus throughput (1 word per clock) through an 8-deep peripheral FIFO with no possibility of overflow or underflow in the absence of fabric latency or contention.

For each channel, the DMA maintains a counter. Each 1-clock pulse on the dreq signal increments this counter. When non-zero, the channel requests a transfer from the DMA's internal arbiter. The counter decrements when the transfer is issued to the address FIFOs. At this point the transfer is in flight, but has not yet necessarily completed.

The counter is saturating, and six bits in size. The counter ignores increments at the maximum value or decrements at zero. The six-bit counter size supports counts up to the depth of any FIFO on RP2350.

Figure 123. DREQ counting

Timing diagram for DREQ counting showing clk, dreq, chan count, and chan issue signals.

The diagram illustrates the DREQ counting mechanism. It shows four signals over time: clk (clock), dreq (data request), chan count (channel count), and chan issue (channel issue). The clk signal is a regular square wave. The dreq signal is a pulse that occurs at specific clock cycles. The chan count signal is a counter that increments from 0 to 2 as dreq pulses occur. The chan issue signal is a pulse that occurs at the end of each chan count increment.

Timing diagram for DREQ counting showing clk, dreq, chan count, and chan issue signals.

The effect is to upper bound the number of in-flight transfers based on the amount of room or data available in the peripheral FIFO. In the steady state, this gives maximum throughput, but can't underflow or underflow. This approach has the following caveats:

12.6.5. Interrupts

Each channel can generate interrupts; these can be masked on a per-channel basis using one of the four identical interrupt enable registers, INTE0 through INTE3 . There are three circumstances where a channel raises an interrupt request:

The masked interrupt status is visible in the INTS registers; there is one bit for each channel. Interrupts are cleared by writing a bit mask to INTS . One idiom for acknowledging interrupts is to read INTS , then write the same value back, so only enabled interrupts are cleared.

The RP2350 DMA provides four system IRQs, with independent masking and status registers (e.g. INTE0 , INTE1 ). Any combination of channel interrupt requests can be routed to each system IRQ, though generally software only routes each channel interrupt to a single system IRQ. For example:

For debugging purposes, the INTF registers can force any channel interrupt to be asserted, which will cause assertion of any system IRQs that have that channel interrupt's enable bit set in their respective INTE registers.

12.6.6. Security

RP2350's processors support partitioning of memory and peripherals into multiple security domains. This partitioning is extended into the DMA, so that different security contexts can safely use their assigned channels without breaking any of the security invariants laid out by the processor security model. For example, an Arm processor in the Non-secure state must not be able to use the DMA to access memory or peripherals owned by Secure software.

The DMA defines four security levels that map onto Arm or RISC-V processor security states:

So that the DMA can compare different security levels in a consistent way, they are considered ordered, with \( SP > SU > NSP > NSU \) . For example, when we say that a channel requires a minimum of SU to access its registers, this means that SP and SU are acceptable, and NSP and NSU are not. As a rule, every action has a reaction that is at or below the security level of the original action, and so the DMA can not be used to escalate accesses to a higher security level.

Software assigns internal DMA resources, like channels, interrupts, pacing timers and the CRC sniffer, to one of the four possible security levels. These resources are then accessible only at and above that level. Channel assignment in particular is discussed in Section 12.6.6.1 .

The DMA memory protection unit ( Section 12.6.6.3 ) defines the minimum security level required to access up to eight programmable address ranges, so that channels of a given security level can not access memory beyond their means. This MPU is intended to mirror the SRAM and XIP memory protection boundaries configured in the processor SAU or PMP. In addition to the internal filtering performed by the DMA MPU, accesses are filtered by the system bus according to the ACCESSCTRL filter rules described in Section 10.6.2 .

The combination of these features allows the DMA to be safely shared by software running in different security domains. If this is not desired, the entire DMA block can instead be assigned wholesale to a single security domain using the ACCESSCTRL DMA register.

12.6.6.1. Channel security assignment

Channels are assigned to security domains using the channel SECCFG registers, SECCFG_CH0 through SECCFG_CH15 . There is one register per channel. Each register contains a 2-bit security level, and a lock bit that prevents that SECCFG register from being changed once configured. At reset, all channels are assigned to the SP security level, which is the highest.

The security level of a channel defines:

The channel SECCFG registers require privileged writes (SP/NSP), and will generate a bus fault on an attempted unprivileged write (SU/NSU). Additionally, the S bit (MSB of the security level) and the LOCK bit are writable only by SP, whilst the P bit (LSB of the security level) is also writable by NSP, if and only if the S bit is clear. Reads are always allowed: it is always possible to query which channels are assigned to you by reading the channel SECCFG registers.

Each channel SECCFG register can be locked manually by writing a one to the LOCK bit in that register, and will also lock automatically upon a successful write to one of the channel's control registers such as CHO_CTRL_TRIG . This automatic locking avoids any race conditions that can arise from a channel's security level changing after it has already started making transfers, or from leaking secure pointers that have been written to its control registers. After a channel SECCFG register has been locked, it becomes read-only. LOCK bits can be cleared only by a full reset of the DMA block.

SECCFG registers can be written multiple times before being locked, so the full assignment does not have to be known up front: for example, Secure Arm software can set spare channels to NSP before launching the Non-secure software context, and Non-secure, Privileged software can then set the remaining channels it does not need to NSU before returning to the Non-secure, Normal context.

12.6.6.2. Interrupt Security Assignment

The RP2350 DMA has four system-level interrupt request lines (IRQs), each of which can be asserted on any combination of channel interrupts, as defined by the channel masks in the interrupt enable registers INTE0 through INTE3 . Because the timing of interrupts can leak information, and because it is possible to cause software to malfunction by deliberately manipulating its interrupts, access to the channel interrupt flags must be controlled.

The interrupt security configuration registers, SECCFG_IRQ0 through SECCFG_IRQ3 , define the security level for each interrupt. This is one of the four security levels laid out in Section 12.6.6 . The security level of an IRQ defines:

The INTR register is shared between all IRQs, so it does not respect any of the IRQ security levels. Instead, it follows the security level of the bus access: reads of INTR will return the interrupt flags of all channels at or below the security level of the bus access (with higher-level channels reading back as zeroes), and writes to INTR have write-one-clear behaviour on channels which are at or below the security level of the bus access.

12.6.6.3. Memory protection unit

The DMA memory protection unit (MPU) monitors the addresses of all read/write transfers performed by the DMA, and notes the security level of the originating channel. The MPU is configured in advance with a user-defined security address map, which specifies the minimum security level required to access up to eight dynamically configured regions. This is one of the four security levels defined in Section 12.6.6 .

Transfers that fail to meet the minimum security level for their address are shot down before reaching the system bus, and a bus error is returned to the originating channel. This will be reported as either a read or write bus error in the channel's CTRL register, depending on whether it was a read or write address that failed the security check.

The intended use for the DMA MPU is to mirror the security definitions of SRAM and XIP memory from the processor SAU or PMP. The number of DMA MPU regions is not sufficient for assigning individual peripherals, so the ACCESSCTRL bus access registers ( Section 10.6.2 ) are provided for this purpose.

Each of the eight MPU regions is configured with a base address, MPU_BAR0 through MPU_BAR7 for each region, and a limit address, MPU_LAR0 through MPU_LAR7 .

MPU regions have a granularity of 32 bytes, so the base/limit addresses are configured by the 27 most-significant bits of each BAR/LAR register (bits 31:5). Addresses match MPU regions when the 27 most-significant bits of the address are greater than or equal to the BAR address bits, and less than or equal to the LAR address bits. For example, when MPU_BAR0 and MPU_LAR0 both have the value 0x10000000, MPU region 0 matches on a 32-byte region extending from byte address 0x10000000 to 0x1000001f(inclusive). Regions can be enabled or disabled using the LAR.EN bits – if a region is disabled, it matches no addresses.

The minimum security level required to access each region is defined by the S and P bits in the LSBs of that region's LAR register. When an address matches multiple regions, the lowest-numbered region applies. This matches the tie-break rules for the RISC-V PMP, but is different from the Arm SAU tie-break rules, so care must be taken when mirroring SAU mappings with overlapping regions. When none of the MPU regions are matched, the security level is defined by the global MPU_CTRL.S and MPU_CTRL.P bits.

The MPU configuration registers ( MPU_CTRL , MPU_BAR0 through MPU_BAR7 and MPU_LAR0 through MPU_LAR7 ) do not permit unprivileged access. Bus accesses at the SU and NSU security levels will return a bus fault and have no other effect.

The MPU registers are also mostly read-only to NSP accesses, with the sole exception being the region P bits which are NSP-writable if and only if the corresponding region's S bit is clear. This delegates to Privileged, Non-secure software the decision of whether Non-secure regions are NSU-accessible.

12.6.7. Bus error handling

A bus error is an error condition flagged to one of the DMA's manager ports in response to an attempted read or write transfer, indicating the transfer was rejected for one of the following reasons:

12.6.7.1. Response to bus errors

Upon encountering a bus error, the DMA halts the offending channel and reports the error through the channel's CH0_CTRL.TRIG.READ_ERROR and WRITE_ERROR flags. The channel stops scheduling bus accesses.

Bus errors are exceptional events which usually indicate misconfiguration of the DMA or some other system hardware. Therefore the DMA refuses to restart the offending channel until its error status is cleared by writing 1 to the relevant error flag. Other channels are not affected, and continue their transfer sequences uninterrupted.

A channel which encounters a bus error does not CHAIN_TO other channels.

Bus errors always cause the channel's interrupt request to be asserted. Whether or not this causes a system-level IRQ depends on the channel masks configured in interrupt enable registers INTE0 through INTE3 .

12.6.7.2. Recovery after bus errors

If an error is reported through READ_ERR/ WRITE_ERR then, before restarting the channel, software must:

  1. 1. Poll for a low BUSY status to ensure that all in-flight transfers for this channel have been flushed from the DMA's bus pipeline.
  2. 2. Clear the error flags by writing 1 to each flag.

Generally the BUSY flag will already be low long before the processor enters its interrupt handler and checks the error status, but it is possible for these events to overlap when the DMA is accessing a slow device such as XIP with a high SCK divisor and processors are executing from SRAM.

READ_ADDR and WRITE_ADDR contain the approximate address where the bus error was encountered. This can be useful for the programmer to understand why the bus error occurred, and fix the software to avoid it in future.

Since the DMA performs reads and writes in parallel, it is possible for a channel to encounter both a read and write error simultaneously, and in this case the DMA sets both READ_ERR and WRITE_ERR. You must clear both.

12.6.7.3. Halt timing

The DMA halts the channel as soon as possible following a bus error. This suppresses future reads and writes. Because the request to access the bus is masked, the bus access has no side effects on the system. The timing relationships are not straightforward due to the DMA's pipelining and buffering. The DMA provides the following ordering guarantees between transfers originating from one channel:

"Paired with" in the above paragraph refers to the write access which writes data originating from a particular read transfer , or vice versa. The DMA always schedules read and write accesses in matched pairs.

Slight variability in halt behaviour is due to the buffering of in-flight transfers, and the parallel operation of the read and write bus ports. The values of READ_ADDR/ WRITE_ADDR following a bus error can be slightly beyond the address that experienced the first error, but the difference is bounded, and usually this is still sufficient to diagnose the reason for the fault. Additionally, READ_ADDR and WRITE_ADDR are guaranteed to over-increment by the same amount, since reads and writes are always scheduled in pairs.

In addition to the increments mentioned above, READ_ADDR/ WRITE_ADDR always point to the next address to be written, so always point slightly past the faulting address if address increment is enabled.

12.6.8. Additional features

12.6.8.1. Pacing timers

These allow transfer of data roughly once every \( n \) clk_sys clocks instead of using external peripheral DREQ to trigger transfers. A fractional (X/Y) divider is used, and will generate a maximum of 1 request per clk_sys cycle.

There are 4 timers available in RP2350. Each DMA channel is able to select any of these in CTRL.TREQ_SEL. There is one register used to configure the pacing coefficients for each timer, TIMER0 through TIMER3.

Each timer's security level is defined by a register field in SECCFG_MISC. This defines the minimum bus security level required to configure that timer (lower levels will get a bus fault), and the minimum channel security level required to observe that timer's TREQ.

12.6.8.2. CRC calculation

The DMA can watch data from a given channel passing through the data FIFO, and calculate checksums based on this data. This is a purely passive affair: the data is not altered by this hardware, only observed.

The feature is controlled via the SNIFF_CTRL and SNIFF_DATA registers, and can be enabled/disabled per DMA transfer via the CTRL.SNIFF_EN field.

As this hardware cannot place back-pressure on the FIFO, it must keep up with the DMA's maximum transfer rate of 32 bits per clock.

The supported checksums are:

The result register is both readable and writable, so that the initial seed value can be set.

Bit/byte manipulations are available on the result, which can aid specific use cases:

These manipulations do not affect the CRC calculation, just how the data is presented in the result register.

The sniffer's security level is configured by the SECCFG_MISC.SNIFF_S and SECCFG_MISC.SNIFF_P bits. This determines the minimum bus security level required to access the sniffer's control registers, as well as the maximum channel security level that the sniffer can observe.

12.6.8.3. Channel abort

It is possible for a channel to get into an irrecoverable state. If commanded to transfer more data than a peripheral will ever request, the channel will never complete. Clearing the CTRL.EN bit pauses the channel, but does not solve the problem. This should not occur under normal circumstances, but it is important that there is a mechanism to recover without simply hard-resetting the entire DMA block.

In such a situation, use the CHAN_ABORT register to force the channel to complete early. There is one bit for each channel. Writing a 1 to the corresponding bit terminates the channel. This clears the transfer counter and forces the channel into an inactive state.

At the time an abort is triggered, a channel might have bus transfers currently in flight between the read and write manager. These transfers cannot be revoked. The CTRL.BUSY flag stays high until these transfers complete, and the channel reaches a safe state. This generally takes only a few cycles. The channel must not be restarted until its CTRL.BUSY flag de-asserts. Starting a new sequence of transfers whilst transfers from an old sequence are still in flight will cause unpredictable behaviour.

The sequence to abort one or more channels in an unknown state (also accounting for the behaviour described in RP2350-E5 is:

  1. 1. Clear the EN bit and disable CHAIN_TO for all channels to be aborted.
  2. 2. Write the CHAN_ABORT register with a bitmap of those same channels.
  3. 3. Poll the ABORT register until all bits set by the previous write are clear.

When aborting a channel involved in a CHAIN_TO, it is recommended to simultaneously abort all other channels involved in the chain.

12.6.8.4. Debug

Debug registers are available for each DMA channel to show the dreq counter DBG_CTDREQ and next transfer count DBG_TCR. These can also be used to reset a DMA channel if required.

12.6.9. Example use cases

12.6.9.1. Using interrupts to reconfigure a channel

When a channel finishes a block of transfers, it becomes available for making more transfers. Software detects that the channel is no longer busy, and reconfigures and restarts the channel. One approach is to poll the CTRL_BUSY bit until the channel is done, but this loses one of the key advantages of the DMA, namely that it does not have to operate in lockstep with a processor. By setting the correct bit in INTE0 through INTE3, you can instruct the DMA to raise one of its four interrupt request lines when a given channel completes. Rather than repeatedly asking if a channel is done, you are told.

i NOTE

Having four system interrupt lines allows different channel completion interrupts to be routed to different cores, or to pre-empt one another on the same core if one channel is more time-critical. It also allows channel interrupts to target different security domains.

When the interrupt is asserted, the processor can be configured to drop whatever it is doing and call a user-specified handler function. The handler can reconfigure and restart the channel. When the handler exits, the processor returns to the interrupted code running in the foreground.

Pico Examples: https://github.com/raspberrypi/pico-examples/blob/master/dma/channel_irq/channel_irq.c Lines 35 - 52

35 void dma_handler() {
36     static int pwm_level = 0;
37     static uint32_t wavetable[N_PWM_LEVELS];
38     static bool first_run = true;
39     // Entry number `i` has `i` one bits and `(32 - i)` zero bits.
40     if (first_run) {
41         first_run = false;
42         for (int i = 0; i < N_PWM_LEVELS; ++i)
43             wavetable[i] = ~(~0u << i);
44     }
45 }
46 // Clear the interrupt request.
47 dma_hw->ints0 = 1u << dma_chan;
48 // Give the channel a new wave table entry to read from, and re-trigger it
49 dma_channel_set_read_addr(dma_chan, &wavetable[pwm_level], true);
50
51 pwm_level = (pwm_level + 1) % N_PWM_LEVELS;
52 }

In many cases, most of the configuration can be done the first time the channel starts. This way, only addresses and transfer lengths need reprogramming in the interrupt handler.

Pico Examples: https://github.com/raspberrypi/pico-examples/blob/master/dma/channel_irq/channel_irq.c Lines 54 - 94

54 int main() {
55 #ifndef PICO_DEFAULT_LED_PIN
56 #warning dma/channel_irq example requires a board with a regular LED
57 #else
58 // Set up a PIO state machine to serialise our bits
59 uint offset = pio_add_program(pio0, &pio_serialiser_program);
60 pio_serialiser_program_init(pio0, 0, offset, PICO_DEFAULT_LED_PIN, PIO_SERIAL_CLKDIV);
61
62 // Configure a channel to write the same word (32 bits) repeatedly to PIO0
63 // SM0's TX FIFO, paced by the data request signal from that peripheral.
64 dma_chan = dma_claim_unused_channel(true);
65 dma_channel_config c = dma_channel_get_default_config(dma_chan);
66 channel_config_set_transfer_data_size(&c, DMA_SIZE_32);
67 channel_config_set_read_increment(&c, false);
68 channel_config_set_dreq(&c, DREQ_PIO0_TX0);
69
70 dma_channel_configure(
71     dma_chan,
72     &c,
73     &pio0_hw->txf[0], // Write address (only need to set this once)
74     NULL,             // Don't provide a read address yet
75     PWM_REPEAT_COUNT, // Write the same value many times, then halt and interrupt
76     false             // Don't start yet
77 );
78
79 // Tell the DMA to raise IRQ line 0 when the channel finishes a block
80 dma_channel_set_irq0_enabled(dma_chan, true);
81
82 // Configure the processor to run dma_handler() when DMA IRQ 0 is asserted
83 irq_set_exclusive_handler(DMA_IRQ_0, dma_handler);
84 irq_set_enabled(DMA_IRQ_0, true);
85
86 // Manually call the handler once, to trigger the first transfer
87 dma_handler();
88
89 // Everything else from this point is interrupt-driven. The processor has
90 // time to sit and think about its early retirement -- maybe open a bakery?
91 while (true)
92     tight_loop_contents();
93 #endif
94 }

One disadvantage of this technique is that you don't start to reconfigure the channel until some time after the channel makes its last transfer. If there is heavy interrupt activity on the processor, this can be quite a long time, and quite a large gap in transfers. This makes it difficult to sustain a high data throughput.

This is solved by using two channels, with their CHAIN_TO fields crossed over, so that channel A triggers channel B when it completes, and vice versa. At any point in time, one of the channels is transferring data. The other is either already

configured to start the next transfer immediately when the current one finishes, or it is in the process of being reconfigured. When channel A completes, it immediately starts the cued-up transfer on channel B. At the same time, the interrupt is fired, and the handler reconfigures channel A so that it is ready when channel B completes.

12.6.9.2. DMA control blocks

Frequently, multiple smaller buffers must be gathered together and sent to the same peripheral. To address this use case, the RP2350 DMA can execute a long and complex sequence of transfers without processor control. One channel repeatedly reconfigures a second channel, and the second channel restarts the first each time it completes block of transfers.

Because the first DMA channel transfers data directly from memory to the second channel's control registers, the format of the control blocks in memory must match those registers. Each time, the last register written to will be one of the trigger registers (Section 12.6.3.1), which will start the second channel on its programmed block of transfers. The register aliases (Section 12.6.3.1) give some flexibility for the block layout, and more importantly allow some registers to be omitted from the blocks, so they occupy less memory and can be loaded more quickly.

This example shows how multiple buffers can be gathered and transferred to the UART, by reprogramming TRANS_COUNT and READ_ADDR_TRIG:

Pico Examples: https://github.com/raspberrypi/pico-examples/blob/master/dma/control_blocks/control_blocks.c

1  /**
2   * Copyright (c) 2020 Raspberry Pi (Trading) Ltd.
3   *
4   * SPDX-License-Identifier: BSD-3-Clause
5   */
6
7  // Use two DMA channels to make a programmed sequence of data transfers to the
8  // UART (a data gather operation). One channel is responsible for transferring
9  // the actual data, the other repeatedly reprograms that channel.
10
11 #include <stdio.h>
12 #include "pico/stdlib.h"
13 #include "hardware/dma.h"
14 #include "hardware/structs/uart.h"
15
16 // These buffers will be DMA'd to the UART, one after the other.
17
18 const char word0[] = "Transferring ";
19 const char word1[] = "one ";
20 const char word2[] = "word ";
21 const char word3[] = "at ";
22 const char word4[] = "a ";
23 const char word5[] = "time.\n";
24
25 // Note the order of the fields here: it's important that the length is before
26 // the read address, because the control channel is going to write to the last
27 // two registers in alias 3 on the data channel:
28 //          +0x0      +0x4      +0x8      +0xC (Trigger)
29 // Alias 0:  READ_ADDR  WRITE_ADDR  TRANS_COUNT  CTRL
30 // Alias 1:  CTRL      READ_ADDR  WRITE_ADDR  TRANS_COUNT
31 // Alias 2:  CTRL      TRANS_COUNT  READ_ADDR  WRITE_ADDR
32 // Alias 3:  CTRL      WRITE_ADDR  TRANS_COUNT  READ_ADDR
33 //
34 // This will program the transfer count and read address of the data channel,
35 // and trigger it. Once the data channel completes, it will restart the
36 // control channel (via CHAIN_TO) to load the next two words into its control
37 // registers.
38
39 const struct {uint32_t len; const char *data;} control_blocks[] = {
40     {count_of(word0) - 1, word0}, // Skip null terminator
41     {count_of(word1) - 1, word1},
42     {count_of(word2) - 1, word2},
43     {count_of(word3) - 1, word3},
44     {count_of(word4) - 1, word4},
45     {count_of(word5) - 1, word5},
46     {0, NULL} // Null trigger to end chain.
47 };
48
49 int main() {
50 #ifndef uart_default
51 #warning dma/control_blocks example requires a UART
52 #else
53     stdio_init_all();
54     puts("DMA control block example:");
55
56     // ctrl_chan loads control blocks into data_chan, which executes them.
57     int ctrl_chan = dma_claim_unused_channel(true);
58     int data_chan = dma_claim_unused_channel(true);
59
60     // The control channel transfers two words into the data channel's control
61     // registers, then halts. The write address wraps on a two-word
62     // (eight-byte) boundary, so that the control channel writes the same two
63     // registers when it is next triggered.
64
65     dma_channel_config c = dma_channel_get_default_config(ctrl_chan);
66     channel_config_set_transfer_data_size(&c, DMA_SIZE_32);
67     channel_config_set_read_increment(&c, true);
68     channel_config_set_write_increment(&c, true);
69     channel_config_set_ring(&c, true, 3); // 1 << 3 byte boundary on write ptr
70
71     dma_channel_configure(
72         ctrl_chan,
73         &c,
74         &dma_hw->ch[data_chan].al3_transfer_count, // Initial write address
75         &control_blocks[0], // Initial read address
76         2, // Halt after each control block
77         false // Don't start yet
78     );
79
80     // The data channel is set up to write to the UART FIFO (paced by the
81     // UART's TX data request signal) and then chain to the control channel
82     // once it completes. The control channel programs a new read address and
83     // data length, and retriggers the data channel.
84
85     c = dma_channel_get_default_config(data_chan);
86     channel_config_set_transfer_data_size(&c, DMA_SIZE_8);
87     channel_config_set_dreq(&c, uart_get_dreq(uart_default, true));
88     // Trigger ctrl_chan when data_chan completes
89     channel_config_set_chain_to(&c, ctrl_chan);
90     // Raise the IRQ flag when 0 is written to a trigger register (end of chain):
91     channel_config_set_irq_quiet(&c, true);
92
93     dma_channel_configure(
94         data_chan,
95         &c,
96         &uart_get_hw(uart_default)->dr,
97         NULL, // Initial read address and transfer count are unimportant;
98         0, // the control channel will reprogram them each time.
99         false // Don't start yet.
100    );
101
102    // Everything is ready to go. Tell the control channel to load the first
103    // control block. Everything is automatic from here.
104 dma_start_channel_mask(1u << ctrl_chan);
105
106 // The data channel will assert its IRQ flag when it gets a null trigger,
107 // indicating the end of the control block list. We're just going to wait
108 // for the IRQ flag instead of setting up an interrupt handler.
109 while (!(dma_hw->intr & 1u << data_chan))
110     tight_loop_contents();
111 dma_hw->ints0 = 1u << data_chan;
112
113 puts("DMA finished.");
114 #endif
115 }

12.6.10. List of Registers

The DMA registers start at a base address of 0x50000000 (defined as DMA_BASE in SDK).

Table 1147. List of DMA registers

OffsetNameInfo
0x000CH0_READ_ADDRDMA Channel 0 Read Address pointer
0x004CH0_WRITE_ADDRDMA Channel 0 Write Address pointer
0x008CH0_TRANS_COUNTDMA Channel 0 Transfer Count
0x00cCH0_CTRL_TRIGDMA Channel 0 Control and Status
0x010CH0_AL1_CTRLAlias for channel 0 CTRL register
0x014CH0_AL1_READ_ADDRAlias for channel 0 READ_ADDR register
0x018CH0_AL1_WRITE_ADDRAlias for channel 0 WRITE_ADDR register
0x01cCH0_AL1_TRANS_COUNT_TRIGAlias for channel 0 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x020CH0_AL2_CTRLAlias for channel 0 CTRL register
0x024CH0_AL2_TRANS_COUNTAlias for channel 0 TRANS_COUNT register
0x028CH0_AL2_READ_ADDRAlias for channel 0 READ_ADDR register
0x02cCH0_AL2_WRITE_ADDR_TRIGAlias for channel 0 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x030CH0_AL3_CTRLAlias for channel 0 CTRL register
0x034CH0_AL3_WRITE_ADDRAlias for channel 0 WRITE_ADDR register
0x038CH0_AL3_TRANS_COUNTAlias for channel 0 TRANS_COUNT register
0x03cCH0_AL3_READ_ADDR_TRIGAlias for channel 0 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x040CH1_READ_ADDRDMA Channel 1 Read Address pointer
0x044CH1_WRITE_ADDRDMA Channel 1 Write Address pointer
0x048CH1_TRANS_COUNTDMA Channel 1 Transfer Count
0x04cCH1_CTRL_TRIGDMA Channel 1 Control and Status
OffsetNameInfo
0x050CH1_AL1_CTRLAlias for channel 1 CTRL register
0x054CH1_AL1_READ_ADDRAlias for channel 1 READ_ADDR register
0x058CH1_AL1_WRITE_ADDRAlias for channel 1 WRITE_ADDR register
0x05cCH1_AL1_TRANS_COUNT_TRIGAlias for channel 1 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x060CH1_AL2_CTRLAlias for channel 1 CTRL register
0x064CH1_AL2_TRANS_COUNTAlias for channel 1 TRANS_COUNT register
0x068CH1_AL2_READ_ADDRAlias for channel 1 READ_ADDR register
0x06cCH1_AL2_WRITE_ADDR_TRIGAlias for channel 1 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x070CH1_AL3_CTRLAlias for channel 1 CTRL register
0x074CH1_AL3_WRITE_ADDRAlias for channel 1 WRITE_ADDR register
0x078CH1_AL3_TRANS_COUNTAlias for channel 1 TRANS_COUNT register
0x07cCH1_AL3_READ_ADDR_TRIGAlias for channel 1 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x080CH2_READ_ADDRDMA Channel 2 Read Address pointer
0x084CH2_WRITE_ADDRDMA Channel 2 Write Address pointer
0x088CH2_TRANS_COUNTDMA Channel 2 Transfer Count
0x08cCH2_CTRL_TRIGDMA Channel 2 Control and Status
0x090CH2_AL1_CTRLAlias for channel 2 CTRL register
0x094CH2_AL1_READ_ADDRAlias for channel 2 READ_ADDR register
0x098CH2_AL1_WRITE_ADDRAlias for channel 2 WRITE_ADDR register
0x09cCH2_AL1_TRANS_COUNT_TRIGAlias for channel 2 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x0a0CH2_AL2_CTRLAlias for channel 2 CTRL register
0x0a4CH2_AL2_TRANS_COUNTAlias for channel 2 TRANS_COUNT register
0x0a8CH2_AL2_READ_ADDRAlias for channel 2 READ_ADDR register
0x0acCH2_AL2_WRITE_ADDR_TRIGAlias for channel 2 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x0b0CH2_AL3_CTRLAlias for channel 2 CTRL register
0x0b4CH2_AL3_WRITE_ADDRAlias for channel 2 WRITE_ADDR register
0x0b8CH2_AL3_TRANS_COUNTAlias for channel 2 TRANS_COUNT register
0x0bcCH2_AL3_READ_ADDR_TRIGAlias for channel 2 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
OffsetNameInfo
0x0c0CH3_READ_ADDRDMA Channel 3 Read Address pointer
0x0c4CH3_WRITE_ADDRDMA Channel 3 Write Address pointer
0x0c8CH3_TRANS_COUNTDMA Channel 3 Transfer Count
0x0ccCH3_CTRL_TRIGDMA Channel 3 Control and Status
0x0d0CH3_AL1_CTRLAlias for channel 3 CTRL register
0x0d4CH3_AL1_READ_ADDRAlias for channel 3 READ_ADDR register
0x0d8CH3_AL1_WRITE_ADDRAlias for channel 3 WRITE_ADDR register
0x0dcCH3_AL1_TRANS_COUNT_TRIGAlias for channel 3 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x0e0CH3_AL2_CTRLAlias for channel 3 CTRL register
0x0e4CH3_AL2_TRANS_COUNTAlias for channel 3 TRANS_COUNT register
0x0e8CH3_AL2_READ_ADDRAlias for channel 3 READ_ADDR register
0x0ecCH3_AL2_WRITE_ADDR_TRIGAlias for channel 3 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x0f0CH3_AL3_CTRLAlias for channel 3 CTRL register
0x0f4CH3_AL3_WRITE_ADDRAlias for channel 3 WRITE_ADDR register
0x0f8CH3_AL3_TRANS_COUNTAlias for channel 3 TRANS_COUNT register
0x0fcCH3_AL3_READ_ADDR_TRIGAlias for channel 3 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x100CH4_READ_ADDRDMA Channel 4 Read Address pointer
0x104CH4_WRITE_ADDRDMA Channel 4 Write Address pointer
0x108CH4_TRANS_COUNTDMA Channel 4 Transfer Count
0x10cCH4_CTRL_TRIGDMA Channel 4 Control and Status
0x110CH4_AL1_CTRLAlias for channel 4 CTRL register
0x114CH4_AL1_READ_ADDRAlias for channel 4 READ_ADDR register
0x118CH4_AL1_WRITE_ADDRAlias for channel 4 WRITE_ADDR register
0x11cCH4_AL1_TRANS_COUNT_TRIGAlias for channel 4 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x120CH4_AL2_CTRLAlias for channel 4 CTRL register
0x124CH4_AL2_TRANS_COUNTAlias for channel 4 TRANS_COUNT register
0x128CH4_AL2_READ_ADDRAlias for channel 4 READ_ADDR register
0x12cCH4_AL2_WRITE_ADDR_TRIGAlias for channel 4 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x130CH4_AL3_CTRLAlias for channel 4 CTRL register
OffsetNameInfo
0x134CH4_AL3_WRITE_ADDRAlias for channel 4 WRITE_ADDR register
0x138CH4_AL3_TRANS_COUNTAlias for channel 4 TRANS_COUNT register
0x13cCH4_AL3_READ_ADDR_TRIGAlias for channel 4 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x140CH5_READ_ADDRDMA Channel 5 Read Address pointer
0x144CH5_WRITE_ADDRDMA Channel 5 Write Address pointer
0x148CH5_TRANS_COUNTDMA Channel 5 Transfer Count
0x14cCH5_CTRL_TRIGDMA Channel 5 Control and Status
0x150CH5_AL1_CTRLAlias for channel 5 CTRL register
0x154CH5_AL1_READ_ADDRAlias for channel 5 READ_ADDR register
0x158CH5_AL1_WRITE_ADDRAlias for channel 5 WRITE_ADDR register
0x15cCH5_AL1_TRANS_COUNT_TRIGAlias for channel 5 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x160CH5_AL2_CTRLAlias for channel 5 CTRL register
0x164CH5_AL2_TRANS_COUNTAlias for channel 5 TRANS_COUNT register
0x168CH5_AL2_READ_ADDRAlias for channel 5 READ_ADDR register
0x16cCH5_AL2_WRITE_ADDR_TRIGAlias for channel 5 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x170CH5_AL3_CTRLAlias for channel 5 CTRL register
0x174CH5_AL3_WRITE_ADDRAlias for channel 5 WRITE_ADDR register
0x178CH5_AL3_TRANS_COUNTAlias for channel 5 TRANS_COUNT register
0x17cCH5_AL3_READ_ADDR_TRIGAlias for channel 5 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x180CH6_READ_ADDRDMA Channel 6 Read Address pointer
0x184CH6_WRITE_ADDRDMA Channel 6 Write Address pointer
0x188CH6_TRANS_COUNTDMA Channel 6 Transfer Count
0x18cCH6_CTRL_TRIGDMA Channel 6 Control and Status
0x190CH6_AL1_CTRLAlias for channel 6 CTRL register
0x194CH6_AL1_READ_ADDRAlias for channel 6 READ_ADDR register
0x198CH6_AL1_WRITE_ADDRAlias for channel 6 WRITE_ADDR register
0x19cCH6_AL1_TRANS_COUNT_TRIGAlias for channel 6 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x1a0CH6_AL2_CTRLAlias for channel 6 CTRL register
0x1a4CH6_AL2_TRANS_COUNTAlias for channel 6 TRANS_COUNT register
OffsetNameInfo
0x1a8CH6_AL2_READ_ADDRAlias for channel 6 READ_ADDR register
0x1acCH6_AL2_WRITE_ADDR_TRIGAlias for channel 6 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x1b0CH6_AL3_CTRLAlias for channel 6 CTRL register
0x1b4CH6_AL3_WRITE_ADDRAlias for channel 6 WRITE_ADDR register
0x1b8CH6_AL3_TRANS_COUNTAlias for channel 6 TRANS_COUNT register
0x1bcCH6_AL3_READ_ADDR_TRIGAlias for channel 6 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x1c0CH7_READ_ADDRDMA Channel 7 Read Address pointer
0x1c4CH7_WRITE_ADDRDMA Channel 7 Write Address pointer
0x1c8CH7_TRANS_COUNTDMA Channel 7 Transfer Count
0x1ccCH7_CTRL_TRIGDMA Channel 7 Control and Status
0x1d0CH7_AL1_CTRLAlias for channel 7 CTRL register
0x1d4CH7_AL1_READ_ADDRAlias for channel 7 READ_ADDR register
0x1d8CH7_AL1_WRITE_ADDRAlias for channel 7 WRITE_ADDR register
0x1dcCH7_AL1_TRANS_COUNT_TRIGAlias for channel 7 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x1e0CH7_AL2_CTRLAlias for channel 7 CTRL register
0x1e4CH7_AL2_TRANS_COUNTAlias for channel 7 TRANS_COUNT register
0x1e8CH7_AL2_READ_ADDRAlias for channel 7 READ_ADDR register
0x1ecCH7_AL2_WRITE_ADDR_TRIGAlias for channel 7 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x1f0CH7_AL3_CTRLAlias for channel 7 CTRL register
0x1f4CH7_AL3_WRITE_ADDRAlias for channel 7 WRITE_ADDR register
0x1f8CH7_AL3_TRANS_COUNTAlias for channel 7 TRANS_COUNT register
0x1fcCH7_AL3_READ_ADDR_TRIGAlias for channel 7 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x200CH8_READ_ADDRDMA Channel 8 Read Address pointer
0x204CH8_WRITE_ADDRDMA Channel 8 Write Address pointer
0x208CH8_TRANS_COUNTDMA Channel 8 Transfer Count
0x20cCH8_CTRL_TRIGDMA Channel 8 Control and Status
0x210CH8_AL1_CTRLAlias for channel 8 CTRL register
0x214CH8_AL1_READ_ADDRAlias for channel 8 READ_ADDR register
0x218CH8_AL1_WRITE_ADDRAlias for channel 8 WRITE_ADDR register
OffsetNameInfo
0x21cCH8_AL1_TRANS_COUNT_TRIGAlias for channel 8 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x220CH8_AL2_CTRLAlias for channel 8 CTRL register
0x224CH8_AL2_TRANS_COUNTAlias for channel 8 TRANS_COUNT register
0x228CH8_AL2_READ_ADDRAlias for channel 8 READ_ADDR register
0x22cCH8_AL2_WRITE_ADDR_TRIGAlias for channel 8 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x230CH8_AL3_CTRLAlias for channel 8 CTRL register
0x234CH8_AL3_WRITE_ADDRAlias for channel 8 WRITE_ADDR register
0x238CH8_AL3_TRANS_COUNTAlias for channel 8 TRANS_COUNT register
0x23cCH8_AL3_READ_ADDR_TRIGAlias for channel 8 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x240CH9_READ_ADDRDMA Channel 9 Read Address pointer
0x244CH9_WRITE_ADDRDMA Channel 9 Write Address pointer
0x248CH9_TRANS_COUNTDMA Channel 9 Transfer Count
0x24cCH9_CTRL_TRIGDMA Channel 9 Control and Status
0x250CH9_AL1_CTRLAlias for channel 9 CTRL register
0x254CH9_AL1_READ_ADDRAlias for channel 9 READ_ADDR register
0x258CH9_AL1_WRITE_ADDRAlias for channel 9 WRITE_ADDR register
0x25cCH9_AL1_TRANS_COUNT_TRIGAlias for channel 9 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x260CH9_AL2_CTRLAlias for channel 9 CTRL register
0x264CH9_AL2_TRANS_COUNTAlias for channel 9 TRANS_COUNT register
0x268CH9_AL2_READ_ADDRAlias for channel 9 READ_ADDR register
0x26cCH9_AL2_WRITE_ADDR_TRIGAlias for channel 9 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x270CH9_AL3_CTRLAlias for channel 9 CTRL register
0x274CH9_AL3_WRITE_ADDRAlias for channel 9 WRITE_ADDR register
0x278CH9_AL3_TRANS_COUNTAlias for channel 9 TRANS_COUNT register
0x27cCH9_AL3_READ_ADDR_TRIGAlias for channel 9 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x280CH10_READ_ADDRDMA Channel 10 Read Address pointer
0x284CH10_WRITE_ADDRDMA Channel 10 Write Address pointer
0x288CH10_TRANS_COUNTDMA Channel 10 Transfer Count
OffsetNameInfo
0x28cCH10_CTRL_TRIGDMA Channel 10 Control and Status
0x290CH10_AL1_CTRLAlias for channel 10 CTRL register
0x294CH10_AL1_READ_ADDRAlias for channel 10 READ_ADDR register
0x298CH10_AL1_WRITE_ADDRAlias for channel 10 WRITE_ADDR register
0x29cCH10_AL1_TRANS_COUNT_TRIGAlias for channel 10 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x2a0CH10_AL2_CTRLAlias for channel 10 CTRL register
0x2a4CH10_AL2_TRANS_COUNTAlias for channel 10 TRANS_COUNT register
0x2a8CH10_AL2_READ_ADDRAlias for channel 10 READ_ADDR register
0x2acCH10_AL2_WRITE_ADDR_TRIGAlias for channel 10 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x2b0CH10_AL3_CTRLAlias for channel 10 CTRL register
0x2b4CH10_AL3_WRITE_ADDRAlias for channel 10 WRITE_ADDR register
0x2b8CH10_AL3_TRANS_COUNTAlias for channel 10 TRANS_COUNT register
0x2bcCH10_AL3_READ_ADDR_TRIGAlias for channel 10 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x2c0CH11_READ_ADDRDMA Channel 11 Read Address pointer
0x2c4CH11_WRITE_ADDRDMA Channel 11 Write Address pointer
0x2c8CH11_TRANS_COUNTDMA Channel 11 Transfer Count
0x2ccCH11_CTRL_TRIGDMA Channel 11 Control and Status
0x2d0CH11_AL1_CTRLAlias for channel 11 CTRL register
0x2d4CH11_AL1_READ_ADDRAlias for channel 11 READ_ADDR register
0x2d8CH11_AL1_WRITE_ADDRAlias for channel 11 WRITE_ADDR register
0x2dcCH11_AL1_TRANS_COUNT_TRIGAlias for channel 11 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x2e0CH11_AL2_CTRLAlias for channel 11 CTRL register
0x2e4CH11_AL2_TRANS_COUNTAlias for channel 11 TRANS_COUNT register
0x2e8CH11_AL2_READ_ADDRAlias for channel 11 READ_ADDR register
0x2ecCH11_AL2_WRITE_ADDR_TRIGAlias for channel 11 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x2f0CH11_AL3_CTRLAlias for channel 11 CTRL register
0x2f4CH11_AL3_WRITE_ADDRAlias for channel 11 WRITE_ADDR register
0x2f8CH11_AL3_TRANS_COUNTAlias for channel 11 TRANS_COUNT register
OffsetNameInfo
0x2fcCH11_AL3_READ_ADDR_TRIGAlias for channel 11 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x300CH12_READ_ADDRDMA Channel 12 Read Address pointer
0x304CH12_WRITE_ADDRDMA Channel 12 Write Address pointer
0x308CH12_TRANS_COUNTDMA Channel 12 Transfer Count
0x30cCH12_CTRL_TRIGDMA Channel 12 Control and Status
0x310CH12_AL1_CTRLAlias for channel 12 CTRL register
0x314CH12_AL1_READ_ADDRAlias for channel 12 READ_ADDR register
0x318CH12_AL1_WRITE_ADDRAlias for channel 12 WRITE_ADDR register
0x31cCH12_AL1_TRANS_COUNT_TRIGAlias for channel 12 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x320CH12_AL2_CTRLAlias for channel 12 CTRL register
0x324CH12_AL2_TRANS_COUNTAlias for channel 12 TRANS_COUNT register
0x328CH12_AL2_READ_ADDRAlias for channel 12 READ_ADDR register
0x32cCH12_AL2_WRITE_ADDR_TRIGAlias for channel 12 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x330CH12_AL3_CTRLAlias for channel 12 CTRL register
0x334CH12_AL3_WRITE_ADDRAlias for channel 12 WRITE_ADDR register
0x338CH12_AL3_TRANS_COUNTAlias for channel 12 TRANS_COUNT register
0x33cCH12_AL3_READ_ADDR_TRIGAlias for channel 12 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x340CH13_READ_ADDRDMA Channel 13 Read Address pointer
0x344CH13_WRITE_ADDRDMA Channel 13 Write Address pointer
0x348CH13_TRANS_COUNTDMA Channel 13 Transfer Count
0x34cCH13_CTRL_TRIGDMA Channel 13 Control and Status
0x350CH13_AL1_CTRLAlias for channel 13 CTRL register
0x354CH13_AL1_READ_ADDRAlias for channel 13 READ_ADDR register
0x358CH13_AL1_WRITE_ADDRAlias for channel 13 WRITE_ADDR register
0x35cCH13_AL1_TRANS_COUNT_TRIGAlias for channel 13 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x360CH13_AL2_CTRLAlias for channel 13 CTRL register
0x364CH13_AL2_TRANS_COUNTAlias for channel 13 TRANS_COUNT register
0x368CH13_AL2_READ_ADDRAlias for channel 13 READ_ADDR register
OffsetNameInfo
0x36cCH13_AL2_WRITE_ADDR_TRIGAlias for channel 13 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x370CH13_AL3_CTRLAlias for channel 13 CTRL register
0x374CH13_AL3_WRITE_ADDRAlias for channel 13 WRITE_ADDR register
0x378CH13_AL3_TRANS_COUNTAlias for channel 13 TRANS_COUNT register
0x37cCH13_AL3_READ_ADDR_TRIGAlias for channel 13 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x380CH14_READ_ADDRDMA Channel 14 Read Address pointer
0x384CH14_WRITE_ADDRDMA Channel 14 Write Address pointer
0x388CH14_TRANS_COUNTDMA Channel 14 Transfer Count
0x38cCH14_CTRL_TRIGDMA Channel 14 Control and Status
0x390CH14_AL1_CTRLAlias for channel 14 CTRL register
0x394CH14_AL1_READ_ADDRAlias for channel 14 READ_ADDR register
0x398CH14_AL1_WRITE_ADDRAlias for channel 14 WRITE_ADDR register
0x39cCH14_AL1_TRANS_COUNT_TRIGAlias for channel 14 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x3a0CH14_AL2_CTRLAlias for channel 14 CTRL register
0x3a4CH14_AL2_TRANS_COUNTAlias for channel 14 TRANS_COUNT register
0x3a8CH14_AL2_READ_ADDRAlias for channel 14 READ_ADDR register
0x3acCH14_AL2_WRITE_ADDR_TRIGAlias for channel 14 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x3b0CH14_AL3_CTRLAlias for channel 14 CTRL register
0x3b4CH14_AL3_WRITE_ADDRAlias for channel 14 WRITE_ADDR register
0x3b8CH14_AL3_TRANS_COUNTAlias for channel 14 TRANS_COUNT register
0x3bcCH14_AL3_READ_ADDR_TRIGAlias for channel 14 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x3c0CH15_READ_ADDRDMA Channel 15 Read Address pointer
0x3c4CH15_WRITE_ADDRDMA Channel 15 Write Address pointer
0x3c8CH15_TRANS_COUNTDMA Channel 15 Transfer Count
0x3ccCH15_CTRL_TRIGDMA Channel 15 Control and Status
0x3d0CH15_AL1_CTRLAlias for channel 15 CTRL register
0x3d4CH15_AL1_READ_ADDRAlias for channel 15 READ_ADDR register
0x3d8CH15_AL1_WRITE_ADDRAlias for channel 15 WRITE_ADDR register
OffsetNameInfo
0x3dcCH15_AL1_TRANS_COUNT_TRIGAlias for channel 15 TRANS_COUNT register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x3e0CH15_AL2_CTRLAlias for channel 15 CTRL register
0x3e4CH15_AL2_TRANS_COUNTAlias for channel 15 TRANS_COUNT register
0x3e8CH15_AL2_READ_ADDRAlias for channel 15 READ_ADDR register
0x3ecCH15_AL2_WRITE_ADDR_TRIGAlias for channel 15 WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x3f0CH15_AL3_CTRLAlias for channel 15 CTRL register
0x3f4CH15_AL3_WRITE_ADDRAlias for channel 15 WRITE_ADDR register
0x3f8CH15_AL3_TRANS_COUNTAlias for channel 15 TRANS_COUNT register
0x3fcCH15_AL3_READ_ADDR_TRIGAlias for channel 15 READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
0x400INTRInterrupt Status (raw)
0x404INTE0Interrupt Enables for IRQ 0
0x408INTF0Force Interrupts
0x40cINTS0Interrupt Status for IRQ 0
0x414INTE1Interrupt Enables for IRQ 1
0x418INTF1Force Interrupts
0x41cINTS1Interrupt Status for IRQ 1
0x424INTE2Interrupt Enables for IRQ 2
0x428INTF2Force Interrupts
0x42cINTS2Interrupt Status for IRQ 2
0x434INTE3Interrupt Enables for IRQ 3
0x438INTF3Force Interrupts
0x43cINTS3Interrupt Status for IRQ 3
0x440TIMER0Pacing timer (generate periodic TREQs)
0x444TIMER1Pacing timer (generate periodic TREQs)
0x448TIMER2Pacing timer (generate periodic TREQs)
0x44cTIMER3Pacing timer (generate periodic TREQs)
0x450MULTI_CHAN_TRIGGERTrigger one or more channels simultaneously
0x454SNIFF_CTRLSniffer Control
0x458SNIFF_DATAData accumulator for sniff hardware
0x460FIFO_LEVELSDebug RAF, WAF, TDF levels
0x464CHAN_ABORTAbort an in-progress transfer sequence on one or more channels
OffsetNameInfo
0x468N_CHANNELSThe number of channels this DMA instance is equipped with. This DMA supports up to 16 hardware channels, but can be configured with as few as one, to minimise silicon area.
0x480SECCFG_CH0Security level configuration for channel 0.
0x484SECCFG_CH1Security level configuration for channel 1.
0x488SECCFG_CH2Security level configuration for channel 2.
0x48cSECCFG_CH3Security level configuration for channel 3.
0x490SECCFG_CH4Security level configuration for channel 4.
0x494SECCFG_CH5Security level configuration for channel 5.
0x498SECCFG_CH6Security level configuration for channel 6.
0x49cSECCFG_CH7Security level configuration for channel 7.
0x4a0SECCFG_CH8Security level configuration for channel 8.
0x4a4SECCFG_CH9Security level configuration for channel 9.
0x4a8SECCFG_CH10Security level configuration for channel 10.
0x4acSECCFG_CH11Security level configuration for channel 11.
0x4b0SECCFG_CH12Security level configuration for channel 12.
0x4b4SECCFG_CH13Security level configuration for channel 13.
0x4b8SECCFG_CH14Security level configuration for channel 14.
0x4bcSECCFG_CH15Security level configuration for channel 15.
0x4c0SECCFG_IRQ0Security configuration for IRQ 0. Control whether the IRQ permits configuration by Non-secure/Unprivileged contexts, and whether it can observe Secure/Privileged channel interrupt flags.
0x4c4SECCFG_IRQ1Security configuration for IRQ 1. Control whether the IRQ permits configuration by Non-secure/Unprivileged contexts, and whether it can observe Secure/Privileged channel interrupt flags.
0x4c8SECCFG_IRQ2Security configuration for IRQ 2. Control whether the IRQ permits configuration by Non-secure/Unprivileged contexts, and whether it can observe Secure/Privileged channel interrupt flags.
0x4ccSECCFG_IRQ3Security configuration for IRQ 3. Control whether the IRQ permits configuration by Non-secure/Unprivileged contexts, and whether it can observe Secure/Privileged channel interrupt flags.
0x4d0SECCFG_MISCMiscellaneous security configuration
0x500MPU_CTRLControl register for DMA MPU. Accessible only from a Privileged context.
0x504MPU_BAR0Base address register for MPU region 0. Writable only from a Secure, Privileged context.
0x508MPU_LAR0Limit address register for MPU region 0. Writable only from a Secure, Privileged context, with the exception of the P bit.
0x50cMPU_BAR1Base address register for MPU region 1. Writable only from a Secure, Privileged context.
OffsetNameInfo
0x510MPU_LAR1Limit address register for MPU region 1. Writable only from a Secure, Privileged context, with the exception of the P bit.
0x514MPU_BAR2Base address register for MPU region 2. Writable only from a Secure, Privileged context.
0x518MPU_LAR2Limit address register for MPU region 2. Writable only from a Secure, Privileged context, with the exception of the P bit.
0x51cMPU_BAR3Base address register for MPU region 3. Writable only from a Secure, Privileged context.
0x520MPU_LAR3Limit address register for MPU region 3. Writable only from a Secure, Privileged context, with the exception of the P bit.
0x524MPU_BAR4Base address register for MPU region 4. Writable only from a Secure, Privileged context.
0x528MPU_LAR4Limit address register for MPU region 4. Writable only from a Secure, Privileged context, with the exception of the P bit.
0x52cMPU_BAR5Base address register for MPU region 5. Writable only from a Secure, Privileged context.
0x530MPU_LAR5Limit address register for MPU region 5. Writable only from a Secure, Privileged context, with the exception of the P bit.
0x534MPU_BAR6Base address register for MPU region 6. Writable only from a Secure, Privileged context.
0x538MPU_LAR6Limit address register for MPU region 6. Writable only from a Secure, Privileged context, with the exception of the P bit.
0x53cMPU_BAR7Base address register for MPU region 7. Writable only from a Secure, Privileged context.
0x540MPU_LAR7Limit address register for MPU region 7. Writable only from a Secure, Privileged context, with the exception of the P bit.
0x800CH0_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0x804CH0_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0x840CH1_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0x844CH1_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0x880CH2_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0x884CH2_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
OffsetNameInfo
0x8c0CH3_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0x8c4CH3_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0x900CH4_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0x904CH4_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0x940CH5_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0x944CH5_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0x980CH6_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0x984CH6_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0x9c0CH7_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0x9c4CH7_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0xa00CH8_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0xa04CH8_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0xa40CH9_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0xa44CH9_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0xa80CH10_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
OffsetNameInfo
0xa84CH10_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0xac0CH11_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0xac4CH11_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0xb00CH12_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0xb04CH12_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0xb40CH13_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0xb44CH13_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0xb80CH14_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0xb84CH14_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer
0xbc0CH15_DBG_CTDREQRead: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.
0xbc4CH15_DBG_TCRRead to get channel TRANS_COUNT reload value, i.e. the length of the next transfer

DMA: CH0_READ_ADDR , CH1_READ_ADDR , ..., CH14_READ_ADDR , CH15_READ_ADDR Registers

Offsets: 0x000, 0x040, ..., 0x380, 0x3c0

Description

DMA Channel N Read Address pointer

Table 1148.
CH0_READ_ADDR ,
CH1_READ_ADDR , ...,
CH14_READ_ADDR ,
CH15_READ_ADDR
Registers

BitsDescriptionTypeReset
31:0This register updates automatically each time a read completes. The current value is the next address to be read by this channel.RW0x00000000

DMA: CH0_WRITE_ADDR , CH1_WRITE_ADDR , ..., CH14_WRITE_ADDR , CH15_WRITE_ADDR Registers

Offsets: 0x004, 0x044, ..., 0x384, 0x3c4

Description DMA Channel N Write Address pointer

Table 1149.
CH0_WRITE_ADDR,
CH1_WRITE_ADDR, ...,
CH14_WRITE_ADDR,
CH15_WRITE_ADDR
Registers

BitsDescriptionTypeReset
31:0This register updates automatically each time a write completes. The current value is the next address to be written by this channel.RW0x00000000

DMA: CH0_TRANS_COUNT, CH1_TRANS_COUNT, ..., CH14_TRANS_COUNT, CH15_TRANS_COUNT Registers

Offsets: 0x008, 0x048, ..., 0x388, 0x3c8 Description DMA Channel N Transfer Count

Table 1150.
CH0_TRANS_COUNT,
CH1_TRANS_COUNT,
...,
CH14_TRANS_COUNT,
CH15_TRANS_COUNT
Registers

BitsDescriptionTypeReset
31:28

MODE: When MODE is 0x0, the transfer count decrements with each transfer until 0, and then the channel triggers the next channel indicated by CTRL_CHAIN_TO.

When MODE is 0x1, the transfer count decrements with each transfer until 0, and then the channel re-triggers itself, in addition to the trigger indicated by CTRL_CHAIN_TO. This is useful for e.g. an endless ring-buffer DMA with periodic interrupts.

When MODE is 0xf, the transfer count does not decrement. The DMA channel performs an endless sequence of transfers, never triggering other channels or raising interrupts, until an ABORT is raised.

All other values are reserved.

RW0x0
Enumerated values:
0x0 → NORMAL
0x1 → TRIGGER_SELF
0xf → ENDLESS
27:0

COUNT: 28-bit transfer count (256 million transfers maximum).

Program the number of bus transfers a channel will perform before halting. Note that, if transfers are larger than one byte in size, this is not equal to the number of bytes transferred (see CTRL_DATA_SIZE).

When the channel is active, reading this register shows the number of transfers remaining, updating automatically each time a write transfer completes.

Writing this register sets the RELOAD value for the transfer counter. Each time this channel is triggered, the RELOAD value is copied into the live transfer counter. The channel can be started multiple times, and will perform the same number of transfers each time, as programmed by most recent write.

The RELOAD value can be observed at CHx_DBG_TCR. If TRANS_COUNT is used as a trigger, the written value is used immediately as the length of the new transfer sequence, as well as being written to RELOAD.

RW0x00000000

DMA: CH0_CTRL_TRIG, CH1_CTRL_TRIG, ..., CH14_CTRL_TRIG, CH15_CTRL_TRIG Registers

Offsets: 0x00c, 0x04c, ..., 0x38c, 0x3cc

Description

DMA Channel N Control and Status

Table 1151.
CH0_CTRL_TRIG,
CH1_CTRL_TRIG, ...,
CH14_CTRL_TRIG,
CH15_CTRL_TRIG
Registers

Bits 31:0 Bits 31:0 Bits 31:28column_2Description Description Input value for GPIO0…31. Description QSPI_SD : Input value on QSPI SD0 (MOSI), SD1 (MISO), SD2 and SD3 pinsType RO Type RO Type ROReset - Reset 0x00000000 Reset 0x0
28:27Reserved.--
26BUSY: This flag goes high when the channel starts a new transfer sequence, BUSY is high pauses the channel, and BUSY will stay high while paused.RO0x0
25SNIFF_EN: If 1, this channel’s data transfers are visible to the sniff hardware, the sniff hardware is enabled, and has this channel selected.RW0x0
24BSWAP: Apply byte-swap transformation to DMA data. For byte data, this has no effect. For halfword data, the two bytes of each halfword are swapped. For word data, the four bytes of each word are swapped to reverse order.RW0x0
23IRQ_QUIET: In QUIET mode, the channel does not generate IRQs at the end of register, indicating the end of a control block chain. This reduces the number of interrupts to be serviced by the CPU when transferring a DMA chain of many small control blocks.RW0x0
22:17TREQ_SEL: Select a Transfer Request signal. The channel uses the transfer request signal to pace its data transfer rate. Sources for TREQ signals are internal (TIMERS) or external (DREQ, a Data Request from the system).RW0x00
0x0 to 0x3a 0x3b → 0x3c → 0x3d →→ select DREQ n as TREQ Enumerated values: TIMER0: Select Timer 0 as TREQ TIMER1: Select Timer 1 as TREQ TIMER2: Select Timer 2 as TREQ (Optional)
BitsDescriptionTypeReset
0x3f → PERMANENT: Permanent request, for unpaced transfers.
16:13CHAIN_TO: When this channel completes, it will trigger the channel indicated by CHAIN_TO. Disable by setting CHAIN_TO = (this channel) .

Note this field resets to 0, so channels 1 and above will chain to channel 0 by default. Set this field to avoid this behaviour.
RW0x0
12RING_SEL: Select whether RING_SIZE applies to read or write addresses. If 0, read addresses are wrapped on a \( (1 \ll \text{RING\_SIZE}) \) boundary. If 1, write addresses are wrapped.RW0x0
11:8RING_SIZE: Size of address wrap region. If 0, don't wrap. For values \( n > 0 \) , only the lower \( n \) bits of the address will change. This wraps the address on a \( (1 \ll n) \) byte boundary, facilitating access to naturally-aligned ring buffers.

Ring sizes between 2 and 32768 bytes are possible. This can apply to either read or write addresses, based on value of RING_SEL.
RW0x0
Enumerated values:
0x0 → RING_NONE
7INCR_WRITE_REV: If 1, and INCR_WRITE is 1, the write address is decremented rather than incremented with each transfer.

If 1, and INCR_WRITE is 0, this otherwise-unused combination causes the write address to be incremented by twice the transfer size, i.e. skipping over alternate addresses.
RW0x0
6INCR_WRITE: If 1, the write address increments with each transfer. If 0, each write is directed to the same, initial address.

Generally this should be disabled for memory-to-peripheral transfers.
RW0x0
5INCR_READ_REV: If 1, and INCR_READ is 1, the read address is decremented rather than incremented with each transfer.

If 1, and INCR_READ is 0, this otherwise-unused combination causes the read address to be incremented by twice the transfer size, i.e. skipping over alternate addresses.
RW0x0
4INCR_READ: If 1, the read address increments with each transfer. If 0, each read is directed to the same, initial address.

Generally this should be disabled for peripheral-to-memory transfers.
RW0x0
3:2DATA_SIZE: Set the size of each bus transfer (byte/halfword/word). READ_ADDR and WRITE_ADDR advance by this amount (1/2/4 bytes) with each transfer.RW0x0
Enumerated values:
0x0 → SIZE_BYTE
0x1 → SIZE_HALFWORD
0x2 → SIZE_WORD
BitsDescriptionTypeReset
1HIGH_PRIORITY: HIGH_PRIORITY gives a channel preferential treatment in issue scheduling: in each scheduling round, all high priority channels are considered first, and then only a single low priority channel, before returning to the high priority channels.

This only affects the order in which the DMA schedules channels. The DMA's bus priority is not changed. If the DMA is not saturated then a low priority channel will see no loss of throughput.
RW0x0
0EN: DMA Channel Enable.
When 1, the channel will respond to triggering events, which will cause it to become BUSY and start transferring data. When 0, the channel will ignore triggers, stop issuing transfers, and pause the current transfer sequence (i.e. BUSY will remain high if already high)
RW0x0

DMA: CH0_AL1_CTRL, CH1_AL1_CTRL, ..., CH14_AL1_CTRL, CH15_AL1_CTRL Registers

Offsets: 0x010, 0x050, ..., 0x390, 0x3d0

Table 1152.
CH0_AL1_CTRL,
CH1_AL1_CTRL, ...,
CH14_AL1_CTRL,
CH15_AL1_CTRL
Registers

BitsDescriptionTypeReset
31:0Alias for channel N CTRL registerRW-

DMA: CH0_AL1_READ_ADDR, CH1_AL1_READ_ADDR, ..., CH14_AL1_READ_ADDR, CH15_AL1_READ_ADDR Registers

Offsets: 0x014, 0x054, ..., 0x394, 0x3d4

Table 1153.
CH0_AL1_READ_ADDR
,
CH1_AL1_READ_ADDR
, ...,
CH14_AL1_READ_ADDR,
CH15_AL1_READ_ADDR
Registers

BitsDescriptionTypeReset
31:0Alias for channel N READ_ADDR registerRW-

DMA: CH0_AL1_WRITE_ADDR, CH1_AL1_WRITE_ADDR, ..., CH14_AL1_WRITE_ADDR, CH15_AL1_WRITE_ADDR Registers

Offsets: 0x018, 0x058, ..., 0x398, 0x3d8

Table 1154.
CH0_AL1_WRITE_ADDR,
CH1_AL1_WRITE_ADDR,
...,
CH14_AL1_WRITE_ADDR,
CH15_AL1_WRITE_ADDR
Registers

BitsDescriptionTypeReset
31:0Alias for channel N WRITE_ADDR registerRW-

DMA: CH0_AL1_TRANS_COUNT_TRIG, CH1_AL1_TRANS_COUNT_TRIG, ..., CH14_AL1_TRANS_COUNT_TRIG, CH15_AL1_TRANS_COUNT_TRIG Registers

Offsets: 0x01c, 0x05c, ..., 0x39c, 0x3dc

Table 1155.
CH0_AL1_TRANS_COUNT_TRIG,
CH1_AL1_TRANS_COUNT_TRIG,
...,
CH14_AL1_TRANS_COUNT_TRIG,
CH15_AL1_TRANS_COUNT_TRIG
Registers

BitsDescriptionTypeReset
31:0Alias for channel N TRANS_COUNT register

This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
RW-

DMA: CH0_AL2_CTRL, CH1_AL2_CTRL, ..., CH14_AL2_CTRL, CH15_AL2_CTRL Registers

Offsets: 0x020, 0x060, ..., 0x3a0, 0x3e0

Table 1156.
CH0_AL2_CTRL,
CH1_AL2_CTRL, ...,
CH14_AL2_CTRL,
CH15_AL2_CTRL
Registers

BitsDescriptionTypeReset
31:0Alias for channel N CTRL registerRW-

DMA: CH0_AL2_TRANS_COUNT, CH1_AL2_TRANS_COUNT, ...,
CH14_AL2_TRANS_COUNT, CH15_AL2_TRANS_COUNT Registers

Offsets: 0x024, 0x064, ..., 0x3a4, 0x3e4

Table 1157.
CH0_AL2_TRANS_COUNT,
CH1_AL2_TRANS_COUNT,
...,
CH14_AL2_TRANS_COUNT,
CH15_AL2_TRANS_COUNT
Registers

BitsDescriptionTypeReset
31:0Alias for channel N TRANS_COUNT registerRW-

DMA: CH0_AL2_READ_ADDR, CH1_AL2_READ_ADDR, ...,
CH14_AL2_READ_ADDR, CH15_AL2_READ_ADDR Registers

Offsets: 0x028, 0x068, ..., 0x3a8, 0x3e8

Table 1158.
CH0_AL2_READ_ADDR,
...,
CH1_AL2_READ_ADDR,
...,
CH14_AL2_READ_ADDR,
...,
CH15_AL2_READ_ADDR
Registers

BitsDescriptionTypeReset
31:0Alias for channel N READ_ADDR registerRW-

DMA: CH0_AL2_WRITE_ADDR_TRIG, CH1_AL2_WRITE_ADDR_TRIG, ...,
CH14_AL2_WRITE_ADDR_TRIG, CH15_AL2_WRITE_ADDR_TRIG Registers

Offsets: 0x02c, 0x06c, ..., 0x3ac, 0x3ec

Table 1159.
CH0_AL2_WRITE_ADDR_TRIG,
CH1_AL2_WRITE_ADDR_TRIG,
...,
CH14_AL2_WRITE_ADDR_TRIG,
CH15_AL2_WRITE_ADDR_TRIG
Registers

BitsDescriptionTypeReset
31:0Alias for channel N WRITE_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
RW-

DMA: CH0_AL3_CTRL, CH1_AL3_CTRL, ..., CH14_AL3_CTRL, CH15_AL3_CTRL
Registers

Offsets: 0x030, 0x070, ..., 0x3b0, 0x3f0

Table 1160.
CH0_AL3_CTRL,
CH1_AL3_CTRL, ...,
CH14_AL3_CTRL,
CH15_AL3_CTRL
Registers

BitsDescriptionTypeReset
31:0Alias for channel N CTRL registerRW-

DMA: CH0_AL3_WRITE_ADDR, CH1_AL3_WRITE_ADDR, ...,
CH14_AL3_WRITE_ADDR, CH15_AL3_WRITE_ADDR Registers

Offsets: 0x034, 0x074, ..., 0x3b4, 0x3f4

Table 1161.
CH0_AL3_WRITE_ADDR,
CH1_AL3_WRITE_ADDR,
...,
CH14_AL3_WRITE_ADDR,
CH15_AL3_WRITE_ADDR
Registers

BitsDescriptionTypeReset
31:0Alias for channel N WRITE_ADDR registerRW-

DMA: CH0_AL3_TRANS_COUNT, CH1_AL3_TRANS_COUNT, ...,
CH14_AL3_TRANS_COUNT, CH15_AL3_TRANS_COUNT Registers

Offsets: 0x038, 0x078, ..., 0x3b8, 0x3f8

Table 1162.
CH0_AL3_TRANS_COUNT,
CH1_AL3_TRANS_COUNT,
...,
CH14_AL3_TRANS_COUNT,
CH15_AL3_TRANS_COUNT Registers

BitsDescriptionTypeReset
31:0Alias for channel N TRANS_COUNT registerRW-

DMA: CH0_AL3_READ_ADDR_TRIG, CH1_AL3_READ_ADDR_TRIG, ..., CH14_AL3_READ_ADDR_TRIG, CH15_AL3_READ_ADDR_TRIG Registers

Offsets: 0x03c, 0x07c, ..., 0x3bc, 0x3fc

Table 1163.
CH0_AL3_READ_ADDR_TRIG,
CH1_AL3_READ_ADDR_TRIG,
...,
CH14_AL3_READ_ADDR_TRIG,
CH15_AL3_READ_ADDR_TRIG Registers

BitsDescriptionTypeReset
31:0Alias for channel N READ_ADDR register
This is a trigger register (0xc). Writing a nonzero value will reload the channel counter and start the channel.
RW-

DMA: INTR Register

Offset: 0x400

Description

Interrupt Status (raw)

Table 1164. INTR Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Raw interrupt status for DMA Channels 0..15. Bit n corresponds to channel n. Ignores any masking or forcing. Channel interrupts can be cleared by writing a bit mask to INTR or INTS0/1/2/3.

Channel interrupts can be routed to either of four system-level IRQs based on INTE0, INTE1, INTE2 and INTE3.

The multiple system-level interrupts might be used to allow NVIC IRQ preemption for more time-critical channels, to spread IRQ load across different cores, or to target IRQs to different security domains.

It is also valid to ignore the multiple IRQs, and just use INTE0/INTS0/IRQ 0.

If this register is accessed at a security/privilege level less than that of a given channel (as defined by that channel's SECCFG_CHx register), then that channel's interrupt status will read as 0, ignore writes.
WC0x0000

DMA: INTE0 Register

Offset: 0x404

Description

Interrupt Enables for IRQ 0

Table 1165. INTF0 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Set bit n to pass interrupts from channel n to DMA IRQ 0.

Note this bit has no effect if the channel security/privilege level, defined by SECCFG_CHx, is greater than the IRQ security/privilege defined by SECCFG_IRQ0.
RW0x0000

DMA: INTF0 Register

Offset: 0x408

Description

Force Interrupts

Table 1166. INTF0 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Write 1s to force the corresponding bits in INTS0. The interrupt remains asserted until INTF0 is cleared.RW0x0000

DMA: INTS0 Register

Offset: 0x40c

Description

Interrupt Status for IRQ 0

Table 1167. INTS0 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Indicates active channel interrupt requests which are currently causing IRQ 0 to be asserted.
Channel interrupts can be cleared by writing a bit mask here.

Channels with a security/privilege (SECCFG_CHx) greater SECCFG_IRQ0) read as 0 in this register, and ignore writes.
WC0x0000

DMA: INTE1 Register

Offset: 0x414

Description

Interrupt Enables for IRQ 1

Table 1168. INTF1 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Set bit n to pass interrupts from channel n to DMA IRQ 1.

Note this bit has no effect if the channel security/privilege level, defined by SECCFG_CHx, is greater than the IRQ security/privilege defined by SECCFG_IRQ1.
RW0x0000

DMA: INTF1 Register

Offset: 0x418

Description

Force Interrupts

Table 1169. INTF1 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Write 1s to force the corresponding bits in INTS1. The interrupt remains asserted until INTF1 is cleared.RW0x0000

DMA: INTS1 Register

Offset: 0x41c

Description

Interrupt Status for IRQ 1

Table 1170. INTS1 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Indicates active channel interrupt requests which are currently causing IRQ 1 to be asserted.
Channel interrupts can be cleared by writing a bit mask here.

Channels with a security/privilege (SECCFG_CHx) greater SECCFG_IRQ1) read as 0 in this register, and ignore writes.
WC0x0000

DMA: INTE2 Register

Offset: 0x424

Description

Interrupt Enables for IRQ 2

Table 1171. INTF2 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Set bit n to pass interrupts from channel n to DMA IRQ 2.

Note this bit has no effect if the channel security/privilege level, defined by SECCFG_CHx, is greater than the IRQ security/privilege defined by SECCFG_IRQ2.
RW0x0000

DMA: INTF2 Register

Offset: 0x428

Description

Force Interrupts

Table 1172. INTF2 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Write 1s to force the corresponding bits in INTS2. The interrupt remains asserted until INTF2 is cleared.RW0x0000

DMA: INTS2 Register

Offset: 0x42c

Description

Interrupt Status for IRQ 2

Table 1173. INTS2 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Indicates active channel interrupt requests which are currently causing IRQ 2 to be asserted.
Channel interrupts can be cleared by writing a bit mask here.

Channels with a security/privilege (SECCFG_CHx) greater SECCFG_IRQ2) read as 0 in this register, and ignore writes.
WC0x0000

DMA: INTE3 Register

Offset: 0x434

Description

Interrupt Enables for IRQ 3

Table 1174. INTF3 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Set bit n to pass interrupts from channel n to DMA IRQ 3.

Note this bit has no effect if the channel security/privilege level, defined by SECCFG_CHx, is greater than the IRQ security/privilege defined by SECCFG_IRQ3.
RW0x0000

DMA: INTF3 Register

Offset: 0x438

Description

Force Interrupts

Table 1175. INTF3 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Write 1s to force the corresponding bits in INTS3. The interrupt remains asserted until INTF3 is cleared.RW0x0000

DMA: INTS3 Register

Offset: 0x43c

Description

Interrupt Status for IRQ 3

Table 1176. INTS3 Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Indicates active channel interrupt requests which are currently causing IRQ 3 to be asserted.
Channel interrupts can be cleared by writing a bit mask here.

Channels with a security/privilege (SECCFG_CHx) greater SECCFG_IRQ3) read as 0 in this register, and ignore writes.
WC0x0000

DMA: TIMER0, TIMER1, TIMER2, TIMER3 Registers

Offsets: 0x440, 0x444, 0x448, 0x44c

Description

Pacing (X/Y) fractional timer

The pacing timer produces TREQ assertions at a rate set by ((X/Y) * sys_clk). This equation is evaluated every sys_clk cycles and therefore can only generate TREQs at a rate of 1 per sys_clk (i.e. permanent TREQ) or less.

Table 1177. TIMER0, TIMER1, TIMER2, TIMER3 Registers

BitsDescriptionTypeReset
31:16X: Pacing Timer Dividend. Specifies the X value for the (X/Y) fractional timer.RW0x0000
15:0Y: Pacing Timer Divisor. Specifies the Y value for the (X/Y) fractional timer.RW0x0000

DMA: MULTI_CHAN_TRIGGER Register

Offset: 0x450

Description

Trigger one or more channels simultaneously

Table 1178.
MULTI_CHAN_TRIGGER
Register

BitsDescriptionTypeReset
31:16Reserved.--
15:0Each bit in this register corresponds to a DMA channel. Writing a 1 to the relevant bit is the same as writing to that channel's trigger register; the channel will start if it is currently enabled and not already busy.SC0x0000
DMA: SNIFF_CTRL Register

Offset: 0x454

Description

Sniffer Control

Table 1179.
SNIFF_CTRL Register

BitsDescriptionTypeReset
31:12Reserved.--
11OUT_INV : If set, the result appears inverted (bitwise complement) when read. This does not affect the way the checksum is calculated; the result is transformed on-the-fly between the result register and the bus.RW0x0
10OUT_REV : If set, the result appears bit-reversed when read. This does not affect the way the checksum is calculated; the result is transformed on-the-fly between the result register and the bus.RW0x0
9BSWAP : Locally perform a byte reverse on the sniffed data, before feeding into checksum.

Note that the sniff hardware is downstream of the DMA channel byteswap performed in the read master: if channel CTRL_BSWAP and SNIFF_CTRL_BSWAP are both enabled, their effects cancel from the sniffer's point of view.
RW0x0
8:5CALCRW0x0
Enumerated values:
0x0 → CRC32: Calculate a CRC-32 (IEEE802.3 polynomial)
0x1 → CRC32R: Calculate a CRC-32 (IEEE802.3 polynomial) with bit reversed data
0x2 → CRC16: Calculate a CRC-16-CCITT
0x3 → CRC16R: Calculate a CRC-16-CCITT with bit reversed data
0xe → EVEN: XOR reduction over all data. == 1 if the total 1 population count is odd.
0xf → SUM: Calculate a simple 32-bit checksum (addition with a 32 bit accumulator)
4:1DMACH : DMA channel for Sniffer to observeRW0x0
0EN : Enable snifferRW0x0
DMA: SNIFF_DATA Register

Offset: 0x458

Description

Data accumulator for sniff hardware

Table 1180.
SNIFF_DATA Register
BitsDescriptionTypeReset
31:0Write an initial seed value here before starting a DMA transfer on the channel indicated by SNIFF_CTRL_DMACH. The hardware will update this register each time it observes a read from the indicated channel. Once the channel completes, the final result can be read from this register.RW0x00000000
DMA: FIFO_LEVELS Register Offset: 0x460 Description

Debug RAF, WAF, TDF levels

Table 1181.
FIFO_LEVELS Register
BitsDescriptionTypeReset
31:24Reserved.--
23:16RAF_LVL: Current Read-Address-FIFO fill levelRO0x00
15:8WAF_LVL: Current Write-Address-FIFO fill levelRO0x00
7:0TDF_LVL: Current Transfer-Data-FIFO fill levelRO0x00
DMA: CHAN_ABORT Register Offset: 0x464 Description

Abort an in-progress transfer sequence on one or more channels

Table 1182.
CHAN_ABORT Register
BitsDescriptionTypeReset
31:16Reserved.--
15:0Each bit corresponds to a channel. Writing a 1 aborts whatever transfer sequence is in progress on that channel. The bit will remain high until any in-flight transfers have been flushed through the address and data FIFOs.

After writing, this register must be polled until it returns all-zero. Until this point, it is unsafe to restart the channel.
SC0x0000
DMA: N_CHANNELS Register Offset: 0x468Table 1183.
N_CHANNELS Register
BitsDescriptionTypeReset
31:5Reserved.--
4:0The number of channels this DMA instance is equipped with. This DMA supports up to 16 hardware channels, but can be configured with as few as one, to minimise silicon area.RO-
DMA: SECCFG_CH0, SECCFG_CH1, ..., SECCFG_CH14, SECCFG_CH15 Registers Offsets: 0x480, 0x484, ..., 0x4b8, 0x4bc Description

Security configuration for channel N . Control whether this channel performs Secure/Non-secure and Privileged/Unprivileged bus accesses.

If this channel generates bus accesses of some security level, an access of at least that level (in the order S+P > S+U > NS+P > NS+U) is required to program, trigger, abort, check the status of, interrupt on or acknowledge the interrupt of this channel.

This register automatically locks down (becomes read-only) once software starts to configure the channel.

This register is world-readable, but is writable only from a Secure, Privileged context.

Table 1184.
SECCFG_CH0,
SECCFG_CH1, ...,
SECCFG_CH14,
SECCFG_CH15
Registers

BitsDescriptionTypeReset
31:3Reserved.--
2

LOCK : LOCK is 0 at reset, and is set to 1 automatically upon a successful write to this channel's control registers. That is, a write to CTRL, READ_ADDR, WRITE_ADDR, TRANS_COUNT and their aliases.

Once its LOCK bit is set, this register becomes read-only.

A failed write, for example due to the write's privilege being lower than that specified in the channel's SECCFG register, will not set the LOCK bit.

RW0x0
1

S : Secure channel. If 1, this channel performs Secure bus accesses. If 0, it performs Non-secure bus accesses.

If 1, this channel is controllable only from a Secure context.

RW0x1
0

P : Privileged channel. If 1, this channel performs Privileged bus accesses. If 0, it performs Unprivileged bus accesses.

If 1, this channel is controllable only from a Privileged context of the same Secure/Non-secure level, or any context of a higher Secure/Non-secure level.

RW0x1
DMA: SECCFG_IRQ0, SECCFG_IRQ1, SECCFG_IRQ2, SECCFG_IRQ3 Registers

Offsets: 0x4c0, 0x4c4, 0x4c8, 0x4cc

Description

Security configuration for IRQ N . Control whether the IRQ permits configuration by Non-secure/Unprivileged contexts, and whether it can observe Secure/Privileged channel interrupt flags.

Table 1185.
SECCFG_IRQ0,
SECCFG_IRQ1,
SECCFG_IRQ2,
SECCFG_IRQ3
Registers

BitsDescriptionTypeReset
31:2Reserved.--
1

S : Secure IRQ. If 1, this IRQ's control registers can only be accessed from a Secure context.

If 0, this IRQ's control registers can be accessed from a Non-secure context, but Secure channels (as per SECCFG_CHx) are masked from the IRQ status, and this IRQ's registers can not be used to acknowledge the channel interrupts of Secure channels.

RW0x1
Bits 31:0 Bits 31:0 Bits 31:28column_2Description Description Input value for GPIO0…31. Description QSPI_SD : Input value on QSPI SD0 (MOSI), SD1 (MISO), SD2 and SD3 pinsType RO Type RO Type ROReset - Reset 0x00000000 Reset 0x0
Register 31:10Reserved.--
9TIMER3_S: If 1, the TIMER3 register is only accessible from a Secure context, and timer DREQ 3 is only visible to Secure channels.RW0x1
8TIMER3_P: If 1, the TIMER3 register is only accessible from a Privileged (or Secure) channels.RW0x1
7TIMER2_S: If 1, the TIMER2 register is only accessible from a Secure context, and timer DREQ 2 is only visible to Secure channels.RW0x1
6TIMER2_P: If 1, the TIMER2 register is only accessible from a Privileged (or Secure) channels.RW0x1
5TIMER1_S: If 1, the TIMER1 register is only accessible from a Secure context, and timer DREQ 1 is only visible to Secure channels.RW0x1
4TIMER1_P: If 1, the TIMER1 register is only accessible from a Privileged (or Secure) channels.RW0x1
3TIMER0_S: If 1, the TIMER0 register is only accessible from a Secure context, and timer DREQ 0 is only visible to Secure channels.RW0x1
2TIMER0_P: If 1, the TIMER0 register is only accessible from a Privileged (or Secure) channels.RW0x1
1SNIFF_S: If 1, the sniffer can see data transfers from Secure channels, and can itself only be accessed from a Secure context.RW0x1
0SNIFF_Pbut can not see data transfers of Secure channels. : If 1, the sniffer can see data transfers from Privileged channels, and when SNIFF_S is 0.RW0x1

DMA: SECCFG_MISC Register

Offset: 0x4d0

Description

Miscellaneous security configuration

Table 1186.
SECCFG_MISC
Register

DMA: MPU_CTRL Register

Offset: 0x500

Description

Control register for DMA MPU. Accessible only from a Privileged context.

Table 1187.
MPU_CTRL Register

BitsDescriptionTypeReset
31:4Reserved.--
3NS_HIDE_ADDR: By default, when a region's S bit is clear, Non-secure-Privileged reads can see the region's base address and limit address. Set this bit to make the addresses appear as 0 to Non-secure reads, even when the region is Non-secure, to avoid leaking information about the processor SAU map.RW0x0
2S: Determine whether an address not covered by an active MPU region is Secure (1) or Non-secure (0)RW0x0
1P: Determine whether an address not covered by an active MPU region is Privileged (1) or Unprivileged (0)RW0x0
0Reserved.--

DMA: MPU_BAR0, MPU_BAR1, ..., MPU_BAR6, MPU_BAR7 Registers

Offsets: 0x504, 0x50c, ..., 0x534, 0x53c

Description

Base address register for MPU region N . Writable only from a Secure, Privileged context.

Table 1188.
MPU_BAR0,
MPU_BAR1, ...,
MPU_BAR6,
MPU_BAR7 Registers

BitsDescriptionTypeReset
31:5ADDR: This MPU region matches addresses where addr[31:5] (the 27 most significant bits) are greater than or equal to BAR_ADDR, and less than or equal to LAR_ADDR.

Readable from any Privileged context, if and only if this region's S bit is clear, and MPU_CTRL_NS_HIDE_ADDR is clear. Otherwise readable only from a Secure, Privileged context.
RW0x0000000
4:0Reserved.--

DMA: MPU_LAR0, MPU_LAR1, ..., MPU_LAR6, MPU_LAR7 Registers

Offsets: 0x508, 0x510, ..., 0x538, 0x540

Description

Limit address register for MPU region N . Writable only from a Secure, Privileged context, with the exception of the P bit.

Table 1189.
MPU_LAR0,
MPU_LAR1, ...,
MPU_LAR6,
MPU_LAR7 Registers

BitsDescriptionTypeReset
31:5ADDR: Limit address bits 31:5. Readable from any Privileged context, if and only if this region's S bit is clear, and MPU_CTRL_NS_HIDE_ADDR is clear. Otherwise readable only from a Secure, Privileged context.RW0x0000000
4:3Reserved.--
BitsDescriptionTypeReset
2S : Determines the Secure/Non-secure (=1/0) status of addresses matching this region, if this region is enabled.RW0x0
1P : Determines the Privileged/Unprivileged (=1/0) status of addresses matching this region, if this region is enabled. Writable from any Privileged context, if and only if the S bit is clear. Otherwise, writable only from a Secure, Privileged context.RW0x0
0EN : Region enable. If 1, any address within range specified by the base address (BAR_ADDR) and limit address (LAR_ADDR) has the attributes specified by S and P.RW0x0

DMA: CH0_DBG_CTDREQ, CH1_DBG_CTDREQ, ..., CH14_DBG_CTDREQ, CH15_DBG_CTDREQ Registers

Offsets: 0x800, 0x840, ..., 0xb80, 0xbc0

Table 1190.
CH0_DBG_CTDREQ,
CH1_DBG_CTDREQ, ...,
CH14_DBG_CTDREQ,
CH15_DBG_CTDREQ
Registers

BitsDescriptionTypeReset
31:6Reserved.--
5:0Read: get channel DREQ counter (i.e. how many accesses the DMA expects it can perform on the peripheral without overflow/underflow. Write any value: clears the counter, and cause channel to re-initiate DREQ handshake.WC0x00

DMA: CH0_DBG_TCR, CH1_DBG_TCR, ..., CH14_DBG_TCR, CH15_DBG_TCR Registers

Offsets: 0x804, 0x844, ..., 0xb84, 0xbc4

Table 1191.
CH0_DBG_TCR,
CH1_DBG_TCR, ...,
CH14_DBG_TCR,
CH15_DBG_TCR
Registers

BitsDescriptionTypeReset
31:0Read to get channel TRANS_COUNT reload value, i.e. the length of the next transferRO0x00000000