dwt_prof: Enable write access for DWT counters
prof_hal_init() performs the initialization of the DWT unit.
However, the effective writes to its registers may be protected
by an architecture-defined software locks (LSR, LAR).
The current implementation does not take into account the above
protection mechanism and thus in some platforms the DWT may not
be configured and the counters are not enabled. The result is that
the profiling metrics are all 0.
Add a step to check for software locks implemented and, if positive,
enable the writes into DWT.
Signed-off-by: Nicola Mazzucato <nicola.mazzucato@arm.com>
Change-Id: Ia34c97a872359b8a099c3d8c9b89abd86a58cbc4
1 file changed