Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Wang, Jian J
Laszlo,


> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Laszlo Ersek
> Sent: Tuesday, November 12, 2019 3:50 PM
> To: Wang, Jian J ; devel@edk2.groups.io
> Cc: Yao, Jiewen ; Zhang, Chao B
> ; Kinney, Michael D ;
> Gao, Liming ; Ard Biesheuvel
> ; Ni, Ray 
> Subject: Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of
> RngLib
> 
> On 11/12/19 06:55, Jian J Wang wrote:
> > This is null version of RngLib which is used for those platforms or
> > components which don't need random number.
> >
> > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> > Cc: Jiewen Yao 
> > Cc: Chao Zhang 
> > Cc: Michael D Kinney 
> > Cc: Liming Gao 
> > Cc: Laszlo Ersek 
> > Cc: Ard Biesheuvel 
> > Cc: Ray Ni 
> > Signed-off-by: Jian J Wang 
> > ---
> >  .../RngLibNull/RngLibNull.c   | 95 +++
> >  .../RngLibNull/RngLibNull.inf | 31 ++
> >  .../RngLibNull/RngLibNull.uni | 14 +++
> >  3 files changed, 140 insertions(+)
> >  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> >  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> >  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> 
> (1) I don't see any reason why this library instance should not be added
> under MdePkg/Library. The other library instance is already there (and
> the lib class header too is from MdePkg):
> 
>   MdePkg/Library/BaseRngLib
> 
> (2) I think this library instance should be called "BaseRngLibNull", not
> just "RngLibNull".
> 

I have no strong opinion on this.

Liming, do you have any comments?

> More below:
> 
> > diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > new file mode 100644
> > index 00..13677abc84
> > --- /dev/null
> > +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > @@ -0,0 +1,95 @@
> > +/** @file
> > +  Null version of Random number generator services.
> > +
> > +Copyright (c) 2019, Intel Corporation. All rights reserved.
> > +SPDX-License-Identifier: BSD-2-Clause-Patent
> > +
> > +**/
> > +
> > +#include 
> > +#include 
> > +#include 
> > +
> > +/**
> > +  Generates a 16-bit random number.
> > +
> > +  if Rand is NULL, then ASSERT().
> > +
> > +  @param[out] Rand Buffer pointer to store the 16-bit random value.
> > +
> > +  @retval TRUE Random number generated successfully.
> > +  @retval FALSEFailed to generate the random number.
> > +
> > +**/
> > +BOOLEAN
> > +EFIAPI
> > +GetRandomNumber16 (
> > +  OUT UINT16*Rand
> > +  )
> > +{
> > +  ASSERT (FALSE);
> > +  return FALSE;
> > +}
> > +
> > +/**
> > +  Generates a 32-bit random number.
> > +
> > +  if Rand is NULL, then ASSERT().
> > +
> > +  @param[out] Rand Buffer pointer to store the 32-bit random value.
> > +
> > +  @retval TRUE Random number generated successfully.
> > +  @retval FALSEFailed to generate the random number.
> > +
> > +**/
> > +BOOLEAN
> > +EFIAPI
> > +GetRandomNumber32 (
> > +  OUT UINT32*Rand
> > +  )
> > +{
> > +  ASSERT (FALSE);
> > +  return FALSE;
> > +}
> > +
> > +/**
> > +  Generates a 64-bit random number.
> > +
> > +  if Rand is NULL, then ASSERT().
> > +
> > +  @param[out] Rand Buffer pointer to store the 64-bit random value.
> > +
> > +  @retval TRUE Random number generated successfully.
> > +  @retval FALSEFailed to generate the random number.
> > +
> > +**/
> > +BOOLEAN
> > +EFIAPI
> > +GetRandomNumber64 (
> > +  OUT UINT64*Rand
> > +  )
> > +{
> > +  ASSERT (FALSE);
> > +  return FALSE;
> > +}
> > +
> > +/**
> > +  Generates a 128-bit random number.
> > +
> > +  if Rand is NULL, then ASSERT().
> > +
> > +  @param[out] Rand Buffer pointer to store the 128-bit random value.
> > +
> > +  @retval TRUE Random number generated successfully.
> > +  @retval FALSEFailed to generate the random number.
> > +
> > +**/
> > +BOOLEAN
> > +EFIAPI
> > +GetRandomNumber128 (
> > +  OUT UINT64*Rand
> > +  )
> > +{
> > +  ASSERT (FALSE);
> > +  return FALSE;
> > +}
> > diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > new file mode 100644
> > index 00..f6494cdb82
> > --- /dev/null
> > +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > @@ -0,0 +1,31 @@
> > +## @file
> > +#  Null instance of RNG (Random Number Generator) Library.
> > +#
> > +#  Copyright (c) 2019, Intel Corporation. All rights reserved.
> > +#
> > +#  SPDX-License-Identifier: BSD-2-Clause-Patent
> > +#
> > +##
> > +
> > +[Defines]
> > +  INF_VERSION= 0x00010005
> > +  BASE_NAME  = RngLibNull
> > +  MODULE_UNI_FILE= RngLibNull.uni
> > +  FILE_GUID  

Re: [edk2-devel] [Patch] Readme.md: Update EDK II CI build branch name

2019-11-11 Thread Laszlo Ersek
On 11/12/19 02:44, Michael D Kinney wrote:
> https://bugzilla.tianocore.org/show_bug.cgi?id=2315
> 
> Update Readme.md to indicate that that status badges are for
> the edk2/master branch.
> 
> Cc: Sean Brogan 
> Cc: Bret Barkelew 
> Cc: Liming Gao 
> Cc: Andrew Fish 
> Cc: Laszlo Ersek 
> Cc: Leif Lindholm 
> Signed-off-by: Michael D Kinney 
> ---
>  Readme.md | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/Readme.md b/Readme.md
> index acbcca88d3..594f16b207 100644
> --- a/Readme.md
> +++ b/Readme.md
> @@ -17,7 +17,7 @@ for the UEFI and PI specifications from www.uefi.org.
>
>  Windows
>  VS2019
> -edk2-ci
> +master
>  
> href="https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=32=master;>
> src="https://dev.azure.com/tianocore/edk2-ci/_apis/build/status/Windows%20VS2019%20CI?branchName=master"/>
> @@ -34,7 +34,7 @@ for the UEFI and PI specifications from www.uefi.org.
>
>  Ubuntu
>  GCC
> -edk2-ci
> +master
>  
> href="https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=31=master;>
> src="https://dev.azure.com/tianocore/edk2-ci/_apis/build/status/Ubuntu%20GCC5%20CI?branchName=master"/>
> 

Acked-by: Laszlo Ersek 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50450): https://edk2.groups.io/g/devel/message/50450
Mute This Topic: https://groups.io/mt/53599349/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch] Readme.md: Update EDK II CI build status badge and links

2019-11-11 Thread Laszlo Ersek
On 11/12/19 00:20, Michael D Kinney wrote:
> https://bugzilla.tianocore.org/show_bug.cgi?id=2315
> 
> Update Readme.md with the status badges from the Azure
> Pipelines, tianocore organization, edk2-ci project
> 
> https://dev.azure.com/tianocore/edk2-ci/_build
> 
> * Windows VS2019 CI pipeline badges and results
> * Ubuntu GCC5 CI pipeline badges and results
> 
> Cc: Sean Brogan 
> Cc: Bret Barkelew 
> Cc: Liming Gao 
> Cc: Andrew Fish 
> Cc: Laszlo Ersek 
> Cc: Leif Lindholm 
> Signed-off-by: Michael D Kinney 
> ---
>  Readme.md | 18 +-
>  1 file changed, 9 insertions(+), 9 deletions(-)
> 
> diff --git a/Readme.md b/Readme.md
> index dcd86daef1..678428bdcf 100644
> --- a/Readme.md
> +++ b/Readme.md
> @@ -19,15 +19,15 @@ for the UEFI and PI specifications from www.uefi.org.
>  VS2019
>  edk2-ci
>  
> -   href="https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
> -   src="https://dev.azure.com/tianocore/edk2-ci-play/_apis/build/status/edk2-staging/Windows%20VS2019%20CI?branchName=edk2-ci"/>
> +   href="https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=32=master;>
> +   src="https://dev.azure.com/tianocore/edk2-ci/_apis/build/status/Windows%20VS2019%20CI?branchName=master"/>
>  
>  
> -   href="https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
> -   src="https://img.shields.io/azure-devops/tests/tianocore/edk2-ci-play/27.svg"/>
> +   href="https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=32=master;>
> +   src="https://img.shields.io/azure-devops/tests/tianocore/edk2-ci/32.svg"/>
>  
>  
> -   href="https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
> +   href="https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=32=master;>
>https://img.shields.io/badge/coverage-coming_soon-blue"/>
>  
>
> @@ -36,15 +36,15 @@ for the UEFI and PI specifications from www.uefi.org.
>  GCC
>  edk2-ci
>  
> -   href="https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
> +   href="https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=31=master;>
> src="https://dev.azure.com/tianocore/edk2-ci-play/_apis/build/status/edk2-staging/Ubuntu%20GCC5%20CI?branchName=edk2-ci"/>
>  
>  
> -   href="https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
> -   src="https://img.shields.io/azure-devops/tests/tianocore/edk2-ci-play/26.svg"/>
> +   href="https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=31=master;>
> +   src="https://img.shields.io/azure-devops/tests/tianocore/edk2-ci/31.svg"/>
>  
>  
> -   href="https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
> +   href="https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=31=master;>
>https://img.shields.io/badge/coverage-coming_soon-blue"/>
>  
>
> 

Acked-by: Laszlo Ersek 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50449): https://edk2.groups.io/g/devel/message/50449
Mute This Topic: https://groups.io/mt/53446318/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Laszlo Ersek
On 11/12/19 06:55, Jian J Wang wrote:
> This is null version of RngLib which is used for those platforms or
> components which don't need random number.
> 
> Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> Cc: Jiewen Yao 
> Cc: Chao Zhang 
> Cc: Michael D Kinney 
> Cc: Liming Gao 
> Cc: Laszlo Ersek 
> Cc: Ard Biesheuvel 
> Cc: Ray Ni 
> Signed-off-by: Jian J Wang 
> ---
>  .../RngLibNull/RngLibNull.c   | 95 +++
>  .../RngLibNull/RngLibNull.inf | 31 ++
>  .../RngLibNull/RngLibNull.uni | 14 +++
>  3 files changed, 140 insertions(+)
>  create mode 100644 SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
>  create mode 100644 
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
>  create mode 100644 
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni

(1) I don't see any reason why this library instance should not be added
under MdePkg/Library. The other library instance is already there (and
the lib class header too is from MdePkg):

  MdePkg/Library/BaseRngLib

(2) I think this library instance should be called "BaseRngLibNull", not
just "RngLibNull".

More below:

> diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c 
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> new file mode 100644
> index 00..13677abc84
> --- /dev/null
> +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> @@ -0,0 +1,95 @@
> +/** @file
> +  Null version of Random number generator services.
> +
> +Copyright (c) 2019, Intel Corporation. All rights reserved.
> +SPDX-License-Identifier: BSD-2-Clause-Patent
> +
> +**/
> +
> +#include 
> +#include 
> +#include 
> +
> +/**
> +  Generates a 16-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 16-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber16 (
> +  OUT UINT16*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 32-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 32-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber32 (
> +  OUT UINT32*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 64-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 64-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber64 (
> +  OUT UINT64*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 128-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 128-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber128 (
> +  OUT UINT64*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf 
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> new file mode 100644
> index 00..f6494cdb82
> --- /dev/null
> +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> @@ -0,0 +1,31 @@
> +## @file
> +#  Null instance of RNG (Random Number Generator) Library.
> +#
> +#  Copyright (c) 2019, Intel Corporation. All rights reserved.
> +#
> +#  SPDX-License-Identifier: BSD-2-Clause-Patent
> +#
> +##
> +
> +[Defines]
> +  INF_VERSION= 0x00010005
> +  BASE_NAME  = RngLibNull
> +  MODULE_UNI_FILE= RngLibNull.uni
> +  FILE_GUID  = CD8991F8-2061-4084-8C9E-9C6F352DC58D
> +  MODULE_TYPE= BASE
> +  VERSION_STRING = 1.0
> +  LIBRARY_CLASS  = RngLib
> +
> +#
> +#  VALID_ARCHITECTURES   = IA32 X64 ARM AARCH64
> +#
> +
> +[Sources]
> +  RngLibNull.c
> +
> +[Packages]
> +  MdePkg/MdePkg.dec
> +
> +[LibraryClasses]
> +  BaseLib
> +  DebugLib
> diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni 
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> new file mode 100644
> index 00..40b2ec3fe1
> --- /dev/null
> +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> @@ -0,0 +1,14 @@
> +// /** @file
> +// Null Instance of RNG (Random Number 

[edk2-devel] [PATCH] Maintainers.txt: add file filter to let GetMaintainer.py work properly

2019-11-11 Thread Wang, Jian J
Cc: Ard Biesheuvel 
Cc: Leif Lindholm 
Cc: Michael D Kinney 
Cc: Ray Ni 
Cc: Liming Gao 
Signed-off-by: Jian J Wang 
---
 Maintainers.txt | 46 +-
 1 file changed, 45 insertions(+), 1 deletion(-)

diff --git a/Maintainers.txt b/Maintainers.txt
index 9599024e20..a4c39000c6 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -11,7 +11,8 @@ Descriptions of section entries:
 
   L: Mailing list that is relevant to this area (default is edk2-devel)
  Patches and questions should be sent to the email list.
-  M: Cc address for patches and questions (ie, the package maintainer)
+  M: Package Maintainer: Cc address for patches and questions. Responsible
+ for reviewing and pushing package changes to source control.
   R: Package Reviewer: Cc address for patches and questions. Reviewers help
  maintainers review code, but don't have push access. A designated Package
  Reviewer is reasonably familiar with the Package (or some modules
@@ -29,6 +30,22 @@ Descriptions of section entries:
  Obsolete:   Old code. Something tagged obsolete generally means
  it has been replaced by a better system and you
  should be using that.
+  F: Files and directories with wildcard patterns.
+ A trailing slash includes all files and subdirectory files.
+ F:   MdeModulePkg/   all files in and below MdeModulePkg
+ F:   MdeModulePkg/*  all files in MdeModulePkg, but not below
+ F:   */Pci/* all files in a directory called Pci, at any depth in
+  the hierarchy, but not below
+ One pattern per line.  Multiple F: lines per section acceptable.
+  X: Files and directories that are NOT maintained, same rules as F:
+ Files exclusions are tested after file matches.
+ Can be useful for excluding a specific subdirectory, for instance:
+ F:   NetworkPkg/
+ X:   NetworkPkg/Ip6Dxe/
+ matches all files in and below NetworkPkg excluding NetworkPkg/Ip6Dxe/
+  Filenames not caught by any F: rule get matched as being located in the top-
+  level directory. (Internally, the script looks for a match called 
'',
+  so please don't add a file called that in the top-level directory.)
 
 EDK II
 --
@@ -44,115 +61,142 @@ EDK II Packages:
 
 
 Drivers/OptionRomPkg
+F: Drivers/OptionRomPkg/
 W: https://github.com/tianocore/tianocore.github.io/wiki/OptionRomPkg
 M: Ray Ni 
 
 Drivers/DisplayLink
+F: Drivers/DisplayLink/
 M: Leif Lindholm 
 M: Ard Bieshuevel 
 R: Andy Hayes 
 
 Platform
+F: Platform/
 M: Ard Biesheuvel 
 M: Leif Lindholm 
 M: Michael D Kinney 
 
 Platform/Intel/QuarkPlatformPkg
+F: Platform/Intel/QuarkPlatformPkg/
 M: Michael D Kinney 
 M: Kelly Steele 
 
 Platform/Intel/Vlv2TbltDevicePkg
+F: Platform/Intel/Vlv2TbltDevicePkg/
 M: Zailiang Sun 
 M: Yi Qian 
 
 Platform/Intel/AdvancedFeaturePkg
+F: Platform/Intel/AdvancedFeaturePkg/
 M: Michael Kubacki 
 M: Sai Chaganty 
 R: Liming Gao 
 
 Platform/Intel/BoardModulePkg
+F: Platform/Intel/BoardModulePkg/
 M: Eric Dong 
 R: Liming Gao 
 
 Platform/Intel/DebugFeaturePkg
+F: Platform/Intel/DebugFeaturePkg/
 M: Eric Dong 
 R: Liming Gao 
 
 Platform/Intel/UserInterfaceFeaturePkg
+F: Platform/Intel/UserInterfaceFeaturePkg/
 M: Dandan Bi 
 R: Liming Gao 
 
 Platform/Intel/KabylakeOpenBoardPkg
+F: Platform/Intel/KabylakeOpenBoardPkg/
 M: Chasel Chiu 
 M: Michael Kubacki 
 M: Nate DeSimone 
 
 Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3
+F: Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/
 R: Jeremy Soller 
 
 Platform/Intel/MinPlatformPkg
+F: Platform/Intel/MinPlatformPkg/
 M: Michael Kubacki 
 M: Chasel Chiu 
 M: Nate DeSimone 
 R: Liming Gao 
 
 Platform/Intel/WhiskeylakeOpenBoardPkg
+F: Platform/Intel/WhiskeylakeOpenBoardPkg/
 M: Chasel Chiu 
 M: Michael Kubacki 
 M: Nate DeSimone 
 
 Platform/Intel/SimicsOpenBoardPkg
+F: Platform/Intel/SimicsOpenBoardPkg/
 M: Wei David Y 
 M: Agyeman Prince 
 
 Platform/Intel/Tools
+F: Platform/Intel/Tools/
 M: Bob Feng 
 M: Liming Gao 
 
 Platform/Marvell
+F: Platform/Marvell/
 R: Marcin Wojtas 
 
 Platform/SolidRun/Armada80x0McBin
+F: Platform/SolidRun/Armada80x0McBin/
 R: Marcin Wojtas 
 
 Silicon
+F: Silicon/
 M: Ard Biesheuvel 
 M: Leif Lindholm 
 M: Michael D Kinney 
 
 Silicon/Intel/IntelSiliconPkg
+F: Silicon/Intel/IntelSiliconPkg/
 M: Ray Ni 
 M: Rangasai V Chaganty 
 
 Silicon/Intel/QuarkSocPkg
+F: Silicon/Intel/QuarkSocPkg/
 M: Michael D Kinney 
 M: Kelly Steele 
 
 Silicon/Intel/Vlv2DeviceRefCodePkg
+F: Silicon/Intel/Vlv2DeviceRefCodePkg/
 M: Zailiang Sun 
 M: Yi Qian 
 
 Silicon/Intel/CoffeelakeSiliconPkg
+F: Silicon/Intel/CoffeelakeSiliconPkg/
 M: Chasel Chiu 
 M: Michael Kubacki 
 M: Sai Chaganty 
 
 Silicon/Intel/KabylakeSiliconPkg
+F: Silicon/Intel/KabylakeSiliconPkg/
 M: Chasel Chiu 
 M: Michael Kubacki 
 M: Sai Chaganty 
 
 Silicon/Intel/SimicsX58SktPkg
+F: Silicon/Intel/SimicsX58SktPkg/
 M: Wei David Y 
 M: Agyeman Prince 
 
 Silicon/Intel/SimicsIch10Pkg
+F: 

Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Wang, Jian J
Yes, currently only those doing encryption/hash (like TLS, HddPassword) needs
random number explicitly. But sometimes it's hard to tell because random might
be needed deeply inside other operations. The ASSERT will help to find out that
situation.

Maybe I should use "link" instead of "use".

Regards,
Jian

> -Original Message-
> From: Ni, Ray 
> Sent: Tuesday, November 12, 2019 3:20 PM
> To: Wang, Jian J ; devel@edk2.groups.io
> Cc: Yao, Jiewen ; Zhang, Chao B
> ; Kinney, Michael D ;
> Gao, Liming ; Laszlo Ersek ; Ard
> Biesheuvel 
> Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> 
> Does a real platform that requires no random number exist?
> If it doesn't, I agree with this implementation but please adjust the commit
> message
> to say it's just for pass build.
> 
> If it does, I prefer to remove the "ASSERT".
> 
> Either way, I just feel the commit message may mislead platforms to use
> this instance but they will hit assertion.
> 
> Thanks,
> Ray
> 
> 
> > -Original Message-
> > From: Wang, Jian J 
> > Sent: Tuesday, November 12, 2019 3:16 PM
> > To: Ni, Ray ; devel@edk2.groups.io
> > Cc: Yao, Jiewen ; Zhang, Chao B
> > ; Kinney, Michael D
> > ; Gao, Liming ; Laszlo
> > Ersek ; Ard Biesheuvel 
> > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> >
> > Since OpensslLib will depend on RngLib, we should give an instance of it
> > anyway, even for those who don't need it. Otherwise the build will fail.
> > What's your suggestion for the message?
> >
> > Regards,
> > Jian
> >
> > > -Original Message-
> > > From: Ni, Ray 
> > > Sent: Tuesday, November 12, 2019 3:05 PM
> > > To: Wang, Jian J ; devel@edk2.groups.io
> > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > ; Kinney, Michael D
> > > ; Gao, Liming ;
> > > Laszlo Ersek ; Ard Biesheuvel
> > > 
> > > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of
> > > RngLib
> > >
> > > Jian,
> > > But the commit message is:
> > > "This is null version of RngLib which is used for those platforms or
> > > components which don't need random number."
> > >
> > > Thanks,
> > > Ray
> > >
> > > > -Original Message-
> > > > From: Wang, Jian J 
> > > > Sent: Tuesday, November 12, 2019 2:58 PM
> > > > To: Ni, Ray ; devel@edk2.groups.io
> > > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > > ; Kinney, Michael D
> > > > ; Gao, Liming ;
> > > > Laszlo Ersek ; Ard Biesheuvel
> > > > 
> > > > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of
> > > > RngLib
> > > >
> > > > Ray,
> > > >
> > > > It's for build only but not supposed to be *used* in a platform. If
> > > > a platform really wants a RngLib, the owners need to change the
> > > > instance to a proper one. ASSERT will tell them that. Otherwise, the
> > > > RngLib interface should not be called.
> > > >
> > > > Regards,
> > > > Jian
> > > >
> > > > > -Original Message-
> > > > > From: Ni, Ray 
> > > > > Sent: Tuesday, November 12, 2019 2:30 PM
> > > > > To: Wang, Jian J ; devel@edk2.groups.io
> > > > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > > > ; Kinney, Michael D
> > > > > ; Gao, Liming ;
> > > > > Laszlo Ersek ; Ard Biesheuvel
> > > > > 
> > > > > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of
> > > > > RngLib
> > > > >
> > > > > Jian,
> > > > > If we expect platform to use this library, probably
> > > > > "ASSERT(FALSE)" is not
> > > > proper.
> > > > >
> > > > > > -Original Message-
> > > > > > From: Wang, Jian J 
> > > > > > Sent: Tuesday, November 12, 2019 1:56 PM
> > > > > > To: devel@edk2.groups.io
> > > > > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > > > > ; Kinney, Michael D
> > > > > > ; Gao, Liming
> > > > > > ; Laszlo Ersek ; Ard
> > > > > > Biesheuvel ; Ni, Ray
> > > > > > 
> > > > > > Subject: [PATCH] SecurityPkg/RngLibNull: add null version of
> > > > > > RngLib
> > > > > >
> > > > > > This is null version of RngLib which is used for those platforms
> > > > > > or components which don't need random number.
> > > > > >
> > > > > > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> > > > > > Cc: Jiewen Yao 
> > > > > > Cc: Chao Zhang 
> > > > > > Cc: Michael D Kinney 
> > > > > > Cc: Liming Gao 
> > > > > > Cc: Laszlo Ersek 
> > > > > > Cc: Ard Biesheuvel 
> > > > > > Cc: Ray Ni 
> > > > > > Signed-off-by: Jian J Wang 
> > > > > > ---
> > > > > >  .../RngLibNull/RngLibNull.c   | 95 
> > > > > > +++
> > > > > >  .../RngLibNull/RngLibNull.inf | 31 ++
> > > > > >  .../RngLibNull/RngLibNull.uni | 14 +++
> > > > > >  3 files changed, 140 insertions(+)  create mode 100644
> > > > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > > > >  create mode 100644
> > > > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > > > > >  create mode 100644
> > > > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> > > > > >
> > > > > > diff --git
> > > > > > 

Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Ni, Ray
Does a real platform that requires no random number exist?
If it doesn't, I agree with this implementation but please adjust the commit 
message
to say it's just for pass build.

If it does, I prefer to remove the "ASSERT".

Either way, I just feel the commit message may mislead platforms to use
this instance but they will hit assertion.

Thanks,
Ray


> -Original Message-
> From: Wang, Jian J 
> Sent: Tuesday, November 12, 2019 3:16 PM
> To: Ni, Ray ; devel@edk2.groups.io
> Cc: Yao, Jiewen ; Zhang, Chao B
> ; Kinney, Michael D
> ; Gao, Liming ; Laszlo
> Ersek ; Ard Biesheuvel 
> Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> 
> Since OpensslLib will depend on RngLib, we should give an instance of it
> anyway, even for those who don't need it. Otherwise the build will fail.
> What's your suggestion for the message?
> 
> Regards,
> Jian
> 
> > -Original Message-
> > From: Ni, Ray 
> > Sent: Tuesday, November 12, 2019 3:05 PM
> > To: Wang, Jian J ; devel@edk2.groups.io
> > Cc: Yao, Jiewen ; Zhang, Chao B
> > ; Kinney, Michael D
> > ; Gao, Liming ;
> > Laszlo Ersek ; Ard Biesheuvel
> > 
> > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of
> > RngLib
> >
> > Jian,
> > But the commit message is:
> > "This is null version of RngLib which is used for those platforms or
> > components which don't need random number."
> >
> > Thanks,
> > Ray
> >
> > > -Original Message-
> > > From: Wang, Jian J 
> > > Sent: Tuesday, November 12, 2019 2:58 PM
> > > To: Ni, Ray ; devel@edk2.groups.io
> > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > ; Kinney, Michael D
> > > ; Gao, Liming ;
> > > Laszlo Ersek ; Ard Biesheuvel
> > > 
> > > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of
> > > RngLib
> > >
> > > Ray,
> > >
> > > It's for build only but not supposed to be *used* in a platform. If
> > > a platform really wants a RngLib, the owners need to change the
> > > instance to a proper one. ASSERT will tell them that. Otherwise, the
> > > RngLib interface should not be called.
> > >
> > > Regards,
> > > Jian
> > >
> > > > -Original Message-
> > > > From: Ni, Ray 
> > > > Sent: Tuesday, November 12, 2019 2:30 PM
> > > > To: Wang, Jian J ; devel@edk2.groups.io
> > > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > > ; Kinney, Michael D
> > > > ; Gao, Liming ;
> > > > Laszlo Ersek ; Ard Biesheuvel
> > > > 
> > > > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of
> > > > RngLib
> > > >
> > > > Jian,
> > > > If we expect platform to use this library, probably
> > > > "ASSERT(FALSE)" is not
> > > proper.
> > > >
> > > > > -Original Message-
> > > > > From: Wang, Jian J 
> > > > > Sent: Tuesday, November 12, 2019 1:56 PM
> > > > > To: devel@edk2.groups.io
> > > > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > > > ; Kinney, Michael D
> > > > > ; Gao, Liming
> > > > > ; Laszlo Ersek ; Ard
> > > > > Biesheuvel ; Ni, Ray
> > > > > 
> > > > > Subject: [PATCH] SecurityPkg/RngLibNull: add null version of
> > > > > RngLib
> > > > >
> > > > > This is null version of RngLib which is used for those platforms
> > > > > or components which don't need random number.
> > > > >
> > > > > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> > > > > Cc: Jiewen Yao 
> > > > > Cc: Chao Zhang 
> > > > > Cc: Michael D Kinney 
> > > > > Cc: Liming Gao 
> > > > > Cc: Laszlo Ersek 
> > > > > Cc: Ard Biesheuvel 
> > > > > Cc: Ray Ni 
> > > > > Signed-off-by: Jian J Wang 
> > > > > ---
> > > > >  .../RngLibNull/RngLibNull.c   | 95 
> > > > > +++
> > > > >  .../RngLibNull/RngLibNull.inf | 31 ++
> > > > >  .../RngLibNull/RngLibNull.uni | 14 +++
> > > > >  3 files changed, 140 insertions(+)  create mode 100644
> > > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > > >  create mode 100644
> > > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > > > >  create mode 100644
> > > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> > > > >
> > > > > diff --git
> > > > > a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > > > b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > > > new file mode 100644
> > > > > index 00..13677abc84
> > > > > --- /dev/null
> > > > > +++
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > > > @@ -0,0 +1,95 @@
> > > > > +/** @file
> > > > > +  Null version of Random number generator services.
> > > > > +
> > > > > +Copyright (c) 2019, Intel Corporation. All rights reserved.
> > > > > +SPDX-License-Identifier: BSD-2-Clause-Patent
> > > > > +
> > > > > +**/
> > > > > +
> > > > > +#include 
> > > > > +#include 
> > > > > +#include 
> > > > > +
> > > > > +/**
> > > > > +  Generates a 16-bit random number.
> > > > > +
> > > > > +  if Rand is NULL, then ASSERT().
> > > > > +
> > > > > +  @param[out] Rand Buffer pointer to store the 16-bit random
> value.
> > > > > +
> > > > > +  

Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Wang, Jian J
Since OpensslLib will depend on RngLib, we should give an instance of it anyway,
even for those who don't need it. Otherwise the build will fail. What's your
suggestion for the message?

Regards,
Jian

> -Original Message-
> From: Ni, Ray 
> Sent: Tuesday, November 12, 2019 3:05 PM
> To: Wang, Jian J ; devel@edk2.groups.io
> Cc: Yao, Jiewen ; Zhang, Chao B
> ; Kinney, Michael D ;
> Gao, Liming ; Laszlo Ersek ; Ard
> Biesheuvel 
> Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> 
> Jian,
> But the commit message is:
> "This is null version of RngLib which is used for those platforms
> or components which don't need random number."
> 
> Thanks,
> Ray
> 
> > -Original Message-
> > From: Wang, Jian J 
> > Sent: Tuesday, November 12, 2019 2:58 PM
> > To: Ni, Ray ; devel@edk2.groups.io
> > Cc: Yao, Jiewen ; Zhang, Chao B
> > ; Kinney, Michael D
> > ; Gao, Liming ; Laszlo
> > Ersek ; Ard Biesheuvel 
> > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> >
> > Ray,
> >
> > It's for build only but not supposed to be *used* in a platform. If a 
> > platform
> > really wants a RngLib, the owners need to change the instance to a proper
> > one. ASSERT will tell them that. Otherwise, the RngLib interface should not
> > be called.
> >
> > Regards,
> > Jian
> >
> > > -Original Message-
> > > From: Ni, Ray 
> > > Sent: Tuesday, November 12, 2019 2:30 PM
> > > To: Wang, Jian J ; devel@edk2.groups.io
> > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > ; Kinney, Michael D
> > > ; Gao, Liming ;
> > > Laszlo Ersek ; Ard Biesheuvel
> > > 
> > > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of
> > > RngLib
> > >
> > > Jian,
> > > If we expect platform to use this library, probably "ASSERT(FALSE)" is not
> > proper.
> > >
> > > > -Original Message-
> > > > From: Wang, Jian J 
> > > > Sent: Tuesday, November 12, 2019 1:56 PM
> > > > To: devel@edk2.groups.io
> > > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > > ; Kinney, Michael D
> > > > ; Gao, Liming ;
> > > > Laszlo Ersek ; Ard Biesheuvel
> > > > ; Ni, Ray 
> > > > Subject: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> > > >
> > > > This is null version of RngLib which is used for those platforms or
> > > > components which don't need random number.
> > > >
> > > > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> > > > Cc: Jiewen Yao 
> > > > Cc: Chao Zhang 
> > > > Cc: Michael D Kinney 
> > > > Cc: Liming Gao 
> > > > Cc: Laszlo Ersek 
> > > > Cc: Ard Biesheuvel 
> > > > Cc: Ray Ni 
> > > > Signed-off-by: Jian J Wang 
> > > > ---
> > > >  .../RngLibNull/RngLibNull.c   | 95 +++
> > > >  .../RngLibNull/RngLibNull.inf | 31 ++
> > > >  .../RngLibNull/RngLibNull.uni | 14 +++
> > > >  3 files changed, 140 insertions(+)
> > > >  create mode 100644
> > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > >  create mode 100644
> > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > > >  create mode 100644
> > > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> > > >
> > > > diff --git
> > > > a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > > b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > > new file mode 100644
> > > > index 00..13677abc84
> > > > --- /dev/null
> > > > +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > > @@ -0,0 +1,95 @@
> > > > +/** @file
> > > > +  Null version of Random number generator services.
> > > > +
> > > > +Copyright (c) 2019, Intel Corporation. All rights reserved.
> > > > +SPDX-License-Identifier: BSD-2-Clause-Patent
> > > > +
> > > > +**/
> > > > +
> > > > +#include 
> > > > +#include 
> > > > +#include 
> > > > +
> > > > +/**
> > > > +  Generates a 16-bit random number.
> > > > +
> > > > +  if Rand is NULL, then ASSERT().
> > > > +
> > > > +  @param[out] Rand Buffer pointer to store the 16-bit random value.
> > > > +
> > > > +  @retval TRUE Random number generated successfully.
> > > > +  @retval FALSEFailed to generate the random number.
> > > > +
> > > > +**/
> > > > +BOOLEAN
> > > > +EFIAPI
> > > > +GetRandomNumber16 (
> > > > +  OUT UINT16*Rand
> > > > +  )
> > > > +{
> > > > +  ASSERT (FALSE);
> > > > +  return FALSE;
> > > > +}
> > > > +
> > > > +/**
> > > > +  Generates a 32-bit random number.
> > > > +
> > > > +  if Rand is NULL, then ASSERT().
> > > > +
> > > > +  @param[out] Rand Buffer pointer to store the 32-bit random value.
> > > > +
> > > > +  @retval TRUE Random number generated successfully.
> > > > +  @retval FALSEFailed to generate the random number.
> > > > +
> > > > +**/
> > > > +BOOLEAN
> > > > +EFIAPI
> > > > +GetRandomNumber32 (
> > > > +  OUT UINT32*Rand
> > > > +  )
> > > > +{
> > > > +  ASSERT (FALSE);
> > > > +  return FALSE;
> > > > +}
> > > > +
> > > > +/**
> > 

Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Ni, Ray
Jian,
But the commit message is:
"This is null version of RngLib which is used for those platforms
or components which don't need random number."

Thanks,
Ray

> -Original Message-
> From: Wang, Jian J 
> Sent: Tuesday, November 12, 2019 2:58 PM
> To: Ni, Ray ; devel@edk2.groups.io
> Cc: Yao, Jiewen ; Zhang, Chao B
> ; Kinney, Michael D
> ; Gao, Liming ; Laszlo
> Ersek ; Ard Biesheuvel 
> Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> 
> Ray,
> 
> It's for build only but not supposed to be *used* in a platform. If a platform
> really wants a RngLib, the owners need to change the instance to a proper
> one. ASSERT will tell them that. Otherwise, the RngLib interface should not
> be called.
> 
> Regards,
> Jian
> 
> > -Original Message-
> > From: Ni, Ray 
> > Sent: Tuesday, November 12, 2019 2:30 PM
> > To: Wang, Jian J ; devel@edk2.groups.io
> > Cc: Yao, Jiewen ; Zhang, Chao B
> > ; Kinney, Michael D
> > ; Gao, Liming ;
> > Laszlo Ersek ; Ard Biesheuvel
> > 
> > Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of
> > RngLib
> >
> > Jian,
> > If we expect platform to use this library, probably "ASSERT(FALSE)" is not
> proper.
> >
> > > -Original Message-
> > > From: Wang, Jian J 
> > > Sent: Tuesday, November 12, 2019 1:56 PM
> > > To: devel@edk2.groups.io
> > > Cc: Yao, Jiewen ; Zhang, Chao B
> > > ; Kinney, Michael D
> > > ; Gao, Liming ;
> > > Laszlo Ersek ; Ard Biesheuvel
> > > ; Ni, Ray 
> > > Subject: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> > >
> > > This is null version of RngLib which is used for those platforms or
> > > components which don't need random number.
> > >
> > > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> > > Cc: Jiewen Yao 
> > > Cc: Chao Zhang 
> > > Cc: Michael D Kinney 
> > > Cc: Liming Gao 
> > > Cc: Laszlo Ersek 
> > > Cc: Ard Biesheuvel 
> > > Cc: Ray Ni 
> > > Signed-off-by: Jian J Wang 
> > > ---
> > >  .../RngLibNull/RngLibNull.c   | 95 +++
> > >  .../RngLibNull/RngLibNull.inf | 31 ++
> > >  .../RngLibNull/RngLibNull.uni | 14 +++
> > >  3 files changed, 140 insertions(+)
> > >  create mode 100644
> > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > >  create mode 100644
> > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > >  create mode 100644
> > > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> > >
> > > diff --git
> > > a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > new file mode 100644
> > > index 00..13677abc84
> > > --- /dev/null
> > > +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > > @@ -0,0 +1,95 @@
> > > +/** @file
> > > +  Null version of Random number generator services.
> > > +
> > > +Copyright (c) 2019, Intel Corporation. All rights reserved.
> > > +SPDX-License-Identifier: BSD-2-Clause-Patent
> > > +
> > > +**/
> > > +
> > > +#include 
> > > +#include 
> > > +#include 
> > > +
> > > +/**
> > > +  Generates a 16-bit random number.
> > > +
> > > +  if Rand is NULL, then ASSERT().
> > > +
> > > +  @param[out] Rand Buffer pointer to store the 16-bit random value.
> > > +
> > > +  @retval TRUE Random number generated successfully.
> > > +  @retval FALSEFailed to generate the random number.
> > > +
> > > +**/
> > > +BOOLEAN
> > > +EFIAPI
> > > +GetRandomNumber16 (
> > > +  OUT UINT16*Rand
> > > +  )
> > > +{
> > > +  ASSERT (FALSE);
> > > +  return FALSE;
> > > +}
> > > +
> > > +/**
> > > +  Generates a 32-bit random number.
> > > +
> > > +  if Rand is NULL, then ASSERT().
> > > +
> > > +  @param[out] Rand Buffer pointer to store the 32-bit random value.
> > > +
> > > +  @retval TRUE Random number generated successfully.
> > > +  @retval FALSEFailed to generate the random number.
> > > +
> > > +**/
> > > +BOOLEAN
> > > +EFIAPI
> > > +GetRandomNumber32 (
> > > +  OUT UINT32*Rand
> > > +  )
> > > +{
> > > +  ASSERT (FALSE);
> > > +  return FALSE;
> > > +}
> > > +
> > > +/**
> > > +  Generates a 64-bit random number.
> > > +
> > > +  if Rand is NULL, then ASSERT().
> > > +
> > > +  @param[out] Rand Buffer pointer to store the 64-bit random value.
> > > +
> > > +  @retval TRUE Random number generated successfully.
> > > +  @retval FALSEFailed to generate the random number.
> > > +
> > > +**/
> > > +BOOLEAN
> > > +EFIAPI
> > > +GetRandomNumber64 (
> > > +  OUT UINT64*Rand
> > > +  )
> > > +{
> > > +  ASSERT (FALSE);
> > > +  return FALSE;
> > > +}
> > > +
> > > +/**
> > > +  Generates a 128-bit random number.
> > > +
> > > +  if Rand is NULL, then ASSERT().
> > > +
> > > +  @param[out] Rand Buffer pointer to store the 128-bit random value.
> > > +
> > > +  @retval TRUE Random number generated successfully.
> > > 

Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Wang, Jian J
Ray,

It's for build only but not supposed to be *used* in a platform. If a platform 
really
wants a RngLib, the owners need to change the instance to a proper one. ASSERT
will tell them that. Otherwise, the RngLib interface should not be called.

Regards,
Jian

> -Original Message-
> From: Ni, Ray 
> Sent: Tuesday, November 12, 2019 2:30 PM
> To: Wang, Jian J ; devel@edk2.groups.io
> Cc: Yao, Jiewen ; Zhang, Chao B
> ; Kinney, Michael D ;
> Gao, Liming ; Laszlo Ersek ; Ard
> Biesheuvel 
> Subject: RE: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> 
> Jian,
> If we expect platform to use this library, probably "ASSERT(FALSE)" is not 
> proper.
> 
> > -Original Message-
> > From: Wang, Jian J 
> > Sent: Tuesday, November 12, 2019 1:56 PM
> > To: devel@edk2.groups.io
> > Cc: Yao, Jiewen ; Zhang, Chao B
> > ; Kinney, Michael D
> > ; Gao, Liming ; Laszlo
> > Ersek ; Ard Biesheuvel ;
> > Ni, Ray 
> > Subject: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> >
> > This is null version of RngLib which is used for those platforms or 
> > components
> > which don't need random number.
> >
> > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> > Cc: Jiewen Yao 
> > Cc: Chao Zhang 
> > Cc: Michael D Kinney 
> > Cc: Liming Gao 
> > Cc: Laszlo Ersek 
> > Cc: Ard Biesheuvel 
> > Cc: Ray Ni 
> > Signed-off-by: Jian J Wang 
> > ---
> >  .../RngLibNull/RngLibNull.c   | 95 +++
> >  .../RngLibNull/RngLibNull.inf | 31 ++
> >  .../RngLibNull/RngLibNull.uni | 14 +++
> >  3 files changed, 140 insertions(+)
> >  create mode 100644
> > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> >  create mode 100644
> > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> >  create mode 100644
> > SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> >
> > diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > new file mode 100644
> > index 00..13677abc84
> > --- /dev/null
> > +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> > @@ -0,0 +1,95 @@
> > +/** @file
> > +  Null version of Random number generator services.
> > +
> > +Copyright (c) 2019, Intel Corporation. All rights reserved.
> > +SPDX-License-Identifier: BSD-2-Clause-Patent
> > +
> > +**/
> > +
> > +#include 
> > +#include 
> > +#include 
> > +
> > +/**
> > +  Generates a 16-bit random number.
> > +
> > +  if Rand is NULL, then ASSERT().
> > +
> > +  @param[out] Rand Buffer pointer to store the 16-bit random value.
> > +
> > +  @retval TRUE Random number generated successfully.
> > +  @retval FALSEFailed to generate the random number.
> > +
> > +**/
> > +BOOLEAN
> > +EFIAPI
> > +GetRandomNumber16 (
> > +  OUT UINT16*Rand
> > +  )
> > +{
> > +  ASSERT (FALSE);
> > +  return FALSE;
> > +}
> > +
> > +/**
> > +  Generates a 32-bit random number.
> > +
> > +  if Rand is NULL, then ASSERT().
> > +
> > +  @param[out] Rand Buffer pointer to store the 32-bit random value.
> > +
> > +  @retval TRUE Random number generated successfully.
> > +  @retval FALSEFailed to generate the random number.
> > +
> > +**/
> > +BOOLEAN
> > +EFIAPI
> > +GetRandomNumber32 (
> > +  OUT UINT32*Rand
> > +  )
> > +{
> > +  ASSERT (FALSE);
> > +  return FALSE;
> > +}
> > +
> > +/**
> > +  Generates a 64-bit random number.
> > +
> > +  if Rand is NULL, then ASSERT().
> > +
> > +  @param[out] Rand Buffer pointer to store the 64-bit random value.
> > +
> > +  @retval TRUE Random number generated successfully.
> > +  @retval FALSEFailed to generate the random number.
> > +
> > +**/
> > +BOOLEAN
> > +EFIAPI
> > +GetRandomNumber64 (
> > +  OUT UINT64*Rand
> > +  )
> > +{
> > +  ASSERT (FALSE);
> > +  return FALSE;
> > +}
> > +
> > +/**
> > +  Generates a 128-bit random number.
> > +
> > +  if Rand is NULL, then ASSERT().
> > +
> > +  @param[out] Rand Buffer pointer to store the 128-bit random value.
> > +
> > +  @retval TRUE Random number generated successfully.
> > +  @retval FALSEFailed to generate the random number.
> > +
> > +**/
> > +BOOLEAN
> > +EFIAPI
> > +GetRandomNumber128 (
> > +  OUT UINT64*Rand
> > +  )
> > +{
> > +  ASSERT (FALSE);
> > +  return FALSE;
> > +}
> > diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > new file mode 100644
> > index 00..f6494cdb82
> > --- /dev/null
> > +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> > @@ -0,0 +1,31 @@
> > +## @file
> > +#  Null instance of RNG (Random Number Generator) Library.
> > +#
> > +#  Copyright (c) 2019, Intel Corporation. All rights reserved. # #
> > +SPDX-License-Identifier: BSD-2-Clause-Patent # ##
> > +
> > 

Re: [edk2-devel] [PATCH] BaseTools: Fix build failure when using python38

2019-11-11 Thread Bob Feng
This patch looks good.

Reviewed-by: Bob C Feng 

-Original Message-
From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Ni, Ray
Sent: Tuesday, November 12, 2019 2:18 PM
To: devel@edk2.groups.io
Cc: Feng, Bob C ; Gao, Liming 
Subject: [edk2-devel] [PATCH] BaseTools: Fix build failure when using python38

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2304

Signed-off-by: Ray Ni 
Cc: Bob C Feng 
Cc: Liming Gao 
---
 BaseTools/Source/Python/build/build.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/BaseTools/Source/Python/build/build.py 
b/BaseTools/Source/Python/build/build.py
index bcd832c525..6c8798ef93 100755
--- a/BaseTools/Source/Python/build/build.py
+++ b/BaseTools/Source/Python/build/build.py
@@ -2064,7 +2064,7 @@ class Build():
 if Fdf.CurrentFdName and Fdf.CurrentFdName in Fdf.Profile.FdDict:
 FdDict = Fdf.Profile.FdDict[Fdf.CurrentFdName]
 for FdRegion in FdDict.RegionList:
-if str(FdRegion.RegionType) is 'FILE' and 
self.Platform.VpdToolGuid in str(FdRegion.RegionDataList):
+if str(FdRegion.RegionType) == 'FILE' and 
self.Platform.VpdToolGuid in str(FdRegion.RegionDataList):
 if int(FdRegion.Offset) % 8 != 0:
 EdkLogger.error("build", FORMAT_INVALID, 'The VPD 
Base Address %s must be 8-byte aligned.' % (FdRegion.Offset))
 Wa.FdfProfile = Fdf.Profile
-- 
2.21.0.windows.1





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50441): https://edk2.groups.io/g/devel/message/50441
Mute This Topic: https://groups.io/mt/54042169/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Ni, Ray
Mike,
I did a simple research in the web and found the slides: 
https://llvm.org/devmtg/2016-11/Slides/Kleckner-CodeViewInLLVM.pdf

In page #3, it says:
"CodeView is stored inside object files and PDBs"
"PDB is a container format written by linker and read by debugger"

The relationships between terms are:
"CodeView :: DWARF"
"PDB :: dSYM"
"PDB :: DWP"


I also found information from "https://llvm.org/docs/PDB/index.html":
"CodeView is another format which comes into the picture. While MSF
defines the structure of the overall file, and PDB defines the set of streams
that appear within the MSF file and the format of those streams, CodeView
defines the format of symbol and type records that appear within specific
streams."

With all these information, I am ok with any of CLANGCODEVIEW, CLANGCV or 
CLANGPDB.

Developers who care about symbolic debugging should be aware of what kind of
debug symbol is generated by build.

Thanks,
Ray

> -Original Message-
> From: Kinney, Michael D 
> Sent: Tuesday, November 12, 2019 11:48 AM
> To: devel@edk2.groups.io; Ni, Ray ; Gao, Liming
> ; af...@apple.com; Leif Lindholm
> ; Kinney, Michael D 
> Cc: Justen, Jordan L ; Shi, Steven
> 
> Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
> chain
> 
> Ray,
> 
> I agree that a name that represents the symbolic debug format makes more
> sense.
> 
> The term 'PE' is short for PE/COFF, and that is the required final output
> format.  A toolchain profile that happens to go through other intermediate
> formats (e.g.
> elf or macho) before finally generating a PE/COFF image is usually not that
> interesting to most developers.  So adding 'PE' to the name is redundant
> information.
> 
> The attribute of the images that does impact developers is the format of the
> symbol information.  Even for Visual Studio, PDB is the file extension used
> when the symbol information is placed in a separate file.  The Visual Studio
> compilers do support putting the symbol information in a section of the
> PE/COFF image.  EDK II builds happen to always use the PDB option to
> minimize the size of firmware images. So PDB may not be the right name
> either.  I think the symbol format in the PDB that is used is codeview.
> 
> If we want to plan ahead for toolchain names perhaps:
> 
> Codeview: CLANGCODEVIEW or CLANGCV or CLANGPDB
> Dwarf:CLANGDWARF
> 
> Best regards,
> 
> Mike
> 
> > -Original Message-
> > From: devel@edk2.groups.io  On Behalf Of Ni,
> Ray
> > Sent: Monday, November 11, 2019 7:23 PM
> > To: devel@edk2.groups.io; Ni, Ray ; Gao, Liming
> > ; af...@apple.com; Leif Lindholm
> > 
> > Cc: Justen, Jordan L ; Shi, Steven
> > 
> > Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg:
> > Enable CLANG9 tool chain
> >
> > And LLVM I believe is capable to support generating PE + DWARF.
> > That's my second concern: Using CLANGPE may not imply PDB is used from
> > a LLVM expert's understanding.
> >
> >
> > > -Original Message-
> > > From: devel@edk2.groups.io  On
> > Behalf Of Ni, Ray
> > > Sent: Tuesday, November 12, 2019 11:10 AM
> > > To: devel@edk2.groups.io; Ni, Ray ;
> > Gao, Liming
> > > ; af...@apple.com; Leif Lindholm
> > > 
> > > Cc: Justen, Jordan L ; Shi,
> > Steven
> > > 
> > > Subject: Re: [edk2-devel] [Patch v3 10/11]
> > EmulatorPkg: Enable CLANG9
> > > tool chain
> > >
> > > My point is if we choose CLANGPE, for LLVM toolchain
> > supporting DWARF
> > > debug symbol, there is no proper name left: we cannot
> > use CLANGELF.
> > >
> > > Andrew, you said CLANGPDE. A typo?
> > >
> > > > -Original Message-
> > > > From: devel@edk2.groups.io  On
> > Behalf Of Ni,
> > > Ray
> > > > Sent: Tuesday, November 12, 2019 9:46 AM
> > > > To: Gao, Liming ;
> > devel@edk2.groups.io;
> > > > af...@apple.com; Leif Lindholm
> > 
> > > > Cc: Justen, Jordan L ;
> > Shi, Steven
> > > > 
> > > > Subject: Re: [edk2-devel] [Patch v3 10/11]
> > EmulatorPkg: Enable
> > > > CLANG9 tool chain
> > > >
> > > > Liming,
> > > > What name will be chosen when in future someone
> > wants a LLVM
> > > toolchain
> > > > which supports DWARF debug symbol?
> > > >
> > > >
> > > > > -Original Message-
> > > > > From: Gao, Liming 
> > > > > Sent: Tuesday, November 12, 2019 8:41 AM
> > > > > To: devel@edk2.groups.io; af...@apple.com; Leif
> > Lindholm
> > > > > 
> > > > > Cc: Ni, Ray ; Justen, Jordan L
> > > > > ; Shi, Steven
> > ;
> > > > > Gao, Liming 
> > > > > Subject: RE: [edk2-devel] [Patch v3 10/11]
> > EmulatorPkg: Enable
> > > > > CLANG9 tool chain
> > > > >
> > > > > Thanks for your feedback. I will choose CLANGPE as
> > the tool chain name.
> > > > >
> > > > > Thanks
> > > > > Liming
> > > > > >-Original Message-
> > > > > >From: devel@edk2.groups.io
> > [mailto:devel@edk2.groups.io] On
> > > > > >Behalf Of Andrew Fish via Groups.Io
> > > > > >Sent: Tuesday, November 12, 2019 12:52 AM
> > > > > >To: Leif Lindholm 
> > > > > >Cc: Ni, Ray ; Gao, Liming
> > > > > >; devel@edk2.groups.io;

Re: [edk2-devel] [PATCH V4 8/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 Update "Intel persistent memory"

2019-11-11 Thread Ni, Ray
Reviewed-by: Ray Ni 

> -Original Message-
> From: Gao, Zhichao 
> Sent: Tuesday, November 12, 2019 11:49 AM
> To: devel@edk2.groups.io
> Cc: Ni, Ray ; Chaganty, Rangasai V
> 
> Subject: [PATCH V4 8/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 Update "Intel
> persistent memory"
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305
> 
> Memory Device (Type 17):
> - SMBIOSCR00179: update the string for Intel persistent memory
> 
> Cc: Ray Ni 
> Cc: Sai Chaganty 
> Signed-off-by: Zhichao Gao 
> ---
>  ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
> | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> index 16b75f2667..b80e16d56a 100644
> ---
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> +++
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> @@ -2638,8 +2638,8 @@ TABLE_ITEM
> MemoryDeviceMemoryTechnologyTable[] = {
>  L" NVDIMM-P"
>},
>{
> -0x07,
> -L" Intel persistent memory"
> +MemoryTechnologyIntelPersistentMemory,
> +L" Intel Optane DC Persistent Memory"
>}
>  };
> 
> --
> 2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50438): https://edk2.groups.io/g/devel/message/50438
Mute This Topic: https://groups.io/mt/53817164/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH V4 5/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 add PCI gen4 values for type 9

2019-11-11 Thread Ni, Ray
Reviewed-by: Ray Ni 

> -Original Message-
> From: Gao, Zhichao 
> Sent: Tuesday, November 12, 2019 11:49 AM
> To: devel@edk2.groups.io
> Cc: Ni, Ray ; Chaganty, Rangasai V
> 
> Subject: [PATCH V4 5/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 add PCI gen4
> values for type 9
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305
> 
> System Slots (Type 9):
> - SMBIOSCR00184: add PCI Express Gen 4 values
> 
> Add the Smbios.h to use the MARCOs or enums.
> 
> Cc: Ray Ni 
> Cc: Sai Chaganty 
> Signed-off-by: Zhichao Gao 
> ---
>  .../SmbiosView/QueryTable.c| 26 
> +-
>  .../SmbiosView/QueryTable.h|  4 +++-
>  2 files changed, 28 insertions(+), 2 deletions(-)
> 
> diff --git
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> index fdb7a47d33..94d995bda1 100644
> ---
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> +++
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> @@ -2,7 +2,7 @@
>Build a table, each item is (Key, Info) pair.
>And give a interface of query a string out of a table.
> 
> -  Copyright (c) 2005 - 2018, Intel Corporation. All rights reserved.
> +  Copyright (c) 2005 - 2019, Intel Corporation. All rights reserved.
>(C) Copyright 2016-2019 Hewlett Packard Enterprise Development LP
>SPDX-License-Identifier: BSD-2-Clause-Patent
> 
> @@ -1523,6 +1523,30 @@ TABLE_ITEM  SystemSlotTypeTable[] = {
>{
>  0xB6,
>  L"PCI Express Gen 3 X16"
> +  },
> +  {
> +SlotTypePciExpressGen4,
> +L"PCI Express Gen 4"
> +  },
> +  {
> +SlotTypePciExpressGen4X1,
> +L"PCI Express Gen 4 X1"
> +  },
> +  {
> +SlotTypePciExpressGen4X2,
> +L"PCI Express Gen 4 X2"
> +  },
> +  {
> +SlotTypePciExpressGen4X4,
> +L"PCI Express Gen 4 X4"
> +  },
> +  {
> +SlotTypePciExpressGen4X8,
> +L"PCI Express Gen 4 X8"
> +  },
> +  {
> +SlotTypePciExpressGen4X16,
> +L"PCI Express Gen 4 X16"
>}
>  };
> 
> diff --git
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> h
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> h
> index 60fb42c59c..589c9178ec 100644
> ---
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> h
> +++
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> h
> @@ -2,7 +2,7 @@
>Build a table, each item is (key, info) pair.
>and give a interface of query a string out of a table.
> 
> -  Copyright (c) 2005 - 2018, Intel Corporation. All rights reserved.
> +  Copyright (c) 2005 - 2019, Intel Corporation. All rights reserved.
>SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -10,6 +10,8 @@
>  #ifndef _SMBIOS_QUERY_TABLE_H_
>  #define _SMBIOS_QUERY_TABLE_H_
> 
> +#include 
> +
>  #define QUERY_TABLE_UNFOUND 0xFF
> 
>  typedef struct TABLE_ITEM {
> --
> 2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50439): https://edk2.groups.io/g/devel/message/50439
Mute This Topic: https://groups.io/mt/53817086/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH V4 6/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 add support for CXL Flexbus

2019-11-11 Thread Ni, Ray
Reviewed-by: Ray Ni 

> -Original Message-
> From: Gao, Zhichao 
> Sent: Tuesday, November 12, 2019 11:49 AM
> To: devel@edk2.groups.io
> Cc: Ni, Ray ; Chaganty, Rangasai V
> 
> Subject: [PATCH V4 6/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 add support for
> CXL Flexbus
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305
> 
> Various:
> - SMBIOSCR00183: add support for CXL Flexbus
> 
> Cc: Ray Ni 
> Cc: Sai Chaganty 
> Signed-off-by: Zhichao Gao 
> ---
>  .../Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c| 8
> 
>  1 file changed, 8 insertions(+)
> 
> diff --git
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> index 94d995bda1..8ed2bae4d3 100644
> ---
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> +++
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> @@ -1432,6 +1432,10 @@ TABLE_ITEM  SystemSlotTypeTable[] = {
>  0x23,
>  L"PCI Express Mini 76-pin (CEM spec. 2.0) Corresponds to Display-Mini
> card"
>},
> +  {
> +SlotTypeCXLFlexbus10,
> +L"CXL Flexbus 1.0"
> +  },
>{
>  0xA0,
>  L"PC-98/C20 "
> @@ -2290,6 +2294,10 @@ TABLE_ITEM  PMALocationTable[] = {
>{
>  0xA3,
>  L"  PC-98/Local bus add-on card"
> +  },
> +  {
> +MemoryArrayLocationCXLFlexbus10AddonCard,
> +L"  CXL Flexbus 1.0 add-on card"
>}
>  };
> 
> --
> 2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50437): https://edk2.groups.io/g/devel/message/50437
Mute This Topic: https://groups.io/mt/53817108/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH V4 7/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 Add value HBM and Die for type 17

2019-11-11 Thread Ni, Ray
Reviewed-by: Ray Ni 

> -Original Message-
> From: Gao, Zhichao 
> Sent: Tuesday, November 12, 2019 11:49 AM
> To: devel@edk2.groups.io
> Cc: Ni, Ray ; Chaganty, Rangasai V
> 
> Subject: [PATCH V4 7/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 Add value HBM
> and Die for type 17
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305
> 
> Memory Device (Type 17):
> - SMBIOSCR00178: add new memory device type value (HBM) and new form
> factor value (Die)
> 
> Cc: Ray Ni 
> Cc: Sai Chaganty 
> Signed-off-by: Zhichao Gao 
> ---
>  .../UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c   | 12
> 
>  1 file changed, 12 insertions(+)
> 
> diff --git
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> index 8ed2bae4d3..16b75f2667 100644
> ---
> a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> c
> +++
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.
> +++ c
> @@ -2423,6 +2423,10 @@ TABLE_ITEM  MemoryDeviceFormFactorTable[] = {
>{
>  0x0F,
>  L"  FB-DIMM"
> +  },
> +  {
> +MemoryFormFactorDie,
> +L"  Die"
>}
>  };
> 
> @@ -2538,6 +2542,14 @@ TABLE_ITEM  MemoryDeviceTypeTable[] = {
>{
>  0x1F,
>  L"  Logical non-volatile device"
> +  },
> +  {
> +MemoryTypeHBM,
> +L"  HBM (High Bandwidth Memory)"
> +  },
> +  {
> +MemoryTypeHBM2,
> +L"  HBM2 (High Bandwidth Memory Generation 2)"
>}
>  };
> 
> --
> 2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50436): https://edk2.groups.io/g/devel/message/50436
Mute This Topic: https://groups.io/mt/53817138/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Ni, Ray
Jian,
If we expect platform to use this library, probably "ASSERT(FALSE)" is not 
proper.

> -Original Message-
> From: Wang, Jian J 
> Sent: Tuesday, November 12, 2019 1:56 PM
> To: devel@edk2.groups.io
> Cc: Yao, Jiewen ; Zhang, Chao B
> ; Kinney, Michael D
> ; Gao, Liming ; Laszlo
> Ersek ; Ard Biesheuvel ;
> Ni, Ray 
> Subject: [PATCH] SecurityPkg/RngLibNull: add null version of RngLib
> 
> This is null version of RngLib which is used for those platforms or components
> which don't need random number.
> 
> Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> Cc: Jiewen Yao 
> Cc: Chao Zhang 
> Cc: Michael D Kinney 
> Cc: Liming Gao 
> Cc: Laszlo Ersek 
> Cc: Ard Biesheuvel 
> Cc: Ray Ni 
> Signed-off-by: Jian J Wang 
> ---
>  .../RngLibNull/RngLibNull.c   | 95 +++
>  .../RngLibNull/RngLibNull.inf | 31 ++
>  .../RngLibNull/RngLibNull.uni | 14 +++
>  3 files changed, 140 insertions(+)
>  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
>  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
>  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> 
> diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> new file mode 100644
> index 00..13677abc84
> --- /dev/null
> +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> @@ -0,0 +1,95 @@
> +/** @file
> +  Null version of Random number generator services.
> +
> +Copyright (c) 2019, Intel Corporation. All rights reserved.
> +SPDX-License-Identifier: BSD-2-Clause-Patent
> +
> +**/
> +
> +#include 
> +#include 
> +#include 
> +
> +/**
> +  Generates a 16-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 16-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber16 (
> +  OUT UINT16*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 32-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 32-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber32 (
> +  OUT UINT32*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 64-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 64-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber64 (
> +  OUT UINT64*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 128-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 128-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber128 (
> +  OUT UINT64*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> new file mode 100644
> index 00..f6494cdb82
> --- /dev/null
> +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> @@ -0,0 +1,31 @@
> +## @file
> +#  Null instance of RNG (Random Number Generator) Library.
> +#
> +#  Copyright (c) 2019, Intel Corporation. All rights reserved. # #
> +SPDX-License-Identifier: BSD-2-Clause-Patent # ##
> +
> +[Defines]
> +  INF_VERSION= 0x00010005
> +  BASE_NAME  = RngLibNull
> +  MODULE_UNI_FILE= RngLibNull.uni
> +  FILE_GUID  = CD8991F8-2061-4084-8C9E-9C6F352DC58D
> +  MODULE_TYPE= BASE
> +  VERSION_STRING = 1.0
> +  LIBRARY_CLASS  = RngLib
> +
> +#
> +#  VALID_ARCHITECTURES   = IA32 X64 ARM AARCH64
> +#
> +
> +[Sources]
> +  RngLibNull.c
> +
> +[Packages]
> +  MdePkg/MdePkg.dec
> +
> +[LibraryClasses]
> +  BaseLib
> +  DebugLib
> diff --git
> a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> new file mode 100644
> index 00..40b2ec3fe1
> --- /dev/null
> +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> @@ -0,0 +1,14 @@
> +// /** @file
> +// Null 

[edk2-devel] [PATCH] BaseTools: Fix build failure when using python38

2019-11-11 Thread Ni, Ray
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2304

Signed-off-by: Ray Ni 
Cc: Bob C Feng 
Cc: Liming Gao 
---
 BaseTools/Source/Python/build/build.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/BaseTools/Source/Python/build/build.py 
b/BaseTools/Source/Python/build/build.py
index bcd832c525..6c8798ef93 100755
--- a/BaseTools/Source/Python/build/build.py
+++ b/BaseTools/Source/Python/build/build.py
@@ -2064,7 +2064,7 @@ class Build():
 if Fdf.CurrentFdName and Fdf.CurrentFdName in Fdf.Profile.FdDict:
 FdDict = Fdf.Profile.FdDict[Fdf.CurrentFdName]
 for FdRegion in FdDict.RegionList:
-if str(FdRegion.RegionType) is 'FILE' and 
self.Platform.VpdToolGuid in str(FdRegion.RegionDataList):
+if str(FdRegion.RegionType) == 'FILE' and 
self.Platform.VpdToolGuid in str(FdRegion.RegionDataList):
 if int(FdRegion.Offset) % 8 != 0:
 EdkLogger.error("build", FORMAT_INVALID, 'The VPD 
Base Address %s must be 8-byte aligned.' % (FdRegion.Offset))
 Wa.FdfProfile = Fdf.Profile
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50434): https://edk2.groups.io/g/devel/message/50434
Mute This Topic: https://groups.io/mt/54042169/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Wang, Jian J
Required by BZ1871, this null version of RngLib needs to be pushed first to 
solve
build problem once we removed the dependency of TimerLib from OpensslLib.

I have to send this patch separately from other patches for bz1871 because there
will be patches cross repo.

Regards,
Jian

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Wang, Jian
> J
> Sent: Tuesday, November 12, 2019 1:56 PM
> To: devel@edk2.groups.io
> Cc: Yao, Jiewen ; Zhang, Chao B
> ; Kinney, Michael D ;
> Gao, Liming ; Laszlo Ersek ; Ard
> Biesheuvel ; Ni, Ray 
> Subject: [edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of 
> RngLib
> 
> This is null version of RngLib which is used for those platforms or
> components which don't need random number.
> 
> Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
> Cc: Jiewen Yao 
> Cc: Chao Zhang 
> Cc: Michael D Kinney 
> Cc: Liming Gao 
> Cc: Laszlo Ersek 
> Cc: Ard Biesheuvel 
> Cc: Ray Ni 
> Signed-off-by: Jian J Wang 
> ---
>  .../RngLibNull/RngLibNull.c   | 95 +++
>  .../RngLibNull/RngLibNull.inf | 31 ++
>  .../RngLibNull/RngLibNull.uni | 14 +++
>  3 files changed, 140 insertions(+)
>  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
>  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
>  create mode 100644
> SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
> 
> diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> new file mode 100644
> index 00..13677abc84
> --- /dev/null
> +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
> @@ -0,0 +1,95 @@
> +/** @file
> +  Null version of Random number generator services.
> +
> +Copyright (c) 2019, Intel Corporation. All rights reserved.
> +SPDX-License-Identifier: BSD-2-Clause-Patent
> +
> +**/
> +
> +#include 
> +#include 
> +#include 
> +
> +/**
> +  Generates a 16-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 16-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber16 (
> +  OUT UINT16*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 32-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 32-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber32 (
> +  OUT UINT32*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 64-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 64-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber64 (
> +  OUT UINT64*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> +
> +/**
> +  Generates a 128-bit random number.
> +
> +  if Rand is NULL, then ASSERT().
> +
> +  @param[out] Rand Buffer pointer to store the 128-bit random value.
> +
> +  @retval TRUE Random number generated successfully.
> +  @retval FALSEFailed to generate the random number.
> +
> +**/
> +BOOLEAN
> +EFIAPI
> +GetRandomNumber128 (
> +  OUT UINT64*Rand
> +  )
> +{
> +  ASSERT (FALSE);
> +  return FALSE;
> +}
> diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> new file mode 100644
> index 00..f6494cdb82
> --- /dev/null
> +++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
> @@ -0,0 +1,31 @@
> +## @file
> +#  Null instance of RNG (Random Number Generator) Library.
> +#
> +#  Copyright (c) 2019, Intel Corporation. All rights reserved.
> +#
> +#  SPDX-License-Identifier: BSD-2-Clause-Patent
> +#
> +##
> +
> +[Defines]
> +  INF_VERSION= 0x00010005
> +  BASE_NAME  = RngLibNull
> +  MODULE_UNI_FILE= RngLibNull.uni
> +  FILE_GUID  = CD8991F8-2061-4084-8C9E-9C6F352DC58D
> +  MODULE_TYPE= BASE
> +  VERSION_STRING = 1.0
> +  LIBRARY_CLASS  = RngLib
> +
> +#
> +#  VALID_ARCHITECTURES   = IA32 X64 ARM AARCH64
> +#
> +
> +[Sources]
> +  RngLibNull.c
> +
> +[Packages]
> +  MdePkg/MdePkg.dec
> +
> +[LibraryClasses]
> +  BaseLib
> +  DebugLib
> diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni

[edk2-devel] [PATCH] SecurityPkg/RngLibNull: add null version of RngLib

2019-11-11 Thread Wang, Jian J
This is null version of RngLib which is used for those platforms or
components which don't need random number.

Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1871
Cc: Jiewen Yao 
Cc: Chao Zhang 
Cc: Michael D Kinney 
Cc: Liming Gao 
Cc: Laszlo Ersek 
Cc: Ard Biesheuvel 
Cc: Ray Ni 
Signed-off-by: Jian J Wang 
---
 .../RngLibNull/RngLibNull.c   | 95 +++
 .../RngLibNull/RngLibNull.inf | 31 ++
 .../RngLibNull/RngLibNull.uni | 14 +++
 3 files changed, 140 insertions(+)
 create mode 100644 SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
 create mode 100644 SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
 create mode 100644 SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni

diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c 
b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
new file mode 100644
index 00..13677abc84
--- /dev/null
+++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.c
@@ -0,0 +1,95 @@
+/** @file
+  Null version of Random number generator services.
+
+Copyright (c) 2019, Intel Corporation. All rights reserved.
+SPDX-License-Identifier: BSD-2-Clause-Patent
+
+**/
+
+#include 
+#include 
+#include 
+
+/**
+  Generates a 16-bit random number.
+
+  if Rand is NULL, then ASSERT().
+
+  @param[out] Rand Buffer pointer to store the 16-bit random value.
+
+  @retval TRUE Random number generated successfully.
+  @retval FALSEFailed to generate the random number.
+
+**/
+BOOLEAN
+EFIAPI
+GetRandomNumber16 (
+  OUT UINT16*Rand
+  )
+{
+  ASSERT (FALSE);
+  return FALSE;
+}
+
+/**
+  Generates a 32-bit random number.
+
+  if Rand is NULL, then ASSERT().
+
+  @param[out] Rand Buffer pointer to store the 32-bit random value.
+
+  @retval TRUE Random number generated successfully.
+  @retval FALSEFailed to generate the random number.
+
+**/
+BOOLEAN
+EFIAPI
+GetRandomNumber32 (
+  OUT UINT32*Rand
+  )
+{
+  ASSERT (FALSE);
+  return FALSE;
+}
+
+/**
+  Generates a 64-bit random number.
+
+  if Rand is NULL, then ASSERT().
+
+  @param[out] Rand Buffer pointer to store the 64-bit random value.
+
+  @retval TRUE Random number generated successfully.
+  @retval FALSEFailed to generate the random number.
+
+**/
+BOOLEAN
+EFIAPI
+GetRandomNumber64 (
+  OUT UINT64*Rand
+  )
+{
+  ASSERT (FALSE);
+  return FALSE;
+}
+
+/**
+  Generates a 128-bit random number.
+
+  if Rand is NULL, then ASSERT().
+
+  @param[out] Rand Buffer pointer to store the 128-bit random value.
+
+  @retval TRUE Random number generated successfully.
+  @retval FALSEFailed to generate the random number.
+
+**/
+BOOLEAN
+EFIAPI
+GetRandomNumber128 (
+  OUT UINT64*Rand
+  )
+{
+  ASSERT (FALSE);
+  return FALSE;
+}
diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf 
b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
new file mode 100644
index 00..f6494cdb82
--- /dev/null
+++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.inf
@@ -0,0 +1,31 @@
+## @file
+#  Null instance of RNG (Random Number Generator) Library.
+#
+#  Copyright (c) 2019, Intel Corporation. All rights reserved.
+#
+#  SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+[Defines]
+  INF_VERSION= 0x00010005
+  BASE_NAME  = RngLibNull
+  MODULE_UNI_FILE= RngLibNull.uni
+  FILE_GUID  = CD8991F8-2061-4084-8C9E-9C6F352DC58D
+  MODULE_TYPE= BASE
+  VERSION_STRING = 1.0
+  LIBRARY_CLASS  = RngLib
+
+#
+#  VALID_ARCHITECTURES   = IA32 X64 ARM AARCH64
+#
+
+[Sources]
+  RngLibNull.c
+
+[Packages]
+  MdePkg/MdePkg.dec
+
+[LibraryClasses]
+  BaseLib
+  DebugLib
diff --git a/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni 
b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
new file mode 100644
index 00..40b2ec3fe1
--- /dev/null
+++ b/SecurityPkg/RandomNumberGenerator/RngLibNull/RngLibNull.uni
@@ -0,0 +1,14 @@
+// /** @file
+// Null Instance of RNG (Random Number Generator) Library.
+//
+// Copyright (c) 2019, Intel Corporation. All rights reserved.
+//
+// SPDX-License-Identifier: BSD-2-Clause-Patent
+//
+// **/
+
+
+#string STR_MODULE_ABSTRACT #language en-US "Null Instance of RNG 
Library"
+
+#string STR_MODULE_DESCRIPTION  #language en-US "Caution: This is a 
null version of RNG library and SHOULD NOT be used on any product ever."
+
-- 
2.17.1.windows.2


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50432): https://edk2.groups.io/g/devel/message/50432
Mute This Topic: https://groups.io/mt/54019525/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: 

Re: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix volatile variable RT cache update logic

2019-11-11 Thread Wang, Jian J
I reproduced this issue in secure boot. The patch fixed the problem.

One minor issue in the patch: you changed the code from if...else... to 
...if...,
which confused me a little bit. I thought you wanted to use 
'VolatileCacheInstance' in the 'if' expression but you didn't. So I suggest to
keep original style, i.e. put the first fetch of 'VolatileCacheInstance' in the 
'else'
statement (it'd be better to go to the if statement to keep the same order as
original code, if it won't cause too complex if expression). From the reviewer
perspective, this way make it clearer to know you just want to update the
condition to determine the non-volatile variable update.

With this addressed (no v2 needed),

   Reviewed-by: Jian J Wang 

Regards,
Jian

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Kubacki,
> Michael A
> Sent: Monday, November 11, 2019 1:16 PM
> To: devel@edk2.groups.io
> Cc: Gao, Liming ; Kinney, Michael D
> ; Wang, Jian J ; Wu, Hao
> A 
> Subject: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix volatile
> variable RT cache update logic
> 
> REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2333
> 
> During a SetVariable () invocation, UpdateVariable () is called.
> UpdateVariable () contains logic to determine whether a volatile or
> non-volatile UEFI variable was set so the corresponding runtime
> cache can be updated to reflect the change. The current logic simply
> evaluates Variable->Volatile to determine which runtime cache should
> be updated.
> 
> The problem is Variable->Volatile does not always reflect whether a
> volatile variable is being set. Variable->Volatile is set to TRUE
> only in the case a pre-existing variable is found in the volatile
> variable store. Therefore, the value is FALSE when a new volatile
> variable is written.
> 
> This change updates the logic to take this into account. If a new
> variable is written successfully, the Attributes will accurately
> reflect whether the variable is non-volatile. If a pre-existing
> variable is modified, the Volatile field will reflect the type of
> variable (Attributes are not reliable; e.g. 0x0 indicates deletion).
> 
> Cc: Liming Gao 
> Cc: Michael D Kinney 
> Cc: Jian J Wang 
> Cc: Hao A Wu 
> Signed-off-by: Michael Kubacki 
> ---
>  MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
> b/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
> index 29d6aca993..75d33ff724 100644
> --- a/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
> +++ b/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
> @@ -2296,9 +2296,8 @@ UpdateVariable (
> 
>  Done:
>if (!EFI_ERROR (Status)) {
> -if (Variable->Volatile) {
> -  VolatileCacheInstance = &(mVariableModuleGlobal-
> >VariableGlobal.VariableRuntimeCacheContext.VariableRuntimeVolatileCache);
> -} else {
> +VolatileCacheInstance = &(mVariableModuleGlobal-
> >VariableGlobal.VariableRuntimeCacheContext.VariableRuntimeVolatileCache);
> +if ((Variable->CurrPtr != NULL && !Variable->Volatile) || (Attributes &
> EFI_VARIABLE_NON_VOLATILE) != 0) {
>VolatileCacheInstance = &(mVariableModuleGlobal-
> >VariableGlobal.VariableRuntimeCacheContext.VariableRuntimeNvCache);
>  }
> 
> --
> 2.16.2.windows.1
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50431): https://edk2.groups.io/g/devel/message/50431
Mute This Topic: https://groups.io/mt/52162397/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH 1/1] MdePkg/Include: Add missing definitions of SMBIOS type 42h in SmBios.h

2019-11-11 Thread Abner Chang
This definitions was defined in SMBIOS 3.2a and we miss to have the 
corresponding definition for this in SmBios.h.

Abner

> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Liming Gao
> Sent: Tuesday, November 12, 2019 12:43 PM
> To: devel@edk2.groups.io; Chang, Abner (HPS SW/FW Technologist)
> 
> Cc: Kinney, Michael D 
> Subject: Re: [edk2-devel] [PATCH 1/1] MdePkg/Include: Add missing
> definitions of SMBIOS type 42h in SmBios.h
> 
> Hi, is this a new definition in SmBios 3.3? Or is this a missing definition in
> previous SmBios version?
> 
> >-Original Message-
> >From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> >Abner Chang
> >Sent: Tuesday, November 12, 2019 10:56 AM
> >To: devel@edk2.groups.io
> >Cc: abner.ch...@hpe.com; Kinney, Michael D
> >; Gao, Liming 
> >Subject: [edk2-devel] [PATCH 1/1] MdePkg/Include: Add missing
> >definitions of SMBIOS type 42h in SmBios.h
> >
> >Add host interface Protocol Type Data Format structure in SmBios.h
> >
> >BZ link,
> >INVALID URI REMOVED
> >.org_show-5Fbug.cgi-3Fid-
> 3D2328=DwIFAg=C5b8zRQO1miGmBeVZ2LFWg=_SN
> >6FZBN4Vgi4Ulkskz6qU3NYRO03nHp9P7Z5q59A3E=nqCVIRL9hVAaMUSX
> QUQXjFwJWv39
> >I6U90eR54obtRSM=p7ENdrSPY3KJNnhX8zR5S1D8ZkjtYzhhhe-ki9-
> 2mTQ=
> >
> >Signed-off-by: Abner Chang 
> >
> >Cc: Michael D Kinney 
> >Cc: Liming Gao 
> >Signed-off-by: Abner Chang 
> >---
> > MdePkg/Include/IndustryStandard/SmBios.h | 9 +
> > 1 file changed, 9 insertions(+)
> >
> >diff --git a/MdePkg/Include/IndustryStandard/SmBios.h
> >b/MdePkg/Include/IndustryStandard/SmBios.h
> >index f504cc84e7..c0144c9c8f 100644
> >--- a/MdePkg/Include/IndustryStandard/SmBios.h
> >+++ b/MdePkg/Include/IndustryStandard/SmBios.h
> >@@ -2483,6 +2483,15 @@ typedef struct {
> >   UINT8 DevFuncNum;
> > } SMBIOS_TABLE_TYPE41;
> >
> >+///
> >+///  Management Controller Host Interface - Protocol Record Data Format.
> >+///
> >+typedef struct {
> >+  UINT8ProtocolType;
> >+  UINT8ProtocolTypeDataLen;
> >+  UINT8ProtocolTypeData[1];
> >+} MC_HOST_INTERFACE_PROTOCOL_RECORD;
> >+
> > ///
> > /// Management Controller Host Interface - Interface Types.
> > /// 00h - 3Fh: MCTP Host Interfaces
> >--
> >2.21.0.windows.1
> >
> >
> >
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50430): https://edk2.groups.io/g/devel/message/50430
Mute This Topic: https://groups.io/mt/53725511/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH 1/1] MdePkg/Include: Add missing definitions of SMBIOS type 42h in SmBios.h

2019-11-11 Thread Liming Gao
Hi, is this a new definition in SmBios 3.3? Or is this a missing definition in 
previous SmBios version? 

>-Original Message-
>From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>Abner Chang
>Sent: Tuesday, November 12, 2019 10:56 AM
>To: devel@edk2.groups.io
>Cc: abner.ch...@hpe.com; Kinney, Michael D ;
>Gao, Liming 
>Subject: [edk2-devel] [PATCH 1/1] MdePkg/Include: Add missing definitions
>of SMBIOS type 42h in SmBios.h
>
>Add host interface Protocol Type Data Format structure in SmBios.h
>
>BZ link,
>https://bugzilla.tianocore.org/show_bug.cgi?id=2328
>
>Signed-off-by: Abner Chang 
>
>Cc: Michael D Kinney 
>Cc: Liming Gao 
>Signed-off-by: Abner Chang 
>---
> MdePkg/Include/IndustryStandard/SmBios.h | 9 +
> 1 file changed, 9 insertions(+)
>
>diff --git a/MdePkg/Include/IndustryStandard/SmBios.h
>b/MdePkg/Include/IndustryStandard/SmBios.h
>index f504cc84e7..c0144c9c8f 100644
>--- a/MdePkg/Include/IndustryStandard/SmBios.h
>+++ b/MdePkg/Include/IndustryStandard/SmBios.h
>@@ -2483,6 +2483,15 @@ typedef struct {
>   UINT8 DevFuncNum;
> } SMBIOS_TABLE_TYPE41;
>
>+///
>+///  Management Controller Host Interface - Protocol Record Data Format.
>+///
>+typedef struct {
>+  UINT8ProtocolType;
>+  UINT8ProtocolTypeDataLen;
>+  UINT8ProtocolTypeData[1];
>+} MC_HOST_INTERFACE_PROTOCOL_RECORD;
>+
> ///
> /// Management Controller Host Interface - Interface Types.
> /// 00h - 3Fh: MCTP Host Interfaces
>--
>2.21.0.windows.1
>
>
>


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50429): https://edk2.groups.io/g/devel/message/50429
Mute This Topic: https://groups.io/mt/53725511/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms: PATCH] MinPlatformPkg: Add SetCacheMtrrLib class to dsc.

2019-11-11 Thread Liming Gao
Reviewed-by: Liming Gao 

>-Original Message-
>From: Chiu, Chasel
>Sent: Tuesday, November 12, 2019 11:26 AM
>To: devel@edk2.groups.io
>Cc: Kubacki, Michael A ; Desimone, Nathaniel L
>; Gao, Liming 
>Subject: [edk2-platforms: PATCH] MinPlatformPkg: Add SetCacheMtrrLib class
>to dsc.
>
>REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2314
>
>Fixed typo issue in MinPlatformPkg.dsc caused by previous
>commit.
>
>Cc: Michael Kubacki 
>Cc: Nate DeSimone 
>Cc: Liming Gao 
>Signed-off-by: Chasel Chiu 
>---
> Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
>b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
>index 17272f819c..038f05be92 100644
>--- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
>+++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
>@@ -94,7 +94,7 @@
>
>ReportFvLib|MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiReport
>FvLib.inf
>
>TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/PeiTestP
>ointCheckLib.inf
>   TestPointLib|MinPlatformPkg/Test/Library/TestPointLib/PeiTestPointLib.inf
>-
>SetCacheMtrrLib|$(PLATFORM_PACKAGE)/Library/SetCacheMtrrLib/SetCach
>eMtrrLibNull.inf
>+
>SetCacheMtrrLib|MinPlatformPkg/Library/SetCacheMtrrLib/SetCacheMtrrLib
>Null.inf
>
> [LibraryClasses.common.DXE_DRIVER]
>   #
>--
>2.13.3.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50428): https://edk2.groups.io/g/devel/message/50428
Mute This Topic: https://groups.io/mt/47032665/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 4/8] MdePkg/Smbios.h: SMBIOS 3.3.0 Update Intel Persistent Memory string

2019-11-11 Thread Gao, Zhichao
From: "Gao, Zhichao" 

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305

Memory Device (Type 17):
- SMBIOSCR00179: update the string for Intel persistent memory

Cc: Michael D Kinney 
Cc: Liming Gao 
Cc: Sai Chaganty 
Reviewed-by: Liming Gao 
Signed-off-by: Zhichao Gao 
---
 MdePkg/Include/IndustryStandard/SmBios.h | 4 
 1 file changed, 4 insertions(+)

diff --git a/MdePkg/Include/IndustryStandard/SmBios.h 
b/MdePkg/Include/IndustryStandard/SmBios.h
index 9aa8cf3e72..8b3c4d7ba9 100644
--- a/MdePkg/Include/IndustryStandard/SmBios.h
+++ b/MdePkg/Include/IndustryStandard/SmBios.h
@@ -1753,6 +1753,10 @@ typedef enum {
   MemoryTechnologyNvdimmN   = 0x04,
   MemoryTechnologyNvdimmF   = 0x05,
   MemoryTechnologyNvdimmP   = 0x06,
+  //
+  // This definition is updated to represent Intel
+  // Optane DC Presistent Memory in SMBIOS spec 3.3.0
+  //
   MemoryTechnologyIntelPersistentMemory = 0x07
 } MEMORY_DEVICE_TECHNOLOGY;
 
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50423): https://edk2.groups.io/g/devel/message/50423
Mute This Topic: https://groups.io/mt/53817057/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 3/8] MdePkg/Smbios.h: SMBIOS 3.3.0 Add value HBM and Die for type 17

2019-11-11 Thread Gao, Zhichao
From: "Gao, Zhichao" 

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305

Memory Device (Type 17):
- SMBIOSCR00178: add new memory device type value (HBM) and new form
factor value (Die)

Cc: Michael D Kinney 
Cc: Liming Gao 
Cc: Sai Chaganty 
Reviewed-by: Liming Gao 
Signed-off-by: Zhichao Gao 
---
 MdePkg/Include/IndustryStandard/SmBios.h | 7 +--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/MdePkg/Include/IndustryStandard/SmBios.h 
b/MdePkg/Include/IndustryStandard/SmBios.h
index 54ec837671..9aa8cf3e72 100644
--- a/MdePkg/Include/IndustryStandard/SmBios.h
+++ b/MdePkg/Include/IndustryStandard/SmBios.h
@@ -1681,7 +1681,8 @@ typedef enum {
   MemoryFormFactorRimm = 0x0C,
   MemoryFormFactorSodimm   = 0x0D,
   MemoryFormFactorSrimm= 0x0E,
-  MemoryFormFactorFbDimm   = 0x0F
+  MemoryFormFactorFbDimm   = 0x0F,
+  MemoryFormFactorDie  = 0x10
 } MEMORY_FORM_FACTOR;
 
 ///
@@ -1715,7 +1716,9 @@ typedef enum {
   MemoryTypeLpddr2 = 0x1C,
   MemoryTypeLpddr3 = 0x1D,
   MemoryTypeLpddr4 = 0x1E,
-  MemoryTypeLogicalNonVolatileDevice   = 0x1F
+  MemoryTypeLogicalNonVolatileDevice   = 0x1F,
+  MemoryTypeHBM= 0x20,
+  MemoryTypeHBM2   = 0x21
 } MEMORY_DEVICE_TYPE;
 
 ///
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50422): https://edk2.groups.io/g/devel/message/50422
Mute This Topic: https://groups.io/mt/53817021/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 8/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 Update "Intel persistent memory"

2019-11-11 Thread Gao, Zhichao
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305

Memory Device (Type 17):
– SMBIOSCR00179: update the string for Intel persistent memory

Cc: Ray Ni 
Cc: Sai Chaganty 
Signed-off-by: Zhichao Gao 
---
 ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c 
b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
index 16b75f2667..b80e16d56a 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
@@ -2638,8 +2638,8 @@ TABLE_ITEM  MemoryDeviceMemoryTechnologyTable[] = {
 L" NVDIMM-P"
   },
   {
-0x07,
-L" Intel persistent memory"
+MemoryTechnologyIntelPersistentMemory,
+L" Intel Optane DC Persistent Memory"
   }
 };
 
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50427): https://edk2.groups.io/g/devel/message/50427
Mute This Topic: https://groups.io/mt/53817164/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 0/8] Update SMBIOS 3.3.0

2019-11-11 Thread Gao, Zhichao
The following changes were made to version 3.2.0 of the document to produce this
version:
System Slots (Type 9):
- Add PCI Express Gen 4 values
- Clarify bus number usage for PCI Express
Memory Device (Type 17):
- Add new memory device type value (HBM) and new form factor value (Die)
- Update the string for Intel persistent memory
Various:
- Add support for RISC-V processors, add structure type 44 
(processor-additional information)
- add support for CXL Flexbus

V2:
Add the new definition to MdePkg/Smbios.h.

V3:
Avoid change the enum name to casue the incompatible issue.
Add the comment instead change the enum define name.

V4:
Use the enums instead of the magic numbers.
Plan to add a new BZ to add the missing enums/MACROs and convert all
magic numbers into enums/MACROs.

Notes:
Clarify bus number usage for PCI Express - Update the spec no code change 
requirement
Add support for RISC-V processors, add structure type 44 (processor-additional 
information) -
Already done at https://bugzilla.tianocore.org/show_bug.cgi?id=2202

Cc: Michael D Kinney 
Cc: Liming Gao 
Cc: Ray Ni 
Cc: Sai Chaganty 
Signed-off-by: Zhichao Gao 

Gao, Zhichao (4):
  MdePkg/Smbios.h: SMBIOS 3.3.0 add PCI gen4 values for type 9
  MdePkg/Smbios.h: SMBIOS 3.3.0 add support for CXL Flexbus
  MdePkg/Smbios.h: SMBIOS 3.3.0 Add value HBM and Die for type 17
  MdePkg/Smbios.h: SMBIOS 3.3.0 Update Intel Persistent Memory string

Zhichao Gao (4):
  ShellPkg/SmbiosView: SMBIOS 3.3.0 add PCI gen4 values for type 9
  ShellPkg/SmbiosView: SMBIOS 3.3.0 add support for CXL Flexbus
  ShellPkg/SmbiosView: SMBIOS 3.3.0 Add value HBM and Die for type 17
  ShellPkg/SmbiosView: SMBIOS 3.3.0 Update "Intel persistent memory"

 MdePkg/Include/IndustryStandard/SmBios.h   | 25 ---
 .../SmbiosView/QueryTable.c| 50 --
 .../SmbiosView/QueryTable.h|  4 +-
 3 files changed, 70 insertions(+), 9 deletions(-)

-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50419): https://edk2.groups.io/g/devel/message/50419
Mute This Topic: https://groups.io/mt/53816933/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 7/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 Add value HBM and Die for type 17

2019-11-11 Thread Gao, Zhichao
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305

Memory Device (Type 17):
– SMBIOSCR00178: add new memory device type value (HBM) and new form
factor value (Die)

Cc: Ray Ni 
Cc: Sai Chaganty 
Signed-off-by: Zhichao Gao 
---
 .../UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c   | 12 
 1 file changed, 12 insertions(+)

diff --git 
a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c 
b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
index 8ed2bae4d3..16b75f2667 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
@@ -2423,6 +2423,10 @@ TABLE_ITEM  MemoryDeviceFormFactorTable[] = {
   {
 0x0F,
 L"  FB-DIMM"
+  },
+  {
+MemoryFormFactorDie,
+L"  Die"
   }
 };
 
@@ -2538,6 +2542,14 @@ TABLE_ITEM  MemoryDeviceTypeTable[] = {
   {
 0x1F,
 L"  Logical non-volatile device"
+  },
+  {
+MemoryTypeHBM,
+L"  HBM (High Bandwidth Memory)"
+  },
+  {
+MemoryTypeHBM2,
+L"  HBM2 (High Bandwidth Memory Generation 2)"
   }
 };
 
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50426): https://edk2.groups.io/g/devel/message/50426
Mute This Topic: https://groups.io/mt/53817138/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 5/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 add PCI gen4 values for type 9

2019-11-11 Thread Gao, Zhichao
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305

System Slots (Type 9):
– SMBIOSCR00184: add PCI Express Gen 4 values

Add the Smbios.h to use the MARCOs or enums.

Cc: Ray Ni 
Cc: Sai Chaganty 
Signed-off-by: Zhichao Gao 
---
 .../SmbiosView/QueryTable.c| 26 +-
 .../SmbiosView/QueryTable.h|  4 +++-
 2 files changed, 28 insertions(+), 2 deletions(-)

diff --git 
a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c 
b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
index fdb7a47d33..94d995bda1 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
@@ -2,7 +2,7 @@
   Build a table, each item is (Key, Info) pair.
   And give a interface of query a string out of a table.
 
-  Copyright (c) 2005 - 2018, Intel Corporation. All rights reserved.
+  Copyright (c) 2005 - 2019, Intel Corporation. All rights reserved.
   (C) Copyright 2016-2019 Hewlett Packard Enterprise Development LP
   SPDX-License-Identifier: BSD-2-Clause-Patent
 
@@ -1523,6 +1523,30 @@ TABLE_ITEM  SystemSlotTypeTable[] = {
   {
 0xB6,
 L"PCI Express Gen 3 X16"
+  },
+  {
+SlotTypePciExpressGen4,
+L"PCI Express Gen 4"
+  },
+  {
+SlotTypePciExpressGen4X1,
+L"PCI Express Gen 4 X1"
+  },
+  {
+SlotTypePciExpressGen4X2,
+L"PCI Express Gen 4 X2"
+  },
+  {
+SlotTypePciExpressGen4X4,
+L"PCI Express Gen 4 X4"
+  },
+  {
+SlotTypePciExpressGen4X8,
+L"PCI Express Gen 4 X8"
+  },
+  {
+SlotTypePciExpressGen4X16,
+L"PCI Express Gen 4 X16"
   }
 };
 
diff --git 
a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.h 
b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.h
index 60fb42c59c..589c9178ec 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.h
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.h
@@ -2,7 +2,7 @@
   Build a table, each item is (key, info) pair.
   and give a interface of query a string out of a table.
 
-  Copyright (c) 2005 - 2018, Intel Corporation. All rights reserved.
+  Copyright (c) 2005 - 2019, Intel Corporation. All rights reserved.
   SPDX-License-Identifier: BSD-2-Clause-Patent
 
 **/
@@ -10,6 +10,8 @@
 #ifndef _SMBIOS_QUERY_TABLE_H_
 #define _SMBIOS_QUERY_TABLE_H_
 
+#include 
+
 #define QUERY_TABLE_UNFOUND 0xFF
 
 typedef struct TABLE_ITEM {
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50424): https://edk2.groups.io/g/devel/message/50424
Mute This Topic: https://groups.io/mt/53817086/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 2/8] MdePkg/Smbios.h: SMBIOS 3.3.0 add support for CXL Flexbus

2019-11-11 Thread Gao, Zhichao
From: "Gao, Zhichao" 

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305

Various:
- SMBIOSCR00183: add support for CXL Flexbus

Cc: Michael D Kinney 
Cc: Liming Gao 
Cc: Sai Chaganty 
Reviewed-by: Sai Chaganty 
Reviewed-by: Liming Gao 
Signed-off-by: Zhichao Gao 
---
 MdePkg/Include/IndustryStandard/SmBios.h | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/MdePkg/Include/IndustryStandard/SmBios.h 
b/MdePkg/Include/IndustryStandard/SmBios.h
index 0a31e37f18..54ec837671 100644
--- a/MdePkg/Include/IndustryStandard/SmBios.h
+++ b/MdePkg/Include/IndustryStandard/SmBios.h
@@ -1285,6 +1285,7 @@ typedef enum {
   SlotTypePciExpressMini52pinWithBSKO  = 0x21,  ///< PCI Express Mini 
52-pin (CEM spec. 2.0) with bottom-side keep-outs.
   SlotTypePciExpressMini52pinWithoutBSKO = 0x22,///< PCI Express Mini 
52-pin (CEM spec. 2.0) without bottom-side keep-outs.
   SlotTypePciExpressMini76pin  = 0x23,  ///< PCI Express Mini 
76-pin (CEM spec. 2.0) Corresponds to Display-Mini card.
+  SlotTypeCXLFlexbus10 = 0x30,
   SlotTypePC98C20  = 0xA0,
   SlotTypePC98C24  = 0xA1,
   SlotTypePC98E= 0xA2,
@@ -1612,7 +1613,8 @@ typedef enum {
   MemoryArrayLocationPc98C20AddonCard  = 0xA0,
   MemoryArrayLocationPc98C24AddonCard  = 0xA1,
   MemoryArrayLocationPc98EAddonCard= 0xA2,
-  MemoryArrayLocationPc98LocalBusAddonCard = 0xA3
+  MemoryArrayLocationPc98LocalBusAddonCard = 0xA3,
+  MemoryArrayLocationCXLFlexbus10AddonCard = 0xA4
 } MEMORY_ARRAY_LOCATION;
 
 ///
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50421): https://edk2.groups.io/g/devel/message/50421
Mute This Topic: https://groups.io/mt/53816969/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 1/8] MdePkg/Smbios.h: SMBIOS 3.3.0 add PCI gen4 values for type 9

2019-11-11 Thread Gao, Zhichao
From: "Gao, Zhichao" 

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305

System Slots (Type 9):
- SMBIOSCR00184: add PCI Express Gen 4 values

Cc: Michael D Kinney 
Cc: Liming Gao 
Cc: Sai Chaganty 
Reviewed-by: Sai Chaganty 
Reviewed-by: Liming Gao 
Signed-off-by: Zhichao Gao 
---
 MdePkg/Include/IndustryStandard/SmBios.h | 10 --
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/MdePkg/Include/IndustryStandard/SmBios.h 
b/MdePkg/Include/IndustryStandard/SmBios.h
index f504cc84e7..0a31e37f18 100644
--- a/MdePkg/Include/IndustryStandard/SmBios.h
+++ b/MdePkg/Include/IndustryStandard/SmBios.h
@@ -1,7 +1,7 @@
 /** @file
   Industry Standard Definitions of SMBIOS Table Specification v3.3.0.
 
-Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
 (C) Copyright 2015-2017 Hewlett Packard Enterprise Development LP
 (C) Copyright 2015 - 2019 Hewlett Packard Enterprise Development LP
 SPDX-License-Identifier: BSD-2-Clause-Patent
@@ -1307,7 +1307,13 @@ typedef enum {
   SlotTypePciExpressGen3X2 = 0xB3,
   SlotTypePciExpressGen3X4 = 0xB4,
   SlotTypePciExpressGen3X8 = 0xB5,
-  SlotTypePciExpressGen3X16= 0xB6
+  SlotTypePciExpressGen3X16= 0xB6,
+  SlotTypePciExpressGen4   = 0xB8,
+  SlotTypePciExpressGen4X1 = 0xB9,
+  SlotTypePciExpressGen4X2 = 0xBA,
+  SlotTypePciExpressGen4X4 = 0xBB,
+  SlotTypePciExpressGen4X8 = 0xBC,
+  SlotTypePciExpressGen4X16= 0xBD
 } MISC_SLOT_TYPE;
 
 ///
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50420): https://edk2.groups.io/g/devel/message/50420
Mute This Topic: https://groups.io/mt/53816948/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V4 6/8] ShellPkg/SmbiosView: SMBIOS 3.3.0 add support for CXL Flexbus

2019-11-11 Thread Gao, Zhichao
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2305

Various:
– SMBIOSCR00183: add support for CXL Flexbus

Cc: Ray Ni 
Cc: Sai Chaganty 
Signed-off-by: Zhichao Gao 
---
 .../Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c| 8 
 1 file changed, 8 insertions(+)

diff --git 
a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c 
b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
index 94d995bda1..8ed2bae4d3 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c
@@ -1432,6 +1432,10 @@ TABLE_ITEM  SystemSlotTypeTable[] = {
 0x23,
 L"PCI Express Mini 76-pin (CEM spec. 2.0) Corresponds to Display-Mini card"
   },
+  {
+SlotTypeCXLFlexbus10,
+L"CXL Flexbus 1.0"
+  },
   {
 0xA0,
 L"PC-98/C20 "
@@ -2290,6 +2294,10 @@ TABLE_ITEM  PMALocationTable[] = {
   {
 0xA3,
 L"  PC-98/Local bus add-on card"
+  },
+  {
+MemoryArrayLocationCXLFlexbus10AddonCard,
+L"  CXL Flexbus 1.0 add-on card"
   }
 };
 
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50425): https://edk2.groups.io/g/devel/message/50425
Mute This Topic: https://groups.io/mt/53817108/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Michael D Kinney
Ray,

I agree that a name that represents the symbolic debug
format makes more sense.

The term 'PE' is short for PE/COFF, and that is the 
required final output format.  A toolchain profile that
happens to go through other intermediate formats (e.g. 
elf or macho) before finally generating a PE/COFF image
is usually not that interesting to most developers.  So
adding 'PE' to the name is redundant information.

The attribute of the images that does impact developers
is the format of the symbol information.  Even for 
Visual Studio, PDB is the file extension used when the
symbol information is placed in a separate file.  The
Visual Studio compilers do support putting the symbol
information in a section of the PE/COFF image.  EDK II
builds happen to always use the PDB option to minimize
the size of firmware images. So PDB may not be the right
name either.  I think the symbol format in the PDB that
is used is codeview.

If we want to plan ahead for toolchain names perhaps:

Codeview: CLANGCODEVIEW or CLANGCV or CLANGPDB 
Dwarf:CLANGDWARF

Best regards,

Mike

> -Original Message-
> From: devel@edk2.groups.io  On
> Behalf Of Ni, Ray
> Sent: Monday, November 11, 2019 7:23 PM
> To: devel@edk2.groups.io; Ni, Ray ;
> Gao, Liming ; af...@apple.com;
> Leif Lindholm 
> Cc: Justen, Jordan L ; Shi,
> Steven 
> Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg:
> Enable CLANG9 tool chain
> 
> And LLVM I believe is capable to support generating PE +
> DWARF.
> That's my second concern: Using CLANGPE may not imply
> PDB is used from a LLVM expert's understanding.
> 
> 
> > -Original Message-
> > From: devel@edk2.groups.io  On
> Behalf Of Ni, Ray
> > Sent: Tuesday, November 12, 2019 11:10 AM
> > To: devel@edk2.groups.io; Ni, Ray ;
> Gao, Liming
> > ; af...@apple.com; Leif Lindholm
> > 
> > Cc: Justen, Jordan L ; Shi,
> Steven
> > 
> > Subject: Re: [edk2-devel] [Patch v3 10/11]
> EmulatorPkg: Enable CLANG9
> > tool chain
> >
> > My point is if we choose CLANGPE, for LLVM toolchain
> supporting DWARF
> > debug symbol, there is no proper name left: we cannot
> use CLANGELF.
> >
> > Andrew, you said CLANGPDE. A typo?
> >
> > > -Original Message-
> > > From: devel@edk2.groups.io  On
> Behalf Of Ni,
> > Ray
> > > Sent: Tuesday, November 12, 2019 9:46 AM
> > > To: Gao, Liming ;
> devel@edk2.groups.io;
> > > af...@apple.com; Leif Lindholm
> 
> > > Cc: Justen, Jordan L ;
> Shi, Steven
> > > 
> > > Subject: Re: [edk2-devel] [Patch v3 10/11]
> EmulatorPkg: Enable
> > > CLANG9 tool chain
> > >
> > > Liming,
> > > What name will be chosen when in future someone
> wants a LLVM
> > toolchain
> > > which supports DWARF debug symbol?
> > >
> > >
> > > > -Original Message-
> > > > From: Gao, Liming 
> > > > Sent: Tuesday, November 12, 2019 8:41 AM
> > > > To: devel@edk2.groups.io; af...@apple.com; Leif
> Lindholm
> > > > 
> > > > Cc: Ni, Ray ; Justen, Jordan L
> > > > ; Shi, Steven
> ;
> > > > Gao, Liming 
> > > > Subject: RE: [edk2-devel] [Patch v3 10/11]
> EmulatorPkg: Enable
> > > > CLANG9 tool chain
> > > >
> > > > Thanks for your feedback. I will choose CLANGPE as
> the tool chain name.
> > > >
> > > > Thanks
> > > > Liming
> > > > >-Original Message-
> > > > >From: devel@edk2.groups.io
> [mailto:devel@edk2.groups.io] On
> > > > >Behalf Of Andrew Fish via Groups.Io
> > > > >Sent: Tuesday, November 12, 2019 12:52 AM
> > > > >To: Leif Lindholm 
> > > > >Cc: Ni, Ray ; Gao, Liming
> > > > >; devel@edk2.groups.io;
> Justen, Jordan L
> > > > >; Shi, Steven
> 
> > > > >Subject: Re: [edk2-devel] [Patch v3 10/11]
> EmulatorPkg: Enable
> > > > >CLANG9 tool chain
> > > > >
> > > > >Either works for me too. I like the PDE ending a
> little more, but
> > > > >agree it is a little more obscure.
> > > > >> On Nov 11, 2019, at 8:39 AM, Leif Lindholm
> > > > >> 
> > > > wrote:
> > > > >>
> > > > >> On Fri, Nov 08, 2019 at 03:34:59AM +, Ni,
> Ray wrote:
> > > > >>> Liming,
> > > > >>> PE is UEFI spec required executable binary
> format. I like
> > > > >>> CLANGPDB more than CLANGPE given LLVM may
> generate DRAWF
> > debug
> > > > >>> symbol
> > > > >even
> > > > >>> when generating PE.
> > > > >>
> > > > >> Just a comment here to point out that while (as
> I stated in
> > > > >> reply to
> > > > >> Liming) my preference would be CLANGPE, I see
> the logic in the
> > > > >> above, and would be happy with either.
> > > > >>
> > > > >> (My reason for preferring CLANGPE is not
> exactly techincal - I
> > > > >> just expect more people to know what PE is than
> who know what
> > > > >> PDB
> > > > >> is.)
> > > > >>
> > > > >> Regards,
> > > > >>
> > > > >> Leif
> > > > >>
> > > >  -Original Message-
> > > >  From: Gao, Liming 
> > > >  Sent: Friday, November 8, 2019 9:50 AM
> > > >  To: devel@edk2.groups.io;
> leif.lindh...@linaro.org; Andrew
> > > >  Fish
> > > > >
> > > >  Cc: Ni, Ray ; Justen,
> Jordan L
> > > > >; Gao, Liming
> ;
> > > > >Shi,
> > > >  Steven 
> 

Re: [edk2-devel] [Patch] Readme.md: Update EDK II CI build branch name

2019-11-11 Thread Sean via Groups.Io
Reviewed-by: Sean Brogan 

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50417): https://edk2.groups.io/g/devel/message/50417
Mute This Topic: https://groups.io/mt/53599349/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][PATCH V1 1/3] KabylakeOpenBoardPkg/GalagoPro3: Update BaseConfigBlockLib package

2019-11-11 Thread Chiu, Chasel
Reviewed-by: Chasel Chiu 

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Kubacki,
> Michael A
> Sent: Tuesday, November 12, 2019 10:39 AM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Desimone, Nathaniel L
> 
> Subject: [edk2-devel] [edk2-platforms][PATCH V1 1/3]
> KabylakeOpenBoardPkg/GalagoPro3: Update BaseConfigBlockLib package
> 
> Updates the silicon package for the BaseConfigBlockLib instance from
> KabylakeSiliconPkg to IntelSiliconPkg to align with the change made in
> commit f0e29f87ad.
> 
> Cc: Chasel Chiu 
> Cc: Nate DeSimone 
> Signed-off-by: Michael Kubacki 
> ---
>  Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc | 2
> +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git
> a/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
> b/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
> index 3c0ae9dfbd..e43c944201 100644
> --- a/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
> +++ b/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
> @@ -104,7 +104,7 @@
>###
># Silicon Initialization Package
>###
> -
> ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseC
> onfigBlockLib.inf
> +
> + ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBl
> + ockLib.inf
> 
> SiliconInitLib|$(PLATFORM_SI_PACKAGE)/Library/SiliconInitLib/SiliconInitLib.i
> nf
> 
> SiliconPolicyInitLib|$(PLATFORM_SI_PACKAGE)/Library/PeiSiliconPolicyInitLib
> Fsp/PeiSiliconPolicyInitLibFsp.inf
> 
> --
> 2.16.2.windows.1
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50415): https://edk2.groups.io/g/devel/message/50415
Mute This Topic: https://groups.io/mt/53690700/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][PATCH V1 2/3] KabylakeOpenBoardPkg/KabylakeRvp3: Update BaseConfigBlockLib package

2019-11-11 Thread Chiu, Chasel


Reviewed-by: Chasel Chiu 

> -Original Message-
> From: Kubacki, Michael A 
> Sent: Tuesday, November 12, 2019 10:39 AM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Desimone, Nathaniel L
> 
> Subject: [edk2-platforms][PATCH V1 2/3]
> KabylakeOpenBoardPkg/KabylakeRvp3: Update BaseConfigBlockLib package
> 
> Updates the silicon package for the BaseConfigBlockLib instance from
> KabylakeSiliconPkg to IntelSiliconPkg to align with the change made in
> commit f0e29f87ad.
> 
> Cc: Chasel Chiu 
> Cc: Nate DeSimone 
> Signed-off-by: Michael Kubacki 
> ---
>  Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc |
> 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git
> a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
> b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
> index 47529a7945..1ce473432a 100644
> ---
> a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
> +++
> b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
> @@ -132,7 +132,7 @@
>###
># Silicon Initialization Package
>###
> -
> ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseC
> onfigBlockLib.inf
> +
> + ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBl
> + ockLib.inf
> 
> SiliconInitLib|$(PLATFORM_SI_PACKAGE)/Library/SiliconInitLib/SiliconInitLib.i
> nf
> 
>  !if gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection == 1
> --
> 2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50413): https://edk2.groups.io/g/devel/message/50413
Mute This Topic: https://groups.io/mt/53690876/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][PATCH V1 3/3] WhiskeylakeURvp: Update BaseConfigBlockLib package

2019-11-11 Thread Chiu, Chasel


Reviewed-by: Chasel Chiu 

> -Original Message-
> From: Kubacki, Michael A 
> Sent: Tuesday, November 12, 2019 10:39 AM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Desimone, Nathaniel L
> 
> Subject: [edk2-platforms][PATCH V1 3/3] WhiskeylakeURvp: Update
> BaseConfigBlockLib package
> 
> Updates the silicon package for the BaseConfigBlockLib instance from
> CoffeelakeSiliconPkg to IntelSiliconPkg to align with the change made in
> commit f0e29f87ad.
> 
> Cc: Chasel Chiu 
> Cc: Nate DeSimone 
> Signed-off-by: Michael Kubacki 
> ---
> 
> Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.
> dsc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git
> a/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardP
> kg.dsc
> b/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardP
> kg.dsc
> index 8a9245f7a6..cdaf47b6f7 100644
> ---
> a/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardP
> kg.dsc
> +++
> b/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardP
> k
> +++ g.dsc
> @@ -103,7 +103,7 @@
>###
># Silicon Initialization Package
>###
> -
> ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseC
> onfigBlockLib.inf
> +
> + ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBl
> + ockLib.inf
> 
> MmPciLib|$(PLATFORM_SI_PACKAGE)/Library/PeiDxeSmmMmPciLib/PeiDxeS
> mmMmPciLib.inf
> 
> PchHsioLib|$(PLATFORM_SI_PACKAGE)/Pch/Library/PeiDxeSmmPchHsioLib/Pe
> iDxeSmmPchHsioLib.inf
> 
> PchPmcLib|$(PLATFORM_SI_PACKAGE)/Pch/Library/PeiDxeSmmPchPmcLib/Pei
> DxeSmmPchPmcLib.inf
> --
> 2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50414): https://edk2.groups.io/g/devel/message/50414
Mute This Topic: https://groups.io/mt/53691089/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms: PATCH] MinPlatformPkg: Add SetCacheMtrrLib class to dsc.

2019-11-11 Thread Kubacki, Michael A
Reviewed-by: Michael Kubacki 

> -Original Message-
> From: Chiu, Chasel 
> Sent: Monday, November 11, 2019 7:26 PM
> To: devel@edk2.groups.io
> Cc: Kubacki, Michael A ; Desimone, Nathaniel
> L ; Gao, Liming 
> Subject: [edk2-platforms: PATCH] MinPlatformPkg: Add SetCacheMtrrLib
> class to dsc.
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2314
> 
> Fixed typo issue in MinPlatformPkg.dsc caused by previous commit.
> 
> Cc: Michael Kubacki 
> Cc: Nate DeSimone 
> Cc: Liming Gao 
> Signed-off-by: Chasel Chiu 
> ---
>  Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
> b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
> index 17272f819c..038f05be92 100644
> --- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
> +++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
> @@ -94,7 +94,7 @@
> 
> ReportFvLib|MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiReport
> FvLib.inf
> 
> TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/PeiTest
> PointCheckLib.inf
>TestPointLib|MinPlatformPkg/Test/Library/TestPointLib/PeiTestPointLib.inf
> -
> SetCacheMtrrLib|$(PLATFORM_PACKAGE)/Library/SetCacheMtrrLib/SetCac
> heMtrrLibNull.inf
> +
> +
> SetCacheMtrrLib|MinPlatformPkg/Library/SetCacheMtrrLib/SetCacheMtrrLi
> b
> + Null.inf
> 
>  [LibraryClasses.common.DXE_DRIVER]
>#
> --
> 2.13.3.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50416): https://edk2.groups.io/g/devel/message/50416
Mute This Topic: https://groups.io/mt/47032665/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] EmulatorPkg/PlatformSmbiosDxe: fix a spell error of platform.

2019-11-11 Thread Ni, Ray
Thanks for your contribution.

Reviewed-by: Ray Ni 


> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Tan,
> Ming
> Sent: Monday, November 11, 2019 3:19 PM
> To: devel@edk2.groups.io
> Subject: [edk2-devel] [PATCH] EmulatorPkg/PlatformSmbiosDxe: fix a spell
> error of platform.
> 
> Old code use platfomr.
> Change PlatfomrSmbiosDriverEntryPoint to PlatformSmbiosDriverEntryPoint.
> 
> Signed-off-by: Ming Tan 
> ---
>  EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c   | 2 +-
>  EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
> b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
> index e6f8734600..48a3bfb5e9 100644
> --- a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
> +++ b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
> @@ -82,7 +82,7 @@ CreatePlatformSmbiosMemoryRecords (
>  **/
> 
>  EFI_STATUS
> 
>  EFIAPI
> 
> -PlatfomrSmbiosDriverEntryPoint (
> 
> +PlatformSmbiosDriverEntryPoint (
> 
>IN EFI_HANDLE ImageHandle,
> 
>IN EFI_SYSTEM_TABLE   *SystemTable
> 
>)
> 
> diff --git a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
> b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
> index 95b119e953..756f643c74 100644
> --- a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
> +++ b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
> @@ -15,7 +15,7 @@
>FILE_GUID  = 67FA951E-4FA2-9F4E-A658-4DBD954AC22E
> 
>MODULE_TYPE= DXE_DRIVER
> 
>VERSION_STRING = 1.0
> 
> -  ENTRY_POINT= PlatfomrSmbiosDriverEntryPoint
> 
> +  ENTRY_POINT= PlatformSmbiosDriverEntryPoint
> 
> 
> 
> 
> 
>  [Sources]
> 
> --
> 2.23.0.windows.1
> 
> 
> -=-=-=-=-=-=
> Groups.io Links: You receive all messages sent to this group.
> 
> View/Reply Online (#50335): https://edk2.groups.io/g/devel/message/50335
> Mute This Topic: https://groups.io/mt/52449861/1712937
> Group Owner: devel+ow...@edk2.groups.io
> Unsubscribe: https://edk2.groups.io/g/devel/unsub  [ray...@intel.com]
> -=-=-=-=-=-=


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50412): https://edk2.groups.io/g/devel/message/50412
Mute This Topic: https://groups.io/mt/52449861/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Ni, Ray
And LLVM I believe is capable to support generating PE + DWARF.
That's my second concern: Using CLANGPE may not imply PDB is used from a LLVM 
expert's understanding.


> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Ni, Ray
> Sent: Tuesday, November 12, 2019 11:10 AM
> To: devel@edk2.groups.io; Ni, Ray ; Gao, Liming
> ; af...@apple.com; Leif Lindholm
> 
> Cc: Justen, Jordan L ; Shi, Steven
> 
> Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
> chain
> 
> My point is if we choose CLANGPE, for LLVM toolchain supporting DWARF
> debug symbol, there is no proper name left: we cannot use CLANGELF.
> 
> Andrew, you said CLANGPDE. A typo?
> 
> > -Original Message-
> > From: devel@edk2.groups.io  On Behalf Of Ni,
> Ray
> > Sent: Tuesday, November 12, 2019 9:46 AM
> > To: Gao, Liming ; devel@edk2.groups.io;
> > af...@apple.com; Leif Lindholm 
> > Cc: Justen, Jordan L ; Shi, Steven
> > 
> > Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9
> > tool chain
> >
> > Liming,
> > What name will be chosen when in future someone wants a LLVM
> toolchain
> > which supports DWARF debug symbol?
> >
> >
> > > -Original Message-
> > > From: Gao, Liming 
> > > Sent: Tuesday, November 12, 2019 8:41 AM
> > > To: devel@edk2.groups.io; af...@apple.com; Leif Lindholm
> > > 
> > > Cc: Ni, Ray ; Justen, Jordan L
> > > ; Shi, Steven ;
> > > Gao, Liming 
> > > Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable
> > > CLANG9 tool chain
> > >
> > > Thanks for your feedback. I will choose CLANGPE as the tool chain name.
> > >
> > > Thanks
> > > Liming
> > > >-Original Message-
> > > >From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf
> > > >Of Andrew Fish via Groups.Io
> > > >Sent: Tuesday, November 12, 2019 12:52 AM
> > > >To: Leif Lindholm 
> > > >Cc: Ni, Ray ; Gao, Liming ;
> > > >devel@edk2.groups.io; Justen, Jordan L ;
> > > >Shi, Steven 
> > > >Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable
> > > >CLANG9 tool chain
> > > >
> > > >Either works for me too. I like the PDE ending a little more, but
> > > >agree it is a little more obscure.
> > > >> On Nov 11, 2019, at 8:39 AM, Leif Lindholm
> > > >> 
> > > wrote:
> > > >>
> > > >> On Fri, Nov 08, 2019 at 03:34:59AM +, Ni, Ray wrote:
> > > >>> Liming,
> > > >>> PE is UEFI spec required executable binary format. I like
> > > >>> CLANGPDB more than CLANGPE given LLVM may generate DRAWF
> debug
> > > >>> symbol
> > > >even
> > > >>> when generating PE.
> > > >>
> > > >> Just a comment here to point out that while (as I stated in reply
> > > >> to
> > > >> Liming) my preference would be CLANGPE, I see the logic in the
> > > >> above, and would be happy with either.
> > > >>
> > > >> (My reason for preferring CLANGPE is not exactly techincal - I
> > > >> just expect more people to know what PE is than who know what PDB
> > > >> is.)
> > > >>
> > > >> Regards,
> > > >>
> > > >> Leif
> > > >>
> > >  -Original Message-
> > >  From: Gao, Liming 
> > >  Sent: Friday, November 8, 2019 9:50 AM
> > >  To: devel@edk2.groups.io; leif.lindh...@linaro.org; Andrew Fish
> > > >
> > >  Cc: Ni, Ray ; Justen, Jordan L
> > > >; Gao, Liming ;
> > > >Shi,
> > >  Steven 
> > >  Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable
> > >  CLANG9
> > > >tool chain
> > > 
> > >  Andrew and Leif:
> > >   Thanks for your comment. CLANG9 is different from CLANG38.
> > >  And,
> > > >CLANG9 will support LLVM9 or the above.
> > >   So, this tool chain should have the specific word for its
> > >  purpose, and
> > > >remove the version 9 to avoid the confuse.
> > > 
> > >   I prefer the tool chain name as CLANGPE or CLANGPDB. CLANGPE
> > may
> > > >be better. Now, CLANG9 tool chain
> > >   build rule family just uses CLANGPE. CLANGPE lets user know
> > >  this tool
> > > >chain generates PE/COFF image.
> > >   And, PE/COFF image debug symbol is PDB. So, PE also means PDB.
> > > 
> > >   Last, I just review the changes. Tool chain name update is not
> > >  big. If you
> > > >accept CLANGPE as tool chain name,
> > >   I will send the patch soon to catch 201911 stable tag.
> > > 
> > >  Thanks
> > >  Liming
> > > > -Original Message-
> > > > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On
> > > Behalf
> > > >Of Leif
> > > > Lindholm
> > > > Sent: Friday, November 08, 2019 2:37 AM
> > > > To: Andrew Fish 
> > > > Cc: devel@edk2.groups.io; Gao, Liming ;
> > > > Ni, Ray ; Justen, Jordan L
> > > > 
> > > > Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable
> > > > CLANG9
> > > >tool
> > > > chain
> > > >
> > > > Hi Andrew,
> > > >
> > > > Yeah, I'm pretty easy with regards to what we change it to.
> > > > Although if we're bikeshedding, I would prefer not using _ in
> > > > 

[edk2-devel] [edk2-platforms: PATCH] MinPlatformPkg: Add SetCacheMtrrLib class to dsc.

2019-11-11 Thread Chiu, Chasel
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2314

Fixed typo issue in MinPlatformPkg.dsc caused by previous
commit.

Cc: Michael Kubacki 
Cc: Nate DeSimone 
Cc: Liming Gao 
Signed-off-by: Chasel Chiu 
---
 Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc 
b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
index 17272f819c..038f05be92 100644
--- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
+++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
@@ -94,7 +94,7 @@
   
ReportFvLib|MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiReportFvLib.inf
   
TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/PeiTestPointCheckLib.inf
   TestPointLib|MinPlatformPkg/Test/Library/TestPointLib/PeiTestPointLib.inf
-  
SetCacheMtrrLib|$(PLATFORM_PACKAGE)/Library/SetCacheMtrrLib/SetCacheMtrrLibNull.inf
+  
SetCacheMtrrLib|MinPlatformPkg/Library/SetCacheMtrrLib/SetCacheMtrrLibNull.inf
 
 [LibraryClasses.common.DXE_DRIVER]
   #
-- 
2.13.3.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50410): https://edk2.groups.io/g/devel/message/50410
Mute This Topic: https://groups.io/mt/47032665/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch 1/1] BaseTools: Enable MACRO for DSC Components section tag

2019-11-11 Thread Liming Gao
Reviewed-by: Liming Gao 

>-Original Message-
>From: Feng, Bob C
>Sent: Tuesday, November 12, 2019 10:04 AM
>To: devel@edk2.groups.io
>Cc: Gao, Liming ; Feng, Bob C 
>Subject: [Patch 1/1] BaseTools: Enable MACRO for DSC Components section
>tag
>
>BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2308
>
>This patch is to enable MACRO for Components section architecture
>modifier.
>
>Cc: Liming Gao 
>Signed-off-by: Bob Feng 
>---
> BaseTools/Source/Python/Workspace/MetaFileParser.py | 1 +
> 1 file changed, 1 insertion(+)
>
>diff --git a/BaseTools/Source/Python/Workspace/MetaFileParser.py
>b/BaseTools/Source/Python/Workspace/MetaFileParser.py
>index 806fc322c56c..0a131fc76981 100644
>--- a/BaseTools/Source/Python/Workspace/MetaFileParser.py
>+++ b/BaseTools/Source/Python/Workspace/MetaFileParser.py
>@@ -326,10 +326,11 @@ class MetaFileParser(object):
> # S1 is always Arch
> if len(ItemList) > 1:
> S1 = ItemList[1].upper()
> else:
> S1 = TAB_ARCH_COMMON
>+S1 = ReplaceMacro(S1, self._Macros)
> ArchList.add(S1)
>
> # S2 may be Platform or ModuleType
> if len(ItemList) > 2:
> if self._SectionName.upper() in SECTIONS_HAVE_ITEM_PCD_SET:
>--
>2.20.1.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50409): https://edk2.groups.io/g/devel/message/50409
Mute This Topic: https://groups.io/mt/53630839/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Ni, Ray
My point is if we choose CLANGPE, for LLVM toolchain supporting DWARF debug 
symbol,
there is no proper name left: we cannot use CLANGELF.

Andrew, you said CLANGPDE. A typo?

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Ni, Ray
> Sent: Tuesday, November 12, 2019 9:46 AM
> To: Gao, Liming ; devel@edk2.groups.io;
> af...@apple.com; Leif Lindholm 
> Cc: Justen, Jordan L ; Shi, Steven
> 
> Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
> chain
> 
> Liming,
> What name will be chosen when in future someone wants a LLVM toolchain
> which supports DWARF debug symbol?
> 
> 
> > -Original Message-
> > From: Gao, Liming 
> > Sent: Tuesday, November 12, 2019 8:41 AM
> > To: devel@edk2.groups.io; af...@apple.com; Leif Lindholm
> > 
> > Cc: Ni, Ray ; Justen, Jordan L
> > ; Shi, Steven ; Gao,
> > Liming 
> > Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9
> > tool chain
> >
> > Thanks for your feedback. I will choose CLANGPE as the tool chain name.
> >
> > Thanks
> > Liming
> > >-Original Message-
> > >From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> > >Andrew Fish via Groups.Io
> > >Sent: Tuesday, November 12, 2019 12:52 AM
> > >To: Leif Lindholm 
> > >Cc: Ni, Ray ; Gao, Liming ;
> > >devel@edk2.groups.io; Justen, Jordan L ;
> > >Shi, Steven 
> > >Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9
> > >tool chain
> > >
> > >Either works for me too. I like the PDE ending a little more, but
> > >agree it is a little more obscure.
> > >> On Nov 11, 2019, at 8:39 AM, Leif Lindholm
> > >> 
> > wrote:
> > >>
> > >> On Fri, Nov 08, 2019 at 03:34:59AM +, Ni, Ray wrote:
> > >>> Liming,
> > >>> PE is UEFI spec required executable binary format. I like CLANGPDB
> > >>> more than CLANGPE given LLVM may generate DRAWF debug symbol
> > >even
> > >>> when generating PE.
> > >>
> > >> Just a comment here to point out that while (as I stated in reply
> > >> to
> > >> Liming) my preference would be CLANGPE, I see the logic in the
> > >> above, and would be happy with either.
> > >>
> > >> (My reason for preferring CLANGPE is not exactly techincal - I just
> > >> expect more people to know what PE is than who know what PDB is.)
> > >>
> > >> Regards,
> > >>
> > >> Leif
> > >>
> >  -Original Message-
> >  From: Gao, Liming 
> >  Sent: Friday, November 8, 2019 9:50 AM
> >  To: devel@edk2.groups.io; leif.lindh...@linaro.org; Andrew Fish
> > >
> >  Cc: Ni, Ray ; Justen, Jordan L
> > >; Gao, Liming ; Shi,
> >  Steven 
> >  Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable
> >  CLANG9
> > >tool chain
> > 
> >  Andrew and Leif:
> >   Thanks for your comment. CLANG9 is different from CLANG38. And,
> > >CLANG9 will support LLVM9 or the above.
> >   So, this tool chain should have the specific word for its
> >  purpose, and
> > >remove the version 9 to avoid the confuse.
> > 
> >   I prefer the tool chain name as CLANGPE or CLANGPDB. CLANGPE
> may
> > >be better. Now, CLANG9 tool chain
> >   build rule family just uses CLANGPE. CLANGPE lets user know this
> >  tool
> > >chain generates PE/COFF image.
> >   And, PE/COFF image debug symbol is PDB. So, PE also means PDB.
> > 
> >   Last, I just review the changes. Tool chain name update is not
> >  big. If you
> > >accept CLANGPE as tool chain name,
> >   I will send the patch soon to catch 201911 stable tag.
> > 
> >  Thanks
> >  Liming
> > > -Original Message-
> > > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On
> > Behalf
> > >Of Leif
> > > Lindholm
> > > Sent: Friday, November 08, 2019 2:37 AM
> > > To: Andrew Fish 
> > > Cc: devel@edk2.groups.io; Gao, Liming ;
> > > Ni, Ray ; Justen, Jordan L
> > > 
> > > Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable
> > > CLANG9
> > >tool
> > > chain
> > >
> > > Hi Andrew,
> > >
> > > Yeah, I'm pretty easy with regards to what we change it to.
> > > Although if we're bikeshedding, I would prefer not using _ in
> > > the toolchain profile name.
> > >
> > > I'm ... optimistic ... it won't break any of my existing
> > > scripts, but since the build system uses it as a  > > profile>__ separator, it would be
> > > profile>nice
> > > if we didn't risk confusion there.
> > >
> > > (I would be totally happy with PECLANG, CLANGPE, PDBCLANG,
> > >CLANGPDB or
> > > something along those lines.)
> > >
> > > Regards,
> > >
> > > Leif
> > >
> > > On Thu, Nov 07, 2019 at 11:54:04AM -0600, Andrew Fish wrote:
> > >> Leif,
> > >>
> > >> I think I proposed CLANG_PDB or CLANG_PECOFF. I seem to like
> > > CLANG_PDB as assuming the PDE debugging experience is
> > >awesome/exists
> > > on Linux and macOS is not a given.
> > >>
> > >> 

[edk2-devel] [PATCH 1/1] MdePkg/Include: Add missing definitions of SMBIOS type 42h in SmBios.h

2019-11-11 Thread Abner Chang
Add host interface Protocol Type Data Format structure in SmBios.h

BZ link,
https://bugzilla.tianocore.org/show_bug.cgi?id=2328

Signed-off-by: Abner Chang 

Cc: Michael D Kinney 
Cc: Liming Gao 
Signed-off-by: Abner Chang 
---
 MdePkg/Include/IndustryStandard/SmBios.h | 9 +
 1 file changed, 9 insertions(+)

diff --git a/MdePkg/Include/IndustryStandard/SmBios.h 
b/MdePkg/Include/IndustryStandard/SmBios.h
index f504cc84e7..c0144c9c8f 100644
--- a/MdePkg/Include/IndustryStandard/SmBios.h
+++ b/MdePkg/Include/IndustryStandard/SmBios.h
@@ -2483,6 +2483,15 @@ typedef struct {
   UINT8 DevFuncNum;
 } SMBIOS_TABLE_TYPE41;
 
+///
+///  Management Controller Host Interface - Protocol Record Data Format.
+///
+typedef struct {
+  UINT8ProtocolType;
+  UINT8ProtocolTypeDataLen;
+  UINT8ProtocolTypeData[1];
+} MC_HOST_INTERFACE_PROTOCOL_RECORD;
+
 ///
 /// Management Controller Host Interface - Interface Types.
 /// 00h - 3Fh: MCTP Host Interfaces
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50406): https://edk2.groups.io/g/devel/message/50406
Mute This Topic: https://groups.io/mt/53725511/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] EDK II Maintainers - EDK II CI is now active on edk2/master

2019-11-11 Thread Michael D Kinney
EDK II Maintainers,

EDK II CI Phase 1 feature is now active on edk2/master.

Please use a GitHub pull request from a branch in a personal
fork of the edk2 repository with a 'push' label to request
a set of patches to be pushed to edk2/master.  The GitHub PR
replaces the 'git push' operation currently used to commit
changes to edk2/master.

You will need to configure your notifications from the edk2
repository to make sure you receive email notifications
when the checks against the GitHub PR passes or fails.

If you submit a GitHub Pull Request without the 'push'
label, then the CI checks are run and the results are
generated.

Please let us know if there are any questions about this
change in the development process.

Best regards,

Mike

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50407): https://edk2.groups.io/g/devel/message/50407
Mute This Topic: https://groups.io/mt/53725670/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][PATCH V1 2/3] KabylakeOpenBoardPkg/KabylakeRvp3: Update BaseConfigBlockLib package

2019-11-11 Thread Nate DeSimone
Reviewed-by: Nate DeSimone 

-Original Message-
From: Kubacki, Michael A  
Sent: Monday, November 11, 2019 6:39 PM
To: devel@edk2.groups.io
Cc: Chiu, Chasel ; Desimone, Nathaniel L 

Subject: [edk2-platforms][PATCH V1 2/3] KabylakeOpenBoardPkg/KabylakeRvp3: 
Update BaseConfigBlockLib package

Updates the silicon package for the BaseConfigBlockLib instance from 
KabylakeSiliconPkg to IntelSiliconPkg to align with the change made in commit 
f0e29f87ad.

Cc: Chasel Chiu 
Cc: Nate DeSimone 
Signed-off-by: Michael Kubacki 
---
 Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc 
b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
index 47529a7945..1ce473432a 100644
--- a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
+++ b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
@@ -132,7 +132,7 @@
   ###
   # Silicon Initialization Package
   ###
-  
ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
+
+ ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBl
+ ockLib.inf
   
SiliconInitLib|$(PLATFORM_SI_PACKAGE)/Library/SiliconInitLib/SiliconInitLib.inf
 
 !if gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection == 1
--
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50404): https://edk2.groups.io/g/devel/message/50404
Mute This Topic: https://groups.io/mt/53690876/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][PATCH V1 1/3] KabylakeOpenBoardPkg/GalagoPro3: Update BaseConfigBlockLib package

2019-11-11 Thread Nate DeSimone
Reviewed-by: Nate DeSimone 

-Original Message-
From: Kubacki, Michael A  
Sent: Monday, November 11, 2019 6:39 PM
To: devel@edk2.groups.io
Cc: Chiu, Chasel ; Desimone, Nathaniel L 

Subject: [edk2-platforms][PATCH V1 1/3] KabylakeOpenBoardPkg/GalagoPro3: Update 
BaseConfigBlockLib package

Updates the silicon package for the BaseConfigBlockLib instance from 
KabylakeSiliconPkg to IntelSiliconPkg to align with the change made in commit 
f0e29f87ad.

Cc: Chasel Chiu 
Cc: Nate DeSimone 
Signed-off-by: Michael Kubacki 
---
 Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc 
b/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
index 3c0ae9dfbd..e43c944201 100644
--- a/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
+++ b/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
@@ -104,7 +104,7 @@
   ###
   # Silicon Initialization Package
   ###
-  
ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
+
+ ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBl
+ ockLib.inf
   
SiliconInitLib|$(PLATFORM_SI_PACKAGE)/Library/SiliconInitLib/SiliconInitLib.inf
   
SiliconPolicyInitLib|$(PLATFORM_SI_PACKAGE)/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFsp.inf
 
--
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50403): https://edk2.groups.io/g/devel/message/50403
Mute This Topic: https://groups.io/mt/53690700/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][PATCH V1 3/3] WhiskeylakeURvp: Update BaseConfigBlockLib package

2019-11-11 Thread Nate DeSimone
Reviewed-by: Nate DeSimone 

-Original Message-
From: devel@edk2.groups.io  On Behalf Of Kubacki, Michael 
A
Sent: Monday, November 11, 2019 6:39 PM
To: devel@edk2.groups.io
Cc: Chiu, Chasel ; Desimone, Nathaniel L 

Subject: [edk2-devel] [edk2-platforms][PATCH V1 3/3] WhiskeylakeURvp: Update 
BaseConfigBlockLib package

Updates the silicon package for the BaseConfigBlockLib instance from 
CoffeelakeSiliconPkg to IntelSiliconPkg to align with the change made in commit 
f0e29f87ad.

Cc: Chasel Chiu 
Cc: Nate DeSimone 
Signed-off-by: Michael Kubacki 
---
 Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc 
b/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc
index 8a9245f7a6..cdaf47b6f7 100644
--- a/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc
+++ b/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPk
+++ g.dsc
@@ -103,7 +103,7 @@
   ###
   # Silicon Initialization Package
   ###
-  
ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
+
+ ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBl
+ ockLib.inf
   
MmPciLib|$(PLATFORM_SI_PACKAGE)/Library/PeiDxeSmmMmPciLib/PeiDxeSmmMmPciLib.inf
   
PchHsioLib|$(PLATFORM_SI_PACKAGE)/Pch/Library/PeiDxeSmmPchHsioLib/PeiDxeSmmPchHsioLib.inf
   
PchPmcLib|$(PLATFORM_SI_PACKAGE)/Pch/Library/PeiDxeSmmPchPmcLib/PeiDxeSmmPchPmcLib.inf
--
2.16.2.windows.1





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50405): https://edk2.groups.io/g/devel/message/50405
Mute This Topic: https://groups.io/mt/53691089/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [edk2-platforms][PATCH V1 3/3] WhiskeylakeURvp: Update BaseConfigBlockLib package

2019-11-11 Thread Kubacki, Michael A
Updates the silicon package for the BaseConfigBlockLib instance from
CoffeelakeSiliconPkg to IntelSiliconPkg to align with the change
made in commit f0e29f87ad.

Cc: Chasel Chiu 
Cc: Nate DeSimone 
Signed-off-by: Michael Kubacki 
---
 Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc 
b/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc
index 8a9245f7a6..cdaf47b6f7 100644
--- a/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc
+++ b/Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc
@@ -103,7 +103,7 @@
   ###
   # Silicon Initialization Package
   ###
-  
ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
+  
ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
   
MmPciLib|$(PLATFORM_SI_PACKAGE)/Library/PeiDxeSmmMmPciLib/PeiDxeSmmMmPciLib.inf
   
PchHsioLib|$(PLATFORM_SI_PACKAGE)/Pch/Library/PeiDxeSmmPchHsioLib/PeiDxeSmmPchHsioLib.inf
   
PchPmcLib|$(PLATFORM_SI_PACKAGE)/Pch/Library/PeiDxeSmmPchPmcLib/PeiDxeSmmPchPmcLib.inf
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50402): https://edk2.groups.io/g/devel/message/50402
Mute This Topic: https://groups.io/mt/53691089/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [edk2-platforms][PATCH V1 2/3] KabylakeOpenBoardPkg/KabylakeRvp3: Update BaseConfigBlockLib package

2019-11-11 Thread Kubacki, Michael A
Updates the silicon package for the BaseConfigBlockLib instance from
KabylakeSiliconPkg to IntelSiliconPkg to align with the change made
in commit f0e29f87ad.

Cc: Chasel Chiu 
Cc: Nate DeSimone 
Signed-off-by: Michael Kubacki 
---
 Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc 
b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
index 47529a7945..1ce473432a 100644
--- a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
+++ b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
@@ -132,7 +132,7 @@
   ###
   # Silicon Initialization Package
   ###
-  
ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
+  
ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
   
SiliconInitLib|$(PLATFORM_SI_PACKAGE)/Library/SiliconInitLib/SiliconInitLib.inf
 
 !if gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection == 1
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50401): https://edk2.groups.io/g/devel/message/50401
Mute This Topic: https://groups.io/mt/53690876/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [edk2-platforms][PATCH V1 1/3] KabylakeOpenBoardPkg/GalagoPro3: Update BaseConfigBlockLib package

2019-11-11 Thread Kubacki, Michael A
Updates the silicon package for the BaseConfigBlockLib instance from
KabylakeSiliconPkg to IntelSiliconPkg to align with the change made
in commit f0e29f87ad.

Cc: Chasel Chiu 
Cc: Nate DeSimone 
Signed-off-by: Michael Kubacki 
---
 Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc 
b/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
index 3c0ae9dfbd..e43c944201 100644
--- a/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
+++ b/Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc
@@ -104,7 +104,7 @@
   ###
   # Silicon Initialization Package
   ###
-  
ConfigBlockLib|$(PLATFORM_SI_PACKAGE)/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
+  
ConfigBlockLib|IntelSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf
   
SiliconInitLib|$(PLATFORM_SI_PACKAGE)/Library/SiliconInitLib/SiliconInitLib.inf
   
SiliconPolicyInitLib|$(PLATFORM_SI_PACKAGE)/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFsp.inf
 
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50400): https://edk2.groups.io/g/devel/message/50400
Mute This Topic: https://groups.io/mt/53690700/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [edk2-platforms][PATCH V1 0/3] Update BaseConfigBlockLib package

2019-11-11 Thread Kubacki, Michael A
Commit f0e29f87ad consolidated the BaseConfigBlockLib library
instances to a single copy in IntelSiliconPkg. The pre-existing
instances in KabylakeSiliconPkg and CoffeelakeSiliconPkg were
removed. That commit did not update board packages dependent
on the library to use the single instance in IntelSiliconPkg.

This patch series updates the affected board packages to use the
instance in IntelSiliconPkg.

Cc: Chasel Chiu 
Cc: Nate DeSimone 
Signed-off-by: Michael Kubacki 

Michael Kubacki (3):
  KabylakeOpenBoardPkg/GalagoPro3: Update BaseConfigBlockLib package
  KabylakeOpenBoardPkg/KabylakeRvp3: Update BaseConfigBlockLib package
  WhiskeylakeURvp: Update BaseConfigBlockLib package

 Platform/Intel/KabylakeOpenBoardPkg/GalagoPro3/OpenBoardPkg.dsc | 2 +-
 Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc   | 2 +-
 Platform/Intel/WhiskeylakeOpenBoardPkg/WhiskeylakeURvp/OpenBoardPkg.dsc | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50399): https://edk2.groups.io/g/devel/message/50399
Mute This Topic: https://groups.io/mt/53690501/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch V3] IntelSiliconPkg/Library:Add BaseConfigBlockLib Library

2019-11-11 Thread Kubacki, Michael A
This was committed and broke the build for almost all board packages that 
consume this library:
  * KabylakeOpenBoardPkg/GalagoPro3
  * KabylakeOpenBoardPkg/KabylakeRvp3
  * WhiskeylakeOpenBoardPkg/WhiskeylakeURvp

I am surprised that this patch series was approved with no thought to package 
DSC file changes
Needed for library consumers. I will submit a patch in the affected board 
packages in edk2-platforms
but please check impact more carefully in the future.

Thanks,
Michael

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Ni, Ray
> Sent: Monday, November 11, 2019 12:00 AM
> To: Tsao, Ethan ; devel@edk2.groups.io
> Cc: Chaganty, Rangasai V 
> Subject: Re: [edk2-devel] [Patch V3] IntelSiliconPkg/Library:Add
> BaseConfigBlockLib Library
> 
> Reviewed-by: Ray Ni 
> 
> > -Original Message-
> > From: Tsao, Ethan 
> > Sent: Monday, November 11, 2019 2:05 PM
> > To: devel@edk2.groups.io
> > Cc: Chaganty, Rangasai V ; Ni, Ray
> > 
> > Subject: [Patch V3] IntelSiliconPkg/Library:Add BaseConfigBlockLib
> > Library
> >
> > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2318
> >
> > Establish one copy of Config blocks library class and instance in
> > IntelSiliconPkg and remove copies from other silicon packages , like
> > KabyLakeSiliconPkg, CoffelakeSiliconPkg.
> >
> > Signed-off-by: Ethan Tsao 
> > Cc: Sai Chaganty 
> > Cc: Ray Ni 
> > ---
> >
> >
> Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBlo
> > ckLib.c  | 146 
> > ---
> ---
> > --
> > --
> >
> >
> Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseConfigBlockLib/BaseConfigBlo
> > ckLib.inf|  29 -
> >  Silicon/Intel/{KabylakeSiliconPkg =>
> > IntelSiliconPkg}/Library/BaseConfigBlockLib/BaseConfigBlockLib.c   |  10 ++-
> --
> > -
> >  Silicon/Intel/{KabylakeSiliconPkg =>
> > IntelSiliconPkg}/Library/BaseConfigBlockLib/BaseConfigBlockLib.inf |   0
> >  4 files changed, 2 insertions(+), 183 deletions(-)
> >
> > diff --git
> > a/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseConfigBlockLib/BaseCo
> > nfigB
> > lockLib.c
> > b/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseConfigBlockLib/BaseCo
> > nfig
> > BlockLib.c
> > deleted file mode 100644
> > index 369dab97ee..00
> > ---
> > a/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseConfigBlockLib/BaseCo
> > nfigB
> > lockLib.c
> > +++ /dev/null
> > @@ -1,146 +0,0 @@
> > -/** @file
> > -  Library functions for Config Block management.
> > -
> > -  Copyright (c) 2019 Intel Corporation. All rights reserved. 
> > -
> > -  SPDX-License-Identifier: BSD-2-Clause-Patent -**/
> > -
> > -#include 
> > -#include 
> > -#include 
> > -#include  -#include
> > 
> > -
> > -/**
> > -  Create config block table
> > -
> > -  @param[in] TotalSize- Max size to be allocated 
> > for the Config
> > Block Table
> > -  @param[out]ConfigBlockTableAddress  - On return, points to a
> pointer
> > to the beginning of Config Block Table Address
> > -
> > -  @retval EFI_INVALID_PARAMETER - Invalid Parameter
> > -  @retval EFI_OUT_OF_RESOURCES  - Out of resources
> > -  @retval EFI_SUCCESS   - Successfully created Config Block Table 
> > at
> > ConfigBlockTableAddress
> > -**/
> > -EFI_STATUS
> > -EFIAPI
> > -CreateConfigBlockTable (
> > -  IN UINT16TotalSize,
> > -  OUTVOID  **ConfigBlockTableAddress
> > -  )
> > -{
> > -  CONFIG_BLOCK_TABLE_HEADER *ConfigBlkTblAddrPtr;
> > -  UINT32ConfigBlkTblHdrSize;
> > -
> > -  ConfigBlkTblHdrSize = (UINT32)(sizeof
> (CONFIG_BLOCK_TABLE_HEADER));
> > -
> > -  if (TotalSize <= (ConfigBlkTblHdrSize + sizeof (CONFIG_BLOCK_HEADER)))
> {
> > -DEBUG ((DEBUG_ERROR, "Invalid Parameter\n"));
> > -return EFI_INVALID_PARAMETER;
> > -  }
> > -
> > -  ConfigBlkTblAddrPtr = (CONFIG_BLOCK_TABLE_HEADER
> *)AllocateZeroPool
> > (TotalSize);
> > -  if (ConfigBlkTblAddrPtr == NULL) {
> > -DEBUG ((DEBUG_ERROR, "Could not allocate memory.\n"));
> > -return EFI_OUT_OF_RESOURCES;
> > -  }
> > -  ConfigBlkTblAddrPtr->NumberOfBlocks = 0;
> > -  ConfigBlkTblAddrPtr->Header.GuidHob.Header.HobLength = TotalSize;
> > -  ConfigBlkTblAddrPtr->AvailableSize = TotalSize -
> > ConfigBlkTblHdrSize;
> > -
> > -  *ConfigBlockTableAddress = (VOID *)ConfigBlkTblAddrPtr;
> > -
> > -  return EFI_SUCCESS;
> > -}
> > -
> > -/**
> > -  Add config block into config block table structure
> > -
> > -  @param[in] ConfigBlockTableAddress  - A pointer to the beginning 
> > of
> > Config Block Table Address
> > -  @param[out]ConfigBlockAddress   - On return, points to a 
> > pointer
> to
> > the beginning of Config Block Address
> > -
> > -  @retval EFI_OUT_OF_RESOURCES - Config Block Table is full and
> > cannot add new Config Block or
> > -

[edk2-devel] [Patch 1/1] BaseTools: Enable MACRO for DSC Components section tag

2019-11-11 Thread Bob Feng
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2308

This patch is to enable MACRO for Components section architecture
modifier.

Cc: Liming Gao 
Signed-off-by: Bob Feng 
---
 BaseTools/Source/Python/Workspace/MetaFileParser.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/BaseTools/Source/Python/Workspace/MetaFileParser.py 
b/BaseTools/Source/Python/Workspace/MetaFileParser.py
index 806fc322c56c..0a131fc76981 100644
--- a/BaseTools/Source/Python/Workspace/MetaFileParser.py
+++ b/BaseTools/Source/Python/Workspace/MetaFileParser.py
@@ -326,10 +326,11 @@ class MetaFileParser(object):
 # S1 is always Arch
 if len(ItemList) > 1:
 S1 = ItemList[1].upper()
 else:
 S1 = TAB_ARCH_COMMON
+S1 = ReplaceMacro(S1, self._Macros)
 ArchList.add(S1)
 
 # S2 may be Platform or ModuleType
 if len(ItemList) > 2:
 if self._SectionName.upper() in SECTIONS_HAVE_ITEM_PCD_SET:
-- 
2.20.1.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50397): https://edk2.groups.io/g/devel/message/50397
Mute This Topic: https://groups.io/mt/53630839/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Ni, Ray
Liming,
What name will be chosen when in future someone wants a LLVM toolchain which
supports DWARF debug symbol?


> -Original Message-
> From: Gao, Liming 
> Sent: Tuesday, November 12, 2019 8:41 AM
> To: devel@edk2.groups.io; af...@apple.com; Leif Lindholm
> 
> Cc: Ni, Ray ; Justen, Jordan L ;
> Shi, Steven ; Gao, Liming 
> Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
> chain
> 
> Thanks for your feedback. I will choose CLANGPE as the tool chain name.
> 
> Thanks
> Liming
> >-Original Message-
> >From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> >Andrew Fish via Groups.Io
> >Sent: Tuesday, November 12, 2019 12:52 AM
> >To: Leif Lindholm 
> >Cc: Ni, Ray ; Gao, Liming ;
> >devel@edk2.groups.io; Justen, Jordan L ;
> >Shi, Steven 
> >Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9
> >tool chain
> >
> >Either works for me too. I like the PDE ending a little more, but agree
> >it is a little more obscure.
> >> On Nov 11, 2019, at 8:39 AM, Leif Lindholm 
> wrote:
> >>
> >> On Fri, Nov 08, 2019 at 03:34:59AM +, Ni, Ray wrote:
> >>> Liming,
> >>> PE is UEFI spec required executable binary format. I like CLANGPDB
> >>> more than CLANGPE given LLVM may generate DRAWF debug symbol
> >even
> >>> when generating PE.
> >>
> >> Just a comment here to point out that while (as I stated in reply to
> >> Liming) my preference would be CLANGPE, I see the logic in the above,
> >> and would be happy with either.
> >>
> >> (My reason for preferring CLANGPE is not exactly techincal - I just
> >> expect more people to know what PE is than who know what PDB is.)
> >>
> >> Regards,
> >>
> >> Leif
> >>
>  -Original Message-
>  From: Gao, Liming 
>  Sent: Friday, November 8, 2019 9:50 AM
>  To: devel@edk2.groups.io; leif.lindh...@linaro.org; Andrew Fish
> >
>  Cc: Ni, Ray ; Justen, Jordan L
> >; Gao, Liming ; Shi,
>  Steven 
>  Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable
>  CLANG9
> >tool chain
> 
>  Andrew and Leif:
>   Thanks for your comment. CLANG9 is different from CLANG38. And,
> >CLANG9 will support LLVM9 or the above.
>   So, this tool chain should have the specific word for its purpose,
>  and
> >remove the version 9 to avoid the confuse.
> 
>   I prefer the tool chain name as CLANGPE or CLANGPDB. CLANGPE may
> >be better. Now, CLANG9 tool chain
>   build rule family just uses CLANGPE. CLANGPE lets user know this
>  tool
> >chain generates PE/COFF image.
>   And, PE/COFF image debug symbol is PDB. So, PE also means PDB.
> 
>   Last, I just review the changes. Tool chain name update is not
>  big. If you
> >accept CLANGPE as tool chain name,
>   I will send the patch soon to catch 201911 stable tag.
> 
>  Thanks
>  Liming
> > -Original Message-
> > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On
> Behalf
> >Of Leif
> > Lindholm
> > Sent: Friday, November 08, 2019 2:37 AM
> > To: Andrew Fish 
> > Cc: devel@edk2.groups.io; Gao, Liming ; Ni,
> > Ray ; Justen, Jordan L
> > 
> > Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable
> > CLANG9
> >tool
> > chain
> >
> > Hi Andrew,
> >
> > Yeah, I'm pretty easy with regards to what we change it to.
> > Although if we're bikeshedding, I would prefer not using _ in the
> > toolchain profile name.
> >
> > I'm ... optimistic ... it won't break any of my existing scripts,
> > but since the build system uses it as a  > profile>__ separator, it would be nice
> > if we didn't risk confusion there.
> >
> > (I would be totally happy with PECLANG, CLANGPE, PDBCLANG,
> >CLANGPDB or
> > something along those lines.)
> >
> > Regards,
> >
> > Leif
> >
> > On Thu, Nov 07, 2019 at 11:54:04AM -0600, Andrew Fish wrote:
> >> Leif,
> >>
> >> I think I proposed CLANG_PDB or CLANG_PECOFF. I seem to like
> > CLANG_PDB as assuming the PDE debugging experience is
> >awesome/exists
> > on Linux and macOS is not a given.
> >>
> >> Thanks,
> >>
> >> Andrew Fish
> >>
> >>> On Nov 7, 2019, at 11:19 AM, Leif Lindholm
> >>> 
> > wrote:
> >>>
> >>> Oops, sorry, missed this in search.
> >>>
> >>> On Wed, Oct 30, 2019 at 03:43:44PM +, Liming Gao wrote:
>  Andrew:
> 
>  I prefer to keep short CLANG9 as the tool chain name. I add
>  wiki page
>  https://github.com/tianocore/tianocore.github.io/wiki/CLANG9-
> >Tools-
> > Chain
>  to introduce it.
> >>>
> >>> Why should users be expected to go and read documentation in
> >order to
> >>> learn that fundamental and incompatible changes to output and
> >debug
> >>> format has been made as part of what looks like a simple version
> >bump?
> >>>
>  And, we 

[edk2-devel] [Patch] Readme.md: Update EDK II CI build branch name

2019-11-11 Thread Michael D Kinney
https://bugzilla.tianocore.org/show_bug.cgi?id=2315

Update Readme.md to indicate that that status badges are for
the edk2/master branch.

Cc: Sean Brogan 
Cc: Bret Barkelew 
Cc: Liming Gao 
Cc: Andrew Fish 
Cc: Laszlo Ersek 
Cc: Leif Lindholm 
Signed-off-by: Michael D Kinney 
---
 Readme.md | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Readme.md b/Readme.md
index acbcca88d3..594f16b207 100644
--- a/Readme.md
+++ b/Readme.md
@@ -17,7 +17,7 @@ for the UEFI and PI specifications from www.uefi.org.
   
 Windows
 VS2019
-edk2-ci
+master
 
   https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=32=master;>
   https://dev.azure.com/tianocore/edk2-ci/_apis/build/status/Windows%20VS2019%20CI?branchName=master"/>
@@ -34,7 +34,7 @@ for the UEFI and PI specifications from www.uefi.org.
   
 Ubuntu
 GCC
-edk2-ci
+master
 
   https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=31=master;>
   https://dev.azure.com/tianocore/edk2-ci/_apis/build/status/Ubuntu%20GCC5%20CI?branchName=master"/>
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50395): https://edk2.groups.io/g/devel/message/50395
Mute This Topic: https://groups.io/mt/53599349/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH V3 0/8] Update SMBIOS 3.3.0

2019-11-11 Thread Ni, Ray
Zhichao,
Thanks for the effort on investigation.
Can you please make sure what you will add doesn't contain magic numbers?
Then enter a BZ to remove the existing magic numbers.

> -Original Message-
> From: Gao, Zhichao 
> Sent: Tuesday, November 12, 2019 9:28 AM
> To: Ni, Ray ; devel@edk2.groups.io
> Cc: Kinney, Michael D ; Gao, Liming
> ; Chaganty, Rangasai V
> 
> Subject: RE: [edk2-devel] [PATCH V3 0/8] Update SMBIOS 3.3.0
> 
> Hi Ray,
> 
> I have tried to convert all the magic number to the MACROs/enums. But
> during that work, many magic numbers don't have the related MARCOs or
> enums. So can we just keep on reviewing this patch and then add a new BZ
> to add the missing enums to Smbios.h then convert all the magic number to
> enums?
> 
> Thanks,
> Zhichao
> 
> > -Original Message-
> > From: Ni, Ray 
> > Sent: Friday, November 8, 2019 11:25 AM
> > To: devel@edk2.groups.io; Gao, Zhichao 
> > Cc: Kinney, Michael D ; Gao, Liming
> > ; Chaganty, Rangasai V
> > 
> > Subject: RE: [edk2-devel] [PATCH V3 0/8] Update SMBIOS 3.3.0
> >
> > Zhichao,
> > I took a  look at the patch 5/8.
> > Given the value is already defined in MdePkg header file, can you
> > please update the implementation to avoid using magic number?
> >
> > I suggest you do the code change in two parts: one patch to modify
> > existing magic numbers to use macros/enums defined in MdePkg, the
> > other patch to add new mappings without using magic numbers.
> >
> > I didn't check the other patches after 5/8. If there are magic numbers
> > as well, can you please update them as well?
> >
> > Thanks,
> > Ray
> > > -Original Message-
> > > From: devel@edk2.groups.io  On Behalf Of Gao,
> > > Zhichao
> > > Sent: Thursday, November 7, 2019 8:52 AM
> > > To: devel@edk2.groups.io
> > > Cc: Kinney, Michael D ; Gao, Liming
> > > ; Ni, Ray ; Chaganty,
> > > Rangasai V 
> > > Subject: [edk2-devel] [PATCH V3 0/8] Update SMBIOS 3.3.0
> > >
> > > The following changes were made to version 3.2.0 of the document to
> > > produce this
> > > version:
> > > • System Slots (Type 9):
> > > – Add PCI Express Gen 4 values
> > > – Clarify bus number usage for PCI Express • Memory Device (Type 17):
> > > – Add new memory device type value (HBM) and new form factor value
> > > (Die) – Update the string for Intel persistent memory • Various:
> > > – Add support for RISC-V processors, add structure type 44
> > > (processor- additional information) – add support for CXL Flexbus
> > >
> > > V2:
> > > Add the new definition to MdePkg/Smbios.h.
> > >
> > > V3:
> > > Avoid change the enum name to casue the incompatible issue.
> > > Add the comment instead change the enum define name.
> > >
> > > Notes:
> > > Clarify bus number usage for PCI Express - Update the spec no code
> > > change requirement Add support for RISC-V processors, add structure
> > > type 44 (processor-additional information) - Already done at
> > > https://bugzilla.tianocore.org/show_bug.cgi?id=2202
> > >
> > > Cc: Michael D Kinney 
> > > Cc: Liming Gao 
> > > Cc: Ray Ni 
> > > Cc: Sai Chaganty 
> > > Signed-off-by: Zhichao Gao 
> > >
> > > Zhichao Gao (8):
> > >   MdePkg/Smbios.h: SMBIOS 3.3.0 add PCI gen4 values for type 9
> > >   MdePkg/Smbios.h: SMBIOS 3.3.0 add support for CXL Flexbus
> > >   MdePkg/Smbios.h: SMBIOS 3.3.0 Add value HBM and Die for type 17
> > >   MdePkg/Smbios.h: SMBIOS 3.3.0 Update Intel Persistent Memory string
> > >   ShellPkg/SmbiosView: SMBIOS 3.3.0 add PCI gen4 values for type 9
> > >   ShellPkg/SmbiosView: SMBIOS 3.3.0 add support for CXL Flexbus
> > >   ShellPkg/SmbiosView: SMBIOS 3.3.0 Add value HBM and Die for type 17
> > >   ShellPkg/SmbiosView: SMBIOS 3.3.0 Update "Intel persistent memory"
> > >
> > >  MdePkg/Include/IndustryStandard/SmBios.h   | 25 ---
> > >  .../SmbiosView/QueryTable.c| 48
> +-
> > >  2 files changed, 66 insertions(+), 7 deletions(-)
> > >
> > > --
> > > 2.16.2.windows.1
> > >
> > >
> > > 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50394): https://edk2.groups.io/g/devel/message/50394
Mute This Topic: https://groups.io/mt/44839633/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH V3 0/8] Update SMBIOS 3.3.0

2019-11-11 Thread Gao, Zhichao
Hi Ray,

I have tried to convert all the magic number to the MACROs/enums. But during 
that work, many magic numbers don't have the related MARCOs or enums. So can we 
just keep on reviewing this patch and then add a new BZ to add the missing 
enums to Smbios.h then convert all the magic number to enums?

Thanks,
Zhichao

> -Original Message-
> From: Ni, Ray 
> Sent: Friday, November 8, 2019 11:25 AM
> To: devel@edk2.groups.io; Gao, Zhichao 
> Cc: Kinney, Michael D ; Gao, Liming
> ; Chaganty, Rangasai V
> 
> Subject: RE: [edk2-devel] [PATCH V3 0/8] Update SMBIOS 3.3.0
> 
> Zhichao,
> I took a  look at the patch 5/8.
> Given the value is already defined in MdePkg header file, can you please 
> update
> the implementation to avoid using magic number?
> 
> I suggest you do the code change in two parts: one patch to modify existing
> magic numbers to use macros/enums defined in MdePkg, the other patch to add
> new mappings without using magic numbers.
> 
> I didn't check the other patches after 5/8. If there are magic numbers as 
> well,
> can you please update them as well?
> 
> Thanks,
> Ray
> > -Original Message-
> > From: devel@edk2.groups.io  On Behalf Of Gao,
> > Zhichao
> > Sent: Thursday, November 7, 2019 8:52 AM
> > To: devel@edk2.groups.io
> > Cc: Kinney, Michael D ; Gao, Liming
> > ; Ni, Ray ; Chaganty, Rangasai
> > V 
> > Subject: [edk2-devel] [PATCH V3 0/8] Update SMBIOS 3.3.0
> >
> > The following changes were made to version 3.2.0 of the document to
> > produce this
> > version:
> > • System Slots (Type 9):
> > – Add PCI Express Gen 4 values
> > – Clarify bus number usage for PCI Express • Memory Device (Type 17):
> > – Add new memory device type value (HBM) and new form factor value
> > (Die) – Update the string for Intel persistent memory • Various:
> > – Add support for RISC-V processors, add structure type 44 (processor-
> > additional information) – add support for CXL Flexbus
> >
> > V2:
> > Add the new definition to MdePkg/Smbios.h.
> >
> > V3:
> > Avoid change the enum name to casue the incompatible issue.
> > Add the comment instead change the enum define name.
> >
> > Notes:
> > Clarify bus number usage for PCI Express - Update the spec no code
> > change requirement Add support for RISC-V processors, add structure
> > type 44 (processor-additional information) - Already done at
> > https://bugzilla.tianocore.org/show_bug.cgi?id=2202
> >
> > Cc: Michael D Kinney 
> > Cc: Liming Gao 
> > Cc: Ray Ni 
> > Cc: Sai Chaganty 
> > Signed-off-by: Zhichao Gao 
> >
> > Zhichao Gao (8):
> >   MdePkg/Smbios.h: SMBIOS 3.3.0 add PCI gen4 values for type 9
> >   MdePkg/Smbios.h: SMBIOS 3.3.0 add support for CXL Flexbus
> >   MdePkg/Smbios.h: SMBIOS 3.3.0 Add value HBM and Die for type 17
> >   MdePkg/Smbios.h: SMBIOS 3.3.0 Update Intel Persistent Memory string
> >   ShellPkg/SmbiosView: SMBIOS 3.3.0 add PCI gen4 values for type 9
> >   ShellPkg/SmbiosView: SMBIOS 3.3.0 add support for CXL Flexbus
> >   ShellPkg/SmbiosView: SMBIOS 3.3.0 Add value HBM and Die for type 17
> >   ShellPkg/SmbiosView: SMBIOS 3.3.0 Update "Intel persistent memory"
> >
> >  MdePkg/Include/IndustryStandard/SmBios.h   | 25 ---
> >  .../SmbiosView/QueryTable.c| 48 
> > +-
> >  2 files changed, 66 insertions(+), 7 deletions(-)
> >
> > --
> > 2.16.2.windows.1
> >
> >
> > 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50393): https://edk2.groups.io/g/devel/message/50393
Mute This Topic: https://groups.io/mt/44839633/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix volatile variable RT cache update logic

2019-11-11 Thread Kubacki, Michael A
In the case a UEFI variable is deleted, the Attributes can be zero (Attributes 
are marked OPTIONAL in the API).
So in that case, the Attributes parameter alone does not accurately reflect the 
type of variable. The function
handles this fairly cryptically. The condition you specified is used in the 
function, for example on the following line:
https://github.com/tianocore/edk2/blob/master/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c#L2024
but I believe that is only valid because the deletion case was handled earlier 
in the function followed by a
goto Done so this code would be skipped over in the case of a pre-existing 
variable which would have the
->Volatile field set properly because it would have been set depending upon 
which variable store buffer 
the variable was found in. At this point in the flow (after the Done label), I 
believe this logic is required to
generically determine the variable volatility status.

Thanks,
Michael

> -Original Message-
> From: Gao, Liming 
> Sent: Monday, November 11, 2019 4:25 PM
> To: Kubacki, Michael A ;
> devel@edk2.groups.io
> Cc: Kinney, Michael D ; Wang, Jian J
> ; Wu, Hao A 
> Subject: RE: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix
> volatile variable RT cache update logic
> 
> Michael:
>   Can the logic be simplified to only check this condition 'Attributes &
> EFI_VARIABLE_NON_VOLATILE) != 0'?
> 
> Thanks
> Liming
> >-Original Message-
> >From: Kubacki, Michael A
> >Sent: Monday, November 11, 2019 2:11 PM
> >To: Gao, Liming ; devel@edk2.groups.io
> >Cc: Kinney, Michael D ; Wang, Jian J
> >; Wu, Hao A 
> >Subject: RE: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix
> >volatile variable RT cache update logic
> >
> >After a new volatile variable is written successfully, Runtime Services
> >GetVariable () may return EFI_NOT_FOUND for that variable.
> >
> >Thanks,
> >Michael
> >
> >> -Original Message-
> >> From: Gao, Liming 
> >> Sent: Sunday, November 10, 2019 10:08 PM
> >> To: devel@edk2.groups.io; Kubacki, Michael A
> >> 
> >> Cc: Kinney, Michael D ; Wang, Jian J
> >> ; Wu, Hao A ; Gao, Liming
> >> 
> >> Subject: RE: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix
> >> volatile variable RT cache update logic
> >>
> >> Michael:
> >>   What real issue is caused by this issue?
> >>
> >> Thanks
> >> Liming
> >> >-Original Message-
> >> >From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf
> >> >Of Kubacki, Michael A
> >> >Sent: Monday, November 11, 2019 1:16 PM
> >> >To: devel@edk2.groups.io
> >> >Cc: Gao, Liming ; Kinney, Michael D
> >> >; Wang, Jian J ;
> >> >Wu, Hao A 
> >> >Subject: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix
> >> >volatile variable RT cache update logic
> >> >
> >> >REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2333
> >> >
> >> >During a SetVariable () invocation, UpdateVariable () is called.
> >> >UpdateVariable () contains logic to determine whether a volatile or
> >> >non-volatile UEFI variable was set so the corresponding runtime
> >> >cache can be updated to reflect the change. The current logic simply
> >> >evaluates Variable->Volatile to determine which runtime cache should
> >> >be updated.
> >> >
> >> >The problem is Variable->Volatile does not always reflect whether a
> >> >volatile variable is being set. Variable->Volatile is set to TRUE
> >> >only in the case a pre-existing variable is found in the volatile
> >> >variable store. Therefore, the value is FALSE when a new volatile
> >> >variable is written.
> >> >
> >> >This change updates the logic to take this into account. If a new
> >> >variable is written successfully, the Attributes will accurately
> >> >reflect whether the variable is non-volatile. If a pre-existing
> >> >variable is modified, the Volatile field will reflect the type of
> >> >variable (Attributes are not reliable; e.g. 0x0 indicates deletion).
> >> >
> >> >Cc: Liming Gao 
> >> >Cc: Michael D Kinney 
> >> >Cc: Jian J Wang 
> >> >Cc: Hao A Wu 
> >> >Signed-off-by: Michael Kubacki 
> >> >---
> >> > MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c | 5 ++---
> >> > 1 file changed, 2 insertions(+), 3 deletions(-)
> >> >
> >> >diff --git a/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
> >> >b/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
> >> >index 29d6aca993..75d33ff724 100644
> >> >--- a/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
> >> >+++ b/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
> >> >@@ -2296,9 +2296,8 @@ UpdateVariable (
> >> >
> >> > Done:
> >> >   if (!EFI_ERROR (Status)) {
> >> >-if (Variable->Volatile) {
> >> >-  VolatileCacheInstance = &(mVariableModuleGlobal-
> >>
> >>VariableGlobal.VariableRuntimeCacheContext.VariableRuntimeVolatileC
> >> >>a
> >c
> >> h
> >> >e);
> >> >-} else {
> >> >+VolatileCacheInstance = &(mVariableModuleGlobal-
> >>
> >>VariableGlobal.VariableRuntimeCacheContext.VariableRuntimeVolatileC
> >> >>a
> >c
> >> h
> >> >e);
> 

Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Liming Gao
Thanks for your feedback. I will choose CLANGPE as the tool chain name. 

Thanks
Liming
>-Original Message-
>From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>Andrew Fish via Groups.Io
>Sent: Tuesday, November 12, 2019 12:52 AM
>To: Leif Lindholm 
>Cc: Ni, Ray ; Gao, Liming ;
>devel@edk2.groups.io; Justen, Jordan L ; Shi,
>Steven 
>Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
>chain
>
>Either works for me too. I like the PDE ending a little more, but agree it is a
>little more obscure.
>> On Nov 11, 2019, at 8:39 AM, Leif Lindholm  wrote:
>>
>> On Fri, Nov 08, 2019 at 03:34:59AM +, Ni, Ray wrote:
>>> Liming,
>>> PE is UEFI spec required executable binary format. I like CLANGPDB
>>> more than CLANGPE given LLVM may generate DRAWF debug symbol
>even
>>> when generating PE.
>>
>> Just a comment here to point out that while (as I stated in reply to
>> Liming) my preference would be CLANGPE, I see the logic in the above,
>> and would be happy with either.
>>
>> (My reason for preferring CLANGPE is not exactly techincal - I just
>> expect more people to know what PE is than who know what PDB is.)
>>
>> Regards,
>>
>> Leif
>>
 -Original Message-
 From: Gao, Liming 
 Sent: Friday, November 8, 2019 9:50 AM
 To: devel@edk2.groups.io; leif.lindh...@linaro.org; Andrew Fish
>
 Cc: Ni, Ray ; Justen, Jordan L
>; Gao, Liming ; Shi,
 Steven 
 Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9
>tool chain

 Andrew and Leif:
  Thanks for your comment. CLANG9 is different from CLANG38. And,
>CLANG9 will support LLVM9 or the above.
  So, this tool chain should have the specific word for its purpose, and
>remove the version 9 to avoid the confuse.

  I prefer the tool chain name as CLANGPE or CLANGPDB. CLANGPE may
>be better. Now, CLANG9 tool chain
  build rule family just uses CLANGPE. CLANGPE lets user know this tool
>chain generates PE/COFF image.
  And, PE/COFF image debug symbol is PDB. So, PE also means PDB.

  Last, I just review the changes. Tool chain name update is not big. If you
>accept CLANGPE as tool chain name,
  I will send the patch soon to catch 201911 stable tag.

 Thanks
 Liming
> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf
>Of Leif
> Lindholm
> Sent: Friday, November 08, 2019 2:37 AM
> To: Andrew Fish 
> Cc: devel@edk2.groups.io; Gao, Liming ; Ni, Ray
> ; Justen, Jordan L 
> Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9
>tool
> chain
>
> Hi Andrew,
>
> Yeah, I'm pretty easy with regards to what we change it to.
> Although if we're bikeshedding, I would prefer not using _ in the
> toolchain profile name.
>
> I'm ... optimistic ... it won't break any of my existing scripts, but
> since the build system uses it as a
> __ separator, it would
> be nice if we didn't risk confusion there.
>
> (I would be totally happy with PECLANG, CLANGPE, PDBCLANG,
>CLANGPDB or
> something along those lines.)
>
> Regards,
>
> Leif
>
> On Thu, Nov 07, 2019 at 11:54:04AM -0600, Andrew Fish wrote:
>> Leif,
>>
>> I think I proposed CLANG_PDB or CLANG_PECOFF. I seem to like
> CLANG_PDB as assuming the PDE debugging experience is
>awesome/exists
> on Linux and macOS is not a given.
>>
>> Thanks,
>>
>> Andrew Fish
>>
>>> On Nov 7, 2019, at 11:19 AM, Leif Lindholm 
> wrote:
>>>
>>> Oops, sorry, missed this in search.
>>>
>>> On Wed, Oct 30, 2019 at 03:43:44PM +, Liming Gao wrote:
 Andrew:

 I prefer to keep short CLANG9 as the tool chain name. I add wiki
 page
 https://github.com/tianocore/tianocore.github.io/wiki/CLANG9-
>Tools-
> Chain
 to introduce it.
>>>
>>> Why should users be expected to go and read documentation in
>order to
>>> learn that fundamental and incompatible changes to output and
>debug
>>> format has been made as part of what looks like a simple version
>bump?
>>>
 And, we have CLANG38 tool chain. It generates ELF
 image and DWARF debug symbol format. It can work with LLVM 9.0
 release. Current tool chain tag name includes compiler name and
 version. There is no specific info in the tool chain name. The
 developer can get the more tool chain information from wiki page.
>>>
>>> We aleady have the problem that people think they need to use
>GCC5 to
>>> build EDK2 since that is the highest named GCC toolchain profile.
>>>
>>> Let's not make this situation *worse* by setting up a
>multidimensional
>>> feature matrix, based off random numerical values.
>>>
>>> So say that we next have a pressing need to create a new toolchain
>>> profile for clang 

Re: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix volatile variable RT cache update logic

2019-11-11 Thread Liming Gao
Michael:
  Can the logic be simplified to only check this condition 'Attributes & 
EFI_VARIABLE_NON_VOLATILE) != 0'?

Thanks
Liming
>-Original Message-
>From: Kubacki, Michael A
>Sent: Monday, November 11, 2019 2:11 PM
>To: Gao, Liming ; devel@edk2.groups.io
>Cc: Kinney, Michael D ; Wang, Jian J
>; Wu, Hao A 
>Subject: RE: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix
>volatile variable RT cache update logic
>
>After a new volatile variable is written successfully, Runtime Services
>GetVariable () may return
>EFI_NOT_FOUND for that variable.
>
>Thanks,
>Michael
>
>> -Original Message-
>> From: Gao, Liming 
>> Sent: Sunday, November 10, 2019 10:08 PM
>> To: devel@edk2.groups.io; Kubacki, Michael A
>> 
>> Cc: Kinney, Michael D ; Wang, Jian J
>> ; Wu, Hao A ; Gao, Liming
>> 
>> Subject: RE: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix
>> volatile variable RT cache update logic
>>
>> Michael:
>>   What real issue is caused by this issue?
>>
>> Thanks
>> Liming
>> >-Original Message-
>> >From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>> >Kubacki, Michael A
>> >Sent: Monday, November 11, 2019 1:16 PM
>> >To: devel@edk2.groups.io
>> >Cc: Gao, Liming ; Kinney, Michael D
>> >; Wang, Jian J ; Wu,
>> >Hao A 
>> >Subject: [edk2-devel] [PATCH V1 1/1] MdeModulePkg/Variable: Fix
>> >volatile variable RT cache update logic
>> >
>> >REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2333
>> >
>> >During a SetVariable () invocation, UpdateVariable () is called.
>> >UpdateVariable () contains logic to determine whether a volatile or
>> >non-volatile UEFI variable was set so the corresponding runtime cache
>> >can be updated to reflect the change. The current logic simply
>> >evaluates Variable->Volatile to determine which runtime cache should be
>> >updated.
>> >
>> >The problem is Variable->Volatile does not always reflect whether a
>> >volatile variable is being set. Variable->Volatile is set to TRUE only
>> >in the case a pre-existing variable is found in the volatile variable
>> >store. Therefore, the value is FALSE when a new volatile variable is
>> >written.
>> >
>> >This change updates the logic to take this into account. If a new
>> >variable is written successfully, the Attributes will accurately
>> >reflect whether the variable is non-volatile. If a pre-existing
>> >variable is modified, the Volatile field will reflect the type of
>> >variable (Attributes are not reliable; e.g. 0x0 indicates deletion).
>> >
>> >Cc: Liming Gao 
>> >Cc: Michael D Kinney 
>> >Cc: Jian J Wang 
>> >Cc: Hao A Wu 
>> >Signed-off-by: Michael Kubacki 
>> >---
>> > MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c | 5 ++---
>> > 1 file changed, 2 insertions(+), 3 deletions(-)
>> >
>> >diff --git a/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
>> >b/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
>> >index 29d6aca993..75d33ff724 100644
>> >--- a/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
>> >+++ b/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c
>> >@@ -2296,9 +2296,8 @@ UpdateVariable (
>> >
>> > Done:
>> >   if (!EFI_ERROR (Status)) {
>> >-if (Variable->Volatile) {
>> >-  VolatileCacheInstance = &(mVariableModuleGlobal-
>> >>VariableGlobal.VariableRuntimeCacheContext.VariableRuntimeVolatileCa
>c
>> h
>> >e);
>> >-} else {
>> >+VolatileCacheInstance = &(mVariableModuleGlobal-
>> >>VariableGlobal.VariableRuntimeCacheContext.VariableRuntimeVolatileCa
>c
>> h
>> >e);
>> >+if ((Variable->CurrPtr != NULL && !Variable->Volatile) ||
>> >+ (Attributes &
>> >EFI_VARIABLE_NON_VOLATILE) != 0) {
>> >   VolatileCacheInstance = &(mVariableModuleGlobal-
>> >>VariableGlobal.VariableRuntimeCacheContext.VariableRuntimeNvCache);
>> > }
>> >
>> >--
>> >2.16.2.windows.1
>> >
>> >
>> >
>>
>


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50390): https://edk2.groups.io/g/devel/message/50390
Mute This Topic: https://groups.io/mt/52162397/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][Patch V2] MinPlatformPkg: Library for customizing TPM platform auth

2019-11-11 Thread Kubacki, Michael A
Can you please make these changes in V3?

MinPlatformPkg\MinPlatformPkg.dsc
  * It seems like a library class override section for Tcg2PlatformDxe is not 
necessary. Can the
  TpmPlatformAuthLib library class simply be assigned in the [LibraryClasses] 
section?

MinPlatformPkg\Tcg\Tcg2PlatformDxe\Tcg2PlatformDxe.c
  * I suggest using "SmmReadyToLock" instead of "ReadyToLock" throughout the 
file.
  * Can you please check again if all library classes included are required for 
this implementation?
  For example, I don't see usage of MemoryAllocationLib in the file.

MinPlatformPkg\Include\Library\TpmPlatformAuthLib\TpmPlatformAuthLib.h
  * Please add a file description to the copyright header.

  * ReadyToBoot is not the actual event the function is being invoked upon.
  So TpmPlatformAuthReadyToBootHandler ( ) is not accurate. The function is 
also not
  directly a notification handler (the function signature does not reflect that 
of a handler)
  so keeping "Handler" in the name is somewhat misleading.

  Some suggestions are:
1. TpmPlatformAuthAtSmmReadyToLock ( ) -> Keeps the event point in the name
2. ConfigureTpmPlatformAuthAtSmmReadyToLock ( ) -> More descriptive; keeps 
event point in the name
3. ConfigureTpmPlatformAuth ( ) -> More succinct; allows flexibility for 
invocation

  Unless there's a strong reason to associate the functionality with 
SmmReadyToLock, I suggest #3 (or your own name).

MinPlatformPkg\Tcg\Tcg2PlatformPei\Tcg2PlatformPei.c
  * It doesn't seem these changes are directly related to the rest of the 
patch? Could it be a separate patch?

MinPlatformPkg\Tcg\Library\TpmPlatformAuthLib\TpmPlatformAuthlib.inf
  * The constructor doesn't do anything. Is it actually needed?
  * Typo in function name: TpmPlatformAuthLibContructor

MinPlatformPkg\Tcg\Library\TpmPlatformAuthLib\TpmPlatformAuthlib.c
  * The function description for TpmPlatformAuthLibConstructor ( ) references 
parameters that don't actually exist
  in the implementation.

Thanks,
Michael

> -Original Message-
> From: Gonzalez Del Cueto, Rodrigo 
> Sent: Monday, November 11, 2019 1:43 AM
> To: devel@edk2.groups.io
> Cc: Gonzalez Del Cueto, Rodrigo ;
> Kubacki, Michael A ; Chiu, Chasel
> ; Desimone, Nathaniel L
> ; Gao, Liming 
> Subject: [edk2-platforms][Patch V2] MinPlatformPkg: Library for customizing
> TPM platform auth
> 
> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2331
> 
> In V2:
>   + Kept callback function and registration in Tcg2PlatformDxe module.
>   + New library defining API function: TpmPlatformAuthReadyToBootHandler
> for configuring the TPM's Platform Hierachy. This is now called
> through Tcg2PlatformDxe's ReadyToLockEventCallBack.
>   + Ported GetAuthSize fix to both Tcg2PlatformPei and MinPlatform's
> TpmPlatformAuthLib instance.
> 
> In order to enable some TPM use cases BIOS should enable to customize the
> configuration of the TPM platform, provisioning of endorsement, platform
> and storage hierarchy.
> 
> Cc: Michael Kubacki 
> Cc: Chasel Chiu 
> Cc: Nate DeSimone 
> Cc: Liming Gao 
> 
> Signed-off-by: Rodrigo Gonzalez del Cueto
> 
> ---
>  .../Include/Library/TpmPlatformAuthLib.h  |  24 ++
>  .../Intel/MinPlatformPkg/MinPlatformPkg.dec   |   2 +
>  .../Intel/MinPlatformPkg/MinPlatformPkg.dsc   |   5 +-
>  .../TpmPlatformAuthLib/TpmPlatformAuthLib.c   | 229
> ++
>  .../TpmPlatformAuthLib/TpmPlatformAuthLib.inf |  49 
>  .../Tcg/Tcg2PlatformDxe/Tcg2PlatformDxe.c | 161 ++--
>  .../Tcg/Tcg2PlatformDxe/Tcg2PlatformDxe.inf   |   6 +-
>  .../Tcg/Tcg2PlatformPei/Tcg2PlatformPei.c | 100 +---
>  8 files changed, 402 insertions(+), 174 deletions(-)  create mode 100644
> Platform/Intel/MinPlatformPkg/Include/Library/TpmPlatformAuthLib.h
>  create mode 100644
> Platform/Intel/MinPlatformPkg/Tcg/Library/TpmPlatformAuthLib/TpmPlatfo
> rmAuthLib.c
>  create mode 100644
> Platform/Intel/MinPlatformPkg/Tcg/Library/TpmPlatformAuthLib/TpmPlatfo
> rmAuthLib.inf
> 
> diff --git
> a/Platform/Intel/MinPlatformPkg/Include/Library/TpmPlatformAuthLib.h
> b/Platform/Intel/MinPlatformPkg/Include/Library/TpmPlatformAuthLib.h
> new file mode 100644
> index ..f33b67b0
> --- /dev/null
> +++
> b/Platform/Intel/MinPlatformPkg/Include/Library/TpmPlatformAuthLib.h
> @@ -0,0 +1,24 @@
> +/** @file++Copyright (c) 2019, Intel Corporation. All rights
> reserved.+SPDX-License-Identifier: BSD-2-Clause-
> Patent++**/++#ifndef _TPM_PLATFORM_AUTH_LIB_H_+#define
> _TPM_PLATFORM_AUTH_LIB_H_++#include +#include
> ++/**+   This service will perform the TPM Platform Auth
> configuration at the ReadyToBoot
> event.++**/+VOID+EFIAPI+TpmPlatformAuthReadyToBootHandler (+
> VOID+  );++#endifdiff --git
> a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec
> b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec
> index a851021c..fc5979db 100644
> --- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec
> +++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec
> @@ -62,6 

Re: [edk2-devel] [Patch 0/4] Enhance Incremental Build

2019-11-11 Thread Liming Gao
Bob:
  This is a fundamental change. It needs more review and test. 

  But now, 201911 stable tag softfreeze will be coming on 11-15. So, I don't 
think this change will catch 201911 stable tag. Right? 

Thanks
Liming
>-Original Message-
>From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>Bob Feng
>Sent: Monday, November 11, 2019 5:40 PM
>To: devel@edk2.groups.io
>Subject: [edk2-devel] [Patch 0/4] Enhance Incremental Build
>
>Incremental build reduces the build time by only building
>the module that need to update. Edk2 Build system is a Makefile
>based build system. The incrememtal build ability is provided by
>the Make program. But Edk2 build tool need to generate correct makefile
>to have Make program do incremental build correctly.
>
>The current solution in build tool to support incremental build is that build
>tool find out the include file list for each source file of a module, and in
>module's
>makefile, build tool add the include file list as the source file's dependency.
>In this way Make program can decide if it need to rebuild a source code by
>checking
>its dependency. This solution has 2 shortcommings, one is the process of
>finding
>include list is slow, the other is this method can't handle case that
>a MACRO in #include statement so the related source file is always built.
>
>This patch provides another method to support incremental build. That is to
>use
>c preprocessor and trim tool to generate dependency files for the source file.
>This method will save much time in AutoGen phase and handle MACRO in
>#include correctly.
>
>For C files:
>1. MSVS.
>cl.exe has a build option /showIncludes to display include files on 
> stdout.
>Build tool captures
>that messages and generate dependency files, .deps files.
>2. CLANG and GCC
>-MMD -MF build option are used to generate dependency files by
>preprocessor. Build tool updates the
>   .deps files.
>For ASL files:
>1. Trim find out all the included files, which are asl specific include 
> format,
>and generate .trim.deps file.
>2. ASL PP use c preprocessor to find out all included files with #include
>format and generate a .deps file
>3. build tool updates the .deps file
>For ASM files (.asm, .s or .nasm):
>1. Trim find out all the included files, which are asm specific include 
> format,
>and generate .trim.deps file.
>2. ASM PP use c preprocessor to find out all included files with #include
>format and generate a deps file
>3. build tool updates the .deps file
>
>Build tool add "include" instruction for those deps files in the Makefile.
>
>This patch does not support RVCT tool chain for the BZ
>https://bugzilla.tianocore.org/show_bug.cgi?id=1750
>
>Feng, Bob C (4):
>  BaseTools: Add build option for dependency file generation
>  BaseTools: Generate dependent files for ASL and ASM files
>  BaseTools: Update build_rule.txt to generate dependent files.
>  BaseTools: Enhance Basetool for incremental build
>
> BaseTools/Conf/build_rule.template|  94 ---
> BaseTools/Conf/tools_def.template | 173 ++--
> BaseTools/Source/Python/AutoGen/GenMake.py|  83 ++
> .../Source/Python/AutoGen/IncludesAutoGen.py  | 255
>++
> .../Source/Python/AutoGen/ModuleAutoGen.py|  23 ++
> BaseTools/Source/Python/Trim/Trim.py  | 115 ++--
> BaseTools/Source/Python/build/build.py|  63 -
> 7 files changed, 588 insertions(+), 218 deletions(-)
> create mode 100644
>BaseTools/Source/Python/AutoGen/IncludesAutoGen.py
>
>--
>2.20.1.windows.1
>
>
>


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50387): https://edk2.groups.io/g/devel/message/50387
Mute This Topic: https://groups.io/mt/52516787/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] EmulatorPkg/PlatformSmbiosDxe: fix a spell error of platform.

2019-11-11 Thread Liming Gao
Reviewed-by: Liming Gao 

>-Original Message-
>From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>Philippe Mathieu-Daudé
>Sent: Monday, November 11, 2019 5:27 PM
>To: devel@edk2.groups.io; Tan, Ming 
>Subject: Re: [edk2-devel] [PATCH] EmulatorPkg/PlatformSmbiosDxe: fix a
>spell error of platform.
>
>On 11/11/19 8:18 AM, Tan, Ming wrote:
>> Old code use platfomr.
>> Change PlatfomrSmbiosDriverEntryPoint to PlatformSmbiosDriverEntryPoint.
>>
>> Signed-off-by: Ming Tan 
>> ---
>>   EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c   | 2 +-
>>   EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf | 2 +-
>>   2 files changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
>b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
>> index e6f8734600..48a3bfb5e9 100644
>> --- a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
>> +++ b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
>> @@ -82,7 +82,7 @@ CreatePlatformSmbiosMemoryRecords (
>>   **/
>>   EFI_STATUS
>>   EFIAPI
>> -PlatfomrSmbiosDriverEntryPoint (
>> +PlatformSmbiosDriverEntryPoint (
>> IN EFI_HANDLE ImageHandle,
>> IN EFI_SYSTEM_TABLE   *SystemTable
>> )
>> diff --git a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
>b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
>> index 95b119e953..756f643c74 100644
>> --- a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
>> +++ b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
>> @@ -15,7 +15,7 @@
>> FILE_GUID  = 67FA951E-4FA2-9F4E-A658-4DBD954AC22E
>> MODULE_TYPE= DXE_DRIVER
>> VERSION_STRING = 1.0
>> -  ENTRY_POINT= PlatfomrSmbiosDriverEntryPoint
>> +  ENTRY_POINT= PlatformSmbiosDriverEntryPoint
>>
>>
>>   [Sources]
>>
>
>Reviewed-by: Philippe Mathieu-Daude 
>
>
>


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50386): https://edk2.groups.io/g/devel/message/50386
Mute This Topic: https://groups.io/mt/52449861/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch] Readme.md: Update EDK II CI build status badge and links

2019-11-11 Thread Sean via Groups.Io
Src of image for GCC build status looks like it is pointing at old 
edk2-staging.  The rest look good.

If that gets updated.

Reviewed-by: Sean Brogan 

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50385): https://edk2.groups.io/g/devel/message/50385
Mute This Topic: https://groups.io/mt/53446318/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration

2019-11-11 Thread Jeff Brasen
I am not sure a PCD would work (unless I am missing something) We do want to do 
a connect all and re-enumerate in UiApp but we need the platform code to be 
involved in that process.


Thanks,

Jeff


From: Ni, Ray 
Sent: Monday, November 11, 2019 4:58 PM
To: devel@edk2.groups.io ; Jeff Brasen 
; Laszlo Ersek ; af...@apple.com 

Cc: Ashish Singhal ; Wang, Jian J 
; Wu, Hao A ; Gao, Zhichao 
; Kinney, Michael D 
Subject: RE: [edk2-devel] [PATCH] Support skipping automatic BM enumeration


Jeff,

If adding a PCD to control UiApp can meet the real needs, I prefer to do in 
that way instead of adding new APIs to PlatformBootManagerLib.



Thanks,

Ray



From: devel@edk2.groups.io  On Behalf Of Jeff Brasen
Sent: Tuesday, November 12, 2019 6:58 AM
To: Laszlo Ersek ; Ni, Ray ; 
devel@edk2.groups.io; af...@apple.com
Cc: Ashish Singhal ; Wang, Jian J 
; Wu, Hao A ; Gao, Zhichao 
; Kinney, Michael D 
Subject: Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration



If we are concerned about deploying this and breaking builds we could do this 
via a new protocol instead. In that case though we would leave the old default 
behavior in the code to handle platforms that didn't implement the new 
protocol, so this might not be the cleanest way to deploy this.



We could also look at adding a generic platform boot hook function (either as a 
library function or protocol) if we wanted to limit the number of disruption on 
new customization hooks. Something like



EFI_STATUS PlatformBootNotify (CONST EFI_GUID *NotificationType, VOID 
*ContextData OPTIONAL)



Where Notification type describes where we are that we want platform to 
potentially handle and ContextData is per type caller allocated data that 
provides additional in/out data. This has the same issue of leaving the current 
default behavior in place for unsupported types as well as being a less than 
specific function to describe.



Thanks,

Jeff





From: Laszlo Ersek mailto:ler...@redhat.com>>
Sent: Friday, November 8, 2019 9:37 AM
To: Jeff Brasen mailto:jbra...@nvidia.com>>; Ni, Ray 
mailto:ray...@intel.com>>; 
devel@edk2.groups.io 
mailto:devel@edk2.groups.io>>; 
af...@apple.com 
mailto:af...@apple.com>>
Cc: Ashish Singhal mailto:ashishsin...@nvidia.com>>; 
Wang, Jian J mailto:jian.j.w...@intel.com>>; Wu, Hao A 
mailto:hao.a...@intel.com>>; Gao, Zhichao 
mailto:zhichao@intel.com>>; Kinney, Michael D 
mailto:michael.d.kin...@intel.com>>
Subject: Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration



On 11/07/19 18:46, Jeff Brasen wrote:
> Fixing UiApp seems reasonable, I do think we would want a hook to the 
> platform library in here as the enumeration that occurs in the UiApp is 
> intended to do a full enumeration of the system and there may be platform 
> specifics to how that occurs.

Fully agreed -- entering UiApp should expose everything bootable in the
system, unless (perhaps) PlatformBootManagerLib specifically thinks
otherwise.

Of course, then we arrive (again) at the problem that a call in
UefiBootManagerLib, to a *new* PlatformBootManagerLib API, will break
tens of out-of-tree platforms. :)

I think that can be prevented, as follows; but it will take quite some time:

- introduce the new function declaration in "PlatformBootManagerLib.h",
- modify all platforms (in tree and out of tree) to implement (define)
the new function,
- call the new function from UefiBootManagerLib

For some history / background on this kind of problem, I suggest reading
through:

  https://bugzilla.tianocore.org/show_bug.cgi?id=982

Thanks,
Laszlo

> From: Ni, Ray mailto:ray...@intel.com>>
> Sent: Thursday, November 7, 2019 12:21 AM
> To: devel@edk2.groups.io; Jeff Brasen 
> mailto:jbra...@nvidia.com>>; 
> af...@apple.com
> Cc: Ashish Singhal mailto:ashishsin...@nvidia.com>>; 
> Laszlo Ersek mailto:ler...@redhat.com>>; Wang, Jian J 
> mailto:jian.j.w...@intel.com>>; Wu, Hao A 
> mailto:hao.a...@intel.com>>; Gao, Zhichao 
> mailto:zhichao@intel.com>>; Kinney, Michael D 
> mailto:michael.d.kin...@intel.com>>
> Subject: RE: [edk2-devel] [PATCH] Support skipping automatic BM enumeration
>
> I treat the issue in this way:
>
>   1.  Platform Boot Manager library does a good job. It doesn't always call 
> RefreshAll() API to auto-create the boot options
>   2.  But UiApp doesn't. It constantly call RefreshAll().
>
> Do you think that we can fix UiApp instead? For example, introducing a PCD to 
> control the boot option refresh behavior?
>
> Thanks,
> Ray
>
> From: 
> devel@edk2.groups.io>
>  
> mailto:devel@edk2.groups.io>>
>  On Behalf Of Jeff Brasen
> Sent: Thursday, November 7, 2019 3:02 PM
> To: Ni, Ray 
> 

Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration

2019-11-11 Thread Ni, Ray
Jeff,
If adding a PCD to control UiApp can meet the real needs, I prefer to do in 
that way instead of adding new APIs to PlatformBootManagerLib.

Thanks,
Ray

From: devel@edk2.groups.io  On Behalf Of Jeff Brasen
Sent: Tuesday, November 12, 2019 6:58 AM
To: Laszlo Ersek ; Ni, Ray ; 
devel@edk2.groups.io; af...@apple.com
Cc: Ashish Singhal ; Wang, Jian J 
; Wu, Hao A ; Gao, Zhichao 
; Kinney, Michael D 
Subject: Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration

If we are concerned about deploying this and breaking builds we could do this 
via a new protocol instead. In that case though we would leave the old default 
behavior in the code to handle platforms that didn't implement the new 
protocol, so this might not be the cleanest way to deploy this.

We could also look at adding a generic platform boot hook function (either as a 
library function or protocol) if we wanted to limit the number of disruption on 
new customization hooks. Something like

EFI_STATUS PlatformBootNotify (CONST EFI_GUID *NotificationType, VOID 
*ContextData OPTIONAL)

Where Notification type describes where we are that we want platform to 
potentially handle and ContextData is per type caller allocated data that 
provides additional in/out data. This has the same issue of leaving the current 
default behavior in place for unsupported types as well as being a less than 
specific function to describe.


Thanks,

Jeff


From: Laszlo Ersek mailto:ler...@redhat.com>>
Sent: Friday, November 8, 2019 9:37 AM
To: Jeff Brasen mailto:jbra...@nvidia.com>>; Ni, Ray 
mailto:ray...@intel.com>>; 
devel@edk2.groups.io 
mailto:devel@edk2.groups.io>>; 
af...@apple.com 
mailto:af...@apple.com>>
Cc: Ashish Singhal mailto:ashishsin...@nvidia.com>>; 
Wang, Jian J mailto:jian.j.w...@intel.com>>; Wu, Hao A 
mailto:hao.a...@intel.com>>; Gao, Zhichao 
mailto:zhichao@intel.com>>; Kinney, Michael D 
mailto:michael.d.kin...@intel.com>>
Subject: Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration

On 11/07/19 18:46, Jeff Brasen wrote:
> Fixing UiApp seems reasonable, I do think we would want a hook to the 
> platform library in here as the enumeration that occurs in the UiApp is 
> intended to do a full enumeration of the system and there may be platform 
> specifics to how that occurs.

Fully agreed -- entering UiApp should expose everything bootable in the
system, unless (perhaps) PlatformBootManagerLib specifically thinks
otherwise.

Of course, then we arrive (again) at the problem that a call in
UefiBootManagerLib, to a *new* PlatformBootManagerLib API, will break
tens of out-of-tree platforms. :)

I think that can be prevented, as follows; but it will take quite some time:

- introduce the new function declaration in "PlatformBootManagerLib.h",
- modify all platforms (in tree and out of tree) to implement (define)
the new function,
- call the new function from UefiBootManagerLib

For some history / background on this kind of problem, I suggest reading
through:

  https://bugzilla.tianocore.org/show_bug.cgi?id=982

Thanks,
Laszlo

> From: Ni, Ray mailto:ray...@intel.com>>
> Sent: Thursday, November 7, 2019 12:21 AM
> To: devel@edk2.groups.io; Jeff Brasen 
> mailto:jbra...@nvidia.com>>; 
> af...@apple.com
> Cc: Ashish Singhal mailto:ashishsin...@nvidia.com>>; 
> Laszlo Ersek mailto:ler...@redhat.com>>; Wang, Jian J 
> mailto:jian.j.w...@intel.com>>; Wu, Hao A 
> mailto:hao.a...@intel.com>>; Gao, Zhichao 
> mailto:zhichao@intel.com>>; Kinney, Michael D 
> mailto:michael.d.kin...@intel.com>>
> Subject: RE: [edk2-devel] [PATCH] Support skipping automatic BM enumeration
>
> I treat the issue in this way:
>
>   1.  Platform Boot Manager library does a good job. It doesn't always call 
> RefreshAll() API to auto-create the boot options
>   2.  But UiApp doesn't. It constantly call RefreshAll().
>
> Do you think that we can fix UiApp instead? For example, introducing a PCD to 
> control the boot option refresh behavior?
>
> Thanks,
> Ray
>
> From: 
> devel@edk2.groups.io>
>  
> mailto:devel@edk2.groups.io>>
>  On Behalf Of Jeff Brasen
> Sent: Thursday, November 7, 2019 3:02 PM
> To: Ni, Ray 
> mailto:ray...@intel.com>>;
>  af...@apple.com
> Cc: 
> devel@edk2.groups.io>;
>  Ashish Singhal 
> mailto:ashishsin...@nvidia.com>>;
>  Laszlo Ersek 
> mailto:ler...@redhat.com>>;
>  Wang, Jian J 
> 

[edk2-devel] [Patch] Readme.md: Update EDK II CI build status badge and links

2019-11-11 Thread Michael D Kinney
https://bugzilla.tianocore.org/show_bug.cgi?id=2315

Update Readme.md with the status badges from the Azure
Pipelines, tianocore organization, edk2-ci project

https://dev.azure.com/tianocore/edk2-ci/_build

* Windows VS2019 CI pipeline badges and results
* Ubuntu GCC5 CI pipeline badges and results

Cc: Sean Brogan 
Cc: Bret Barkelew 
Cc: Liming Gao 
Cc: Andrew Fish 
Cc: Laszlo Ersek 
Cc: Leif Lindholm 
Signed-off-by: Michael D Kinney 
---
 Readme.md | 18 +-
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/Readme.md b/Readme.md
index dcd86daef1..678428bdcf 100644
--- a/Readme.md
+++ b/Readme.md
@@ -19,15 +19,15 @@ for the UEFI and PI specifications from www.uefi.org.
 VS2019
 edk2-ci
 
-  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
-  https://dev.azure.com/tianocore/edk2-ci-play/_apis/build/status/edk2-staging/Windows%20VS2019%20CI?branchName=edk2-ci"/>
+  https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=32=master;>
+  https://dev.azure.com/tianocore/edk2-ci/_apis/build/status/Windows%20VS2019%20CI?branchName=master"/>
 
 
-  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
-  https://img.shields.io/azure-devops/tests/tianocore/edk2-ci-play/27.svg"/>
+  https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=32=master;>
+  https://img.shields.io/azure-devops/tests/tianocore/edk2-ci/32.svg"/>
 
 
-  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
+  https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=32=master;>
   https://img.shields.io/badge/coverage-coming_soon-blue"/>
 
   
@@ -36,15 +36,15 @@ for the UEFI and PI specifications from www.uefi.org.
 GCC
 edk2-ci
 
-  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
+  https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=31=master;>
   https://dev.azure.com/tianocore/edk2-ci-play/_apis/build/status/edk2-staging/Ubuntu%20GCC5%20CI?branchName=edk2-ci"/>
 
 
-  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
-  https://img.shields.io/azure-devops/tests/tianocore/edk2-ci-play/26.svg"/>
+  https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=31=master;>
+  https://img.shields.io/azure-devops/tests/tianocore/edk2-ci/31.svg"/>
 
 
-  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
+  https://dev.azure.com/tianocore/edk2-ci/_build/latest?definitionId=31=master;>
   https://img.shields.io/badge/coverage-coming_soon-blue"/>
 
   
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50382): https://edk2.groups.io/g/devel/message/50382
Mute This Topic: https://groups.io/mt/53446318/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration

2019-11-11 Thread Jeff Brasen
If we are concerned about deploying this and breaking builds we could do this 
via a new protocol instead. In that case though we would leave the old default 
behavior in the code to handle platforms that didn't implement the new 
protocol, so this might not be the cleanest way to deploy this.

We could also look at adding a generic platform boot hook function (either as a 
library function or protocol) if we wanted to limit the number of disruption on 
new customization hooks. Something like

EFI_STATUS PlatformBootNotify (CONST EFI_GUID *NotificationType, VOID 
*ContextData OPTIONAL)

Where Notification type describes where we are that we want platform to 
potentially handle and ContextData is per type caller allocated data that 
provides additional in/out data. This has the same issue of leaving the current 
default behavior in place for unsupported types as well as being a less than 
specific function to describe.


Thanks,

Jeff


From: Laszlo Ersek 
Sent: Friday, November 8, 2019 9:37 AM
To: Jeff Brasen ; Ni, Ray ; 
devel@edk2.groups.io ; af...@apple.com 
Cc: Ashish Singhal ; Wang, Jian J 
; Wu, Hao A ; Gao, Zhichao 
; Kinney, Michael D 
Subject: Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration

On 11/07/19 18:46, Jeff Brasen wrote:
> Fixing UiApp seems reasonable, I do think we would want a hook to the 
> platform library in here as the enumeration that occurs in the UiApp is 
> intended to do a full enumeration of the system and there may be platform 
> specifics to how that occurs.

Fully agreed -- entering UiApp should expose everything bootable in the
system, unless (perhaps) PlatformBootManagerLib specifically thinks
otherwise.

Of course, then we arrive (again) at the problem that a call in
UefiBootManagerLib, to a *new* PlatformBootManagerLib API, will break
tens of out-of-tree platforms. :)

I think that can be prevented, as follows; but it will take quite some time:

- introduce the new function declaration in "PlatformBootManagerLib.h",
- modify all platforms (in tree and out of tree) to implement (define)
the new function,
- call the new function from UefiBootManagerLib

For some history / background on this kind of problem, I suggest reading
through:

  https://bugzilla.tianocore.org/show_bug.cgi?id=982

Thanks,
Laszlo

> From: Ni, Ray 
> Sent: Thursday, November 7, 2019 12:21 AM
> To: devel@edk2.groups.io; Jeff Brasen ; af...@apple.com
> Cc: Ashish Singhal ; Laszlo Ersek 
> ; Wang, Jian J ; Wu, Hao A 
> ; Gao, Zhichao ; Kinney, Michael D 
> 
> Subject: RE: [edk2-devel] [PATCH] Support skipping automatic BM enumeration
>
> I treat the issue in this way:
>
>   1.  Platform Boot Manager library does a good job. It doesn't always call 
> RefreshAll() API to auto-create the boot options
>   2.  But UiApp doesn't. It constantly call RefreshAll().
>
> Do you think that we can fix UiApp instead? For example, introducing a PCD to 
> control the boot option refresh behavior?
>
> Thanks,
> Ray
>
> From: devel@edk2.groups.io 
> mailto:devel@edk2.groups.io>> On Behalf Of Jeff Brasen
> Sent: Thursday, November 7, 2019 3:02 PM
> To: Ni, Ray mailto:ray...@intel.com>>; 
> af...@apple.com
> Cc: devel@edk2.groups.io; Ashish Singhal 
> mailto:ashishsin...@nvidia.com>>; Laszlo Ersek 
> mailto:ler...@redhat.com>>; Wang, Jian J 
> mailto:jian.j.w...@intel.com>>; Wu, Hao A 
> mailto:hao.a...@intel.com>>; Gao, Zhichao 
> mailto:zhichao@intel.com>>; Kinney, Michael D 
> mailto:michael.d.kin...@intel.com>>
> Subject: Re: [edk2-devel] [PATCH] Support skipping automatic BM enumeration
>
> The issue is there are some auto created options we do not want on our 
> platform.
> Get Outlook for Android
>
> 
> From: Ni, Ray mailto:ray...@intel.com>>
> Sent: Wednesday, November 6, 2019 11:59:31 PM
> To: Jeff Brasen mailto:jbra...@nvidia.com>>; 
> af...@apple.com 
> mailto:af...@apple.com>>
> Cc: devel@edk2.groups.io 
> mailto:devel@edk2.groups.io>>; Ashish Singhal 
> mailto:ashishsin...@nvidia.com>>; Laszlo Ersek 
> mailto:ler...@redhat.com>>; Wang, Jian J 
> mailto:jian.j.w...@intel.com>>; Wu, Hao A 
> mailto:hao.a...@intel.com>>; Gao, Zhichao 
> mailto:zhichao@intel.com>>; Kinney, Michael D 
> mailto:michael.d.kin...@intel.com>>
> Subject: RE: [edk2-devel] [PATCH] Support skipping automatic BM enumeration
>
>
> Jeff,
>
> RefreshAllBootOption() only modifies/creates the auto-created boot options. 
> For the boot options created by platform boot manager library, they stay with 
> no one touches. And all auto-created boot options are appended in the end of 
> boot option list (through BootOrder).
>
>
>
> From: Jeff Brasen mailto:jbra...@nvidia.com>>
> Sent: Thursday, November 7, 2019 12:13 PM
> To: af...@apple.com; Ni, Ray 
> mailto:ray...@intel.com>>
> 

Re: [edk2-devel] [edk2-platforms: PATCH] MinPlatformPkg: Add SetCacheMtrrLib class to dsc.

2019-11-11 Thread Nate DeSimone
Reviewed-by: Nate DeSimone 

-Original Message-
From: devel@edk2.groups.io  On Behalf Of Chiu, Chasel
Sent: Thursday, November 7, 2019 6:15 PM
To: devel@edk2.groups.io
Cc: Kubacki, Michael A ; Desimone, Nathaniel L 
; Gao, Liming 
Subject: [edk2-devel] [edk2-platforms: PATCH] MinPlatformPkg: Add 
SetCacheMtrrLib class to dsc.

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2314

Added SetCacheMtrrLib class to MinPlatformPkg.dsc.

Cc: Michael Kubacki 
Cc: Nate DeSimone 
Cc: Liming Gao 
Signed-off-by: Chasel Chiu 
---
 Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc 
b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
index 5f9363ff32..17272f819c 100644
--- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
+++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
@@ -94,6 +94,7 @@
   
ReportFvLib|MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiReportFvLib.inf
   
TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/PeiTestPointCheckLib.inf
   TestPointLib|MinPlatformPkg/Test/Library/TestPointLib/PeiTestPointLib.inf
+
+ SetCacheMtrrLib|$(PLATFORM_PACKAGE)/Library/SetCacheMtrrLib/SetCacheMt
+ rrLibNull.inf
 
 [LibraryClasses.common.DXE_DRIVER]
   #
@@ -189,4 +190,4 @@
 !endif
 
 [BuildOptions]
-  *_*_*_CC_FLAGS = -D DISABLE_NEW_DEPRECATED_INTERFACES \ No newline at end of 
file
+  *_*_*_CC_FLAGS = -D DISABLE_NEW_DEPRECATED_INTERFACES
--
2.13.3.windows.1





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50380): https://edk2.groups.io/g/devel/message/50380
Mute This Topic: https://groups.io/mt/47032665/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [staging/branch]: CdePkg - added unit test for remaining TIME.H functions - difftime(), mktime(), time(), asctime(), ctime(), gmtime(), localtime(), strftime()

2019-11-11 Thread Kilian Kegel
Hi UEFI community,

I’d like to inform you about an update in the CdePkg branch of  edk2-staging.
https://github.com/tianocore/edk2-staging/tree/CdePkg#cdepkg

The goal of the CdePkg is to provide an ANSI C Interface for UEFI POST drivers,
that enables BIOS engineers to (more) easily port standard C programs or 
libraries
(e.g. the openSSL library, already done) to POST drivers.

Furthermore the ANSI C Interface is disseminated widely, also it’s bugs and 
pitfalls are known very well
by a broad range of IT professionals and may help to be better supportable by 
the open source initiative
compared to the proprietary interface that is available today in Tianocore UEFI.

Now the ANSI C functions difftime() mktime() time() asctime() ctime() gmtime() 
localtime() strftime() are introduced for PEI and DXE.


Currently there are 4 examples implemented:

  1.  argvc: 
https://github.com/tianocore/edk2-staging/blob/CdePkg/CdeValidationPkg/HOSTED_ENV/argcv/main.c#L57

argc/argv handling according to 
https://msdn.microsoft.com/en-us/library/a1y7w461.aspx

  1.  systeminterfacePEI: 
https://github.com/tianocore/edk2-staging/blob/CdePkg/CdeValidationPkg/SYSTEM_IF/systeminterfacePEI/main.c#L57

demonstration, how PeiServices and FileHandle are passed into main()

  1.  systeminterfaceDXE: 
https://github.com/tianocore/edk2-staging/blob/CdePkg/CdeValidationPkg/SYSTEM_IF/systeminterfaceDXE/main.c#L57

demonstration, how SystemTable and ImageHandle are passed into main()



ANSI C LIBRARY functions:

  1.  time.h clock(): 
https://github.com/tianocore/edk2-staging/blob/CdePkg/CdeValidationPkg/TIME_H/clock/main.c#L1

for PEI and DXE phase. It provides TSC based, millisecond precise, exact and 
chipset independent clock() function.

NOTE: in emulation mode the TSC nominal frequency is supposed to be 1GHz

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/clock?view=vs-2019

  1.  NEW: time.h  difftime():

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/difftime-difftime32-difftime64?view=vs-2019

NEW: time.h  mktime():

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/mktime-mktime32-mktime64?view=vs-2019<%20https:/docs.microsoft.com/en-us/cpp/c-runtime-library/reference/mktime-mktime32-mktime64?view=vs-2019>

NEW: time.h time():

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/time-time32-time64?view=vs-2019<%20https:/docs.microsoft.com/en-us/cpp/c-runtime-library/reference/time-time32-time64?view=vs-2019>

NEW: time.h asctime():

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/asctime-wasctime?view=vs-2019

NEW: time.h  ctime():

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/ctime-ctime32-ctime64-wctime-wctime32-wctime64?view=vs-2019

NEW: time.h  gmtime():

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/gmtime-gmtime32-gmtime64?view=vs-2019

NEW: time.h  localtime():

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/localtime-localtime32-localtime64?view=vs-2019

NEW: time.h  strftime():

https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/strftime-wcsftime-strftime-l-wcsftime-l?view=vs-2019

NOTE: All TIME.H functions support UTC only.

All functions are tested in one single driver PEI/DXE: 
https://github.com/tianocore/edk2-staging/blob/CdePkg/CdeValidationPkg/TIME_H/timehfunctions/main.c#L52




Best Regards,
Kilian

From: Kilian Kegel
Sent: Wednesday, October 23, 2019 10:03 PM
To: devel@edk2.groups.io
Cc: Kinney, Michael D; Richardson, 
Brian
Subject: [edk2-devel] [staging/branch]: CdePkg - C Development Environment 
Package

Hi UEFI community,

I’d like to introduce the CdePkg to edk2-staging.


Some time ago I decided to write my own ANSI C Library for UEFI Shell and POST.



The UEFI Shell library (“Torito C Library”) has been production-ready for more 
than one year.

The POST version of the library (“CdeLib”) is not yet fully tested.



I will be demonstrating my verification procedure in the upcoming weeks on EDK2 
STAGING  https://github.com/tianocore/edk2-staging/tree/CdePkg



Currently there are 3 examples implemented:

  1.  argvc: 
https://github.com/tianocore/edk2-staging/blob/CdePkg/CdeValidationPkg/HOSTED_ENV/argcv/main.c#L57

argc/argv handling according to 
https://msdn.microsoft.com/en-us/library/a1y7w461.aspx

  1.  systeminterfacePEI: 
https://github.com/tianocore/edk2-staging/blob/CdePkg/CdeValidationPkg/SYSTEM_IF/systeminterfacePEI/main.c#L57

demonstration, how PeiServices and FileHandle are passed into main()

  1.  systeminterfaceDXE: 
https://github.com/tianocore/edk2-staging/blob/CdePkg/CdeValidationPkg/SYSTEM_IF/systeminterfaceDXE/main.c#L57

demonstration, how SystemTable and ImageHandle are passed into main()



Upcoming next demonstration will be the clock() function end of this week



The idea is to bring the 

Re: [edk2-devel] [edk2-platforms] [PATCH] BoardModulePkg: Remove unused variable

2019-11-11 Thread Kubacki, Michael A
Reviewed-by: Michael Kubacki 

> -Original Message-
> From: Agyeman, Prince 
> Sent: Wednesday, November 6, 2019 10:49 PM
> To: devel@edk2.groups.io
> Cc: Kubacki, Michael A ; Chiu, Chasel
> ; Desimone, Nathaniel L
> 
> Subject: [edk2-platforms] [PATCH] BoardModulePkg: Remove unused
> variable
> 
> Removed unused variable 'RegEmptied' in BdsPs2KbcLib.c to avoid gcc 5 build
> error unused-but-set-variable.
> 
> Cc: Michael Kubacki 
> Cc: Chasel Chiu 
> Cc: Nate DeSimone 
> 
> Signed-off-by: Prince Agyeman 
> ---
>  .../Intel/BoardModulePkg/Library/BdsPs2KbcLib/BdsPs2KbcLib.c| 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git
> a/Platform/Intel/BoardModulePkg/Library/BdsPs2KbcLib/BdsPs2KbcLib.c
> b/Platform/Intel/BoardModulePkg/Library/BdsPs2KbcLib/BdsPs2KbcLib.c
> index 3a885e0d71..eff10bddb4 100644
> --- a/Platform/Intel/BoardModulePkg/Library/BdsPs2KbcLib/BdsPs2KbcLib.c
> +++
> b/Platform/Intel/BoardModulePkg/Library/BdsPs2KbcLib/BdsPs2KbcLib.c
> @@ -47,13 +47,11 @@ DetectPs2Keyboard (
>)
>  {
>UINT32TimeOut;
> -  UINT32RegEmptied;
>UINT8 Data;
>UINT32SumTimeOut;
>BOOLEAN   FoundPs2Kbc;
> 
>TimeOut = 0;
> -  RegEmptied  = 0;
>FoundPs2Kbc   = FALSE;
> 
>//
> --
> 2.19.1.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50378): https://edk2.groups.io/g/devel/message/50378
Mute This Topic: https://groups.io/mt/45359163/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch v5 22/22] Readme.md: Add CI build status badges

2019-11-11 Thread Leif Lindholm
(on a phone)

This looks ... OK. I'm fine with this as a compromise.

Reviewed-by: me

On Mon, 11 Nov 2019, 08:41 Michael D Kinney, 
wrote:

> Update Readme.md with status badges from the most recent
> EDK II Continuous Integration(CI) build.
>
> Cc: Andrew Fish 
> Cc: Laszlo Ersek 
> Cc: Leif Lindholm 
> Signed-off-by: Michael D Kinney 
> Acked-by: Laszlo Ersek 
> Reviewed-by: Liming Gao 
> ---
>  Readme.md | 51 +++
>  1 file changed, 51 insertions(+)
>
> diff --git a/Readme.md b/Readme.md
> index 27e4ce0771..c22cac9748 100644
> --- a/Readme.md
> +++ b/Readme.md
> @@ -3,6 +3,57 @@
>  A modern, feature-rich, cross-platform firmware development environment
>  for the UEFI and PI specifications from www.uefi.org.
>
> +# Build Status
> +
> +
> +  
> +Host Type
> +Toolchain
> +Branch
> +Build Status
> +Test Status
> +Code Coverage
> +  
> +  
> +Windows
> +VS2019
> +edk2-ci
> +
> +  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci
> ">
> +  https://dev.azure.com/tianocore/edk2-ci-play/_apis/build/status/edk2-staging/Windows%20VS2019%20CI?branchName=edk2-ci
> "/>
> +
> +
> +  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci
> ">
> +  https://img.shields.io/azure-devops/tests/tianocore/edk2-ci-play/27.svg
> "/>
> +
> +
> +  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci
> ">
> +  https://img.shields.io/badge/coverage-coming_soon-blue
> "/>
> +
> +  
> +  
> +Ubuntu
> +GCC
> +edk2-ci
> +
> +  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci
> ">
> +  https://dev.azure.com/tianocore/edk2-ci-play/_apis/build/status/edk2-staging/Ubuntu%20GCC5%20CI?branchName=edk2-ci
> "/>
> +
> +
> +  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci
> ">
> +  https://img.shields.io/azure-devops/tests/tianocore/edk2-ci-play/26.svg
> "/>
> +
> +
> +  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci
> ">
> +  https://img.shields.io/badge/coverage-coming_soon-blue
> "/>
> +
> +  
> +
> +
> +[More CI Build information](.pytool/Readme.md)
> +
> +# License Details
> +
>  The majority of the content in the EDK II open source project uses a
>  [BSD-2-Clause Plus Patent License](License.txt).  The EDK II open source
> project
>  contains the following components that are covered by additional licenses:
> --
> 2.21.0.windows.1
>
>

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50377): https://edk2.groups.io/g/devel/message/50377
Mute This Topic: https://groups.io/mt/52458201/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Andrew Fish via Groups.Io
Either works for me too. I like the PDE ending a little more, but agree it is a 
little more obscure.
> On Nov 11, 2019, at 8:39 AM, Leif Lindholm  wrote:
> 
> On Fri, Nov 08, 2019 at 03:34:59AM +, Ni, Ray wrote:
>> Liming,
>> PE is UEFI spec required executable binary format. I like CLANGPDB
>> more than CLANGPE given LLVM may generate DRAWF debug symbol even
>> when generating PE.
> 
> Just a comment here to point out that while (as I stated in reply to
> Liming) my preference would be CLANGPE, I see the logic in the above,
> and would be happy with either.
> 
> (My reason for preferring CLANGPE is not exactly techincal - I just
> expect more people to know what PE is than who know what PDB is.)
> 
> Regards,
> 
> Leif
> 
>>> -Original Message-
>>> From: Gao, Liming 
>>> Sent: Friday, November 8, 2019 9:50 AM
>>> To: devel@edk2.groups.io; leif.lindh...@linaro.org; Andrew Fish 
>>> 
>>> Cc: Ni, Ray ; Justen, Jordan L 
>>> ; Gao, Liming ; Shi,
>>> Steven 
>>> Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool 
>>> chain
>>> 
>>> Andrew and Leif:
>>>  Thanks for your comment. CLANG9 is different from CLANG38. And, CLANG9 
>>> will support LLVM9 or the above.
>>>  So, this tool chain should have the specific word for its purpose, and 
>>> remove the version 9 to avoid the confuse.
>>> 
>>>  I prefer the tool chain name as CLANGPE or CLANGPDB. CLANGPE may be 
>>> better. Now, CLANG9 tool chain
>>>  build rule family just uses CLANGPE. CLANGPE lets user know this tool 
>>> chain generates PE/COFF image.
>>>  And, PE/COFF image debug symbol is PDB. So, PE also means PDB.
>>> 
>>>  Last, I just review the changes. Tool chain name update is not big. If you 
>>> accept CLANGPE as tool chain name,
>>>  I will send the patch soon to catch 201911 stable tag.
>>> 
>>> Thanks
>>> Liming
 -Original Message-
 From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Leif
 Lindholm
 Sent: Friday, November 08, 2019 2:37 AM
 To: Andrew Fish 
 Cc: devel@edk2.groups.io; Gao, Liming ; Ni, Ray
 ; Justen, Jordan L 
 Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
 chain
 
 Hi Andrew,
 
 Yeah, I'm pretty easy with regards to what we change it to.
 Although if we're bikeshedding, I would prefer not using _ in the
 toolchain profile name.
 
 I'm ... optimistic ... it won't break any of my existing scripts, but
 since the build system uses it as a
 __ separator, it would
 be nice if we didn't risk confusion there.
 
 (I would be totally happy with PECLANG, CLANGPE, PDBCLANG, CLANGPDB or
 something along those lines.)
 
 Regards,
 
 Leif
 
 On Thu, Nov 07, 2019 at 11:54:04AM -0600, Andrew Fish wrote:
> Leif,
> 
> I think I proposed CLANG_PDB or CLANG_PECOFF. I seem to like
 CLANG_PDB as assuming the PDE debugging experience is awesome/exists
 on Linux and macOS is not a given.
> 
> Thanks,
> 
> Andrew Fish
> 
>> On Nov 7, 2019, at 11:19 AM, Leif Lindholm 
 wrote:
>> 
>> Oops, sorry, missed this in search.
>> 
>> On Wed, Oct 30, 2019 at 03:43:44PM +, Liming Gao wrote:
>>> Andrew:
>>> 
>>> I prefer to keep short CLANG9 as the tool chain name. I add wiki
>>> page
>>> https://github.com/tianocore/tianocore.github.io/wiki/CLANG9-Tools-
 Chain
>>> to introduce it.
>> 
>> Why should users be expected to go and read documentation in order to
>> learn that fundamental and incompatible changes to output and debug
>> format has been made as part of what looks like a simple version bump?
>> 
>>> And, we have CLANG38 tool chain. It generates ELF
>>> image and DWARF debug symbol format. It can work with LLVM 9.0
>>> release. Current tool chain tag name includes compiler name and
>>> version. There is no specific info in the tool chain name. The
>>> developer can get the more tool chain information from wiki page.
>> 
>> We aleady have the problem that people think they need to use GCC5 to
>> build EDK2 since that is the highest named GCC toolchain profile.
>> 
>> Let's not make this situation *worse* by setting up a multidimensional
>> feature matrix, based off random numerical values.
>> 
>> So say that we next have a pressing need to create a new toolchain
>> profile for clang 10, using the old ELF mechanism. Are you then
>> suggesting we set up a table on said wiki page where people have to go
>> and look up what the object and debug formats are for each CLANG##
>> toolchain profile?
>> 
>> And what if you then end up needing to do the same for the PDB
>> flavour?
>> 
>>> CLANG9 is designed to support Emulator for Windows host only.
>> 
>> Which is why it makes no sense to name it as a successor of
>> CLANG38.
>> 
>>> CLANG38 

Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Andrew Fish via Groups.Io
Either works for me too. I like the PDE ending a little more, but agree it is a 
little more obscure.
> On Nov 11, 2019, at 8:39 AM, Leif Lindholm  wrote:
> 
> On Fri, Nov 08, 2019 at 03:34:59AM +, Ni, Ray wrote:
>> Liming,
>> PE is UEFI spec required executable binary format. I like CLANGPDB
>> more than CLANGPE given LLVM may generate DRAWF debug symbol even
>> when generating PE.
> 
> Just a comment here to point out that while (as I stated in reply to
> Liming) my preference would be CLANGPE, I see the logic in the above,
> and would be happy with either.
> 
> (My reason for preferring CLANGPE is not exactly techincal - I just
> expect more people to know what PE is than who know what PDB is.)
> 
> Regards,
> 
> Leif
> 
>>> -Original Message-
>>> From: Gao, Liming 
>>> Sent: Friday, November 8, 2019 9:50 AM
>>> To: devel@edk2.groups.io; leif.lindh...@linaro.org; Andrew Fish 
>>> 
>>> Cc: Ni, Ray ; Justen, Jordan L 
>>> ; Gao, Liming ; Shi,
>>> Steven 
>>> Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool 
>>> chain
>>> 
>>> Andrew and Leif:
>>>  Thanks for your comment. CLANG9 is different from CLANG38. And, CLANG9 
>>> will support LLVM9 or the above.
>>>  So, this tool chain should have the specific word for its purpose, and 
>>> remove the version 9 to avoid the confuse.
>>> 
>>>  I prefer the tool chain name as CLANGPE or CLANGPDB. CLANGPE may be 
>>> better. Now, CLANG9 tool chain
>>>  build rule family just uses CLANGPE. CLANGPE lets user know this tool 
>>> chain generates PE/COFF image.
>>>  And, PE/COFF image debug symbol is PDB. So, PE also means PDB.
>>> 
>>>  Last, I just review the changes. Tool chain name update is not big. If you 
>>> accept CLANGPE as tool chain name,
>>>  I will send the patch soon to catch 201911 stable tag.
>>> 
>>> Thanks
>>> Liming
 -Original Message-
 From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Leif
 Lindholm
 Sent: Friday, November 08, 2019 2:37 AM
 To: Andrew Fish 
 Cc: devel@edk2.groups.io; Gao, Liming ; Ni, Ray
 ; Justen, Jordan L 
 Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
 chain
 
 Hi Andrew,
 
 Yeah, I'm pretty easy with regards to what we change it to.
 Although if we're bikeshedding, I would prefer not using _ in the
 toolchain profile name.
 
 I'm ... optimistic ... it won't break any of my existing scripts, but
 since the build system uses it as a
 __ separator, it would
 be nice if we didn't risk confusion there.
 
 (I would be totally happy with PECLANG, CLANGPE, PDBCLANG, CLANGPDB or
 something along those lines.)
 
 Regards,
 
 Leif
 
 On Thu, Nov 07, 2019 at 11:54:04AM -0600, Andrew Fish wrote:
> Leif,
> 
> I think I proposed CLANG_PDB or CLANG_PECOFF. I seem to like
 CLANG_PDB as assuming the PDE debugging experience is awesome/exists
 on Linux and macOS is not a given.
> 
> Thanks,
> 
> Andrew Fish
> 
>> On Nov 7, 2019, at 11:19 AM, Leif Lindholm 
 wrote:
>> 
>> Oops, sorry, missed this in search.
>> 
>> On Wed, Oct 30, 2019 at 03:43:44PM +, Liming Gao wrote:
>>> Andrew:
>>> 
>>> I prefer to keep short CLANG9 as the tool chain name. I add wiki
>>> page
>>> https://github.com/tianocore/tianocore.github.io/wiki/CLANG9-Tools-
 Chain
>>> to introduce it.
>> 
>> Why should users be expected to go and read documentation in order to
>> learn that fundamental and incompatible changes to output and debug
>> format has been made as part of what looks like a simple version bump?
>> 
>>> And, we have CLANG38 tool chain. It generates ELF
>>> image and DWARF debug symbol format. It can work with LLVM 9.0
>>> release. Current tool chain tag name includes compiler name and
>>> version. There is no specific info in the tool chain name. The
>>> developer can get the more tool chain information from wiki page.
>> 
>> We aleady have the problem that people think they need to use GCC5 to
>> build EDK2 since that is the highest named GCC toolchain profile.
>> 
>> Let's not make this situation *worse* by setting up a multidimensional
>> feature matrix, based off random numerical values.
>> 
>> So say that we next have a pressing need to create a new toolchain
>> profile for clang 10, using the old ELF mechanism. Are you then
>> suggesting we set up a table on said wiki page where people have to go
>> and look up what the object and debug formats are for each CLANG##
>> toolchain profile?
>> 
>> And what if you then end up needing to do the same for the PDB
>> flavour?
>> 
>>> CLANG9 is designed to support Emulator for Windows host only.
>> 
>> Which is why it makes no sense to name it as a successor of
>> CLANG38.
>> 
>>> CLANG38 

Re: [edk2-devel] [Patch v5 03/22] pip_requirements.txt: Add python pip requirements file

2019-11-11 Thread Laszlo Ersek
On 11/11/19 17:35, Kinney, Michael D wrote:
> Hi Laszlo,
> 
> I will change to pip-requirements.txt.

Please update both the subject line and the actual filename.

With that:

Reviewed-by: Laszlo Ersek 

Thanks!
Laszlo

> 
> Mike
> 
>> -Original Message-
>> From: Laszlo Ersek 
>> Sent: Monday, November 11, 2019 1:58 AM
>> To: Kinney, Michael D ;
>> devel@edk2.groups.io
>> Cc: Sean Brogan ; Andrew Fish
>> ; Leif Lindholm
>> ; Gao, Liming
>> 
>> Subject: Re: [Patch v5 03/22] pip_requirements.txt: Add
>> python pip requirements file
>>
>> Hi Mike,
>>
>> On 11/11/19 09:40, Michael D Kinney wrote:
>>> From: Sean Brogan 
>>>
>>> Add pip requirements file that is used to install the
>> python pip
>>> modules build from the edk2-pytool-library and edk2-
>> pytool-extensions
>>> repositories.
>>>
>>> These python modules provide the extensions required
>> to perform EDK II
>>> Continuous Integration(CI) builds.
>>>
>>> Cc: Andrew Fish 
>>> Cc: Laszlo Ersek 
>>> Cc: Leif Lindholm 
>>> Signed-off-by: Michael D Kinney
>> 
>>> Reviewed-by: Liming Gao 
>>> ---
>>>  pip_requirements.txt | 17 +
>>>  1 file changed, 17 insertions(+)
>>>  create mode 100644 pip_requirements.txt
>>>
>>> diff --git a/pip_requirements.txt
>> b/pip_requirements.txt new file mode
>>> 100644 index 00..4ad72cfc98
>>> --- /dev/null
>>> +++ b/pip_requirements.txt
>>
>> Is the underscore (ASCII 0x5F) a typo /
>> misunderstanding, or is it
>> intentional?
>>
>> I never tested "pip_requirements.txt"; I tested "pip-
>> requirements.txt"
>> (hyphen, ASCII 0x2D).
>>
>> Thanks
>> Laszlo
>>
>>> @@ -0,0 +1,17 @@
>>> +## @file
>>> +# EDK II Python PIP requirements file
>>> +#
>>> +# This file provides the list of python components to
>> install using PIP.
>>> +#
>>> +# Copyright (c) Microsoft Corporation. All rights
>> reserved.
>>> +#
>>> +# SPDX-License-Identifier: BSD-2-Clause-Patent
>>> +#
>>> +# https://pypi.org/project/pip/
>>> +#
>> https://pip.pypa.io/en/stable/user_guide/#requirements-
>> files
>>> +#
>> https://pip.pypa.io/en/stable/reference/pip_install/#req
>> uirements-file-format
>>> +#
>>> +##
>>> +
>>> +edk2-pytool-library==0.10.*
>>> +edk2-pytool-extensions==0.12.*
>>>
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50374): https://edk2.groups.io/g/devel/message/50374
Mute This Topic: https://groups.io/mt/52458143/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Leif Lindholm
On Fri, Nov 08, 2019 at 03:34:59AM +, Ni, Ray wrote:
> Liming,
> PE is UEFI spec required executable binary format. I like CLANGPDB
> more than CLANGPE given LLVM may generate DRAWF debug symbol even
> when generating PE.

Just a comment here to point out that while (as I stated in reply to
Liming) my preference would be CLANGPE, I see the logic in the above,
and would be happy with either.

(My reason for preferring CLANGPE is not exactly techincal - I just
expect more people to know what PE is than who know what PDB is.)

Regards,

Leif

> > -Original Message-
> > From: Gao, Liming 
> > Sent: Friday, November 8, 2019 9:50 AM
> > To: devel@edk2.groups.io; leif.lindh...@linaro.org; Andrew Fish 
> > 
> > Cc: Ni, Ray ; Justen, Jordan L 
> > ; Gao, Liming ; Shi,
> > Steven 
> > Subject: RE: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool 
> > chain
> > 
> > Andrew and Leif:
> >   Thanks for your comment. CLANG9 is different from CLANG38. And, CLANG9 
> > will support LLVM9 or the above.
> >   So, this tool chain should have the specific word for its purpose, and 
> > remove the version 9 to avoid the confuse.
> > 
> >   I prefer the tool chain name as CLANGPE or CLANGPDB. CLANGPE may be 
> > better. Now, CLANG9 tool chain
> >   build rule family just uses CLANGPE. CLANGPE lets user know this tool 
> > chain generates PE/COFF image.
> >   And, PE/COFF image debug symbol is PDB. So, PE also means PDB.
> > 
> >   Last, I just review the changes. Tool chain name update is not big. If 
> > you accept CLANGPE as tool chain name,
> >   I will send the patch soon to catch 201911 stable tag.
> > 
> > Thanks
> > Liming
> > >-Original Message-
> > >From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Leif
> > >Lindholm
> > >Sent: Friday, November 08, 2019 2:37 AM
> > >To: Andrew Fish 
> > >Cc: devel@edk2.groups.io; Gao, Liming ; Ni, Ray
> > >; Justen, Jordan L 
> > >Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
> > >chain
> > >
> > >Hi Andrew,
> > >
> > >Yeah, I'm pretty easy with regards to what we change it to.
> > >Although if we're bikeshedding, I would prefer not using _ in the
> > >toolchain profile name.
> > >
> > >I'm ... optimistic ... it won't break any of my existing scripts, but
> > >since the build system uses it as a
> > >__ separator, it would
> > >be nice if we didn't risk confusion there.
> > >
> > >(I would be totally happy with PECLANG, CLANGPE, PDBCLANG, CLANGPDB or
> > >something along those lines.)
> > >
> > >Regards,
> > >
> > >Leif
> > >
> > >On Thu, Nov 07, 2019 at 11:54:04AM -0600, Andrew Fish wrote:
> > >> Leif,
> > >>
> > >> I think I proposed CLANG_PDB or CLANG_PECOFF. I seem to like
> > >CLANG_PDB as assuming the PDE debugging experience is awesome/exists
> > >on Linux and macOS is not a given.
> > >>
> > >> Thanks,
> > >>
> > >> Andrew Fish
> > >>
> > >> > On Nov 7, 2019, at 11:19 AM, Leif Lindholm 
> > >wrote:
> > >> >
> > >> > Oops, sorry, missed this in search.
> > >> >
> > >> > On Wed, Oct 30, 2019 at 03:43:44PM +, Liming Gao wrote:
> > >> >> Andrew:
> > >> >>
> > >> >>  I prefer to keep short CLANG9 as the tool chain name. I add wiki
> > >> >>  page
> > >> >>  https://github.com/tianocore/tianocore.github.io/wiki/CLANG9-Tools-
> > >Chain
> > >> >>  to introduce it.
> > >> >
> > >> > Why should users be expected to go and read documentation in order to
> > >> > learn that fundamental and incompatible changes to output and debug
> > >> > format has been made as part of what looks like a simple version bump?
> > >> >
> > >> >>  And, we have CLANG38 tool chain. It generates ELF
> > >> >>  image and DWARF debug symbol format. It can work with LLVM 9.0
> > >> >>  release. Current tool chain tag name includes compiler name and
> > >> >>  version. There is no specific info in the tool chain name. The
> > >> >>  developer can get the more tool chain information from wiki page.
> > >> >
> > >> > We aleady have the problem that people think they need to use GCC5 to
> > >> > build EDK2 since that is the highest named GCC toolchain profile.
> > >> >
> > >> > Let's not make this situation *worse* by setting up a multidimensional
> > >> > feature matrix, based off random numerical values.
> > >> >
> > >> > So say that we next have a pressing need to create a new toolchain
> > >> > profile for clang 10, using the old ELF mechanism. Are you then
> > >> > suggesting we set up a table on said wiki page where people have to go
> > >> > and look up what the object and debug formats are for each CLANG##
> > >> > toolchain profile?
> > >> >
> > >> > And what if you then end up needing to do the same for the PDB
> > >> > flavour?
> > >> >
> > >> >>  CLANG9 is designed to support Emulator for Windows host only.
> > >> >
> > >> > Which is why it makes no sense to name it as a successor of
> > >> > CLANG38.
> > >> >
> > >> >>  CLANG38 may be used for Emulator in Linux or Mac. I don’t
> > >> >>  try it before.
> > >> >>
> > >> 

Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool chain

2019-11-11 Thread Leif Lindholm
On Fri, Nov 08, 2019 at 01:49:30AM +, Gao, Liming wrote:
> Andrew and Leif:
>   Thanks for your comment. CLANG9 is different from CLANG38. And, CLANG9 will 
> support LLVM9 or the above. 
>   So, this tool chain should have the specific word for its purpose, and 
> remove the version 9 to avoid the confuse. 
> 
>   I prefer the tool chain name as CLANGPE or CLANGPDB. CLANGPE may be better. 
> Now, CLANG9 tool chain 
>   build rule family just uses CLANGPE. CLANGPE lets user know this tool chain 
> generates PE/COFF image. 
>   And, PE/COFF image debug symbol is PDB. So, PE also means PDB.

My preference would also be CLANGPE.

>   Last, I just review the changes. Tool chain name update is not big. If you 
> accept CLANGPE as tool chain name, 
>   I will send the patch soon to catch 201911 stable tag. 

I have no problem with this.

Thanks!

/
Leif

> Thanks
> Liming
> >-Original Message-
> >From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Leif
> >Lindholm
> >Sent: Friday, November 08, 2019 2:37 AM
> >To: Andrew Fish 
> >Cc: devel@edk2.groups.io; Gao, Liming ; Ni, Ray
> >; Justen, Jordan L 
> >Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9 tool
> >chain
> >
> >Hi Andrew,
> >
> >Yeah, I'm pretty easy with regards to what we change it to.
> >Although if we're bikeshedding, I would prefer not using _ in the
> >toolchain profile name.
> >
> >I'm ... optimistic ... it won't break any of my existing scripts, but
> >since the build system uses it as a
> >__ separator, it would
> >be nice if we didn't risk confusion there.
> >
> >(I would be totally happy with PECLANG, CLANGPE, PDBCLANG, CLANGPDB or
> >something along those lines.)
> >
> >Regards,
> >
> >Leif
> >
> >On Thu, Nov 07, 2019 at 11:54:04AM -0600, Andrew Fish wrote:
> >> Leif,
> >>
> >> I think I proposed CLANG_PDB or CLANG_PECOFF. I seem to like
> >CLANG_PDB as assuming the PDE debugging experience is awesome/exists
> >on Linux and macOS is not a given.
> >>
> >> Thanks,
> >>
> >> Andrew Fish
> >>
> >> > On Nov 7, 2019, at 11:19 AM, Leif Lindholm 
> >wrote:
> >> >
> >> > Oops, sorry, missed this in search.
> >> >
> >> > On Wed, Oct 30, 2019 at 03:43:44PM +, Liming Gao wrote:
> >> >> Andrew:
> >> >>
> >> >>  I prefer to keep short CLANG9 as the tool chain name. I add wiki
> >> >>  page
> >> >>  https://github.com/tianocore/tianocore.github.io/wiki/CLANG9-Tools-
> >Chain
> >> >>  to introduce it.
> >> >
> >> > Why should users be expected to go and read documentation in order to
> >> > learn that fundamental and incompatible changes to output and debug
> >> > format has been made as part of what looks like a simple version bump?
> >> >
> >> >>  And, we have CLANG38 tool chain. It generates ELF
> >> >>  image and DWARF debug symbol format. It can work with LLVM 9.0
> >> >>  release. Current tool chain tag name includes compiler name and
> >> >>  version. There is no specific info in the tool chain name. The
> >> >>  developer can get the more tool chain information from wiki page.
> >> >
> >> > We aleady have the problem that people think they need to use GCC5 to
> >> > build EDK2 since that is the highest named GCC toolchain profile.
> >> >
> >> > Let's not make this situation *worse* by setting up a multidimensional
> >> > feature matrix, based off random numerical values.
> >> >
> >> > So say that we next have a pressing need to create a new toolchain
> >> > profile for clang 10, using the old ELF mechanism. Are you then
> >> > suggesting we set up a table on said wiki page where people have to go
> >> > and look up what the object and debug formats are for each CLANG##
> >> > toolchain profile?
> >> >
> >> > And what if you then end up needing to do the same for the PDB
> >> > flavour?
> >> >
> >> >>  CLANG9 is designed to support Emulator for Windows host only.
> >> >
> >> > Which is why it makes no sense to name it as a successor of
> >> > CLANG38.
> >> >
> >> >>  CLANG38 may be used for Emulator in Linux or Mac. I don’t
> >> >>  try it before.
> >> >>
> >> >>  CLANG9 goal is to align the same compiler in the different host
> >> >>  development environment. It can replace VS or GCC compiler. On
> >> >>  Windows Host, I verify VS debugger for the source level debug. On
> >> >>  Linux host, I have not verified llvm debugger. I will investigate
> >> >>  the debugger solution for OVMF in Linux host.
> >> >
> >> > We are not asking you to throw out this toolchain profile.
> >> >
> >> > We are saying that since the functionality it provides is completely
> >> > unrelated to that of CLANG38, it should not be named in a way that
> >> > suggests it is merely a revision update.
> >> >
> >> > /
> >> >Leif
> >> >
> >> >> Thanks
> >> >> Liming
> >> >> From: af...@apple.com 
> >> >> Sent: Saturday, October 26, 2019 2:45 AM
> >> >> To: devel@edk2.groups.io; Gao, Liming 
> >> >> Cc: Ni, Ray ; Justen, Jordan L
> >
> >> >> Subject: Re: [edk2-devel] [Patch v3 10/11] EmulatorPkg: Enable CLANG9
> >tool 

Re: [edk2-devel] [Patch v5 03/22] pip_requirements.txt: Add python pip requirements file

2019-11-11 Thread Michael D Kinney
Hi Laszlo,

I will change to pip-requirements.txt.

Mike

> -Original Message-
> From: Laszlo Ersek 
> Sent: Monday, November 11, 2019 1:58 AM
> To: Kinney, Michael D ;
> devel@edk2.groups.io
> Cc: Sean Brogan ; Andrew Fish
> ; Leif Lindholm
> ; Gao, Liming
> 
> Subject: Re: [Patch v5 03/22] pip_requirements.txt: Add
> python pip requirements file
> 
> Hi Mike,
> 
> On 11/11/19 09:40, Michael D Kinney wrote:
> > From: Sean Brogan 
> >
> > Add pip requirements file that is used to install the
> python pip
> > modules build from the edk2-pytool-library and edk2-
> pytool-extensions
> > repositories.
> >
> > These python modules provide the extensions required
> to perform EDK II
> > Continuous Integration(CI) builds.
> >
> > Cc: Andrew Fish 
> > Cc: Laszlo Ersek 
> > Cc: Leif Lindholm 
> > Signed-off-by: Michael D Kinney
> 
> > Reviewed-by: Liming Gao 
> > ---
> >  pip_requirements.txt | 17 +
> >  1 file changed, 17 insertions(+)
> >  create mode 100644 pip_requirements.txt
> >
> > diff --git a/pip_requirements.txt
> b/pip_requirements.txt new file mode
> > 100644 index 00..4ad72cfc98
> > --- /dev/null
> > +++ b/pip_requirements.txt
> 
> Is the underscore (ASCII 0x5F) a typo /
> misunderstanding, or is it
> intentional?
> 
> I never tested "pip_requirements.txt"; I tested "pip-
> requirements.txt"
> (hyphen, ASCII 0x2D).
> 
> Thanks
> Laszlo
> 
> > @@ -0,0 +1,17 @@
> > +## @file
> > +# EDK II Python PIP requirements file
> > +#
> > +# This file provides the list of python components to
> install using PIP.
> > +#
> > +# Copyright (c) Microsoft Corporation. All rights
> reserved.
> > +#
> > +# SPDX-License-Identifier: BSD-2-Clause-Patent
> > +#
> > +# https://pypi.org/project/pip/
> > +#
> https://pip.pypa.io/en/stable/user_guide/#requirements-
> files
> > +#
> https://pip.pypa.io/en/stable/reference/pip_install/#req
> uirements-file-format
> > +#
> > +##
> > +
> > +edk2-pytool-library==0.10.*
> > +edk2-pytool-extensions==0.12.*
> >


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50371): https://edk2.groups.io/g/devel/message/50371
Mute This Topic: https://groups.io/mt/52458143/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH 1/1] Readme.md: remove positional references from submodule description

2019-11-11 Thread Leif Lindholm
On Thu, Nov 07, 2019 at 05:38:15PM +, Leif Lindholm via Groups.Io wrote:
> Remove references to the number of submodules in the tree, as well as
> reword the referring to specific submodules as "former" and "previous".
> This means we won't need to keep updating the surrounding text if we
> add/remove submodules.
> 
> Cc: Andrew Fish 
> Cc: Michael D Kinney 
> Signed-off-by: Leif Lindholm 
> Reviewed-by: Laszlo Ersek 

Not seen any responses, so since this is a trivial text update an I
had Laszlo's pregiven R-b - pushed as cc6854506c2b.

Thanks!

> ---
>  Readme.md | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/Readme.md b/Readme.md
> index 27e4ce07719b..9bf60bede8ec 100644
> --- a/Readme.md
> +++ b/Readme.md
> @@ -144,12 +144,12 @@ Signed-off-by: Contributor Name 
> 
>  # Submodules
>  
>  Submodule in EDK II is allowed but submodule chain should be avoided
> -as possible as we can. Currently EDK II contains two submodules
> +as possible as we can. Currently EDK II contains the following submodules
>  
>  - CryptoPkg/Library/OpensslLib/openssl
>  - ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3
>  
> -The latter one is actually required by previous one. It's inevitable
> +ArmSoftFloatLib is actually required by OpensslLib. It's inevitable
>  in openssl-1.1.1 (since stable201905) for floating point parameter
>  conversion, but should be dropped once there's no such need in future
>  release of openssl.
> -- 
> 2.20.1
> 
> 
> 
> 

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50370): https://edk2.groups.io/g/devel/message/50370
Mute This Topic: https://groups.io/mt/46388412/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH V3 4/6] IntelSiliconPkg/IntelPciDeviceSecurityDxe: Add PciSecurity.

2019-11-11 Thread Ni, Ray
With that, Reviewed-by: Ray Ni 

> -Original Message-
> From: Yao, Jiewen 
> Sent: Monday, November 11, 2019 6:17 PM
> To: Ni, Ray ; devel@edk2.groups.io
> Cc: Chaganty, Rangasai V ; Lou, Yun 
> 
> Subject: RE: [PATCH V3 4/6] IntelSiliconPkg/IntelPciDeviceSecurityDxe: Add 
> PciSecurity.
> 
> Agree. I will remove them.
> 
> > -Original Message-
> > From: Ni, Ray 
> > Sent: Monday, November 11, 2019 4:20 PM
> > To: Yao, Jiewen ; devel@edk2.groups.io
> > Cc: Chaganty, Rangasai V ; Lou, Yun
> > 
> > Subject: RE: [PATCH V3 4/6] IntelSiliconPkg/IntelPciDeviceSecurityDxe: Add
> > PciSecurity.
> >
> > Jiewen,
> > Below definitions are not used by the new driver but defined in
> > driver internal header file.
> > Can you please remove the unused definitions?
> >
> > EDKII_DEVICE_SECURITY_EVENT_DATA_USB_CONTEXT
> > #define EDKII_DEVICE_ROOT_CERT_VARAIBLE_NAMEL"devdb"
> > #define EDKII_DEVICE_ROOT_CERT_VARAIBLE2_NAME   L"devdbx"
> >
> > #define EDKII_DEVICE_SIGNATURE_DATABASE_GUID \
> >   {0xb9c2b4f4, 0xbf5f, 0x462d, 0x8a, 0xdf, 0xc5, 0xc7, 0xa, 0xc3, 0x5d, 
> > 0xad}
> >
> > > -Original Message-
> > > From: Yao, Jiewen 
> > > Sent: Thursday, November 7, 2019 9:38 PM
> > > To: devel@edk2.groups.io
> > > Cc: Ni, Ray ; Chaganty, Rangasai V
> > > ; Lou, Yun 
> > > Subject: [PATCH V3 4/6] IntelSiliconPkg/IntelPciDeviceSecurityDxe: Add
> > > PciSecurity.
> > >
> > > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2303
> > >
> > > This driver is to do the PCI device authentication based upon Intel PCIe
> > > Security Specification.
> > >
> > > Cc: Ray Ni 
> > > Cc: Rangasai V Chaganty 
> > > Cc: Yun Lou 
> > > Signed-off-by: Jiewen Yao 
> > > Signed-off-by: Yun Lou 
> > > ---
> > >  .../IntelPciDeviceSecurityDxe.c   | 697 ++
> > >  .../IntelPciDeviceSecurityDxe.inf |  45 ++
> > >  .../TcgDeviceEvent.h  | 178 +
> > >  3 files changed, 920 insertions(+)
> > >  create mode 100644
> > > Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDxe
> > > /IntelPciDeviceSecurityDxe.c
> > >  create mode 100644
> > > Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDxe
> > > /IntelPciDeviceSecurityDxe.inf
> > >  create mode 100644
> > > Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDxe
> > > /TcgDeviceEvent.h
> > >
> > > diff --git
> > > a/Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDx
> > > e/IntelPciDeviceSecurityDxe.c
> > > b/Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityD
> > > xe/IntelPciDeviceSecurityDxe.c
> > > new file mode 100644
> > > index 00..8838d5635a
> > > --- /dev/null
> > > +++ b/Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceS
> > > +++ ecurityDxe/IntelPciDeviceSecurityDxe.c
> > > @@ -0,0 +1,697 @@
> > > +/** @file
> > > +  EDKII Device Security library for PCI device.
> > > +  It follows the Intel PCIe Security Specification.
> > > +
> > > +Copyright (c) 2019, Intel Corporation. All rights reserved.
> > > +SPDX-License-Identifier: BSD-2-Clause-Patent
> > > +
> > > +**/
> > > +
> > > +#include 
> > > +#include 
> > > +#include 
> > > +#include 
> > > +#include 
> > > +#include 
> > > +#include 
> > > +#include 
> > > +#include 
> > > +#include 
> > > +#include  #include
> > > + #include  #include
> > > + #include
> > > +
> > > +#include "TcgDeviceEvent.h"
> > > +
> > > +typedef struct {
> > > +  EDKII_DEVICE_SECURITY_EVENT_DATA_HEADER   EventData;
> > > +  SPDM_MEASUREMENT_BLOCK_COMMON_HEADER  CommonHeader;
> > > +  SPDM_MEASUREMENT_BLOCK_DMTF_HEADERDmtfHeader;
> > > +  UINT8 
> > > Digest[SHA256_DIGEST_SIZE];
> > > +  EDKII_DEVICE_SECURITY_EVENT_DATA_PCI_CONTEXT  PciContext; }
> > > +EDKII_DEVICE_SECURITY_PCI_EVENT_DATA;
> > > +
> > > +typedef struct {
> > > +  UINTN Signature;
> > > +  LIST_ENTRYLink;
> > > +  UINTN PciSegment;
> > > +  UINTN PciBus;
> > > +  UINTN PciDevice;
> > > +  UINTN PciFunction;
> > > +} PCI_DEVICE_INSTANCE;
> > > +
> > > +#define PCI_DEVICE_INSTANCE_SIGNATURE  SIGNATURE_32 ('P', 'D', 'I',
> > > +'S') #define PCI_DEVICE_INSTANCE_FROM_LINK(a)  CR (a,
> > > +PCI_DEVICE_INSTANCE, Link, PCI_DEVICE_INSTANCE_SIGNATURE)
> > > +
> > > +LIST_ENTRY mSecurityEventMeasurementDeviceList =
> > > +INITIALIZE_LIST_HEAD_VARIABLE(mSecurityEventMeasurementDeviceList)
> > > ;;
> > > +EDKII_DEVICE_SECURITY_POLICY_PROTOCOL  *mDeviceSecurityPolicy;
> > > +
> > > +/**
> > > +  Record a PCI device into device list.
> > > +
> > > +  @param PciIoPciIo instance of the device
> > > +  @param PciDeviceListThe list to record the the device
> > > +**/
> > > +VOID
> > > +RecordPciDeviceInList(
> > > +  IN EFI_PCI_IO_PROTOCOL  *PciIo,
> > > +  IN LIST_ENTRY   *PciDeviceList
> > > +  )
> > > +{
> > > +  UINTN 

[edk2-devel] [edk2-platforms][Patch V2] MinPlatformPkg: Library for customizing TPM platform auth

2019-11-11 Thread Rodrigo Gonzalez del Cueto
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2331

In V2:
  + Kept callback function and registration in Tcg2PlatformDxe module.
  + New library defining API function: TpmPlatformAuthReadyToBootHandler
for configuring the TPM's Platform Hierachy. This is now called
through Tcg2PlatformDxe's ReadyToLockEventCallBack.
  + Ported GetAuthSize fix to both Tcg2PlatformPei and MinPlatform's
TpmPlatformAuthLib instance.

In order to enable some TPM use cases BIOS should enable to customize
the configuration of the TPM platform, provisioning of endorsement,
platform and storage hierarchy.

Cc: Michael Kubacki 
Cc: Chasel Chiu 
Cc: Nate DeSimone 
Cc: Liming Gao 

Signed-off-by: Rodrigo Gonzalez del Cueto 
---
 .../Include/Library/TpmPlatformAuthLib.h  |  24 ++
 .../Intel/MinPlatformPkg/MinPlatformPkg.dec   |   2 +
 .../Intel/MinPlatformPkg/MinPlatformPkg.dsc   |   5 +-
 .../TpmPlatformAuthLib/TpmPlatformAuthLib.c   | 229 ++
 .../TpmPlatformAuthLib/TpmPlatformAuthLib.inf |  49 
 .../Tcg/Tcg2PlatformDxe/Tcg2PlatformDxe.c | 161 ++--
 .../Tcg/Tcg2PlatformDxe/Tcg2PlatformDxe.inf   |   6 +-
 .../Tcg/Tcg2PlatformPei/Tcg2PlatformPei.c | 100 +---
 8 files changed, 402 insertions(+), 174 deletions(-)
 create mode 100644 
Platform/Intel/MinPlatformPkg/Include/Library/TpmPlatformAuthLib.h
 create mode 100644 
Platform/Intel/MinPlatformPkg/Tcg/Library/TpmPlatformAuthLib/TpmPlatformAuthLib.c
 create mode 100644 
Platform/Intel/MinPlatformPkg/Tcg/Library/TpmPlatformAuthLib/TpmPlatformAuthLib.inf

diff --git a/Platform/Intel/MinPlatformPkg/Include/Library/TpmPlatformAuthLib.h 
b/Platform/Intel/MinPlatformPkg/Include/Library/TpmPlatformAuthLib.h
new file mode 100644
index ..f33b67b0
--- /dev/null
+++ b/Platform/Intel/MinPlatformPkg/Include/Library/TpmPlatformAuthLib.h
@@ -0,0 +1,24 @@
+/** @file
+
+Copyright (c) 2019, Intel Corporation. All rights reserved.
+SPDX-License-Identifier: BSD-2-Clause-Patent
+
+**/
+
+#ifndef _TPM_PLATFORM_AUTH_LIB_H_
+#define _TPM_PLATFORM_AUTH_LIB_H_
+
+#include 
+#include 
+
+/**
+   This service will perform the TPM Platform Auth configuration at the 
ReadyToBoot event.
+
+**/
+VOID
+EFIAPI
+TpmPlatformAuthReadyToBootHandler (
+  VOID
+  );
+
+#endif
diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec 
b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec
index a851021c..fc5979db 100644
--- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec
+++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec
@@ -62,6 +62,8 @@ BoardInitLib|Include/Library/BoardInitLib.h
 MultiBoardInitSupportLib|Include/Library/MultiBoardInitSupportLib.h
 SecBoardInitLib|Include/Library/SecBoardInitLib.h
 
+TpmPlatformAuthLib|Include/Library/TpmPlatformAuthLib.h
+
 TestPointLib|Include/Library/TestPointLib.h
 TestPointCheckLib|Include/Library/TestPointCheckLib.h
 
diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc 
b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
index 5f9363ff..fbfd1e5d 100644
--- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
+++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
@@ -185,7 +185,10 @@
 
 !if gMinPlatformPkgTokenSpaceGuid.PcdTpm2Enable == TRUE
   MinPlatformPkg/Tcg/Tcg2PlatformPei/Tcg2PlatformPei.inf
-  MinPlatformPkg/Tcg/Tcg2PlatformDxe/Tcg2PlatformDxe.inf
+  MinPlatformPkg/Tcg/Tcg2PlatformDxe/Tcg2PlatformDxe.inf {
+
+
TpmPlatformAuthLib|MinPlatformPkg/Tcg/Library/TpmPlatformAuthLib/TpmPlatformAuthLib.inf
+  }
 !endif
 
 [BuildOptions]
diff --git 
a/Platform/Intel/MinPlatformPkg/Tcg/Library/TpmPlatformAuthLib/TpmPlatformAuthLib.c
 
b/Platform/Intel/MinPlatformPkg/Tcg/Library/TpmPlatformAuthLib/TpmPlatformAuthLib.c
new file mode 100644
index ..8ac780e1
--- /dev/null
+++ 
b/Platform/Intel/MinPlatformPkg/Tcg/Library/TpmPlatformAuthLib/TpmPlatformAuthLib.c
@@ -0,0 +1,229 @@
+/** @file
+TPM Platform Auth configuration library.
+
+Copyright (c) 2019, Intel Corporation. All rights reserved.
+SPDX-License-Identifier: BSD-2-Clause-Patent
+
+@par Specification Reference:
+
https://trustedcomputinggroup.org/resource/tcg-tpm-v2-0-provisioning-guidance/
+**/
+
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+//
+// The authorization value may be no larger than the digest produced by the 
hash
+//   algorithm used for context integrity.
+//
+#define  MAX_NEW_AUTHORIZATION_SIZE SHA512_DIGEST_SIZE
+
+/**
+  Generate high-quality entropy source through RDRAND.
+
+  @param[in]   LengthSize of the buffer, in bytes, to fill with.
+  @param[out]  Entropy   Pointer to the buffer to store the entropy data.
+
+  @retval EFI_SUCCESSEntropy generation succeeded.
+  @retval EFI_NOT_READY  Failed to request random data.
+
+**/
+EFI_STATUS
+EFIAPI
+RdRandGenerateEntropy (
+  IN UINTN Length,
+  OUT UINT8*Entropy
+  )
+{
+  EFI_STATUS  Status;
+  UINTN   BlockCount;
+  UINT64  

Re: [edk2-devel] [PATCH V3 4/6] IntelSiliconPkg/IntelPciDeviceSecurityDxe: Add PciSecurity.

2019-11-11 Thread Yao, Jiewen
Agree. I will remove them.

> -Original Message-
> From: Ni, Ray 
> Sent: Monday, November 11, 2019 4:20 PM
> To: Yao, Jiewen ; devel@edk2.groups.io
> Cc: Chaganty, Rangasai V ; Lou, Yun
> 
> Subject: RE: [PATCH V3 4/6] IntelSiliconPkg/IntelPciDeviceSecurityDxe: Add
> PciSecurity.
> 
> Jiewen,
> Below definitions are not used by the new driver but defined in
> driver internal header file.
> Can you please remove the unused definitions?
> 
> EDKII_DEVICE_SECURITY_EVENT_DATA_USB_CONTEXT
> #define EDKII_DEVICE_ROOT_CERT_VARAIBLE_NAMEL"devdb"
> #define EDKII_DEVICE_ROOT_CERT_VARAIBLE2_NAME   L"devdbx"
> 
> #define EDKII_DEVICE_SIGNATURE_DATABASE_GUID \
>   {0xb9c2b4f4, 0xbf5f, 0x462d, 0x8a, 0xdf, 0xc5, 0xc7, 0xa, 0xc3, 0x5d, 0xad}
> 
> > -Original Message-
> > From: Yao, Jiewen 
> > Sent: Thursday, November 7, 2019 9:38 PM
> > To: devel@edk2.groups.io
> > Cc: Ni, Ray ; Chaganty, Rangasai V
> > ; Lou, Yun 
> > Subject: [PATCH V3 4/6] IntelSiliconPkg/IntelPciDeviceSecurityDxe: Add
> > PciSecurity.
> >
> > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2303
> >
> > This driver is to do the PCI device authentication based upon Intel PCIe
> > Security Specification.
> >
> > Cc: Ray Ni 
> > Cc: Rangasai V Chaganty 
> > Cc: Yun Lou 
> > Signed-off-by: Jiewen Yao 
> > Signed-off-by: Yun Lou 
> > ---
> >  .../IntelPciDeviceSecurityDxe.c   | 697 ++
> >  .../IntelPciDeviceSecurityDxe.inf |  45 ++
> >  .../TcgDeviceEvent.h  | 178 +
> >  3 files changed, 920 insertions(+)
> >  create mode 100644
> > Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDxe
> > /IntelPciDeviceSecurityDxe.c
> >  create mode 100644
> > Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDxe
> > /IntelPciDeviceSecurityDxe.inf
> >  create mode 100644
> > Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDxe
> > /TcgDeviceEvent.h
> >
> > diff --git
> > a/Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDx
> > e/IntelPciDeviceSecurityDxe.c
> > b/Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityD
> > xe/IntelPciDeviceSecurityDxe.c
> > new file mode 100644
> > index 00..8838d5635a
> > --- /dev/null
> > +++ b/Silicon/Intel/IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceS
> > +++ ecurityDxe/IntelPciDeviceSecurityDxe.c
> > @@ -0,0 +1,697 @@
> > +/** @file
> > +  EDKII Device Security library for PCI device.
> > +  It follows the Intel PCIe Security Specification.
> > +
> > +Copyright (c) 2019, Intel Corporation. All rights reserved.
> > +SPDX-License-Identifier: BSD-2-Clause-Patent
> > +
> > +**/
> > +
> > +#include 
> > +#include 
> > +#include 
> > +#include 
> > +#include 
> > +#include 
> > +#include 
> > +#include 
> > +#include 
> > +#include 
> > +#include  #include
> > + #include  #include
> > + #include
> > +
> > +#include "TcgDeviceEvent.h"
> > +
> > +typedef struct {
> > +  EDKII_DEVICE_SECURITY_EVENT_DATA_HEADER   EventData;
> > +  SPDM_MEASUREMENT_BLOCK_COMMON_HEADER  CommonHeader;
> > +  SPDM_MEASUREMENT_BLOCK_DMTF_HEADERDmtfHeader;
> > +  UINT8 Digest[SHA256_DIGEST_SIZE];
> > +  EDKII_DEVICE_SECURITY_EVENT_DATA_PCI_CONTEXT  PciContext; }
> > +EDKII_DEVICE_SECURITY_PCI_EVENT_DATA;
> > +
> > +typedef struct {
> > +  UINTN Signature;
> > +  LIST_ENTRYLink;
> > +  UINTN PciSegment;
> > +  UINTN PciBus;
> > +  UINTN PciDevice;
> > +  UINTN PciFunction;
> > +} PCI_DEVICE_INSTANCE;
> > +
> > +#define PCI_DEVICE_INSTANCE_SIGNATURE  SIGNATURE_32 ('P', 'D', 'I',
> > +'S') #define PCI_DEVICE_INSTANCE_FROM_LINK(a)  CR (a,
> > +PCI_DEVICE_INSTANCE, Link, PCI_DEVICE_INSTANCE_SIGNATURE)
> > +
> > +LIST_ENTRY mSecurityEventMeasurementDeviceList =
> > +INITIALIZE_LIST_HEAD_VARIABLE(mSecurityEventMeasurementDeviceList)
> > ;;
> > +EDKII_DEVICE_SECURITY_POLICY_PROTOCOL  *mDeviceSecurityPolicy;
> > +
> > +/**
> > +  Record a PCI device into device list.
> > +
> > +  @param PciIoPciIo instance of the device
> > +  @param PciDeviceListThe list to record the the device
> > +**/
> > +VOID
> > +RecordPciDeviceInList(
> > +  IN EFI_PCI_IO_PROTOCOL  *PciIo,
> > +  IN LIST_ENTRY   *PciDeviceList
> > +  )
> > +{
> > +  UINTN PciSegment;
> > +  UINTN PciBus;
> > +  UINTN PciDevice;
> > +  UINTN PciFunction;
> > +  EFI_STATUSStatus;
> > +  PCI_DEVICE_INSTANCE   *NewPciDevice;
> > +
> > +  Status = PciIo->GetLocation (PciIo, , , ,
> > + );  ASSERT_EFI_ERROR(Status);
> > +
> > +  NewPciDevice = AllocateZeroPool(sizeof(*NewPciDevice));
> > +  ASSERT_EFI_ERROR(NewPciDevice != NULL);
> > +
> > +  NewPciDevice->Signature   = PCI_DEVICE_INSTANCE_SIGNATURE;
> > +  NewPciDevice->PciSegment  = PciSegment;
> > +  NewPciDevice->PciBus  = 

Re: [edk2-devel] [Patch v5 03/22] pip_requirements.txt: Add python pip requirements file

2019-11-11 Thread Laszlo Ersek
Hi Mike,

On 11/11/19 09:40, Michael D Kinney wrote:
> From: Sean Brogan 
> 
> Add pip requirements file that is used to install the
> python pip modules build from the edk2-pytool-library and
> edk2-pytool-extensions repositories.
> 
> These python modules provide the extensions required to
> perform EDK II Continuous Integration(CI) builds.
> 
> Cc: Andrew Fish 
> Cc: Laszlo Ersek 
> Cc: Leif Lindholm 
> Signed-off-by: Michael D Kinney 
> Reviewed-by: Liming Gao 
> ---
>  pip_requirements.txt | 17 +
>  1 file changed, 17 insertions(+)
>  create mode 100644 pip_requirements.txt
> 
> diff --git a/pip_requirements.txt b/pip_requirements.txt
> new file mode 100644
> index 00..4ad72cfc98
> --- /dev/null
> +++ b/pip_requirements.txt

Is the underscore (ASCII 0x5F) a typo / misunderstanding, or is it
intentional?

I never tested "pip_requirements.txt"; I tested "pip-requirements.txt"
(hyphen, ASCII 0x2D).

Thanks
Laszlo

> @@ -0,0 +1,17 @@
> +## @file
> +# EDK II Python PIP requirements file
> +#
> +# This file provides the list of python components to install using PIP.
> +#
> +# Copyright (c) Microsoft Corporation. All rights reserved.
> +#
> +# SPDX-License-Identifier: BSD-2-Clause-Patent
> +#
> +# https://pypi.org/project/pip/
> +# https://pip.pypa.io/en/stable/user_guide/#requirements-files
> +# 
> https://pip.pypa.io/en/stable/reference/pip_install/#requirements-file-format
> +#
> +##
> +
> +edk2-pytool-library==0.10.*
> +edk2-pytool-extensions==0.12.*
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50365): https://edk2.groups.io/g/devel/message/50365
Mute This Topic: https://groups.io/mt/52458143/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [Patch 4/4] BaseTools: Enhance Basetool for incremental build

2019-11-11 Thread Bob Feng
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2311

Include dependency file in Makefile to enhance
incremental build

Cc: Liming Gao 
Cc: Steven Shi 
Signed-off-by: Bob Feng 
---
 BaseTools/Source/Python/AutoGen/GenMake.py|  83 ++
 .../Source/Python/AutoGen/IncludesAutoGen.py  | 261 ++
 .../Source/Python/AutoGen/ModuleAutoGen.py|  23 ++
 BaseTools/Source/Python/build/build.py|  63 -
 4 files changed, 357 insertions(+), 73 deletions(-)
 create mode 100644 BaseTools/Source/Python/AutoGen/IncludesAutoGen.py

diff --git a/BaseTools/Source/Python/AutoGen/GenMake.py 
b/BaseTools/Source/Python/AutoGen/GenMake.py
index 59a01a7f243a..fe94f9a4c232 100755
--- a/BaseTools/Source/Python/AutoGen/GenMake.py
+++ b/BaseTools/Source/Python/AutoGen/GenMake.py
@@ -183,10 +183,16 @@ class BuildFile(object):
 EdkLogger.error("build", PARAMETER_INVALID, "Invalid build type 
[%s]" % FileType,
 ExtraData="[%s]" % str(self._AutoGenObject))
 self._FileType = FileType
 FileContent = self._TEMPLATE_.Replace(self._TemplateDict)
 FileName = self._FILE_NAME_[FileType]
+if not os.path.exists(os.path.join(self._AutoGenObject.MakeFileDir, 
"deps.txt")):
+with open(os.path.join(self._AutoGenObject.MakeFileDir, 
"deps.txt"),"w+") as fd:
+fd.write("")
+if not os.path.exists(os.path.join(self._AutoGenObject.MakeFileDir, 
"dependency")):
+with open(os.path.join(self._AutoGenObject.MakeFileDir, 
"dependency"),"w+") as fd:
+fd.write("")
 return SaveFileOnChange(os.path.join(self._AutoGenObject.MakeFileDir, 
FileName), FileContent, False)
 
 ## Return a list of directory creation command string
 #
 #   @param  DirList The list of directory to be created
@@ -302,13 +308,10 @@ MAKE_FILE = ${makefile_path}
 # Build Macro
 #
 ${BEGIN}${file_macro}
 ${END}
 
-COMMON_DEPS = ${BEGIN}${common_dependency_file} \\
-  ${END}
-
 #
 # Overridable Target Macro Definitions
 #
 FORCE_REBUILD = force_build
 INIT_TARGET = init
@@ -380,10 +383,12 @@ gen_libs:
 #
 gen_fds:
 \t@"$(MAKE)" $(MAKE_FLAGS) -f $(BUILD_DIR)${separator}${makefile_name} fds
 \t@cd $(MODULE_BUILD_DIR)
 
+${INCLUDETAG}
+
 #
 # Individual Object Build Targets
 #
 ${BEGIN}${file_build_target}
 ${END}
@@ -513,13 +518,10 @@ cleanlib:
 if Tool == "MAKE":
 continue
 # Remove duplicated include path, if any
 if Attr == "FLAGS":
 Value = RemoveDupOption(Value, IncPrefix, 
MyAgo.IncludePathList)
-if self._AutoGenObject.BuildRuleFamily == 
TAB_COMPILER_MSFT and Tool == 'CC' and '/GM' in Value:
-Value = Value.replace(' /MP', '')
-MyAgo.BuildOption[Tool][Attr] = Value
 if Tool == "OPTROM" and PCI_COMPRESS_Flag:
 ValueList = Value.split()
 if ValueList:
 for i, v in enumerate(ValueList):
 if '-e' == v:
@@ -538,11 +540,11 @@ cleanlib:
 RespFile = os.path.join(MyAgo.OutputDir, str(Resp).lower() + 
'.txt')
 StrList = RespDict[Resp].split(' ')
 UnexpandMacro = []
 NewStr = []
 for Str in StrList:
-if '$' in Str:
+if '$' in Str or '-MMD' in Str or '-MF' in Str:
 UnexpandMacro.append(Str)
 else:
 NewStr.append(Str)
 UnexpandMacroStr = ' '.join(UnexpandMacro)
 NewRespStr = ' '.join(NewStr)
@@ -588,14 +590,13 @@ cleanlib:
 "source_file" : 
IncludePathList
 }
 )
 FileMacroList.append(FileMacro)
 # Add support when compiling .nasm source files
-for File in self.FileCache.keys():
-if not str(File).endswith('.nasm'):
-continue
-IncludePathList = []
+IncludePathList = []
+asmsource = [item for item in MyAgo.SourceFileList if 
item.File.upper().endswith((".NASM",".ASM",".NASMB","S"))]
+if asmsource:
 for P in  MyAgo.IncludePathList:
 IncludePath = self._INC_FLAG_['NASM'] + self.PlaceMacro(P, 
self.Macros)
 if IncludePath.endswith(os.sep):
 IncludePath = IncludePath.rstrip(os.sep)
 # When compiling .nasm files, need to add a literal backslash 
at each path
@@ -604,11 +605,10 @@ cleanlib:
 IncludePath = ''.join([IncludePath, '^', os.sep])
 else:
 IncludePath = os.path.join(IncludePath, '')

[edk2-devel] [Patch 3/4] BaseTools: Update build_rule.txt to generate dependent files.

2019-11-11 Thread Bob Feng
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2311

Enable the dependent files generation function for compilers
and Trim tool.

Cc: Liming Gao 
Cc: Steven Shi 
Signed-off-by: Bob Feng 
---
 BaseTools/Conf/build_rule.template | 94 +-
 1 file changed, 52 insertions(+), 42 deletions(-)

diff --git a/BaseTools/Conf/build_rule.template 
b/BaseTools/Conf/build_rule.template
index 3a58ac8015e0..00d31d0022fa 100755
--- a/BaseTools/Conf/build_rule.template
+++ b/BaseTools/Conf/build_rule.template
@@ -121,18 +121,18 @@
 
 
 $(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.obj
 
 
-"$(CC)" /Fo${dst} $(CC_FLAGS) $(INC) ${src}
+"$(CC)" /Fo${dst} $(DEPS_FLAGS) $(CC_FLAGS) $(INC) ${src}
 
 
 # For RVCTCYGWIN CC_FLAGS must be first to work around pathing issues
-"$(CC)" $(CC_FLAGS) -c -o ${dst} $(INC) ${src}
+"$(CC)" $(DEPS_FLAGS) $(CC_FLAGS) -c -o ${dst} $(INC) ${src}
 
 
-"$(CC)" $(CC_FLAGS) -o ${dst} $(INC) ${src}
+"$(CC)" $(DEPS_FLAGS) $(CC_FLAGS) -o ${dst} $(INC) ${src}
 
 
[C-Code-File.BASE.AARCH64,C-Code-File.SEC.AARCH64,C-Code-File.PEI_CORE.AARCH64,C-Code-File.PEIM.AARCH64,C-Code-File.BASE.ARM,C-Code-File.SEC.ARM,C-Code-File.PEI_CORE.ARM,C-Code-File.PEIM.ARM]
 
 ?.c
 
@@ -165,19 +165,21 @@
 
 
 $(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.obj
 
 
-"$(PP)" $(PP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
-Trim --source-code --convert-hex --trim-long -o 
${d_path}(+)${s_base}.iii ${d_path}(+)${s_base}.i
-"$(ASM)" /Fo${dst} $(ASM_FLAGS) /I${s_path} $(INC) 
${d_path}(+)${s_base}.iii
+Trim --asm-file -o ${d_path}(+)${s_base}.i -i $(INC_LIST) ${src}
+"$(PP)" $(DEPS_FLAGS) $(PP_FLAGS) $(INC) ${src} > 
${d_path}(+)${s_base}.ii
+Trim --source-code --convert-hex --trim-long -o 
${d_path}(+)${s_base}. ${d_path}(+)${s_base}.ii
+"$(ASM)" /Fo${dst} $(ASM_FLAGS) /I${s_path} $(INC) 
${d_path}(+)${s_base}.
 
 
-"$(PP)" $(PP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
-Trim --trim-long --source-code -o ${d_path}(+)${s_base}.iii 
${d_path}(+)${s_base}.i
+Trim --asm-file -o ${d_path}(+)${s_base}.i -i $(INC_LIST) ${src}
+"$(PP)" $(DEPS_FLAGS) $(PP_FLAGS) $(INC) ${src} > 
${d_path}(+)${s_base}.ii
+Trim --trim-long --source-code -o ${d_path}(+)${s_base}. 
${d_path}(+)${s_base}.ii
 # For RVCTCYGWIN ASM_FLAGS must be first to work around pathing issues
-"$(ASM)" $(ASM_FLAGS) -o ${dst} $(INC) ${d_path}(+)${s_base}.iii
+"$(ASM)" $(ASM_FLAGS) -o ${dst} $(INC) ${d_path}(+)${s_base}.
 
 [Assembly-Code-File.COMMON.ARM,Assembly-Code-File.COMMON.AARCH64]
 # Remove --convert-hex for ARM as it breaks MSFT assemblers
 
 ?.asm, ?.Asm, ?.ASM
@@ -190,24 +192,27 @@
 
 
 $(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.obj
 
 
-"$(PP)" $(PP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
-Trim --source-code --convert-hex --trim-long -o 
${d_path}(+)${s_base}.iii ${d_path}(+)${s_base}.i
-"$(ASM)" /Fo${dst} $(ASM_FLAGS) /I${s_path} $(INC) 
${d_path}(+)${s_base}.iii
+Trim --asm-file -o ${d_path}(+)${s_base}.i -i $(INC_LIST) ${src}
+"$(PP)" $(DEPS_FLAGS) $(PP_FLAGS) $(INC) ${src} > 
${d_path}(+)${s_base}.ii
+Trim --source-code --convert-hex --trim-long -o 
${d_path}(+)${s_base}. ${d_path}(+)${s_base}.ii
+"$(ASM)" /Fo${dst} $(ASM_FLAGS) /I${s_path} $(INC) 
${d_path}(+)${s_base}.
 
 
-"$(PP)" $(PP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
-Trim --source-code --trim-long -o ${d_path}(+)${s_base}.iii 
${d_path}(+)${s_base}.i
-"$(ASM)" /Fo${dst} $(ASM_FLAGS) /I${s_path} $(INC) 
${d_path}(+)${s_base}.iii
+Trim --asm-file  -o ${d_path}(+)${s_base}.i -i $(INC_LIST) ${src}
+"$(PP)" $(DEPS_FLAGS) $(PP_FLAGS) $(INC) ${src} > 
${d_path}(+)${s_base}.ii
+Trim --source-code --trim-long -o ${d_path}(+)${s_base}. 
${d_path}(+)${s_base}.ii
+"$(ASM)" /Fo${dst} $(ASM_FLAGS) /I${s_path} $(INC) 
${d_path}(+)${s_base}.
 
 
-"$(PP)" $(PP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
-Trim --trim-long --source-code -o ${d_path}(+)${s_base}.iii 
${d_path}(+)${s_base}.i
+Trim --asm-file -o ${d_path}(+)${s_base}.i -i $(INC_LIST) ${src}
+"$(PP)" $(DEPS_FLAGS) $(PP_FLAGS) $(INC) ${src} > 
${d_path}(+)${s_base}.ii
+Trim --trim-long --source-code -o ${d_path}(+)${s_base}. 
${d_path}(+)${s_base}.ii
 # For RVCTCYGWIN ASM_FLAGS must be first to work around pathing issues
-"$(ASM)" $(ASM_FLAGS) -o ${dst} $(INC) ${d_path}(+)${s_base}.iii
+"$(ASM)" $(ASM_FLAGS) -o ${dst} $(INC) ${d_path}(+)${s_base}.
 
 [Nasm-Assembly-Code-File.COMMON.COMMON]
 
 ?.nasm
 
@@ -216,12 +221,13 @@
 
 
 $(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.obj
 
 
-"$(PP)" $(PP_FLAGS) $(INC) ${src} > 

[edk2-devel] [Patch 0/4] Enhance Incremental Build

2019-11-11 Thread Bob Feng
Incremental build reduces the build time by only building
the module that need to update. Edk2 Build system is a Makefile
based build system. The incrememtal build ability is provided by
the Make program. But Edk2 build tool need to generate correct makefile
to have Make program do incremental build correctly.

The current solution in build tool to support incremental build is that build
tool find out the include file list for each source file of a module, and in 
module's
makefile, build tool add the include file list as the source file's dependency. 
In this way Make program can decide if it need to rebuild a source code by 
checking
its dependency. This solution has 2 shortcommings, one is the process of finding
include list is slow, the other is this method can't handle case that 
a MACRO in #include statement so the related source file is always built. 

This patch provides another method to support incremental build. That is to use
c preprocessor and trim tool to generate dependency files for the source file.
This method will save much time in AutoGen phase and handle MACRO in #include 
correctly.

For C files:
1. MSVS.
cl.exe has a build option /showIncludes to display include files on 
stdout. Build tool captures
that messages and generate dependency files, .deps files.
2. CLANG and GCC
-MMD -MF build option are used to generate dependency files by 
preprocessor. Build tool updates the
   .deps files.
For ASL files:
1. Trim find out all the included files, which are asl specific include 
format, and generate .trim.deps file.
2. ASL PP use c preprocessor to find out all included files with #include 
format and generate a .deps file
3. build tool updates the .deps file
For ASM files (.asm, .s or .nasm):
1. Trim find out all the included files, which are asm specific include 
format, and generate .trim.deps file.
2. ASM PP use c preprocessor to find out all included files with #include 
format and generate a deps file
3. build tool updates the .deps file

Build tool add "include" instruction for those deps files in the Makefile.

This patch does not support RVCT tool chain for the BZ 
https://bugzilla.tianocore.org/show_bug.cgi?id=1750

Feng, Bob C (4):
  BaseTools: Add build option for dependency file generation
  BaseTools: Generate dependent files for ASL and ASM files
  BaseTools: Update build_rule.txt to generate dependent files.
  BaseTools: Enhance Basetool for incremental build

 BaseTools/Conf/build_rule.template|  94 ---
 BaseTools/Conf/tools_def.template | 173 ++--
 BaseTools/Source/Python/AutoGen/GenMake.py|  83 ++
 .../Source/Python/AutoGen/IncludesAutoGen.py  | 255 ++
 .../Source/Python/AutoGen/ModuleAutoGen.py|  23 ++
 BaseTools/Source/Python/Trim/Trim.py  | 115 ++--
 BaseTools/Source/Python/build/build.py|  63 -
 7 files changed, 588 insertions(+), 218 deletions(-)
 create mode 100644 BaseTools/Source/Python/AutoGen/IncludesAutoGen.py

-- 
2.20.1.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50360): https://edk2.groups.io/g/devel/message/50360
Mute This Topic: https://groups.io/mt/52516787/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [Patch 1/4] BaseTools: Add build option for dependency file generation

2019-11-11 Thread Bob Feng
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2311

Add /showIncludes for msvc and -MMD -MF $@.deps
for GCC and CLANG

Remove /MP for msvc since /MP does not work with
/showIncludes

Cc: Liming Gao 
Cc: Steven Shi 
Signed-off-by: Bob Feng 
---
 BaseTools/Conf/tools_def.template | 173 --
 1 file changed, 90 insertions(+), 83 deletions(-)

diff --git a/BaseTools/Conf/tools_def.template 
b/BaseTools/Conf/tools_def.template
index dce6c5875a23..0b7e73ff91b5 100755
--- a/BaseTools/Conf/tools_def.template
+++ b/BaseTools/Conf/tools_def.template
@@ -131,10 +131,11 @@ DEFINE IASL_OUTFLAGS   = -p
 
 DEFINE DEFAULT_WIN_ASL_BIN  = DEF(WIN_IASL_BIN)
 DEFINE DEFAULT_WIN_ASL_FLAGS= DEF(IASL_FLAGS)
 DEFINE DEFAULT_WIN_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
 
+DEFINE MSFT_DEPS_FLAGS = /showIncludes
 DEFINE MSFT_ASLPP_FLAGS= /nologo /E /C /FIAutoGen.h
 DEFINE MSFT_ASLCC_FLAGS= /nologo /c /FIAutoGen.h /TC 
/Dmain=ReferenceAcpiTable
 DEFINE MSFT_ASLDLINK_FLAGS = /NODEFAULTLIB /ENTRY:ReferenceAcpiTable 
/SUBSYSTEM:CONSOLE
 
 DEFINE IPHONE_TOOLS= 
/Developer/Platforms/iPhoneOS.platform/Developer
@@ -399,11 +400,11 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
 
 *_VS2008_*_SLINK_FLAGS= /NOLOGO /LTCG
 *_VS2008_*_APP_FLAGS  = /nologo /E /TC
 *_VS2008_*_PP_FLAGS   = /nologo /E /TC /FIAutoGen.h
 *_VS2008_*_VFRPP_FLAGS= /nologo /E /TC /DVFRCOMPILE 
/FI$(MODULE_NAME)StrDefs.h
-
+*_VS2008_*_DEPS_FLAGS= DEF(MSFT_DEPS_FLAGS)
 *_VS2008_*_ASM16_PATH = DEF(VS2008_BIN)\ml.exe
 
 ##
 # ASL definitions
 ##
@@ -462,13 +463,13 @@ NOOPT_VS2008_IA32_DLINK_FLAGS = /NOLOGO /NODEFAULTLIB 
/IGNORE:4001 /OPT:REF
 *_VS2008_X64_DLINK_PATH= DEF(VS2008_BINX64)\link.exe
 *_VS2008_X64_ASLCC_PATH= DEF(VS2008_BINX64)\cl.exe
 *_VS2008_X64_ASLPP_PATH= DEF(VS2008_BINX64)\cl.exe
 *_VS2008_X64_ASLDLINK_PATH = DEF(VS2008_BINX64)\link.exe
 
-  DEBUG_VS2008_X64_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE 
/O1b2s /GL /Gy /FIAutoGen.h /EHs-c- /GR- /GF /Z7 /MP
-RELEASE_VS2008_X64_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE 
/O1b2s /GL /Gy /FIAutoGen.h /EHs-c- /GR- /GF /MP
-NOOPT_VS2008_X64_CC_FLAGS   = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE 
/Gy /FIAutoGen.h /EHs-c- /GR- /GF /Z7 /Od /MP
+  DEBUG_VS2008_X64_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE 
/O1b2s /GL /Gy /FIAutoGen.h /EHs-c- /GR- /GF /Z7
+RELEASE_VS2008_X64_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE 
/O1b2s /GL /Gy /FIAutoGen.h /EHs-c- /GR- /GF
+NOOPT_VS2008_X64_CC_FLAGS   = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE 
/Gy /FIAutoGen.h /EHs-c- /GR- /GF /Z7 /Od
 
   DEBUG_VS2008_X64_ASM_FLAGS= /nologo /c /WX /W3 /Cx /Zd /Zi
 RELEASE_VS2008_X64_ASM_FLAGS= /nologo /c /WX /W3 /Cx /Zd
 NOOPT_VS2008_X64_ASM_FLAGS= /nologo /c /WX /W3 /Cx /Zd /Zi
 
@@ -515,11 +516,11 @@ NOOPT_VS2008_X64_DLINK_FLAGS  = /NOLOGO /NODEFAULTLIB 
/IGNORE:4001 /OPT:REF /OPT
 *_VS2008x86_*_MAKE_FLAGS  = /nologo
 *_VS2008x86_*_SLINK_FLAGS = /NOLOGO /LTCG
 *_VS2008x86_*_APP_FLAGS   = /nologo /E /TC
 *_VS2008x86_*_PP_FLAGS= /nologo /E /TC /FIAutoGen.h
 *_VS2008x86_*_VFRPP_FLAGS = /nologo /E /TC /DVFRCOMPILE 
/FI$(MODULE_NAME)StrDefs.h
-
+*_VS2008x86_*_DEPS_FLAGS  = DEF(MSFT_DEPS_FLAGS)
 *_VS2008x86_*_ASM16_PATH  = DEF(VS2008x86_BIN)\ml.exe
 
 ##
 # ASL definitions
 ##
@@ -546,13 +547,13 @@ NOOPT_VS2008_X64_DLINK_FLAGS  = /NOLOGO /NODEFAULTLIB 
/IGNORE:4001 /OPT:REF /OPT
 *_VS2008x86_IA32_APP_PATH = DEF(VS2008x86_BIN)\cl.exe
 *_VS2008x86_IA32_PP_PATH  = DEF(VS2008x86_BIN)\cl.exe
 *_VS2008x86_IA32_ASM_PATH = DEF(VS2008x86_BIN)\ml.exe
 
   *_VS2008x86_IA32_MAKE_FLAGS  = /nologo
-  DEBUG_VS2008x86_IA32_CC_FLAGS= /nologo /c /WX /GS- /W4 /Gs32768 /D 
UNICODE /O1b2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /Gy /Z7 /MP
-RELEASE_VS2008x86_IA32_CC_FLAGS= /nologo /c /WX /GS- /W4 /Gs32768 /D 
UNICODE /O1b2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /MP
-NOOPT_VS2008x86_IA32_CC_FLAGS  = /nologo /c /WX /GS- /W4 /Gs32768 /D 
UNICODE /FIAutoGen.h /EHs-c- /GR- /GF /Gy /Z7 /Od /MP
+  DEBUG_VS2008x86_IA32_CC_FLAGS= /nologo /c /WX /GS- /W4 /Gs32768 /D 
UNICODE /O1b2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /Gy /Z7
+RELEASE_VS2008x86_IA32_CC_FLAGS= /nologo /c /WX /GS- /W4 /Gs32768 /D 
UNICODE /O1b2 /GL /FIAutoGen.h /EHs-c- /GR- /GF
+NOOPT_VS2008x86_IA32_CC_FLAGS  = /nologo /c /WX /GS- /W4 /Gs32768 /D 
UNICODE /FIAutoGen.h /EHs-c- /GR- /GF /Gy /Z7 /Od
 
   DEBUG_VS2008x86_IA32_ASM_FLAGS   = /nologo /c /WX /W3 /Cx /coff /Zd /Zi
 RELEASE_VS2008x86_IA32_ASM_FLAGS   = /nologo /c /WX /W3 /Cx /coff /Zd
 NOOPT_VS2008x86_IA32_ASM_FLAGS = /nologo /c /WX /W3 /Cx /coff /Zd /Zi
 
@@ -578,14 +579,13 @@ NOOPT_VS2008x86_IA32_DLINK_FLAGS   = /NOLOGO 
/NODEFAULTLIB /IGNORE:4001 /OPT:REF
 

[edk2-devel] [Patch 2/4] BaseTools: Generate dependent files for ASL and ASM files

2019-11-11 Thread Bob Feng
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2311

Implement the function in Trim tool to get the included
file list for ASL and ASM file.

Cc: Liming Gao 
Cc: Steven Shi 
Signed-off-by: Bob Feng 
---
 BaseTools/Source/Python/Trim/Trim.py | 115 ++-
 1 file changed, 95 insertions(+), 20 deletions(-)

diff --git a/BaseTools/Source/Python/Trim/Trim.py 
b/BaseTools/Source/Python/Trim/Trim.py
index 24c3fafa76f9..c5638376e41a 100644
--- a/BaseTools/Source/Python/Trim/Trim.py
+++ b/BaseTools/Source/Python/Trim/Trim.py
@@ -54,10 +54,14 @@ gLongNumberPattern = 
re.compile("(?<=[^a-zA-Z0-9_])(0[xX][0-9a-fA-F]+|[0-9]+)U?L
 gAslIncludePattern = re.compile("^(\s*)[iI]nclude\s*\(\"?([^\"\(\)]+)\"\)", 
re.MULTILINE)
 ## Regular expression for matching C style #include "XXX.asl" in asl file
 gAslCIncludePattern = 
re.compile(r'^(\s*)#include\s*[<"]\s*([-\\/\w.]+)\s*([>"])', re.MULTILINE)
 ## Patterns used to convert EDK conventions to EDK2 ECP conventions
 
+## Regular expression for finding header file inclusions
+gIncludePattern = re.compile(r"^[ \t]*[%]?[ \t]*include(?:[ 
\t]*(?:\\(?:\r\n|\r|\n))*[ \t]*)*(?:\(?[\"<]?[ \t]*)([-\w.\\/() \t]+)(?:[ 
\t]*[\">]?\)?)", re.MULTILINE | re.UNICODE | re.IGNORECASE)
+
+
 ## file cache to avoid circular include in ASL file
 gIncludedAslFile = []
 
 ## Trim preprocessed source code
 #
@@ -251,13 +255,14 @@ def TrimPreprocessedVfr(Source, Target):
 # @param  IncludePathList   The list of external include file
 # @param  LocalSearchPath   If LocalSearchPath is specified, this path will be 
searched
 #   first for the included file; otherwise, only the 
path specified
 #   in the IncludePathList will be searched.
 #
-def DoInclude(Source, Indent='', IncludePathList=[], LocalSearchPath=None):
+def DoInclude(Source, Indent='', IncludePathList=[], LocalSearchPath=None, 
IncludeFileList = None, filetype=None):
 NewFileContent = []
-
+if IncludeFileList is None:
+IncludeFileList = []
 try:
 #
 # Search LocalSearchPath first if it is specified.
 #
 if LocalSearchPath:
@@ -286,28 +291,41 @@ def DoInclude(Source, Indent='', IncludePathList=[], 
LocalSearchPath=None):
 if IncludeFile in gIncludedAslFile:
 EdkLogger.warn("Trim", "Circular include",
ExtraData= "%s -> %s" % (" -> ".join(gIncludedAslFile), 
IncludeFile))
 return []
 gIncludedAslFile.append(IncludeFile)
-
+IncludeFileList.append(IncludeFile.strip())
 for Line in F:
 LocalSearchPath = None
-Result = gAslIncludePattern.findall(Line)
-if len(Result) == 0:
-Result = gAslCIncludePattern.findall(Line)
-if len(Result) == 0 or os.path.splitext(Result[0][1])[1].lower() 
not in [".asl", ".asi"]:
+if filetype == "ASL":
+Result = gAslIncludePattern.findall(Line)
+if len(Result) == 0:
+Result = gAslCIncludePattern.findall(Line)
+if len(Result) == 0 or 
os.path.splitext(Result[0][1])[1].lower() not in [".asl", ".asi"]:
+NewFileContent.append("%s%s" % (Indent, Line))
+continue
+#
+# We should first search the local directory if current file 
are using pattern #include "XXX"
+#
+if Result[0][2] == '"':
+LocalSearchPath = os.path.dirname(IncludeFile)
+CurrentIndent = Indent + Result[0][0]
+IncludedFile = Result[0][1]
+NewFileContent.extend(DoInclude(IncludedFile, CurrentIndent, 
IncludePathList, LocalSearchPath,IncludeFileList,filetype))
+NewFileContent.append("\n")
+elif filetype == "ASM":
+Result = gIncludePattern.findall(Line)
+if len(Result) == 0:
 NewFileContent.append("%s%s" % (Indent, Line))
 continue
-#
-# We should first search the local directory if current file are 
using pattern #include "XXX"
-#
-if Result[0][2] == '"':
-LocalSearchPath = os.path.dirname(IncludeFile)
-CurrentIndent = Indent + Result[0][0]
-IncludedFile = Result[0][1]
-NewFileContent.extend(DoInclude(IncludedFile, CurrentIndent, 
IncludePathList, LocalSearchPath))
-NewFileContent.append("\n")
+
+IncludedFile = Result[0]
+
+IncludedFile = IncludedFile.strip()
+IncludedFile = os.path.normpath(IncludedFile)
+NewFileContent.extend(DoInclude(IncludedFile, '', IncludePathList, 
LocalSearchPath,IncludeFileList,filetype))
+NewFileContent.append("\n")
 
 gIncludedAslFile.pop()
 
 return NewFileContent
 
@@ -318,11 +336,11 @@ def DoInclude(Source, Indent='', IncludePathList=[], 
LocalSearchPath=None):
 #
 # @param  Source  File to be trimmed
 # @param  Target  File to store the 

Re: [edk2-devel] [PATCH] EmulatorPkg/PlatformSmbiosDxe: fix a spell error of platform.

2019-11-11 Thread Philippe Mathieu-Daudé

On 11/11/19 8:18 AM, Tan, Ming wrote:

Old code use platfomr.
Change PlatfomrSmbiosDriverEntryPoint to PlatformSmbiosDriverEntryPoint.

Signed-off-by: Ming Tan 
---
  EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c   | 2 +-
  EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf | 2 +-
  2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c 
b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
index e6f8734600..48a3bfb5e9 100644
--- a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
+++ b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.c
@@ -82,7 +82,7 @@ CreatePlatformSmbiosMemoryRecords (
  **/
  EFI_STATUS
  EFIAPI
-PlatfomrSmbiosDriverEntryPoint (
+PlatformSmbiosDriverEntryPoint (
IN EFI_HANDLE ImageHandle,
IN EFI_SYSTEM_TABLE   *SystemTable
)
diff --git a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf 
b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
index 95b119e953..756f643c74 100644
--- a/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
+++ b/EmulatorPkg/PlatformSmbiosDxe/PlatformSmbiosDxe.inf
@@ -15,7 +15,7 @@
FILE_GUID  = 67FA951E-4FA2-9F4E-A658-4DBD954AC22E
MODULE_TYPE= DXE_DRIVER
VERSION_STRING = 1.0
-  ENTRY_POINT= PlatfomrSmbiosDriverEntryPoint
+  ENTRY_POINT= PlatformSmbiosDriverEntryPoint
  
  
  [Sources]




Reviewed-by: Philippe Mathieu-Daude 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50359): https://edk2.groups.io/g/devel/message/50359
Mute This Topic: https://groups.io/mt/52449861/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [Patch v5 19/22] .pytool: Add CISettings.py and Readme.md

2019-11-11 Thread Michael D Kinney
From: Sean Brogan 

Add main python script for EDK II Continuous Integration (CI)
builds along with a Readme.md that provides a summary of the
packages, platforms, and checks performs during a CI build.

Cc: Sean Brogan 
Cc: Bret Barkelew 
Cc: Liming Gao 
Signed-off-by: Michael D Kinney 
Reviewed-by: Liming Gao 
---
 .pytool/CISettings.py | 173 
 .pytool/Readme.md | 223 ++
 2 files changed, 396 insertions(+)
 create mode 100644 .pytool/CISettings.py
 create mode 100644 .pytool/Readme.md

diff --git a/.pytool/CISettings.py b/.pytool/CISettings.py
new file mode 100644
index 00..a78e8b974c
--- /dev/null
+++ b/.pytool/CISettings.py
@@ -0,0 +1,173 @@
+# @file
+#
+# Copyright (c) 2018, Microsoft Corporation
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+import os
+import logging
+from edk2toolext.environment import shell_environment
+from edk2toolext.invocables.edk2_ci_build import CiBuildSettingsManager
+from edk2toolext.invocables.edk2_setup import SetupSettingsManager, 
RequiredSubmodule
+from edk2toolext.invocables.edk2_update import UpdateSettingsManager
+from edk2toolext.invocables.edk2_pr_eval import PrEvalSettingsManager
+from edk2toollib.utility_functions import GetHostInfo
+
+
+class Settings(CiBuildSettingsManager, UpdateSettingsManager, 
SetupSettingsManager, PrEvalSettingsManager):
+
+def __init__(self):
+self.ActualPackages = []
+self.ActualTargets = []
+self.ActualArchitectures = []
+self.ActualToolChainTag = ""
+
+# 
###
 #
+# Extra CmdLine configuration  
   #
+# 
###
 #
+
+def AddCommandLineOptions(self, parserObj):
+pass
+
+def RetrieveCommandLineOptions(self, args):
+pass
+
+# 
###
 #
+#Default Support for this Ci Build 
   #
+# 
###
 #
+
+def GetPackagesSupported(self):
+''' return iterable of edk2 packages supported by this build.
+These should be edk2 workspace relative paths '''
+
+return ("MdePkg",
+"MdeModulePkg",
+"NetworkPkg",
+"PcAtChipsetPkg",
+"SecurityPkg",
+"UefiCpuPkg",
+"FmpDevicePkg",
+"ShellPkg",
+"FatPkg",
+"CryptoPkg"
+)
+
+def GetArchitecturesSupported(self):
+''' return iterable of edk2 architectures supported by this build '''
+return ("IA32",
+"X64",
+"ARM",
+"AARCH64")
+
+def GetTargetsSupported(self):
+''' return iterable of edk2 target tags supported by this build '''
+return ("DEBUG", "RELEASE", "NO-TARGET", "NOOPT")
+
+# 
###
 #
+# Verify and Save requested Ci Build Config
   #
+# 
###
 #
+
+def SetPackages(self, list_of_requested_packages):
+''' Confirm the requested package list is valid and configure 
SettingsManager
+to build the requested packages.
+
+Raise UnsupportedException if a requested_package is not supported
+'''
+unsupported = set(list_of_requested_packages) - \
+set(self.GetPackagesSupported())
+if(len(unsupported) > 0):
+logging.critical(
+"Unsupported Package Requested: " + " ".join(unsupported))
+raise Exception("Unsupported Package Requested: " +
+" ".join(unsupported))
+self.ActualPackages = list_of_requested_packages
+
+def SetArchitectures(self, list_of_requested_architectures):
+''' Confirm the requests architecture list is valid and configure 
SettingsManager
+to run only the requested architectures.
+
+Raise Exception if a list_of_requested_architectures is not supported
+'''
+unsupported = set(list_of_requested_architectures) - \
+set(self.GetArchitecturesSupported())
+if(len(unsupported) > 0):
+logging.critical(
+"Unsupported Architecture Requested: " + " ".join(unsupported))
+raise Exception(
+"Unsupported Architecture Requested: " + " ".join(unsupported))
+self.ActualArchitectures = list_of_requested_architectures
+
+def SetTargets(self, list_of_requested_target):
+   

[edk2-devel] [Patch v5 07/22] .pytool/Plugin: Add CI plugins

2019-11-11 Thread Michael D Kinney
From: Sean Brogan 

Add .pytool directory to the edk2 repository with the
following plugins.  These plugins are in a top level
directory because that can be used with all packages
and platforms.

* CharEncodingCheck
* CompilerPlugin
* DependencyCheck
* DscCompleteCheck
* GuidCheck
* LibraryClassCheck
* SpellCheck

Cc: Sean Brogan 
Cc: Bret Barkelew 
Cc: Liming Gao 
Signed-off-by: Michael D Kinney 
Reviewed-by: Liming Gao 
---
 .../CharEncodingCheck/CharEncodingCheck.py| 118 
 .../CharEncodingCheck_plug_in.yaml|  11 +
 .pytool/Plugin/CharEncodingCheck/Readme.md|  18 ++
 .../Plugin/CompilerPlugin/CompilerPlugin.py   | 102 +++
 .../CompilerPlugin/Compiler_plug_in.yaml  |  11 +
 .pytool/Plugin/CompilerPlugin/Readme.md   |  17 ++
 .../Plugin/DependencyCheck/DependencyCheck.py | 120 +
 .../DependencyCheck_plug_in.yaml  |  13 +
 .pytool/Plugin/DependencyCheck/Readme.md  |  31 +++
 .../DscCompleteCheck/DscCompleteCheck.py  | 118 
 .../DscCompleteCheck_plug_in.yaml |  12 +
 .pytool/Plugin/DscCompleteCheck/Readme.md |  27 ++
 .pytool/Plugin/GuidCheck/GuidCheck.py | 251 ++
 .../Plugin/GuidCheck/GuidCheck_plug_in.yaml   |  11 +
 .pytool/Plugin/GuidCheck/Readme.md|  80 ++
 .../LibraryClassCheck/LibraryClassCheck.py| 153 +++
 .../LibraryClassCheck_plug_in.yaml|  11 +
 .pytool/Plugin/LibraryClassCheck/Readme.md|  25 ++
 .pytool/Plugin/SpellCheck/Readme.md   | 127 +
 .pytool/Plugin/SpellCheck/SpellCheck.py   | 216 +++
 .../Plugin/SpellCheck/SpellCheck_plug_in.yaml |  11 +
 .pytool/Plugin/SpellCheck/cspell.base.yaml| 165 
 22 files changed, 1648 insertions(+)
 create mode 100644 .pytool/Plugin/CharEncodingCheck/CharEncodingCheck.py
 create mode 100644 
.pytool/Plugin/CharEncodingCheck/CharEncodingCheck_plug_in.yaml
 create mode 100644 .pytool/Plugin/CharEncodingCheck/Readme.md
 create mode 100644 .pytool/Plugin/CompilerPlugin/CompilerPlugin.py
 create mode 100644 .pytool/Plugin/CompilerPlugin/Compiler_plug_in.yaml
 create mode 100644 .pytool/Plugin/CompilerPlugin/Readme.md
 create mode 100644 .pytool/Plugin/DependencyCheck/DependencyCheck.py
 create mode 100644 .pytool/Plugin/DependencyCheck/DependencyCheck_plug_in.yaml
 create mode 100644 .pytool/Plugin/DependencyCheck/Readme.md
 create mode 100644 .pytool/Plugin/DscCompleteCheck/DscCompleteCheck.py
 create mode 100644 
.pytool/Plugin/DscCompleteCheck/DscCompleteCheck_plug_in.yaml
 create mode 100644 .pytool/Plugin/DscCompleteCheck/Readme.md
 create mode 100644 .pytool/Plugin/GuidCheck/GuidCheck.py
 create mode 100644 .pytool/Plugin/GuidCheck/GuidCheck_plug_in.yaml
 create mode 100644 .pytool/Plugin/GuidCheck/Readme.md
 create mode 100644 .pytool/Plugin/LibraryClassCheck/LibraryClassCheck.py
 create mode 100644 
.pytool/Plugin/LibraryClassCheck/LibraryClassCheck_plug_in.yaml
 create mode 100644 .pytool/Plugin/LibraryClassCheck/Readme.md
 create mode 100644 .pytool/Plugin/SpellCheck/Readme.md
 create mode 100644 .pytool/Plugin/SpellCheck/SpellCheck.py
 create mode 100644 .pytool/Plugin/SpellCheck/SpellCheck_plug_in.yaml
 create mode 100644 .pytool/Plugin/SpellCheck/cspell.base.yaml

diff --git a/.pytool/Plugin/CharEncodingCheck/CharEncodingCheck.py 
b/.pytool/Plugin/CharEncodingCheck/CharEncodingCheck.py
new file mode 100644
index 00..54a2424875
--- /dev/null
+++ b/.pytool/Plugin/CharEncodingCheck/CharEncodingCheck.py
@@ -0,0 +1,118 @@
+# @file CharEncodingCheck.py
+#
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+
+
+import os
+import logging
+from edk2toolext.environment.plugintypes.ci_build_plugin import ICiBuildPlugin
+from edk2toolext.environment.var_dict import VarDict
+
+##
+# map
+##
+EcodingMap = {
+".md": 'utf-8',
+".dsc": 'utf-8',
+".dec": 'utf-8',
+".c": 'utf-8',
+".h": 'utf-8',
+".asm": 'utf-8',
+".masm": 'utf-8',
+".nasm": 'utf-8',
+".s": 'utf-8',
+".inf": 'utf-8',
+".asl": 'utf-8',
+".uni": 'utf-8',
+".py": 'utf-8'
+}
+
+
+class CharEncodingCheck(ICiBuildPlugin):
+"""
+A CiBuildPlugin that scans each file in the code tree and confirms the 
encoding is correct.
+
+Configuration options:
+"CharEncodingCheck": {
+"IgnoreFiles": []
+}
+"""
+
+def GetTestName(self, packagename: str, environment: VarDict) -> tuple:
+""" Provide the testcase name and classname for use in reporting
+testclassname: a descriptive string for the testcase can include 
whitespace
+classname: should be patterned ..
+
+Args:
+  packagename: string containing name of package to build
+  environment: The VarDict for the test to run in
+Returns:
+a tuple containing the testcase name and the classname
+(testcasename, 

[edk2-devel] [Patch v5 21/22] .mergify: Add Mergify YML pull request rules configuration file

2019-11-11 Thread Michael D Kinney
Add directory for the Mergify YML configuration files that
provides rules and actions used to process a pull request.

* Auto commit a PR from EDK II Maintainer with 'push' label
  set and all CI checks pass
* Auto close a PR from any developers without 'push' label
  set and all CI checks pass.
* Auto close a PR from a non EDK II Maintainer that has
  the 'push' label set.
* Post a comment to a PR that has a merge conflict.
  Submitter can resolved conflicts and reopen the PR.
* Post a comment to a PR that fails PatchCheck.py
  Submitter can resolve PatchCheck.py issues and
  reopen the PR.

Cc: Liming Gao 
Cc: Sean Brogan 
Cc: Bret Barkelew 
Signed-off-by: Michael D Kinney 
Reviewed-by: Liming Gao 
---
 .mergify/config.yml | 97 +
 1 file changed, 97 insertions(+)
 create mode 100644 .mergify/config.yml

diff --git a/.mergify/config.yml b/.mergify/config.yml
new file mode 100644
index 00..26583de0f6
--- /dev/null
+++ b/.mergify/config.yml
@@ -0,0 +1,97 @@
+## @file
+# Mergify YML file that automatically merges a GitHub pull request against
+# edk2-ci if all of the GitHub branch protections have passed.  It also
+# contains rules to:
+# * auto close branches that are not from an EDK II Maintainer
+# * post a comment on pull requests that have merge conflicts.
+# * post a comment on pull requests that have PatchCheck.py errors.
+#
+# Configuration Notes:
+# * Update the 'base=edk2-ci' statements with the name of the branch to merge
+#   pull requests.
+#
+# * Update the 'status-failure' statement with the name of the name of the 
Azure
+#   Pipelines Build that performs the EDK II Maintainer check.
+#
+# * This file must be checked into the 'default' branch of a repo.  Copies
+#   of this file on other branches of a repo are ignored by Mergify.
+#
+# Copyright (c) 2019, Intel Corporation. All rights reserved.
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+# https://github.com/apps/mergify
+# https://doc.mergify.io/
+#
+##
+
+pull_request_rules:
+
+  - name: Automatically merge a PR when all required checks pass and 'push' 
label is present
+conditions:
+  - base=master
+  - label=push
+  - author=@tianocore/edk-ii-maintainers
+  - status-success=tianocore.PatchCheck
+  - status-success=Ubuntu GCC5 PR
+  - status-success=Windows VS2019 PR
+actions:
+  merge:
+strict: true
+method: rebase
+
+  - name: Automatically close a PR when all required checks pass and 'push' 
label is not present
+conditions:
+  - base=master
+  - -label=push
+  - -closed
+  - status-success=tianocore.PatchCheck
+  - status-success=Ubuntu GCC5 PR
+  - status-success=Windows VS2019 PR
+  - status-success=Ubuntu GCC5 PR (FINISHED)
+  - status-success=Windows VS2019 PR (FINISHED)
+actions:
+  close:
+message: All checks passed. Auto close personal build.
+
+  - name: Post a comment on a PR that can not be merged due to a merge conflict
+conditions:
+  - base=master
+  - conflict
+actions:
+  comment:
+message: PR can not be merged due to conflict.  Please rebase and 
resubmit
+
+  - name: Automatically close a PR that fails the EDK II Maintainers 
membership check and 'push' label is present
+conditions:
+  - base=master
+  - label=push
+  - -author=@tianocore/edk-ii-maintainers
+actions:
+  close:
+message: PR submitter is not a member of the Tianocore EDK II 
Maintainers team
+
+  - name: Post a comment on a PR if PatchCheck fails
+conditions:
+  - base=master
+  - status-failure=tianocore.PatchCheck
+actions:
+  comment:
+message: PR can not be merged due to a PatchCheck failure.  Please 
resolve and resubmit
+
+  - name: Post a comment on a PR if Ubuntu GCC5 fails
+conditions:
+  - base=master
+  - status-failure=Ubuntu GCC5 PR
+  - status-success=Ubuntu GCC5 PR (FAILED)
+actions:
+  comment:
+message: PR can not be merged due to an Ubuntu GCC5 failure.  Please 
resolve and resubmit
+
+  - name: Post a comment on a PR if Windows VS2019 fails
+conditions:
+  - base=master
+  - status-failure=Windows VS2019 PR
+  - status-success=Windows VS2019 PR (FAILED)
+actions:
+  comment:
+message: PR can not be merged due to a Windows VS2019 failure.  Please 
resolve and resubmit
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50356): https://edk2.groups.io/g/devel/message/50356
Mute This Topic: https://groups.io/mt/52458196/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [Patch v5 22/22] Readme.md: Add CI build status badges

2019-11-11 Thread Michael D Kinney
Update Readme.md with status badges from the most recent
EDK II Continuous Integration(CI) build.

Cc: Andrew Fish 
Cc: Laszlo Ersek 
Cc: Leif Lindholm 
Signed-off-by: Michael D Kinney 
Acked-by: Laszlo Ersek 
Reviewed-by: Liming Gao 
---
 Readme.md | 51 +++
 1 file changed, 51 insertions(+)

diff --git a/Readme.md b/Readme.md
index 27e4ce0771..c22cac9748 100644
--- a/Readme.md
+++ b/Readme.md
@@ -3,6 +3,57 @@
 A modern, feature-rich, cross-platform firmware development environment
 for the UEFI and PI specifications from www.uefi.org.
 
+# Build Status
+
+
+  
+Host Type
+Toolchain
+Branch
+Build Status
+Test Status
+Code Coverage
+  
+  
+Windows
+VS2019
+edk2-ci
+
+  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
+  https://dev.azure.com/tianocore/edk2-ci-play/_apis/build/status/edk2-staging/Windows%20VS2019%20CI?branchName=edk2-ci"/>
+
+
+  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
+  https://img.shields.io/azure-devops/tests/tianocore/edk2-ci-play/27.svg"/>
+
+
+  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=27=edk2-ci;>
+  https://img.shields.io/badge/coverage-coming_soon-blue"/>
+
+  
+  
+Ubuntu
+GCC
+edk2-ci
+
+  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
+  https://dev.azure.com/tianocore/edk2-ci-play/_apis/build/status/edk2-staging/Ubuntu%20GCC5%20CI?branchName=edk2-ci"/>
+
+
+  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
+  https://img.shields.io/azure-devops/tests/tianocore/edk2-ci-play/26.svg"/>
+
+
+  https://dev.azure.com/tianocore/edk2-ci-play/_build/latest?definitionId=26=edk2-ci;>
+  https://img.shields.io/badge/coverage-coming_soon-blue"/>
+
+  
+
+
+[More CI Build information](.pytool/Readme.md)
+
+# License Details
+
 The majority of the content in the EDK II open source project uses a
 [BSD-2-Clause Plus Patent License](License.txt).  The EDK II open source 
project
 contains the following components that are covered by additional licenses:
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50358): https://edk2.groups.io/g/devel/message/50358
Mute This Topic: https://groups.io/mt/52458201/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [Patch v5 18/22] SignedCapsulePkg: Use BaseCryptLibNull to reduce package CI time

2019-11-11 Thread Michael D Kinney
Use BaseCryptLibNull for package CI builds to reduce package
build times.  Enabled with PYTOOL_CONTINUOUS_INTEGRATION in YAML
files.  By default PYTOOL_CONTINUOUS_INTEGRATION is not defined,
and the original lib mappings are preserved.

Cc: Jiewen Yao 
Cc: Chao Zhang 
Signed-off-by: Michael D Kinney 
Reviewed-by: Liming Gao 
---
 SignedCapsulePkg/SignedCapsulePkg.dsc | 38 +--
 1 file changed, 36 insertions(+), 2 deletions(-)

diff --git a/SignedCapsulePkg/SignedCapsulePkg.dsc 
b/SignedCapsulePkg/SignedCapsulePkg.dsc
index 03f714f9a7..c5080ec1dd 100644
--- a/SignedCapsulePkg/SignedCapsulePkg.dsc
+++ b/SignedCapsulePkg/SignedCapsulePkg.dsc
@@ -87,8 +87,6 @@ [LibraryClasses]
   
AuthVariableLib|MdeModulePkg/Library/AuthVariableLibNull/AuthVariableLibNull.inf
   VarCheckLib|MdeModulePkg/Library/VarCheckLib/VarCheckLib.inf
   FileExplorerLib|MdeModulePkg/Library/FileExplorerLib/FileExplorerLib.inf
-  IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf
-  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
 
   
EdkiiSystemCapsuleLib|SignedCapsulePkg/Library/EdkiiSystemCapsuleLib/EdkiiSystemCapsuleLib.inf
   IniParsingLib|SignedCapsulePkg/Library/IniParsingLib/IniParsingLib.inf
@@ -116,7 +114,13 @@ [LibraryClasses.common.PEIM]
   HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
   
MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf
   LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxPeiLib.inf
+!ifdef CONTINUOUS_INTEGRATION
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLibNull/BaseCryptLibNull.inf
+!else
+  IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf
+  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
   BaseCryptLib|CryptoPkg/Library/BaseCryptLib/PeiCryptLib.inf
+!endif
 
 [LibraryClasses.common.DXE_CORE]
   HobLib|MdePkg/Library/DxeCoreHobLib/DxeCoreHobLib.inf
@@ -125,7 +129,13 @@ [LibraryClasses.common.DXE_CORE]
 [LibraryClasses.common.DXE_DRIVER]
   HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
   
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
+!ifdef CONTINUOUS_INTEGRATION
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLibNull/BaseCryptLibNull.inf
+!else
+  IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf
+  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
   BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf
+!endif
 
   CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.inf
 
@@ -133,7 +143,13 @@ [LibraryClasses.common.DXE_RUNTIME_DRIVER]
   HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
   
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
   DebugLib|MdePkg/Library/UefiDebugLibConOut/UefiDebugLibConOut.inf
+!ifdef CONTINUOUS_INTEGRATION
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLibNull/BaseCryptLibNull.inf
+!else
+  IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf
+  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
   BaseCryptLib|CryptoPkg/Library/BaseCryptLib/RuntimeCryptLib.inf
+!endif
 
   CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibFmp/DxeRuntimeCapsuleLib.inf
 
@@ -150,19 +166,37 @@ [LibraryClasses.common.DXE_SMM_DRIVER]
   
MemoryAllocationLib|MdePkg/Library/SmmMemoryAllocationLib/SmmMemoryAllocationLib.inf
   
SmmServicesTableLib|MdePkg/Library/SmmServicesTableLib/SmmServicesTableLib.inf
   SmmMemLib|MdePkg/Library/SmmMemLib/SmmMemLib.inf
+!ifdef CONTINUOUS_INTEGRATION
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLibNull/BaseCryptLibNull.inf
+!else
+  IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf
+  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
   BaseCryptLib|CryptoPkg/Library/BaseCryptLib/SmmCryptLib.inf
+!endif
 
 [LibraryClasses.common.UEFI_DRIVER]
   HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
   
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
   DebugLib|MdePkg/Library/UefiDebugLibConOut/UefiDebugLibConOut.inf
+!ifdef CONTINUOUS_INTEGRATION
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLibNull/BaseCryptLibNull.inf
+!else
+  IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf
+  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
   BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf
+!endif
 
 [LibraryClasses.common.UEFI_APPLICATION]
   HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
   
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
   DebugLib|MdePkg/Library/UefiDebugLibStdErr/UefiDebugLibStdErr.inf
+!ifdef CONTINUOUS_INTEGRATION
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLibNull/BaseCryptLibNull.inf
+!else
+  IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf
+  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
   BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf
+!endif
 
 [PcdsFixedAtBuild]
   gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x0f
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive 

[edk2-devel] [Patch v5 08/22] CryptoPkg: Add YAML file for CI builds

2019-11-11 Thread Michael D Kinney
Add YAML file to the package directory with the
configuration of the checks to perform during a
CI build.

Cc: Jian J Wang 
Cc: Xiaoyu Lu 
Signed-off-by: Kinney 
Reviewed-by: Jian J Wang 
Reviewed-by: Liming Gao 
---
 CryptoPkg/CryptoPkg.ci.yaml | 47 +
 1 file changed, 47 insertions(+)
 create mode 100644 CryptoPkg/CryptoPkg.ci.yaml

diff --git a/CryptoPkg/CryptoPkg.ci.yaml b/CryptoPkg/CryptoPkg.ci.yaml
new file mode 100644
index 00..f54ebfb22e
--- /dev/null
+++ b/CryptoPkg/CryptoPkg.ci.yaml
@@ -0,0 +1,47 @@
+## @file
+# CI configuration for CryptoPkg
+#
+# Copyright (c) Microsoft Corporation
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+{
+"CompilerPlugin": {
+"DscPath": "CryptoPkg.dsc"
+},
+"CharEncodingCheck": {
+"IgnoreFiles": []
+},
+"DependencyCheck": {
+"AcceptableDependencies": [
+"MdePkg/MdePkg.dec",
+"MdeModulePkg/MdeModulePkg.dec",
+"CryptoPkg/CryptoPkg.dec",
+],
+# For host based unit tests
+"AcceptableDependencies-HOST_APPLICATION":[],
+# For UEFI shell based apps
+"AcceptableDependencies-UEFI_APPLICATION":[],
+"IgnoreInf": []
+},
+"DscCompleteCheck": {
+"DscPath": "CryptoPkg.dsc",
+"IgnoreInf": []
+},
+"GuidCheck": {
+"IgnoreGuidName": [],
+"IgnoreGuidValue": [],
+"IgnoreFoldersAndFiles": []
+},
+"LibraryClassCheck": {
+"IgnoreHeaderFile": []
+},
+
+## options defined ci/Plugin/SpellCheck
+"SpellCheck": {
+"skip": True,
+"IgnoreFiles": [],   # use gitignore syntax to ignore errors 
in matching files
+"ExtendWords": [],   # words to extend to the dictionary for 
this package
+"IgnoreStandardPaths": [],   # Standard Plugin defined paths that 
should be ignore
+"AdditionalIncludePaths": [] # Additional paths to spell check 
(wildcards supported)
+}
+}
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50351): https://edk2.groups.io/g/devel/message/50351
Mute This Topic: https://groups.io/mt/52458175/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [Patch v5 11/22] MdeModulePkg: Add YAML file for CI builds

2019-11-11 Thread Michael D Kinney
Add YAML file to the package directory with the
configuration of the checks to perform during a
CI build.

Cc: Jian J Wang 
Cc: Hao A Wu 
Signed-off-by: Michael D Kinney 
Reviewed-by: Hao A Wu 
Reviewed-by: Liming Gao 
---
 MdeModulePkg/MdeModulePkg.ci.yaml | 80 +++
 1 file changed, 80 insertions(+)
 create mode 100644 MdeModulePkg/MdeModulePkg.ci.yaml

diff --git a/MdeModulePkg/MdeModulePkg.ci.yaml 
b/MdeModulePkg/MdeModulePkg.ci.yaml
new file mode 100644
index 00..0bf149f205
--- /dev/null
+++ b/MdeModulePkg/MdeModulePkg.ci.yaml
@@ -0,0 +1,80 @@
+## @file
+# CI configuration for MdeModulePkg
+#
+# Copyright (c) Microsoft Corporation
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+{
+## options defined ci/Plugin/CompilerPlugin
+"CompilerPlugin": {
+"DscPath": "MdeModulePkg.dsc"
+},
+
+## options defined ci/Plugin/CharEncodingCheck
+"CharEncodingCheck": {
+"IgnoreFiles": []
+},
+
+## options defined ci/Plugin/DependencyCheck
+"DependencyCheck": {
+"AcceptableDependencies": [
+"MdePkg/MdePkg.dec",
+"MdeModulePkg/MdeModulePkg.dec",
+"StandaloneMmPkg/StandaloneMmPkg.dec",
+"ArmPkg/ArmPkg.dec"  # this should be fixed by promoting an 
abstraction
+],
+# For host based unit tests
+"AcceptableDependencies-HOST_APPLICATION":[],
+# For UEFI shell based apps
+"AcceptableDependencies-UEFI_APPLICATION":[],
+"IgnoreInf": []
+},
+
+## options defined ci/Plugin/DscCompleteCheck
+"DscCompleteCheck": {
+"IgnoreInf": [],
+"DscPath": "MdeModulePkg.dsc"
+},
+
+## options defined ci/Plugin/GuidCheck
+"GuidCheck": {
+"IgnoreGuidName": [],
+"IgnoreGuidValue": ["----"],
+"IgnoreFoldersAndFiles": [],
+"IgnoreDuplicates": [
+"gEdkiiFormBrowserExProtocolGuid=gEfiFormBrowserExProtocolGuid",
+"gEfiPeiMmAccessPpiGuid=gPeiSmmAccessPpiGuid",
+"gPeiSmmControlPpiGuid=gEfiPeiMmControlPpiGuid",
+]
+},
+
+## options defined ci/Plugin/LibraryClassCheck
+"LibraryClassCheck": {
+"IgnoreHeaderFile": []
+},
+
+## options defined ci/Plugin/SpellCheck
+"SpellCheck": {
+"AuditOnly": True,   # Fails test but run in AuditOnly mode to 
collect log
+"IgnoreStandardPaths": [ # Standard Plugin defined paths that 
should be ignore
+"*.c", "*.asm", "*.h", "*.nasm", "*.s", "*.asl", "*.inf"
+],
+"IgnoreFiles": [ # use gitignore syntax to ignore errors 
in matching files
+"Library/LzmaCustomDecompressLib/Sdk/DOC/*"
+],
+"ExtendWords": [   # words to extend to the dictionary for 
this package
+"LIGHTGRAY",
+"DARKGRAY",
+"LIGHTBLUE",
+"LIGHTGREEN",
+"LIGHTCYAN",
+"LIGHTRED",
+"LIGHTMAGENTA",
+"FVMAIN",
+"VARCHECKPCD",
+"Getxx",
+"lzturbo"
+],
+"AdditionalIncludePaths": [] # Additional paths to spell check 
relative to package root (wildcards supported)
+}
+}
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50349): https://edk2.groups.io/g/devel/message/50349
Mute This Topic: https://groups.io/mt/52458169/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [Patch v5 09/22] FatPkg: Add YAML file for CI builds

2019-11-11 Thread Michael D Kinney
Add YAML file to the package directory with the
configuration of the checks to perform during a
CI build.

Cc: Ray Ni 
Signed-off-by: Michael D Kinney 
Acked-by: Ray Ni 
Reviewed-by: Liming Gao 
---
 FatPkg/FatPkg.ci.yaml | 50 +++
 1 file changed, 50 insertions(+)
 create mode 100644 FatPkg/FatPkg.ci.yaml

diff --git a/FatPkg/FatPkg.ci.yaml b/FatPkg/FatPkg.ci.yaml
new file mode 100644
index 00..8b0fb1d4fc
--- /dev/null
+++ b/FatPkg/FatPkg.ci.yaml
@@ -0,0 +1,50 @@
+## @file
+# CI configuration for FatPkg
+#
+# Copyright (c) Microsoft Corporation
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+{
+"CompilerPlugin": {
+"DscPath": "FatPkg.dsc"
+},
+"CharEncodingCheck": {
+"IgnoreFiles": []
+},
+"DependencyCheck": {
+"AcceptableDependencies": [
+"MdePkg/MdePkg.dec",
+"MdeModulePkg/MdeModulePkg.dec",
+],
+# For host based unit tests
+"AcceptableDependencies-HOST_APPLICATION":[],
+# For UEFI shell based apps
+"AcceptableDependencies-UEFI_APPLICATION":[],
+"IgnoreInf": []
+},
+"DscCompleteCheck": {
+"IgnoreInf": [],
+"DscPath": "FatPkg.dsc"
+},
+"GuidCheck": {
+"IgnoreGuidName": [],
+"IgnoreGuidValue": [],
+"IgnoreFoldersAndFiles": []
+},
+"LibraryClassCheck": {
+"IgnoreHeaderFile": []
+},
+"SpellCheck": {
+"ExtendWords": [
+"ELTORITO",
+"FHAND",
+"IFILE",
+"OFILE",
+"FDISKed",
+"Lfnbuffer",
+"L",
+"CDVOL",
+"DMDEPKG"
+]
+}
+}
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50352): https://edk2.groups.io/g/devel/message/50352
Mute This Topic: https://groups.io/mt/52458181/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [Patch v5 10/22] FmpDevicePkg: Add YAML file for CI builds

2019-11-11 Thread Michael D Kinney
Add YAML file to the package directory with the
configuration of the checks to perform during a
CI build.

Use BaseCryptLibNull for package CI builds to reduce package
build times.  Enabled with CONTINUOUS_INTEGRATION in YAML
files.  By default CONTINUOUS_INTEGRATION is not defined,
and the original lib mappings are preserved.

Cc: Liming Gao 
Signed-off-by: Michael D Kinney 
Reviewed-by: Liming Gao 
---
 FmpDevicePkg/FmpDevicePkg.ci.yaml | 43 +++
 FmpDevicePkg/FmpDevicePkg.dsc |  6 -
 2 files changed, 48 insertions(+), 1 deletion(-)
 create mode 100644 FmpDevicePkg/FmpDevicePkg.ci.yaml

diff --git a/FmpDevicePkg/FmpDevicePkg.ci.yaml 
b/FmpDevicePkg/FmpDevicePkg.ci.yaml
new file mode 100644
index 00..c17b355d42
--- /dev/null
+++ b/FmpDevicePkg/FmpDevicePkg.ci.yaml
@@ -0,0 +1,43 @@
+## @file
+# CI configuration for FmpDevicePkg
+#
+# Copyright (c) Microsoft Corporation
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+{
+"CompilerPlugin": {
+"DscPath": "FmpDevicePkg.dsc"
+},
+"CharEncodingCheck": {
+"IgnoreFiles": []
+},
+"DependencyCheck": {
+"AcceptableDependencies": [
+"MdePkg/MdePkg.dec",
+"MdeModulePkg/MdeModulePkg.dec",
+"FmpDevicePkg/FmpDevicePkg.dec",
+"CryptoPkg/CryptoPkg.dec"
+],
+"IgnoreInf": []
+},
+"DscCompleteCheck": {
+"DscPath": "FmpDevicePkg.dsc",
+"IgnoreInf": []
+},
+"GuidCheck": {
+"IgnoreGuidName": [],
+"IgnoreGuidValue": [],
+"IgnoreFoldersAndFiles": []
+},
+"LibraryClassCheck": {
+"IgnoreHeaderFile": []
+},
+"SpellCheck": {
+"ExtendWords": [
+"FMPSTATE",
+]
+},
+"Defines": {
+"BLD_*_CONTINUOUS_INTEGRATION": "TRUE",
+}
+}
diff --git a/FmpDevicePkg/FmpDevicePkg.dsc b/FmpDevicePkg/FmpDevicePkg.dsc
index 67b5aa7a32..f4093d3837 100644
--- a/FmpDevicePkg/FmpDevicePkg.dsc
+++ b/FmpDevicePkg/FmpDevicePkg.dsc
@@ -48,9 +48,13 @@ [LibraryClasses]
   DebugLib|MdePkg/Library/UefiDebugLibStdErr/UefiDebugLibStdErr.inf
   
DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf
   PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
-  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
+!ifdef CONTINUOUS_INTEGRATION
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLibNull/BaseCryptLibNull.inf
+!else
   IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf
+  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf
   BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf
+!endif
   
FmpAuthenticationLib|SecurityPkg/Library/FmpAuthenticationLibPkcs7/FmpAuthenticationLibPkcs7.inf
   
CapsuleUpdatePolicyLib|FmpDevicePkg/Library/CapsuleUpdatePolicyLibNull/CapsuleUpdatePolicyLibNull.inf
   
FmpPayloadHeaderLib|FmpDevicePkg/Library/FmpPayloadHeaderLibV1/FmpPayloadHeaderLibV1.inf
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50350): https://edk2.groups.io/g/devel/message/50350
Mute This Topic: https://groups.io/mt/52458174/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



  1   2   >