The access ports can be protected to secure the internal assets and resources of the
device. While the control access port (CTRL-AP) is always accessible from an external debugger,
the system applies various protection mechanisms to control and restrict access to the
individual AHB access ports.
Protection is controlled by specific registers, which enable or disable debug access at
different levels. These registers are part of UICR and TAMPC. The access port is normally
protected. The hardware and software configurations of these registers control the access
protection policies as shown in the following table.
CPU control of debug access. The registers can be locked.
The access port protection is illustrated in the following figures.
Figure 2. AUX access port protection overviewFigure 3. Arm Cortex-M33 AHB-AP access port protection overview
Software control of RRAMC ERASEALL and CTRL-AP ERASEALL protection. The
register can be locked.
The ERASEALL protection is illustrated in the following figure: Figure 4. ERASEALL protection overview
The reset behavior of the TAMPC access port and ERASEALL protection is defined in Signal protector. On-chip software must write to the TAMPC registers before
a debug access port is opened.
The access port remains open after the completion of the CTRL-AP.ERASEALL operation. CTRL-AP temporarily removes the access port protection
until certain conditions are met, after which the protection will be reinstated. The AHB-AP
will be protected when one of the following conditions are met:
Power-on reset
Brownout reset
Watchdog timer reset
Pin reset
The following figure shows how a device with access port protection enabled can be erased,
programmed, and configured to allow debugging. The access port state is determined by
operations sent from the debugger and registers written by firmware. Reset in the following
figure refers to any of the conditions previously listed for AHB-AP protection. When writing
to the TAMPC, the software must first disable write protection, then write the new values. For
more details, see TAMPC — Tamper controller. Figure 5. Access port unlocking
The debugger can read the access port protection status in the core's AHB-AP, using the Arm AHB-AP Control/Status Word register
(CSW), defined in the Arm
CoreSight SoC-400 Technical
Reference Manual. The DbgStatus field indicates that the AHB-AP can perform AHB
transfers, while the SPIStatus field indicates if secure AHB transfers are permitted. For a
list of all debug access ports, see Debug access port.