Re: [edk2-devel] [PATCH V4 0/3] Rename VmgExitLib to CcExitLib

2022-11-10 Thread Ni, Ray
Reviewed-by: Ray Ni 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96186): https://edk2.groups.io/g/devel/message/96186
Mute This Topic: https://groups.io/mt/94881760/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH v1 1/1] .github/dependabot.yml: Enable dependabot

2022-11-10 Thread Michael Kubacki
From: Michael Kubacki 

Enables dependabot in this repo so we can better alerted when
dependency updates are available.

This GitHub action will automatically create pull requests and
summarize the dependency details. Because it is a pull request,
the CI system will validate the dependency update in the pull
request.

Configures dependabot for:

1. PIP module updates
2. Submodule updates
3. GitHub action updates

The maintainers/reviewers of the .github directory were added as
pull request reviewers so they can be notified when the pull request
is available.

Cc: Sean Brogan 
Cc: Michael D Kinney 
Signed-off-by: Michael Kubacki 
---

Notes:
An example of the pull requests created by this change
are available on my edk2 fork:

https://github.com/makubacki/edk2/pulls

 .github/dependabot.yml | 45 
 1 file changed, 45 insertions(+)

diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index ..7f405721fd3d
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,45 @@
+## @file
+# Dependabot configuration file to enable GitHub services for managing and 
updating
+# dependencies.
+#
+# Copyright (c) Microsoft Corporation.
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+# Please see the documentation for all configuration options:
+# 
https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
+##
+version: 2
+updates:
+  - package-ecosystem: "pip"
+directory: "/"
+schedule:
+  interval: "daily"
+commit-message:
+  prefix: "pip"
+reviewers:
+  - "makubacki"
+  - "mdkinney"
+  - "spbrogan"
+
+  - package-ecosystem: "gitsubmodule"
+directory: "/"
+schedule:
+  interval: "daily"
+commit-message:
+  prefix: "submodule"
+reviewers:
+  - "makubacki"
+  - "mdkinney"
+  - "spbrogan"
+
+  - package-ecosystem: "github-actions"
+directory: "/"
+schedule:
+  interval: "weekly"
+  day: "monday"
+commit-message:
+  prefix: "GitHub Action"
+reviewers:
+  - "makubacki"
+  - "mdkinney"
+  - "spbrogan"
-- 
2.28.0.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96187): https://edk2.groups.io/g/devel/message/96187
Mute This Topic: https://groups.io/mt/94935824/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL without virtio-rng

2022-11-10 Thread Ard Biesheuvel
Currently, we only expose EFI_RNG_PROTOCOL when running under QEMU if it
exposes a virtio-rng device. This means that generic EFI apps or
loaders have no access to an entropy source if this device is
unavailable, unless they implement their own arch-specific handling to
figure out whether any CPU instructions or monitor calls can be used
instead.

So let's wire those up as EFI_RNG_PROTOCOL implementations as well,
using the existing drivers and libraries.

First patch is a bugfix - Liming, mind if I merge that right away?
Thanks.

Cc: Liming Gao 
Cc: Rebecca Cran 
Cc: Pierre Gondois 
Cc: Leif Lindholm 
Cc: Sami Mujawar 
Cc: Gerd Hoffmann 
Cc: Jason A. Donenfeld 

Ard Biesheuvel (3):
  ArmPkg/ArmTrngLib: Fix incorrect GUID reference in DEBUG() output
  ArmVirtPkg/ArmVirtQemu: Expose TRNG hypercall via RngDxe if
implemented
  OvmfPkg/OvmfX86: Enable RDRAND based EFI_RNG_PROTOCOL implementation

 ArmPkg/Library/ArmTrngLib/ArmTrngLib.c |  2 +-
 ArmVirtPkg/ArmVirtQemu.dsc | 11 +++
 ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc   |  5 +
 ArmVirtPkg/ArmVirtQemuKernel.dsc   | 11 +++
 OvmfPkg/OvmfPkgIa32.dsc|  1 +
 OvmfPkg/OvmfPkgIa32.fdf|  1 +
 OvmfPkg/OvmfPkgIa32X64.dsc |  1 +
 OvmfPkg/OvmfPkgIa32X64.fdf |  1 +
 OvmfPkg/OvmfPkgX64.dsc |  1 +
 OvmfPkg/OvmfPkgX64.fdf |  1 +
 10 files changed, 34 insertions(+), 1 deletion(-)

-- 
2.35.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96188): https://edk2.groups.io/g/devel/message/96188
Mute This Topic: https://groups.io/mt/94935839/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH 1/3] ArmPkg/ArmTrngLib: Fix incorrect GUID reference in DEBUG() output

2022-11-10 Thread Ard Biesheuvel
ArmTrngLib crashes when run in DEBUG mode due to the fact that it passed
the [truncated] GUID value to a DEBUG() print statement instead of a
pointer to the GUID which is what the %g conversion expects.

Signed-off-by: Ard Biesheuvel 
---
 ArmPkg/Library/ArmTrngLib/ArmTrngLib.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ArmPkg/Library/ArmTrngLib/ArmTrngLib.c 
b/ArmPkg/Library/ArmTrngLib/ArmTrngLib.c
index b974a9423880..fdabc02cd39c 100644
--- a/ArmPkg/Library/ArmTrngLib/ArmTrngLib.c
+++ b/ArmPkg/Library/ArmTrngLib/ArmTrngLib.c
@@ -375,7 +375,7 @@ ArmTrngLibConstructor (
 "FW-TRNG: Version %d.%d, GUID {%g}\n",
 MajorRev,
 MinorRev,
-Guid
+&Guid
 ));
 
   DEBUG_CODE_END ();
-- 
2.35.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96189): https://edk2.groups.io/g/devel/message/96189
Mute This Topic: https://groups.io/mt/94935840/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH 2/3] ArmVirtPkg/ArmVirtQemu: Expose TRNG hypercall via RngDxe if implemented

2022-11-10 Thread Ard Biesheuvel
Currently, we only expose the EFI_RNG_PROTOCOL in ArmVirtQemu if QEMU
provides a virtio-rng device, and it doesn't do so by default.

Given that KVM exposes the ARM architected TRNG service (and has done so
for a while now), let's incorporate the RngDxe driver which has recently
grown support for the ARM firmware/hypervisor service.

If both the service and the virtio device are available, two
implementations of the RNG protocol will be exposed, but this is fine:
callers that don't care about the distinction will grab the first one
available.

Signed-off-by: Ard Biesheuvel 
---
 ArmVirtPkg/ArmVirtQemu.dsc   | 11 +++
 ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc |  5 +
 ArmVirtPkg/ArmVirtQemuKernel.dsc | 11 +++
 3 files changed, 27 insertions(+)

diff --git a/ArmVirtPkg/ArmVirtQemu.dsc b/ArmVirtPkg/ArmVirtQemu.dsc
index f77443229e8e..1771ad562225 100644
--- a/ArmVirtPkg/ArmVirtQemu.dsc
+++ b/ArmVirtPkg/ArmVirtQemu.dsc
@@ -140,6 +140,8 @@ [PcdsFeatureFlag.common]
 
   gArmVirtTokenSpaceGuid.PcdTpm2SupportEnabled|$(TPM2_ENABLE)
 
+  gArmTokenSpaceGuid.PcdMonitorConduitHvc|TRUE
+
 [PcdsFixedAtBuild.common]
 !if $(ARCH) == AARCH64
   gArmTokenSpaceGuid.PcdVFPEnabled|1
@@ -442,6 +444,15 @@ [Components.common]
   OvmfPkg/VirtioNetDxe/VirtioNet.inf
   OvmfPkg/VirtioRngDxe/VirtioRng.inf
 
+  #
+  # Rng Support
+  #
+  SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf {
+
+  ArmMonitorLib|ArmPkg/Library/ArmMonitorLib/ArmMonitorLib.inf
+  ArmTrngLib|ArmPkg/Library/ArmTrngLib/ArmTrngLib.inf
+  }
+
   #
   # FAT filesystem + GPT/MBR partitioning + UDF filesystem + virtio-fs
   #
diff --git a/ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc 
b/ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc
index e06ca7424476..75c75a2d9a17 100644
--- a/ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc
+++ b/ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc
@@ -99,6 +99,11 @@ [FV.FvMain]
   INF OvmfPkg/VirtioScsiDxe/VirtioScsi.inf
   INF OvmfPkg/VirtioRngDxe/VirtioRng.inf
 
+  #
+  # Rng Support
+  #
+  INF SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf
+
   INF ShellPkg/Application/Shell/Shell.inf
   INF ShellPkg/DynamicCommand/TftpDynamicCommand/TftpDynamicCommand.inf
   INF ShellPkg/DynamicCommand/HttpDynamicCommand/HttpDynamicCommand.inf
diff --git a/ArmVirtPkg/ArmVirtQemuKernel.dsc b/ArmVirtPkg/ArmVirtQemuKernel.dsc
index f5db3ac432f3..abe0cbab8295 100644
--- a/ArmVirtPkg/ArmVirtQemuKernel.dsc
+++ b/ArmVirtPkg/ArmVirtQemuKernel.dsc
@@ -114,6 +114,8 @@ [PcdsFeatureFlag.common]
 
   gEfiMdeModulePkgTokenSpaceGuid.PcdTurnOffUsbLegacySupport|TRUE
 
+  gArmTokenSpaceGuid.PcdMonitorConduitHvc|TRUE
+
 [PcdsFixedAtBuild.common]
 !if $(ARCH) == AARCH64
   gArmTokenSpaceGuid.PcdVFPEnabled|1
@@ -350,6 +352,15 @@ [Components.common]
   OvmfPkg/VirtioNetDxe/VirtioNet.inf
   OvmfPkg/VirtioRngDxe/VirtioRng.inf
 
+  #
+  # Rng Support
+  #
+  SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf {
+
+  ArmMonitorLib|ArmPkg/Library/ArmMonitorLib/ArmMonitorLib.inf
+  ArmTrngLib|ArmPkg/Library/ArmTrngLib/ArmTrngLib.inf
+  }
+
   #
   # FAT filesystem + GPT/MBR partitioning + UDF filesystem + virtio-fs
   #
-- 
2.35.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96190): https://edk2.groups.io/g/devel/message/96190
Mute This Topic: https://groups.io/mt/94935841/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH 3/3] OvmfPkg/OvmfX86: Enable RDRAND based EFI_RNG_PROTOCOL implementation

2022-11-10 Thread Ard Biesheuvel
Expose the EFI_RNG_PROTOCOL based on RdRand, so that we don't have to
rely on QEMU providing a virtio-rng device in order to implement this
protocol.

Signed-off-by: Ard Biesheuvel 
---
 OvmfPkg/OvmfPkgIa32.dsc| 1 +
 OvmfPkg/OvmfPkgIa32.fdf| 1 +
 OvmfPkg/OvmfPkgIa32X64.dsc | 1 +
 OvmfPkg/OvmfPkgIa32X64.fdf | 1 +
 OvmfPkg/OvmfPkgX64.dsc | 1 +
 OvmfPkg/OvmfPkgX64.fdf | 1 +
 6 files changed, 6 insertions(+)

diff --git a/OvmfPkg/OvmfPkgIa32.dsc b/OvmfPkg/OvmfPkgIa32.dsc
index e9ba491237ae..18c1e7255812 100644
--- a/OvmfPkg/OvmfPkgIa32.dsc
+++ b/OvmfPkg/OvmfPkgIa32.dsc
@@ -941,6 +941,7 @@ [Components]
   }
 !endif
 
+  SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf
 !if $(SECURE_BOOT_ENABLE) == TRUE
   SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
   OvmfPkg/EnrollDefaultKeys/EnrollDefaultKeys.inf
diff --git a/OvmfPkg/OvmfPkgIa32.fdf b/OvmfPkg/OvmfPkgIa32.fdf
index 7023ade8cebe..34f27ca832bc 100644
--- a/OvmfPkg/OvmfPkgIa32.fdf
+++ b/OvmfPkg/OvmfPkgIa32.fdf
@@ -248,6 +248,7 @@ [FV.DXEFV]
 INF  OvmfPkg/LsiScsiDxe/LsiScsiDxe.inf
 !endif
 
+  INF  SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf
 !if $(SECURE_BOOT_ENABLE) == TRUE
   INF  
SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
 !endif
diff --git a/OvmfPkg/OvmfPkgIa32X64.dsc b/OvmfPkg/OvmfPkgIa32X64.dsc
index af566b953f36..e9a199c9f490 100644
--- a/OvmfPkg/OvmfPkgIa32X64.dsc
+++ b/OvmfPkg/OvmfPkgIa32X64.dsc
@@ -955,6 +955,7 @@ [Components.X64]
   }
 !endif
 
+  SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf
 !if $(SECURE_BOOT_ENABLE) == TRUE
   SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
   OvmfPkg/EnrollDefaultKeys/EnrollDefaultKeys.inf
diff --git a/OvmfPkg/OvmfPkgIa32X64.fdf b/OvmfPkg/OvmfPkgIa32X64.fdf
index 80de4fa2c0df..33cc163e596e 100644
--- a/OvmfPkg/OvmfPkgIa32X64.fdf
+++ b/OvmfPkg/OvmfPkgIa32X64.fdf
@@ -249,6 +249,7 @@ [FV.DXEFV]
 INF  OvmfPkg/LsiScsiDxe/LsiScsiDxe.inf
 !endif
 
+  INF  SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf
 !if $(SECURE_BOOT_ENABLE) == TRUE
   INF  
SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
 !endif
diff --git a/OvmfPkg/OvmfPkgX64.dsc b/OvmfPkg/OvmfPkgX64.dsc
index f39d9cd117e6..5572cb82998f 100644
--- a/OvmfPkg/OvmfPkgX64.dsc
+++ b/OvmfPkg/OvmfPkgX64.dsc
@@ -1023,6 +1023,7 @@ [Components]
   }
 !endif
 
+  SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf
 !if $(SECURE_BOOT_ENABLE) == TRUE
   SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
   OvmfPkg/EnrollDefaultKeys/EnrollDefaultKeys.inf
diff --git a/OvmfPkg/OvmfPkgX64.fdf b/OvmfPkg/OvmfPkgX64.fdf
index c0f5a1ef3c30..d42deebe3f8f 100644
--- a/OvmfPkg/OvmfPkgX64.fdf
+++ b/OvmfPkg/OvmfPkgX64.fdf
@@ -274,6 +274,7 @@ [FV.DXEFV]
 INF  OvmfPkg/LsiScsiDxe/LsiScsiDxe.inf
 !endif
 
+INF  SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf
 !if $(SECURE_BOOT_ENABLE) == TRUE
   INF  
SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
 !endif
-- 
2.35.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96191): https://edk2.groups.io/g/devel/message/96191
Mute This Topic: https://groups.io/mt/94935843/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH] UefiCpuPkg: Bug fix in 5LPage handling

2022-11-10 Thread Guenzel, Robert
When build in DEBUG, the code asserts that 5LPage support is there
when the physical address width is larger than 48.
In a RELEASE build it will just force LA57 to 1 in CR4
even if CPUID(7).ECX[16] says it is not supported.

The hang (in the ASSERT) in DEBUG is not warranted as there are
legal configurations with CPUID(7).ECX[16](==LA57)=0
and with a physical address width of larger than 48 (like 52).

This is also supported by this code:
https://github.com/tianocore/edk2/blob/master/UefiCpuPkg/PiSmmCpuDxeSmm/X64/PageTbl.c#L221
There (as long as physical address width is smaller or equal to 52)
any address width above 48 will be reduced to 48 and the
system can and will work without 5LPaging.

The forced setting of LA57 in CR4 (in the absence of LA57 in CPUID(7).ECX)
is a spec violation and should not happen.

Hence the proposed fix
a) removes the assert.
b) only returns TRUE from Is5LevelPagingNeeded if 5LPaging is actually
   supported by HW.

Signed-off-by: Robert Guenzel mailto:robert.guen...@intel.com
---
 UefiCpuPkg/PiSmmCpuDxeSmm/X64/PageTbl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/X64/PageTbl.c 
b/UefiCpuPkg/PiSmmCpuDxeSmm/X64/PageTbl.c
index 6587212f4e..f8b1ac31f1 100644
--- a/UefiCpuPkg/PiSmmCpuDxeSmm/X64/PageTbl.c
+++ b/UefiCpuPkg/PiSmmCpuDxeSmm/X64/PageTbl.c
@@ -104,8 +104,8 @@ Is5LevelPagingNeeded (
 ExtFeatureEcx.Bits.FiveLevelPage
 ));

-  if (VirPhyAddressSize.Bits.PhysicalAddressBits > 4 * 9 + 12) {
-ASSERT (ExtFeatureEcx.Bits.FiveLevelPage == 1);
+  if ((VirPhyAddressSize.Bits.PhysicalAddressBits > 4 * 9 + 12) &&
+  (ExtFeatureEcx.Bits.FiveLevelPage == 1)) {
 return TRUE;
   } else {
 return FALSE;
-- 
2.34.1
Intel Deutschland GmbH
Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
Tel: +49 89 99 8853-0, www.intel.de 
Managing Directors: Christin Eisenschmid, Sharon Heck, Tiffany Doon Silva  
Chairperson of the Supervisory Board: Nicole Lau
Registered Office: Munich
Commercial Register: Amtsgericht Muenchen HRB 186928



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96192): https://edk2.groups.io/g/devel/message/96192
Mute This Topic: https://groups.io/mt/94935896/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/3] ArmPkg/ArmTrngLib: Fix incorrect GUID reference in DEBUG() output

2022-11-10 Thread Sami Mujawar
Hi Ard,

Thank you for this fix.

Reviewed-by: Sami Mujawar 

Regards,

Sami Mujawar

On 10/11/2022, 13:48, "Ard Biesheuvel"  wrote:

ArmTrngLib crashes when run in DEBUG mode due to the fact that it passed
the [truncated] GUID value to a DEBUG() print statement instead of a
pointer to the GUID which is what the %g conversion expects.

Signed-off-by: Ard Biesheuvel 
---
 ArmPkg/Library/ArmTrngLib/ArmTrngLib.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ArmPkg/Library/ArmTrngLib/ArmTrngLib.c 
b/ArmPkg/Library/ArmTrngLib/ArmTrngLib.c
index b974a9423880..fdabc02cd39c 100644
--- a/ArmPkg/Library/ArmTrngLib/ArmTrngLib.c
+++ b/ArmPkg/Library/ArmTrngLib/ArmTrngLib.c
@@ -375,7 +375,7 @@ ArmTrngLibConstructor (
 "FW-TRNG: Version %d.%d, GUID {%g}\n",

 MajorRev,

 MinorRev,

-Guid

+&Guid

 ));



   DEBUG_CODE_END ();

-- 
2.35.1




-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96193): https://edk2.groups.io/g/devel/message/96193
Mute This Topic: https://groups.io/mt/94935840/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH] MdePkg: Add After Ready To Boot Event Definition from UEFI 2.9

2022-11-10 Thread Robert Phelps via groups.io
Add After Ready To Boot Event Definitions

Cc: Michael D Kinney  [mdkinney]
Cc: Liming Gao  [lgao4]
Cc: Zhiguang Liu  [LiuZhiguang001]

Signed-off-by: Robert Phelps 
---
 MdePkg/Include/Guid/EventGroup.h | 5 +
 MdePkg/MdePkg.dec| 3 +++
 2 files changed, 8 insertions(+)

diff --git a/MdePkg/Include/Guid/EventGroup.h b/MdePkg/Include/Guid/EventGroup.h
index 063d1f7157..a68b654e0a 100644
--- a/MdePkg/Include/Guid/EventGroup.h
+++ b/MdePkg/Include/Guid/EventGroup.h
@@ -29,6 +29,11 @@ extern EFI_GUID  gEfiEventMemoryMapChangeGuid;

 extern EFI_GUID  gEfiEventReadyToBootGuid;

+#define EFI_EVENT_GROUP_AFTER_READY_TO_BOOT \
+  { 0x3a2a00ad, 0x98b9, 0x4cdf, { 0xa4, 0x78, 0x70, 0x27, 0x77, 0xf1, 0xc1, 
0xb } }
+
+extern EFI_GUID  gEfiEventAfterReadyToBootGuid;
+
 #define EFI_EVENT_GROUP_DXE_DISPATCH_GUID \
   { 0x7081e22f, 0xcac6, 0x4053, { 0x94, 0x68, 0x67, 0x57, 0x82, 0xcf, 0x88, 
0xe5 }}

diff --git a/MdePkg/MdePkg.dec b/MdePkg/MdePkg.dec
index e49b2d5b5f..0d6dfe8792 100644
--- a/MdePkg/MdePkg.dec
+++ b/MdePkg/MdePkg.dec
@@ -413,6 +413,9 @@
   ## Include/Guid/EventGroup.h
   gEfiEventReadyToBootGuid   = { 0x7CE88FB3, 0x4BD7, 0x4679, { 0x87, 0xA8, 
0xA8, 0xD8, 0xDE, 0xE5, 0x0D, 0x2B }}

+  ## Include/Guid/EventGroup.h
+  gEfiEventAfterReadyToBootGuid  = { 0x7081e22f, 0xcac6, 0x4053, { 0x94, 0x68, 
0x67, 0x57, 0x82, 0xcf, 0x88, 0xe5 }}
+
   ## Include/Guid/EventGroup.h
   gEfiEventMemoryMapChangeGuid   = { 0x78BEE926, 0x692F, 0x48FD, { 0x9E, 0xDB, 
0x01, 0x42, 0x2E, 0xF0, 0xD7, 0xAB }}

--
2.36.1.windows.1
-The information contained in this message may be confidential and proprietary 
to American Megatrends (AMI). This communication is intended to be read only by 
the individual or entity to whom it is addressed or by their designee. If the 
reader of this message is not the intended recipient, you are on notice that 
any distribution of this message, in any form, is strictly prohibited. Please 
promptly notify the sender by reply e-mail or by telephone at 770-246-8600, and 
then delete or destroy all copies of the transmission.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96194): https://edk2.groups.io/g/devel/message/96194
Mute This Topic: https://groups.io/mt/94938379/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] Event: TianoCore Community Meeting EMEA/NAMO - Thursday, November 10, 2022 #cal-reminder

2022-11-10 Thread Group Notification
*Reminder: TianoCore Community Meeting EMEA/NAMO*

*When:*
Thursday, November 10, 2022
8:00am to 9:00am
(UTC-08:00) America/Los Angeles

*Where:*
Microsoft Teams meeting Join on your computer or mobile app Click here to join 
the meeting Meeting ID: 226 323 011 029 Passcode: hMRCj6 Download Teams | Join 
on the web Join with a video conferencing device te...@conf.intel.com Video 
Conference ID: 112 716 814 3 Alternate VTC instructions Learn More | Meeting 
options

*Organizer:* Miki Demeter

