summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/target/arm_dpm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/target/arm_dpm.c b/src/target/arm_dpm.c
index f15bff7..3e8180c 100644
--- a/src/target/arm_dpm.c
+++ b/src/target/arm_dpm.c
@@ -973,7 +973,7 @@ int arm_dpm_setup(struct arm_dpm *dpm)
arm->read_core_reg = arm_dpm_read_core_reg;
arm->write_core_reg = arm_dpm_write_core_reg;
- if (arm->core_cache != NULL) {
+ if (arm->core_cache == NULL) {
cache = arm_build_reg_cache(target, arm);
if (!cache)
return ERROR_FAIL;