]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ARM: hw_breakpoint: fix ordering of debug register reset sequence
authorWill Deacon <will.deacon@arm.com>
Fri, 21 Sep 2012 14:38:26 +0000 (15:38 +0100)
committerWill Deacon <will.deacon@arm.com>
Mon, 15 Oct 2012 11:01:08 +0000 (12:01 +0100)
commite9e1dee292d4eb01f59858337864e1745551d6b4
tree4276c10ad3d58fbc7f140fab5eb07db9b92b92d0
parentf5206faf707ec754f4eccf789e9c9c9156308a15
ARM: hw_breakpoint: fix ordering of debug register reset sequence

The debug register reset sequence for v7 and v7.1 is congruent with
tap-dancing through a minefield.

Rather than wait until we've blown ourselves to pieces, this patch
instead checks the debug_err_mask after each potentially faulting
operation. We also move the enabling of monitor_mode to the end of the
sequence in order to prevent spurious debug events generated by UNKNOWN
register values.

Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm/kernel/hw_breakpoint.c