View Event ( https://edk2.groups.io/g/devel/viewevent?eventid=1624376 )

*Description:*



Microsoft Teams meeting

*Join on your computer or mobile app*

Click here to join the meeting ( 
https://teams.microsoft.com/l/meetup-join/19%3ameeting_MTAyZGJhNjMtYzQ4Mi00MTUxLWFlMWMtOGU0MWNlZDk4NjY5%40thread.v2/0?context=%7b%22Tid%22%3a%2246c98d88-e344-4ed4-8496-4ed7712e255d%22%2c%22Oid%22%3a%226e4ce4c4-1242-431b-9a51-92cd01a5df3c%22%7d
 )

Meeting ID: 226 323 011 029
Passcode: hMRCj6

Download Teams ( https://www.microsoft.com/en-us/microsoft-teams/download-app ) 
| Join on the web ( https://www.microsoft.com/microsoft-teams/join-a-meeting )

*Join with a video conferencing device*

te...@conf.intel.com

Video Conference ID: 112 716 814 3

Alternate VTC instructions ( 
https://conf.intel.com/teams/?conf=1127168143&ivr=teams&d=conf.intel.com&test=test_call
 )

Learn More ( https://aka.ms/JoinTeamsMeeting ) | Meeting options ( 
https://teams.microsoft.com/meetingOptions/?organizerId=6e4ce4c4-1242-431b-9a51-92cd01a5df3c&tenantId=46c98d88-e344-4ed4-8496-4ed7712e255d&threadId=19_meeting_MTAyZGJhNjMtYzQ4Mi00MTUxLWFlMWMtOGU0MWNlZDk4NjY5@thread.v2&messageId=0&language=en-US
 )




-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96195): https://edk2.groups.io/g/devel/message/96195
Mute This Topic: https://groups.io/mt/94915883/21656
Mute #cal-reminder:https://edk2.groups.io/g/devel/mutehashtag/cal-reminder
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] Now: TianoCore Community Meeting EMEA/NAMO - Thursday, November 10, 2022 #cal-notice

2022-11-10 Thread Group Notification
*TianoCore Community Meeting EMEA/NAMO*

*When:*
Thursday, November 10, 2022
8:00am to 9:00am
(UTC-08:00) America/Los Angeles

*Where:*
Microsoft Teams meeting Join on your computer or mobile app Click here to join 
the meeting Meeting ID: 226 323 011 029 Passcode: hMRCj6 Download Teams | Join 
on the web Join with a video conferencing device te...@conf.intel.com Video 
Conference ID: 112 716 814 3 Alternate VTC instructions Learn More | Meeting 
options

*Organizer:* Miki Demeter

View Event ( https://edk2.groups.io/g/devel/viewevent?eventid=1624376 )

*Description:*



Microsoft Teams meeting

*Join on your computer or mobile app*

Click here to join the meeting ( 
https://teams.microsoft.com/l/meetup-join/19%3ameeting_MTAyZGJhNjMtYzQ4Mi00MTUxLWFlMWMtOGU0MWNlZDk4NjY5%40thread.v2/0?context=%7b%22Tid%22%3a%2246c98d88-e344-4ed4-8496-4ed7712e255d%22%2c%22Oid%22%3a%226e4ce4c4-1242-431b-9a51-92cd01a5df3c%22%7d
 )

Meeting ID: 226 323 011 029
Passcode: hMRCj6

Download Teams ( https://www.microsoft.com/en-us/microsoft-teams/download-app ) 
| Join on the web ( https://www.microsoft.com/microsoft-teams/join-a-meeting )

*Join with a video conferencing device*

te...@conf.intel.com

Video Conference ID: 112 716 814 3

Alternate VTC instructions ( 
https://conf.intel.com/teams/?conf=1127168143&ivr=teams&d=conf.intel.com&test=test_call
 )

Learn More ( https://aka.ms/JoinTeamsMeeting ) | Meeting options ( 
https://teams.microsoft.com/meetingOptions/?organizerId=6e4ce4c4-1242-431b-9a51-92cd01a5df3c&tenantId=46c98d88-e344-4ed4-8496-4ed7712e255d&threadId=19_meeting_MTAyZGJhNjMtYzQ4Mi00MTUxLWFlMWMtOGU0MWNlZDk4NjY5@thread.v2&messageId=0&language=en-US
 )




-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96196): https://edk2.groups.io/g/devel/message/96196
Mute This Topic: https://groups.io/mt/94938952/21656
Mute #cal-notice:https://edk2.groups.io/g/devel/mutehashtag/cal-notice
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [edk2-stable202211] [PATCH V4 0/3] Rename VmgExitLib to CcExitLib

2022-11-10 Thread Michael D Kinney
Hi Jiewen,

Changing the name of a library is a non-backwards compatible change from a 
platform DSC
file perspective for downstream consumers.

Whenever any type of non-backwards compatible change is made, we need to 
highlight
that in the commit messages and the Patch #0.

The rename is clearly documented in this series.  I am only asking that the
non-backwards compatible aspect be highlighted along with instructions on what
updates to a downstream platform DSC are required.

We can work on ways to collect this type of information into a release note
format so the changes required to move from one release to the next are
clearly documented.

Best regards,

Mike

> -Original Message-
> From: Yao, Jiewen 
> Sent: Monday, November 7, 2022 5:28 PM
> To: Xu, Min M ; devel@edk2.groups.io
> Cc: Dong, Eric ; Ni, Ray ; Brijesh 
> Singh ; Aktas, Erdem
> ; Gerd Hoffmann ; James Bottomley 
> ; Tom Lendacky
> ; Dong, Guo ; Rhodes, Sean 
> ; Lu, James ;
> Guo, Gua ; Kinney, Michael D ; 
> Gao, Liming 
> Subject: [edk2-stable202211] [PATCH V4 0/3] Rename VmgExitLib to CcExitLib
> 
> Hi
> I suggest we catch this to edk2-stable202211.
> 
> I already give R-B for V3 before soft-freeze.
> 
> The V4 just merges 2 patch into 1, based upon other feedback.
> 
> Thank you
> Yao, Jiewen
> 
> 
> > -Original Message-
> > From: Xu, Min M 
> > Sent: Tuesday, November 8, 2022 9:15 AM
> > To: devel@edk2.groups.io
> > Cc: Xu, Min M ; Dong, Eric ;
> > Ni, Ray ; Brijesh Singh ; Aktas,
> > Erdem ; Gerd Hoffmann ;
> > James Bottomley ; Yao, Jiewen
> > ; Tom Lendacky ;
> > Dong, Guo ; Rhodes, Sean ;
> > Lu, James ; Guo, Gua ; Kinney,
> > Michael D ; Gao, Liming
> > 
> > Subject: [PATCH V4 0/3] Rename VmgExitLib to CcExitLib
> >
> > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4123
> >
> > VmgExitLib once was designed to provide interfaces to support #VC handler
> > and issue VMGEXIT instruction. After TDVF (enable TDX feature in OVMF) is
> > introduced, this library is updated to support #VE as well. Now the name
> > of VmgExitLib cannot reflect what the lib does.
> >
> > This patch-set renames VmgExitLib to CcExitLib (Cc means Confidential
> > Computing). This is simple renaming and there is no logic changes. Then
> > APIs defined in CcExitLib.h are added with a CcExit prefix. This is to
> > make the name more meaningful.
> >
> > Code: https://github.com/mxu9/edk2/tree/CcExitLib.v4
> >
> > v4 changes:
> >  - The previous versions of the patch-set are to first duplicate a new
> >CcExitLib then delete the old VmgExitLib. According to this comments
> >https://edk2.groups.io/g/devel/message/96019 it suggests renaming in
> >a single patch is better.
> >  - Lib APIs are added with CcExit prefix, not CcExitLib prefix.
> >
> > v3 changes:
> >  - Rename CcExitHandleVc / CcExitHandleVe to
> >CcExitLibHandleVc / CcExitLibHandleVe to make the nameing consistent.
> >  - Update the CcExitLib to merge the patch eff44c008d99
> >   (OvmfPkg/VmgExitLig: HALT on #VE when access to private memory).
> >
> > v2 changes:
> >  - Patch #3 is added to import CcExitLib in OvmfPkg's *.dsc. This is to
> >prevent the building from being broken in the following patches.
> >
> > Cc: Eric Dong 
> > Cc: Ray Ni 
> > Cc: Brijesh Singh 
> > Cc: Erdem Aktas 
> > Cc: Gerd Hoffmann 
> > Cc: James Bottomley 
> > Cc: Jiewen Yao 
> > Cc: Tom Lendacky 
> > Cc: Guo Dong 
> > Cc: Sean Rhodes 
> > Cc: James Lu 
> > Cc: Gua Guo 
> > Cc: Michael D Kinney 
> > Cc: Liming Gao 
> > Reviewed-by: Jiewen Yao 
> > Signed-off-by: Min Xu 
> >
> > Min M Xu (3):
> >   OvmfPkg/UefiCpuPkg/UefiPayloadPkg: Rename VmgExitLib to CcExitLib
> >   OvmfPkg/UefiCpuPkg: Add CcExit prefix to the APIs of CcExitLib
> >   Maintainers: Update the VmgExitLib to CcExitLib
> >
> >  Maintainers.txt   |   2 +-
> >  OvmfPkg/AmdSev/AmdSevX64.dsc  |   4 +-
> >  OvmfPkg/Bhyve/BhyveX64.dsc|   2 +-
> >  OvmfPkg/CloudHv/CloudHvX64.dsc|   6 +-
> >  OvmfPkg/IntelTdx/IntelTdxX64.dsc  |   4 +-
> >  .../DxeMemEncryptSevLib.inf   |   2 +-
> >  .../PeiMemEncryptSevLib.inf   |   2 +-
> >  .../SecMemEncryptSevLib.inf   |   2 +-
> >  .../X64/SnpPageStateChangeInternal.c  |  10 +-
> >  .../VmgExitLib.c => CcExitLib/CcExitLib.c}|  23 ++--
> >  .../CcExitLib.inf}|  17 +--
> >  .../CcExitTd.h}   |   4 +-
> >  .../CcExitVcHandler.c}| 129 +-
> >  .../CcExitVcHandler.h}|   6 +-
> >  .../CcExitVeHandler.c}|   6 +-
> >  .../PeiDxeCcExitVcHandler.c}  |   6 +-
> >  .../SecCcExitLib.inf} |  14 +-
> >  .../SecCcExitVcHandler.c} |   6 +-
> >  .../X64/TdVmcallCpuid.nasm|   0
> >  OvmfPkg/Microvm/MicrovmX64.dsc|   4 +-
> >  Ov

Re: [edk2-devel] [PATCH 3/3] MdeModulePkg: Notify BeforeExitBootServices in CoreExitBootServices

2022-11-10 Thread Dionna Glaze via groups.io
> Reviewed-by: Michael D Kinney 

Great, thanks Michael. With all three patches reviewed/acked, does
that mean they get merged, or what else has to be done? I'm new to
this.

--
-Dionna Glaze, PhD (she/her)


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96199): https://edk2.groups.io/g/devel/message/96199
Mute This Topic: https://groups.io/mt/94894288/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] .github/dependabot.yml: Enable dependabot

2022-11-10 Thread Michael D Kinney
Hi Michael,

Thanks.  This feature is really useful to help keep our dependencies up to date.

For the EDK II Development Process, the PRs produced by dependabot would only
be informative and would never be merged directly.  How do we mark these PRs
so they are never merged directly with a "push" label?

The EDK II Maintainers can monitor these PRs and when there is something that
needs to be updated, a developer can produce patches and send reviews 
with required Signed-off-by and Reviewed-by tags in the commit message.

Thanks,

Mike

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Michael Kubacki
> Sent: Thursday, November 10, 2022 5:47 AM
> To: devel@edk2.groups.io
> Cc: Sean Brogan ; Kinney, Michael D 
> 
> Subject: [edk2-devel] [PATCH v1 1/1] .github/dependabot.yml: Enable dependabot
> 
> From: Michael Kubacki 
> 
> Enables dependabot in this repo so we can better alerted when
> dependency updates are available.
> 
> This GitHub action will automatically create pull requests and
> summarize the dependency details. Because it is a pull request,
> the CI system will validate the dependency update in the pull
> request.
> 
> Configures dependabot for:
> 
> 1. PIP module updates
> 2. Submodule updates
> 3. GitHub action updates
> 
> The maintainers/reviewers of the .github directory were added as
> pull request reviewers so they can be notified when the pull request
> is available.
> 
> Cc: Sean Brogan 
> Cc: Michael D Kinney 
> Signed-off-by: Michael Kubacki 
> ---
> 
> Notes:
> An example of the pull requests created by this change
> are available on my edk2 fork:
> 
> https://github.com/makubacki/edk2/pulls
> 
>  .github/dependabot.yml | 45 
>  1 file changed, 45 insertions(+)
> 
> diff --git a/.github/dependabot.yml b/.github/dependabot.yml
> new file mode 100644
> index ..7f405721fd3d
> --- /dev/null
> +++ b/.github/dependabot.yml
> @@ -0,0 +1,45 @@
> +## @file
> +# Dependabot configuration file to enable GitHub services for managing and 
> updating
> +# dependencies.
> +#
> +# Copyright (c) Microsoft Corporation.
> +# SPDX-License-Identifier: BSD-2-Clause-Patent
> +#
> +# Please see the documentation for all configuration options:
> +# 
> https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
> +##
> +version: 2
> +updates:
> +  - package-ecosystem: "pip"
> +directory: "/"
> +schedule:
> +  interval: "daily"
> +commit-message:
> +  prefix: "pip"
> +reviewers:
> +  - "makubacki"
> +  - "mdkinney"
> +  - "spbrogan"
> +
> +  - package-ecosystem: "gitsubmodule"
> +directory: "/"
> +schedule:
> +  interval: "daily"
> +commit-message:
> +  prefix: "submodule"
> +reviewers:
> +  - "makubacki"
> +  - "mdkinney"
> +  - "spbrogan"
> +
> +  - package-ecosystem: "github-actions"
> +directory: "/"
> +schedule:
> +  interval: "weekly"
> +  day: "monday"
> +commit-message:
> +  prefix: "GitHub Action"
> +reviewers:
> +  - "makubacki"
> +  - "mdkinney"
> +  - "spbrogan"
> --
> 2.28.0.windows.1
> 
> 
> 
> -=-=-=-=-=-=
> Groups.io Links: You receive all messages sent to this group.
> View/Reply Online (#96187): https://edk2.groups.io/g/devel/message/96187
> Mute This Topic: https://groups.io/mt/94935824/1643496
> Group Owner: devel+ow...@edk2.groups.io
> Unsubscribe: https://edk2.groups.io/g/devel/unsub [michael.d.kin...@intel.com]
> -=-=-=-=-=-=
> 



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96200): https://edk2.groups.io/g/devel/message/96200
Mute This Topic: https://groups.io/mt/94935824/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [PATCH 3/3] MdeModulePkg: Notify BeforeExitBootServices in CoreExitBootServices

2022-11-10 Thread Michael D Kinney
Hi Dionna,

https://github.com/tianocore/tianocore.github.io/wiki/EDK-II-Development-Process

I think you are at step 13.  If you have not done so already, please update the
commit messages with all the Reviewed-by and Acked-by tags and make sure your
branch is rebased against the latest edk2/master and update the PR with that
content and verify that all EDK II CI checks pass.

At that point, it is the responsibility of the EDK II Maintainers to review
the final state of the PR and set the "push" label if everything looks correct.

At this moment, we are in Soft Freeze and will be in Hard Freeze for the next
2 weeks.  If this is considered critical for the stable tag release, then 
please send a request to Liming with justification for stable tag.  Otherwise,
it will be merged after the stable tag release.

https://github.com/tianocore/tianocore.github.io/wiki/EDK-II-Release-Planning

Thanks,

Mike



> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Dionna Glaze 
> via groups.io
> Sent: Thursday, November 10, 2022 8:44 AM
> To: Kinney, Michael D 
> Cc: devel@edk2.groups.io; Gerd Hoffmann ; James Bottomley 
> ; Yao, Jiewen
> ; Tom Lendacky ; Ard 
> Biesheuvel ; Xu, Min M
> ; Andrew Fish ; Ni, Ray 
> 
> Subject: Re: [edk2-devel] [PATCH 3/3] MdeModulePkg: Notify 
> BeforeExitBootServices in CoreExitBootServices
> 
> > Reviewed-by: Michael D Kinney 
> 
> Great, thanks Michael. With all three patches reviewed/acked, does
> that mean they get merged, or what else has to be done? I'm new to
> this.
> 
> --
> -Dionna Glaze, PhD (she/her)
> 
> 
> 
> 



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96201): https://edk2.groups.io/g/devel/message/96201
Mute This Topic: https://groups.io/mt/94894288/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [Patch edk2-stable202211 1/1] pip-requirements.txt: Update edk2-pytool-library to 0.12.0

2022-11-10 Thread Michael D Kinney
Hi Liming,

PR: https://github.com/tianocore/edk2/pull/3619

All EDK II CI checks passed.

Mike

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Michael D 
> Kinney
> Sent: Wednesday, November 9, 2022 10:30 PM
> To: devel@edk2.groups.io
> Cc: Sean Brogan ; Michael Kubacki 
> ; Gao, Liming
> ; Andrew Fish ; Leif Lindholm 
> 
> Subject: [edk2-devel] [Patch edk2-stable202211 1/1] pip-requirements.txt: 
> Update edk2-pytool-library to 0.12.0
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4146
> 
> Update edk2-pytool-library to version 0.12.0 that adds support for
> the environment variable PYTOOL_TEMPORARILY_IGNORE_NESTED_EDK_PACKAGES
> that can be set to true to ignore nested packages instead of breaking
> the build with an exception. Nested packages are not allowed by the
> edk2 specifications.  This environment variable allows pytools to run
> with reduced functionality if nested packages are present giving
> downstream consumers of edk2 that use pytools time to resolve the use
> of nested packages and restore all features of pytools.
> 
> Cc: Sean Brogan 
> Cc: Michael Kubacki 
> Cc: Liming Gao 
> Cc: Andrew Fish 
> Cc: Leif Lindholm 
> Signed-off-by: Michael D Kinney 
> ---
>  pip-requirements.txt | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/pip-requirements.txt b/pip-requirements.txt
> index 74d1bb35f2f2..d7e6b536f987 100644
> --- a/pip-requirements.txt
> +++ b/pip-requirements.txt
> @@ -12,7 +12,7 @@
>  # https://www.python.org/dev/peps/pep-0440/#version-specifiers
>  ##
> 
> -edk2-pytool-library==0.11.6
> +edk2-pytool-library==0.12.0
>  edk2-pytool-extensions~=0.19.1
>  edk2-basetools==0.1.39
>  antlr4-python3-runtime==4.7.1
> --
> 2.37.1.windows.1
> 
> 
> 
> 
> 



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96202): https://edk2.groups.io/g/devel/message/96202
Mute This Topic: https://groups.io/mt/94931193/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [edk2-stable202211] [PATCH V4 0/3] Rename VmgExitLib to CcExitLib

2022-11-10 Thread Yao, Jiewen
Yes, Mike. Good point.

We will send a new patch to highlight: 1) incompatibility change, 2) how to 
upgrade.

Thanks for the suggestion.


