]>
git.proxmox.com Git - mirror_edk2.git/blob - MdePkg/Library/BaseRngLib/BaseRngLibInternals.h
3 Architecture specific interface to RNG functionality.
5 Copyright (c) 2021, NUVIA Inc. All rights reserved.<BR>
7 SPDX-License-Identifier: BSD-2-Clause-Patent
11 #ifndef BASE_RNGLIB_INTERNALS_H_
14 Generates a 16-bit random number.
16 @param[out] Rand Buffer pointer to store the 16-bit random value.
18 @retval TRUE Random number generated successfully.
19 @retval FALSE Failed to generate the random number.
24 ArchGetRandomNumber16 (
29 Generates a 32-bit random number.
31 @param[out] Rand Buffer pointer to store the 32-bit random value.
33 @retval TRUE Random number generated successfully.
34 @retval FALSE Failed to generate the random number.
39 ArchGetRandomNumber32 (
44 Generates a 64-bit random number.
46 @param[out] Rand Buffer pointer to store the 64-bit random value.
48 @retval TRUE Random number generated successfully.
49 @retval FALSE Failed to generate the random number.
54 ArchGetRandomNumber64 (
59 Checks whether the RNG instruction is supported.
61 @retval TRUE RNG instruction is supported.
62 @retval FALSE RNG instruction is not supported.
71 #if defined (MDE_CPU_AARCH64)
73 // RNDR, Random Number
74 #define RNDR S3_3_C2_C4_0
78 #endif // BASE_RNGLIB_INTERNALS_H_