From: Michel Pollet Date: Sat, 19 Feb 2011 00:21:53 +0000 (+0000) Subject: core: Remove the run() callback X-Git-Tag: v1.0a7~37 X-Git-Url: https://git.htl-mechatronik.at/public/?a=commitdiff_plain;h=c1a849dc1b8a86c6d00970421b27756580ba6ac7;p=sx%2Fsimavr.git core: Remove the run() callback run() callback was unused but was still using cycles Signed-off-by: Michel Pollet --- diff --git a/simavr/sim/sim_avr.c b/simavr/sim/sim_avr.c index d21f109..7f7a3ab 100644 --- a/simavr/sim/sim_avr.c +++ b/simavr/sim/sim_avr.c @@ -180,15 +180,7 @@ int avr_run(avr_t * avr) if (avr->sreg[S_I] && !avr->i_shadow) avr->pending_wait++; avr->i_shadow = avr->sreg[S_I]; - - // run IO modules that wants it - avr_io_t * port = avr->io_port; - while (port) { - if (port->run) - port->run(port); - port = port->next; - } - + // run the cycle timers, get the suggested sleeo time // until the next timer is due avr_cycle_count_t sleep = avr_cycle_timer_process(avr); diff --git a/simavr/sim/sim_io.h b/simavr/sim/sim_io.h index e165678..ce42a63 100644 --- a/simavr/sim/sim_io.h +++ b/simavr/sim/sim_io.h @@ -47,8 +47,6 @@ typedef struct avr_io_t { uint32_t irq_ioctl_get; // used to get irqs from this module int irq_count; // number of (optional) irqs struct avr_irq_t * irq; // optional external IRQs - // called at every instruction - void (*run)(struct avr_io_t *io); // called at reset time void (*reset)(struct avr_io_t *io); // called externally. allow access to io modules and so on