Changes between Version 3 and Version 4 of icu_device_api
- Timestamp:
- Nov 3, 2016, 7:54:45 PM (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
icu_device_api
v3 v4 1 = ICU genericdevice API =1 = ICU device API = 2 2 3 3 [[PageOutline]] … … 5 5 == A) General principles == 6 6 7 The ICU (Interrupt Controller Unit) device is an ''internal'' peripheral, distributedin all clusters containing cores.8 He is in charge of concentrating all IRQs (interrupt request) generated by the - internal or external - peripherals to signal the completion of a given I/O operation, and routing each IRQ to the core that started the I/O operation. He is also in charge of helping the kernel to select the ISR (Interrupt Service Routine) tobe executed by the target core.7 The ICU (Interrupt Controller Unit) generic device describes an ''internal'' peripheral, acting in all clusters containing cores. 8 He is in charge of concentrating all IRQs (interrupt request) generated by the - internal or external - peripherals to signal the completion of the I/O operation started by a core in a given cluster. Each IRQ should be routed to the core that started the I/O operation. The ICU device must also help the kernel to select the ISR (Interrupt Service Routine) that must be executed by the target core. 9 9 10 This component can be implemented as a dedicated hardware, distributed in all clusters, or emulated in software,10 This component can be implemented as a dedicated hardware, centralized or distributed in all clusters, or emulated in software, 11 11 as long as it implements the API defined below. 12 12 … … 39 39 The <icu> argument is a local pointer on the ICU device descriptor. 40 40 41 === 2) '''error_t dev_icu_enable_irq'''( uint32_t irq_type , uint32_t irq_id , device_t *src_dev ) ===41 === 2) '''error_t dev_icu_enable_irq'''( uint32_t irq_type , uint32_t irq_id , xptr_t src_dev ) === 42 42 43 43 This function must be executed by a thread running in the cluster containing the ICU device descriptor. It enables one IRQ defined by its type and index for the calling core, and register it in the interrupt vector. … … 51 51 It returns 0 if success / returns EINVAL if illegal arguments. 52 52 53 53 === 4) '''error_t dev_icu_set_period'''( core_t * core , uint32_t pti_id , uint32_t period ) === 54 54 55 This function set the period value for a PTI timer identified by its index in the local ICU device descriptor. 56 The <core> argument is local pointer on the target core. The <pti_id> argument is the timer index. 57 The <period> argument is the period value (number of cycles). 58 It return 0 if success / returns EINVAL if illegal arguments. 55 59 56 /*****************************************************************************************57 * This blocking function set the period value for a timer identified by the PTI index58 * in the local ICU device descriptor.59 *****************************************************************************************60 * @ pti_id : PTI index.61 * @ period : number of cycles.62 * @ return 0 if success / returns EINVAL if illegal arguments.63 ****************************************************************************************/64 error_t dev_icu_set_period( core_t * core,65 uint32_t pti_id,66 uint32_t period );67 60 68 61 /*****************************************************************************************