[edk2] Sourceforge svn mirror of edk2

2017-02-08 Thread Shifflett, Joseph
I apologize if this is not the best list. There hasn't been a commit that was cherrypicked from the git repo into the sourceforge svn repo since 2/3. This was an automated process for the last year or two. Was it intentionally discontinued? Thanks, Joe Shifflett

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Duran, Leo
Lazlo, et al, Please reply below. Leo. > -Original Message- > From: Laszlo Ersek [mailto:ler...@redhat.com] > Sent: Wednesday, February 08, 2017 2:39 AM > To: Duran, Leo ; edk2-de...@ml01.01.org > Cc: Feng Tian ; Singh, Brijesh >

[edk2] [PATCH 02/12] MdePkg/SmiHandlerProfileLibNull: Add NULL instance.

2017-02-08 Thread Jiewen Yao
Cc: Michael D Kinney Cc: Liming Gao Cc: Laszlo Ersek Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jiewen Yao ---

[edk2] [PATCH 01/12] MdePkg/Include: Add SmiHandlerProfileLib.h

2017-02-08 Thread Jiewen Yao
This library should be linked by SmmChildDispatch to report the hardware SMI handler maintained by SmmChildDispatch. Cc: Michael D Kinney Cc: Liming Gao Cc: Laszlo Ersek Contributed-under: TianoCore Contribution Agreement 1.0

[edk2] [PATCH 04/12] MdeModulePkg/include: Add SmiHandlerProfile header file.

2017-02-08 Thread Jiewen Yao
This header file defines: 1) An SMI handler profile protocol. So that SmmChildDispatch module can register the hardware SMI handler information. 2) The SMI handler profile communication buffer. So that a shell application can use SMM communication to get the SMI handler profile info. Cc: Feng

[edk2] [PATCH 03/12] MdePkg/dsc: add SmiHandlerProfileLib to dsc.

2017-02-08 Thread Jiewen Yao
Cc: Michael D Kinney Cc: Liming Gao Cc: Laszlo Ersek Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jiewen Yao --- MdePkg/MdePkg.dsc | 3 ++- 1 file changed, 2 insertions(+), 1

[edk2] [PATCH 05/12] MdeModulePkg/dec: Add PcdSmiHandlerProfilePropertyMask.

2017-02-08 Thread Jiewen Yao
This PCD is linked by PiSmmCore to control if it enables SMI handler profile feature. Cc: Feng Tian Cc: Star Zeng Cc: Michael D Kinney Cc: Laszlo Ersek Contributed-under: TianoCore Contribution Agreement

[edk2] [PATCH 06/12] MdeModulePkg/SmmSmiHandlerProfileLib: Add SMM instance.

2017-02-08 Thread Jiewen Yao
This instance should be linked by SmmChildDispatcher if SMI handler profile feature is enabled. Cc: Feng Tian Cc: Star Zeng Cc: Michael D Kinney Cc: Laszlo Ersek Contributed-under: TianoCore Contribution

[edk2] [PATCH 07/12] MdeModulePkg/PiSmmCore: Add SmiHandlerProfile support.

2017-02-08 Thread Jiewen Yao
1) SmmCore maintains the root SMI handler and NULL SMI handler database. 2) SmmCore consumes PcdSmiHandlerProfilePropertyMask to decide if SmmCore need support SMI handler profile. If SMI handler profile is supported, the SmmCore installs SMI handler profile protocol and SMI handler profile

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Gao, Liming
Leo: MdeModulePkg CapsulePei and UefiCpuPkg S3Resume2 also create PageTable to run X64 code. Do they require this change? Thanks Liming -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Leo Duran Sent: Wednesday, February 8, 2017 3:54 AM To:

[edk2] [PATCH 08/12] MdeModulePkg/App: Add SmiHandlerProfile dump app.

2017-02-08 Thread Jiewen Yao
This app uses SMM communication to get SMI handler profile from SMM core. Cc: Feng Tian Cc: Star Zeng Cc: Michael D Kinney Cc: Laszlo Ersek Contributed-under: TianoCore Contribution Agreement 1.0

[edk2] [PATCH 00/12] Add SmiHandlerProfile feature

2017-02-08 Thread Jiewen Yao
This series patch add SMI handler profile. The purpose of SMI handler profile is to add the capability to dump all SMI handlers produced by the firmware in a given boot. The SMI handlers here include 1) Root SMI handlers registered with SMST->SmiHandlerRegister by SmmCore. 2) GUID SMI handlers

[edk2] [PATCH 11/12] QuarkSocPkg/SmmChildDispatch: Add SmiHandlerProfile support.

2017-02-08 Thread Jiewen Yao
Cc: Michael D Kinney Cc: Kelly Steele Cc: Laszlo Ersek Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jiewen Yao ---

Re: [edk2] Sourceforge svn mirror of edk2

