aboutsummaryrefslogtreecommitdiff
path: root/sim
diff options
context:
space:
mode:
Diffstat (limited to 'sim')
-rw-r--r--sim/bfin/interp.c4
-rw-r--r--sim/common/callback.c2
-rw-r--r--sim/common/cgen-trace.c2
-rw-r--r--sim/cris/sim-if.c2
-rw-r--r--sim/cris/traps.c4
-rw-r--r--sim/frv/traps.c4
-rw-r--r--sim/m32c/trace.c2
-rw-r--r--sim/m32r/traps.c4
-rw-r--r--sim/mips/interp.c4
-rw-r--r--sim/ppc/emul_chirp.c2
-rw-r--r--sim/ppc/hw_htab.c8
-rw-r--r--sim/ppc/hw_init.c4
-rw-r--r--sim/rl78/trace.c2
-rw-r--r--sim/rx/trace.c2
14 files changed, 23 insertions, 23 deletions
diff --git a/sim/bfin/interp.c b/sim/bfin/interp.c
index 74d0a15..58bec8b 100644
--- a/sim/bfin/interp.c
+++ b/sim/bfin/interp.c
@@ -132,8 +132,8 @@ bfin_syscall (SIM_CPU *cpu)
sc.arg5 = args[4] = GET_LONG (DREG (0) + 16);
sc.arg6 = args[5] = GET_LONG (DREG (0) + 20);
}
- sc.p1 = (PTR) sd;
- sc.p2 = (PTR) cpu;
+ sc.p1 = sd;
+ sc.p2 = cpu;
sc.read_mem = sim_syscall_read_mem;
sc.write_mem = sim_syscall_write_mem;
diff --git a/sim/common/callback.c b/sim/common/callback.c
index 070f451..63e0ab1 100644
--- a/sim/common/callback.c
+++ b/sim/common/callback.c
@@ -812,7 +812,7 @@ cb_read_target_syscall_maps (host_callback *cb, const char *file)
if (cb->signal_map)
free (cb->signal_map);
if (cb->stat_map)
- free ((PTR) cb->stat_map);
+ free ((void *) cb->stat_map);
cb->syscall_map = syscall_map;
cb->errno_map = errno_map;
diff --git a/sim/common/cgen-trace.c b/sim/common/cgen-trace.c
index 12f6126..3df30c5 100644
--- a/sim/common/cgen-trace.c
+++ b/sim/common/cgen-trace.c
@@ -433,7 +433,7 @@ sim_cgen_disassemble_insn (SIM_CPU *cpu, const CGEN_INSN *insn,
disasm_info.buffer = insn_buf.bytes;
disasm_info.buffer_length = length;
- ex_info.dis_info = (PTR) &disasm_info;
+ ex_info.dis_info = &disasm_info;
ex_info.valid = (1 << length) - 1;
ex_info.insn_bytes = insn_buf.bytes;
diff --git a/sim/cris/sim-if.c b/sim/cris/sim-if.c
index 3589f5b..5b1240f 100644
--- a/sim/cris/sim-if.c
+++ b/sim/cris/sim-if.c
@@ -1022,7 +1022,7 @@ cris_disassemble_insn (SIM_CPU *cpu,
disasm_info.endian = BFD_ENDIAN_LITTLE;
disasm_info.read_memory_func = sim_disasm_read_memory;
disasm_info.memory_error_func = sim_disasm_perror_memory;
- disasm_info.application_data = (PTR) cpu;
+ disasm_info.application_data = cpu;
pinsn = cris_get_disassembler (STATE_PROG_BFD (sd));
(*pinsn) (pc, &disasm_info);
}
diff --git a/sim/cris/traps.c b/sim/cris/traps.c
index e92fa1a..8750c4d 100644
--- a/sim/cris/traps.c
+++ b/sim/cris/traps.c
@@ -1442,8 +1442,8 @@ cris_break_13_handler (SIM_CPU *current_cpu, USI callnum, USI arg1,
sim_engine_halt (sd, current_cpu, NULL, pc, sim_exited, arg1);
}
- s.p1 = (PTR) sd;
- s.p2 = (PTR) current_cpu;
+ s.p1 = sd;
+ s.p2 = current_cpu;
s.read_mem = sim_syscall_read_mem;
s.write_mem = sim_syscall_write_mem;
diff --git a/sim/frv/traps.c b/sim/frv/traps.c
index 11f4a60..0c9eacd 100644
--- a/sim/frv/traps.c
+++ b/sim/frv/traps.c
@@ -138,8 +138,8 @@ frv_itrap (SIM_CPU *current_cpu, PCADDR pc, USI base, SI offset)
sim_engine_halt (sd, current_cpu, NULL, pc, sim_exited, s.arg1);
}
- s.p1 = (PTR) sd;
- s.p2 = (PTR) current_cpu;
+ s.p1 = sd;
+ s.p2 = current_cpu;
s.read_mem = syscall_read_mem;
s.write_mem = syscall_write_mem;
cb_syscall (cb, &s);
diff --git a/sim/m32c/trace.c b/sim/m32c/trace.c
index f5171c2..1888e69 100644
--- a/sim/m32c/trace.c
+++ b/sim/m32c/trace.c
@@ -75,7 +75,7 @@ remove_useless_symbols (asymbol ** symbols, long count)
}
static int
-compare_symbols (const PTR ap, const PTR bp)
+compare_symbols (const void *ap, const void *bp)
{
const asymbol *a = *(const asymbol **) ap;
const asymbol *b = *(const asymbol **) bp;
diff --git a/sim/m32r/traps.c b/sim/m32r/traps.c
index a696b58..267d548 100644
--- a/sim/m32r/traps.c
+++ b/sim/m32r/traps.c
@@ -237,8 +237,8 @@ m32r_trap (SIM_CPU *current_cpu, PCADDR pc, int num)
s.arg6 = arg6;
s.arg7 = arg7;
- s.p1 = (PTR) sd;
- s.p2 = (PTR) current_cpu;
+ s.p1 = sd;
+ s.p2 = current_cpu;
s.read_mem = sim_syscall_read_mem;
s.write_mem = sim_syscall_write_mem;
diff --git a/sim/mips/interp.c b/sim/mips/interp.c
index c5d0901..e46e817 100644
--- a/sim/mips/interp.c
+++ b/sim/mips/interp.c
@@ -1299,8 +1299,8 @@ sim_monitor (SIM_DESC sd,
MIPS simulator's memory model is still 32-bit. */
s.arg1 = A0 & 0xFFFFFFFF;
s.arg2 = A1 & 0xFFFFFFFF;
- s.p1 = (PTR) sd;
- s.p2 = (PTR) cpu;
+ s.p1 = sd;
+ s.p2 = cpu;
s.read_mem = sim_syscall_read_mem;
s.write_mem = sim_syscall_write_mem;
diff --git a/sim/ppc/emul_chirp.c b/sim/ppc/emul_chirp.c
index a72a34e..7a58538 100644
--- a/sim/ppc/emul_chirp.c
+++ b/sim/ppc/emul_chirp.c
@@ -1492,7 +1492,7 @@ typedef struct _chirp_note_head {
static void
map_over_chirp_note(bfd *image,
asection *sect,
- PTR obj)
+ void *obj)
{
chirp_note *note = (chirp_note*)obj;
if (strcmp(sect->name, ".note") == 0) {
diff --git a/sim/ppc/hw_htab.c b/sim/ppc/hw_htab.c
index ce09834..b4537fc 100644
--- a/sim/ppc/hw_htab.c
+++ b/sim/ppc/hw_htab.c
@@ -388,7 +388,7 @@ typedef struct _htab_binary_sizes {
static void
htab_sum_binary(bfd *abfd,
sec_ptr sec,
- PTR data)
+ void *data)
{
htab_binary_sizes *sizes = (htab_binary_sizes*)data;
unsigned_word size = bfd_section_size (sec);
@@ -422,7 +422,7 @@ htab_sum_binary(bfd *abfd,
static void
htab_dma_binary(bfd *abfd,
sec_ptr sec,
- PTR data)
+ void *data)
{
htab_binary_sizes *sizes = (htab_binary_sizes*)data;
void *section_init;
@@ -526,7 +526,7 @@ htab_map_binary(device *me,
}
/* determine the size of each of the files regions */
- bfd_map_over_sections (image, htab_sum_binary, (PTR) &sizes);
+ bfd_map_over_sections (image, htab_sum_binary, &sizes);
/* if needed, determine the real addresses of the sections */
if (ra != -1) {
@@ -590,7 +590,7 @@ htab_map_binary(device *me,
htaborg, htabmask);
/* dma the sections into physical memory */
- bfd_map_over_sections (image, htab_dma_binary, (PTR) &sizes);
+ bfd_map_over_sections (image, htab_dma_binary, &sizes);
}
static void
diff --git a/sim/ppc/hw_init.c b/sim/ppc/hw_init.c
index 66f2058..804daa9 100644
--- a/sim/ppc/hw_init.c
+++ b/sim/ppc/hw_init.c
@@ -316,7 +316,7 @@ static device_callbacks const hw_data_callbacks = {
static void
update_for_binary_section(bfd *abfd,
asection *the_section,
- PTR obj)
+ void *obj)
{
unsigned_word section_vma;
unsigned_word section_size;
@@ -431,7 +431,7 @@ hw_binary_init_data_callback(device *me)
/* and the data sections */
bfd_map_over_sections(image,
update_for_binary_section,
- (PTR)me);
+ me);
bfd_close(image);
}
diff --git a/sim/rl78/trace.c b/sim/rl78/trace.c
index a485c4c..669c2b5 100644
--- a/sim/rl78/trace.c
+++ b/sim/rl78/trace.c
@@ -78,7 +78,7 @@ remove_useless_symbols (asymbol ** symbols, long count)
}
static int
-compare_symbols (const PTR ap, const PTR bp)
+compare_symbols (const void *ap, const void *bp)
{
const asymbol *a = *(const asymbol **) ap;
const asymbol *b = *(const asymbol **) bp;
diff --git a/sim/rx/trace.c b/sim/rx/trace.c
index df83dc1..8d9293c 100644
--- a/sim/rx/trace.c
+++ b/sim/rx/trace.c
@@ -83,7 +83,7 @@ remove_useless_symbols (asymbol ** symbols, long count)
}
static int
-compare_symbols (const PTR ap, const PTR bp)
+compare_symbols (const void *ap, const void *bp)
{
const asymbol *a = *(const asymbol **) ap;
const asymbol *b = *(const asymbol **) bp;