riscv: timer: Add support for an early timer
Added support for timer_early_get_count() and timer_early_get_rate() This is mostly useful in tracing. Signed-off-by: Pragnesh Patel <pragnesh.patel@sifive.com> Reviewed-by: Rick Chen <rick@andestech.com>
This commit is contained in:
@@ -17,6 +17,11 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#define RISCV_MMODE_TIMERBASE 0xe6000000
|
||||
#define RISCV_MMODE_TIMER_FREQ 60000000
|
||||
|
||||
#define RISCV_SMODE_TIMER_FREQ 60000000
|
||||
|
||||
/*
|
||||
* CPU and Board Configuration Options
|
||||
*/
|
||||
|
||||
@@ -29,6 +29,11 @@
|
||||
|
||||
#define CONFIG_STANDALONE_LOAD_ADDR 0x80200000
|
||||
|
||||
#define RISCV_MMODE_TIMERBASE 0x2000000
|
||||
#define RISCV_MMODE_TIMER_FREQ 1000000
|
||||
|
||||
#define RISCV_SMODE_TIMER_FREQ 1000000
|
||||
|
||||
/* Environment options */
|
||||
|
||||
#ifndef CONFIG_SPL_BUILD
|
||||
|
||||
@@ -36,6 +36,11 @@
|
||||
|
||||
#define CONFIG_STANDALONE_LOAD_ADDR 0x80200000
|
||||
|
||||
#define RISCV_MMODE_TIMERBASE 0x2000000
|
||||
#define RISCV_MMODE_TIMER_FREQ 1000000
|
||||
|
||||
#define RISCV_SMODE_TIMER_FREQ 1000000
|
||||
|
||||
/* Environment options */
|
||||
|
||||
#ifndef CONFIG_SPL_BUILD
|
||||
|
||||
Reference in New Issue
Block a user