2017-02-08 Thread Laszlo Ersek
On 02/08/17 16:00, Shifflett, Joseph wrote: > I apologize if this is not the best list. It is the correct list, yes. > > There hasn't been a commit that was cherrypicked from the git repo > into the sourceforge svn repo since 2/3. > > This was an automated process for the last year or two.

[edk2] [PATCH 10/12] BaseTool/Script: Add SmiHandleProfile OS tool to get symbol.

2017-02-08 Thread Jiewen Yao
This tool accepts the input XML file generated by SmiHandlerProfile application and convert the RVA address to be a user readable symbol. It also converts the GUID to be a user readable string. Cc: Yonghong Zhu Cc: Liming Gao Cc: Michael D Kinney

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Duran, Leo
Lazlo, et al, Please see reply below. Lleo > -Original Message- > From: Laszlo Ersek [mailto:ler...@redhat.com] > Sent: Wednesday, February 08, 2017 11:11 AM > To: Yao, Jiewen ; Duran, Leo > ; Zeng, Star ; edk2- >

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Yao, Jiewen
Comments below: From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Duran, Leo Sent: Wednesday, February 8, 2017 10:31 AM To: Yao, Jiewen ; Gao, Liming ; edk2-de...@ml01.01.org Cc: Laszlo Ersek ; Tian, Feng

Re: [edk2] [PATCH 00/12] Add SmiHandlerProfile feature

2017-02-08 Thread Laszlo Ersek
CC Jordan On 02/08/17 17:30, Jiewen Yao wrote: > This series patch add SMI handler profile. > > The purpose of SMI handler profile is to add the capability to > dump all SMI handlers produced by the firmware in a given boot. > The SMI handlers here include > 1) Root SMI handlers registered with

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Yao, Jiewen
Got it. If the means of PcdDxeIplSwitchtoLongMode is unclear, we may add more description to make it clear. If we believe "PcdDxeIplSwitchtoLongMode == DXE is Long mode" as final conclusion, can we treat that as a bug and fix OVMF X64? Thank you Yao Jiewen From: Laszlo Ersek

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Laszlo Ersek
On 02/08/17 18:28, Duran, Leo wrote: > Lazlo, et al, > Please see reply below. > Lleo > >> -Original Message- >> From: Laszlo Ersek [mailto:ler...@redhat.com] >> Sent: Wednesday, February 08, 2017 11:11 AM >> To: Yao, Jiewen ; Duran, Leo >> ; Zeng,

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Duran, Leo
Please see replies below. Thanks, Leo > -Original Message- > From: Gao, Liming [mailto:liming@intel.com] > Sent: Wednesday, February 08, 2017 9:19 AM > To: Duran, Leo ; edk2-de...@ml01.01.org > Cc: Laszlo Ersek ; Tian, Feng ;

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Duran, Leo
Please see below. Leo. From: Yao, Jiewen [mailto:jiewen@intel.com] Sent: Wednesday, February 08, 2017 11:05 AM To: Duran, Leo ; Zeng, Star ; edk2-de...@ml01.01.org Cc: Laszlo Ersek ; Tian, Feng ; Singh, Brijesh

Re: [edk2] [PATCH 00/12] Add SmiHandlerProfile feature

2017-02-08 Thread Yao, Jiewen
Hi Laszlo Thanks for the comment. To clarify something: 1) I did not enable SMI handler profile for OVMF because I notice the OVMF just use very few SMI handlers, and it does not have SmmChildDispatcher. Just like what you mentioned. 2) I forget to mention: I did regression test

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Yao, Jiewen
I think X64 DXEIPL *may* create page table for X64 DXE. It is controlled by PcdDxeIplBuildPageTables. if (FeaturePcdGet (PcdDxeIplBuildPageTables)) { // // Create page table and save PageMapLevel4 to CR3 // PageTables = CreateIdentityMappingPageTables ((EFI_PHYSICAL_ADDRESS)

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Yao, Jiewen
HI Leo Thanks to clarify that. If that is the case, do you think it will be better to limit this PCD to X64 only in DEC file. Such as [PcdsDynamic.X64, PcdsDynamicEx.X64] Thank you Yao Jiewen From: Duran, Leo [mailto:leo.du...@amd.com] Sent: Wednesday, February 8, 2017 9:00 AM To: Zeng, Star

Re: [edk2] Sourceforge svn mirror of edk2

2017-02-08 Thread Laszlo Ersek
On 02/08/17 17:56, Carsey, Jaben wrote: > Laszlo - Nice article. Maybe you posted the link before, but if so I had > missed it. Thank you! > On a SVN-related note, I noticed that SVN via github also seems to be > out of date. Basically the message is: use git. That's right. Cheers, Laszlo

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Yao, Jiewen
I believe PcdDxeIplSwitchtoLongMode == DXE is Long mode. See DEC description: # It is assumed that 64-bit DxeCore is built in firmware if it is true; otherwise 32-bit DxeCore # is built in firmware. And the code MdeModulePkg\Universal\Acpi\S3SaveStateDxe\AcpiS3ContextSave.c: BOOLEAN

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Laszlo Ersek
On 02/08/17 18:27, Yao, Jiewen wrote: > I believe PcdDxeIplSwitchtoLongMode == DXE is Long mode. > > > > See DEC description: > > # It is assumed that 64-bit DxeCore is built in firmware if it is > true; otherwise 32-bit DxeCore > > # is built in firmware. Unfortunately, I have no

Re: [edk2] [PATCH 00/12] Add SmiHandlerProfile feature

2017-02-08 Thread Laszlo Ersek
On 02/08/17 18:57, Yao, Jiewen wrote: > Hi Laszlo > > Thanks for the comment. > > > > To clarify something: > > > > 1) I did not enable SMI handler profile for OVMF because I notice > the OVMF just use very few SMI handlers, and it does not have > SmmChildDispatcher. Just like what

