| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
- /**
- * \file
- *
- * \section Purpose
- *
- * Methods and definitions for configuring interrupts.
- *
- * \section Usage
- * -# Enable or disable interrupt generation of a particular source with
- * IRQ_EnableIT and IRQ_DisableIT.
- * -# Start or stop the timer clock using TC_Start() and TC_Stop().
- */
- #ifndef GIC_H
- #define GIC_H
- /*------------------------------------------------------------------------------
- * Headers
- *------------------------------------------------------------------------------*/
- //#include "chip.h"
- #include <stdint.h>
- /*------------------------------------------------------------------------------
- * Global functions
- *------------------------------------------------------------------------------*/
- #ifdef __cplusplus
- extern "C" {
- #endif
- enum {
- IRQ_TYPE_EDGE_BOTH,
- IRQ_TYPE_EDGE_RISING,
- IRQ_TYPE_EDGE_FALLING,
- IRQ_TYPE_LEVEL_HIGH,
- IRQ_TYPE_LEVEL_LOW,
- };
- typedef void (*ISRFunction_t)(void *param);
- void GIC_IrqHandler(void);
- void GIC_Initialize(void);
- int32_t request_irq(uint32_t irq_source, int32_t priority,ISRFunction_t func, void *param);
- int32_t free_irq(uint32_t irq_source);
- #ifdef __cplusplus
- }
- #endif
- #endif //#ifndef GIC_H
|