From: Sebastien Bourdeauducq Date: Mon, 6 Feb 2012 23:07:25 +0000 (+0100) Subject: software: remove unnecessary IRQ acks X-Git-Tag: 24jan2021_ls180~3255 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=494c383fa8b1071a80e59407f6b1f8ea87308094;p=litex.git software: remove unnecessary IRQ acks --- diff --git a/software/include/base/irq.h b/software/include/base/irq.h index 37cf73fd..33bd05be 100644 --- a/software/include/base/irq.h +++ b/software/include/base/irq.h @@ -49,9 +49,4 @@ static inline unsigned int irq_pending(void) return pending; } -static inline void irq_ack(unsigned int mask) -{ - __asm__ __volatile__("wcsr IP, %0" : : "r" (mask)); -} - #endif /* __IRQ_H */ diff --git a/software/libbase/system.c b/software/libbase/system.c index 0edcb818..b253c214 100644 --- a/software/libbase/system.c +++ b/software/libbase/system.c @@ -44,7 +44,7 @@ __attribute__((noreturn)) void reboot(void) { uart_sync(); irq_setmask(0); - irq_enable(0); + irq_setie(0); CSR_SYSTEM_ID = 1; /* Writing to CSR_SYSTEM_ID causes a system reset */ while(1); } @@ -61,7 +61,7 @@ __attribute__((noreturn)) void reconf(void) { uart_sync(); irq_setmask(0); - irq_enable(0); + irq_setie(0); icap_write(0, 0xffff); /* dummy word */ icap_write(0, 0xffff); /* dummy word */ icap_write(0, 0xffff); /* dummy word */ diff --git a/software/libbase/uart.c b/software/libbase/uart.c index 8490bcdf..248e5f52 100644 --- a/software/libbase/uart.c +++ b/software/libbase/uart.c @@ -62,7 +62,6 @@ void uart_isr(void) } CSR_UART_EV_PENDING = stat; - irq_ack(IRQ_UART); } /* Do not use in interrupt handlers! */ @@ -108,8 +107,6 @@ void uart_init(void) tx_consume = 0; tx_cts = 1; - irq_ack(IRQ_UART); - /* ack any events */ CSR_UART_EV_PENDING = CSR_UART_EV_PENDING;