static uint32_t read_uart (uint32_t addr);
static void write_uart (uint32_t addr, uint32_t data);
static void flush_uart (void);
-static void uarta_tx (void);
-static void uartb_tx (void);
-static void uart_rx (void *arg);
-static void uart_intr (void *arg);
+static void uarta_tx (int32_t);
+static void uartb_tx (int32_t);
+static void uart_rx (int32_t);
+static void uart_intr (int32_t);
static void uart_irq_start (void);
-static void wdog_intr (void *arg);
+static void wdog_intr (int32_t);
static void wdog_start (void);
-static void rtc_intr (void *arg);
+static void rtc_intr (int32_t);
static void rtc_start (void);
static uint32_t rtc_counter_read (void);
static void rtc_scaler_set (uint32_t val);
static void rtc_reload_set (uint32_t val);
-static void gpt_intr (void *arg);
+static void gpt_intr (int32_t);
static void gpt_start (void);
static uint32_t gpt_counter_read (void);
static void gpt_scaler_set (uint32_t val);
ATTRIBUTE_UNUSED
static void
-uarta_tx(void)
+uarta_tx(int32_t arg ATTRIBUTE_UNUSED)
{
while (f1open && fwrite(&uarta_sreg, 1, 1, f1out) != 1);
ATTRIBUTE_UNUSED
static void
-uartb_tx(void)
+uartb_tx(int32_t arg ATTRIBUTE_UNUSED)
{
while (f2open && fwrite(&uartb_sreg, 1, 1, f2out) != 1);
if (uart_stat_reg & UARTB_HRE) {
ATTRIBUTE_UNUSED
static void
-uart_rx(void *arg)
+uart_rx(int32_t arg ATTRIBUTE_UNUSED)
{
int32_t rsize;
char rxd;
}
static void
-uart_intr(void *arg)
+uart_intr(int32_t arg ATTRIBUTE_UNUSED)
{
read_uart(0xE8); /* Check for UART interrupts every 1000 clk */
flush_uart(); /* Flush UART ports */
/* Watch-dog */
static void
-wdog_intr(void *arg)
+wdog_intr(int32_t arg ATTRIBUTE_UNUSED)
{
if (wdog_status == disabled) {
wdog_status = stopped;
static void
-rtc_intr(void *arg)
+rtc_intr(int32_t arg ATTRIBUTE_UNUSED)
{
if (rtc_counter == 0) {
}
static void
-gpt_intr(void *arg)
+gpt_intr(int32_t arg ATTRIBUTE_UNUSED)
{
if (gpt_counter == 0) {
mec_irq(12);
#ifdef ERRINJ
void
-errinj (void)
+errinj (int32_t arg ATTRIBUTE_UNUSED)
{
int err;
/* Add event to event queue */
void
-event(void (*cfunc) (), int32_t arg, uint64_t delta)
+event(void (*cfunc) (int32_t), int32_t arg, uint64_t delta)
{
struct evcell *ev1, *evins;
{
struct evcell *evrem;
- void (*cfunc) ();
- uint32_t arg;
+ void (*cfunc) (int32_t);
+ int32_t arg;
uint64_t endtime;
#ifdef STAT
wait_for_irq(void)
{
struct evcell *evrem;
- void (*cfunc) ();
+ void (*cfunc) (int32_t);
int32_t arg;
uint64_t endtime;
};
struct evcell {
- void (*cfunc) ();
+ void (*cfunc) (int32_t);
int32_t arg;
uint64_t time;
struct evcell *nxt;
struct disassemble_info;
extern void dis_mem (uint32_t addr, uint32_t len,
struct disassemble_info *info);
-extern void event (void (*cfunc) (), int32_t arg, uint64_t delta);
+extern void event (void (*cfunc) (int32_t), int32_t arg, uint64_t delta);
extern void set_int (int32_t level, void (*callback) (), int32_t arg);
extern void advance_time (struct pstate *sregs);
extern uint32_t now (void);