Dietmar Eggemann 9a6eb310ea ARM: hw_breakpoint: Debug powerdown support for self-hosted debug
This patch introduces debug powerdown support for self-hosted debug for v7
and v7.1 debug architecture for a SinglePower system, i.e. a system without a
separate core and debug power domain. On a SinglePower system the OS Lock is
lost over a powerdown.

If CONFIG_CPU_PM is set the new function pm_init() registers hw_breakpoint
with CPU PM for a system supporting OS Save and Restore.

Receiving a CPU PM EXIT notifier indicates that a single CPU has exited a low
power state. A call to reset_ctrl_regs() is hooked into the CPU PM EXIT
notifier chain. This function makes sure that the sticky power-down is clear
(only v7 debug), the OS Double Lock is clear (only v7.1 debug) and it clears
the OS Lock for v7 debug (for a system supporting OS Save and Restore) and
v7.1 debug. Furthermore, it clears any vector-catch events and all
breakpoint/watchpoint control/value registers for v7 and v7.1 debug.

Signed-off-by: Dietmar Eggemann <dietmar.eggemann@arm.com>
[will: removed redundant has_ossr check]
Signed-off-by: Will Deacon <will.deacon@arm.com>
2013-01-10 21:13:07 +00:00
..
2012-11-05 09:35:59 -08:00
2012-03-28 18:30:01 +01:00
2013-01-03 15:57:04 -08:00
2012-07-01 21:59:19 +08:00
2012-10-11 10:55:04 +01:00
2012-03-24 09:38:56 +00:00
2012-10-09 20:24:24 +02:00
2010-10-29 13:14:40 -05:00
2012-10-11 10:55:04 +01:00
2012-11-09 11:37:26 +00:00
2012-10-01 09:58:18 -04:00
2012-03-28 18:30:01 +01:00
2012-12-12 12:05:15 -08:00
2012-03-28 18:30:01 +01:00