Re: [edk2] Sourceforge svn mirror of edk2

2017-02-08 Thread Carsey, Jaben
Laszlo - Nice article. Maybe you posted the link before, but if so I had missed it. On a SVN-related note, I noticed that SVN via github also seems to be out of date. Basically the message is: use git. > -Original Message- > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org]

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Duran, Leo
Agreed. Leo From: Yao, Jiewen [mailto:jiewen@intel.com] Sent: Wednesday, February 08, 2017 11:18 AM To: Laszlo Ersek ; Duran, Leo ; Zeng, Star ; edk2-de...@ml01.01.org Cc: Tian, Feng ; Singh, Brijesh

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Duran, Leo
[Jiewen] The IA32 capsule code creates X64 page tables, then switch to X64. So the page table is for X64. Would you please double check if this PCD is needed? Regarding: MedModelePkg/Universal/CapsulePei/UefiCapsule.c Create4GPageTables() explicitly sets PhysicalAddressBits = 32; So it seems

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Laszlo Ersek
On 02/08/17 19:13, Yao, Jiewen wrote: > I think X64 DXEIPL **may** create page table for X64 DXE. It is > controlled by PcdDxeIplBuildPageTables. > > > > if(FeaturePcdGet (PcdDxeIplBuildPageTables)) { > > // > > // Create page table and save PageMapLevel4 to CR3 > > // > >

Re: [edk2] [PATCH 00/12] Add SmiHandlerProfile feature

2017-02-08 Thread Yao, Jiewen
Sounds great. I appreciate your help. :) Thank you Yao Jiewen From: Laszlo Ersek [mailto:ler...@redhat.com] Sent: Wednesday, February 8, 2017 10:28 AM To: Yao, Jiewen ; edk2-de...@ml01.01.org Cc: Kinney, Michael D ; Justen, Jordan L

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Laszlo Ersek
On 02/08/17 19:20, Yao, Jiewen wrote: > Got it. > > > > If the means of PcdDxeIplSwitchtoLongMode is unclear, we may add more > description to make it clear. > > > > If we believe “PcdDxeIplSwitchtoLongMode == DXE is Long mode” as final > conclusion, can we treat that as a bug and fix

[edk2] [PATCH 2/3] MdeModulePkg/Universal/CapsulePei: Add support for PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Leo Duran
This PCD holds the address mask for page table entries when memory encryption is enabled on AMD processors supporting the Secure Encrypted Virtualization (SEV) feature. The mask is applied when 4GB tables are created (UefiCapsule.c), and when the tables are expanded on-demand by page-faults above

[edk2] [PATCH 3/3] UefiCpuPkg/Universal/Acpi/S3Resume2Pei: Add support for PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Leo Duran
This PCD holds the address mask for page table entries when memory encryption is enabled on AMD processors supporting the Secure Encrypted Virtualization (SEV) feature. The mask is applied when page tables are created (S3Resume.c). CC: Jeff Fan Cc: Feng Tian

[edk2] [PATCH 0/3] Add PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Leo Duran
This new PCD holds the address mask for page table entries when memory encryption is enabled on AMD processors supporting the Secure Encrypted Virtualization (SEV) feature. This mask is be applied when creating 1:1 virtual to physical mapping tables. For example, the OvmfPkg sets the PCD when

[edk2] [PATCH 1/3] MdeModulePkg: Add PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Leo Duran
From: Brijesh Singh This PCD holds the address mask for page table entries when memory encryption is enabled on AMD processors supporting the Secure Encrypted Virtualization (SEV) feature. Cc: Feng Tian Cc: Star Zeng Cc: Laszlo

[edk2] Print from DXE_DRIVER

