move safe_irq_disable and irq_restore to isr.h

This commit is contained in:
Mariano Alvira 2010-05-12 16:40:44 -04:00
parent e0da07ae95
commit 1460eac9cd
2 changed files with 2 additions and 3 deletions

View file

@ -71,6 +71,8 @@ enum interrupt_nums {
#define enable_irq(irq) (*INTENNUM = INT_NUM_##irq)
#define disable_irq(irq) (*INTDISNUM = INT_NUM_##irq)
#define safe_irq_disable(x) volatile uint32_t saved_irq; saved_irq = *INTENABLE; disable_irq(x)
#define irq_restore() *INTENABLE = saved_irq
extern void tmr0_isr(void) __attribute__((weak));
extern void tmr1_isr(void) __attribute__((weak));

View file

@ -98,9 +98,6 @@ enum posts {
};
static volatile uint8_t last_post = NO_POST;
#define safe_irq_disable(x) volatile uint32_t saved_irq; saved_irq = *INTENABLE; disable_irq(x)
#define irq_restore() *INTENABLE = saved_irq
volatile uint8_t fcs_mode = USE_FCS;
/* call periodically to */