> -Original Message-
> From: Kinney, Michael D 
> Sent: Friday, November 11, 2022 12:39 AM
> To: Yao, Jiewen ; Xu, Min M
> ; devel@edk2.groups.io; Kinney, Michael D
> 
> Cc: Dong, Eric ; Ni, Ray ; Brijesh
> Singh ; Aktas, Erdem ;
> Gerd Hoffmann ; James Bottomley
> ; Tom Lendacky ; Dong,
> Guo ; Rhodes, Sean ; Lu,
> James ; Guo, Gua ; Gao, Liming
> 
> Subject: RE: [edk2-stable202211] [PATCH V4 0/3] Rename VmgExitLib to
> CcExitLib
> 
> Hi Jiewen,
> 
> Changing the name of a library is a non-backwards compatible change from
> a platform DSC
> file perspective for downstream consumers.
> 
> Whenever any type of non-backwards compatible change is made, we need
> to highlight
> that in the commit messages and the Patch #0.
> 
> The rename is clearly documented in this series.  I am only asking that the
> non-backwards compatible aspect be highlighted along with instructions on
> what
> updates to a downstream platform DSC are required.
> 
> We can work on ways to collect this type of information into a release note
> format so the changes required to move from one release to the next are
> clearly documented.
> 
> Best regards,
> 
> Mike
> 
> > -Original Message-
> > From: Yao, Jiewen 
> > Sent: Monday, November 7, 2022 5:28 PM
> > To: Xu, Min M ; devel@edk2.groups.io
> > Cc: Dong, Eric ; Ni, Ray ; Brijesh
> Singh ; Aktas, Erdem
> > ; Gerd Hoffmann ;
> James Bottomley ; Tom Lendacky
> > ; Dong, Guo ;
> Rhodes, Sean ; Lu, James ;
> > Guo, Gua ; Kinney, Michael D
> ; Gao, Liming 
> > Subject: [edk2-stable202211] [PATCH V4 0/3] Rename VmgExitLib to
> CcExitLib
> >
> > Hi
> > I suggest we catch this to edk2-stable202211.
> >
> > I already give R-B for V3 before soft-freeze.
> >
> > The V4 just merges 2 patch into 1, based upon other feedback.
> >
> > Thank you
> > Yao, Jiewen
> >
> >
> > > -Original Message-
> > > From: Xu, Min M 
> > > Sent: Tuesday, November 8, 2022 9:15 AM
> > > To: devel@edk2.groups.io
> > > Cc: Xu, Min M ; Dong, Eric
> ;
> > > Ni, Ray ; Brijesh Singh ;
> Aktas,
> > > Erdem ; Gerd Hoffmann
> ;
> > > James Bottomley ; Yao, Jiewen
> > > ; Tom Lendacky ;
> > > Dong, Guo ; Rhodes, Sean
> ;
> > > Lu, James ; Guo, Gua ;
> Kinney,
> > > Michael D ; Gao, Liming
> > > 
> > > Subject: [PATCH V4 0/3] Rename VmgExitLib to CcExitLib
> > >
> > > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4123
> > >
> > > VmgExitLib once was designed to provide interfaces to support #VC
> handler
> > > and issue VMGEXIT instruction. After TDVF (enable TDX feature in OVMF)
> is
> > > introduced, this library is updated to support #VE as well. Now the
> name
> > > of VmgExitLib cannot reflect what the lib does.
> > >
> > > This patch-set renames VmgExitLib to CcExitLib (Cc means Confidential
> > > Computing). This is simple renaming and there is no logic changes. Then
> > > APIs defined in CcExitLib.h are added with a CcExit prefix. This is to
> > > make the name more meaningful.
> > >
> > > Code: https://github.com/mxu9/edk2/tree/CcExitLib.v4
> > >
> > > v4 changes:
> > >  - The previous versions of the patch-set are to first duplicate a new
> > >CcExitLib then delete the old VmgExitLib. According to this comments
> > >https://edk2.groups.io/g/devel/message/96019 it suggests renaming
> in
> > >a single patch is better.
> > >  - Lib APIs are added with CcExit prefix, not CcExitLib prefix.
> > >
> > > v3 changes:
> > >  - Rename CcExitHandleVc / CcExitHandleVe to
> > >CcExitLibHandleVc / CcExitLibHandleVe to make the nameing
> consistent.
> > >  - Update the CcExitLib to merge the patch eff44c008d99
> > >   (OvmfPkg/VmgExitLig: HALT on #VE when access to private memory).
> > >
> > > v2 changes:
> > >  - Patch #3 is added to import CcExitLib in OvmfPkg's *.dsc. This is to
> > >prevent the building from being broken in the following patches.
> > >
> > > Cc: Eric Dong 
> > > Cc: Ray Ni 
> > > Cc: Brijesh Singh 
> > > Cc: Erdem Aktas 
> > > Cc: Gerd Hoffmann 
> > > Cc: James Bottomley 
> > > Cc: Jiewen Yao 
> > > Cc: Tom Lendacky 
> > > Cc: Guo Dong 
> > > Cc: Sean Rhodes 
> > > Cc: James Lu 
> > > Cc: Gua Guo 
> > > Cc: Michael D Kinney 
> > > Cc: Liming Gao 
> > > Reviewed-by: Jiewen Yao 
> > > Signed-off-by: Min Xu 
> > >
> > > Min M Xu (3):
> > >   OvmfPkg/UefiCpuPkg/UefiPayloadPkg: Rename VmgExitLib to CcExitLib
> > >   OvmfPkg/UefiCpuPkg: Add CcExit prefix to the APIs of CcExitLib
> > >   Maintainers: Update the VmgExitLib to CcExitLib
> > >
> > >  Maintainers.txt   |   2 +-
> > >  OvmfPkg/AmdSev/AmdSevX64.dsc  |   4 +-
> > >  OvmfPkg/Bhyve/BhyveX64.dsc|   2 +-
> > >  OvmfPkg/CloudHv/CloudHvX64.dsc|   6 +-
> > >  OvmfPkg/IntelTdx/IntelTdxX64.dsc  |   4 +-
> > >  .../DxeMemEncryptSevLib.inf   |   2 +-
> > >  .../PeiMemEncryptSevLib.

[edk2-devel] [Patch edk2-platforms] IntelSiliconPkg/IntelVTdDxe: Fix CLANG detected incorrect return

2022-11-10 Thread Michael D Kinney
CreateSecondLevelPagingEntryTable() has a return type of
VTD_SECOND_LEVEL_PAGING_ENTRY * and an error condition
returns a value of NULL.

Change return value of EFI_SUCCESS (value 0) to NULL to
address CLANG compiler detection of incorrect return type.

Cc: Ray Ni 
Cc: Rangasai V Chaganty 
Cc: Isaac Oram 
Cc: Ashraf Ali S 
Signed-off-by: Michael D Kinney 
---
 .../IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c 
b/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c
index 3220789080..6788c86531 100644
--- a/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c
+++ b/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c
@@ -196,7 +196,7 @@ CreateSecondLevelPagingEntryTable (
   UINT64 EndAddress;
 
   if (MemoryLimit == 0) {
-return EFI_SUCCESS;
+return NULL;
   }
 
   Lvl4PagesStart = 0;
-- 
2.37.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96204): https://edk2.groups.io/g/devel/message/96204
Mute This Topic: https://groups.io/mt/94942403/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 1/1] MdePkg: Use ANSI colors to indicate debug message severity

2022-11-10 Thread Michael D Kinney
Hi Rebecca,

In the edk2 repo, I see the following instances of the DebugPrintMarker() API
where you are currently adding he ANSI color sequences.  Should all of these
be updated?  I did not review the edk2-platforms repo.  And there may be
downstream custom DebugLib instances.  It would better if this feature could 
be enabled for all existing DebugLib instances, but the only common location
is the DEBUG() macro definition in MdePkg/Include/Library/DebugLib.h and 
adding code to that macro adds statements to the module calling the DebugLib
services, which can increase code size.

ArmPkg\Library\SemiHostingDebugLib\DebugLib.c:
   75  VOID
   76: DebugPrintMarker (
   77IN  UINTNErrorLevel,

IntelFsp2Pkg\Library\BaseFspDebugLibSerialPort\DebugLib.c:
   89  VOID
   90: DebugPrintMarker (
   91IN  UINTNErrorLevel,

MdeModulePkg\Library\PeiDxeDebugLibReportStatusCode\DebugLib.c:
   85  VOID
   86: DebugPrintMarker (
   87IN  UINTNErrorLevel,

MdePkg\Library\BaseDebugLibSerialPort\DebugLib.c:
   97  VOID
   98: DebugPrintMarker (
   99IN  UINTNErrorLevel,

MdePkg\Library\DxeRuntimeDebugLibSerialPort\DebugLib.c:
  156  VOID
  157: DebugPrintMarker (
  158IN  UINTNErrorLevel,

MdePkg\Library\UefiDebugLibConOut\DebugLib.c:
   79  VOID
   80: DebugPrintMarker (
   81IN  UINTNErrorLevel,

MdePkg\Library\UefiDebugLibDebugPortProtocol\DebugLib.c:
  137  VOID
  138: DebugPrintMarker (
  139IN  UINTNErrorLevel,

MdePkg\Library\UefiDebugLibStdErr\DebugLib.c:
   79  VOID
   80: DebugPrintMarker (
   81IN  UINTNErrorLevel,

OvmfPkg\Library\PlatformDebugLibIoPort\DebugLib.c:
   79  VOID
   80: DebugPrintMarker (
   81IN  UINTNErrorLevel,

Also, the ErrorLevel parameter is a bitmask.  It cannot be used in
a switch/case statement for only 1 bit being set.  To test for a 
debug message of type ERROR or WARN, a check must be done for that
one bit being set in ErrorLevel.

The DebugLib also provides support for ASSERT() macros.  Should 
ASSERT() messages have the same color as an ERROR message?  Or
its own color?

The logic below changes the color for the message based on message
type.  But is does not save/restore the current ANSI color setting.
It see it using the END_ESC_SEQ.  Does that put the color settings
back to the previous setting?

Thanks,

Mike

> -Original Message-
> From: Rebecca Cran 
> Sent: Thursday, October 27, 2022 11:51 AM
> To: devel@edk2.groups.io; Kinney, Michael D ; 
> Gao, Liming ; Liu, Zhiguang
> ; Andrew Fish 
> Cc: Rebecca Cran 
> Subject: [PATCH v4 1/1] MdePkg: Use ANSI colors to indicate debug message 
> severity
> 
> There currently isn't a way to differentiate the different
> levels of DEBUG output: DEBUG_ERROR, DEBUG_WARN, DEBUG_INFO
> etc.
> 
> To improve this, wrap DEBUG_ERROR and DEBUG_WARN level
> messages in ANSI color code escape sequences. DEBUG_ERROR
> messages will be displayed in red text, and DEBUG_WARN
> in yellow.
> 
> Only enable this new functionality if the FeatureFlag
> gEfiMdePkgTokenSpaceGuid.PcdDebugAnsiSeqSupport
> is set to TRUE. By default it's FALSE.
> 
> Signed-off-by: Rebecca Cran 
> ---
>  MdePkg/MdePkg.dec|  6 ++
>  MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf |  2 +-
>  MdePkg/Library/UefiDebugLibConOut/UefiDebugLibConOut.inf |  2 +-
>  MdePkg/Library/BaseDebugLibSerialPort/DebugLib.c | 64 
> 
>  MdePkg/Library/UefiDebugLibConOut/DebugLib.c | 64 
> 
>  5 files changed, 136 insertions(+), 2 deletions(-)
> 
> diff --git a/MdePkg/MdePkg.dec b/MdePkg/MdePkg.dec
> index 4c81cbd75ab2..8ddc46b62e7d 100644
> --- a/MdePkg/MdePkg.dec
> +++ b/MdePkg/MdePkg.dec
> @@ -4,6 +4,7 @@
>  # It also provides the definitions(including PPIs/PROTOCOLs/GUIDs) of
>  # EFI1.10/UEFI2.7/PI1.7 and some Industry Standards.
>  #
> +# Copyright (c) 2022, Qualcomm Innovation Center, Inc. All rights 
> reserved.
>  # Copyright (c) 2007 - 2022, Intel Corporation. All rights reserved.
>  # Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.
>  # (C) Copyright 2016 - 2021 Hewlett Packard Enterprise Development LP
> @@ -1977,6 +1978,11 @@ [PcdsFeatureFlag]
># @Prompt Validate ORDERED_COLLECTION structure
>
> gEfiMdePkgTokenSpaceGuid.PcdValidateOrderedCollection|FALSE|BOOLEAN|0x002a
> 
> +  ## Indicates if DEBUG output should use ANSI sequences.
> +  #   TRUE  - Will use ANSI sequences in DEBUG output.
> +  #   FALSE - Will not use ANSI sequences in DEBUG output.
> +  gEfiMdePkgTokenSpaceGuid.PcdDebugAnsiSeqSupport|FALSE|BOOLEAN|0x002f
> +
>  [PcdsFixedAtBuild]
>## Status code value for indicating a watchdog timer has expired.
># EFI_COMPUTING_UNIT_HOST_PROCESSOR | EFI_CU_HP_EC_TIMER_EXPIRED
> diff --git a/MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
> b/MdePkg/Library/BaseDebugLibSer

Re: [edk2-devel] [Patch edk2-platforms] IntelSiliconPkg/IntelVTdDxe: Fix CLANG detected incorrect return

2022-11-10 Thread Chaganty, Rangasai V
Reviewed-by: Sai Chaganty 

-Original Message-
From: Kinney, Michael D  
Sent: Thursday, November 10, 2022 10:24 AM
To: devel@edk2.groups.io
Cc: Ni, Ray ; Chaganty, Rangasai V 
; Oram, Isaac W ; S, 
Ashraf Ali 
Subject: [Patch edk2-platforms] IntelSiliconPkg/IntelVTdDxe: Fix CLANG detected 
incorrect return

CreateSecondLevelPagingEntryTable() has a return type of 
VTD_SECOND_LEVEL_PAGING_ENTRY * and an error condition returns a value of NULL.

Change return value of EFI_SUCCESS (value 0) to NULL to address CLANG compiler 
detection of incorrect return type.

Cc: Ray Ni 
Cc: Rangasai V Chaganty 
Cc: Isaac Oram 
Cc: Ashraf Ali S 
Signed-off-by: Michael D Kinney 
---
 .../IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c 
b/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c
index 3220789080..6788c86531 100644
--- a/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c
+++ b/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationT
+++ able.c
@@ -196,7 +196,7 @@ CreateSecondLevelPagingEntryTable (
   UINT64 EndAddress;
 
   if (MemoryLimit == 0) {
-return EFI_SUCCESS;
+return NULL;
   }
 
   Lvl4PagesStart = 0;
--
2.37.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96206): https://edk2.groups.io/g/devel/message/96206
Mute This Topic: https://groups.io/mt/94942403/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] .github/dependabot.yml: Enable dependabot

2022-11-10 Thread Michael Kubacki

Hi Mike,

One thing that comes to mind, is I can have the PR from dependabot 
automatically have a label added (e.g. "do-not-merge") and then update 
the mergify configuration to prevent merging of PRs with that label.


I can also have a comment automatically added to the PR that explains it 
is only for reference.


I made this changes on my fork in the following commits. What do you think?

- Branch: https://github.com/makubacki/edk2/commits/enable_dependabot
- Commit 1: 
https://github.com/makubacki/edk2/commit/7c8331885a9e052084cfdb5d40c845a0efd77248
- Commit 2: 
https://github.com/makubacki/edk2/commit/48be17075903cfc5278fd9bb031b965954d15bbb


Thanks,
Michael

On 11/10/2022 11:44 AM, Michael D Kinney wrote:

Hi Michael,

Thanks.  This feature is really useful to help keep our dependencies up to date.

For the EDK II Development Process, the PRs produced by dependabot would only
be informative and would never be merged directly.  How do we mark these PRs
so they are never merged directly with a "push" label?

The EDK II Maintainers can monitor these PRs and when there is something that
needs to be updated, a developer can produce patches and send reviews
with required Signed-off-by and Reviewed-by tags in the commit message.

Thanks,

Mike


-Original Message-
From: devel@edk2.groups.io  On Behalf Of Michael Kubacki
Sent: Thursday, November 10, 2022 5:47 AM
To: devel@edk2.groups.io
Cc: Sean Brogan ; Kinney, Michael D 

Subject: [edk2-devel] [PATCH v1 1/1] .github/dependabot.yml: Enable dependabot

From: Michael Kubacki 

Enables dependabot in this repo so we can better alerted when
dependency updates are available.

This GitHub action will automatically create pull requests and
summarize the dependency details. Because it is a pull request,
the CI system will validate the dependency update in the pull
request.

Configures dependabot for:

1. PIP module updates
2. Submodule updates
3. GitHub action updates

The maintainers/reviewers of the .github directory were added as
pull request reviewers so they can be notified when the pull request
is available.

Cc: Sean Brogan 
Cc: Michael D Kinney 
Signed-off-by: Michael Kubacki 
---

Notes:
 An example of the pull requests created by this change
 are available on my edk2 fork:

 https://github.com/makubacki/edk2/pulls

  .github/dependabot.yml | 45 
  1 file changed, 45 insertions(+)

diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index ..7f405721fd3d
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,45 @@
+## @file
+# Dependabot configuration file to enable GitHub services for managing and 
updating
+# dependencies.
+#
+# Copyright (c) Microsoft Corporation.
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+# Please see the documentation for all configuration options:
+# 
https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
+##
+version: 2
+updates:
+  - package-ecosystem: "pip"
+directory: "/"
+schedule:
+  interval: "daily"
+commit-message:
+  prefix: "pip"
+reviewers:
+  - "makubacki"
+  - "mdkinney"
+  - "spbrogan"
+
+  - package-ecosystem: "gitsubmodule"
+directory: "/"
+schedule:
+  interval: "daily"
+commit-message:
+  prefix: "submodule"
+reviewers:
+  - "makubacki"
+  - "mdkinney"
+  - "spbrogan"
+
+  - package-ecosystem: "github-actions"
+directory: "/"
+schedule:
+  interval: "weekly"
+  day: "monday"
+commit-message:
+  prefix: "GitHub Action"
+reviewers:
+  - "makubacki"
+  - "mdkinney"
+  - "spbrogan"
--
2.28.0.windows.1



-=-=-=-=-=-=
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96187): https://edk2.groups.io/g/devel/message/96187
Mute This Topic: https://groups.io/mt/94935824/1643496
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [michael.d.kin...@intel.com]
-=-=-=-=-=-=











-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96207): https://edk2.groups.io/g/devel/message/96207
Mute This Topic: https://groups.io/mt/94935824/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] .github/dependabot.yml: Enable dependabot

2022-11-10 Thread Michael D Kinney
Hi Michael,

This is a good idea to use a label.

Can dependabot PRs be marked as "Draft" PRs?  May be another way to prevent.

Also, can a comment to the PR be done from the dependabot action?
My experience with mergify is that less logic is easier to maintain.

Thanks,

Mike

> -Original Message-
> From: Michael Kubacki 
> Sent: Thursday, November 10, 2022 11:53 AM
> To: devel@edk2.groups.io; Kinney, Michael D ; 
> mikub...@linux.microsoft.com
> Cc: Sean Brogan 
> Subject: Re: [edk2-devel] [PATCH v1 1/1] .github/dependabot.yml: Enable 
> dependabot
> 
> Hi Mike,
> 
> One thing that comes to mind, is I can have the PR from dependabot
> automatically have a label added (e.g. "do-not-merge") and then update
> the mergify configuration to prevent merging of PRs with that label.
> 
> I can also have a comment automatically added to the PR that explains it
> is only for reference.
> 
> I made this changes on my fork in the following commits. What do you think?
> 
> - Branch: https://github.com/makubacki/edk2/commits/enable_dependabot
> - Commit 1:
> https://github.com/makubacki/edk2/commit/7c8331885a9e052084cfdb5d40c845a0efd77248
> - Commit 2:
> https://github.com/makubacki/edk2/commit/48be17075903cfc5278fd9bb031b965954d15bbb
> 
> Thanks,
> Michael
> 
> On 11/10/2022 11:44 AM, Michael D Kinney wrote:
> > Hi Michael,
> >
> > Thanks.  This feature is really useful to help keep our dependencies up to 
> > date.
> >
> > For the EDK II Development Process, the PRs produced by dependabot would 
> > only
> > be informative and would never be merged directly.  How do we mark these PRs
> > so they are never merged directly with a "push" label?
> >
> > The EDK II Maintainers can monitor these PRs and when there is something 
> > that
> > needs to be updated, a developer can produce patches and send reviews
> > with required Signed-off-by and Reviewed-by tags in the commit message.
> >
> > Thanks,
> >
> > Mike
> >
> >> -Original Message-
> >> From: devel@edk2.groups.io  On Behalf Of Michael 
> >> Kubacki
> >> Sent: Thursday, November 10, 2022 5:47 AM
> >> To: devel@edk2.groups.io
> >> Cc: Sean Brogan ; Kinney, Michael D 
> >> 
> >> Subject: [edk2-devel] [PATCH v1 1/1] .github/dependabot.yml: Enable 
> >> dependabot
> >>
> >> From: Michael Kubacki 
> >>
> >> Enables dependabot in this repo so we can better alerted when
> >> dependency updates are available.
> >>
> >> This GitHub action will automatically create pull requests and
> >> summarize the dependency details. Because it is a pull request,
> >> the CI system will validate the dependency update in the pull
> >> request.
> >>
> >> Configures dependabot for:
> >>
> >> 1. PIP module updates
> >> 2. Submodule updates
> >> 3. GitHub action updates
> >>
> >> The maintainers/reviewers of the .github directory were added as
> >> pull request reviewers so they can be notified when the pull request
> >> is available.
> >>
> >> Cc: Sean Brogan 
> >> Cc: Michael D Kinney 
> >> Signed-off-by: Michael Kubacki 
> >> ---
> >>
> >> Notes:
> >>  An example of the pull requests created by this change
> >>  are available on my edk2 fork:
> >>
> >>  https://github.com/makubacki/edk2/pulls
> >>
> >>   .github/dependabot.yml | 45 
> >>   1 file changed, 45 insertions(+)
> >>
> >> diff --git a/.github/dependabot.yml b/.github/dependabot.yml
> >> new file mode 100644
> >> index ..7f405721fd3d
> >> --- /dev/null
> >> +++ b/.github/dependabot.yml
> >> @@ -0,0 +1,45 @@
> >> +## @file
> >> +# Dependabot configuration file to enable GitHub services for managing 
> >> and updating
> >> +# dependencies.
> >> +#
> >> +# Copyright (c) Microsoft Corporation.
> >> +# SPDX-License-Identifier: BSD-2-Clause-Patent
> >> +#
> >> +# Please see the documentation for all configuration options:
> >> +# 
> >> https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
> >> +##
> >> +version: 2
> >> +updates:
> >> +  - package-ecosystem: "pip"
> >> +directory: "/"
> >> +schedule:
> >> +  interval: "daily"
> >> +commit-message:
> >> +  prefix: "pip"
> >> +reviewers:
> >> +  - "makubacki"
> >> +  - "mdkinney"
> >> +  - "spbrogan"
> >> +
> >> +  - package-ecosystem: "gitsubmodule"
> >> +directory: "/"
> >> +schedule:
> >> +  interval: "daily"
> >> +commit-message:
> >> +  prefix: "submodule"
> >> +reviewers:
> >> +  - "makubacki"
> >> +  - "mdkinney"
> >> +  - "spbrogan"
> >> +
> >> +  - package-ecosystem: "github-actions"
> >> +directory: "/"
> >> +schedule:
> >> +  interval: "weekly"
> >> +  day: "monday"
> >> +commit-message:
> >> +  prefix: "GitHub Action"
> >> +reviewers:
> >> +  - "makubacki"
> >> +  - "mdkinney"
> >> +  - "spbrogan"
> >> --
> >> 2.28.0.windows.1
> >>
> >>
> >>
> >> -=-=-=-=-=-=
> >> Groups.io Links: You receive all messages sent to this group.
> >> View/Reply Online (#96187): http

Re: [edk2-devel] [PATCH v4 1/1] MdePkg: Use ANSI colors to indicate debug message severity

2022-11-10 Thread Michael D Kinney
Hi Rebecca,

Here is an alternate way to implement this feature.  Just an
experiment because it does not follow the recommended methods
to add a feature that can be enabled/disabled.  I have tested
this on EmulatorPkg and OvmfPkg and it works as expected.
Does not require any updates to any DebugLib instances.

https://github.com/mdkinney/edk2/tree/POC_DebugLibAnsi
https://github.com/mdkinney/edk2/commit/8961ee82e95495651eca53145ae76c4f0097c637

In general we do not like using #if to enable/disable features.
However, this feature does increase the size of modules to enable
ANSI color sequences.  This approach has zero size impact
if MDEPKG_DEBUGANSI is not defined.

There are also challenges with this feature for platform FW
builds that may integrate binaries from other sources if there 
is a mix of modules that enable or disable the feature.

Only the platform developer knows if the device that all
DEBUG()/ASSERT() messages are routed supports ANSI color
sequences or not.  This means adding the sequences needs
to be in a platform component.  Or we need a mode where all 
generated messages are more like trace messages that include
the message type and error level, and let the receiver of
the trace messages reformat as needed.

Best regards,

Mike

> -Original Message-
> From: Kinney, Michael D 
> Sent: Thursday, November 10, 2022 11:12 AM
> To: Rebecca Cran ; devel@edk2.groups.io; Gao, Liming 
> ; Liu, Zhiguang
> ; Andrew Fish ; Kinney, Michael D 
> 
> Subject: RE: [PATCH v4 1/1] MdePkg: Use ANSI colors to indicate debug message 
> severity
> 
> Hi Rebecca,
> 
> In the edk2 repo, I see the following instances of the DebugPrintMarker() API
> where you are currently adding he ANSI color sequences.  Should all of these
> be updated?  I did not review the edk2-platforms repo.  And there may be
> downstream custom DebugLib instances.  It would better if this feature could
> be enabled for all existing DebugLib instances, but the only common location
> is the DEBUG() macro definition in MdePkg/Include/Library/DebugLib.h and
> adding code to that macro adds statements to the module calling the DebugLib
> services, which can increase code size.
> 
> ArmPkg\Library\SemiHostingDebugLib\DebugLib.c:
>75  VOID
>76: DebugPrintMarker (
>77IN  UINTNErrorLevel,
> 
> IntelFsp2Pkg\Library\BaseFspDebugLibSerialPort\DebugLib.c:
>89  VOID
>90: DebugPrintMarker (
>91IN  UINTNErrorLevel,
> 
> MdeModulePkg\Library\PeiDxeDebugLibReportStatusCode\DebugLib.c:
>85  VOID
>86: DebugPrintMarker (
>87IN  UINTNErrorLevel,
> 
> MdePkg\Library\BaseDebugLibSerialPort\DebugLib.c:
>97  VOID
>98: DebugPrintMarker (
>99IN  UINTNErrorLevel,
> 
> MdePkg\Library\DxeRuntimeDebugLibSerialPort\DebugLib.c:
>   156  VOID
>   157: DebugPrintMarker (
>   158IN  UINTNErrorLevel,
> 
> MdePkg\Library\UefiDebugLibConOut\DebugLib.c:
>79  VOID
>80: DebugPrintMarker (
>81IN  UINTNErrorLevel,
> 
> MdePkg\Library\UefiDebugLibDebugPortProtocol\DebugLib.c:
>   137  VOID
>   138: DebugPrintMarker (
>   139IN  UINTNErrorLevel,
> 
> MdePkg\Library\UefiDebugLibStdErr\DebugLib.c:
>79  VOID
>80: DebugPrintMarker (
>81IN  UINTNErrorLevel,
> 
> OvmfPkg\Library\PlatformDebugLibIoPort\DebugLib.c:
>79  VOID
>80: DebugPrintMarker (
>81IN  UINTNErrorLevel,
> 
> Also, the ErrorLevel parameter is a bitmask.  It cannot be used in
> a switch/case statement for only 1 bit being set.  To test for a
> debug message of type ERROR or WARN, a check must be done for that
> one bit being set in ErrorLevel.
> 
> The DebugLib also provides support for ASSERT() macros.  Should
> ASSERT() messages have the same color as an ERROR message?  Or
> its own color?
> 
> The logic below changes the color for the message based on message
> type.  But is does not save/restore the current ANSI color setting.
> It see it using the END_ESC_SEQ.  Does that put the color settings
> back to the previous setting?
> 
> Thanks,
> 
> Mike
> 
> > -Original Message-
> > From: Rebecca Cran 
> > Sent: Thursday, October 27, 2022 11:51 AM
> > To: devel@edk2.groups.io; Kinney, Michael D ; 
> > Gao, Liming ; Liu,
> Zhiguang
> > ; Andrew Fish 
> > Cc: Rebecca Cran 
> > Subject: [PATCH v4 1/1] MdePkg: Use ANSI colors to indicate debug message 
> > severity
> >
> > There currently isn't a way to differentiate the different
> > levels of DEBUG output: DEBUG_ERROR, DEBUG_WARN, DEBUG_INFO
> > etc.
> >
> > To improve this, wrap DEBUG_ERROR and DEBUG_WARN level
> > messages in ANSI color code escape sequences. DEBUG_ERROR
> > messages will be displayed in red text, and DEBUG_WARN
> > in yellow.
> >
> > Only enable this new functionality if the FeatureFlag
> > gEfiMdePkgTokenSpaceGuid.PcdDebugAnsiSeqSupport
> > is set to TRUE. By default it's FALSE.
> >
> > Signed-off-by: Rebecca Cran 
> > ---
> >  MdePkg/MdePkg.dec

Re: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting null UPD pointer in FSP-T

2022-11-10 Thread Nate DeSimone
Reviewed-by: Nate DeSimone 

-Original Message-
From: devel@edk2.groups.io  On Behalf Of Kuo, Ted
Sent: Wednesday, November 9, 2022 3:31 AM
To: devel@edk2.groups.io
Cc: Chiu, Chasel ; Desimone, Nathaniel L 
; Zeng, Star ; S, Ashraf 
Ali ; Duggapu, Chinni B 
Subject: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting null 
UPD pointer in FSP-T

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

1.Use xmm5 slot 1 and xmm6 slot 3 to save ucode status and UPD pointer
  respectively in TempRamInitApi in IA32 FspSecCoreT.
2.Correct inappropriate description in the return value of
  AsmGetFspInfoHeader.
3.Replace hardcoded offset value 0x1C with FSP_HEADER_IMGBASE_OFFSET in
  FspHeler.nasm.

Cc: Chasel Chiu 
Cc: Nate DeSimone 
Cc: Star Zeng 
Cc: Ashraf Ali S 
Cc: Chinni B Duggapu 
Signed-off-by: Ted Kuo 
---
 .../FspSecCore/Ia32/FspApiEntryT.nasm | 17 +++--
 IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm   |  4 +-
 .../FspSecCore/Ia32/SaveRestoreSseNasm.inc| 74 ++-
 IntelFsp2Pkg/FspSecCore/SecFsp.h  |  2 +-
 IntelFsp2Pkg/FspSecCore/X64/FspHelper.nasm|  4 +-
 5 files changed, 55 insertions(+), 46 deletions(-)

diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm 
b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
index 73821ad22a..2cff8b3643 100644
--- a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
+++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
@@ -594,37 +594,38 @@ ASM_PFX(TempRamInitApi):
   SAVE_EAX
   SAVE_EDX
 
+  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param
+  SAVE_ECX   ; save UPD param to slot 3 in xmm6
+
   ;
   ; Sec Platform Init
   ;
-  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param
   CALL_MMX  ASM_PFX(SecPlatformInit)
   cmp   eax, 0
   jnz   TempRamInitExit
 
   ; Load microcode
   LOAD_ESP
-  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param
+  LOAD_ECX
   CALL_MMX  ASM_PFX(LoadMicrocodeDefault)
-  SXMMN xmm6, 3, eax;Save microcode return status in ECX-SLOT 
3 in xmm6.
+  SAVE_UCODE_STATUS ; Save microcode return status in slot 1 
in xmm5.
   ;@note If return value eax is not 0, microcode did not load, but continue 
and attempt to boot.
 
   ; Call Sec CAR Init
   LOAD_ESP
-  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param
+  LOAD_ECX
   CALL_MMX  ASM_PFX(SecCarInit)
   cmp   eax, 0
   jnz   TempRamInitExit
 
   LOAD_ESP
-  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param
-  mov   edi, ecx ; Save UPD param to EDI for later 
code use
+  LOAD_ECX
+  mov   edi, ecx; Save UPD param to EDI for later code use
   CALL_MMX  ASM_PFX(EstablishStackFsp)
   cmp   eax, 0
   jnz   TempRamInitExit
 
-  LXMMN xmm6, eax, 3  ;Restore microcode status if no CAR init error from 
ECX-SLOT 3 in xmm6.
-  SXMMN xmm6, 3, edi  ;Save FSP-T UPD parameter pointer in ECX-SLOT 3 in 
xmm6.
+  LOAD_UCODE_STATUS ; Restore microcode status if no CAR init 
error from slot 1 in xmm5.
 
 TempRamInitExit:
   mov   bl, al  ; save al data in bl
diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm 
b/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
index e3e1945473..3c63f6eea5 100644
--- a/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
+++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
@@ -7,6 +7,8 @@
 
 SECTION .text
 
+FSP_HEADER_IMGBASE_OFFSETEQU   1Ch
+
 global ASM_PFX(FspInfoHeaderRelativeOff)
 ASM_PFX(FspInfoHeaderRelativeOff):
DD0x12345678   ; This value must be patched by the build 
script
@@ -14,7 +16,7 @@ ASM_PFX(FspInfoHeaderRelativeOff):
 global ASM_PFX(AsmGetFspBaseAddress)
 ASM_PFX(AsmGetFspBaseAddress):
call  ASM_PFX(AsmGetFspInfoHeader)
-   add   eax, 0x1C
+   add   eax, FSP_HEADER_IMGBASE_OFFSET
mov   eax, dword [eax]
ret
 
diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc 
b/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc
index 4c321cbece..a222f2e376 100644
--- a/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc
+++ b/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc
@@ -1,6 +1,6 @@
 ;--
 ;
-; Copyright (c) 2015 - 2019, Intel Corporation. All rights reserved.
+; Copyright (c) 2015 - 2022, Intel Corporation. All rights reserved.
 ; SPDX-License-Identifier: BSD-2-Clause-Patent
 ;
 ; Abstract:
@@ -16,21 +16,21 @@
 ;
 ; Define SSE macros using SSE 4.1 instructions
 ; args 1:XMM, 2:IDX, 3:REG
-%macro SXMMN   3
+%macro SXMMN3
  pinsrd  %1, %3, (%2 & 3)
  %endmacro
 
 ;
 ;args 1:XMM, 2:REG, 3:IDX
 ;
-%macro LXMMN   3
+%macro LXMMN3
  pextrd  %2, %1, (%3 & 3)
  %endmacro
 %else
 ;
 ; Define SSE macros using SSE 2 instructions
 ; args 1:XMM, 2:IDX, 3:REG
-%macro SXMMN   3
+%macro SXMMN3
  pinsrw  %1, %3, (%

回复: [edk2-devel] [Patch edk2-stable202211 1/1] pip-requirements.txt: Update edk2-pytool-library to 0.12.0

2022-11-10 Thread gaoliming via groups.io
Reviewed-by: Liming Gao 

I agree this change to be merged now.

Thanks
Liming
> -邮件原件-
> 发件人: devel@edk2.groups.io  代表 Michael D
> Kinney
> 发送时间: 2022年11月11日 0:59
> 收件人: devel@edk2.groups.io; Kinney, Michael D
> ; Gao, Liming 
> 抄送: Sean Brogan ; Michael Kubacki
> ; Gao, Liming ;
> Andrew Fish ; Leif Lindholm 
> 主题: Re: [edk2-devel] [Patch edk2-stable202211 1/1] pip-requirements.txt:
> Update edk2-pytool-library to 0.12.0
> 
> Hi Liming,
> 
> PR: https://github.com/tianocore/edk2/pull/3619
> 
> All EDK II CI checks passed.
> 
> Mike
> 
> > -Original Message-
> > From: devel@edk2.groups.io  On Behalf Of Michael
> D Kinney
> > Sent: Wednesday, November 9, 2022 10:30 PM
> > To: devel@edk2.groups.io
> > Cc: Sean Brogan ; Michael Kubacki
> ; Gao, Liming
> > ; Andrew Fish ; Leif
> Lindholm 
> > Subject: [edk2-devel] [Patch edk2-stable202211 1/1] pip-requirements.txt:
> Update edk2-pytool-library to 0.12.0
> >
> > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4146
> >
> > Update edk2-pytool-library to version 0.12.0 that adds support for
> > the environment variable
> PYTOOL_TEMPORARILY_IGNORE_NESTED_EDK_PACKAGES
> > that can be set to true to ignore nested packages instead of breaking
> > the build with an exception. Nested packages are not allowed by the
> > edk2 specifications.  This environment variable allows pytools to run
> > with reduced functionality if nested packages are present giving
> > downstream consumers of edk2 that use pytools time to resolve the use
> > of nested packages and restore all features of pytools.
> >
> > Cc: Sean Brogan 
> > Cc: Michael Kubacki 
> > Cc: Liming Gao 
> > Cc: Andrew Fish 
> > Cc: Leif Lindholm 
> > Signed-off-by: Michael D Kinney 
> > ---
> >  pip-requirements.txt | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/pip-requirements.txt b/pip-requirements.txt
> > index 74d1bb35f2f2..d7e6b536f987 100644
> > --- a/pip-requirements.txt
> > +++ b/pip-requirements.txt
> > @@ -12,7 +12,7 @@
> >  # https://www.python.org/dev/peps/pep-0440/#version-specifiers
> >  ##
> >
> > -edk2-pytool-library==0.11.6
> > +edk2-pytool-library==0.12.0
> >  edk2-pytool-extensions~=0.19.1
> >  edk2-basetools==0.1.39
> >  antlr4-python3-runtime==4.7.1
> > --
> > 2.37.1.windows.1
> >
> >
> >
> >
> >
> 
> 
> 
> 
> 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96211): https://edk2.groups.io/g/devel/message/96211
Mute This Topic: https://groups.io/mt/94949579/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] 回复: [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL without virtio-rng

2022-11-10 Thread gaoliming via groups.io
Ard:
  The first patch is the bug fix. I agree to merge it for this stable tag. I
will help merge it today. 

Thanks
Liming
> -邮件原件-
> 发件人: Ard Biesheuvel 
> 发送时间: 2022年11月10日 21:48
> 收件人: devel@edk2.groups.io
> 抄送: Ard Biesheuvel ; Liming Gao
> ; Rebecca Cran ; Pierre
> Gondois ; Leif Lindholm
> ; Sami Mujawar ;
> Gerd Hoffmann ; Jason A . Donenfeld
> 
> 主题: [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL without virtio-rng
> 
> Currently, we only expose EFI_RNG_PROTOCOL when running under QEMU if
> it
> 
> exposes a virtio-rng device. This means that generic EFI apps or
> 
> loaders have no access to an entropy source if this device is
> 
> unavailable, unless they implement their own arch-specific handling to
> 
> figure out whether any CPU instructions or monitor calls can be used
> 
> instead.
> 
> 
> 
> So let's wire those up as EFI_RNG_PROTOCOL implementations as well,
> 
> using the existing drivers and libraries.
> 
> 
> 
> First patch is a bugfix - Liming, mind if I merge that right away?
> 
> Thanks.
> 
> 
> 
> Cc: Liming Gao 
> 
> Cc: Rebecca Cran 
> 
> Cc: Pierre Gondois 
> 
> Cc: Leif Lindholm 
> 
> Cc: Sami Mujawar 
> 
> Cc: Gerd Hoffmann 
> 
> Cc: Jason A. Donenfeld 
> 
> 
> 
> Ard Biesheuvel (3):
> 
>   ArmPkg/ArmTrngLib: Fix incorrect GUID reference in DEBUG() output
> 
>   ArmVirtPkg/ArmVirtQemu: Expose TRNG hypercall via RngDxe if
> 
> implemented
> 
>   OvmfPkg/OvmfX86: Enable RDRAND based EFI_RNG_PROTOCOL
> implementation
> 
> 
> 
>  ArmPkg/Library/ArmTrngLib/ArmTrngLib.c |  2 +-
> 
>  ArmVirtPkg/ArmVirtQemu.dsc | 11 +++
> 
>  ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc   |  5 +
> 
>  ArmVirtPkg/ArmVirtQemuKernel.dsc   | 11 +++
> 
>  OvmfPkg/OvmfPkgIa32.dsc|  1 +
> 
>  OvmfPkg/OvmfPkgIa32.fdf|  1 +
> 
>  OvmfPkg/OvmfPkgIa32X64.dsc |  1 +
> 
>  OvmfPkg/OvmfPkgIa32X64.fdf |  1 +
> 
>  OvmfPkg/OvmfPkgX64.dsc |  1 +
> 
>  OvmfPkg/OvmfPkgX64.fdf |  1 +
> 
>  10 files changed, 34 insertions(+), 1 deletion(-)
> 
> 
> 
> --
> 
> 2.35.1
> 
> 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96212): https://edk2.groups.io/g/devel/message/96212
Mute This Topic: https://groups.io/mt/94949625/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] IntelFsp2Pkg: Improvement of supporting null UPD pointer in FSP-T

2022-11-10 Thread Chiu, Chasel


Hi Liming, Michael,

May I know why we cannot merge this PR 
https://github.com/tianocore/edk2/pull/3624 ?
Was it due to Hard Feature Freeze? But I thought we still have time right?

Thanks,
Chasel


> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Kuo,
> Ted
> Sent: Wednesday, November 9, 2022 3:31 AM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Desimone, Nathaniel L
> ; Zeng, Star ; S,
> Ashraf Ali ; Duggapu, Chinni B
> 
> Subject: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting
> null UPD pointer in FSP-T
> 
> REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4114
> 
> 1.Use xmm5 slot 1 and xmm6 slot 3 to save ucode status and UPD pointer
>   respectively in TempRamInitApi in IA32 FspSecCoreT.
> 2.Correct inappropriate description in the return value of
>   AsmGetFspInfoHeader.
> 3.Replace hardcoded offset value 0x1C with
> FSP_HEADER_IMGBASE_OFFSET in
>   FspHeler.nasm.
> 
> Cc: Chasel Chiu 
> Cc: Nate DeSimone 
> Cc: Star Zeng 
> Cc: Ashraf Ali S 
> Cc: Chinni B Duggapu 
> Signed-off-by: Ted Kuo 
> ---
>  .../FspSecCore/Ia32/FspApiEntryT.nasm | 17 +++--
>  IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm   |  4 +-
>  .../FspSecCore/Ia32/SaveRestoreSseNasm.inc| 74 ++-
>  IntelFsp2Pkg/FspSecCore/SecFsp.h  |  2 +-
>  IntelFsp2Pkg/FspSecCore/X64/FspHelper.nasm|  4 +-
>  5 files changed, 55 insertions(+), 46 deletions(-)
> 
> diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> index 73821ad22a..2cff8b3643 100644
> --- a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> +++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> @@ -594,37 +594,38 @@ ASM_PFX(TempRamInitApi):
>SAVE_EAX   SAVE_EDX +  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ;
> ECX for UPD param+  SAVE_ECX   ; save UPD param 
> to slot
> 3 in xmm6+   ;   ; Sec Platform Init   ;-  CALL_EBP
> ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param   CALL_MMX
> ASM_PFX(SecPlatformInit)   cmp   eax, 0   jnz   TempRamInitExit;
> Load microcode   LOAD_ESP-  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ;
> ECX for UPD param+  LOAD_ECX   CALL_MMX
> ASM_PFX(LoadMicrocodeDefault)-  SXMMN xmm6, 3, eax;Save
> microcode return status in ECX-SLOT 3 in xmm6.+
> SAVE_UCODE_STATUS ; Save microcode return status in slot 1 in
> xmm5.   ;@note If return value eax is not 0, microcode did not load, but
> continue and attempt to boot.; Call Sec CAR Init   LOAD_ESP-  CALL_EBP
> ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param+  LOAD_ECX
> CALL_MMX  ASM_PFX(SecCarInit)   cmp   eax, 0   jnz   TempRamInitExit
> LOAD_ESP-  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD
> param-  mov   edi, ecx ; Save UPD param to EDI for 
> later code
> use+  LOAD_ECX+  mov   edi, ecx; Save UPD param to EDI for
> later code use   CALL_MMX  ASM_PFX(EstablishStackFsp)   cmp   eax, 0
> jnz   TempRamInitExit -  LXMMN xmm6, eax, 3  ;Restore microcode
> status if no CAR init error from ECX-SLOT 3 in xmm6.-  SXMMN xmm6, 3,
> edi  ;Save FSP-T UPD parameter pointer in ECX-SLOT 3 in xmm6.+
> LOAD_UCODE_STATUS ; Restore microcode status if no CAR init
> error from slot 1 in xmm5.  TempRamInitExit:   mov   bl, al   
>;
> save al data in bldiff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
> b/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
> index e3e1945473..3c63f6eea5 100644
> --- a/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
> +++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
> @@ -7,6 +7,8 @@
>   SECTION .text +FSP_HEADER_IMGBASE_OFFSETEQU   1Ch+ global
> ASM_PFX(FspInfoHeaderRelativeOff) ASM_PFX(FspInfoHeaderRelativeOff):
> DD0x12345678   ; This value must be patched by the build
> script@@ -14,7 +16,7 @@ ASM_PFX(FspInfoHeaderRelativeOff):
>  global ASM_PFX(AsmGetFspBaseAddress)
> ASM_PFX(AsmGetFspBaseAddress):call
> ASM_PFX(AsmGetFspInfoHeader)-   add   eax, 0x1C+   add   eax,
> FSP_HEADER_IMGBASE_OFFSETmov   eax, dword [eax]ret diff --git
> a/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc
> b/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc
> index 4c321cbece..a222f2e376 100644
> --- a/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc
> +++ b/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc
> @@ -1,6 +1,6 @@
>  
> ;--
>  ;-; Copyright (c)
> 2015 - 2019, Intel Corporation. All rights reserved.+; Copyright (c)
> 2015 - 2022, Intel Corporation. All rights reserved. ; SPDX-License-
> Identifier: BSD-2-Clause-Patent ; ; Abstract:@@ -16,21 +16,21 @@
>  ; ; Define SSE macros using SSE 4.1 instructions ; args 1:XMM, 2:IDX,
> 3:REG-%macro SXMMN   3+%macro SXMMN3  pinsrd  %1, %3,
> (%2 & 3)  %endmacro  ; ;args 1:XMM, 2:REG, 3:IDX ;-%m

回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] [PATCH] ShellPkg:Improved Smbios Type 9 data under smbiosview

2022-11-10 Thread gaoliming via groups.io
I see the failure that the code can’t clone success. I re-run it and check 
again. 

 

Thanks

Liming

发件人: sainadhn via groups.io  
发送时间: 2022年11月10日 15:36
收件人: gaoliming ; devel@edk2.groups.io
主题: Re: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] [PATCH] 
ShellPkg:Improved Smbios Type 9 data under smbiosview

 

Hi Liming,

I see the pull request CI check failed and changes are not merged. The failure 
is not related to ShellPkg changes.
Please help to check.

Thanks,
Sainadh. 



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96214): https://edk2.groups.io/g/devel/message/96214
Mute This Topic: https://groups.io/mt/94949706/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting null UPD pointer in FSP-T

2022-11-10 Thread gaoliming via groups.io
Chasel:
  Please see the announce mail https://edk2.groups.io/g/devel/message/96175

  Now, we are in soft feature freeze. If the patch wants to catch this
stable tag, please highlight it and get approval from Stewards.

Thanks
Liming
> -邮件原件-
> 发件人: Chiu, Chasel 
> 发送时间: 2022年11月11日 8:47
> 收件人: Gao, Liming ; Kinney, Michael D
> 
> 抄送: Desimone, Nathaniel L ; Zeng, Star
> ; S, Ashraf Ali ; Duggapu,
> Chinni B ; devel@edk2.groups.io; Kuo, Ted
> 
> 主题: RE: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting
> null UPD pointer in FSP-T
> 
> 
> Hi Liming, Michael,
> 
> May I know why we cannot merge this PR
> https://github.com/tianocore/edk2/pull/3624 ?
> Was it due to Hard Feature Freeze? But I thought we still have time right?
> 
> Thanks,
> Chasel
> 
> 
> > -Original Message-
> > From: devel@edk2.groups.io  On Behalf Of Kuo,
> > Ted
> > Sent: Wednesday, November 9, 2022 3:31 AM
> > To: devel@edk2.groups.io
> > Cc: Chiu, Chasel ; Desimone, Nathaniel L
> > ; Zeng, Star ; S,
> > Ashraf Ali ; Duggapu, Chinni B
> > 
> > Subject: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting
> > null UPD pointer in FSP-T
> >
> > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4114
> >
> > 1.Use xmm5 slot 1 and xmm6 slot 3 to save ucode status and UPD pointer
> >   respectively in TempRamInitApi in IA32 FspSecCoreT.
> > 2.Correct inappropriate description in the return value of
> >   AsmGetFspInfoHeader.
> > 3.Replace hardcoded offset value 0x1C with
> > FSP_HEADER_IMGBASE_OFFSET in
> >   FspHeler.nasm.
> >
> > Cc: Chasel Chiu 
> > Cc: Nate DeSimone 
> > Cc: Star Zeng 
> > Cc: Ashraf Ali S 
> > Cc: Chinni B Duggapu 
> > Signed-off-by: Ted Kuo 
> > ---
> >  .../FspSecCore/Ia32/FspApiEntryT.nasm | 17 +++--
> >  IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm   |  4 +-
> >  .../FspSecCore/Ia32/SaveRestoreSseNasm.inc| 74
> ++-
> >  IntelFsp2Pkg/FspSecCore/SecFsp.h  |  2 +-
> >  IntelFsp2Pkg/FspSecCore/X64/FspHelper.nasm|  4 +-
> >  5 files changed, 55 insertions(+), 46 deletions(-)
> >
> > diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > index 73821ad22a..2cff8b3643 100644
> > --- a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > +++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > @@ -594,37 +594,38 @@ ASM_PFX(TempRamInitApi):
> >SAVE_EAX   SAVE_EDX +  CALL_EBP
> ASM_PFX(LoadUpdPointerToECX) ;
> > ECX for UPD param+  SAVE_ECX   ;
> save UPD param to slot
> > 3 in xmm6+   ;   ; Sec Platform Init   ;-  CALL_EBP
> > ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param   CALL_MMX
> > ASM_PFX(SecPlatformInit)   cmp   eax, 0   jnz
> TempRamInitExit;
> > Load microcode   LOAD_ESP-  CALL_EBP
> ASM_PFX(LoadUpdPointerToECX) ;
> > ECX for UPD param+  LOAD_ECX   CALL_MMX
> > ASM_PFX(LoadMicrocodeDefault)-  SXMMN xmm6, 3,
> eax;Save
> > microcode return status in ECX-SLOT 3 in xmm6.+
> > SAVE_UCODE_STATUS ; Save microcode return status in
> slot 1 in
> > xmm5.   ;@note If return value eax is not 0, microcode did not load, but
> > continue and attempt to boot.; Call Sec CAR Init   LOAD_ESP-
> CALL_EBP
> > ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param+  LOAD_ECX
> > CALL_MMX  ASM_PFX(SecCarInit)   cmp   eax, 0   jnz
> TempRamInitExit
> > LOAD_ESP-  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD
> > param-  mov   edi, ecx ; Save UPD param
> to EDI for later code
> > use+  LOAD_ECX+  mov   edi, ecx; Save UPD
> param to EDI for
> > later code use   CALL_MMX  ASM_PFX(EstablishStackFsp)   cmp
> eax, 0
> > jnz   TempRamInitExit -  LXMMN xmm6, eax, 3  ;Restore
> microcode
> > status if no CAR init error from ECX-SLOT 3 in xmm6.-  SXMMN xmm6,
> 3,
> > edi  ;Save FSP-T UPD parameter pointer in ECX-SLOT 3 in xmm6.+
> > LOAD_UCODE_STATUS ; Restore microcode status if no
> CAR init
> > error from slot 1 in xmm5.  TempRamInitExit:   mov   bl,
> al  ;
> > save al data in bldiff --git
a/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
> > b/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
> > index e3e1945473..3c63f6eea5 100644
> > --- a/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
> > +++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm
> > @@ -7,6 +7,8 @@
> >   SECTION .text +FSP_HEADER_IMGBASE_OFFSETEQU   1Ch+
> global
> > ASM_PFX(FspInfoHeaderRelativeOff) ASM_PFX(FspInfoHeaderRelativeOff):
> > DD0x12345678   ; This value must be patched by the
> build
> > script@@ -14,7 +16,7 @@ ASM_PFX(FspInfoHeaderRelativeOff):
> >  global ASM_PFX(AsmGetFspBaseAddress)
> > ASM_PFX(AsmGetFspBaseAddress):call
> > ASM_PFX(AsmGetFspInfoHeader)-   add   eax, 0x1C+   add   eax,
> > FSP_HEADER_IMGBASE_OFFSETmov   eax, dword [eax]ret diff
> --git
> > a/IntelFsp2Pkg/FspSecCore/Ia32/SaveRestoreSseNasm.inc
> > b/IntelFsp2Pkg/FspS

回复: [edk2-devel] [Patch edk2-stable202211 1/1] pip-requirements.txt: Update edk2-pytool-library to 0.12.0

2022-11-10 Thread gaoliming via groups.io
Mike:
  This patch is merged at 342813a3f7794bf67405a236053f27c916804d36

Thanks
Liming
> -邮件原件-
> 发件人: devel@edk2.groups.io  代表 gaoliming via
> groups.io
> 发送时间: 2022年11月11日 8:38
> 收件人: devel@edk2.groups.io; michael.d.kin...@intel.com
> 抄送: 'Sean Brogan' ; 'Michael Kubacki'
> ; 'Andrew Fish' ; 'Leif
> Lindholm' 
> 主题: 回复: [edk2-devel] [Patch edk2-stable202211 1/1]
> pip-requirements.txt: Update edk2-pytool-library to 0.12.0
> 
> Reviewed-by: Liming Gao 
> 
> I agree this change to be merged now.
> 
> Thanks
> Liming
> > -邮件原件-
> > 发件人: devel@edk2.groups.io  代表 Michael D
> > Kinney
> > 发送时间: 2022年11月11日 0:59
> > 收件人: devel@edk2.groups.io; Kinney, Michael D
> > ; Gao, Liming 
> > 抄送: Sean Brogan ; Michael Kubacki
> > ; Gao, Liming
> ;
> > Andrew Fish ; Leif Lindholm
> 
> > 主题: Re: [edk2-devel] [Patch edk2-stable202211 1/1]
> pip-requirements.txt:
> > Update edk2-pytool-library to 0.12.0
> >
> > Hi Liming,
> >
> > PR: https://github.com/tianocore/edk2/pull/3619
> >
> > All EDK II CI checks passed.
> >
> > Mike
> >
> > > -Original Message-
> > > From: devel@edk2.groups.io  On Behalf Of
> Michael
> > D Kinney
> > > Sent: Wednesday, November 9, 2022 10:30 PM
> > > To: devel@edk2.groups.io
> > > Cc: Sean Brogan ; Michael Kubacki
> > ; Gao, Liming
> > > ; Andrew Fish ; Leif
> > Lindholm 
> > > Subject: [edk2-devel] [Patch edk2-stable202211 1/1]
> pip-requirements.txt:
> > Update edk2-pytool-library to 0.12.0
> > >
> > > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4146
> > >
> > > Update edk2-pytool-library to version 0.12.0 that adds support for
> > > the environment variable
> > PYTOOL_TEMPORARILY_IGNORE_NESTED_EDK_PACKAGES
> > > that can be set to true to ignore nested packages instead of breaking
> > > the build with an exception. Nested packages are not allowed by the
> > > edk2 specifications.  This environment variable allows pytools to run
> > > with reduced functionality if nested packages are present giving
> > > downstream consumers of edk2 that use pytools time to resolve the use
> > > of nested packages and restore all features of pytools.
> > >
> > > Cc: Sean Brogan 
> > > Cc: Michael Kubacki 
> > > Cc: Liming Gao 
> > > Cc: Andrew Fish 
> > > Cc: Leif Lindholm 
> > > Signed-off-by: Michael D Kinney 
> > > ---
> > >  pip-requirements.txt | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/pip-requirements.txt b/pip-requirements.txt
> > > index 74d1bb35f2f2..d7e6b536f987 100644
> > > --- a/pip-requirements.txt
> > > +++ b/pip-requirements.txt
> > > @@ -12,7 +12,7 @@
> > >  # https://www.python.org/dev/peps/pep-0440/#version-specifiers
> > >  ##
> > >
> > > -edk2-pytool-library==0.11.6
> > > +edk2-pytool-library==0.12.0
> > >  edk2-pytool-extensions~=0.19.1
> > >  edk2-basetools==0.1.39
> > >  antlr4-python3-runtime==4.7.1
> > > --
> > > 2.37.1.windows.1
> > >
> > >
> > >
> > >
> > >
> >
> >
> >
> >
> >
> 
> 
> 
> 
> 
> 
> 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96216): https://edk2.groups.io/g/devel/message/96216
Mute This Topic: https://groups.io/mt/94949796/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH] UefiPayloadPkg: Define default values for the DynamicEX PCDs

2022-11-10 Thread Jiading Zhang
The following PCDs have no value in UefiPayloadPkg.dsc,and they can not pass 
the Ecc tool check, so assign the default values the same as they are in *.dec 
file.
gEfiMdeModulePkgTokenSpaceGuid.PcdAriSupport
gEfiMdeModulePkgTokenSpaceGuid.PcdMrIovSupport
gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSupport
gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSystemPageSize
gUefiCpuPkgTokenSpaceGuid.PcdCpuApInitTimeOutInMicroSeconds
gUefiCpuPkgTokenSpaceGuid.PcdCpuApLoopMode
gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchAddress
gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchRegionSize

Signed-off-by: jdzhang 
---
UefiPayloadPkg/UefiPayloadPkg.dsc | 16 
1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc 
b/UefiPayloadPkg/UefiPayloadPkg.dsc
index 1150be6acd..ce7d3a7f89 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.dsc
+++ b/UefiPayloadPkg/UefiPayloadPkg.dsc
@@ -530,14 +530,14 @@
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultParity|$(UART_DEFAULT_PARITY)
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultStopBits|$(UART_DEFAULT_STOP_BITS)
gEfiMdePkgTokenSpaceGuid.PcdDefaultTerminalType|$(DEFAULT_TERMINAL_TYPE)
-  gEfiMdeModulePkgTokenSpaceGuid.PcdAriSupport
-  gEfiMdeModulePkgTokenSpaceGuid.PcdMrIovSupport
-  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSupport
-  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSystemPageSize
-  gUefiCpuPkgTokenSpaceGuid.PcdCpuApInitTimeOutInMicroSeconds
-  gUefiCpuPkgTokenSpaceGuid.PcdCpuApLoopMode
-  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchAddress
-  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchRegionSize
+  gEfiMdeModulePkgTokenSpaceGuid.PcdAriSupport|TRUE
+  gEfiMdeModulePkgTokenSpaceGuid.PcdMrIovSupport|FALSE
+  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSupport|TRUE
+  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSystemPageSize|0x1
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuApInitTimeOutInMicroSeconds|5
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuApLoopMode|1
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchAddress|0x0
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchRegionSize|0x0
!if ($(TARGET) == DEBUG || $(USE_CBMEM_FOR_CONSOLE) == TRUE)
gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseSerial|TRUE
!else
--
2.38.1.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96217): https://edk2.groups.io/g/devel/message/96217
Mute This Topic: https://groups.io/mt/94949814/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] IntelFsp2Pkg: Improvement of supporting null UPD pointer in FSP-T

2022-11-10 Thread Chiu, Chasel

Sorry for missing this message.
Since this patch is important for unblocking platform FSP implementation, @Gao, 
Liming, @Kinney, Michael D, could you please help to merge it to catch this 
stable tag?

Thanks,
Chasel



> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of
> gaoliming via groups.io
> Sent: Thursday, November 10, 2022 4:54 PM
> To: Chiu, Chasel ; Kinney, Michael D
> 
> Cc: Desimone, Nathaniel L ; Zeng, Star
> ; S, Ashraf Ali ; Duggapu,
> Chinni B ; devel@edk2.groups.io; Kuo, Ted
> 
> Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> supporting null UPD pointer in FSP-T
> 
> Chasel:
>   Please see the announce mail
> https://edk2.groups.io/g/devel/message/96175
> 
>   Now, we are in soft feature freeze. If the patch wants to catch this stable
> tag, please highlight it and get approval from Stewards.
> 
> Thanks
> Liming
> > -邮件原件-
> > 发件人: Chiu, Chasel 
> > 发送时间: 2022年11月11日 8:47
> > 收件人: Gao, Liming ; Kinney, Michael D
> > 
> > 抄送: Desimone, Nathaniel L ; Zeng,
> Star
> > ; S, Ashraf Ali ;
> > Duggapu, Chinni B ; devel@edk2.groups.io;
> > Kuo, Ted 
> > 主题: RE: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> supporting
> > null UPD pointer in FSP-T
> >
> >
> > Hi Liming, Michael,
> >
> > May I know why we cannot merge this PR
> > https://github.com/tianocore/edk2/pull/3624 ?
> > Was it due to Hard Feature Freeze? But I thought we still have time right?
> >
> > Thanks,
> > Chasel
> >
> >
> > > -Original Message-
> > > From: devel@edk2.groups.io  On Behalf Of Kuo,
> > > Ted
> > > Sent: Wednesday, November 9, 2022 3:31 AM
> > > To: devel@edk2.groups.io
> > > Cc: Chiu, Chasel ; Desimone, Nathaniel L
> > > ; Zeng, Star ;
> > > S, Ashraf Ali ; Duggapu, Chinni B
> > > 
> > > Subject: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > supporting null UPD pointer in FSP-T
> > >
> > > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4114
> > >
> > > 1.Use xmm5 slot 1 and xmm6 slot 3 to save ucode status and UPD
> pointer
> > >   respectively in TempRamInitApi in IA32 FspSecCoreT.
> > > 2.Correct inappropriate description in the return value of
> > >   AsmGetFspInfoHeader.
> > > 3.Replace hardcoded offset value 0x1C with
> FSP_HEADER_IMGBASE_OFFSET
> > > in
> > >   FspHeler.nasm.
> > >
> > > Cc: Chasel Chiu 
> > > Cc: Nate DeSimone 
> > > Cc: Star Zeng 
> > > Cc: Ashraf Ali S 
> > > Cc: Chinni B Duggapu 
> > > Signed-off-by: Ted Kuo 
> > > ---
> > >  .../FspSecCore/Ia32/FspApiEntryT.nasm | 17 +++--
> > >  IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm   |  4 +-
> > >  .../FspSecCore/Ia32/SaveRestoreSseNasm.inc| 74
> > ++-
> > >  IntelFsp2Pkg/FspSecCore/SecFsp.h  |  2 +-
> > >  IntelFsp2Pkg/FspSecCore/X64/FspHelper.nasm|  4 +-
> > >  5 files changed, 55 insertions(+), 46 deletions(-)
> > >
> > > diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > index 73821ad22a..2cff8b3643 100644
> > > --- a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > +++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > @@ -594,37 +594,38 @@ ASM_PFX(TempRamInitApi):
> > >SAVE_EAX   SAVE_EDX +  CALL_EBP
> > ASM_PFX(LoadUpdPointerToECX) ;
> > > ECX for UPD param+  SAVE_ECX   ;
> > save UPD param to slot
> > > 3 in xmm6+   ;   ; Sec Platform Init   ;-  CALL_EBP
> > > ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param   CALL_MMX
> > > ASM_PFX(SecPlatformInit)   cmp   eax, 0   jnz
> > TempRamInitExit;
> > > Load microcode   LOAD_ESP-  CALL_EBP
> > ASM_PFX(LoadUpdPointerToECX) ;
> > > ECX for UPD param+  LOAD_ECX   CALL_MMX
> > > ASM_PFX(LoadMicrocodeDefault)-  SXMMN xmm6, 3,
> > eax;Save
> > > microcode return status in ECX-SLOT 3 in xmm6.+
> > > SAVE_UCODE_STATUS ; Save microcode return status in
> > slot 1 in
> > > xmm5.   ;@note If return value eax is not 0, microcode did not load, but
> > > continue and attempt to boot.; Call Sec CAR Init   LOAD_ESP-
> > CALL_EBP
> > > ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param+  LOAD_ECX
> > > CALL_MMX  ASM_PFX(SecCarInit)   cmp   eax, 0   jnz
> > TempRamInitExit
> > > LOAD_ESP-  CALL_EBP  ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD
> > > param-  mov   edi, ecx ; Save UPD param
> > to EDI for later code
> > > use+  LOAD_ECX+  mov   edi, ecx; Save UPD
> > param to EDI for
> > > later code use   CALL_MMX  ASM_PFX(EstablishStackFsp)   cmp
> > eax, 0
> > > jnz   TempRamInitExit -  LXMMN xmm6, eax, 3  ;Restore
> > microcode
> > > status if no CAR init error from ECX-SLOT 3 in xmm6.-  SXMMN xmm6,
> > 3,
> > > edi  ;Save FSP-T UPD parameter pointer in ECX-SLOT 3 in xmm6.+
> > > LOAD_UCODE_STATUS ; Restore microcode status if no
> > CAR init
> > > error from slot 1 in xmm5.  TempRamInitExit:   mov   bl,
> > al  ;
> > > save al data in bldiff --git

FW: [edk2-devel] [Patch v3 0/7] Add GoogleTest to UnitTestFrameworkPkg

2022-11-10 Thread Michael D Kinney
Liming,

The review for adding GoogleTest support to the UnitTestFrameworkPkg was started
before Soft Freeze and only had some minor documentation updates during the 
Soft Freeze.

I would like to request this PR be merged for the stable tag.

https://github.com/tianocore/edk2/pull/3595

It has all the commit messages updated with Rb/Ab and passes all CI checks.

Thanks,

Mike

-Original Message-
From: devel@edk2.groups.io  On Behalf Of Michael D Kinney
Sent: Tuesday, November 8, 2022 3:13 PM
To: devel@edk2.groups.io
Cc: Gao, Liming ; Liu, Zhiguang 
; Feng, Bob C ; Chen, Christine 
; Sean Brogan ; Michael 
Kubacki ; Andrew Fish ; Leif 
Lindholm 
Subject: [edk2-devel] [Patch v3 0/7] Add GoogleTest to UnitTestFrameworkPkg

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

Add GoogleTest support to UnitTestFrameworkPkg to provide an
additional host-based unit test framework to developers.

Code: https://github.com/google/googletest
Docs: https://google.github.io/googletest

GoogleTest is implemented in C++, but does support implementing
unit tests for C code.  This patch series makes a few updates for C++
compatibility and build issues related to multiple definitions of _ASSERT().
The GoogleTest git submodule is added to the UnitTestFrameworkPkg
and .pytools/CISettings.py file along with an update to the host-based
test runner plugin to set the GTEST_OUTPUT environment variable to 
specify the XML output file format and location.

A port of the unit tests for the the MdePkg BaseSafeIntLib are included
to provide an example that is in both the current unit test style and the
GoogleTest style.

New in V2
-
* Update maintainers/reviewers
* Add feature table to Readme.md and fix typos

New in V3
-
* Add link to googletest license file to Readme.rst 

Cc: Liming Gao 
Cc: Zhiguang Liu 
Cc: Bob Feng 
Cc: Yuwei Chen 
Cc: Sean Brogan 
Cc: Michael Kubacki 
Cc: Andrew Fish 
Cc: Leif Lindholm 
Signed-off-by: Michael D Kinney 

Michael D Kinney (7):
  MdePkg/Include: Update Base.h to improve C++ compatibility
  MdePkg/Include/Library: Undefine _ASSERT() if already defined
  UnitTestFrameworkPkg: Add googletest submodule and GoogleTestLib
  UnitTestFrameworkPkg/Library/CmockaLib: Generate symbol information
  .pytool: Add googletest submodule to CISettings.py
  BaseTools/Plugin/HostBaseUnitTestRunner: Enable gtest xml output
  MdePkg/Test: Add port of BaseSafeIntLib unit tests to GoogleTest

 .gitmodules   |3 +
 .pytool/CISettings.py |2 +
 .../HostBasedUnitTestRunner.py|7 +-
 MdePkg/Include/Base.h |   12 +-
 MdePkg/Include/Library/DebugLib.h |3 +
 .../GoogleTestBaseSafeIntLib.inf  |   37 +
 .../GoogleTestBaseSafeIntLib.uni  |   13 +
 .../SafeIntLibUintnIntnUnitTests32.cpp|  425 +++
 .../SafeIntLibUintnIntnUnitTests64.cpp|  429 
 .../BaseSafeIntLib/TestBaseSafeIntLib.cpp | 2274 +
 MdePkg/Test/MdePkgHostTest.dsc|1 +
 ReadMe.rst|1 +
 .../Include/Library/GoogleTestLib.h   |   14 +
 .../Library/CmockaLib/CmockaLib.inf   |2 +-
 .../Library/GoogleTestLib/GoogleTestLib.inf   |   36 +
 .../Library/GoogleTestLib/GoogleTestLib.uni   |   14 +
 .../Library/GoogleTestLib/googletest  |1 +
 UnitTestFrameworkPkg/ReadMe.md|  255 +-
 .../SampleGoogleTest/SampleGoogleTest.cpp |  263 ++
 .../SampleGoogleTest/SampleGoogleTestHost.inf |   35 +
 .../Test/UnitTestFrameworkPkgHostTest.dsc |4 +-
 .../UnitTestFrameworkPkg.ci.yaml  |4 +-
 UnitTestFrameworkPkg/UnitTestFrameworkPkg.dec |8 +
 .../UnitTestFrameworkPkgHost.dsc.inc  |4 +-
 24 files changed, 3811 insertions(+), 36 deletions(-)
 create mode 100644 
MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/GoogleTestBaseSafeIntLib.inf
 create mode 100644 
MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/GoogleTestBaseSafeIntLib.uni
 create mode 100644 
MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests32.cpp
 create mode 100644 
MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests64.cpp
 create mode 100644 
MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/TestBaseSafeIntLib.cpp
 create mode 100644 UnitTestFrameworkPkg/Include/Library/GoogleTestLib.h
 create mode 100644 UnitTestFrameworkPkg/Library/GoogleTestLib/GoogleTestLib.inf
 create mode 100644 UnitTestFrameworkPkg/Library/GoogleTestLib/GoogleTestLib.uni
 create mode 16 UnitTestFrameworkPkg/Library/GoogleTestLib/googletest
 create mode 100644 
UnitTestFrameworkPkg/Test/GoogleTest/Sample/SampleGoogleTest/SampleGoogleTest.cpp
 create mode 100644 
UnitTestFrameworkPkg/Test/GoogleTest/Sample/SampleGoogleTest/SampleGoogleTestHost.inf

-- 
2.37.1.windows.1








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

[edk2-devel] Open CI failure on CodeQL / Analyze

2022-11-10 Thread gaoliming via groups.io
Michael:

 Can you help check this failure in open CI? The failure is in
https://github.com/tianocore/edk2/pull/3611 

 

Thanks

Liming



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96220): https://edk2.groups.io/g/devel/message/96220
Mute This Topic: https://groups.io/mt/94950299/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




回复: [edk2-devel] [Patch v3 0/7] Add GoogleTest to UnitTestFrameworkPkg

2022-11-10 Thread gaoliming via groups.io
Mike:
  Since there is no big change in soft feature freeze phase, I agree to merge 
it for this stable tag.  

Thanks
Liming
> -邮件原件-
> 发件人: Kinney, Michael D 
> 发送时间: 2022年11月11日 9:10
> 收件人: Gao, Liming ; Kinney, Michael D
> ; devel@edk2.groups.io
> 主题: FW: [edk2-devel] [Patch v3 0/7] Add GoogleTest to
> UnitTestFrameworkPkg
> 
> Liming,
> 
> The review for adding GoogleTest support to the UnitTestFrameworkPkg was
> started
> before Soft Freeze and only had some minor documentation updates during
> the Soft Freeze.
> 
> I would like to request this PR be merged for the stable tag.
> 
> https://github.com/tianocore/edk2/pull/3595
> 
> It has all the commit messages updated with Rb/Ab and passes all CI checks.
> 
> Thanks,
> 
> Mike
> 
> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Michael
> D Kinney
> Sent: Tuesday, November 8, 2022 3:13 PM
> To: devel@edk2.groups.io
> Cc: Gao, Liming ; Liu, Zhiguang
> ; Feng, Bob C ; Chen,
> Christine ; Sean Brogan
> ; Michael Kubacki
> ; Andrew Fish ; Leif
> Lindholm 
> Subject: [edk2-devel] [Patch v3 0/7] Add GoogleTest to
> UnitTestFrameworkPkg
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4134
> 
> Add GoogleTest support to UnitTestFrameworkPkg to provide an
> additional host-based unit test framework to developers.
> 
> Code: https://github.com/google/googletest
> Docs: https://google.github.io/googletest
> 
> GoogleTest is implemented in C++, but does support implementing
> unit tests for C code.  This patch series makes a few updates for C++
> compatibility and build issues related to multiple definitions of _ASSERT().
> The GoogleTest git submodule is added to the UnitTestFrameworkPkg
> and .pytools/CISettings.py file along with an update to the host-based
> test runner plugin to set the GTEST_OUTPUT environment variable to
> specify the XML output file format and location.
> 
> A port of the unit tests for the the MdePkg BaseSafeIntLib are included
> to provide an example that is in both the current unit test style and the
> GoogleTest style.
> 
> New in V2
> -
> * Update maintainers/reviewers
> * Add feature table to Readme.md and fix typos
> 
> New in V3
> -
> * Add link to googletest license file to Readme.rst
> 
> Cc: Liming Gao 
> Cc: Zhiguang Liu 
> Cc: Bob Feng 
> Cc: Yuwei Chen 
> Cc: Sean Brogan 
> Cc: Michael Kubacki 
> Cc: Andrew Fish 
> Cc: Leif Lindholm 
> Signed-off-by: Michael D Kinney 
> 
> Michael D Kinney (7):
>   MdePkg/Include: Update Base.h to improve C++ compatibility
>   MdePkg/Include/Library: Undefine _ASSERT() if already defined
>   UnitTestFrameworkPkg: Add googletest submodule and GoogleTestLib
>   UnitTestFrameworkPkg/Library/CmockaLib: Generate symbol information
>   .pytool: Add googletest submodule to CISettings.py
>   BaseTools/Plugin/HostBaseUnitTestRunner: Enable gtest xml output
>   MdePkg/Test: Add port of BaseSafeIntLib unit tests to GoogleTest
> 
>  .gitmodules   |3 +
>  .pytool/CISettings.py |2 +
>  .../HostBasedUnitTestRunner.py|7 +-
>  MdePkg/Include/Base.h |   12 +-
>  MdePkg/Include/Library/DebugLib.h |3 +
>  .../GoogleTestBaseSafeIntLib.inf  |   37 +
>  .../GoogleTestBaseSafeIntLib.uni  |   13 +
>  .../SafeIntLibUintnIntnUnitTests32.cpp|  425 +++
>  .../SafeIntLibUintnIntnUnitTests64.cpp|  429 
>  .../BaseSafeIntLib/TestBaseSafeIntLib.cpp | 2274
> +
>  MdePkg/Test/MdePkgHostTest.dsc|1 +
>  ReadMe.rst|1 +
>  .../Include/Library/GoogleTestLib.h   |   14 +
>  .../Library/CmockaLib/CmockaLib.inf   |2 +-
>  .../Library/GoogleTestLib/GoogleTestLib.inf   |   36 +
>  .../Library/GoogleTestLib/GoogleTestLib.uni   |   14 +
>  .../Library/GoogleTestLib/googletest  |1 +
>  UnitTestFrameworkPkg/ReadMe.md|  255 +-
>  .../SampleGoogleTest/SampleGoogleTest.cpp |  263 ++
>  .../SampleGoogleTest/SampleGoogleTestHost.inf |   35 +
>  .../Test/UnitTestFrameworkPkgHostTest.dsc |4 +-
>  .../UnitTestFrameworkPkg.ci.yaml  |4 +-
>  UnitTestFrameworkPkg/UnitTestFrameworkPkg.dec |8 +
>  .../UnitTestFrameworkPkgHost.dsc.inc  |4 +-
>  24 files changed, 3811 insertions(+), 36 deletions(-)
>  create mode 100644
> MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/GoogleTestBaseSafeIntLib.i
> nf
>  create mode 100644
> MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/GoogleTestBaseSafeIntLib.u
> ni
>  create mode 100644
> MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTest
> s32.cpp
>  create mode 100644
> MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTest
> s64.cpp
>  create mode 100644
> MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/TestBaseSafeIntLib.cpp
>  create mode 100644
> UnitTestFrameworkPkg/Include/Library/Goog

回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting null UPD pointer in FSP-T

2022-11-10 Thread gaoliming via groups.io
Chasel:
  Seemly, this is a bug fix for the previous change. In soft feature freeze, 
the bug is still allowed. Since this patch has passed review, I can help merge 
it. 

Thanks
Liming
> -邮件原件-
> 发件人: devel@edk2.groups.io  代表 Chiu, Chasel
> 发送时间: 2022年11月11日 9:08
> 收件人: devel@edk2.groups.io; Gao, Liming ;
> Kinney, Michael D 
> 抄送: Desimone, Nathaniel L ; Zeng, Star
> ; S, Ashraf Ali ; Duggapu,
> Chinni B ; Kuo, Ted 
> 主题: Re: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting
> null UPD pointer in FSP-T
> 
> 
> Sorry for missing this message.
> Since this patch is important for unblocking platform FSP implementation,
> @Gao, Liming, @Kinney, Michael D, could you please help to merge it to catch
> this stable tag?
> 
> Thanks,
> Chasel
> 
> 
> 
> > -Original Message-
> > From: devel@edk2.groups.io  On Behalf Of
> > gaoliming via groups.io
> > Sent: Thursday, November 10, 2022 4:54 PM
> > To: Chiu, Chasel ; Kinney, Michael D
> > 
> > Cc: Desimone, Nathaniel L ; Zeng, Star
> > ; S, Ashraf Ali ; Duggapu,
> > Chinni B ; devel@edk2.groups.io; Kuo, Ted
> > 
> > Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > supporting null UPD pointer in FSP-T
> >
> > Chasel:
> >   Please see the announce mail
> > https://edk2.groups.io/g/devel/message/96175
> >
> >   Now, we are in soft feature freeze. If the patch wants to catch this 
> > stable
> > tag, please highlight it and get approval from Stewards.
> >
> > Thanks
> > Liming
> > > -邮件原件-
> > > 发件人: Chiu, Chasel 
> > > 发送时间: 2022年11月11日 8:47
> > > 收件人: Gao, Liming ; Kinney, Michael D
> > > 
> > > 抄送: Desimone, Nathaniel L ; Zeng,
> > Star
> > > ; S, Ashraf Ali ;
> > > Duggapu, Chinni B ; devel@edk2.groups.io;
> > > Kuo, Ted 
> > > 主题: RE: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > supporting
> > > null UPD pointer in FSP-T
> > >
> > >
> > > Hi Liming, Michael,
> > >
> > > May I know why we cannot merge this PR
> > > https://github.com/tianocore/edk2/pull/3624 ?
> > > Was it due to Hard Feature Freeze? But I thought we still have time right?
> > >
> > > Thanks,
> > > Chasel
> > >
> > >
> > > > -Original Message-
> > > > From: devel@edk2.groups.io  On Behalf Of Kuo,
> > > > Ted
> > > > Sent: Wednesday, November 9, 2022 3:31 AM
> > > > To: devel@edk2.groups.io
> > > > Cc: Chiu, Chasel ; Desimone, Nathaniel L
> > > > ; Zeng, Star ;
> > > > S, Ashraf Ali ; Duggapu, Chinni B
> > > > 
> > > > Subject: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > > supporting null UPD pointer in FSP-T
> > > >
> > > > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4114
> > > >
> > > > 1.Use xmm5 slot 1 and xmm6 slot 3 to save ucode status and UPD
> > pointer
> > > >   respectively in TempRamInitApi in IA32 FspSecCoreT.
> > > > 2.Correct inappropriate description in the return value of
> > > >   AsmGetFspInfoHeader.
> > > > 3.Replace hardcoded offset value 0x1C with
> > FSP_HEADER_IMGBASE_OFFSET
> > > > in
> > > >   FspHeler.nasm.
> > > >
> > > > Cc: Chasel Chiu 
> > > > Cc: Nate DeSimone 
> > > > Cc: Star Zeng 
> > > > Cc: Ashraf Ali S 
> > > > Cc: Chinni B Duggapu 
> > > > Signed-off-by: Ted Kuo 
> > > > ---
> > > >  .../FspSecCore/Ia32/FspApiEntryT.nasm | 17 +++--
> > > >  IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm   |  4 +-
> > > >  .../FspSecCore/Ia32/SaveRestoreSseNasm.inc| 74
> > > ++-
> > > >  IntelFsp2Pkg/FspSecCore/SecFsp.h  |  2 +-
> > > >  IntelFsp2Pkg/FspSecCore/X64/FspHelper.nasm|  4 +-
> > > >  5 files changed, 55 insertions(+), 46 deletions(-)
> > > >
> > > > diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > index 73821ad22a..2cff8b3643 100644
> > > > --- a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > +++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > @@ -594,37 +594,38 @@ ASM_PFX(TempRamInitApi):
> > > >SAVE_EAX   SAVE_EDX +  CALL_EBP
> > > ASM_PFX(LoadUpdPointerToECX) ;
> > > > ECX for UPD param+
> SAVE_ECX   ;
> > > save UPD param to slot
> > > > 3 in xmm6+   ;   ; Sec Platform Init   ;-  CALL_EBP
> > > > ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param   CALL_MMX
> > > > ASM_PFX(SecPlatformInit)   cmp   eax, 0   jnz
> > > TempRamInitExit;
> > > > Load microcode   LOAD_ESP-  CALL_EBP
> > > ASM_PFX(LoadUpdPointerToECX) ;
> > > > ECX for UPD param+  LOAD_ECX   CALL_MMX
> > > > ASM_PFX(LoadMicrocodeDefault)-  SXMMN xmm6, 3,
> > > eax;Save
> > > > microcode return status in ECX-SLOT 3 in xmm6.+
> > > > SAVE_UCODE_STATUS ; Save microcode return
> status in
> > > slot 1 in
> > > > xmm5.   ;@note If return value eax is not 0, microcode did not load,
> but
> > > > continue and attempt to boot.; Call Sec CAR Init   LOAD_ESP-
> > > CALL_EBP
> > > > ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param+  LOAD_ECX
> > > > CALL_MMX  ASM_PFX(SecCarInit)   cmp   eax, 0   jnz
> > > TempRam

Re: [edk2-devel] Open CI failure on CodeQL / Analyze

2022-11-10 Thread Michael Kubacki
I'm looking at it now.

Thanks,
Michael


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96223): https://edk2.groups.io/g/devel/message/96223
Mute This Topic: https://groups.io/mt/94950299/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [PATCH] UefiPayloadPkg: Define default values for the DynamicEX PCDs

2022-11-10 Thread Guo, Gua
Due to hardware freeze, it needs to wait after hardware freeze.

Reviewed-by: Gua Guo mailto:gua@intel.com>>

From: devel@edk2.groups.io  On Behalf Of Jiading Zhang
Sent: Friday, November 11, 2022 8:56 AM
To: devel@edk2.groups.io
Subject: [edk2-devel] [PATCH] UefiPayloadPkg: Define default values for the 
DynamicEX PCDs

The following PCDs have no value in UefiPayloadPkg.dsc,and they can not pass 
the Ecc tool check, so assign the default values the same as they are in *.dec 
file.
  gEfiMdeModulePkgTokenSpaceGuid.PcdAriSupport
  gEfiMdeModulePkgTokenSpaceGuid.PcdMrIovSupport
  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSupport
  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSystemPageSize
  gUefiCpuPkgTokenSpaceGuid.PcdCpuApInitTimeOutInMicroSeconds
  gUefiCpuPkgTokenSpaceGuid.PcdCpuApLoopMode
  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchAddress
  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchRegionSize

Signed-off-by: jdzhang 
mailto:jdzh...@kunluntech.com.cn>>
---
 UefiPayloadPkg/UefiPayloadPkg.dsc | 16 
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc 
b/UefiPayloadPkg/UefiPayloadPkg.dsc
index 1150be6acd..ce7d3a7f89 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.dsc
+++ b/UefiPayloadPkg/UefiPayloadPkg.dsc
@@ -530,14 +530,14 @@
   gEfiMdePkgTokenSpaceGuid.PcdUartDefaultParity|$(UART_DEFAULT_PARITY)
   gEfiMdePkgTokenSpaceGuid.PcdUartDefaultStopBits|$(UART_DEFAULT_STOP_BITS)
   gEfiMdePkgTokenSpaceGuid.PcdDefaultTerminalType|$(DEFAULT_TERMINAL_TYPE)
-  gEfiMdeModulePkgTokenSpaceGuid.PcdAriSupport
-  gEfiMdeModulePkgTokenSpaceGuid.PcdMrIovSupport
-  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSupport
-  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSystemPageSize
-  gUefiCpuPkgTokenSpaceGuid.PcdCpuApInitTimeOutInMicroSeconds
-  gUefiCpuPkgTokenSpaceGuid.PcdCpuApLoopMode
-  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchAddress
-  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchRegionSize
+  gEfiMdeModulePkgTokenSpaceGuid.PcdAriSupport|TRUE
+  gEfiMdeModulePkgTokenSpaceGuid.PcdMrIovSupport|FALSE
+  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSupport|TRUE
+  gEfiMdeModulePkgTokenSpaceGuid.PcdSrIovSystemPageSize|0x1
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuApInitTimeOutInMicroSeconds|5
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuApLoopMode|1
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchAddress|0x0
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchRegionSize|0x0
 !if ($(TARGET) == DEBUG || $(USE_CBMEM_FOR_CONSOLE) == TRUE)
   gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseSerial|TRUE
 !else
--
2.38.1.windows.1




-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96224): https://edk2.groups.io/g/devel/message/96224
Mute This Topic: https://groups.io/mt/94949814/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] Open CI failure on CodeQL / Analyze

2022-11-10 Thread Michael D Kinney
The CodeQL GitHub Action: 
https://github.com/tianocore/edk2/blob/master/.github/workflows/codeql-analysis.yml

Uses Windows-2019 image:

https://github.com/actions/runner-images/blob/main/images/win/Windows2019-Readme.md

That image include Python 3.7.9.

The latest version of Pytools required Python 3.9 or higher.

The CodeQL GitHub Action YML file needs to be updated to install Python 3.9.x.

Mike


From: devel@edk2.groups.io  On Behalf Of gaoliming via 
groups.io
Sent: Thursday, November 10, 2022 5:25 PM
To: michael.kuba...@outlook.com
Cc: Kinney, Michael D ; Kubacki, Michael 
; 'Michael Kubacki' 
; devel@edk2.groups.io
Subject: [edk2-devel] Open CI failure on CodeQL / Analyze

Michael:
 Can you help check this failure in open CI? The failure is in 
https://github.com/tianocore/edk2/pull/3611

Thanks
Liming



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96225): https://edk2.groups.io/g/devel/message/96225
Mute This Topic: https://groups.io/mt/94950299/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] Open CI failure on CodeQL / Analyze

2022-11-10 Thread Michael D Kinney
here is a PR with proposed change to install Python 3.9

https://github.com/tianocore/edk2/pull/3626

Mike

From: Kinney, Michael D 
Sent: Thursday, November 10, 2022 5:40 PM
To: devel@edk2.groups.io; Gao, Liming ; 
michael.kuba...@outlook.com; Kinney, Michael D 
Cc: Kubacki, Michael ; 'Michael Kubacki' 

Subject: RE: [edk2-devel] Open CI failure on CodeQL / Analyze

The CodeQL GitHub Action: 
https://github.com/tianocore/edk2/blob/master/.github/workflows/codeql-analysis.yml

Uses Windows-2019 image:

https://github.com/actions/runner-images/blob/main/images/win/Windows2019-Readme.md

That image include Python 3.7.9.

The latest version of Pytools required Python 3.9 or higher.

The CodeQL GitHub Action YML file needs to be updated to install Python 3.9.x.

Mike


From: devel@edk2.groups.io 
mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via 
groups.io
Sent: Thursday, November 10, 2022 5:25 PM
To: michael.kuba...@outlook.com
Cc: Kinney, Michael D 
mailto:michael.d.kin...@intel.com>>; Kubacki, 
Michael mailto:michael.kuba...@microsoft.com>>; 
'Michael Kubacki' 
mailto:mikub...@linux.microsoft.com>>; 
devel@edk2.groups.io
Subject: [edk2-devel] Open CI failure on CodeQL / Analyze

Michael:
 Can you help check this failure in open CI? The failure is in 
https://github.com/tianocore/edk2/pull/3611

Thanks
Liming



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96226): https://edk2.groups.io/g/devel/message/96226
Mute This Topic: https://groups.io/mt/94950299/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] Open CI failure on CodeQL / Analyze

2022-11-10 Thread Michael Kubacki
Hi Mike,

We have the Azure Pipeline on 3.10.6+ because of the following issue we 
encountered starting in Python 3.9.11.

3891 – Tar files fail with Python 3.9.11+ (tianocore.org) ( 
https://bugzilla.tianocore.org/show_bug.cgi?id=3891 )

I think it would be nice to align the Python version here for consistency with 
those pipelines.

Though that shouldn't be an issue on the Windows agents currently being used 
for CodeQL.

Thanks,
Michael


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96227): https://edk2.groups.io/g/devel/message/96227
Mute This Topic: https://groups.io/mt/94950299/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [Patch edk2-stable202211 1/1] .github/workflows: Update CodeQL to install Python 3.9

2022-11-10 Thread Michael D Kinney
Cc: Sean Brogan 
Cc: Michael Kubacki 
Cc: Liming Gao 
Signed-off-by: Michael D Kinney 
---
 .github/workflows/codeql-analysis.yml | 5 +
 1 file changed, 5 insertions(+)

diff --git a/.github/workflows/codeql-analysis.yml 
b/.github/workflows/codeql-analysis.yml
index 2eacb9c9e1a1..c8d9943b2292 100644
--- a/.github/workflows/codeql-analysis.yml
+++ b/.github/workflows/codeql-analysis.yml
@@ -62,6 +62,11 @@ jobs:
 - name: Checkout repository
   uses: actions/checkout@v3
 
+- name: Install Python
+  uses: actions/setup-python@v4
+  with:
+python-version: '3.9'
+
 # Initializes the CodeQL tools for scanning.
 - name: Initialize CodeQL
   uses: github/codeql-action/init@v2
-- 
2.37.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96228): https://edk2.groups.io/g/devel/message/96228
Mute This Topic: https://groups.io/mt/94950714/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] IntelFsp2Pkg: Improvement of supporting null UPD pointer in FSP-T

2022-11-10 Thread Chiu, Chasel

Thanks Liming!!

> -Original Message-
> From: gaoliming 
> Sent: Thursday, November 10, 2022 5:37 PM
> To: devel@edk2.groups.io; Chiu, Chasel ; Kinney,
> Michael D 
> Cc: Desimone, Nathaniel L ; Zeng, Star
> ; S, Ashraf Ali ; Duggapu,
> Chinni B ; Kuo, Ted 
> Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> supporting null UPD pointer in FSP-T
> 
> Chasel:
>   Seemly, this is a bug fix for the previous change. In soft feature freeze, 
> the
> bug is still allowed. Since this patch has passed review, I can help merge it.
> 
> Thanks
> Liming
> > -邮件原件-
> > 发件人: devel@edk2.groups.io  代表 Chiu,
> Chasel
> > 发送时间: 2022年11月11日 9:08
> > 收件人: devel@edk2.groups.io; Gao, Liming
> ;
> > Kinney, Michael D 
> > 抄送: Desimone, Nathaniel L ; Zeng,
> Star
> > ; S, Ashraf Ali ;
> > Duggapu, Chinni B ; Kuo, Ted
> > 
> > 主题: Re: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> supporting
> > null UPD pointer in FSP-T
> >
> >
> > Sorry for missing this message.
> > Since this patch is important for unblocking platform FSP
> > implementation, @Gao, Liming, @Kinney, Michael D, could you please
> > help to merge it to catch this stable tag?
> >
> > Thanks,
> > Chasel
> >
> >
> >
> > > -Original Message-
> > > From: devel@edk2.groups.io  On Behalf Of
> > > gaoliming via groups.io
> > > Sent: Thursday, November 10, 2022 4:54 PM
> > > To: Chiu, Chasel ; Kinney, Michael D
> > > 
> > > Cc: Desimone, Nathaniel L ; Zeng,
> > > Star ; S, Ashraf Ali ;
> > > Duggapu, Chinni B ;
> > > devel@edk2.groups.io; Kuo, Ted 
> > > Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > supporting null UPD pointer in FSP-T
> > >
> > > Chasel:
> > >   Please see the announce mail
> > > https://edk2.groups.io/g/devel/message/96175
> > >
> > >   Now, we are in soft feature freeze. If the patch wants to catch
> > > this stable tag, please highlight it and get approval from Stewards.
> > >
> > > Thanks
> > > Liming
> > > > -邮件原件-
> > > > 发件人: Chiu, Chasel 
> > > > 发送时间: 2022年11月11日 8:47
> > > > 收件人: Gao, Liming ; Kinney, Michael D
> > > > 
> > > > 抄送: Desimone, Nathaniel L ; Zeng,
> > > Star
> > > > ; S, Ashraf Ali ;
> > > > Duggapu, Chinni B ;
> > > > devel@edk2.groups.io; Kuo, Ted 
> > > > 主题: RE: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > supporting
> > > > null UPD pointer in FSP-T
> > > >
> > > >
> > > > Hi Liming, Michael,
> > > >
> > > > May I know why we cannot merge this PR
> > > > https://github.com/tianocore/edk2/pull/3624 ?
> > > > Was it due to Hard Feature Freeze? But I thought we still have time
> right?
> > > >
> > > > Thanks,
> > > > Chasel
> > > >
> > > >
> > > > > -Original Message-
> > > > > From: devel@edk2.groups.io  On Behalf Of
> > > > > Kuo, Ted
> > > > > Sent: Wednesday, November 9, 2022 3:31 AM
> > > > > To: devel@edk2.groups.io
> > > > > Cc: Chiu, Chasel ; Desimone, Nathaniel L
> > > > > ; Zeng, Star
> > > > > ; S, Ashraf Ali ;
> > > > > Duggapu, Chinni B 
> > > > > Subject: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > > > supporting null UPD pointer in FSP-T
> > > > >
> > > > > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4114
> > > > >
> > > > > 1.Use xmm5 slot 1 and xmm6 slot 3 to save ucode status and UPD
> > > pointer
> > > > >   respectively in TempRamInitApi in IA32 FspSecCoreT.
> > > > > 2.Correct inappropriate description in the return value of
> > > > >   AsmGetFspInfoHeader.
> > > > > 3.Replace hardcoded offset value 0x1C with
> > > FSP_HEADER_IMGBASE_OFFSET
> > > > > in
> > > > >   FspHeler.nasm.
> > > > >
> > > > > Cc: Chasel Chiu 
> > > > > Cc: Nate DeSimone 
> > > > > Cc: Star Zeng 
> > > > > Cc: Ashraf Ali S 
> > > > > Cc: Chinni B Duggapu 
> > > > > Signed-off-by: Ted Kuo 
> > > > > ---
> > > > >  .../FspSecCore/Ia32/FspApiEntryT.nasm | 17 +++--
> > > > >  IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm   |  4 +-
> > > > >  .../FspSecCore/Ia32/SaveRestoreSseNasm.inc| 74
> > > > ++-
> > > > >  IntelFsp2Pkg/FspSecCore/SecFsp.h  |  2 +-
> > > > >  IntelFsp2Pkg/FspSecCore/X64/FspHelper.nasm|  4 +-
> > > > >  5 files changed, 55 insertions(+), 46 deletions(-)
> > > > >
> > > > > diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > > b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > > index 73821ad22a..2cff8b3643 100644
> > > > > --- a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > > +++ b/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > > @@ -594,37 +594,38 @@ ASM_PFX(TempRamInitApi):
> > > > >SAVE_EAX   SAVE_EDX +  CALL_EBP
> > > > ASM_PFX(LoadUpdPointerToECX) ;
> > > > > ECX for UPD param+
> > SAVE_ECX   ;
> > > > save UPD param to slot
> > > > > 3 in xmm6+   ;   ; Sec Platform Init   ;-  CALL_EBP
> > > > > ASM_PFX(LoadUpdPointerToECX) ; ECX for UPD param   CALL_MMX
> > > > > ASM_PFX(SecPlatformInit)   cmp   eax, 0   jnz
> > > > TempRamInitExit;
> > > > > Load microcode   LOAD_ESP-  CALL_E

Re: [edk2-devel] [Patch edk2-stable202211 1/1] .github/workflows: Update CodeQL to install Python 3.9

2022-11-10 Thread Michael Kubacki
Reviewed-by: Michael Kubacki 

Suggest to align the Python version with that in 
edk2/platform-build-run-steps.yml at master · tianocore/edk2 (github.com) ( 
https://github.com/tianocore/edk2/blob/master/.azurepipelines/templates/platform-build-run-steps.yml
 ) for consistency.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96230): https://edk2.groups.io/g/devel/message/96230
Mute This Topic: https://groups.io/mt/94950714/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [Patch edk2-stable202211 1/1] .github/workflows: Update CodeQL to install Python 3.9

2022-11-10 Thread Michael D Kinney
I will update PR and patch for 3.10.6+

Mike

From: Michael Kubacki 
Sent: Thursday, November 10, 2022 6:00 PM
To: Kinney, Michael D ; devel@edk2.groups.io
Subject: Re: [edk2-devel] [Patch edk2-stable202211 1/1] .github/workflows: 
Update CodeQL to install Python 3.9

Reviewed-by: Michael Kubacki 
mailto:michael.kuba...@microsoft.com>>

Suggest to align the Python version with that in 
edk2/platform-build-run-steps.yml at master · tianocore/edk2 
(github.com)
 for consistency.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96231): https://edk2.groups.io/g/devel/message/96231
Mute This Topic: https://groups.io/mt/94950714/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [Patch V2 edk2-stable202211 1/1] .github/workflows: Update CodeQL to install Python 3.10.6

2022-11-10 Thread Michael D Kinney
Cc: Sean Brogan 
Cc: Michael Kubacki 
Cc: Liming Gao 
Signed-off-by: Michael D Kinney 
Reviewed-by: Michael Kubacki 
---
 .github/workflows/codeql-analysis.yml | 5 +
 1 file changed, 5 insertions(+)

diff --git a/.github/workflows/codeql-analysis.yml 
b/.github/workflows/codeql-analysis.yml
index 2eacb9c9e1a1..791f79d1f014 100644
--- a/.github/workflows/codeql-analysis.yml
+++ b/.github/workflows/codeql-analysis.yml
@@ -62,6 +62,11 @@ jobs:
 - name: Checkout repository
   uses: actions/checkout@v3
 
+- name: Install Python
+  uses: actions/setup-python@v4
+  with:
+python-version: '3.10.6'
+
 # Initializes the CodeQL tools for scanning.
 - name: Initialize CodeQL
   uses: github/codeql-action/init@v2
-- 
2.37.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96232): https://edk2.groups.io/g/devel/message/96232
Mute This Topic: https://groups.io/mt/94951122/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [Patch V2 edk2-stable202211 1/1] .github/workflows: Update CodeQL to install Python 3.10.6

2022-11-10 Thread Michael D Kinney
Hi Liming,

The PR for this change is: https://github.com/tianocore/edk2/pull/3626

It is still running, but it has installed Python 3.10.6, and has gotten past 
earlier failure point.

If it passes, you can make decision to merge and then see if the other failing 
PRs will now pass.

Best regards,

Mike

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Michael D 
> Kinney
> Sent: Thursday, November 10, 2022 6:19 PM
> To: devel@edk2.groups.io
> Cc: Sean Brogan ; Michael Kubacki 
> ; Gao, Liming
> 
> Subject: [edk2-devel] [Patch V2 edk2-stable202211 1/1] .github/workflows: 
> Update CodeQL to install Python 3.10.6
> 
> Cc: Sean Brogan 
> Cc: Michael Kubacki 
> Cc: Liming Gao 
> Signed-off-by: Michael D Kinney 
> Reviewed-by: Michael Kubacki 
> ---
>  .github/workflows/codeql-analysis.yml | 5 +
>  1 file changed, 5 insertions(+)
> 
> diff --git a/.github/workflows/codeql-analysis.yml 
> b/.github/workflows/codeql-analysis.yml
> index 2eacb9c9e1a1..791f79d1f014 100644
> --- a/.github/workflows/codeql-analysis.yml
> +++ b/.github/workflows/codeql-analysis.yml
> @@ -62,6 +62,11 @@ jobs:
>  - name: Checkout repository
>uses: actions/checkout@v3
> 
> +- name: Install Python
> +  uses: actions/setup-python@v4
> +  with:
> +python-version: '3.10.6'
> +
>  # Initializes the CodeQL tools for scanning.
>  - name: Initialize CodeQL
>uses: github/codeql-action/init@v2
> --
> 2.37.1.windows.1
> 
> 
> 
> 
> 



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96233): https://edk2.groups.io/g/devel/message/96233
Mute This Topic: https://groups.io/mt/94951122/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




回复: [edk2-devel] [Patch V2 edk2-stable202211 1/1] .github/workflows: Update CodeQL to install Python 3.10.6

2022-11-10 Thread gaoliming via groups.io
Mike:
  Thanks for your quick fix. I just merge it. 

Thanks
Liming
> -邮件原件-
> 发件人: devel@edk2.groups.io  代表 Michael D
> Kinney
> 发送时间: 2022年11月11日 10:24
> 收件人: devel@edk2.groups.io; Kinney, Michael D
> 
> 抄送: Sean Brogan ; Michael Kubacki
> ; Gao, Liming 
> 主题: Re: [edk2-devel] [Patch V2 edk2-stable202211 1/1] .github/workflows:
> Update CodeQL to install Python 3.10.6
> 
> Hi Liming,
> 
> The PR for this change is: https://github.com/tianocore/edk2/pull/3626
> 
> It is still running, but it has installed Python 3.10.6, and has gotten past 
> earlier
> failure point.
> 
> If it passes, you can make decision to merge and then see if the other failing
> PRs will now pass.
> 
> Best regards,
> 
> Mike
> 
> > -Original Message-
> > From: devel@edk2.groups.io  On Behalf Of Michael
> D Kinney
> > Sent: Thursday, November 10, 2022 6:19 PM
> > To: devel@edk2.groups.io
> > Cc: Sean Brogan ; Michael Kubacki
> ; Gao, Liming
> > 
> > Subject: [edk2-devel] [Patch V2 edk2-stable202211 1/1] .github/workflows:
> Update CodeQL to install Python 3.10.6
> >
> > Cc: Sean Brogan 
> > Cc: Michael Kubacki 
> > Cc: Liming Gao 
> > Signed-off-by: Michael D Kinney 
> > Reviewed-by: Michael Kubacki 
> > ---
> >  .github/workflows/codeql-analysis.yml | 5 +
> >  1 file changed, 5 insertions(+)
> >
> > diff --git a/.github/workflows/codeql-analysis.yml
> b/.github/workflows/codeql-analysis.yml
> > index 2eacb9c9e1a1..791f79d1f014 100644
> > --- a/.github/workflows/codeql-analysis.yml
> > +++ b/.github/workflows/codeql-analysis.yml
> > @@ -62,6 +62,11 @@ jobs:
> >  - name: Checkout repository
> >uses: actions/checkout@v3
> >
> > +- name: Install Python
> > +  uses: actions/setup-python@v4
> > +  with:
> > +python-version: '3.10.6'
> > +
> >  # Initializes the CodeQL tools for scanning.
> >  - name: Initialize CodeQL
> >uses: github/codeql-action/init@v2
> > --
> > 2.37.1.windows.1
> >
> >
> >
> >
> >
> 
> 
> 
> 
> 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96234): https://edk2.groups.io/g/devel/message/96234
Mute This Topic: https://groups.io/mt/94951806/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] Event: TianoCore Community Meeting - APAC/NAMO - Thursday, November 10, 2022 #cal-reminder

2022-11-10 Thread Group Notification
*Reminder: TianoCore Community Meeting - APAC/NAMO*

*When:*
Thursday, November 10, 2022
7:30pm to 8:30pm
(UTC-08:00) America/Los Angeles

*Where:*
https://teams.microsoft.com/l/meetup-join/19%3ameeting_Y2M1NDE3ODYtN2M3Yy00MDMxLTk3OWYtMTlkNjhlNWFlMjA2%40thread.v2/0?context=%7b%22Tid%22%3a%2246c98d88-e344-4ed4-8496-4ed7712e255d%22%2c%22Oid%22%3a%226e4ce4c4-1242-431b-9a51-92cd01a5df3c%22%7d

*Organizer:* Miki Demeter

View Event ( https://edk2.groups.io/g/devel/viewevent?eventid=1624385 )

*Description:*



Microsoft Teams meeting

*Join on your computer or mobile app*

Click here to join the meeting ( 
https://teams.microsoft.com/l/meetup-join/19%3ameeting_Y2M1NDE3ODYtN2M3Yy00MDMxLTk3OWYtMTlkNjhlNWFlMjA2%40thread.v2/0?context=%7b%22Tid%22%3a%2246c98d88-e344-4ed4-8496-4ed7712e255d%22%2c%22Oid%22%3a%226e4ce4c4-1242-431b-9a51-92cd01a5df3c%22%7d
 )

Meeting ID: 283 318 374 436
Passcode: 633zLo

Download Teams ( https://www.microsoft.com/en-us/microsoft-teams/download-app ) 
| Join on the web ( https://www.microsoft.com/microsoft-teams/join-a-meeting )

*Join with a video conferencing device*

te...@conf.intel.com

Video Conference ID: 119 493 012 8

Alternate VTC instructions ( 
https://conf.intel.com/teams/?conf=1194930128&ivr=teams&d=conf.intel.com&test=test_call
 )

Learn More ( https://aka.ms/JoinTeamsMeeting ) | Meeting options ( 
https://teams.microsoft.com/meetingOptions/?organizerId=6e4ce4c4-1242-431b-9a51-92cd01a5df3c&tenantId=46c98d88-e344-4ed4-8496-4ed7712e255d&threadId=19_meeting_Y2M1NDE3ODYtN2M3Yy00MDMxLTk3OWYtMTlkNjhlNWFlMjA2@thread.v2&messageId=0&language=en-US
 )




-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96235): https://edk2.groups.io/g/devel/message/96235
Mute This Topic: https://groups.io/mt/94929432/21656
Mute #cal-reminder:https://edk2.groups.io/g/devel/mutehashtag/cal-reminder
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] [PATCH] ShellPkg:Improved Smbios Type 9 data under smbiosview

2022-11-10 Thread gaoliming via groups.io
Sainadh:

It has been merged at c17c3c24d8c7dd2107bfcca86179d5375dceb42b

 

Thanks

Liming

发件人: devel@edk2.groups.io  代表 gaoliming via groups.io
发送时间: 2022年11月11日 8:47
收件人: 'Sainadh Nagolu' ; devel@edk2.groups.io
主题: 回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] [PATCH] 
ShellPkg:Improved Smbios Type 9 data under smbiosview

 

I see the failure that the code can’t clone success. I re-run it and check 
again. 

 

Thanks

Liming

发件人: sainadhn via groups.io mailto:sainadhn=ami@groups.io> > 
发送时间: 2022年11月10日 15:36
收件人: gaoliming mailto:gaolim...@byosoft.com.cn> >; 
devel@edk2.groups.io  
主题: Re: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] [PATCH] 
ShellPkg:Improved Smbios Type 9 data under smbiosview

 

Hi Liming,

I see the pull request CI check failed and changes are not merged. The failure 
is not related to ShellPkg changes.
Please help to check.

Thanks,
Sainadh. 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96237): https://edk2.groups.io/g/devel/message/96237
Mute This Topic: https://groups.io/mt/94952173/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