2017-02-08 Thread David A. Van Arnem
Hello, I am working on a DXE_DRIVER for a custom device. I like to use Print() statements to trace code execution during development. Thus I have put a print statement in each of my Supported(), Start(), and Stop() functions for the driver binding protocol. Currently I am building the driver

Re: [edk2] Print from DXE_DRIVER

2017-02-08 Thread Laszlo Ersek
On 02/08/17 23:10, David A. Van Arnem wrote: > Hello, > > I am working on a DXE_DRIVER for a custom device. I like to use Print() > statements to trace code execution during development. Thus I have put > a print statement in each of my Supported(), Start(), and Stop() > functions for the

Re: [edk2] [PATCH V2 1/6] CryptoPkg:SmmCryptLib: Add real Pkcs5Pbkdf2.c.

2017-02-08 Thread Long, Qin
Reviewed-by: Qin Long Best Regards & Thanks, LONG, Qin > -Original Message- > From: Yao, Jiewen > Sent: Tuesday, February 7, 2017 12:24 AM > To: edk2-devel@lists.01.org > Cc: Long, Qin > Subject: [PATCH V2 1/6] CryptoPkg:SmmCryptLib: Add real

Re: [edk2] Print from DXE_DRIVER

2017-02-08 Thread Andrew Fish
> On Feb 8, 2017, at 4:41 PM, David A. Van Arnem wrote: > > > > On 02/08/2017 05:15 PM, Laszlo Ersek wrote: >> On 02/08/17 23:10, David A. Van Arnem wrote: >>> Hello, >>> >>> I am working on a DXE_DRIVER for a custom device. I like to use Print() >>> statements to trace

Re: [edk2] [PATCH V2 0/6] Add password support

2017-02-08 Thread Zhang, Chao B
Serial reviewed-by : Chao Zhang -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Jiewen Yao Sent: Tuesday, February 7, 2017 4:24 PM To: edk2-devel@lists.01.org Subject: [edk2] [PATCH V2 0/6] Add password support V2

Re: [edk2] [PATCH V2 6/6] SecurityPkg/dsc: add Password authentication module.

2017-02-08 Thread Long, Qin
Reviewed-by: Qin Long Best Regards & Thanks, LONG, Qin > -Original Message- > From: Yao, Jiewen > Sent: Tuesday, February 7, 2017 12:24 AM > To: edk2-devel@lists.01.org > Cc: Long, Qin ; Zhang, Chao B > > Subject: [PATCH

[edk2] [PATCH v2] OvmfPkg/QemuBootOrderLib: Fix NOOPT build failure

2017-02-08 Thread Dandan Bi
This patch is to fix the IA32/NOOPT/VS Toolchain build failure. Cc: Jordan Justen Cc: Laszlo Ersek Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dandan Bi Notes:

[edk2] [PATCH v4 6/6] MdePkg/Pci22.h: Deprecate out-of-Spec IncompatiblePciDevice macros

2017-02-08 Thread Ruiyu Ni
DEVICE_ID_NOCARE is defined as 0x but Spec says (UINT64) -1 should be used to match any VendorId/DeviceId/RevisionId/ SubsystemVendorId/SubsystemDeviceId. PCI_BAR_OLD_ALIGN/PCI_BAR_EVEN_ALIGN/PCI_BAR_SQUAD_ALIGN/ PCI_BAR_DQUAD_ALIGN are defined but Spec doesn't have such definitions.

Re: [edk2] Print from DXE_DRIVER

2017-02-08 Thread Tim Lewis
Also, on many systems, the output will be invisible, since boot screen output is a platform policy. In general, using DEBUG() is better, since it can either be redirected to StdErr() or through the serial port. Tim -Original Message- From: edk2-devel

Re: [edk2] Sourceforge svn mirror of edk2

2017-02-08 Thread Gao, Liming
Recently, our auto sync machine meets with some issue. We are working on it to let it work back asap. Long term goal is to stop svn, and everyone uses edk2 git. Thanks Liming -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Laszlo Ersek Sent:

Re: [edk2] Print from DXE_DRIVER

2017-02-08 Thread Rebecca Cran
> On Feb 8, 2017, at 5:43 PM, Andrew Fish wrote: > > If you want to write directly to the UEFI Console you can try this. Place it > in the entry point of your driver in case you have some bug that is > preventing your from registering the Driver Binding Protocol. > >

[edk2] [PATCH v2 0/3] PrintLib: Refine the SPrint functions

2017-02-08 Thread Hao Wu
V2 changes: Update the description of the following services of EFI_PRINT2_PROTOCOL: UNICODE_BS_PRINT UNICODE_S_PRINT UNICODE_BS_PRINT_ASCII_FORMAT UNICODE_S_PRINT_ASCII_FORMAT ASCII_BS_PRINT ASCII_S_PRINT ASCII_BS_PRINT_UNICODE_FORMAT ASCII_S_PRINT_UNICODE_FORMAT Keep them the same as the

[edk2] [PATCH v2 1/3] MdePkg/BasePrintLib: Refine the SPrint functions

2017-02-08 Thread Hao Wu
For the following 12 APIs in MdePkg/BasePrintLib: UnicodeVSPrint UnicodeBSPrint UnicodeSPrint UnicodeVSPrintAsciiFormat UnicodeBSPrintAsciiFormat UnicodeSPrintAsciiFormat AsciiVSPrint AsciiBSPrint AsciiSPrint AsciiVSPrintUnicodeFormat AsciiBSPrintUnicodeFormat AsciiSPrintUnicodeFormat They will

[edk2] [PATCH v2 3/3] MdeModulePkg: Refine the services comments in EFI_PRINT2_PROTOCOL

2017-02-08 Thread Hao Wu
For the following 8 services in EFI_PRINT2_PROTOCOL: UNICODE_BS_PRINT UNICODE_S_PRINT UNICODE_BS_PRINT_ASCII_FORMAT UNICODE_S_PRINT_ASCII_FORMAT ASCII_BS_PRINT ASCII_S_PRINT ASCII_BS_PRINT_UNICODE_FORMAT ASCII_S_PRINT_UNICODE_FORMAT They will ASSERT when: 1) The input parameter 'StartOfBuffer' is

