* 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.
This commit is contained in:
parent
6b911e8b2a
commit
0146f85bf7
8 changed files with 27 additions and 13 deletions
|
@ -1,3 +1,17 @@
|
|||
2010-08-27 Pedro Alves <pedro@codesourcery.com>
|
||||
|
||||
* 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 <pedro@codesourcery.com>
|
||||
|
||||
* linux-low.c (linux_prepare_to_access_memory): New.
|
||||
|
|
|
@ -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,
|
||||
|
|
|
@ -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':
|
||||
|
|
|
@ -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 */
|
||||
|
|
|
@ -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;
|
||||
}
|
||||
|
|
|
@ -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,
|
||||
|
|
|
@ -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);
|
||||
|
|
|
@ -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 */
|
||||
|
|
Loading…
Reference in a new issue