This is an automated email from Gerrit.

Matthias Welwarsky (matth...@welwarsky.de) just uploaded a new patch set to 
Gerrit, which you can find at http://openocd.zylin.com/3766

-- gerrit

commit c666c0c1f8a83a57adaffed85ae1e35692a8d7fb
Author: Matthias Welwarsky <matthias.welwar...@sysgo.com>
Date:   Thu Sep 15 17:17:05 2016 +0200

    aarch64: fix duplication of register cache
    
    Change-Id: Ib4422e39171f19eea3f0b5a86f9dccdbb7044265
    Signed-off-by: Matthias Welwarsky <matthias.welwar...@sysgo.com>

diff --git a/src/target/armv8_dpm.c b/src/target/armv8_dpm.c
index dc6682b..493ccca 100644
--- a/src/target/armv8_dpm.c
+++ b/src/target/armv8_dpm.c
@@ -916,9 +916,11 @@ int armv8_dpm_setup(struct arm_dpm *dpm)
        arm->read_core_reg = armv8_dpm_read_core_reg;
        arm->write_core_reg = armv8_dpm_write_core_reg;
 
-       cache = armv8_build_reg_cache(target);
-       if (!cache)
-               return ERROR_FAIL;
+       if (arm->core_cache == NULL) {
+               cache = armv8_build_reg_cache(target);
+               if (!cache)
+                       return ERROR_FAIL;
+       }
 
        /* coprocessor access setup */
        arm->mrc = dpmv8_mrc;

-- 

------------------------------------------------------------------------------
_______________________________________________
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to