diff options
-rw-r--r-- | gdb/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/target.c | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 9de86a3..78a871f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,10 @@ 2013-11-20 Yao Qi <yao@codesourcery.com> + * target.c (memory_xfer_partial_1): Update 'target_dcache' if + it is initialized. + +2013-11-20 Yao Qi <yao@codesourcery.com> + * dcache.c (last_cache): Remove. (dcache_free, dcache_init): Update. (dcache_update): diff --git a/gdb/target.c b/gdb/target.c index cb75853..2c0096e 100644 --- a/gdb/target.c +++ b/gdb/target.c @@ -1667,11 +1667,12 @@ memory_xfer_partial_1 (struct target_ops *ops, enum target_object object, if (res > 0 && inf != NULL && writebuf != NULL + && target_dcache_init_p () && !region->attrib.cache && stack_cache_enabled_p && object != TARGET_OBJECT_STACK_MEMORY) { - DCACHE *dcache = target_dcache_get_or_init (); + DCACHE *dcache = target_dcache_get (); dcache_update (dcache, memaddr, (void *) writebuf, res); } |