回复: [edk2-devel] 回复: [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL without virtio-rng

2022-11-10 Thread gaoliming via groups.io
It has been merged at c8fb7240469b5753773da4fa5710b870b790c363

Thanks
Liming
> -邮件原件-
> 发件人: devel@edk2.groups.io  代表 gaoliming via
> groups.io
> 发送时间: 2022年11月11日 8:42
> 收件人: 'Ard Biesheuvel' ; devel@edk2.groups.io
> 抄送: 'Rebecca Cran' ; 'Pierre Gondois'
> ; 'Leif Lindholm' ;
> 'Sami Mujawar' ; 'Gerd Hoffmann'
> ; 'Jason A . Donenfeld' 
> 主题: [edk2-devel] 回复: [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL
> without virtio-rng
> 
> Ard:
>   The first patch is the bug fix. I agree to merge it for this stable tag.
I
> will help merge it today.
> 
> Thanks
> Liming
> > -邮件原件-
> > 发件人: Ard Biesheuvel 
> > 发送时间: 2022年11月10日 21:48
> > 收件人: devel@edk2.groups.io
> > 抄送: Ard Biesheuvel ; Liming Gao
> > ; Rebecca Cran ; Pierre
> > Gondois ; Leif Lindholm
> > ; Sami Mujawar ;
> > Gerd Hoffmann ; Jason A . Donenfeld
> > 
> > 主题: [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL without virtio-rng
> >
> > Currently, we only expose EFI_RNG_PROTOCOL when running under QEMU
> if
> > it
> >
> > exposes a virtio-rng device. This means that generic EFI apps or
> >
> > loaders have no access to an entropy source if this device is
> >
> > unavailable, unless they implement their own arch-specific handling to
> >
> > figure out whether any CPU instructions or monitor calls can be used
> >
> > instead.
> >
> >
> >
> > So let's wire those up as EFI_RNG_PROTOCOL implementations as well,
> >
> > using the existing drivers and libraries.
> >
> >
> >
> > First patch is a bugfix - Liming, mind if I merge that right away?
> >
> > Thanks.
> >
> >
> >
> > Cc: Liming Gao 
> >
> > Cc: Rebecca Cran 
> >
> > Cc: Pierre Gondois 
> >
> > Cc: Leif Lindholm 
> >
> > Cc: Sami Mujawar 
> >
> > Cc: Gerd Hoffmann 
> >
> > Cc: Jason A. Donenfeld 
> >
> >
> >
> > Ard Biesheuvel (3):
> >
> >   ArmPkg/ArmTrngLib: Fix incorrect GUID reference in DEBUG() output
> >
> >   ArmVirtPkg/ArmVirtQemu: Expose TRNG hypercall via RngDxe if
> >
> > implemented
> >
> >   OvmfPkg/OvmfX86: Enable RDRAND based EFI_RNG_PROTOCOL
> > implementation
> >
> >
> >
> >  ArmPkg/Library/ArmTrngLib/ArmTrngLib.c |  2 +-
> >
> >  ArmVirtPkg/ArmVirtQemu.dsc | 11 +++
> >
> >  ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc   |  5 +
> >
> >  ArmVirtPkg/ArmVirtQemuKernel.dsc   | 11 +++
> >
> >  OvmfPkg/OvmfPkgIa32.dsc|  1 +
> >
> >  OvmfPkg/OvmfPkgIa32.fdf|  1 +
> >
> >  OvmfPkg/OvmfPkgIa32X64.dsc |  1 +
> >
> >  OvmfPkg/OvmfPkgIa32X64.fdf |  1 +
> >
> >  OvmfPkg/OvmfPkgX64.dsc |  1 +
> >
> >  OvmfPkg/OvmfPkgX64.fdf |  1 +
> >
> >  10 files changed, 34 insertions(+), 1 deletion(-)
> >
> >
> >
> > --
> >
> > 2.35.1
> >
> >
> 
> 
> 
> 
> 
> 
> 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96238): https://edk2.groups.io/g/devel/message/96238
Mute This Topic: https://groups.io/mt/94952178/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] 回复: [edk2-devel] [PATCH] ShellPkg:Improved Smbios Type 9 data under smbiosview

2022-11-10 Thread Sainadh Nagolu via groups.io
Thanks Liming.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96239): https://edk2.groups.io/g/devel/message/96239
Mute This Topic: https://groups.io/mt/94952173/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting null UPD pointer in FSP-T

2022-11-10 Thread gaoliming via groups.io
This change has been merged at 3182843f3bc92599fa2ed4fd13ffd3f75907fe9e

Thanks
Liming
> -邮件原件-
> 发件人: devel@edk2.groups.io  代表 Chiu, Chasel
> 发送时间: 2022年11月11日 9:57
> 收件人: Gao, Liming ; devel@edk2.groups.io;
> Kinney, Michael D 
> 抄送: Desimone, Nathaniel L ; Zeng, Star
> ; S, Ashraf Ali ; Duggapu,
> Chinni B ; Kuo, Ted 
> 主题: Re: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting
> null UPD pointer in FSP-T
> 
> 
> Thanks Liming!!
> 
> > -Original Message-
> > From: gaoliming 
> > Sent: Thursday, November 10, 2022 5:37 PM
> > To: devel@edk2.groups.io; Chiu, Chasel ; Kinney,
> > Michael D 
> > Cc: Desimone, Nathaniel L ; Zeng, Star
> > ; S, Ashraf Ali ; Duggapu,
> > Chinni B ; Kuo, Ted 
> > Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > supporting null UPD pointer in FSP-T
> >
> > Chasel:
> >   Seemly, this is a bug fix for the previous change. In soft feature freeze,
> the
> > bug is still allowed. Since this patch has passed review, I can help merge 
> > it.
> >
> > Thanks
> > Liming
> > > -邮件原件-
> > > 发件人: devel@edk2.groups.io  代表 Chiu,
> > Chasel
> > > 发送时间: 2022年11月11日 9:08
> > > 收件人: devel@edk2.groups.io; Gao, Liming
> > ;
> > > Kinney, Michael D 
> > > 抄送: Desimone, Nathaniel L ; Zeng,
> > Star
> > > ; S, Ashraf Ali ;
> > > Duggapu, Chinni B ; Kuo, Ted
> > > 
> > > 主题: Re: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > supporting
> > > null UPD pointer in FSP-T
> > >
> > >
> > > Sorry for missing this message.
> > > Since this patch is important for unblocking platform FSP
> > > implementation, @Gao, Liming, @Kinney, Michael D, could you please
> > > help to merge it to catch this stable tag?
> > >
> > > Thanks,
> > > Chasel
> > >
> > >
> > >
> > > > -Original Message-
> > > > From: devel@edk2.groups.io  On Behalf Of
> > > > gaoliming via groups.io
> > > > Sent: Thursday, November 10, 2022 4:54 PM
> > > > To: Chiu, Chasel ; Kinney, Michael D
> > > > 
> > > > Cc: Desimone, Nathaniel L ; Zeng,
> > > > Star ; S, Ashraf Ali ;
> > > > Duggapu, Chinni B ;
> > > > devel@edk2.groups.io; Kuo, Ted 
> > > > Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > > supporting null UPD pointer in FSP-T
> > > >
> > > > Chasel:
> > > >   Please see the announce mail
> > > > https://edk2.groups.io/g/devel/message/96175
> > > >
> > > >   Now, we are in soft feature freeze. If the patch wants to catch
> > > > this stable tag, please highlight it and get approval from Stewards.
> > > >
> > > > Thanks
> > > > Liming
> > > > > -邮件原件-
> > > > > 发件人: Chiu, Chasel 
> > > > > 发送时间: 2022年11月11日 8:47
> > > > > 收件人: Gao, Liming ; Kinney, Michael D
> > > > > 
> > > > > 抄送: Desimone, Nathaniel L ;
> Zeng,
> > > > Star
> > > > > ; S, Ashraf Ali ;
> > > > > Duggapu, Chinni B ;
> > > > > devel@edk2.groups.io; Kuo, Ted 
> > > > > 主题: RE: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > > supporting
> > > > > null UPD pointer in FSP-T
> > > > >
> > > > >
> > > > > Hi Liming, Michael,
> > > > >
> > > > > May I know why we cannot merge this PR
> > > > > https://github.com/tianocore/edk2/pull/3624 ?
> > > > > Was it due to Hard Feature Freeze? But I thought we still have time
> > right?
> > > > >
> > > > > Thanks,
> > > > > Chasel
> > > > >
> > > > >
> > > > > > -Original Message-
> > > > > > From: devel@edk2.groups.io  On Behalf Of
> > > > > > Kuo, Ted
> > > > > > Sent: Wednesday, November 9, 2022 3:31 AM
> > > > > > To: devel@edk2.groups.io
> > > > > > Cc: Chiu, Chasel ; Desimone, Nathaniel L
> > > > > > ; Zeng, Star
> > > > > > ; S, Ashraf Ali ;
> > > > > > Duggapu, Chinni B 
> > > > > > Subject: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > > > > supporting null UPD pointer in FSP-T
> > > > > >
> > > > > > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4114
> > > > > >
> > > > > > 1.Use xmm5 slot 1 and xmm6 slot 3 to save ucode status and UPD
> > > > pointer
> > > > > >   respectively in TempRamInitApi in IA32 FspSecCoreT.
> > > > > > 2.Correct inappropriate description in the return value of
> > > > > >   AsmGetFspInfoHeader.
> > > > > > 3.Replace hardcoded offset value 0x1C with
> > > > FSP_HEADER_IMGBASE_OFFSET
> > > > > > in
> > > > > >   FspHeler.nasm.
> > > > > >
> > > > > > Cc: Chasel Chiu 
> > > > > > Cc: Nate DeSimone 
> > > > > > Cc: Star Zeng 
> > > > > > Cc: Ashraf Ali S 
> > > > > > Cc: Chinni B Duggapu 
> > > > > > Signed-off-by: Ted Kuo 
> > > > > > ---
> > > > > >  .../FspSecCore/Ia32/FspApiEntryT.nasm | 17 +++--
> > > > > >  IntelFsp2Pkg/FspSecCore/Ia32/FspHelper.nasm   |  4 +-
> > > > > >  .../FspSecCore/Ia32/SaveRestoreSseNasm.inc| 74
> > > > > ++-
> > > > > >  IntelFsp2Pkg/FspSecCore/SecFsp.h  |  2 +-
> > > > > >  IntelFsp2Pkg/FspSecCore/X64/FspHelper.nasm|  4 +-
> > > > > >  5 files changed, 55 insertions(+), 46 deletions(-)
> > > > > >
> > > > > > diff --git a/IntelFsp2Pkg/FspSecCore/Ia32/FspApiEntryT.nasm
> > > > > > b/IntelFsp2Pkg/FspSec

Re: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of supporting null UPD pointer in FSP-T

2022-11-10 Thread Chiu, Chasel

Thanks Liming!!

> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of
> gaoliming via groups.io
> Sent: Thursday, November 10, 2022 8:52 PM
> To: devel@edk2.groups.io; Chiu, Chasel ; Kinney,
> Michael D 
> Cc: Desimone, Nathaniel L ; Zeng, Star
> ; S, Ashraf Ali ; Duggapu,
> Chinni B ; Kuo, Ted 
> Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> supporting null UPD pointer in FSP-T
> 
> This change has been merged at
> 3182843f3bc92599fa2ed4fd13ffd3f75907fe9e
> 
> Thanks
> Liming
> > -邮件原件-
> > 发件人: devel@edk2.groups.io  代表 Chiu,
> Chasel
> > 发送时间: 2022年11月11日 9:57
> > 收件人: Gao, Liming ;
> devel@edk2.groups.io;
> > Kinney, Michael D 
> > 抄送: Desimone, Nathaniel L ; Zeng,
> Star
> > ; S, Ashraf Ali ;
> > Duggapu, Chinni B ; Kuo, Ted
> > 
> > 主题: Re: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> supporting
> > null UPD pointer in FSP-T
> >
> >
> > Thanks Liming!!
> >
> > > -Original Message-
> > > From: gaoliming 
> > > Sent: Thursday, November 10, 2022 5:37 PM
> > > To: devel@edk2.groups.io; Chiu, Chasel ;
> > > Kinney, Michael D 
> > > Cc: Desimone, Nathaniel L ; Zeng,
> > > Star ; S, Ashraf Ali ;
> > > Duggapu, Chinni B ; Kuo, Ted
> > > 
> > > Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > supporting null UPD pointer in FSP-T
> > >
> > > Chasel:
> > >   Seemly, this is a bug fix for the previous change. In soft feature
> > > freeze,
> > the
> > > bug is still allowed. Since this patch has passed review, I can help merge
> it.
> > >
> > > Thanks
> > > Liming
> > > > -邮件原件-
> > > > 发件人: devel@edk2.groups.io  代表 Chiu,
> > > Chasel
> > > > 发送时间: 2022年11月11日 9:08
> > > > 收件人: devel@edk2.groups.io; Gao, Liming
> > > ;
> > > > Kinney, Michael D 
> > > > 抄送: Desimone, Nathaniel L ; Zeng,
> > > Star
> > > > ; S, Ashraf Ali ;
> > > > Duggapu, Chinni B ; Kuo, Ted
> > > > 
> > > > 主题: Re: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > supporting
> > > > null UPD pointer in FSP-T
> > > >
> > > >
> > > > Sorry for missing this message.
> > > > Since this patch is important for unblocking platform FSP
> > > > implementation, @Gao, Liming, @Kinney, Michael D, could you please
> > > > help to merge it to catch this stable tag?
> > > >
> > > > Thanks,
> > > > Chasel
> > > >
> > > >
> > > >
> > > > > -Original Message-
> > > > > From: devel@edk2.groups.io  On Behalf Of
> > > > > gaoliming via groups.io
> > > > > Sent: Thursday, November 10, 2022 4:54 PM
> > > > > To: Chiu, Chasel ; Kinney, Michael D
> > > > > 
> > > > > Cc: Desimone, Nathaniel L ;
> > > > > Zeng, Star ; S, Ashraf Ali
> > > > > ; Duggapu, Chinni B
> > > > > ; devel@edk2.groups.io; Kuo, Ted
> > > > > 
> > > > > Subject: 回复: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement
> of
> > > > > supporting null UPD pointer in FSP-T
> > > > >
> > > > > Chasel:
> > > > >   Please see the announce mail
> > > > > https://edk2.groups.io/g/devel/message/96175
> > > > >
> > > > >   Now, we are in soft feature freeze. If the patch wants to
> > > > > catch this stable tag, please highlight it and get approval from
> Stewards.
> > > > >
> > > > > Thanks
> > > > > Liming
> > > > > > -邮件原件-
> > > > > > 发件人: Chiu, Chasel 
> > > > > > 发送时间: 2022年11月11日 8:47
> > > > > > 收件人: Gao, Liming ; Kinney,
> Michael D
> > > > > > 
> > > > > > 抄送: Desimone, Nathaniel L ;
> > Zeng,
> > > > > Star
> > > > > > ; S, Ashraf Ali ;
> > > > > > Duggapu, Chinni B ;
> > > > > > devel@edk2.groups.io; Kuo, Ted 
> > > > > > 主题: RE: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > > > supporting
> > > > > > null UPD pointer in FSP-T
> > > > > >
> > > > > >
> > > > > > Hi Liming, Michael,
> > > > > >
> > > > > > May I know why we cannot merge this PR
> > > > > > https://github.com/tianocore/edk2/pull/3624 ?
> > > > > > Was it due to Hard Feature Freeze? But I thought we still have
> > > > > > time
> > > right?
> > > > > >
> > > > > > Thanks,
> > > > > > Chasel
> > > > > >
> > > > > >
> > > > > > > -Original Message-
> > > > > > > From: devel@edk2.groups.io  On Behalf
> > > > > > > Of Kuo, Ted
> > > > > > > Sent: Wednesday, November 9, 2022 3:31 AM
> > > > > > > To: devel@edk2.groups.io
> > > > > > > Cc: Chiu, Chasel ; Desimone,
> > > > > > > Nathaniel L ; Zeng, Star
> > > > > > > ; S, Ashraf Ali
> > > > > > > ; Duggapu, Chinni B
> > > > > > > 
> > > > > > > Subject: [edk2-devel][PATCH v1] IntelFsp2Pkg: Improvement of
> > > > > > > supporting null UPD pointer in FSP-T
> > > > > > >
> > > > > > > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4114
> > > > > > >
> > > > > > > 1.Use xmm5 slot 1 and xmm6 slot 3 to save ucode status and
> > > > > > > UPD
> > > > > pointer
> > > > > > >   respectively in TempRamInitApi in IA32 FspSecCoreT.
> > > > > > > 2.Correct inappropriate description in the return value of
> > > > > > >   AsmGetFspInfoHeader.
> > > > > > > 3.Replace hardcoded offset value 0x1C with
> > > > > FSP_HEADER_IMGBASE_OFFSET
> > > > > > > in
> > > > > > >   FspH

[edk2-devel] [PATCH V5 0/3] Rename VmgExitLib to CcExitLib

2022-11-10 Thread Min Xu
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4123

VmgExitLib once was designed to provide interfaces to support #VC handler
and issue VMGEXIT instruction. After TDVF (enable TDX feature in OVMF) is
introduced, this library is updated to support #VE as well. Now the name
of VmgExitLib cannot reflect what the lib does.

This patch-set renames VmgExitLib to CcExitLib (Cc means Confidential
Computing). This is simple renaming and there is no logic changes. Then
APIs defined in CcExitLib.h are added with a CcExit prefix. This is to
make the name more meaningful.

Please to be noted, changing the name of VmgExitLib to CcExitLib is a
non-backwards compatible change from a platform DSC file perspective for
downstream consumers. So for downstream platform below changes should
be applied:
1. For DSC files:
- VmgExitLib|OvmfPkg/Library/VmgExitLib/SecVmgExitLib.inf =>
  CcExitLib|OvmfPkg/Library/CcExitLib/SecCcExitLib.inf

- VmgExitLib|UefiCpuPkg/Library/VmgExitLibNull/VmgExitLibNull.inf =>
  CcExitLib|UefiCpuPkg/Library/CcExitLibNull/CcExitLibNull.inf

- VmgExitLib|OvmfPkg/Library/VmgExitLib/SecVmgExitLib.inf =>
  CcExitLib|OvmfPkg/Library/CcExitLib/SecCcExitLib.inf

2. For INF files:
- VmgExitLib => CcExitLib

3. For Header files
- #include  => #include 

4. For C files
- Replace the APIs defined in the VmgExitLib.h with the ones defined in
  CcExitLib.h. The old name is renamed by adding a prefix (CcExit).
  For example VmgInit is renamed as CcExitVmgInit.

Code: https://github.com/mxu9/edk2/tree/CcExitLib.v5

v5 changes:
 - Rebased the code base to c17c3c24d8.
 - Add instructions in patch#0 on what updates to a downstream
   platform DSC.

v4 changes:
 - The previous versions of the patch-set are to first duplicate a new
   CcExitLib then delete the old VmgExitLib. According to this comments
   https://edk2.groups.io/g/devel/message/96019 it suggests renaming in
   a single patch is better.
 - Lib APIs are added with CcExit prefix, not CcExitLib prefix.

v3 changes:
 - Rename CcExitHandleVc / CcExitHandleVe to
   CcExitLibHandleVc / CcExitLibHandleVe to make the nameing consistent.
 - Update the CcExitLib to merge the patch eff44c008d99
  (OvmfPkg/VmgExitLig: HALT on #VE when access to private memory).
 
v2 changes:
 - Patch #3 is added to import CcExitLib in OvmfPkg's *.dsc. This is to
   prevent the building from being broken in the following patches.

Cc: Eric Dong 
Cc: Ray Ni 
Cc: Brijesh Singh 
Cc: Erdem Aktas 
Cc: Gerd Hoffmann 
Cc: James Bottomley 
Cc: Jiewen Yao 
Cc: Tom Lendacky 
Cc: Guo Dong 
Cc: Sean Rhodes 
Cc: James Lu 
Cc: Gua Guo 
Cc: Michael D Kinney 
Cc: Liming Gao 
Signed-off-by: Min Xu 

Min M Xu (3):
  OvmfPkg/UefiCpuPkg/UefiPayloadPkg: Rename VmgExitLib to CcExitLib
  OvmfPkg/UefiCpuPkg: Add CcExit prefix to the APIs of CcExitLib
  Maintainers: Update the VmgExitLib to CcExitLib

 Maintainers.txt   |   2 +-
 OvmfPkg/AmdSev/AmdSevX64.dsc  |   4 +-
 OvmfPkg/Bhyve/BhyveX64.dsc|   2 +-
 OvmfPkg/CloudHv/CloudHvX64.dsc|   6 +-
 OvmfPkg/IntelTdx/IntelTdxX64.dsc  |   4 +-
 .../DxeMemEncryptSevLib.inf   |   2 +-
 .../PeiMemEncryptSevLib.inf   |   2 +-
 .../SecMemEncryptSevLib.inf   |   2 +-
 .../X64/SnpPageStateChangeInternal.c  |  10 +-
 .../VmgExitLib.c => CcExitLib/CcExitLib.c}|  23 ++--
 .../CcExitLib.inf}|  17 +--
 .../CcExitTd.h}   |   4 +-
 .../CcExitVcHandler.c}| 129 +-
 .../CcExitVcHandler.h}|   6 +-
 .../CcExitVeHandler.c}|   6 +-
 .../PeiDxeCcExitVcHandler.c}  |   6 +-
 .../SecCcExitLib.inf} |  14 +-
 .../SecCcExitVcHandler.c} |   6 +-
 .../X64/TdVmcallCpuid.nasm|   0
 OvmfPkg/Microvm/MicrovmX64.dsc|   4 +-
 OvmfPkg/OvmfPkgIa32.dsc   |   4 +-
 OvmfPkg/OvmfPkgIa32X64.dsc|   4 +-
 OvmfPkg/OvmfPkgX64.dsc|   6 +-
 OvmfPkg/OvmfXen.dsc   |   2 +-
 OvmfPkg/PlatformPei/AmdSev.c  |  10 +-
 OvmfPkg/PlatformPei/PlatformPei.inf   |   2 +-
 .../FvbServicesRuntimeDxe.inf |   2 +-
 .../QemuFlashDxe.c|  10 +-
 .../Library/{VmgExitLib.h => CcExitLib.h} |  29 ++--
 .../CcExitLibNull.c}  |  47 +--
 .../CcExitLibNull.inf}|  12 +-
 .../Library/CcExitLibNull/CcExitLibNull.uni   |  14 ++
 .../DxeCpuExceptionHandlerLib.inf |   2 +-
 .../PeiCpuExceptionHandlerLib.inf |   2 +-
 .../PeiDxeSmmCpuException.c   |   6 +-
 .../SecPeiCpuException.c  |   6 +-
 .../SecPeiCpuExceptionHandlerLib.inf  |   2 +-
 .../SmmCpuExceptionHandlerLib.inf |   2 