Re: [edk2] [PATCH V2 5/6] SecurityPkg/Password: Add Password based UserAuthentication modules.

2017-02-08 Thread Long, Qin
Good thoughts, though the time attack looks just theoretical in here (the hash result comparison in here can nearly ignored on CPU overhead.) :) In general, time-based attack was possible if the attacker is capable of adjust some parameters to collect more CPU usage or power for clearer

Re: [edk2] [RFC v2 1/6] MdeModulePkg: Add DxeBmDmaLib (BmDmaLib class) library

2017-02-08 Thread Ni, Ruiyu
Leo, Did you forget to add the BmDmaLib implementation in the patch? Thanks/Ray > -Original Message- > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of > Leo Duran > Sent: Saturday, January 14, 2017 6:14 AM > To: edk2-devel@lists.01.org > Cc: Tian, Feng

Re: [edk2] Sourceforge svn mirror of edk2

2017-02-08 Thread Gao, Liming
Hi, all Edk2 svn mirror works now! Thanks Liming >-Original Message- >From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Gao, >Liming >Sent: Thursday, February 09, 2017 9:54 AM >To: Laszlo Ersek ; Shifflett, Joseph > >Cc:

[edk2] [Patch 1/2] MdeModulePkg PeiCore: Reset PeimNeedingDispatch when its security violation

2017-02-08 Thread Liming Gao
When PEIM is security violation, its matched extraction ppi may not be installed. So, its PeimNeedingDispatch will still reset to TRUE. Cc: Star Zeng Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Liming Gao ---

Re: [edk2] [Patch 2/2] MdeModulePkg PeiCore: Don't cache GUIDED section with AUTH_NOT_TESTED

2017-02-08 Thread Zeng, Star
Reviewed-by: Star Zeng -Original Message- From: Gao, Liming Sent: Thursday, February 9, 2017 12:15 PM To: edk2-devel@lists.01.org Cc: Zeng, Star Subject: [Patch 2/2] MdeModulePkg PeiCore: Don't cache GUIDED section with AUTH_NOT_TESTED If

Re: [edk2] [PATCH 10/12] BaseTool/Script: Add SmiHandleProfile OS tool to get symbol.

2017-02-08 Thread Yao, Jiewen
1) Good reminder. I will clean up. 2) I did add parameter to let user input GUID, by using -g. (You can see the quark sample in patch 12) At same time, I want to provide a short default GUID list for core module. Just in case user does not use -g, we can still have some basic

Re: [edk2] [PATCH 10/12] BaseTool/Script: Add SmiHandleProfile OS tool to get symbol.

2017-02-08 Thread Gao, Liming
Jiewen: For the commented code, if they are useless, could you clean up them? Besides, Guid Value and Name mapping is recorded into Build Output FV\Guid.xref. Could you enhance script to parse this file to get full guid lists? +#print "0 - " + match.group(0) +

Re: [edk2] [Patch 1/2] MdeModulePkg PeiCore: Reset PeimNeedingDispatch when its security violation

