GD32W51x User Manual
318
interfaces are implemented in each DMA respectively for memory and peripheral.
Memory to peripheral: read data from memory through AHB master interface for memory,
and write data to peripheral through AHB master interface for peripheral.
Peripheral to memory: read data from peripheral through AHB master interface for
peripheral, and write data to memory through AHB master interface for memory.
Memory to memory: read data from memory through AHB master interface for peripheral,
and write data to another memory through AHB master interface for memory.
12.4.1.
Secure & priviledge
Security
The DMA controller is compliant with the TrustZone-M hardware architecture, partitioning all
its resources so that they exist in one of the two worlds: the secure world and the nonsecure
world, at any given time.
A secure software is able to access any resource/register, whatever secure or non-secure.
A non-secure software is restricted to access any non-secure resource/register.
Any channel is in a secure or non-secure state, as securely configured by the
DMA_CHxSCTL.SECM secure register bit.
When a channel x is configured in secure mode, the following access controls rules are
applied:
A non-secure read access to a register field of this channel is forced to return 0, except
for both the secure state and the privileged state of this channel x (SECM and PRIV bits
of the DMA_CHxSCTL register) which are readable by a non-secure software.
A non-secure write access to a register field of this channel has no impact.
When a channel is configured in secure mode, a secure software can separately configure
as secure or non-secure the AHB DMA master transfer from the source (by the
DMA_CHxSCTL.SSEC register bit), and as secure or non-secure the AHB DMA master
transfer to the destination (by the DMA_CHxSCTL.DSEC register bit).
The DMA controller also generates a security illegal access pulse, on an illegal non-secure
software access to a secure DMA register or register field. This event is routed to the
TrustZone interrupt controller.
The illegal access pulse is generated in the configurations described below:
If the channel x is in secure state (SECM bit of the DMA_CHxSCTL register set), the
illegal access pulse is generated on one of the following accesses:
-
a non-secure write access to a dedicated register of this channel x
(DMA_CHxCTL, DMA_CHxCNT, DMA_CHxPADDR, DMA_CHxM0ADDR
DMA_CHxM1ADDR, DMA_CHxFCTL and DMA_CHxSCTL).
-
a non-secure read access to a dedicated register of this channel x, except the
DMA_CHxSCTL register (DMA_CHxCTL, DMA_CHxCNT, DMA_CHxPADDR,
DMA_CHxM0ADDR DMA_CHxM1ADDR and DMA_CHxFCTL).
If the channel x is in non-secure state (SECM bit of the DMA_CHxSCTL register