File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed
bsp/raspberry-pi/raspi3-64/driver
libcpu/aarch64/cortex-a53 Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,8 @@ static rt_uint64_t timerStep;
2525
2626int rt_hw_get_gtimer_frq (void );
2727void rt_hw_set_gtimer_val (rt_uint64_t value );
28+ int rt_hw_get_gtimer_val (void );
29+ int rt_hw_get_cntpct_val (void );
2830void rt_hw_gtimer_enable (void );
2931
3032void core0_timer_enable_interrupt_controller ()
Original file line number Diff line number Diff line change @@ -25,6 +25,20 @@ rt_hw_set_gtimer_val:
2525 MSR CNTP_TVAL_EL0 , X0
2626 RET
2727
28+ / *
29+ * get gtimer CNTP_TVAL_EL0 value
30+ * /
31+ .globl rt_hw_get_gtimer_val
32+ rt_hw_get_gtimer_val:
33+ MRS X0 , CNTP_TVAL_EL0
34+ RET
35+
36+
37+ .globl rt_hw_get_cntpct_val
38+ rt_hw_get_cntpct_val:
39+ MRS X0 , CNTPCT_EL0
40+ RET
41+
2842/ *
2943 * get gtimer frq value
3044 * /
You can’t perform that action at this time.
0 commit comments