aboutsummaryrefslogtreecommitdiff
path: root/gdb/remote.c
diff options
context:
space:
mode:
authorJ.T. Conklin <jtc@acorntoolworks.com>2000-08-10 18:54:27 +0000
committerJ.T. Conklin <jtc@acorntoolworks.com>2000-08-10 18:54:27 +0000
commitf1d7622b957e12c8130c24fe4c46882f70b59b1c (patch)
tree00b4defbb759d34bc6ef4db5dc670b7fc5702473 /gdb/remote.c
parente84d946b3ae38920c124cba665158104049c8665 (diff)
downloadgdb-f1d7622b957e12c8130c24fe4c46882f70b59b1c.zip
gdb-f1d7622b957e12c8130c24fe4c46882f70b59b1c.tar.gz
gdb-f1d7622b957e12c8130c24fe4c46882f70b59b1c.tar.bz2
* monitor.c (monitor_open): If a dcache has already been created,
invalidate it rather than creating another. * ocd.c (ocd_open): Likewise. * remote-nindy.c (nindy_open): Likewise. * remote-sds.c (sds_open): Likewise. * remote-utils.c (gr_open): Likewise. * remote.c (remote_open_1, remote_cisco_open): Likewise. * dcache.c (dcache_alloc): Changed to take address of line as an argument, and to invalidate cache line before returning. (dcache_peek_byte): Updated. (dcache_poke_byte): Updated. -------------------------------------------------------------------
Diffstat (limited to 'gdb/remote.c')
-rw-r--r--gdb/remote.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/gdb/remote.c b/gdb/remote.c
index 9fe2a29..557ab46 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -2057,7 +2057,10 @@ serial device is attached to the remote system\n\
unpush_target (target);
- remote_dcache = dcache_init (remote_read_bytes, remote_write_bytes);
+ if (!remote_dcache)
+ remote_dcache = dcache_init (remote_read_bytes, remote_write_bytes);
+ else
+ dcache_flush (remote_dcache);
remote_desc = SERIAL_OPEN (name);
if (!remote_desc)
@@ -5034,7 +5037,10 @@ device is attached to the remote system (e.g. host:port).");
unpush_target (&remote_cisco_ops);
- remote_dcache = dcache_init (remote_read_bytes, remote_write_bytes);
+ if (!remote_dcache)
+ remote_dcache = dcache_init (remote_read_bytes, remote_write_bytes);
+ else
+ dcache_flush (remote_dcache);
remote_desc = SERIAL_OPEN (name);
if (!remote_desc)