2017-02-08 Thread Zeng, Star
Reviewed-by: Star Zeng to this change. How about to also move the code blocks below into the "if (Status != EFI_SECURITY_VIOLATION) {" to follow PI Spec? PERF_START (PeimFileHandle, "PEIM", NULL, 0); REPORT_STATUS_CODE_WITH_EXTENDED_DATA (

Re: [edk2] [PATCH 10/12] BaseTool/Script: Add SmiHandleProfile OS tool to get symbol.

2017-02-08 Thread Gao, Liming
Got it. That's good. From: Yao, Jiewen Sent: Thursday, February 09, 2017 12:52 PM To: Gao, Liming ; edk2-devel@lists.01.org Cc: Zhu, Yonghong ; Kinney, Michael D ; Laszlo Ersek Subject: RE: [PATCH

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Zeng, Star
In fact, X64 DxeIplPeim does not refer PcdDxeIplSwitchToLongMode at all. DxeIpl.inf: [FeaturePcd.IA32] gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode ## CONSUMES As I remember, I did a draft patch below before for the discussion about how to determine DXE is 32BITs or 64BITs in

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Zeng, Star
Correct typo in below email. "about how to determine DXE is 32BITs or 64BITs" should be "about how to determine PEI is 32BITs or 64BITs". At that time, we were discussing if the code needs to allocate <4G ACPI table for PEI phase at S3 resume. Thanks, Star -Original Message- From:

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Zeng, Star
Stick to current comments and code, OvmfPkg X64 has bug? :) PCD comments: # It is assumed that 64-bit DxeCore is built in firmware if it is true; otherwise 32-bit DxeCore Code pieces in S3ResumePei, S3SaveStateDxe, SmmLockBoxPeiLib, etc: // Both BIOS and OS wants 64bit vector if (FeaturePcdGet

[edk2] [PATCH v2 1/4] MdePkg/BasePrintLib: Add safe print functions [A|U]ValueToStringS

2017-02-08 Thread Hao Wu
Add the following 2 APIs: UnicodeValueToStringS AsciiValueToStringS These safe version APIs are used to enhance their counterpart (APIs without trailing 'S' in function names). They perform checks to the input parameters and will return relative status to reflect the check result. Return

[edk2] [PATCH v2 0/4] PrintLib: Add safe print functions [A|U]ValueToStringS

2017-02-08 Thread Hao Wu
V2 changes: Add the EFI_PRINT2S_PROTOCOL as a safe version of the EFI_PRINT2_PROTOCOL, the new protocol replaces the following 2 services in EFI_PRINT2_PROTOCOL: UNICODE_VALUE_TO_STRING ASCII_VALUE_TO_STRING with: UNICODE_VALUE_TO_STRING_S ASCII_VALUE_TO_STRING_S Now, the PrintLib instance

[edk2] [PATCH v2 2/4] MdeModulePkg: Add the EFI_PRINT2S_PROTOCOL

2017-02-08 Thread Hao Wu
Add the EFI_PRINT2S_PROTOCOL as a safe version of the EFI_PRINT2_PROTOCOL, the EFI_PRINT2S_PROTOCOL replaces the following 2 services in EFI_PRINT2_PROTOCOL: UNICODE_VALUE_TO_STRING ASCII_VALUE_TO_STRING with: UNICODE_VALUE_TO_STRING_S ASCII_VALUE_TO_STRING_S The 2 new services perform checks to

[edk2] [PATCH v2 3/4] MdeModulePkg/PrintLib: Use EFI_PRINT2S_PROTOCOL for this instance

2017-02-08 Thread Hao Wu
The commit updates the PrintLib instance MdeModulePkg/Library/DxePrintLibPrint2Protocol to use EFI_PRINT2S_PROTOCOL to implement the APIs. Cc: Jiewen Yao Cc: Liming Gao Cc: Michael Kinney Contributed-under: TianoCore

[edk2] [PATCH v2 4/4] MdeModulePkg/PrintLib: Add safe print functions [A|U]ValueToStringS

2017-02-08 Thread Hao Wu
Add the following 2 APIs: UnicodeValueToStringS AsciiValueToStringS These safe version APIs are used to enhance their counterpart (APIs without trailing 'S' in function names). They perform checks to the input parameters and will return relative status to reflect the check result. Return

Re: [edk2] [PATCH V2 2/6] SecurityPkg/dec: Add PcdPasswordCleared.

2017-02-08 Thread Yao, Jiewen
Good catch. Fixed. From: Long, Qin Sent: Wednesday, February 8, 2017 4:41 PM To: Yao, Jiewen ; edk2-devel@lists.01.org Cc: Zhang, Chao B Subject: RE: [PATCH V2 2/6] SecurityPkg/dec: Add PcdPasswordCleared. Reviewed-by: Qin Long

Re: [edk2] [PATCH V2 3/6] SecurityPkg/include: Add PlatformPasswordLib lib class.

2017-02-08 Thread Yao, Jiewen
Good catch. Fixed. From: Long, Qin Sent: Wednesday, February 8, 2017 4:39 PM To: Yao, Jiewen ; edk2-devel@lists.01.org Cc: Zhang, Chao B Subject: RE: [PATCH V2 3/6] SecurityPkg/include: Add PlatformPasswordLib lib class. Reviewed-by: Qin Long

