Add qemu 2.4.0
[kvmfornfv.git] / qemu / roms / ipxe / src / include / ipxe / linux / linux_entropy.h
1 #ifndef _IPXE_LINUX_ENTROPY_H
2 #define _IPXE_LINUX_ENTROPY_H
3
4 /** @file
5  *
6  * iPXE entropy API for linux
7  *
8  */
9
10 FILE_LICENCE(GPL2_OR_LATER);
11
12 #ifdef ENTROPY_LINUX
13 #define ENTROPY_PREFIX_linux
14 #else
15 #define ENTROPY_PREFIX_linux __linux_
16 #endif
17
18 /**
19  * min-entropy per sample
20  *
21  * @ret min_entropy     min-entropy of each sample
22  */
23 static inline __always_inline double
24 ENTROPY_INLINE ( linux, min_entropy_per_sample ) ( void ) {
25
26         /* We read single bytes from /dev/random and assume that each
27          * contains full entropy.
28          */
29         return 8;
30 }
31
32 #endif /* _IPXE_LINUX_ENTROPY_H */