aboutsummaryrefslogtreecommitdiff
path: root/sim/mn10300
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2003-08-28 17:02:00 +0000
committerAndrew Cagney <cagney@redhat.com>2003-08-28 17:02:00 +0000
commite158f0a010490f7fc3363dc45b7045fd0277331d (patch)
tree9eb3151344923ef9fa23d181d1157454cf4f9194 /sim/mn10300
parente94cc8fa71f933ee86093243e3a37712aa8f41f5 (diff)
downloadgdb-e158f0a010490f7fc3363dc45b7045fd0277331d.zip
gdb-e158f0a010490f7fc3363dc45b7045fd0277331d.tar.gz
gdb-e158f0a010490f7fc3363dc45b7045fd0277331d.tar.bz2
Index: common/ChangeLog
2003-08-28 Andrew Cagney <cagney@redhat.com> * dv-glue.c (hw_glue_finish): Change %d to %ld to match sizeof. * sim-options.c (print_help): Cast the format with specifier to "int". Index: mn10300/ChangeLog 2003-08-28 Andrew Cagney <cagney@redhat.com> * dv-mn103ser.c (do_polling_event): Change type of "serial_reg" to "long". (read_status_reg): Cast "serial_reg" to "long". * dv-mn103tim.c (do_counter_event): Change type of "timer_nr" to "long". (do_counter6_event, write_mode_reg, write_tm6md): Ditto.
Diffstat (limited to 'sim/mn10300')
-rw-r--r--sim/mn10300/ChangeLog9
-rw-r--r--sim/mn10300/dv-mn103ser.c4
-rw-r--r--sim/mn10300/dv-mn103tim.c13
3 files changed, 18 insertions, 8 deletions
diff --git a/sim/mn10300/ChangeLog b/sim/mn10300/ChangeLog
index 9a5b602..5602ce8 100644
--- a/sim/mn10300/ChangeLog
+++ b/sim/mn10300/ChangeLog
@@ -1,3 +1,12 @@
+2003-08-28 Andrew Cagney <cagney@redhat.com>
+
+ * dv-mn103ser.c (do_polling_event): Change type of "serial_reg" to
+ "long".
+ (read_status_reg): Cast "serial_reg" to "long".
+ * dv-mn103tim.c (do_counter_event): Change type of "timer_nr" to
+ "long".
+ (do_counter6_event, write_mode_reg, write_tm6md): Ditto.
+
2003-02-27 Andrew Cagney <cagney@redhat.com>
* interp.c (sim_open, sim_create_inferior, sim_open)
diff --git a/sim/mn10300/dv-mn103ser.c b/sim/mn10300/dv-mn103ser.c
index 7f20ed1..bba20c9 100644
--- a/sim/mn10300/dv-mn103ser.c
+++ b/sim/mn10300/dv-mn103ser.c
@@ -240,7 +240,7 @@ do_polling_event (struct hw *me,
void *data)
{
struct mn103ser *serial = hw_data(me);
- int serial_reg = (int) data;
+ long serial_reg = (long) data;
char c;
int count;
@@ -421,7 +421,7 @@ read_status_reg (struct hw *me,
serial->device[serial_reg].event
= hw_event_queue_schedule (me, 1000,
do_polling_event,
- (void *)serial_reg);
+ (void *) (long) serial_reg);
}
if ( nr_bytes == 1 )
diff --git a/sim/mn10300/dv-mn103tim.c b/sim/mn10300/dv-mn103tim.c
index 9b1e0d2..a6272d8 100644
--- a/sim/mn10300/dv-mn103tim.c
+++ b/sim/mn10300/dv-mn103tim.c
@@ -568,7 +568,7 @@ do_counter_event (struct hw *me,
void *data)
{
struct mn103tim *timers = hw_data(me);
- int timer_nr = (int) data;
+ long timer_nr = (long) data;
int next_timer;
/* Check if counting is still enabled. */
@@ -609,7 +609,7 @@ do_counter6_event (struct hw *me,
void *data)
{
struct mn103tim *timers = hw_data(me);
- int timer_nr = (int) data;
+ long timer_nr = (long) data;
int next_timer;
/* Check if counting is still enabled. */
@@ -705,7 +705,7 @@ write_base_reg (struct hw *me,
static void
write_mode_reg (struct hw *me,
struct mn103tim *timers,
- int timer_nr,
+ long timer_nr,
const void *source,
unsigned nr_bytes)
/* for timers 0 to 5 */
@@ -716,7 +716,8 @@ write_mode_reg (struct hw *me,
if ( nr_bytes != 1 )
{
- hw_abort (me, "bad write size of %d bytes to TM%dMD.", nr_bytes, timer_nr);
+ hw_abort (me, "bad write size of %d bytes to TM%ldMD.", nr_bytes,
+ timer_nr);
}
mode_val = *(unsigned8 *)source;
@@ -742,7 +743,7 @@ write_mode_reg (struct hw *me,
{
if ( timer_nr == 0 || timer_nr == 4 )
{
- hw_abort(me, "Timer %d cannot be cascaded.", timer_nr);
+ hw_abort(me, "Timer %ld cannot be cascaded.", timer_nr);
}
}
else
@@ -839,7 +840,7 @@ write_tm6md (struct hw *me,
{
unsigned8 mode_val0 = 0x00, mode_val1 = 0x00;
unsigned32 div_ratio;
- int timer_nr = 6;
+ long timer_nr = 6;
unsigned_word offset = address - timers->block[0].base;