[edk2] [Patch] BaseTools: Add NOOPT target in CLANG38 tool chain

2017-02-08 Thread Liming Gao
https://bugzilla.tianocore.org/show_bug.cgi?id=310 Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Liming Gao --- BaseTools/Conf/tools_def.template | 32 1 file changed, 24

Re: [edk2] [patch] OvmfPkg/QemuBootOrderLib: Fix NOOPT build failure

2017-02-08 Thread Laszlo Ersek
On 02/08/17 08:15, Bi, Dandan wrote: > Hi Jordan, > > Yes, it fails on IA32. > As far as I know, it impacts VS2012/2013/2015. Thank you for confirming. (Unfortunately, a few months back I lost the virtual machine in which I had installed VS2015, and since then I haven't found the energy to

Re: [edk2] [PATCH] MdeModulePkg/UefiBootManagerLib: Initialize Handle before using it

2017-02-08 Thread Wang, Sunny (HPS SW)
Looks good to me. Reviewed-by: Sunny Wang However, I saw the other potential issue below. If you also think the potential issue is valid, you can fix this in the other patch. We need to consider the case where MDEPKG_NDEBUG is defined. We're using ASSERT_EFI_ERROR to handle

Re: [edk2] [PATCH] MdeModulePkg: Add dynamic PCD PcdPteMemoryEncryptionAddressOrMask

2017-02-08 Thread Laszlo Ersek
On 02/07/17 20:53, Leo Duran wrote: > From: Brijesh Singh > > This dynamic PCD holds the address mask for page table entries when memory > encryption is enabled on AMD processors supporting the Secure Encrypted > Virtualization (SEV) feature. > > Cc: Feng Tian

Re: [edk2] [PATCH] MdeModulePkg/UefiBootManagerLib: Initialize Handle before using it

2017-02-08 Thread Laszlo Ersek
On 02/08/17 09:13, Wang, Sunny (HPS SW) wrote: > Looks good to me. > Reviewed-by: Sunny Wang > > However, I saw the other potential issue below. If you also think the > potential issue is valid, you can fix this in the other patch. > We need to consider the case where

Re: [edk2] [PATCH] MdeModulePkg/UefiBootManagerLib: Initialize Handle before using it

2017-02-08 Thread Ni, Ruiyu
Sunny, It's impossible for the Handle which doesn't have SimpleFileSystem or BlockIo installed. Thanks/Ray > -Original Message- > From: Wang, Sunny (HPS SW) [mailto:sunnyw...@hpe.com] > Sent: Wednesday, February 8, 2017 4:13 PM > To: Ni, Ruiyu ;

Re: [edk2] [PATCH v4 6/6] MdePkg/Pci22.h: Deprecate out-of-Spec IncompatiblePciDevice macros

2017-02-08 Thread Laszlo Ersek
On 02/08/17 10:42, Ruiyu Ni wrote: > DEVICE_ID_NOCARE is defined as 0x but Spec says (UINT64) -1 > should be used to match any VendorId/DeviceId/RevisionId/ > SubsystemVendorId/SubsystemDeviceId. > > PCI_BAR_OLD_ALIGN/PCI_BAR_EVEN_ALIGN/PCI_BAR_SQUAD_ALIGN/ > PCI_BAR_DQUAD_ALIGN are defined

Re: [edk2] [PATCH] MdeModulePkg/UefiBootManagerLib: Initialize Handle before using it

2017-02-08 Thread Wang, Sunny (HPS SW)
Yeah, I misread the commit message and had a misunderstanding on what situation BmExpandMediaDevicePath() is called . Ray and Lazlo, thanks for both of you clarifying this. :) Regards, Sunny Wang -Original Message- From: Laszlo Ersek [mailto:ler...@redhat.com] Sent: Wednesday,

[edk2] [PATCH v4 0/6] Fix PciBus to accept Spec values as BarIndex and Alignment

2017-02-08 Thread Ruiyu Ni
If a platform developer follows the PI spec to write an IncompatiblePciDeviceSupport driver, due to a spec complaince bug in PciBus driver, the IncompatiblePciDeviceSupport driver may not work as expected. The patches fix PciBus to follow Spec to accept Spec defined values. v2: Use

[edk2] [PATCH v4 6/6] MdePkg/Pci22.h: Deprecate out-of-Spec IncompatiblePciDevice macros

2017-02-08 Thread Ruiyu Ni
DEVICE_ID_NOCARE is defined as 0x but Spec says (UINT64) -1 should be used to match any VendorId/DeviceId/RevisionId/ SubsystemVendorId/SubsystemDeviceId. PCI_BAR_OLD_ALIGN/PCI_BAR_EVEN_ALIGN/PCI_BAR_SQUAD_ALIGN/ PCI_BAR_DQUAD_ALIGN are defined but Spec doesn't have such definitions.