[edk2-devel] [PATCH V5 1/3] OvmfPkg/UefiCpuPkg/UefiPayloadPkg: Rename VmgExitLib to CcExitLib

2022-11-10 Thread Min Xu
From: Min M Xu 

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

VmgExitLib once was designed to provide interfaces to support #VC handler
and issue VMGEXIT instruction. After TDVF (enable TDX feature in OVMF) is
introduced, this library is updated to support #VE as well. Now the name
of VmgExitLib cannot reflect what the lib does.

This patch renames VmgExitLib to CcExitLib (Cc means Confidential
Computing). This is a simple renaming and there is no logic changes.
After renaming all the VmgExitLib related codes are updated with
CcExitLib. These changes are in OvmfPkg/UefiCpuPkg/UefiPayloadPkg.

Cc: Guo Dong 
Cc: Sean Rhodes 
Cc: James Lu 
Cc: Gua Guo 
Cc: Eric Dong 
Cc: Ray Ni 
Cc: Brijesh Singh 
Cc: Erdem Aktas 
Cc: Gerd Hoffmann 
Cc: James Bottomley 
Cc: Jiewen Yao 
Cc: Tom Lendacky 
Reviewed-by: James Lu 
Reviewed-by: Gua Guo 
Reviewed-by: Jiewen Yao 
Reviewed-by: Ray Ni 
Signed-off-by: Min Xu 
---
 OvmfPkg/AmdSev/AmdSevX64.dsc  |  4 +-
 OvmfPkg/Bhyve/BhyveX64.dsc|  2 +-
 OvmfPkg/CloudHv/CloudHvX64.dsc|  6 +--
 OvmfPkg/IntelTdx/IntelTdxX64.dsc  |  4 +-
 .../DxeMemEncryptSevLib.inf   |  2 +-
 .../PeiMemEncryptSevLib.inf   |  2 +-
 .../SecMemEncryptSevLib.inf   |  2 +-
 .../X64/SnpPageStateChangeInternal.c  |  2 +-
 .../VmgExitLib.c => CcExitLib/CcExitLib.c}|  5 ++-
 .../CcExitLib.inf}| 17 +
 .../CcExitTd.h}   |  4 +-
 .../CcExitVcHandler.c}|  5 +--
 .../CcExitVcHandler.h}|  6 +--
 .../CcExitVeHandler.c}|  4 +-
 .../PeiDxeCcExitVcHandler.c}  |  4 +-
 .../SecCcExitLib.inf} | 14 +++
 .../SecCcExitVcHandler.c} |  4 +-
 .../X64/TdVmcallCpuid.nasm|  0
 OvmfPkg/Microvm/MicrovmX64.dsc|  4 +-
 OvmfPkg/OvmfPkgIa32.dsc   |  4 +-
 OvmfPkg/OvmfPkgIa32X64.dsc|  4 +-
 OvmfPkg/OvmfPkgX64.dsc|  6 +--
 OvmfPkg/OvmfXen.dsc   |  2 +-
 OvmfPkg/PlatformPei/AmdSev.c  |  2 +-
 OvmfPkg/PlatformPei/PlatformPei.inf   |  2 +-
 .../FvbServicesRuntimeDxe.inf |  2 +-
 .../QemuFlashDxe.c|  2 +-
 .../Library/{VmgExitLib.h => CcExitLib.h} | 13 ---
 .../CcExitLibNull.c}  | 33 +++-
 .../CcExitLibNull.inf}| 12 +++---
 .../Library/CcExitLibNull/CcExitLibNull.uni   | 14 +++
 .../DxeCpuExceptionHandlerLib.inf |  2 +-
 .../PeiCpuExceptionHandlerLib.inf |  2 +-
 .../PeiDxeSmmCpuException.c   |  2 +-
 .../SecPeiCpuException.c  |  2 +-
 .../SecPeiCpuExceptionHandlerLib.inf  |  2 +-
 .../SmmCpuExceptionHandlerLib.inf |  2 +-
 .../Xcode5SecPeiCpuExceptionHandlerLib.inf|  2 +-
 UefiCpuPkg/Library/MpInitLib/AmdSev.c |  2 +-
 UefiCpuPkg/Library/MpInitLib/DxeMpInitLib.inf |  2 +-
 UefiCpuPkg/Library/MpInitLib/DxeMpLib.c   |  2 +-
 UefiCpuPkg/Library/MpInitLib/MpLib.c  |  2 +-
 UefiCpuPkg/Library/MpInitLib/PeiMpInitLib.inf |  2 +-
 UefiCpuPkg/Library/MpInitLib/X64/AmdSev.c |  2 +-
 .../Library/VmgExitLibNull/VmTdExitNull.c | 38 ---
 .../Library/VmgExitLibNull/VmgExitLibNull.uni | 15 
 UefiCpuPkg/UefiCpuPkg.dec |  4 +-
 UefiCpuPkg/UefiCpuPkg.dsc |  4 +-
 UefiPayloadPkg/UefiPayloadPkg.dsc |  2 +-
 49 files changed, 135 insertions(+), 141 deletions(-)
 rename OvmfPkg/Library/{VmgExitLib/VmgExitLib.c => CcExitLib/CcExitLib.c} (94%)
 rename OvmfPkg/Library/{VmgExitLib/VmgExitLib.inf => CcExitLib/CcExitLib.inf} 
