blob: 04728baf0ce7f9da0adad6c7f10ae1d68b96adbb [file] [log] [blame]
/* SPDX-License-Identifier: GPL-2.0-only */
#include <bl_uapp/bl_syscall_public.h>
#include <stdint.h>
#include <timer.h>
void timer_monotonic_get(struct mono_time *mt)
{
/* Chrono timer is based on a 25MHz clock */
uint64_t clk;
svc_read_timer_val(PSP_TIMER_TYPE_CHRONO, &clk);
mt->microseconds = clk / 25;
}