Branch: refs/heads/master Home: https://github.com/tianocore/edk2 Commit: dcf8c790560c7344c80c157b4919d75aafc93dba https://github.com/tianocore/edk2/commit/dcf8c790560c7344c80c157b4919d75aafc93dba Author: Sami Mujawar <sami.muja...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022)
Changed paths: M ArmPkg/ArmPkg.dec Log Message: ----------- ArmPkg: PCD to select conduit for monitor calls Define a PCD 'PcdMonitorConduitHvc' to select the conduit to use for monitor calls. PcdMonitorConduitHvc is defined as FALSE by default, meaning the SMC conduit is enabled as default. Adding PcdMonitorConduitHvc allows selection of HVC conduit to be used by virtual firmware implementations. Reviewed-by: Leif Lindholm <quic_llind...@quicinc.com> Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Commit: 9a50990cdb5a8f3ecdcd343ac78c58aaf5b2dbc3 https://github.com/tianocore/edk2/commit/9a50990cdb5a8f3ecdcd343ac78c58aaf5b2dbc3 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M ArmPkg/ArmPkg.dec A ArmPkg/Include/Library/ArmMonitorLib.h Log Message: ----------- ArmPkg/ArmMonitorLib: Definition for ArmMonitorLib library class The ArmMonitorLib provides an abstract interface to issue an HyperVisor Call (HVC) or System Monitor Call (SMC) depending on the default conduit. The PcdMonitorConduitHvc PCD allows to select the default conduit. The new library relies on the ArmHvcLib and ArmSmcLib libraries. A Null instance of these libraries can be used for the unused conduit. Reviewed-by: Leif Lindholm <quic_llind...@quicinc.com> Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Commit: aa0f522471b3832a8ced9d5ca22d0a7d9ea678a2 https://github.com/tianocore/edk2/commit/aa0f522471b3832a8ced9d5ca22d0a7d9ea678a2 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M ArmPkg/ArmPkg.dsc A ArmPkg/Library/ArmMonitorLib/ArmMonitorLib.c A ArmPkg/Library/ArmMonitorLib/ArmMonitorLib.inf Log Message: ----------- ArmPkg/ArmMonitorLib: Add ArmMonitorLib The ArmMonitorLib provides an abstract interface to issue an HyperVisor Call (HVC) or System Monitor Call (SMC) depending on the default conduit. The PcdMonitorConduitHvc PCD allows to select the default conduit. Reviewed-by: Leif Lindholm <quic_llind...@quicinc.com> Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Commit: 9d8ed9c8ee859aee04f88fda060d2f024a1e0905 https://github.com/tianocore/edk2/commit/9d8ed9c8ee859aee04f88fda060d2f024a1e0905 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M ArmPkg/ArmPkg.dsc Log Message: ----------- ArmPkg: Sort HVC/SMC section alphbetically in ArmPkg.dsc Sort the section containing HVC/SMC libraries prior to adding new libraries in this specific section. Reviewed-by: Leif Lindholm <quic_llind...@quicinc.com> Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Commit: 3d480a93defc0e39410877b477519592b7656b3d https://github.com/tianocore/edk2/commit/3d480a93defc0e39410877b477519592b7656b3d Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M ArmPkg/ArmPkg.dsc A ArmPkg/Library/ArmHvcLibNull/ArmHvcLibNull.c A ArmPkg/Library/ArmHvcLibNull/ArmHvcLibNull.inf Log Message: ----------- ArmPkg/ArmHvcLibNull: Add NULL instance of ArmHvcLib Add a Null instance of ArmHvcLib in case of library dependencies. Reviewed-by: Leif Lindholm <quic_llind...@quicinc.com> Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Commit: cbce5a1a93ab092d9c2c4c7949f26f6a9d753995 https://github.com/tianocore/edk2/commit/cbce5a1a93ab092d9c2c4c7949f26f6a9d753995 Author: Sami Mujawar <sami.muja...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: A MdePkg/Include/Library/ArmTrngLib.h M MdePkg/MdePkg.dec Log Message: ----------- MdePkg/ArmTrngLib: Definition for Arm TRNG library class interface Bugzilla: 3668 (https://bugzilla.tianocore.org/show_bug.cgi?id=3668) The NIST Special Publications 800-90A, 800-90B and 800-90C provide recommendations for random number generation. The NIST 800-90C, Recommendation for Random Bit Generator (RBG) Constructions, defines the GetEntropy() interface that is used to access the entropy source. The GetEntropy() interface is further used by Deterministic Random Bit Generators (DRBG) to generate random numbers. The Arm True Random Number Generator (TRNG) library defines an interface to access the entropy source on a platform, following the 'Arm True Random Number Generator Firmware Interface' specification. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Reviewed-by: Liming Gao <gaolim...@byosoft.com.cn> Commit: ef4cf3d88df2dd2b8afa790007c9f62a3d6cfcd6 https://github.com/tianocore/edk2/commit/ef4cf3d88df2dd2b8afa790007c9f62a3d6cfcd6 Author: Sami Mujawar <sami.muja...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: A MdePkg/Library/BaseArmTrngLibNull/BaseArmTrngLibNull.c A MdePkg/Library/BaseArmTrngLibNull/BaseArmTrngLibNull.inf A MdePkg/Library/BaseArmTrngLibNull/BaseArmTrngLibNull.uni M MdePkg/MdeLibs.dsc.inc M MdePkg/MdePkg.dsc Log Message: ----------- MdePkg/ArmTrngLib: Add NULL instance of Arm TRNG Library Bugzilla: 3668 (https://bugzilla.tianocore.org/show_bug.cgi?id=3668) The Arm True Random Number Generator (TRNG) library defines an interface to access the entropy source on a platform. On platforms that do not have access to an entropy source, a NULL instance of the TRNG library may be useful to satisfy the build dependency. Therefore, add a NULL instance of the Arm TRNG library. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Reviewed-by: Liming Gao <gaolim...@byosoft.com.cn> Commit: 351fe776668ca50aadab8b2b0614ed520c12c09e https://github.com/tianocore/edk2/commit/351fe776668ca50aadab8b2b0614ed520c12c09e Author: Sami Mujawar <sami.muja...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M ArmPkg/Include/IndustryStandard/ArmStdSmc.h Log Message: ----------- ArmPkg: Add FID definitions for Arm TRNG Bugzilla: 3668 (https://bugzilla.tianocore.org/show_bug.cgi?id=3668) The Arm True Random Number Generator Firmware, Interface 1.0, Platform Design Document (https://developer.arm.com/documentation/den0098/latest/) defines an interface between an Operating System (OS) executing at EL1 and Firmware (FW) exposing a conditioned entropy source that is provided by a TRNG back end. New function IDs have been defined by the specification for accessing the TRNG services. Therefore, add these definitions to the Arm standard SMC header. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Reviewed-by: Ard Biesheuvel <a...@kernel.org> Commit: e00ec499c5b72c6ef3920aa6b18aebaf13175ee3 https://github.com/tianocore/edk2/commit/e00ec499c5b72c6ef3920aa6b18aebaf13175ee3 Author: Sami Mujawar <sami.muja...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M ArmPkg/ArmPkg.dsc A ArmPkg/Library/ArmTrngLib/ArmTrngDefs.h A ArmPkg/Library/ArmTrngLib/ArmTrngLib.c A ArmPkg/Library/ArmTrngLib/ArmTrngLib.inf Log Message: ----------- ArmPkg/ArmTrngLib: Add Arm TRNG library Bugzilla: 3668 (https://bugzilla.tianocore.org/show_bug.cgi?id=3668) The Arm True Random Number Generator Firmware, Interface 1.0, Platform Design Document (https://developer.arm.com/documentation/den0098/latest/) defines an interface between an Operating System (OS) executing at EL1 and Firmware (FW) exposing a conditioned entropy source that is provided by a TRNG back end. The conditioned entropy, that is provided by the Arm TRNG interface, is commonly used to seed deterministic random number generators. This patch adds an ArmTrngLib library that implements the Arm TRNG interface. Acked-by: Leif Lindholm <quic_llind...@quicinc.com> Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Commit: 8a89747844a5061791e55a25daedcf895180a794 https://github.com/tianocore/edk2/commit/8a89747844a5061791e55a25daedcf895180a794 Author: Sami Mujawar <sami.muja...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M SecurityPkg/RandomNumberGenerator/RngDxe/Rand/RdRand.c R SecurityPkg/RandomNumberGenerator/RngDxe/Rand/RdRand.h M SecurityPkg/RandomNumberGenerator/RngDxe/Rand/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxeInternals.h Log Message: ----------- SecurityPkg/RngDxe: Rename RdRandGenerateEntropy to generic name Bugzilla: 3668 (https://bugzilla.tianocore.org/show_bug.cgi?id=3668) Rename RdRandGenerateEntropy() to GenerateEntropy() to provide a common interface to generate entropy on other architectures. GenerateEntropy() is intended to generate high quality entropy. Also move the definition to RngDxeInternals.h Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: aade3b93feddfb538e1f93207affb3f0d9cef5e8 https://github.com/tianocore/edk2/commit/aade3b93feddfb538e1f93207affb3f0d9cef5e8 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M SecurityPkg/RandomNumberGenerator/RngDxe/Rand/RngDxe.c Log Message: ----------- SecurityPkg/RngDxe: Replace Pcd with Sp80090Ctr256Guid gEfiRngAlgorithmSp80090Ctr256Guid was used as the default algorithm in RngGetRNG(). The commit below set the default algorithm to PcdCpuRngSupportedAlgorithm, which is a zero GUID by default. As the Pcd value is not defined for any platform in the edk2-platfoms repository, assume it was an error and go back to the first version, using gEfiRngAlgorithmSp80090Ctr256Guid. Fixes: 4e5ecdbac8bd ("SecurityPkg: Add support for RngDxe on AARCH64") Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: 922bf317f1731554b3e77a0a48033a38fdc75a77 https://github.com/tianocore/edk2/commit/922bf317f1731554b3e77a0a48033a38fdc75a77 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M SecurityPkg/RandomNumberGenerator/RngDxe/AArch64/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/Rand/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxeInternals.h Log Message: ----------- SecurityPkg/RngDxe: Remove ArchGetSupportedRngAlgorithms() RngGetInfo() is one of the 2 functions of the EFI_RNG_PROTOCOL. RngGetInfo() is currently a mere wrapper around ArchGetSupportedRngAlgorithms() which is implemented differently depending on the architecture used. RngGetInfo() does nothing more than calling ArchGetSupportedRngAlgorithms(). So remove it, and let RngGetInfo() be implemented differently according to the architecture. This follows the implementation of the other function of the EFI_RNG_PROTOCOL, RngGetRNG(). Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: 199031b2b0233652ad5d5fdf73f0f44c0f264d55 https://github.com/tianocore/edk2/commit/199031b2b0233652ad5d5fdf73f0f44c0f264d55 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M SecurityPkg/RandomNumberGenerator/RngDxe/AArch64/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/Rand/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.c Log Message: ----------- SecurityPkg/RngDxe: Documentation/include/parameter cleanup This patch: -Update RngGetBytes() documentation to align the function definition and declaration. -Improve input parameter checking. Even though 'This' it is not used, the parameter should always point to the current EFI_RNG_PROTOCOL. -Removes TimerLib inclusion as unused. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: 4b3e9d80bedf5909a4ec901425ed9c0a738fc76f https://github.com/tianocore/edk2/commit/4b3e9d80bedf5909a4ec901425ed9c0a738fc76f Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M SecurityPkg/RandomNumberGenerator/RngDxe/AArch64/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/Rand/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxeInternals.h Log Message: ----------- SecurityPkg/RngDxe: Check before advertising Cpu Rng algo RngGetBytes() relies on the RngLib. The RngLib might use the RNDR instruction if the FEAT_RNG feature is present. RngGetInfo and RngGetRNG both must check that RngGetBytes() is working before advertising/using it. To do so, allocate an array storing the available algorithms. The Rng algorithm at the lowest index will be the default Rng algorithm. The array is shared between RngGetInfo and RngGetRNG. This array is allocated when the driver is loaded, and freed when unloaded. This patch also prevents from having PcdCpuRngSupportedAlgorithm let to a zero GUID, but let the possibility to have no valid Rng algorithm in such case. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: 863fe9e191fb3d90c3283062183692c04cd71975 https://github.com/tianocore/edk2/commit/863fe9e191fb3d90c3283062183692c04cd71975 Author: Sami Mujawar <sami.muja...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M SecurityPkg/RandomNumberGenerator/RngDxe/AArch64/RngDxe.c A SecurityPkg/RandomNumberGenerator/RngDxe/ArmTrng.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf M SecurityPkg/SecurityPkg.dsc Log Message: ----------- SecurityPkg/RngDxe: Add AArch64 RawAlgorithm support through ArmTrngLib Bugzilla: 3668 (https://bugzilla.tianocore.org/show_bug.cgi?id=3668) RawAlgorithm is used to provide access to entropy that is suitable for cryptographic applications. Therefore, add RawAlgorithm support that provides access to entropy using the ArmTrngLib. Also remove unused UefiBootServicesTableLib library inclusion and Status variable. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: 6cdddccf0085cf2929f8ae710515e4e53663dfb2 https://github.com/tianocore/edk2/commit/6cdddccf0085cf2929f8ae710515e4e53663dfb2 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M SecurityPkg/RandomNumberGenerator/RngDxe/AArch64/RngDxe.c Log Message: ----------- SecurityPkg/RngDxe: Add debug warning for NULL PcdCpuRngSupportedAlgorithm PcdCpuRngSupportedAlgorithm should allow to identify the the algorithm used by the RNDR CPU instruction to generate a random number. Add a debug warning if the Pcd is not set. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: ff29cdb968a1a4d7bd7ab4eba2597a77c0748dc2 https://github.com/tianocore/edk2/commit/ff29cdb968a1a4d7bd7ab4eba2597a77c0748dc2 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: R SecurityPkg/RandomNumberGenerator/RngDxe/AArch64/RngDxe.c A SecurityPkg/RandomNumberGenerator/RngDxe/ArmRngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf Log Message: ----------- SecurityPkg/RngDxe: Rename AArch64/RngDxe.c To re-use the AArch64/RngDxe.c for an Arm implementation, rename AArch64/RngDxe.c to ArmRngDxe.c. Acked-by: Leif Lindholm <quic_llind...@quicinc.com> Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: 9eb5ccda505917f6ee80284ed6fb5b51aa7152f9 https://github.com/tianocore/edk2/commit/9eb5ccda505917f6ee80284ed6fb5b51aa7152f9 Author: Pierre Gondois <pierre.gond...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: A SecurityPkg/RandomNumberGenerator/RngDxe/AArch64/AArch64Algo.c A SecurityPkg/RandomNumberGenerator/RngDxe/Arm/ArmAlgo.c M SecurityPkg/RandomNumberGenerator/RngDxe/ArmRngDxe.c M SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf M SecurityPkg/SecurityPkg.dsc Log Message: ----------- SecurityPkg/RngDxe: Add Arm support of RngDxe Bugzilla: 3668 (https://bugzilla.tianocore.org/show_bug.cgi?id=3668) Add RngDxe support for Arm. This implementation uses the ArmTrngLib to support the RawAlgorithm and doens't support the RNDR instruction. To re-use the RngGetRNG(), RngGetInfo() and FreeAvailableAlgorithms() functions, create Arm/AArch64 files which implement the arch specific function GetAvailableAlgorithms(). Indeed, FEAT_RNG instruction is not supported on Arm. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Acked-by: Jiewen Yao <jiewen....@intel.com> Commit: b556f2445c251adf405ac966b48c237d20c0d46c https://github.com/tianocore/edk2/commit/b556f2445c251adf405ac966b48c237d20c0d46c Author: Sami Mujawar <sami.muja...@arm.com> Date: 2022-11-06 (Sun, 06 Nov 2022) Changed paths: M ArmVirtPkg/ArmVirtKvmTool.dsc M ArmVirtPkg/ArmVirtKvmTool.fdf Log Message: ----------- ArmVirtPkg: Kvmtool: Add RNG support using Arm TRNG interface Bugzilla: 3668 (https://bugzilla.tianocore.org/show_bug.cgi?id=3668) The EFI_RNG_PROTOCOL published by RngDxe has been updated to implement the EFI_RNG_ALGORITHM_RAW using the Arm TRNG interface to provide access to entropy. Therefore, enable EFI_RNG_PROTOCOL for the Kvmtool guest/virtual firmware. Signed-off-by: Pierre Gondois <pierre.gond...@arm.com> Reviewed-by: Ard Biesheuvel <a...@kernel.org> Compare: https://github.com/tianocore/edk2/compare/cc650a0378f8...b556f2445c25 _______________________________________________ edk2-commits mailing list edk2-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/edk2-commits