(66%)
 rename OvmfPkg/Library/{VmgExitLib/VmTdExitHandler.h => CcExitLib/CcExitTd.h} 
(86%)
 rename OvmfPkg/Library/{VmgExitLib/VmgExitVcHandler.c => 
CcExitLib/CcExitVcHandler.c} (95%)
 rename OvmfPkg/Library/{VmgExitLib/VmgExitVcHandler.h => 
CcExitLib/CcExitVcHandler.h} (89%)
 rename OvmfPkg/Library/{VmgExitLib/VmTdExitVeHandler.c => 
CcExitLib/CcExitVeHandler.c} (95%)
 rename OvmfPkg/Library/{VmgExitLib/PeiDxeVmgExitVcHandler.c => 
CcExitLib/PeiDxeCcExitVcHandler.c} (94%)
 rename OvmfPkg/Library/{VmgExitLib/SecVmgExitLib.inf => 
CcExitLib/SecCcExitLib.inf} (79%)
 rename OvmfPkg/Library/{VmgExitLib/SecVmgExitVcHandler.c => 
CcExitLib/SecCcExitVcHandler.c} (94%)
 rename OvmfPkg/Library/{VmgExitLib => CcExitLib}/X64/TdVmcallCpuid.nasm (100%)
 rename UefiCpuPkg/Include/Library/{VmgExitLib.h => CcExitLib.h} (89%)
 rename UefiCpuPkg/Library/{VmgExitLibNull/VmgExitLibNull.c => 
CcExitLibNull/CcExitLibNull.c} (79%)
 rename UefiCpuPkg/Library/{VmgExitLibNull/VmgExitLibNull.inf => 
CcExitLibNull/CcExitLibNull.inf} (60%)
 create mode 100644 UefiCpuPkg/Library/CcExitLibNull/CcExitLibNull.u

