From: Pedro Alves Date: Fri, 27 Aug 2010 00:16:48 +0000 (+0000) Subject: * linux-low.c (linux_unprepare_to_access_memory): Rename to ... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0146f85bf73a3395b8c0e17ed2beb0d737e5b8e1;p=binutils-gdb.git * linux-low.c (linux_unprepare_to_access_memory): Rename to ... (linux_done_accessing_memory): ... this. (linux_target_ops): Adjust. * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust. * nto-low.c (nto_target_ops): Adjust comment. * server.c (gdb_read_memory, gdb_write_memory): Adjust. * spu-low.c (spu_target_ops): Adjust comment. * target.h (target_ops): Rename unprepare_to_access_memory field to done_accessing_memory. (unprepare_to_access_memory): Rename to ... (done_accessing_memory): ... this. --- diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index b31695438ed..fbc3e4efb19 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,17 @@ +2010-08-27 Pedro Alves + + * linux-low.c (linux_unprepare_to_access_memory): Rename to ... + (linux_done_accessing_memory): ... this. + (linux_target_ops): Adjust. + * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust. + * nto-low.c (nto_target_ops): Adjust comment. + * server.c (gdb_read_memory, gdb_write_memory): Adjust. + * spu-low.c (spu_target_ops): Adjust comment. + * target.h (target_ops): Rename unprepare_to_access_memory field + to done_accessing_memory. + (unprepare_to_access_memory): Rename to ... + (done_accessing_memory): ... this. + 2010-08-26 Pedro Alves * linux-low.c (linux_prepare_to_access_memory): New. diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c index 7fa9336e8cd..0f6c543fbba 100644 --- a/gdb/gdbserver/linux-low.c +++ b/gdb/gdbserver/linux-low.c @@ -5016,7 +5016,7 @@ linux_prepare_to_access_memory (void) } static void -linux_unprepare_to_access_memory (void) +linux_done_accessing_memory (void) { /* Neither ptrace nor /proc/PID/mem allow accessing memory through a running LWP. */ @@ -5063,7 +5063,7 @@ static struct target_ops linux_target_ops = { linux_fetch_registers, linux_store_registers, linux_prepare_to_access_memory, - linux_unprepare_to_access_memory, + linux_done_accessing_memory, linux_read_memory, linux_write_memory, linux_look_up_symbols, diff --git a/gdb/gdbserver/linux-x86-low.c b/gdb/gdbserver/linux-x86-low.c index b169b755433..8ddb5530e9d 100644 --- a/gdb/gdbserver/linux-x86-low.c +++ b/gdb/gdbserver/linux-x86-low.c @@ -562,7 +562,7 @@ x86_insert_point (char type, CORE_ADDR addr, int len) if (ret) return -1; ret = set_gdb_breakpoint_at (addr); - unprepare_to_access_memory (); + done_accessing_memory (); return ret; } case '2': @@ -590,7 +590,7 @@ x86_remove_point (char type, CORE_ADDR addr, int len) if (ret) return -1; ret = delete_gdb_breakpoint_at (addr); - unprepare_to_access_memory (); + done_accessing_memory (); return ret; } case '2': diff --git a/gdb/gdbserver/nto-low.c b/gdb/gdbserver/nto-low.c index 4502ee7f921..0c54b90b878 100644 --- a/gdb/gdbserver/nto-low.c +++ b/gdb/gdbserver/nto-low.c @@ -914,7 +914,7 @@ static struct target_ops nto_target_ops = { nto_fetch_registers, nto_store_registers, NULL, /* prepare_to_access_memory */ - NULL, /* unprepare_to_access_memory */ + NULL, /* done_accessing_memory */ nto_read_memory, nto_write_memory, NULL, /* nto_look_up_symbols */ diff --git a/gdb/gdbserver/server.c b/gdb/gdbserver/server.c index 5daf4b53f2d..c406abe3293 100644 --- a/gdb/gdbserver/server.c +++ b/gdb/gdbserver/server.c @@ -564,7 +564,7 @@ gdb_read_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len) if (ret == 0) { ret = read_inferior_memory (memaddr, myaddr, len); - unprepare_to_access_memory (); + done_accessing_memory (); } return ret; @@ -586,7 +586,7 @@ gdb_write_memory (CORE_ADDR memaddr, const unsigned char *myaddr, int len) if (ret == 0) { ret = write_inferior_memory (memaddr, myaddr, len); - unprepare_to_access_memory (); + done_accessing_memory (); } return ret; } diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c index dc301b2ed16..1568c100dc1 100644 --- a/gdb/gdbserver/spu-low.c +++ b/gdb/gdbserver/spu-low.c @@ -654,7 +654,7 @@ static struct target_ops spu_target_ops = { spu_fetch_registers, spu_store_registers, NULL, /* prepare_to_access_memory */ - NULL, /* unprepare_to_access_memory */ + NULL, /* done_accessing_memory */ spu_read_memory, spu_write_memory, spu_look_up_symbols, diff --git a/gdb/gdbserver/target.h b/gdb/gdbserver/target.h index 8126f857f71..a621b324713 100644 --- a/gdb/gdbserver/target.h +++ b/gdb/gdbserver/target.h @@ -196,7 +196,7 @@ struct target_ops /* Undo the effects of prepare_to_access_memory. */ - void (*unprepare_to_access_memory) (void); + void (*done_accessing_memory) (void); /* Read memory from the inferior process. This should generally be called through read_inferior_memory, which handles breakpoint shadowing. @@ -491,11 +491,11 @@ ptid_t mywait (ptid_t ptid, struct target_waitstatus *ourstatus, int options, ? (*the_target->prepare_to_access_memory) () \ : 0) -#define unprepare_to_access_memory() \ +#define done_accessing_memory() \ do \ { \ - if (the_target->unprepare_to_access_memory) \ - (*the_target->unprepare_to_access_memory) (); \ + if (the_target->done_accessing_memory) \ + (*the_target->done_accessing_memory) (); \ } while (0) int read_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len); diff --git a/gdb/gdbserver/win32-low.c b/gdb/gdbserver/win32-low.c index f64673849cb..dd26d730b23 100644 --- a/gdb/gdbserver/win32-low.c +++ b/gdb/gdbserver/win32-low.c @@ -1782,7 +1782,7 @@ static struct target_ops win32_target_ops = { win32_fetch_inferior_registers, win32_store_inferior_registers, NULL, /* prepare_to_access_memory */ - NULL, /* unprepare_to_access_memory */ + NULL, /* done_accessing_memory */ win32_read_inferior_memory, win32_write_inferior_memory, NULL, /* lookup_symbols */