[edk2-devel] [PATCH edk2-platforms 02/15] Platform/AMD: add RngLib for Overdriveboard

Leif Lindholm posted 15 patches 5 years, 2 months ago
[edk2-devel] [PATCH edk2-platforms 02/15] Platform/AMD: add RngLib for Overdriveboard
Posted by Leif Lindholm 5 years, 2 months ago
OpenSSL now requires an RngLib. Add the generic
MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf
to fix Overdrive build.

Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
Signed-off-by: Leif Lindholm <leif@nuviainc.com>
---
 Platform/AMD/OverdriveBoard/OverdriveBoard.dsc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
index 5a38b9dd96ae..bf4d6dd7b804 100644
--- a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
+++ b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
@@ -119,6 +119,7 @@ [LibraryClasses.common]
   PlatformFlashAccessLib|Silicon/AMD/Styx/Library/StyxPlatformFlashAccessLib/StyxPlatformFlashAccessLib.inf
 
   OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
+  RngLib|MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf
   TlsLib|CryptoPkg/Library/TlsLib/TlsLib.inf
 
   UefiBootManagerLib|MdeModulePkg/Library/UefiBootManagerLib/UefiBootManagerLib.inf
-- 
2.20.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#67949): https://edk2.groups.io/g/devel/message/67949
Mute This Topic: https://groups.io/mt/78498662/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [edk2-devel] [PATCH edk2-platforms 02/15] Platform/AMD: add RngLib for Overdriveboard
Posted by Ard Biesheuvel 5 years, 2 months ago
On 11/25/20 1:55 PM, Leif Lindholm wrote:
> OpenSSL now requires an RngLib. Add the generic
> MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf
> to fix Overdrive build.
> 
> Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
> Signed-off-by: Leif Lindholm <leif@nuviainc.com>
> ---
>   Platform/AMD/OverdriveBoard/OverdriveBoard.dsc | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
> index 5a38b9dd96ae..bf4d6dd7b804 100644
> --- a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
> +++ b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
> @@ -119,6 +119,7 @@ [LibraryClasses.common]
>     PlatformFlashAccessLib|Silicon/AMD/Styx/Library/StyxPlatformFlashAccessLib/StyxPlatformFlashAccessLib.inf
>   
>     OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
> +  RngLib|MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf
>     TlsLib|CryptoPkg/Library/TlsLib/TlsLib.inf
>   
>     UefiBootManagerLib|MdeModulePkg/Library/UefiBootManagerLib/UefiBootManagerLib.inf
> 

Could we use DxeRngLib here? That will be backed by the h/w RNG instead 
of the cycle counter.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#67963): https://edk2.groups.io/g/devel/message/67963
Mute This Topic: https://groups.io/mt/78498662/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [edk2-devel] [PATCH edk2-platforms 02/15] Platform/AMD: add RngLib for Overdriveboard
Posted by Leif Lindholm 5 years, 2 months ago
On Wed, Nov 25, 2020 at 14:09:00 +0100, Ard Biesheuvel wrote:
> On 11/25/20 1:55 PM, Leif Lindholm wrote:
> > OpenSSL now requires an RngLib. Add the generic
> > MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf
> > to fix Overdrive build.
> > 
> > Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
> > Signed-off-by: Leif Lindholm <leif@nuviainc.com>
> > ---
> >   Platform/AMD/OverdriveBoard/OverdriveBoard.dsc | 1 +
> >   1 file changed, 1 insertion(+)
> > 
> > diff --git a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
> > index 5a38b9dd96ae..bf4d6dd7b804 100644
> > --- a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
> > +++ b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
> > @@ -119,6 +119,7 @@ [LibraryClasses.common]
> >     PlatformFlashAccessLib|Silicon/AMD/Styx/Library/StyxPlatformFlashAccessLib/StyxPlatformFlashAccessLib.inf
> >     OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
> > +  RngLib|MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf
> >     TlsLib|CryptoPkg/Library/TlsLib/TlsLib.inf
> >     UefiBootManagerLib|MdeModulePkg/Library/UefiBootManagerLib/UefiBootManagerLib.inf
> > 
> 
> Could we use DxeRngLib here? That will be backed by the h/w RNG instead of
> the cycle counter.

You mean since we have EFI_RNG_PROTOCOL from StyxRngDxe?
Good point, had forgotten about that.
OK to fold in before pushing?

/
    Leif


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#67970): https://edk2.groups.io/g/devel/message/67970
Mute This Topic: https://groups.io/mt/78498662/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [edk2-devel] [PATCH edk2-platforms 02/15] Platform/AMD: add RngLib for Overdriveboard
Posted by Ard Biesheuvel 5 years, 2 months ago
On 11/25/20 2:20 PM, Leif Lindholm wrote:
> On Wed, Nov 25, 2020 at 14:09:00 +0100, Ard Biesheuvel wrote:
>> On 11/25/20 1:55 PM, Leif Lindholm wrote:
>>> OpenSSL now requires an RngLib. Add the generic
>>> MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf
>>> to fix Overdrive build.
>>>
>>> Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
>>> Signed-off-by: Leif Lindholm <leif@nuviainc.com>
>>> ---
>>>    Platform/AMD/OverdriveBoard/OverdriveBoard.dsc | 1 +
>>>    1 file changed, 1 insertion(+)
>>>
>>> diff --git a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
>>> index 5a38b9dd96ae..bf4d6dd7b804 100644
>>> --- a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
>>> +++ b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc
>>> @@ -119,6 +119,7 @@ [LibraryClasses.common]
>>>      PlatformFlashAccessLib|Silicon/AMD/Styx/Library/StyxPlatformFlashAccessLib/StyxPlatformFlashAccessLib.inf
>>>      OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
>>> +  RngLib|MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf
>>>      TlsLib|CryptoPkg/Library/TlsLib/TlsLib.inf
>>>      UefiBootManagerLib|MdeModulePkg/Library/UefiBootManagerLib/UefiBootManagerLib.inf
>>>
>>
>> Could we use DxeRngLib here? That will be backed by the h/w RNG instead of
>> the cycle counter.
> 
> You mean since we have EFI_RNG_PROTOCOL from StyxRngDxe?
> Good point, had forgotten about that.
> OK to fold in before pushing?
> 


Sure

Acked-by: Ard Biesheuvel <ard.biesheuvel@arm.com>


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#67971): https://edk2.groups.io/g/devel/message/67971
Mute This Topic: https://groups.io/mt/78498662/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-