[edk2-devel] [PATCH V5 2/3] OvmfPkg/UefiCpuPkg: Add CcExit prefix to the APIs of CcExitLib

2022-11-10 Thread Min Xu
From: Min M Xu 

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

APIs which are defined in CcExitLib.h are added with the CcExit prefix.
This is to make the APIs' name more meaningful.

This change impacts OvmfPkg/UefiCpuPkg.

Cc: Eric Dong 
Cc: Ray Ni 
Cc: Brijesh Singh 
Cc: Erdem Aktas 
Cc: Gerd Hoffmann 
Cc: James Bottomley 
Cc: Jiewen Yao 
Cc: Tom Lendacky 
Reviewed-by: Jiewen Yao 
Reviewed-by: Ray Ni 
Signed-off-by: Min Xu 
---
 .../X64/SnpPageStateChangeInternal.c  |   8 +-
 OvmfPkg/Library/CcExitLib/CcExitLib.c |  18 +--
 OvmfPkg/Library/CcExitLib/CcExitVcHandler.c   | 124 +-
 OvmfPkg/Library/CcExitLib/CcExitVeHandler.c   |   2 +-
 .../Library/CcExitLib/PeiDxeCcExitVcHandler.c |   2 +-
 .../Library/CcExitLib/SecCcExitVcHandler.c|   2 +-
 OvmfPkg/PlatformPei/AmdSev.c  |   8 +-
 .../QemuFlashDxe.c|   8 +-
 UefiCpuPkg/Include/Library/CcExitLib.h|  16 +--
 .../Library/CcExitLibNull/CcExitLibNull.c |  16 +--
 .../PeiDxeSmmCpuException.c   |   4 +-
 .../SecPeiCpuException.c  |   4 +-
 UefiCpuPkg/Library/MpInitLib/AmdSev.c |   8 +-
 UefiCpuPkg/Library/MpInitLib/DxeMpLib.c   |   6 +-
 UefiCpuPkg/Library/MpInitLib/X64/AmdSev.c |   8 +-
 15 files changed, 117 insertions(+), 117 deletions(-)

diff --git 
a/OvmfPkg/Library/BaseMemEncryptSevLib/X64/SnpPageStateChangeInternal.c 
b/OvmfPkg/Library/BaseMemEncryptSevLib/X64/SnpPageStateChangeInternal.c
index 73698a7b9d8c..4d684964d838 100644
--- a/OvmfPkg/Library/BaseMemEncryptSevLib/X64/SnpPageStateChangeInternal.c
+++ b/OvmfPkg/Library/BaseMemEncryptSevLib/X64/SnpPageStateChangeInternal.c
@@ -193,9 +193,9 @@ PageStateChangeVmgExit (
   //
   while (Info->Header.CurrentEntry <= Info->Header.EndEntry) {
 Ghcb->SaveArea.SwScratch = (UINT64)Ghcb->SharedBuffer;
-VmgSetOffsetValid (Ghcb, GhcbSwScratch);
+CcExitVmgSetOffsetValid (Ghcb, GhcbSwScratch);
 
-Status = VmgExit (Ghcb, SVM_EXIT_SNP_PAGE_STATE_CHANGE, 0, 0);
+Status = CcExitVmgExit (Ghcb, SVM_EXIT_SNP_PAGE_STATE_CHANGE, 0, 0);
 
 //
 // The Page State Change VMGEXIT can pass the failure through the
@@ -251,7 +251,7 @@ InternalSetPageState (
 //
 // Initialize the GHCB
 //
-VmgInit (Ghcb, &InterruptState);
+CcExitVmgInit (Ghcb, &InterruptState);
 
 //
 // Build the page state structure
@@ -293,7 +293,7 @@ InternalSetPageState (
   PvalidateRange (Info, CurrentEntry, EndEntry, TRUE);
 }
 
-VmgDone (Ghcb, InterruptState);
+CcExitVmgDone (Ghcb, InterruptState);
 
 BaseAddress = NextAddress;
   }
diff --git a/OvmfPkg/Library/CcExitLib/CcExitLib.c 
b/OvmfPkg/Library/CcExitLib/CcExitLib.c
index 477064cde2bb..e256000fb283 100644
--- a/OvmfPkg/Library/CcExitLib/CcExitLib.c
+++ b/OvmfPkg/Library/CcExitLib/CcExitLib.c
@@ -103,7 +103,7 @@ VmgExitErrorCheck (
 **/
 UINT64
 EFIAPI
-VmgExit (
+CcExitVmgExit (
   IN OUT GHCB*Ghcb,
   IN UINT64  ExitCode,
   IN UINT64  ExitInfo1,
@@ -114,9 +114,9 @@ VmgExit (
   Ghcb->SaveArea.SwExitInfo1 = ExitInfo1;
   Ghcb->SaveArea.SwExitInfo2 = ExitInfo2;
 
-  VmgSetOffsetValid (Ghcb, GhcbSwExitCode);
-  VmgSetOffsetValid (Ghcb, GhcbSwExitInfo1);
-  VmgSetOffsetValid (Ghcb, GhcbSwExitInfo2);
+  CcExitVmgSetOffsetValid (Ghcb, GhcbSwExitCode);
+  CcExitVmgSetOffsetValid (Ghcb, GhcbSwExitInfo1);
+  CcExitVmgSetOffsetValid (Ghcb, GhcbSwExitInfo2);
 
   //
   // Guest memory is used for the guest-hypervisor communication, so fence
@@ -138,12 +138,12 @@ VmgExit (
 
   @param[in, out]  GhcbA pointer to the GHCB
   @param[in, out]  InterruptState  A pointer to hold the current interrupt
-   state, used for restoring in VmgDone ()
+   state, used for restoring in CcExitVmgDone 
()
 
 **/
 VOID
 EFIAPI
-VmgInit (
+CcExitVmgInit (
   IN OUT GHCB *Ghcb,
   IN OUT BOOLEAN  *InterruptState
   )
@@ -173,7 +173,7 @@ VmgInit (
 **/
 VOID
 EFIAPI
-VmgDone (
+CcExitVmgDone (
   IN OUT GHCB *Ghcb,
   IN BOOLEAN  InterruptState
   )
@@ -195,7 +195,7 @@ VmgDone (
 **/
 VOID
 EFIAPI
-VmgSetOffsetValid (
+CcExitVmgSetOffsetValid (
   IN OUT GHCB   *Ghcb,
   IN GHCB_REGISTER  Offset
   )
@@ -224,7 +224,7 @@ VmgSetOffsetValid (
 **/
 BOOLEAN
 EFIAPI
-VmgIsOffsetValid (
+CcExitVmgIsOffsetValid (
   IN GHCB   *Ghcb,
   IN GHCB_REGISTER  Offset
   )
diff --git a/OvmfPkg/Library/CcExitLib/CcExitVcHandler.c 
b/OvmfPkg/Library/CcExitLib/CcExitVcHandler.c
index ad2a922c9f43..985e5479775c 100644
--- a/OvmfPkg/Library/CcExitLib/CcExitVcHandler.c
+++ b/OvmfPkg/Library/CcExitLib/CcExitVcHandler.c
@@ -611,7 +611,7 @@ UnsupportedExit (
 {
   UINT64  Status;
 
-  Status = VmgExit (Ghcb, SVM_EXIT_UNSUPPORTED, Regs->ExceptionData, 0);
+  Status = CcExitVmgExit (Ghcb, SVM_EXIT_UNSUPPORTED, Regs->ExceptionData, 0);
   if (Status == 0) {
 GHCB_EVENT_INJECTION  Event;
 
@@ -755,8 +755,8 @@ 

[edk2-devel] [PATCH V5 3/3] Maintainers: Update the VmgExitLib to CcExitLib

2022-11-10 Thread Min Xu
From: Min M Xu 

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

VmgExitLib is renamed as CcExitLib. The related section in
Maintainers.txt should be updated as well.

Cc: Michael D Kinney 
Cc: Liming Gao 
Cc: Erdem Aktas 
Cc: Gerd Hoffmann 
Cc: James Bottomley 
Cc: Jiewen Yao 
Cc: Tom Lendacky 
Reviewed-by: Michael D Kinney 
Signed-off-by: Min Xu 
---
 Maintainers.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Maintainers.txt b/Maintainers.txt
index a2727fa7bd42..7e98083685bc 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -481,7 +481,7 @@ F: OvmfPkg/Include/Library/MemEncryptSevLib.h
 F: OvmfPkg/IoMmuDxe/AmdSevIoMmu.*
 F: OvmfPkg/Library/BaseMemEncryptSevLib/
 F: OvmfPkg/Library/PlatformBootManagerLibGrub/
-F: OvmfPkg/Library/VmgExitLib/
+F: OvmfPkg/Library/CcExitLib/
 F: OvmfPkg/PlatformPei/AmdSev.c
 F: OvmfPkg/ResetVector/
 F: OvmfPkg/Sec/
-- 
2.29.2.windows.2



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96245): https://edk2.groups.io/g/devel/message/96245
Mute This Topic: https://groups.io/mt/94954109/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




[edk2-devel] [PATCH V6 0/3] Rename VmgExitLib to CcExitLib

2022-11-10 Thread Min Xu
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4123

VmgExitLib once was designed to provide interfaces to support #VC handler
and issue VMGEXIT instruction. After TDVF (enable TDX feature in OVMF) is
introduced, this library is updated to support #VE as well. Now the name
of VmgExitLib cannot reflect what the lib does.

This patch-set renames VmgExitLib to CcExitLib (Cc means Confidential
Computing). This is simple renaming and there is no logic changes. Then
APIs defined in CcExitLib.h are added with a CcExit prefix. This is to
make the name more meaningful.

Please to be noted, changing the name of VmgExitLib to CcExitLib is a
non-backwards compatible change from a platform DSC file perspective for
downstream consumers. So for downstream platform below changes should
be applied:
1. For DSC files:
- VmgExitLib|OvmfPkg/Library/VmgExitLib/SecVmgExitLib.inf =>
  CcExitLib|OvmfPkg/Library/CcExitLib/SecCcExitLib.inf

- VmgExitLib|UefiCpuPkg/Library/VmgExitLibNull/VmgExitLibNull.inf =>
  CcExitLib|UefiCpuPkg/Library/CcExitLibNull/CcExitLibNull.inf

- VmgExitLib|OvmfPkg/Library/VmgExitLib/VmgExitLib.inf =>
  CcExitLib|OvmfPkg/Library/CcExitLib/CcExitLib.inf

2. For INF files:
- VmgExitLib => CcExitLib

3. For Header files
- #include  => #include 

4. For C files
- Replace the APIs defined in the VmgExitLib.h with the ones defined in
  CcExitLib.h. The old name is renamed by adding a prefix (CcExit).
  For example VmgInit is renamed as CcExitVmgInit.

Code: https://github.com/mxu9/edk2/tree/CcExitLib.v5

v6 changes:
 - Fix a typo in patch0@v5.
 - No other changes from v5. So the code is same as v5.

v5 changes:
 - Rebased the code base to c17c3c24d8.
 - Add instructions in patch#0 on what updates to a downstream
   platform DSC.

v4 changes:
 - The previous versions of the patch-set are to first duplicate a new
   CcExitLib then delete the old VmgExitLib. According to this comments
   https://edk2.groups.io/g/devel/message/96019 it suggests renaming in
   a single patch is better.
 - Lib APIs are added with CcExit prefix, not CcExitLib prefix.

v3 changes:
 - Rename CcExitHandleVc / CcExitHandleVe to
   CcExitLibHandleVc / CcExitLibHandleVe to make the nameing consistent.
 - Update the CcExitLib to merge the patch eff44c008d99
  (OvmfPkg/VmgExitLig: HALT on #VE when access to private memory).
 
v2 changes:
 - Patch #3 is added to import CcExitLib in OvmfPkg's *.dsc. This is to
   prevent the building from being broken in the following patches.

Cc: Eric Dong 
Cc: Ray Ni 
Cc: Brijesh Singh 
Cc: Erdem Aktas 
Cc: Gerd Hoffmann 
Cc: James Bottomley 
Cc: Jiewen Yao 
Cc: Tom Lendacky 
Cc: Guo Dong 
Cc: Sean Rhodes 
Cc: James Lu 
Cc: Gua Guo 
Cc: Michael D Kinney 
Cc: Liming Gao 
Signed-off-by: Min Xu 

Min M Xu (3):
  OvmfPkg/UefiCpuPkg/UefiPayloadPkg: Rename VmgExitLib to CcExitLib
  OvmfPkg/UefiCpuPkg: Add CcExit prefix to the APIs of CcExitLib
  Maintainers: Update the VmgExitLib to CcExitLib

 Maintainers.txt   |   2 +-
 OvmfPkg/AmdSev/AmdSevX64.dsc  |   4 +-
 OvmfPkg/Bhyve/BhyveX64.dsc|   2 +-
 OvmfPkg/CloudHv/CloudHvX64.dsc|   6 +-
 OvmfPkg/IntelTdx/IntelTdxX64.dsc  |   4 +-
 .../DxeMemEncryptSevLib.inf   |   2 +-
 .../PeiMemEncryptSevLib.inf   |   2 +-
 .../SecMemEncryptSevLib.inf   |   2 +-
 .../X64/SnpPageStateChangeInternal.c  |  10 +-
 .../VmgExitLib.c => CcExitLib/CcExitLib.c}|  23 ++--
 .../CcExitLib.inf}|  17 +--
 .../CcExitTd.h}   |   4 +-
 .../CcExitVcHandler.c}| 129 +-
 .../CcExitVcHandler.h}|   6 +-
 .../CcExitVeHandler.c}|   6 +-
 .../PeiDxeCcExitVcHandler.c}  |   6 +-
 .../SecCcExitLib.inf} |  14 +-
 .../SecCcExitVcHandler.c} |   6 +-
 .../X64/TdVmcallCpuid.nasm|   0
 OvmfPkg/Microvm/MicrovmX64.dsc|   4 +-
 OvmfPkg/OvmfPkgIa32.dsc   |   4 +-
 OvmfPkg/OvmfPkgIa32X64.dsc|   4 +-
 OvmfPkg/OvmfPkgX64.dsc|   6 +-
 OvmfPkg/OvmfXen.dsc   |   2 +-
 OvmfPkg/PlatformPei/AmdSev.c  |  10 +-
 OvmfPkg/PlatformPei/PlatformPei.inf   |   2 +-
 .../FvbServicesRuntimeDxe.inf |   2 +-
 .../QemuFlashDxe.c|  10 +-
 .../Library/{VmgExitLib.h => CcExitLib.h} |  29 ++--
 .../CcExitLibNull.c}  |  47 +--
 .../CcExitLibNull.inf}|  12 +-
 .../Library/CcExitLibNull/CcExitLibNull.uni   |  14 ++
 .../DxeCpuExceptionHandlerLib.inf |   2 +-
 .../PeiCpuExceptionHandlerLib.inf |   2 +-
 .../PeiDxeSmmCpuException.c   |   6 +-
 .../SecPeiCpuException.c  |   6 +-
 .../SecPeiCpuExce

[edk2-devel] [PATCH V6 1/3] OvmfPkg/UefiCpuPkg/UefiPayloadPkg: Rename VmgExitLib to CcExitLib

2022-11-10 Thread Min Xu
From: Min M Xu 

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

VmgExitLib once was designed to provide interfaces to support #VC handler
and issue VMGEXIT instruction. After TDVF (enable TDX feature in OVMF) is
introduced, this library is updated to support #VE as well. Now the name
of VmgExitLib cannot reflect what the lib does.

This patch renames VmgExitLib to CcExitLib (Cc means Confidential
Computing). This is a simple renaming and there is no logic changes.
After renaming all the VmgExitLib related codes are updated with
CcExitLib. These changes are in OvmfPkg/UefiCpuPkg/UefiPayloadPkg.

Cc: Guo Dong 
Cc: Sean Rhodes 
Cc: James Lu 
Cc: Gua Guo 
Cc: Eric Dong 
Cc: Ray Ni 
Cc: Brijesh Singh 
Cc: Erdem Aktas 
Cc: Gerd Hoffmann 
Cc: James Bottomley 
Cc: Jiewen Yao 
Cc: Tom Lendacky 
Reviewed-by: James Lu 
Reviewed-by: Gua Guo 
Reviewed-by: Jiewen Yao 
Reviewed-by: Ray Ni 
Signed-off-by: Min Xu 
---
 OvmfPkg/AmdSev/AmdSevX64.dsc  |  4 +-
 OvmfPkg/Bhyve/BhyveX64.dsc|  2 +-
 OvmfPkg/CloudHv/CloudHvX64.dsc|  6 +--
 OvmfPkg/IntelTdx/IntelTdxX64.dsc  |  4 +-
 .../DxeMemEncryptSevLib.inf   |  2 +-
 .../PeiMemEncryptSevLib.inf   |  2 +-
 .../SecMemEncryptSevLib.inf   |  2 +-
 .../X64/SnpPageStateChangeInternal.c  |  2 +-
 .../VmgExitLib.c => CcExitLib/CcExitLib.c}|  5 ++-
 .../CcExitLib.inf}| 17 +
 .../CcExitTd.h}   |  4 +-
 .../CcExitVcHandler.c}|  5 +--
 .../CcExitVcHandler.h}|  6 +--
 .../CcExitVeHandler.c}|  4 +-
 .../PeiDxeCcExitVcHandler.c}  |  4 +-
 .../SecCcExitLib.inf} | 14 +++
 .../SecCcExitVcHandler.c} |  4 +-
 .../X64/TdVmcallCpuid.nasm|  0
 OvmfPkg/Microvm/MicrovmX64.dsc|  4 +-
 OvmfPkg/OvmfPkgIa32.dsc   |  4 +-
 OvmfPkg/OvmfPkgIa32X64.dsc|  4 +-
 OvmfPkg/OvmfPkgX64.dsc|  6 +--
 OvmfPkg/OvmfXen.dsc   |  2 +-
 OvmfPkg/PlatformPei/AmdSev.c  |  2 +-
 OvmfPkg/PlatformPei/PlatformPei.inf   |  2 +-
 .../FvbServicesRuntimeDxe.inf |  2 +-
 .../QemuFlashDxe.c|  2 +-
 .../Library/{VmgExitLib.h => CcExitLib.h} | 13 ---
 .../CcExitLibNull.c}  | 33 +++-
 .../CcExitLibNull.inf}| 12 +++---
 .../Library/CcExitLibNull/CcExitLibNull.uni   | 14 +++
 .../DxeCpuExceptionHandlerLib.inf |  2 +-
 .../PeiCpuExceptionHandlerLib.inf |  2 +-
 .../PeiDxeSmmCpuException.c   |  2 +-
 .../SecPeiCpuException.c  |  2 +-
 .../SecPeiCpuExceptionHandlerLib.inf  |  2 +-
 .../SmmCpuExceptionHandlerLib.inf |  2 +-
 .../Xcode5SecPeiCpuExceptionHandlerLib.inf|  2 +-
 UefiCpuPkg/Library/MpInitLib/AmdSev.c |  2 +-
 UefiCpuPkg/Library/MpInitLib/DxeMpInitLib.inf |  2 +-
 UefiCpuPkg/Library/MpInitLib/DxeMpLib.c   |  2 +-
 UefiCpuPkg/Library/MpInitLib/MpLib.c  |  2 +-
 UefiCpuPkg/Library/MpInitLib/PeiMpInitLib.inf |  2 +-
 UefiCpuPkg/Library/MpInitLib/X64/AmdSev.c |  2 +-
 .../Library/VmgExitLibNull/VmTdExitNull.c | 38 ---
 .../Library/VmgExitLibNull/VmgExitLibNull.uni | 15 
 UefiCpuPkg/UefiCpuPkg.dec |  4 +-
 UefiCpuPkg/UefiCpuPkg.dsc |  4 +-
 UefiPayloadPkg/UefiPayloadPkg.dsc |  2 +-
 49 files changed, 135 insertions(+), 141 deletions(-)
 rename OvmfPkg/Library/{VmgExitLib/VmgExitLib.c => CcExitLib/CcExitLib.c} (94%)
 rename OvmfPkg/Library/{VmgExitLib/VmgExitLib.inf => CcExitLib/CcExitLib.inf} 
