diff options
| author | aozima <[email protected]> | 2013-03-23 17:34:52 +0800 |
|---|---|---|
| committer | aozima <[email protected]> | 2013-03-31 17:32:16 +0800 |
| commit | 6058efbd9ba70da9113c50c13e2493453c32c772 (patch) | |
| tree | 663161287a71f90cfe71475fb92e7700a3751cde /libcpu | |
| parent | 29a3ae43680f50123dbe045605093b2c0fe9616e (diff) | |
update Jz47xx: Modify the interrupt interface implementations.
Diffstat (limited to 'libcpu')
| -rw-r--r-- | libcpu/mips/jz47xx/interrupt.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libcpu/mips/jz47xx/interrupt.c b/libcpu/mips/jz47xx/interrupt.c index f9ada3254a..0ea4827ee2 100644 --- a/libcpu/mips/jz47xx/interrupt.c +++ b/libcpu/mips/jz47xx/interrupt.c @@ -90,7 +90,9 @@ rt_isr_handler_t rt_hw_interrupt_install(int vector, { old_handler = irq_handle_table[vector].handler; +#ifdef RT_USING_INTERRUPT_INFO rt_strncpy(irq_handle_table[vector].name, name, RT_NAME_MAX); +#endif /* RT_USING_INTERRUPT_INFO */ irq_handle_table[vector].handler = handler; irq_handle_table[vector].param = param; } @@ -118,6 +120,10 @@ void rt_interrupt_dispatch(void *ptreg) /* do interrupt */ (*irq_func)(i, irq_handle_table[i].param); +#ifdef RT_USING_INTERRUPT_INFO + irq_handle_table[i].counter++; +#endif /* RT_USING_INTERRUPT_INFO */ + /* ack interrupt */ INTC_IPR = (1 << i); } |