Re: [edk2] [PATCH] MdeModulePkg/UefiBootManagerLib: Initialize Handle before using it

2017-02-08 Thread Ni, Ruiyu
I will change the commit message as Laszlo suggested. Thanks/Ray > -Original Message- > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of > Wang, Sunny (HPS SW) > Sent: Wednesday, February 8, 2017 5:38 PM > To: Laszlo Ersek ; Ni, Ruiyu

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3] Change MRC parameter

2017-02-08 Thread Guo, Mang
These code cause HDMI cable of some vendor couldn't work. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../LeafHill/BoardInitPreMem/BoardInitMiscs.c | 17 +- .../LeafHill/BoardInitPreMem/BoardInitPreMem.inf | 1 -

Re: [edk2] [Patch][edk2-platforms/devel-MinnowBoard3] Change MRC parameter

2017-02-08 Thread Lu, ShifeiX A
Reviewed-by: lushifex Thanks, Shifei -Original Message- From: Guo, Mang Sent: Wednesday, February 08, 2017 6:39 PM To: edk2-devel@lists.01.org Cc: Lu, ShifeiX A; Wei, David Subject: [Patch][edk2-platforms/devel-MinnowBoard3] Change MRC parameter These code

Re: [edk2] [PATCH V3 0/4] DXE Memory Protection

2017-02-08 Thread Yao, Jiewen
Hi Lindholm/Ard This version 3 contains both of your feedback before. If you can do me a favor to evaluated the impact to ARM, that will be great. Thank you Yao Jiewen > -Original Message- > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Jiewen > Yao > Sent:

Re: [edk2] [PATCH v2] MdeModulePkg PiSmmIpl: Update SmmCommunication comments to match code logic

2017-02-08 Thread Tian, Feng
Reviewed-by: Feng Tian Thanks Feng -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Liming Gao Sent: Thursday, February 9, 2017 3:05 PM To: edk2-devel@lists.01.org Cc: Tian, Feng ; Zeng, Star

Re: [edk2] [PATCH v2] MdeModulePkg PiSmmIpl: Update SmmCommunication comments to match code logic

2017-02-08 Thread Zeng, Star
Reviewed-by: Star Zeng -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Liming Gao Sent: Thursday, February 9, 2017 3:05 PM To: edk2-devel@lists.01.org Cc: Tian, Feng ; Zeng, Star

[edk2] [PATCH v2] MdeModulePkg PiSmmIpl: Update SmmCommunication comments to match code logic

2017-02-08 Thread Liming Gao
Cc: Star Zeng Cc: Feng Tian Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Liming Gao --- MdeModulePkg/Core/PiSmmCore/PiSmmIpl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[edk2] [PATCH V3 2/4] ArmPkg/CpuDxe: Correct EFI_MEMORY_RO usage

2017-02-08 Thread Jiewen Yao
Current Arm CpuDxe driver uses EFI_MEMORY_WP for write protection, according to UEFI spec, we should use EFI_MEMORY_RO for write protection. The EFI_MEMORY_WP is the cache attribute instead of memory attribute. Cc: Leif Lindholm Cc: Ard Biesheuvel

[edk2] [PATCH V3 4/4] MdeModulePkg/DxeCore: Add UEFI image protection.

2017-02-08 Thread Jiewen Yao
If the UEFI image is page aligned, the image code section is set to read only and the image data section is set to non-executable. 1) This policy is applied for all UEFI image including boot service driver, runtime driver or application. 2) This policy is applied only if the UEFI image meets the

[edk2] [PATCH V3 1/4] UefiCpuPkg/CpuDxe: Add memory attribute setting.

2017-02-08 Thread Jiewen Yao
Add memory attribute setting in CpuArch protocol. Previous SetMemoryAttributes() API only supports cache attribute setting. This patch updated SetMemoryAttributes() API to support memory attribute setting by updating CPU page table. Cc: Jeff Fan Cc: Michael Kinney

[edk2] [PATCH V3 3/4] MdeModulePkg/dec: add PcdImageProtectionPolicy.

2017-02-08 Thread Jiewen Yao
Add PCD for image protection policy. Cc: Star Zeng Cc: Feng Tian Cc: Michael Kinney Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jiewen Yao --- MdeModulePkg/MdeModulePkg.dec

[edk2] [PATCH V3 0/4] DXE Memory Protection

2017-02-08 Thread Jiewen Yao
V3 1) Add PCD for policy control (feedback from Ard Biesheuvel) (Discussed with Mike Kinney) + #BIT0 - Image from unknown device. + #BIT1 - Image from firmware volume. + # @Prompt Set image protection policy. + # @ValidRange 0x8002 | 0x - 0x001F +