aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/ChangeLog12
-rw-r--r--gdb/dcache.c16
-rw-r--r--gdb/infptrace.c2
-rw-r--r--gdb/inftarg.c4
-rw-r--r--gdb/rs6000-nat.c2
-rw-r--r--gdb/target.h2
-rw-r--r--gdb/win32-nat.c2
-rw-r--r--gdb/wince.c2
-rw-r--r--gdb/windows-nat.c2
9 files changed, 26 insertions, 18 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 7187608..f68f9a8 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,17 @@
2005-05-23 Andrew Cagney <cagney@gnu.org>
+ * target.h (child_xfer_memory): Use gdb_byte for byte buffer
+ parameters.
+ * inftarg.c (child_xfer_partial): Update.
+ * wince.c (child_xfer_memory): Update.
+ * win32-nat.c (child_xfer_memory): Update.
+ * rs6000-nat.c (child_xfer_memory): Update.
+ * infptrace.c (child_xfer_memory): Update.
+ * dcache.c (struct dcache_block): Use gdb_byte for the byte
+ buffers.
+ (dcache_read_line, dcache_xfer_memory, dcache_poke_byte)
+ (dcache_peek_byte, dcache_write_line): Ditto.
+
* auxv.h (target_auxv_read, procfs_xfer_auxv)
(target_auxv_parse): Use gdb_byte for byte buffer parameters.
* auxv.c (target_auxv_read, procfs_xfer_auxv, target_auxv_parse)
diff --git a/gdb/dcache.c b/gdb/dcache.c
index 72e9866..acfb6cd 100644
--- a/gdb/dcache.c
+++ b/gdb/dcache.c
@@ -124,7 +124,7 @@ struct dcache_block
{
struct dcache_block *p; /* next in list */
CORE_ADDR addr; /* Address for which data is recorded. */
- char data[LINE_SIZE]; /* bytes at given address */
+ gdb_byte data[LINE_SIZE]; /* bytes at given address */
unsigned char state[LINE_SIZE]; /* what state the data is in */
/* whether anything in state is dirty - used to speed up the
@@ -162,10 +162,6 @@ struct dcache_struct
struct dcache_block *the_cache;
};
-static int dcache_poke_byte (DCACHE *dcache, CORE_ADDR addr, char *ptr);
-
-static int dcache_peek_byte (DCACHE *dcache, CORE_ADDR addr, char *ptr);
-
static struct dcache_block *dcache_hit (DCACHE *dcache, CORE_ADDR addr);
static int dcache_write_line (DCACHE *dcache, struct dcache_block *db);
@@ -250,7 +246,7 @@ static int
dcache_write_line (DCACHE *dcache, struct dcache_block *db)
{
CORE_ADDR memaddr;
- char *myaddr;
+ gdb_byte *myaddr;
int len;
int res;
int reg_len;
@@ -331,7 +327,7 @@ static int
dcache_read_line (DCACHE *dcache, struct dcache_block *db)
{
CORE_ADDR memaddr;
- char *myaddr;
+ gdb_byte *myaddr;
int len;
int res;
int reg_len;
@@ -450,7 +446,7 @@ dcache_writeback (DCACHE *dcache)
Returns 0 on error. */
static int
-dcache_peek_byte (DCACHE *dcache, CORE_ADDR addr, char *ptr)
+dcache_peek_byte (DCACHE *dcache, CORE_ADDR addr, gdb_byte *ptr)
{
struct dcache_block *db = dcache_hit (dcache, addr);
@@ -477,7 +473,7 @@ dcache_peek_byte (DCACHE *dcache, CORE_ADDR addr, char *ptr)
*/
static int
-dcache_poke_byte (DCACHE *dcache, CORE_ADDR addr, char *ptr)
+dcache_poke_byte (DCACHE *dcache, CORE_ADDR addr, gdb_byte *ptr)
{
struct dcache_block *db = dcache_hit (dcache, addr);
@@ -536,7 +532,7 @@ dcache_xfer_memory (DCACHE *dcache, CORE_ADDR memaddr, gdb_byte *myaddr,
int len, int should_write)
{
int i;
- int (*xfunc) (DCACHE *dcache, CORE_ADDR addr, char *ptr);
+ int (*xfunc) (DCACHE *dcache, CORE_ADDR addr, gdb_byte *ptr);
xfunc = should_write ? dcache_poke_byte : dcache_peek_byte;
for (i = 0; i < len; i++)
diff --git a/gdb/infptrace.c b/gdb/infptrace.c
index a612d13..3035967 100644
--- a/gdb/infptrace.c
+++ b/gdb/infptrace.c
@@ -332,7 +332,7 @@ store_inferior_registers (int regnum)
us in the target stack anyway. */
int
-child_xfer_memory (CORE_ADDR memaddr, char *myaddr, int len, int write,
+child_xfer_memory (CORE_ADDR memaddr, gdb_byte *myaddr, int len, int write,
struct mem_attrib *attrib, struct target_ops *target)
{
int i;
diff --git a/gdb/inftarg.c b/gdb/inftarg.c
index cd8674d..279f3a7 100644
--- a/gdb/inftarg.c
+++ b/gdb/inftarg.c
@@ -531,8 +531,8 @@ child_core_file_to_sym_file (char *core)
static LONGEST
child_xfer_partial (struct target_ops *ops, enum target_object object,
- const char *annex, void *readbuf,
- const void *writebuf, ULONGEST offset, LONGEST len)
+ const char *annex, gdb_byte *readbuf,
+ const gdb_byte *writebuf, ULONGEST offset, LONGEST len)
{
switch (object)
{
diff --git a/gdb/rs6000-nat.c b/gdb/rs6000-nat.c
index c930097..3aaa77c 100644
--- a/gdb/rs6000-nat.c
+++ b/gdb/rs6000-nat.c
@@ -449,7 +449,7 @@ read_word (CORE_ADDR from, int *to, int arch64)
us in the target stack anyway. */
int
-child_xfer_memory (CORE_ADDR memaddr, char *myaddr, int len,
+child_xfer_memory (CORE_ADDR memaddr, gdb_byte *myaddr, int len,
int write, struct mem_attrib *attrib,
struct target_ops *target)
{
diff --git a/gdb/target.h b/gdb/target.h
index 80fd783..bc10b25 100644
--- a/gdb/target.h
+++ b/gdb/target.h
@@ -545,7 +545,7 @@ extern int target_write_memory (CORE_ADDR memaddr, const gdb_byte *myaddr,
extern int xfer_memory (CORE_ADDR, gdb_byte *, int, int,
struct mem_attrib *, struct target_ops *);
-extern int child_xfer_memory (CORE_ADDR, char *, int, int,
+extern int child_xfer_memory (CORE_ADDR, gdb_byte *, int, int,
struct mem_attrib *, struct target_ops *);
/* Make a single attempt at transfering LEN bytes. On a successful
diff --git a/gdb/win32-nat.c b/gdb/win32-nat.c
index bfdf9dc..bd775ad 100644
--- a/gdb/win32-nat.c
+++ b/gdb/win32-nat.c
@@ -1931,7 +1931,7 @@ child_stop (void)
}
int
-child_xfer_memory (CORE_ADDR memaddr, char *our, int len,
+child_xfer_memory (CORE_ADDR memaddr, gdb_byte *our, int len,
int write, struct mem_attrib *mem,
struct target_ops *target)
{
diff --git a/gdb/wince.c b/gdb/wince.c
index 14f28e4..9be5e6f 100644
--- a/gdb/wince.c
+++ b/gdb/wince.c
@@ -1839,7 +1839,7 @@ child_mourn_inferior (void)
/* Move memory from child to/from gdb. */
int
-child_xfer_memory (CORE_ADDR memaddr, char *our,
+child_xfer_memory (CORE_ADDR memaddr, gdb_byte *our,
int len, int write,
struct mem_attrib *attrib,
struct target_ops *target)
diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c
index bfdf9dc..bd775ad 100644
--- a/gdb/windows-nat.c
+++ b/gdb/windows-nat.c
@@ -1931,7 +1931,7 @@ child_stop (void)
}
int
-child_xfer_memory (CORE_ADDR memaddr, char *our, int len,
+child_xfer_memory (CORE_ADDR memaddr, gdb_byte *our, int len,
int write, struct mem_attrib *mem,
struct target_ops *target)
{