1 /*
2  * SPDX-License-Identifier: Apache-2.0
3  *
4  * Copyright (c) 2020 Arm Limited
5  */
6 
7 #ifndef __FAULT_INJECTION_HARDENING_DELAY_RNG_H__
8 #define __FAULT_INJECTION_HARDENING_DELAY_RNG_H__
9 
10 #ifdef __cplusplus
11 extern "C" {
12 #endif /* __cplusplus */
13 
14 /**
15  * \brief Set up the RNG for use with random delays. Called once at startup.
16  */
17 int fih_delay_init(void);
18 
19 /**
20  * \brief Get a random unsigned char from an RNG seeded with an entropy source.
21  *
22  * \return A random value that fits inside an unsigned char.
23  */
24 unsigned char fih_delay_random_uchar(void);
25 
26 #ifdef __cplusplus
27 }
28 #endif /* __cplusplus */
29 
30 #endif /* __FAULT_INJECTION_HARDENING_DELAY_RNG_H__ */
31