ARM DPM: disable some nyet-ready breakpoint code
authorDavid Brownell <dbrownell@users.sourceforge.net>
Fri, 15 Jan 2010 20:53:26 +0000 (12:53 -0800)
committerDavid Brownell <dbrownell@users.sourceforge.net>
Fri, 15 Jan 2010 20:53:26 +0000 (12:53 -0800)
Until we manage breakpoints at runtime (patches not ready for 0.4)
the only way this code should touch them is to disable them at server
startup (a previous debug session may have left them active).

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
src/target/arm_dpm.c

index 0908ca92d0088c81ad8820cfa9455843d3dba99d..4bd22ffbf53cc7fa3807a8387d9728d60c015df2 100644 (file)
@@ -341,13 +341,21 @@ int arm_dpm_write_dirty_registers(struct arm_dpm *dpm, bool bpwp)
        if (retval != ERROR_OK)
                goto done;
 
-       /* enable/disable hardware breakpoints */
-       for (unsigned i = 0; i < dpm->nbp; i++) {
-               struct dpm_bp *dbp = dpm->dbp + i;
-               struct breakpoint *bp = dbp->bp;
+       /* If we're managing hardware breakpoints for this core, enable
+        * or disable them as requested.
+        *
+        * REVISIT We don't yet manage them for ANY cores.  Eventually
+        * we should be able to assume we handle them; but until then,
+        * cope with the hand-crafted breakpoint code.
+        */
+       if (0) {
+               for (unsigned i = 0; i < dpm->nbp; i++) {
+                       struct dpm_bp *dbp = dpm->dbp + i;
+                       struct breakpoint *bp = dbp->bp;
 
-               retval = dpm_maybe_update_bpwp(dpm, bpwp, &dbp->bpwp,
-                               bp ? &bp->set : NULL);
+                       retval = dpm_maybe_update_bpwp(dpm, bpwp, &dbp->bpwp,
+                                       bp ? &bp->set : NULL);
+               }
        }
 
        /* enable/disable watchpoints */

Linking to existing account procedure

If you already have an account and want to add another login method you MUST first sign in with your existing account and then change URL to read https://review.openocd.org/login/?link to get to this page again but this time it'll work for linking. Thank you.

SSH host keys fingerprints

1024 SHA256:YKx8b7u5ZWdcbp7/4AeXNaqElP49m6QrwfXaqQGJAOk gerrit-code-review@openocd.zylin.com (DSA)
384 SHA256:jHIbSQa4REvwCFG4cq5LBlBLxmxSqelQPem/EXIrxjk gerrit-code-review@openocd.org (ECDSA)
521 SHA256:UAOPYkU9Fjtcao0Ul/Rrlnj/OsQvt+pgdYSZ4jOYdgs gerrit-code-review@openocd.org (ECDSA)
256 SHA256:A13M5QlnozFOvTllybRZH6vm7iSt0XLxbA48yfc2yfY gerrit-code-review@openocd.org (ECDSA)
256 SHA256:spYMBqEYoAOtK7yZBrcwE8ZpYt6b68Cfh9yEVetvbXg gerrit-code-review@openocd.org (ED25519)
+--[ED25519 256]--+
|=..              |
|+o..   .         |
|*.o   . .        |
|+B . . .         |
|Bo. = o S        |
|Oo.+ + =         |
|oB=.* = . o      |
| =+=.+   + E     |
|. .=o   . o      |
+----[SHA256]-----+
2048 SHA256:0Onrb7/PHjpo6iVZ7xQX2riKN83FJ3KGU0TvI0TaFG4 gerrit-code-review@openocd.zylin.com (RSA)