Changes between Version 5 and Version 6 of xcu_driver
- Timestamp:
- Mar 13, 2015, 5:27:03 PM (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
xcu_driver
v5 v6 23 23 The addressable registers map is defined [source:soft/giet_vm/giet_drivers/xcu_driver.h here]. 24 24 25 == __Access Functions__ == 26 25 27 === void '''_xcu_set_mask'''( unsigned int cluster_xy, unsigned int channel, unsigned int mask, unsigned int irq_type ) === 26 This function set the mask register for the IRQ type defined by "irq_type", 27 and for the channel identified by the "cluster_xy" and "channel" arguments. 28 All '1' bits are set / all '0' bits are not modified. 28 This function set the mask register for all IRQs of a given type. 29 * '''cluster_xy''' : cluster coordinates. 30 * '''channel''' : XCU channel (output IRQ index). 31 * '''mask''' : mask value : All '1' bits are set / all '0' bits are not modified. 32 * '''irq_type''' : IRQ type. 29 33 30 34 === void '''_xcu_get_index'''( unsigned int cluster_xy, unsigned int channel, unsigned int * index, unsigned int * irq_type ) === 31 This function returns the index and the type of the highest priority active interrupt: 32 1. active PTI (Timer Interrupt), 33 2. active HWI (Hardware Interrupt), 34 3. active WTI (Software Interrupt) 35 * '''cluster_xy''' : cluster coordinates. 36 * '''channel''' : XCU channel (output IRQ index). 37 * '''index''' : pointer on the index buffer. 38 * '''irq_type''' : pointer on the IRQ type buffer. 39 This function returns the index and the type of the highest priority active interrupt with the following priorities: PTI > HWI > WTI. 35 40 36 41 === void '''_xcu_send_wti'''( unsigned int cluster_xy, unsigned int wti_index, unsigned int wdata ) === 37 This function writes the ''wdata'' value in the mailbox defined by the ''cluster_xy'' and ''wti_inde'' arguments. 42 This function writes a 32 bits word in a WTI mailbox. 43 * '''cluster_xy''' : cluster coordinates. 44 * '''wti_index''' : mailbox index. 45 * '''wdata''' : written value. 38 46 39 47 === void '''_xcu_get_wti_value'''( unsigned int cluster_xy, unsigned int wti_index, unsigned int * value ) === 40 This function returns the value contained in a WTI mailbox defined by the ''cluster_xy'' and ''wti_index'' arguments. This value is written in the ''value'' argument, and the corresponding WTI is acknowledged. 48 This function returns the value contained in a WTI mailbox. The corresponding WTI is acknowledged. 49 * '''cluster_xy''' : cluster coordinates. 50 * '''wti_index''' : mailbox index. 51 * '''value''' : pointer on the destination buffer. 41 52 42 53 === void '''_xcu_get_wti_address'''( unsigned int wti_index, unsigned int * address ) === 43 This function returns the physical address of the WTI mailbox in cluster [0][0], defined by the ''wti_index'' argument, in the ''address'' argument. 44 It is used by the GIET to configurate the IOPIC component. There is no access to a specific XCU component in a specific cluster. 54 This function returns the physical address (32 LSB bits) of the WTI mailbox identified by its index. 55 There is no access to a specific XCU component in a specific cluster. 56 * '''wti_index''' : WTI index. 57 * '''address''' : pointer on the destination buffer. 45 58 46 59 === void '''_xcu_timer_start'''( unsigned int cluster_xy, unsigned int pti_index, unsigned int period ) === 47 60 This function activates a timer contained in XCU by writing in the proper register the period value. 61 * '''cluster_xy''' : cluster coordinates. 62 * '''pti_index''' : mailbox index. 63 * '''period''' : period value. 48 64 49 65 === void '''_xcu_timer_stop'''( unsigned int cluster_xy, unsigned int pti_index ) === 50 66 This function desactivates a timer in XCU component by writing in the proper register. 67 * '''cluster_xy''' : cluster coordinates. 68 * '''pti_index''' : mailbox index. 51 69 52 === unsigned int'''_xcu_timer_reset_irq'''( unsigned int cluster_xy, unsigned int pti_index ) ===70 === void '''_xcu_timer_reset_irq'''( unsigned int cluster_xy, unsigned int pti_index ) === 53 71 This function acknowlegge a timer interrupt in XCU component by reading in the proper XCU register. 54 72 It is used by both the isr_switch() for a system timer, or by the _isr_timer() for an user timer. 73 * '''cluster_xy''' : cluster coordinates. 74 * '''pti_index''' : mailbox index. 55 75 56 76 === void '''_xcu_timer_reset_cpt'''( unsigned int cluster_xy, unsigned int pti_index ) === 57 This function resets a timer counter. To do so, it read in the TIMER_PERIOD register, and rewrite the same value in the same register, 58 what causes the count to restart. This function is called during a context switch (user or preemptive). 77 This function resets a timer counter. To do so, it read in the TIMER_PERIOD register, and rewrite the same value in the same register, what causes the count to restart. This function is called during a context switch (user or preemptive). 78 * '''cluster_xy''' : cluster coordinates. 79 * '''pti_index''' : mailbox index. 59 80