---

**[tickets:#415] Watchpoints not fully functional on Cortex-A9**

**Status:** new
**Milestone:** 0.10.0
**Created:** Mon Sep 11, 2023 04:34 PM UTC by Ahmad Fatoum
**Last Updated:** Mon Sep 11, 2023 04:34 PM UTC
**Owner:** nobody


The support added in commit 1fb736f6c5a6 ("target/cortex_a: add support for 
watchpoints") appears to be for CPUs  with ARM debug architecture >= v7.1, like 
Cortex-A7. On the older Cortex-A9, it doesn't work fully: The first access 
indeed triggers the watchpoint, but if I remove the watchpoint, step a few 
instructions after the instruction which triggered the watchpoint, readd the 
watchpoint and resume,  the  watchpoint is immediately triggered again at the 
current instruction. This happens whether using the shell over telnet or gdb.

I suspect this is because Cortex-A9 is ARM_DEBUG_ARCH_V7_ECP14. The Linux code 
differs for it compared to Cortex-A7's ARM_DEBUG_ARCH_V7_1.

I was testing on an i.MX6Q running bare-metal firmware in THUMB2 mode.

It would be nice if OpenOCD could just refuse adding watchpoints on older CPUs.


---

Sent from sourceforge.net because openocd-devel@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/openocd/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/openocd/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.


Reply via email to