(66%)
 rename OvmfPkg/Library/{VmgExitLib/VmTdExitHandler.h => CcExitLib/CcExitTd.h} 
(86%)
 rename OvmfPkg/Library/{VmgExitLib/VmgExitVcHandler.c => 
CcExitLib/CcExitVcHandler.c} (95%)
 rename OvmfPkg/Library/{VmgExitLib/VmgExitVcHandler.h => 
CcExitLib/CcExitVcHandler.h} (89%)
 rename OvmfPkg/Library/{VmgExitLib/VmTdExitVeHandler.c => 
CcExitLib/CcExitVeHandler.c} (95%)
 rename OvmfPkg/Library/{VmgExitLib/PeiDxeVmgExitVcHandler.c => 
CcExitLib/PeiDxeCcExitVcHandler.c} (94%)
 rename OvmfPkg/Library/{VmgExitLib/SecVmgExitLib.inf => 
CcExitLib/SecCcExitLib.inf} (79%)
 rename OvmfPkg/Library/{VmgExitLib/SecVmgExitVcHandler.c => 
CcExitLib/SecCcExitVcHandler.c} (94%)
 rename OvmfPkg/Library/{VmgExitLib => CcExitLib}/X64/TdVmcallCpuid.nasm (100%)
 rename UefiCpuPkg/Include/Library/{VmgExitLib.h => CcExitLib.h} (89%)
 rename UefiCpuPkg/Library/{VmgExitLibNull/VmgExitLibNull.c => 
CcExitLibNull/CcExitLibNull.c} (79%)
 rename UefiCpuPkg/Library/{VmgExitLibNull/VmgExitLibNull.inf => 
CcExitLibNull/CcExitLibNull.inf} (60%)
 create mode 100644 UefiCpuPkg/Library/CcExitLibNull/CcExitLibNull.u

[edk2-devel] [PATCH V6 2/3] OvmfPkg/UefiCpuPkg: Add CcExit prefix to the APIs of CcExitLib

2022-11-10 Thread Min Xu
From: Min M Xu 

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

APIs which are defined in CcExitLib.h are added with the CcExit prefix.
This is to make the APIs' name more meaningful.

This change impacts OvmfPkg/UefiCpuPkg.

Cc: Eric Dong 
Cc: Ray Ni 
Cc: Brijesh Singh 
Cc: Erdem Aktas 
Cc: Gerd Hoffmann 
Cc: James Bottomley 
Cc: Jiewen Yao 
Cc: Tom Lendacky 
Reviewed-by: Jiewen Yao 
Reviewed-by: Ray Ni 
Signed-off-by: Min Xu 
---
 .../X64/SnpPageStateChangeInternal.c  |   8 +-
 OvmfPkg/Library/CcExitLib/CcExitLib.c |  18 +--
 OvmfPkg/Library/CcExitLib/CcExitVcHandler.c   | 124 +-
 OvmfPkg/Library/CcExitLib/CcExitVeHandler.c   |   2 +-
 .../Library/CcExitLib/PeiDxeCcExitVcHandler.c |   2 +-
 .../Library/CcExitLib/SecCcExitVcHandler.c|   2 +-
 OvmfPkg/PlatformPei/AmdSev.c  |   8 +-
 .../QemuFlashDxe.c|   8 +-
 UefiCpuPkg/Include/Library/CcExitLib.h|  16 +--
 .../Library/CcExitLibNull/CcExitLibNull.c |  16 +--
 .../PeiDxeSmmCpuException.c   |   4 +-
 .../SecPeiCpuException.c  |   4 +-
 UefiCpuPkg/Library/MpInitLib/AmdSev.c |   8 +-
 UefiCpuPkg/Library/MpInitLib/DxeMpLib.c   |   6 +-
 UefiCpuPkg/Library/MpInitLib/X64/AmdSev.c |   8 +-
 15 files changed, 117 insertions(+), 117 deletions(-)

diff --git 
a/OvmfPkg/Library/BaseMemEncryptSevLib/X64/SnpPageStateChangeInternal.c 
b/OvmfPkg/Library/BaseMemEncryptSevLib/X64/SnpPageStateChangeInternal.c
index 73698a7b9d8c..4d684964d838 100644
--- a/OvmfPkg/Library/BaseMemEncryptSevLib/X64/SnpPageStateChangeInternal.c
+++ b/OvmfPkg/Library/BaseMemEncryptSevLib/X64/SnpPageStateChangeInternal.c
@@ -193,9 +193,9 @@ PageStateChangeVmgExit (
   //
   while (Info->Header.CurrentEntry <= Info->Header.EndEntry) {
 Ghcb->SaveArea.SwScratch = (UINT64)Ghcb->SharedBuffer;
-VmgSetOffsetValid (Ghcb, GhcbSwScratch);
+CcExitVmgSetOffsetValid (Ghcb, GhcbSwScratch);
 
-Status = VmgExit (Ghcb, SVM_EXIT_SNP_PAGE_STATE_CHANGE, 0, 0);
+Status = CcExitVmgExit (Ghcb, SVM_EXIT_SNP_PAGE_STATE_CHANGE, 0, 0);
 
 //
 // The Page State Change VMGEXIT can pass the failure through the
@@ -251,7 +251,7 @@ InternalSetPageState (
 //
 // Initialize the GHCB
 //
-VmgInit (Ghcb, &InterruptState);
+CcExitVmgInit (Ghcb, &InterruptState);
 
 //
 // Build the page state structure
@@ -293,7 +293,7 @@ InternalSetPageState (
   PvalidateRange (Info, CurrentEntry, EndEntry, TRUE);
 }
 
-VmgDone (Ghcb, InterruptState);
+CcExitVmgDone (Ghcb, InterruptState);
 
 BaseAddress = NextAddress;
   }
diff --git a/OvmfPkg/Library/CcExitLib/CcExitLib.c 
b/OvmfPkg/Library/CcExitLib/CcExitLib.c
index 477064cde2bb..e256000fb283 100644
--- a/OvmfPkg/Library/CcExitLib/CcExitLib.c
+++ b/OvmfPkg/Library/CcExitLib/CcExitLib.c
@@ -103,7 +103,7 @@ VmgExitErrorCheck (
 **/
 UINT64
 EFIAPI
-VmgExit (
+CcExitVmgExit (
   IN OUT GHCB*Ghcb,
   IN UINT64  ExitCode,
   IN UINT64  ExitInfo1,
@@ -114,9 +114,9 @@ VmgExit (
   Ghcb->SaveArea.SwExitInfo1 = ExitInfo1;
   Ghcb->SaveArea.SwExitInfo2 = ExitInfo2;
 
-  VmgSetOffsetValid (Ghcb, GhcbSwExitCode);
-  VmgSetOffsetValid (Ghcb, GhcbSwExitInfo1);
-  VmgSetOffsetValid (Ghcb, GhcbSwExitInfo2);
+  CcExitVmgSetOffsetValid (Ghcb, GhcbSwExitCode);
+  CcExitVmgSetOffsetValid (Ghcb, GhcbSwExitInfo1);
+  CcExitVmgSetOffsetValid (Ghcb, GhcbSwExitInfo2);
 
   //
   // Guest memory is used for the guest-hypervisor communication, so fence
@@ -138,12 +138,12 @@ VmgExit (
 
   @param[in, out]  GhcbA pointer to the GHCB
   @param[in, out]  InterruptState  A pointer to hold the current interrupt
-   state, used for restoring in VmgDone ()
+   state, used for restoring in CcExitVmgDone 
()
 
 **/
 VOID
 EFIAPI
-VmgInit (
+CcExitVmgInit (
   IN OUT GHCB *Ghcb,
   IN OUT BOOLEAN  *InterruptState
   )
@@ -173,7 +173,7 @@ VmgInit (
 **/
 VOID
 EFIAPI
-VmgDone (
+CcExitVmgDone (
   IN OUT GHCB *Ghcb,
   IN BOOLEAN  InterruptState
   )
@@ -195,7 +195,7 @@ VmgDone (
 **/
 VOID
 EFIAPI
-VmgSetOffsetValid (
+CcExitVmgSetOffsetValid (
   IN OUT GHCB   *Ghcb,
   IN GHCB_REGISTER  Offset
   )
@@ -224,7 +224,7 @@ VmgSetOffsetValid (
 **/
 BOOLEAN
 EFIAPI
-VmgIsOffsetValid (
+CcExitVmgIsOffsetValid (
   IN GHCB   *Ghcb,
   IN GHCB_REGISTER  Offset
   )
diff --git a/OvmfPkg/Library/CcExitLib/CcExitVcHandler.c 
b/OvmfPkg/Library/CcExitLib/CcExitVcHandler.c
index ad2a922c9f43..985e5479775c 100644
--- a/OvmfPkg/Library/CcExitLib/CcExitVcHandler.c
+++ b/OvmfPkg/Library/CcExitLib/CcExitVcHandler.c
@@ -611,7 +611,7 @@ UnsupportedExit (
 {
   UINT64  Status;
 
-  Status = VmgExit (Ghcb, SVM_EXIT_UNSUPPORTED, Regs->ExceptionData, 0);
+  Status = CcExitVmgExit (Ghcb, SVM_EXIT_UNSUPPORTED, Regs->ExceptionData, 0);
   if (Status == 0) {
 GHCB_EVENT_INJECTION  Event;
 
@@ -755,8 +755,8 @@ 

[edk2-devel] [PATCH V6 3/3] Maintainers: Update the VmgExitLib to CcExitLib

2022-11-10 Thread Min Xu
From: Min M Xu 

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

VmgExitLib is renamed as CcExitLib. The related section in
Maintainers.txt should be updated as well.

Cc: Michael D Kinney 
Cc: Liming Gao 
Cc: Erdem Aktas 
Cc: Gerd Hoffmann 
Cc: James Bottomley 
Cc: Jiewen Yao 
Cc: Tom Lendacky 
Reviewed-by: Michael D Kinney 
Signed-off-by: Min Xu 
---
 Maintainers.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Maintainers.txt b/Maintainers.txt
index a2727fa7bd42..7e98083685bc 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -481,7 +481,7 @@ F: OvmfPkg/Include/Library/MemEncryptSevLib.h
 F: OvmfPkg/IoMmuDxe/AmdSevIoMmu.*
 F: OvmfPkg/Library/BaseMemEncryptSevLib/
 F: OvmfPkg/Library/PlatformBootManagerLibGrub/
-F: OvmfPkg/Library/VmgExitLib/
+F: OvmfPkg/Library/CcExitLib/
 F: OvmfPkg/PlatformPei/AmdSev.c
 F: OvmfPkg/ResetVector/
 F: OvmfPkg/Sec/
-- 
2.29.2.windows.2



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96249): https://edk2.groups.io/g/devel/message/96249
Mute This Topic: https://groups.io/mt/94954288/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] 回复: [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL without virtio-rng

2022-11-10 Thread Ard Biesheuvel
On Fri, 11 Nov 2022 at 04:53, gaoliming via groups.io
 wrote:
>
> It has been merged at c8fb7240469b5753773da4fa5710b870b790c363
>
> Thanks
> Liming

Thank you.

I'll merge the remaining ones after the stable tag has been created.


> > -邮件原件-
> > 发件人: devel@edk2.groups.io  代表 gaoliming via
> > groups.io
> > 发送时间: 2022年11月11日 8:42
> > 收件人: 'Ard Biesheuvel' ; devel@edk2.groups.io
> > 抄送: 'Rebecca Cran' ; 'Pierre Gondois'
> > ; 'Leif Lindholm' ;
> > 'Sami Mujawar' ; 'Gerd Hoffmann'
> > ; 'Jason A . Donenfeld' 
> > 主题: [edk2-devel] 回复: [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL
> > without virtio-rng
> >
> > Ard:
> >   The first patch is the bug fix. I agree to merge it for this stable tag.
> I
> > will help merge it today.
> >
> > Thanks
> > Liming
> > > -邮件原件-
> > > 发件人: Ard Biesheuvel 
> > > 发送时间: 2022年11月10日 21:48
> > > 收件人: devel@edk2.groups.io
> > > 抄送: Ard Biesheuvel ; Liming Gao
> > > ; Rebecca Cran ; Pierre
> > > Gondois ; Leif Lindholm
> > > ; Sami Mujawar ;
> > > Gerd Hoffmann ; Jason A . Donenfeld
> > > 
> > > 主题: [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL without virtio-rng
> > >
> > > Currently, we only expose EFI_RNG_PROTOCOL when running under QEMU
> > if
> > > it
> > >
> > > exposes a virtio-rng device. This means that generic EFI apps or
> > >
> > > loaders have no access to an entropy source if this device is
> > >
> > > unavailable, unless they implement their own arch-specific handling to
> > >
> > > figure out whether any CPU instructions or monitor calls can be used
> > >
> > > instead.
> > >
> > >
> > >
> > > So let's wire those up as EFI_RNG_PROTOCOL implementations as well,
> > >
> > > using the existing drivers and libraries.
> > >
> > >
> > >
> > > First patch is a bugfix - Liming, mind if I merge that right away?
> > >
> > > Thanks.
> > >
> > >
> > >
> > > Cc: Liming Gao 
> > >
> > > Cc: Rebecca Cran 
> > >
> > > Cc: Pierre Gondois 
> > >
> > > Cc: Leif Lindholm 
> > >
> > > Cc: Sami Mujawar 
> > >
> > > Cc: Gerd Hoffmann 
> > >
> > > Cc: Jason A. Donenfeld 
> > >
> > >
> > >
> > > Ard Biesheuvel (3):
> > >
> > >   ArmPkg/ArmTrngLib: Fix incorrect GUID reference in DEBUG() output
> > >
> > >   ArmVirtPkg/ArmVirtQemu: Expose TRNG hypercall via RngDxe if
> > >
> > > implemented
> > >
> > >   OvmfPkg/OvmfX86: Enable RDRAND based EFI_RNG_PROTOCOL
> > > implementation
> > >
> > >
> > >
> > >  ArmPkg/Library/ArmTrngLib/ArmTrngLib.c |  2 +-
> > >
> > >  ArmVirtPkg/ArmVirtQemu.dsc | 11 +++
> > >
> > >  ArmVirtPkg/ArmVirtQemuFvMain.fdf.inc   |  5 +
> > >
> > >  ArmVirtPkg/ArmVirtQemuKernel.dsc   | 11 +++
> > >
> > >  OvmfPkg/OvmfPkgIa32.dsc|  1 +
> > >
> > >  OvmfPkg/OvmfPkgIa32.fdf|  1 +
> > >
> > >  OvmfPkg/OvmfPkgIa32X64.dsc |  1 +
> > >
> > >  OvmfPkg/OvmfPkgIa32X64.fdf |  1 +
> > >
> > >  OvmfPkg/OvmfPkgX64.dsc |  1 +
> > >
> > >  OvmfPkg/OvmfPkgX64.fdf |  1 +
> > >
> > >  10 files changed, 34 insertions(+), 1 deletion(-)
> > >
> > >
> > >
> > > --
> > >
> > > 2.35.1
> > >
> > >
> >
> >
> >
> >
> >
> >
> >
>
>
>
>
>
> 
>
>


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96250): https://edk2.groups.io/g/devel/message/96250
Mute This Topic: https://groups.io/mt/94954423/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [PATCH 0/3] OVMF: support EFI_RNG_PROTOCOL without virtio-rng

2022-11-10 Thread Ard Biesheuvel
On Fri, 11 Nov 2022 at 03:41, Jason A. Donenfeld  wrote:
>
> Hi Ard,
>
> On Thu, Nov 10, 2022 at 2:48 PM Ard Biesheuvel  wrote:
> >
> > Currently, we only expose EFI_RNG_PROTOCOL when running under QEMU if it
> > exposes a virtio-rng device. This means that generic EFI apps or
> > loaders have no access to an entropy source if this device is
> > unavailable, unless they implement their own arch-specific handling to
> > figure out whether any CPU instructions or monitor calls can be used
> > instead.
> >
> > So let's wire those up as EFI_RNG_PROTOCOL implementations as well,
> > using the existing drivers and libraries.
>
> I tested this series on x86 and it appears to work as expected. Thanks
> for putting this together. So,
>
> Tested-by: Jason A. Donenfeld 
>
> On very brief inspection, this also looks good, though I'm not really
> an EDK2 expert and my review isn't very thorough. But in case it
> helps, which you can take or leave,
>
> Reviewed-by: Jason A. Donenfeld 
>

Thanks.

> My only question is how it chooses which RNG source to use in the
> event that multiple are available. I would think preferring virtio-rng
> if available is the right thing there. If it's based on the order of
> the items in the .dsc file, then it looks like this series is doing
> the right thing.
>

No, it is essentially arbitrary (but not random :-))

We already have special handling for the virtio RNG device in the BDS
code, because normally, EFI only dispatches drivers for devices that
it needs to boot (i..e, it walks the device path of the boot entry and
only connects a device to its driver at each stage if it needs to do
so to get to the next one)

So connecting the virtio-rng device to its driver needs to be done
explicitly, or it may not be connected at all. We handle this in
ConnectVirtioPciRng() for x86 and some similar code exists in
ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c

On ARM, the RngDxe wired up by this patch is backed by a hypervisor or
secure world firmware service, rather than by the VMM, so in the ARM
case, I think this one is the preferred one given that the VMM is
generally less trusted (although that distinction really only matters
for confidential compute).

On x86, we use the RdRand instruction, which is also independent from
the VMM, so I'd assume this is the preferred choice, no? Or do you
have concerns about broken implementations?

Another distinction is that the ARM version only implements
EFI_RNG_ALGORITHM_RAW, whereas x86 also implements
EFI_RNG_ALGORITHM_SP800_90_CTR_256_GUID. (virtio-rng also only
implements EFI_RNG_ALGORITHM_RAW). This likely does not matter at all,
but it is nevertheless good to call out while we decide which driver
to give precedence.

Another thing to note is that we generally try very hard to do as
little as possible at boot time (although you might get a different
impression when looking at the code :-)). So simply skipping the
virtio-rng driver dispatch if some implementation of EFI_RNG_PROTOCOL
is already available seems appropriate from that angle as well.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96251): https://edk2.groups.io/g/devel/message/96251
Mute This Topic: https://groups.io/mt/94935839/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-




Re: [edk2-devel] [Patch edk2-platforms] IntelSiliconPkg/IntelVTdDxe: Fix CLANG detected incorrect return

2022-11-10 Thread Ashraf Ali S
Reviewed-by: S, Ashraf Ali 


Regards,
Ashraf Ali S
Intel Technology India Pvt. Ltd. 

-Original Message-
From: Kinney, Michael D  
Sent: Thursday, November 10, 2022 11:54 PM
To: devel@edk2.groups.io
Cc: Ni, Ray ; Chaganty, Rangasai V 
; Oram, Isaac W ; S, 
Ashraf Ali 
Subject: [Patch edk2-platforms] IntelSiliconPkg/IntelVTdDxe: Fix CLANG detected 
incorrect return

CreateSecondLevelPagingEntryTable() has a return type of 
VTD_SECOND_LEVEL_PAGING_ENTRY * and an error condition returns a value of NULL.

Change return value of EFI_SUCCESS (value 0) to NULL to address CLANG compiler 
detection of incorrect return type.

Cc: Ray Ni 
Cc: Rangasai V Chaganty 
Cc: Isaac Oram 
Cc: Ashraf Ali S 
Signed-off-by: Michael D Kinney 
---
 .../IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c 
b/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c
index 3220789080..6788c86531 100644
--- a/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationTable.c
+++ b/Silicon/Intel/IntelSiliconPkg/Feature/VTd/IntelVTdDxe/TranslationT
+++ able.c
@@ -196,7 +196,7 @@ CreateSecondLevelPagingEntryTable (
   UINT64 EndAddress;
 
   if (MemoryLimit == 0) {
-return EFI_SUCCESS;
+return NULL;
   }
 
   Lvl4PagesStart = 0;
--
2.37.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#96252): https://edk2.groups.io/g/devel/message/96252
Mute This Topic: https://groups.io/mt/94942403/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-