73 typedef volatile struct
83 typedef volatile struct
@ MSIP_ENABLE
Enable Software Interrupt */.
@ MSIP_DISABLE
Disable Software Interrupt */.
u32 clint_getTimeHigh()
Reads the high part of the current time.
void clint_setCmp(u64 cmp, u32 hart_id)
This function sets the compare value for the CLINT CMP register for a specific hardware thread.
u64 clint_getTime()
Reads the current time value from the CLINT TIME register.
double clint_timerSub(u64 t0, u64 t1)
Get the time difference between t0 and t1.
u32 clint_getTimeLow()
Reads the low part of the current time.
void clint_set_SoftInterrupt(clint_msip_t enable, u32 hart_id)
Sets the software interrupt state for a specific hart.
void clint_uDelay(u32 usec, u32 hz)
This function introduces a microsecond delay using the CLINT TIME register.
u32 clint_get_SoftInterrupt(u32 hart_id)
Obtain the current state of the software interrupt for a specific hart.
CLINT hardware register map.
u32 reserved1[(0xBFF8U - 0x4000 - 8 *HART_COUNT)/4U]
Reserved Space (0x4000 to 0xBFF7) */.
u32 MSIP[HART_COUNT]
Offset: 0x0000, Software Interrupt Pending for each hart */.
clint_mtimecmp_hwreg_t MTIMECMP[HART_COUNT]
Offset: 0x4000, MTIMECMP for each hart */.
u32 reserved0[(0x4000 - 4 *HART_COUNT)/4U]
Reserved Space (0x0C to 0x3FFF) */.
u32 MTIME_LOW
Offset: 0xBFF8, MTIME Low */.
CLINT MTIMECMP hardware register map.
u32 MTIMECMP_LOW
Offset: 0x00, MTIMECMP Low */.
u32 MTIMECMP_HIGH
Offset: 0x04, MTIMECMP High */.