diff options
Diffstat (limited to 'spm/scmi/include/ext/drivers/arm/system_timer.h')
-rw-r--r-- | spm/scmi/include/ext/drivers/arm/system_timer.h | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/spm/scmi/include/ext/drivers/arm/system_timer.h b/spm/scmi/include/ext/drivers/arm/system_timer.h new file mode 100644 index 0000000..3bb5dfa --- /dev/null +++ b/spm/scmi/include/ext/drivers/arm/system_timer.h @@ -0,0 +1,39 @@ +/* + * Copyright (c) 2018, Arm Limited. All rights reserved. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +#ifndef __SYSTEM_TIMER_H__ +#define __SYSTEM_TIMER_H__ + +#include <stdint.h> + +/* + * Program systimer to fire an interrupt after time_out_ms + * + * Always return 0 + */ +int program_systimer(unsigned long time_out_ms); +/* + * Cancel the currently programmed systimer interrupt + * + * Always return 0 + */ +int cancel_systimer(void); +/* + * Initialises the systimer so that it can be used for programming timer + * interrupt. + * Must be called by the primary CPU only. + * + * Always return 0 + */ +int init_systimer(uintptr_t systimer_base); +/* + * Handler to acknowledge and de-activate the systimer interrupt + * + * Always return 0 + */ +int handler_systimer(void); + +#endif /* __SYSTEM_TIMER_H__ */ |