aboutsummaryrefslogtreecommitdiff
path: root/gdb/remote.c
diff options
context:
space:
mode:
authorAlan Hayward <alan.hayward@arm.com>2017-02-27 09:58:35 +0000
committerAlan Hayward <alan.hayward@arm.com>2017-02-27 09:58:35 +0000
commit8e3681243c642d667164bd23ae9a376620da0780 (patch)
treea2311ff7b18870d84e8685aabc08d85692067c09 /gdb/remote.c
parenta0aa382843fc5ccbeebf99d8d3c3075ca13e8125 (diff)
downloadgdb-8e3681243c642d667164bd23ae9a376620da0780.zip
gdb-8e3681243c642d667164bd23ae9a376620da0780.tar.gz
gdb-8e3681243c642d667164bd23ae9a376620da0780.tar.bz2
Remove MAX_REGISTER_SIZE from remote.c
gdb/ * regcache.c (regcache_raw_update): New function. (regcache_raw_read): Move code to regcache_raw_update. * regcache.h (regcache_raw_update): New declaration. * remote.c (remote_prepare_to_store): Call regcache_raw_update.
Diffstat (limited to 'gdb/remote.c')
-rw-r--r--gdb/remote.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gdb/remote.c b/gdb/remote.c
index 3befbd3..87fb6e0 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -7759,7 +7759,6 @@ remote_prepare_to_store (struct target_ops *self, struct regcache *regcache)
{
struct remote_arch_state *rsa = get_remote_arch_state ();
int i;
- gdb_byte buf[MAX_REGISTER_SIZE];
/* Make sure the entire registers array is valid. */
switch (packet_support (PACKET_P))
@@ -7769,7 +7768,7 @@ remote_prepare_to_store (struct target_ops *self, struct regcache *regcache)
/* Make sure all the necessary registers are cached. */
for (i = 0; i < gdbarch_num_regs (get_regcache_arch (regcache)); i++)
if (rsa->regs[i].in_g_packet)
- regcache_raw_read (regcache, rsa->regs[i].regnum, buf);
+ regcache_raw_update (regcache, rsa->regs[i].regnum);
break;
case PACKET_ENABLE:
break;