[edk2-devel] Upcoming Event: TianoCore Community Meeting - APAC/NAMO - Thu, 06/06/2019 7:30pm-8:00pm #cal-reminder
*Reminder:* TianoCore Community Meeting - APAC/NAMO *When:* Thursday, 6 June 2019, 7:30pm to 8:00pm, (GMT-07:00) America/Los Angeles *Where:* https://zoom.us/j/769108409 View Event ( https://edk2.groups.io/g/devel/viewevent?eventid=458021 ) *Organizer:* Stephano Cetola stephano.cet...@intel.com ( stephano.cet...@intel.com?subject=Re:%20Event:%20TianoCore%20Community%20Meeting%20-%20APAC%2FNAMO ) *Description:* Join Zoom Meeting https://zoom.us/j/769108409 ( https://zoom.us/j/769108409 ) One tap mobile +17207072699,,769108409# US +16465588656,,769108409# US (New York) Dial by your location +1 720 707 2699 US +1 646 558 8656 US (New York) Meeting ID: 769 108 409 Find your local number: https://zoom.us/u/abOtdJckxL -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42018): https://edk2.groups.io/g/devel/message/42018 Mute This Topic: https://groups.io/mt/31970773/21656 Mute #cal-reminder: https://groups.io/mk?hashtag=cal-reminder=3846945 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [edk2-devel] [Patch V3] OpensslLib: Missing local header files in [Sources] section of .INFs
Hi Xiaoyu, For your comment (1), I don't see a way to rule out headers using configdata. I was already using configdata to get the include directories, but configdata doesn't list the specific header files that will be used for compilation. We can ignore things with a common name or specific files, but ruling out all of them doesn't seem possible using what is given. The rest of the comments can be addressed. -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42017): https://edk2.groups.io/g/devel/message/42017 Mute This Topic: https://groups.io/mt/31713211/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 0/4] Define EDKII_SERIAL_PORT_LIB_VENDOR_GUID
On Thu, 6 Jun 2019 at 19:16, Laszlo Ersek wrote: > > On 06/06/19 15:14, Anthony PERARD wrote: > > The macro SERIAL_DXE_FILE_GUID is been defined twice and the GUID is been > > used > > once without defining the macro. This patch series define a macro in > > MdeModulePkg where the SerialDxe is, and replace all other use by this new > > one, > > EDKII_SERIAL_PORT_LIB_VENDOR_GUID. > > > > Note that I haven't build/test those changes, but I have test the first > > patch > > by applying a similar change to a patch series I'm working on. > > > > Patch series available in this git branch: > > https://xenbits.xen.org/git-http/people/aperard/ovmf.git > > br.serial-dxe-guid-v2 > > > > Thanks. > > > > Anthony PERARD (4): > > MdeModulePkg: Introduce EDKII_SERIAL_PORT_LIB_VENDOR_GUID > > ArmVirtPkg/PlatformBootManagerLib: Use > > EDKII_SERIAL_PORT_LIB_VENDOR_GUID from MdeModulePkg > > ArmPkg/PlatformBootManagerLib: Use EDKII_SERIAL_PORT_LIB_VENDOR_GUID > > from MdeModulePkg > > UefiPayloadPkg/PlatformBootManagerLib: Use > > EDKII_SERIAL_PORT_LIB_VENDOR_GUID from MdeModulePkg > > > > MdeModulePkg/MdeModulePkg.dec | 3 +++ > > .../Universal/SerialDxe/SerialDxe.inf | 1 + > > .../Include/Guid/SerialPortLibVendor.h| 19 +++ > > .../PlatformBootManagerLib/PlatformBm.c | 8 ++-- > > .../PlatformBootManagerLib/PlatformBm.c | 8 ++-- > > MdeModulePkg/Universal/SerialDxe/SerialIo.c | 3 ++- > > .../PlatformBootManagerLib/PlatformConsole.c | 3 ++- > > 7 files changed, 31 insertions(+), 14 deletions(-) > > create mode 100644 MdeModulePkg/Include/Guid/SerialPortLibVendor.h > > > > For patches #1 and #2: > > Tested-by: Laszlo Ersek > For the series: Acked-by: Ard Biesheuvel -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42016): https://edk2.groups.io/g/devel/message/42016 Mute This Topic: https://groups.io/mt/31950872/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 0/4] Define EDKII_SERIAL_PORT_LIB_VENDOR_GUID
On 06/06/19 15:14, Anthony PERARD wrote: > The macro SERIAL_DXE_FILE_GUID is been defined twice and the GUID is been used > once without defining the macro. This patch series define a macro in > MdeModulePkg where the SerialDxe is, and replace all other use by this new > one, > EDKII_SERIAL_PORT_LIB_VENDOR_GUID. > > Note that I haven't build/test those changes, but I have test the first patch > by applying a similar change to a patch series I'm working on. > > Patch series available in this git branch: > https://xenbits.xen.org/git-http/people/aperard/ovmf.git br.serial-dxe-guid-v2 > > Thanks. > > Anthony PERARD (4): > MdeModulePkg: Introduce EDKII_SERIAL_PORT_LIB_VENDOR_GUID > ArmVirtPkg/PlatformBootManagerLib: Use > EDKII_SERIAL_PORT_LIB_VENDOR_GUID from MdeModulePkg > ArmPkg/PlatformBootManagerLib: Use EDKII_SERIAL_PORT_LIB_VENDOR_GUID > from MdeModulePkg > UefiPayloadPkg/PlatformBootManagerLib: Use > EDKII_SERIAL_PORT_LIB_VENDOR_GUID from MdeModulePkg > > MdeModulePkg/MdeModulePkg.dec | 3 +++ > .../Universal/SerialDxe/SerialDxe.inf | 1 + > .../Include/Guid/SerialPortLibVendor.h| 19 +++ > .../PlatformBootManagerLib/PlatformBm.c | 8 ++-- > .../PlatformBootManagerLib/PlatformBm.c | 8 ++-- > MdeModulePkg/Universal/SerialDxe/SerialIo.c | 3 ++- > .../PlatformBootManagerLib/PlatformConsole.c | 3 ++- > 7 files changed, 31 insertions(+), 14 deletions(-) > create mode 100644 MdeModulePkg/Include/Guid/SerialPortLibVendor.h > For patches #1 and #2: Tested-by: Laszlo Ersek Thanks Laszlo -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42015): https://edk2.groups.io/g/devel/message/42015 Mute This Topic: https://groups.io/mt/31950872/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 2/4] ArmVirtPkg/PlatformBootManagerLib: Use EDKII_SERIAL_PORT_LIB_VENDOR_GUID from MdeModulePkg
On 06/06/19 15:14, Anthony PERARD wrote: > SERIAL_DXE_FILE_GUID is now defined in MdeModulePkg as > EDKII_SERIAL_PORT_LIB_VENDOR_GUID, simply use it. > > Signed-off-by: Anthony PERARD > --- > ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c | 8 ++-- > 1 file changed, 2 insertions(+), 6 deletions(-) > > diff --git a/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c > b/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c > index b8f50ea96b..30c015eec5 100644 > --- a/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c > +++ b/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c > @@ -26,6 +26,7 @@ > #include > #include > #include > +#include > > #include "PlatformBm.h" > > @@ -41,18 +42,13 @@ typedef struct { > } PLATFORM_SERIAL_CONSOLE; > #pragma pack () > > -#define SERIAL_DXE_FILE_GUID { \ > - 0xD3987D4B, 0x971A, 0x435F, \ > - { 0x8C, 0xAF, 0x49, 0x67, 0xEB, 0x62, 0x72, 0x41 } \ > - } > - > STATIC PLATFORM_SERIAL_CONSOLE mSerialConsole = { >// >// VENDOR_DEVICE_PATH SerialDxe >// >{ > { HARDWARE_DEVICE_PATH, HW_VENDOR_DP, DP_NODE_LEN (VENDOR_DEVICE_PATH) }, > -SERIAL_DXE_FILE_GUID > +EDKII_SERIAL_PORT_LIB_VENDOR_GUID >}, > >// > I would drop "from MdeModulePkg" from the subject line. With that change, Reviewed-by: Laszlo Ersek If the maintainer that pushes this series agrees to tweak the subject like that, then I'm OK if the series is not reposted just for this. (BTW I could be that maintainer too.) Thanks Laszlo -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42013): https://edk2.groups.io/g/devel/message/42013 Mute This Topic: https://groups.io/mt/31950871/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[edk2-devel] Upcoming Event: TianoCore Community Meeting - EMEA/NAMO - Thu, 06/06/2019 9:00am-10:00am #cal-reminder
*Reminder:* TianoCore Community Meeting - EMEA/NAMO *When:* Thursday, 6 June 2019, 9:00am to 10:00am, (GMT-07:00) America/Los Angeles *Where:* https://zoom.us/j/188375690 View Event ( https://edk2.groups.io/g/devel/viewevent?eventid=456834 ) *Organizer:* Stephano Cetola stephano.cet...@intel.com ( stephano.cet...@intel.com?subject=Re:%20Event:%20TianoCore%20Community%20Meeting%20-%20EMEA%2FNAMO ) *Description:* Join Zoom Meeting https://zoom.us/j/188375690 ( https://zoom.us/j/188375690 ) One tap mobile +16465588656,,188375690# US (New York) +17207072699,,188375690# US Dial by your location +1 646 558 8656 US (New York) +1 720 707 2699 US Meeting ID: 188 375 690 Find your local number: https://zoom.us/u/abOtdJckxL -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42012): https://edk2.groups.io/g/devel/message/42012 Mute This Topic: https://groups.io/mt/31952458/21656 Mute #cal-reminder: https://groups.io/mk?hashtag=cal-reminder=3846945 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] ShellPkg/acpiview: GTDT updates for ACPI 6.3
Reviewed-by: Sami Mujawar -Original Message- From: PierreGondois Sent: 06 June 2019 01:29 PM To: devel@edk2.groups.io Cc: jaben.car...@intel.com; ray...@intel.com; zhichao@intel.com; Sami Mujawar ; Matteo Carlini ; Stephanie Hughes-Fitt ; Pierre Gondois ; nd Subject: [PATCH v1 1/1] ShellPkg/acpiview: GTDT updates for ACPI 6.3 From: Pierre Gondois The ACPI 6.3 specification introduces support to describe the ARMv8.1 virtual EL2 timers. This patch updates the GTDT parser of acpiview to decode the EL2 virtual timer fields. Signed-off-by: Pierre Gondois --- The changes can be seen at: https://github.com/PierreARM/edk2/tree/382_acpiview_gtdt_acpi6_3_update_v1 Notes: v1: - GTDT updates for ACPI 6.3 [Pierre] ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c index 1b7e56486c8fb98a8fe063ae5fa25d86500a58a9..3b05ff3015d4a3af62dd9fab057c32369a456267 100644 --- a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c +++ b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtPars +++ er.c @@ -5,7 +5,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent @par Reference(s): -- ACPI 6.2 Specification - Errata A, September 2017 +- ACPI 6.3 Specification - January 2019 **/ #include @@ -77,7 +77,9 @@ STATIC CONST ACPI_PARSER GtdtParser[] = { {L"Platform Timer Count", 4, 88, L"%d", NULL, (VOID**), NULL, NULL}, {L"Platform Timer Offset", 4, 92, L"0x%x", NULL, - (VOID**), NULL, NULL} + (VOID**), NULL, NULL}, {L"Virtual EL2 Timer + GSIV", 4, 96, L"0x%x", NULL, NULL, NULL, NULL}, {L"Virtual EL2 Timer + Flags", 4, 100, L"0x%x", NULL, NULL, NULL, NULL} }; /** -- 'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)' -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42011): https://edk2.groups.io/g/devel/message/42011 Mute This Topic: https://groups.io/mt/31950298/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] BaseTools: don't use WHOLEARCHIVE linker flag for VS2017 toolchain
Roman: Below is my data. There is no big difference for their image size. My VS2017 version 15.9, VS2015 version 14.0. And, /GL is the global optimization compiler option. /LTCG is the linker option for the whole-program optimization. /WHOLEARCHIVE will force to link all obj files. It is helpful to detect the duplicated functions or the missing functions. But, /LTCG can do the global optimization to remove unused ones. Then, the final image should be the similar./WHOLEARCHIVE has some issue in VS2015. So, it is not enabled in VS2015. edk2 git version 20d2e5a125 edk2-platform git version 892766538f, now OptionRomPkg is in edk2-platforms Directory of D:\AllPkg\Build\OptionRomPkg\RELEASE_VS2015x86\X64 06/06/2019 09:44 PM . 06/06/2019 09:44 PM .. 06/06/2019 09:44 PM20,512 AtapiPassThruDxe.efi 06/06/2019 09:44 PM20,992 AtapiPassThruDxe.rom 06/06/2019 09:44 PM23,040 Ax88772.efi 06/06/2019 09:44 PM26,464 Ax88772b.efi 06/06/2019 09:44 PM10,208 BltLibSample.efi 06/06/2019 09:44 PM21,376 CirrusLogic5430Dxe.efi 06/06/2019 09:44 PM11,264 CirrusLogic5430Dxe.rom 06/06/2019 09:44 PM21,664 FtdiUsbSerialDxe.efi 06/06/2019 09:44 PM MdePkg 06/06/2019 09:44 PM OptionRomPkg 06/06/2019 09:44 PM 6,685 TOOLS_DEF.X64 06/06/2019 09:44 PM34,688 UndiRuntimeDxe.efi Directory of D:\AllPkg\Build\OptionRomPkg\RELEASE_VS2017\X64 06/06/2019 09:41 PM . 06/06/2019 09:41 PM .. 06/06/2019 09:41 PM20,864 AtapiPassThruDxe.efi 06/06/2019 09:41 PM20,992 AtapiPassThruDxe.rom 06/06/2019 09:41 PM23,360 Ax88772.efi 06/06/2019 09:41 PM26,944 Ax88772b.efi 06/06/2019 09:41 PM10,528 BltLibSample.efi 06/06/2019 09:41 PM21,792 CirrusLogic5430Dxe.efi 06/06/2019 09:41 PM11,264 CirrusLogic5430Dxe.rom 06/06/2019 09:41 PM22,080 FtdiUsbSerialDxe.efi 06/06/2019 09:41 PM MdePkg 06/06/2019 09:41 PM OptionRomPkg 06/06/2019 09:41 PM 7,129 TOOLS_DEF.X64 06/06/2019 09:41 PM35,104 UndiRuntimeDxe.efi Thanks Liming > -Original Message- > From: Roman Agafonov [mailto:roman.agafo...@aquantia.com] > Sent: Thursday, June 6, 2019 8:20 PM > To: Gao, Liming ; devel@edk2.groups.io > Cc: Feng, Bob C ; Zhu, Yonghong > Subject: Re: [PATCH v1 1/1] BaseTools: don't use WHOLEARCHIVE linker flag for > VS2017 toolchain > > Hi Liming, > > I don't have any custom options except a few ones to disable compiler > warnings. AFAIK /GL is a compiler, not linker option, and it is used > by EDK Visual Studio toolchains by default. > > Of course, the results may vary from project to project. There difference may > not be that big in all cases. Please try building some other > package and compare the results. For example, this is what I get for > OptionRomPkg compiled with two different toolchains. As you can see, > the difference in size is abnormal. > > pcfist@pcfist-pc:/mnt/c/src/UEFI/UDK2018/Build/OptionRomPkg$ ls -psh1 > RELEASE_VS2017/X64 RELEASE_VS2015x86/X64 > RELEASE_VS2015x86/X64: > total 212K > 20K AtapiPassThruDxe.efi > 24K AtapiPassThruDxe.rom > 28K Ax88772b.efi > 24K Ax88772.efi > 12K BltLibSample.efi > 24K CirrusLogic5430Dxe.efi > 12K CirrusLogic5430Dxe.rom > 24K FtdiUsbSerialDxe.efi >0 MdePkg/ >0 OptionRomPkg/ > 8.0K TOOLS_DEF.X64 > 36K UndiRuntimeDxe.efi > > RELEASE_VS2017/X64: > total 424K > 56K AtapiPassThruDxe.efi > 56K AtapiPassThruDxe.rom > 60K Ax88772b.efi > 24K Ax88772.efi > 12K BltLibSample.efi > 56K CirrusLogic5430Dxe.efi > 28K CirrusLogic5430Dxe.rom > 56K FtdiUsbSerialDxe.efi >0 MdePkg/ >0 OptionRomPkg/ > 8.0K TOOLS_DEF.X64 > 68K UndiRuntimeDxe.efi > > When comparing the .map files using difftool, I see a lot of unused functions > from edk2 libraries (such as UefiDevicePathLib etc.) being > included in the resulting executable, thus increasing its size. This is > exactly what /WHOLEARCHIVE flag is intended for. My point here is > whether this behavior is really desired, and given the fact that WHOLEARCHIVE > had been removed from VS2015 toolchain previously, I > don't see a reason to use it with VS2017 too. > > Best regards, > Roman > > > From: Gao, Liming > Sent: Wednesday, June 5, 2019 6:47 PM > To: Roman Agafonov; devel@edk2.groups.io > Cc: Feng, Bob C; Zhu, Yonghong > Subject: RE: [PATCH v1 1/1] BaseTools: don't use WHOLEARCHIVE linker flag for > VS2017 toolchain > > I build edk2 OVMF with VS2015 and VS2017. Their image size are almost same. > Have you the additional options to disable the > optimization? In fact, /GL option will remove the unused function and logic. > > > -Original Message- > > From: Roman Agafonov [mailto:roman.agafo...@aquantia.com] > > Sent: Wednesday, June 5, 2019 1:21 AM > > To: Gao, Liming ;
[edk2-devel] [PATCH v2 3/4] ArmPkg/PlatformBootManagerLib: Use EDKII_SERIAL_PORT_LIB_VENDOR_GUID from MdeModulePkg
SERIAL_DXE_FILE_GUID is now defined in MdeModulePkg as EDKII_SERIAL_PORT_LIB_VENDOR_GUID, simply use it. Signed-off-by: Anthony PERARD --- ArmPkg/Library/PlatformBootManagerLib/PlatformBm.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/ArmPkg/Library/PlatformBootManagerLib/PlatformBm.c b/ArmPkg/Library/PlatformBootManagerLib/PlatformBm.c index 0f91692c1a..1e30f148b3 100644 --- a/ArmPkg/Library/PlatformBootManagerLib/PlatformBm.c +++ b/ArmPkg/Library/PlatformBootManagerLib/PlatformBm.c @@ -28,6 +28,7 @@ #include #include #include +#include #include "PlatformBm.h" @@ -42,18 +43,13 @@ typedef struct { } PLATFORM_SERIAL_CONSOLE; #pragma pack () -#define SERIAL_DXE_FILE_GUID { \ - 0xD3987D4B, 0x971A, 0x435F, \ - { 0x8C, 0xAF, 0x49, 0x67, 0xEB, 0x62, 0x72, 0x41 } \ - } - STATIC PLATFORM_SERIAL_CONSOLE mSerialConsole = { // // VENDOR_DEVICE_PATH SerialDxe // { { HARDWARE_DEVICE_PATH, HW_VENDOR_DP, DP_NODE_LEN (VENDOR_DEVICE_PATH) }, -SERIAL_DXE_FILE_GUID +EDKII_SERIAL_PORT_LIB_VENDOR_GUID }, // -- Anthony PERARD -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42008): https://edk2.groups.io/g/devel/message/42008 Mute This Topic: https://groups.io/mt/31950874/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[edk2-devel] [PATCH v2 4/4] UefiPayloadPkg/PlatformBootManagerLib: Use EDKII_SERIAL_PORT_LIB_VENDOR_GUID from MdeModulePkg
EDKII_SERIAL_PORT_LIB_VENDOR_GUID is now defined in MdeModulePkg, simply use it. Signed-off-by: Anthony PERARD --- .../Library/PlatformBootManagerLib/PlatformConsole.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformConsole.c b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformConsole.c index 80a11d7451..ee2d8c8d1e 100644 --- a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformConsole.c +++ b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformConsole.c @@ -8,6 +8,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include "PlatformBootManager.h" #include "PlatformConsole.h" +#include #define PCI_DEVICE_PATH_NODE(Func, Dev) \ { \ @@ -53,7 +54,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent (UINT8) ((sizeof (VENDOR_DEVICE_PATH)) >> 8) \ } \ }, \ -{0xD3987D4B, 0x971A, 0x435F, {0x8C, 0xAF, 0x49, 0x67, 0xEB, 0x62, 0x72, 0x41}} \ +EDKII_SERIAL_PORT_LIB_VENDOR_GUID \ } #define gUart \ -- Anthony PERARD -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42007): https://edk2.groups.io/g/devel/message/42007 Mute This Topic: https://groups.io/mt/31950873/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[edk2-devel] [PATCH v2 2/4] ArmVirtPkg/PlatformBootManagerLib: Use EDKII_SERIAL_PORT_LIB_VENDOR_GUID from MdeModulePkg
SERIAL_DXE_FILE_GUID is now defined in MdeModulePkg as EDKII_SERIAL_PORT_LIB_VENDOR_GUID, simply use it. Signed-off-by: Anthony PERARD --- ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c b/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c index b8f50ea96b..30c015eec5 100644 --- a/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c +++ b/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c @@ -26,6 +26,7 @@ #include #include #include +#include #include "PlatformBm.h" @@ -41,18 +42,13 @@ typedef struct { } PLATFORM_SERIAL_CONSOLE; #pragma pack () -#define SERIAL_DXE_FILE_GUID { \ - 0xD3987D4B, 0x971A, 0x435F, \ - { 0x8C, 0xAF, 0x49, 0x67, 0xEB, 0x62, 0x72, 0x41 } \ - } - STATIC PLATFORM_SERIAL_CONSOLE mSerialConsole = { // // VENDOR_DEVICE_PATH SerialDxe // { { HARDWARE_DEVICE_PATH, HW_VENDOR_DP, DP_NODE_LEN (VENDOR_DEVICE_PATH) }, -SERIAL_DXE_FILE_GUID +EDKII_SERIAL_PORT_LIB_VENDOR_GUID }, // -- Anthony PERARD -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42005): https://edk2.groups.io/g/devel/message/42005 Mute This Topic: https://groups.io/mt/31950871/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] ShellPkg/acpiview: GTDT updates for ACPI 6.3
Reviewed-by: Alexei Fedorov -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42004): https://edk2.groups.io/g/devel/message/42004 Mute This Topic: https://groups.io/mt/31950298/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] BaseTools: don't use WHOLEARCHIVE linker flag for VS2017 toolchain
Hi Liming, I don't have any custom options except a few ones to disable compiler warnings. AFAIK /GL is a compiler, not linker option, and it is used by EDK Visual Studio toolchains by default. Of course, the results may vary from project to project. There difference may not be that big in all cases. Please try building some other package and compare the results. For example, this is what I get for OptionRomPkg compiled with two different toolchains. As you can see, the difference in size is abnormal. pcfist@pcfist-pc:/mnt/c/src/UEFI/UDK2018/Build/OptionRomPkg$ ls -psh1 RELEASE_VS2017/X64 RELEASE_VS2015x86/X64 RELEASE_VS2015x86/X64: total 212K 20K AtapiPassThruDxe.efi 24K AtapiPassThruDxe.rom 28K Ax88772b.efi 24K Ax88772.efi 12K BltLibSample.efi 24K CirrusLogic5430Dxe.efi 12K CirrusLogic5430Dxe.rom 24K FtdiUsbSerialDxe.efi 0 MdePkg/ 0 OptionRomPkg/ 8.0K TOOLS_DEF.X64 36K UndiRuntimeDxe.efi RELEASE_VS2017/X64: total 424K 56K AtapiPassThruDxe.efi 56K AtapiPassThruDxe.rom 60K Ax88772b.efi 24K Ax88772.efi 12K BltLibSample.efi 56K CirrusLogic5430Dxe.efi 28K CirrusLogic5430Dxe.rom 56K FtdiUsbSerialDxe.efi 0 MdePkg/ 0 OptionRomPkg/ 8.0K TOOLS_DEF.X64 68K UndiRuntimeDxe.efi When comparing the .map files using difftool, I see a lot of unused functions from edk2 libraries (such as UefiDevicePathLib etc.) being included in the resulting executable, thus increasing its size. This is exactly what /WHOLEARCHIVE flag is intended for. My point here is whether this behavior is really desired, and given the fact that WHOLEARCHIVE had been removed from VS2015 toolchain previously, I don't see a reason to use it with VS2017 too. Best regards, Roman From: Gao, Liming Sent: Wednesday, June 5, 2019 6:47 PM To: Roman Agafonov; devel@edk2.groups.io Cc: Feng, Bob C; Zhu, Yonghong Subject: RE: [PATCH v1 1/1] BaseTools: don't use WHOLEARCHIVE linker flag for VS2017 toolchain I build edk2 OVMF with VS2015 and VS2017. Their image size are almost same. Have you the additional options to disable the optimization? In fact, /GL option will remove the unused function and logic. > -Original Message- > From: Roman Agafonov [mailto:roman.agafo...@aquantia.com] > Sent: Wednesday, June 5, 2019 1:21 AM > To: Gao, Liming ; devel@edk2.groups.io > Cc: Feng, Bob C ; Zhu, Yonghong > Subject: Re: [PATCH v1 1/1] BaseTools: don't use WHOLEARCHIVE linker flag for > VS2017 toolchain > > Hi Liming, > > Sure. Here is what I get after building our NIC driver binary with VS2015x86 > and VS2017 toolchains: > > pcfist@pcfist-pc:/mnt/c/src/uefi/udk2018$ du -h > Build/xgbe_atl/RELEASE_VS2015x86/X64/xgbe_atl.efi > Build/xgbe_atl/RELEASE_VS2017/X64/xgbe_atl.efi > 36K Build/xgbe_atl/RELEASE_VS2015x86/X64/xgbe_atl.efi > 68K Build/xgbe_atl/RELEASE_VS2017/X64/xgbe_atl.efi > > Best regards, > Roman > > From: Gao, Liming > Sent: Tuesday, June 4, 2019 6:54 PM > To: Roman Agafonov; devel@edk2.groups.io > Cc: Feng, Bob C; Zhu, Yonghong > Subject: RE: [PATCH v1 1/1] BaseTools: don't use WHOLEARCHIVE linker flag for > VS2017 toolchain > > Can you show the size data with VS2017 and VS2015 for the same code? > > Thanks > Liming > > -Original Message- > > From: Roman Agafonov [mailto:roman.agafo...@aquantia.com] > > Sent: Tuesday, June 4, 2019 11:41 PM > > To: devel@edk2.groups.io > > Cc: Feng, Bob C ; Gao, Liming ; > > Zhu, Yonghong > > Subject: [PATCH v1 1/1] BaseTools: don't use WHOLEARCHIVE linker flag for > > VS2017 toolchain > > > > I have noticed the resulting binaries are about twice as large when > > using VS2017 toolchain compared to the ones built with VS2015. It appears > > this is caused by /WHOLEARCHIVE linker flag used by this toolchain. This > > flag was previously removed from VS2015 toolchain due to compatibility > > issues. I believe it should not be used with VS2017 as well. > > > > Cc: Bob Feng > > Cc: Liming Gao > > Cc: Yonghong Zhu > > Signed-off-by: Roman Agafonov > > --- > > BaseTools/Conf/tools_def.template | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/BaseTools/Conf/tools_def.template > > b/BaseTools/Conf/tools_def.template > > index 26a2cf604f74..482a526f3052 100755 > > --- a/BaseTools/Conf/tools_def.template > > +++ b/BaseTools/Conf/tools_def.template > > @@ -1545,7 +1545,7 @@ NOOPT_VS2015x86_X64_DLINK_FLAGS = /NOLOGO > > /NODEFAULTLIB /IGNORE:4001 /OPT:REF > > *_VS2017_*_APP_FLAGS = /nologo /E /TC > > *_VS2017_*_PP_FLAGS = /nologo /E /TC /FIAutoGen.h > > *_VS2017_*_VFRPP_FLAGS = /nologo /E /TC /DVFRCOMPILE > >/FI$(MODULE_NAME)StrDefs.h > > -*_VS2017_*_DLINK2_FLAGS = /WHOLEARCHIVE > > +*_VS2017_*_DLINK2_FLAGS = > > *_VS2017_*_ASM16_PATH = DEF(VS2017_BIN_IA32)\ml.exe > > > > ## > > -- > > 2.9.0.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42003): https://edk2.groups.io/g/devel/message/42003 Mute
Re: [edk2-devel] [PATCH 0/4] Define SERIAL_DXE_FILE_GUID only once
> > So, ultimately, we are asking Anthony to: > > > > (1) please introduce the new GUID as > > EDKII_SERIAL_VENDOR_GUID and gEdkiiSerialVendorGuid, > > Yes. > > > > > (2) please append another patch to this series, > > replacing EFI_CALLER_ID_GUID -- and the comment! -- with > > EDKII_SERIAL_VENDOR_GUID, in the "mSerialDevicePath" > > initializer (in > > "MdeModulePkg/Universal/SerialDxe/SerialIo.c"). > > > > Correct? > > Yes. > > > > > Can we suggest an include file name too, in place of > > "MdeModulePkg/Include/Guid/SerialDxe.h"? > > The SerialDxe module uses the services of the SeriaPortLib to > produce the Serial I/O Protocol. Instead of a physical register > interface such as UART in HW, the SW APIs of the SerialPortLib are > used. The GUIDed Vendor HW node in the device path for the HW > register case would be a GUID value and name(s) that represents > the HW device used to perform the Serial I/O actions. Applying > this to the SerialPortLib access would imply GUID and Include > file names that are associated with the SerialPortLib. Perhaps: > > MdeModulePkg/Include/Guid/SerialPortLibVendor.h > > EDKII_SERIAL_PORT_LIB_VENDOR_GUID > > gEdkiiSerialPortLibVendorGuid Thank you all, I'll update the patches. -- Anthony PERARD -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42002): https://edk2.groups.io/g/devel/message/42002 Mute This Topic: https://groups.io/mt/31832613/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] ShellPkg/acpiview: GTDT updates for ACPI 6.3
From: Pierre Gondois The ACPI 6.3 specification introduces support to describe the ARMv8.1 virtual EL2 timers. This patch updates the GTDT parser of acpiview to decode the EL2 virtual timer fields. Signed-off-by: Pierre Gondois --- The changes can be seen at: https://github.com/PierreARM/edk2/tree/382_acpiview_gtdt_acpi6_3_update_v1 Notes: v1: - GTDT updates for ACPI 6.3 [Pierre] ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c index 1b7e56486c8fb98a8fe063ae5fa25d86500a58a9..3b05ff3015d4a3af62dd9fab057c32369a456267 100644 --- a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c +++ b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c @@ -5,7 +5,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent @par Reference(s): -- ACPI 6.2 Specification - Errata A, September 2017 +- ACPI 6.3 Specification - January 2019 **/ #include @@ -77,7 +77,9 @@ STATIC CONST ACPI_PARSER GtdtParser[] = { {L"Platform Timer Count", 4, 88, L"%d", NULL, (VOID**), NULL, NULL}, {L"Platform Timer Offset", 4, 92, L"0x%x", NULL, - (VOID**), NULL, NULL} + (VOID**), NULL, NULL}, + {L"Virtual EL2 Timer GSIV", 4, 96, L"0x%x", NULL, NULL, NULL, NULL}, + {L"Virtual EL2 Timer Flags", 4, 100, L"0x%x", NULL, NULL, NULL, NULL} }; /** -- 'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)' -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#42001): https://edk2.groups.io/g/devel/message/42001 Mute This Topic: https://groups.io/mt/31950298/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] DynamicTablesPkg: GTDT updates for ACPI 6.3
From: Pierre Gondois The ACPI 6.3 specification adds support for describing ARMv8.1 EL2 virtual timers. Update GTDTGenerator to extend this support. Signed-off-by: Pierre Gondois --- The changes can be seen at: https://github.com/PierreARM/edk2/tree/381_dynamicTables_gtdt_acpi6_3_update_v1 Notes: v1: - Add support for describing ARMv8.1 EL2 virtual timers and update GTDTGenerator to extend this support. [Pierre] DynamicTablesPkg/Include/ArmNameSpaceObjects.h | 6 ++ DynamicTablesPkg/Library/Acpi/Arm/AcpiGtdtLibArm/GtdtGenerator.c | 69 +++- 2 files changed, 44 insertions(+), 31 deletions(-) diff --git a/DynamicTablesPkg/Include/ArmNameSpaceObjects.h b/DynamicTablesPkg/Include/ArmNameSpaceObjects.h index bf70dc76cea044b9a8e8eb529d2ddbf892bafd58..0b00c8669729138e910d1fa09870f12dbc2a02a6 100644 --- a/DynamicTablesPkg/Include/ArmNameSpaceObjects.h +++ b/DynamicTablesPkg/Include/ArmNameSpaceObjects.h @@ -290,6 +290,12 @@ typedef struct CmArmGenericTimerInfo { /// The non-secure PL2 timer flags UINT32 NonSecurePL2TimerFlags; + + /// GSIV for the virtual EL2 timer + UINT32 VirtualPL2TimerGSIV; + + /// Flags for the virtual EL2 timer + UINT32 VirtualPL2TimerFlags; } CM_ARM_GENERIC_TIMER_INFO; /** A structure that describes the diff --git a/DynamicTablesPkg/Library/Acpi/Arm/AcpiGtdtLibArm/GtdtGenerator.c b/DynamicTablesPkg/Library/Acpi/Arm/AcpiGtdtLibArm/GtdtGenerator.c index 8d9ddcf9244b9f8b795edf7a53dd8a071bb121bc..adc91c073efcac8e06997658b20096ae0b7d7b86 100644 --- a/DynamicTablesPkg/Library/Acpi/Arm/AcpiGtdtLibArm/GtdtGenerator.c +++ b/DynamicTablesPkg/Library/Acpi/Arm/AcpiGtdtLibArm/GtdtGenerator.c @@ -5,7 +5,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent @par Reference(s): - - ACPI 6.2 Specification - Errata A, September 2017 + - ACPI 6.3 Specification - January 2019 **/ @@ -77,7 +77,7 @@ GET_OBJECT_LIST ( Protocol Interface. @param [in] Gtdt Pointer to the GTDT Table. @param [in] PlatformTimerCount Platform timer count. - + @param [in] AcpiTableRevision Acpi Revision targeted by the platform. @retval EFI_SUCCESS Success. @retval EFI_INVALID_PARAMETER A parameter is invalid. @retval EFI_NOT_FOUND The required object was not found. @@ -90,8 +90,9 @@ EFI_STATUS EFIAPI AddGenericTimerInfo ( IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL * CONST CfgMgrProtocol, - INEFI_ACPI_6_2_GENERIC_TIMER_DESCRIPTION_TABLE * CONST Gtdt, - IN CONST UINT32 PlatformTimerCount + INEFI_ACPI_6_3_GENERIC_TIMER_DESCRIPTION_TABLE * CONST Gtdt, + IN CONST UINT32 PlatformTimerCount, + IN CONST UINT32 AcpiTableRevision ) { EFI_STATUS Status; @@ -131,9 +132,14 @@ AddGenericTimerInfo ( GenericTimerInfo->CounterReadBaseAddress; Gtdt->PlatformTimerCount = PlatformTimerCount; Gtdt->PlatformTimerOffset = (PlatformTimerCount == 0) ? 0 : -sizeof (EFI_ACPI_6_2_GENERIC_TIMER_DESCRIPTION_TABLE); +sizeof (EFI_ACPI_6_3_GENERIC_TIMER_DESCRIPTION_TABLE); - return EFI_SUCCESS; + if (AcpiTableRevision > EFI_ACPI_6_2_GENERIC_TIMER_DESCRIPTION_TABLE_REVISION) { +Gtdt->VirtualPL2TimerGSIV = GenericTimerInfo->VirtualPL2TimerGSIV; +Gtdt->VirtualPL2TimerFlags = GenericTimerInfo->VirtualPL2TimerFlags; + } + + return Status; } /** Add the SBSA Generic Watchdog Timers to the GTDT table. @@ -147,26 +153,26 @@ AddGenericTimerInfo ( STATIC VOID AddGenericWatchdogList ( - IN EFI_ACPI_6_2_GENERIC_TIMER_DESCRIPTION_TABLE * CONST Gtdt, + IN EFI_ACPI_6_3_GENERIC_TIMER_DESCRIPTION_TABLE * CONST Gtdt, IN CONST UINT32 WatchdogOffset, IN CONST CM_ARM_GENERIC_WATCHDOG_INFO* WatchdogInfoList, IN UINT32 WatchdogCount ) { - EFI_ACPI_6_2_GTDT_SBSA_GENERIC_WATCHDOG_STRUCTURE * Watchdog; + EFI_ACPI_6_3_GTDT_SBSA_GENERIC_WATCHDOG_STRUCTURE * Watchdog; ASSERT (Gtdt != NULL); ASSERT (WatchdogInfoList != NULL); - Watchdog = (EFI_ACPI_6_2_GTDT_SBSA_GENERIC_WATCHDOG_STRUCTURE *) + Watchdog = (EFI_ACPI_6_3_GTDT_SBSA_GENERIC_WATCHDOG_STRUCTURE *) ((UINT8*)Gtdt + WatchdogOffset); while (WatchdogCount-- != 0) { // Add watchdog entry DEBUG ((DEBUG_INFO, "GTDT: Watchdog = 0x%p\n", Watchdog)); -Watchdog->Type = EFI_ACPI_6_2_GTDT_SBSA_GENERIC_WATCHDOG; +Watchdog->Type = EFI_ACPI_6_3_GTDT_SBSA_GENERIC_WATCHDOG; Watchdog->Length = - sizeof (EFI_ACPI_6_2_GTDT_SBSA_GENERIC_WATCHDOG_STRUCTURE); + sizeof (EFI_ACPI_6_3_GTDT_SBSA_GENERIC_WATCHDOG_STRUCTURE); Watchdog->Reserved = EFI_ACPI_RESERVED_BYTE; Watchdog->RefreshFramePhysicalAddress =
Re: [edk2-devel] [PATCH v4 2/2] MdeMoudlePkg/CapsulePei: Substantial change on UefiCapsule.c
Zhichao, Thank you for splitting the patches up. This makes for much better history. However, On Wed, Jun 05, 2019 at 09:15:45AM +0800, Zhichao Gao wrote: > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1853 > > AreCapsulesStaged do not need to return the status, only boolean > result is useful. So directly return a boolean value. > Cannot initialize the variable at its definition. > > GetScatterGatherHeadEntries: use allocated buffer instead of fixed > array to handle the condition which the SG list is larger then the > array size. > > Remove API specifier AreCapsulesStaged and GetScatterGatherHeadEntries > because they are internal used. > > Fix some coding style issues. The above are three or four (is the EFIAPI change a coding style issue or not?) unrelated changes. Could you please break this up further? Best Regards, Leif > Cc: Jian J Wang > Cc: Hao A Wu > Cc: Ray Ni > Cc: Star Zeng > Cc: Liming Gao > Cc: Sean Brogan > Cc: Michael Turner > Cc: Bret Barkelew > Cc: Leif Lindholm > Signed-off-by: Zhichao gao > --- > .../Universal/CapsulePei/UefiCapsule.c| 103 +- > 1 file changed, 54 insertions(+), 49 deletions(-) > > diff --git a/MdeModulePkg/Universal/CapsulePei/UefiCapsule.c > b/MdeModulePkg/Universal/CapsulePei/UefiCapsule.c > index 7c8c7a0f45..fabf30926c 100644 > --- a/MdeModulePkg/Universal/CapsulePei/UefiCapsule.c > +++ b/MdeModulePkg/Universal/CapsulePei/UefiCapsule.c > @@ -1,7 +1,7 @@ > /** @file >Capsule update PEIM for UEFI2.0 > > -Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved. > +Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved. > Copyright (c) 2017, AMD Incorporated. All rights reserved. > > SPDX-License-Identifier: BSD-2-Clause-Patent > @@ -10,6 +10,8 @@ SPDX-License-Identifier: BSD-2-Clause-Patent > > #include "Capsule.h" > > +#define DEFAULT_SG_LIST_HEADS (20) > + > #ifdef MDE_CPU_IA32 > // > // Global Descriptor Table (GDT) > @@ -793,30 +795,21 @@ BuildMemoryResourceDescriptor ( > /** >Check if the capsules are staged. > > - @param UpdateCapsules A pointer to return the check result. > - > - @retval EFI_INVALID_PARAMETER The parameter is null. > - @retval EFI_SUCCESS The Capsules are staged. > + @retval TRUE The capsules are staged. > + @retval FALSE The capsules are not staged. > > **/ > -EFI_STATUS > -EFIAPI > -AreCapsulesStaged( > - OUT BOOLEAN *UpdateCapsules > +BOOLEAN > +AreCapsulesStaged ( > + VOID >) > { >EFI_STATUSStatus; >UINTN Size; >EFI_PEI_READ_ONLY_VARIABLE2_PPI *PPIVariableServices; > - EFI_PHYSICAL_ADDRESS CapsuleDataPtr64 = 0; > - > - if (UpdateCapsules == NULL) { > -DEBUG ((DEBUG_ERROR, "%a Invalid parameters. Inputs can't be NULL\n", > __FUNCTION__)); > -ASSERT (UpdateCapsules != NULL); > -return EFI_INVALID_PARAMETER; > - } > + EFI_PHYSICAL_ADDRESS CapsuleDataPtr64; > > - *UpdateCapsules = FALSE; > + CapsuleDataPtr64 = 0; > >Status = PeiServicesLocatePpi( >, > @@ -827,7 +820,7 @@ AreCapsulesStaged( > >if (EFI_ERROR (Status)) { > DEBUG ((DEBUG_ERROR, "Failed to find ReadOnlyVariable2PPI\n")); > -return Status; > +return FALSE; >} > >// > @@ -844,14 +837,12 @@ AreCapsulesStaged( >); > >if (!EFI_ERROR (Status)) { > -*UpdateCapsules = TRUE; > +return TRUE; >} > > - return EFI_SUCCESS; > + return FALSE; > } > > -#define MAX_SG_LIST_HEADS (20) > - > /** >Check all the variables for SG list heads and get the count and addresses. > > @@ -865,23 +856,24 @@ AreCapsulesStaged( > > **/ > EFI_STATUS > -EFIAPI > -GetScatterGatherHeadEntries( > +GetScatterGatherHeadEntries ( >OUT UINTN *ListLength, >OUT EFI_PHYSICAL_ADDRESS **HeadList >) > { > - EFI_STATUS Status; > - UINTNSize; > - UINTNIndex; > - UINTNTempIndex; > - UINTNValidIndex; > - BOOLEAN Flag; > - CHAR16 CapsuleVarName[30]; > - CHAR16 *TempVarName; > - EFI_PHYSICAL_ADDRESS CapsuleDataPtr64; > - EFI_PEI_READ_ONLY_VARIABLE2_PPI *PPIVariableServices; > - EFI_PHYSICAL_ADDRESS TempList[MAX_SG_LIST_HEADS]; > + EFI_STATUSStatus; > + UINTN Size; > + UINTN Index; > + UINTN TempIndex; > + UINTN ValidIndex; > + BOOLEAN Flag; > + CHAR16CapsuleVarName[30]; > + CHAR16*TempVarName; > + EFI_PHYSICAL_ADDRESS CapsuleDataPtr64; > +
Re: [edk2-devel] [PATCH v2] OvmfPkg/QemuVideoDxe: Shouldn't assume system in VGA alias mode.
On 06/06/19 09:56, Laszlo Ersek wrote: > On 06/06/19 09:42, Marc W Chen wrote: >> Query the supported attributes firstly, then bitwise AND (&) both VGA_IO >> and VGA_IO_16. Since the supported attributes should only have one of >> VGA_IO or VGA_IO_16 set, the result of bitwise AND (&) is either VGA_IO >> or IO_16. Then the result can be passed to PciIo->Attributes() to set the >> attributes. >> >> Device driver should consider both since the mReserveVgaAliases in >> PciBusDxe driver is default FALSE(implies that device driver can only set >> VGA_IO_16 to PCI_ROOT_BRIDGE), and Platform code may not return >> EFI_RESERVE_VGA_IO_ALIAS in GetPlatformPolicy of PciPlatformProtocol to >> make mReserveVgaAliases become TRUE(implies that device driver can only >> set VGA_IO to PCI_ROOT_BRIDGE), Currently OvmfPkg doesn't have problem >> due to it has hard code value for PCI_ROOT_BRIDGE's attributes field, so >> an IO access by PciIoProtocol will be successed due to >> RootBridgeIoCheckParameter of PciRootBridgeIo.c will always get pass >> result for legacy IO access. >> >> Usually the attributes field of PCI_ROOT_BRIDGE should be 0, in that case >> it will have issue since the VGA_IO may not be able to be enabled, then >> IO access by PciIoProtocol will be failed, hence the QemuVideoDxe driver >> will not work fine. >> >> Signed-off-by: Marc Chen >> Cc: Jordan Justen >> Cc: Laszlo Ersek >> Cc: Ard Biesheuvel >> Cc: Anthony Perard >> Cc: Julien Grall >> Cc: Marc-André Lureau >> Cc: Stefan Berger >> Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1880 >> --- >> OvmfPkg/QemuVideoDxe/Driver.c | 22 +- >> 1 file changed, 21 insertions(+), 1 deletion(-) >> >> diff --git a/OvmfPkg/QemuVideoDxe/Driver.c b/OvmfPkg/QemuVideoDxe/Driver.c >> index e8a613ef33..522110ef4e 100644 >> --- a/OvmfPkg/QemuVideoDxe/Driver.c >> +++ b/OvmfPkg/QemuVideoDxe/Driver.c >> @@ -201,6 +201,7 @@ QemuVideoControllerDriverStart ( >>PCI_TYPE00Pci; >>QEMU_VIDEO_CARD *Card; >>EFI_PCI_IO_PROTOCOL *ChildPciIo; >> + UINT64SupportedVgaIo; >> >>OldTpl = gBS->RaiseTPL (TPL_CALLBACK); >> >> @@ -277,13 +278,32 @@ QemuVideoControllerDriverStart ( >> goto ClosePciIo; >>} >> >> + // >> + // Get supported PCI attributes >> + // >> + Status = Private->PciIo->Attributes ( >> + Private->PciIo, >> + EfiPciIoAttributeOperationSupported, >> + 0, >> + >> + ); >> + if (EFI_ERROR (Status)) { >> +goto ClosePciIo; >> + } >> + >> + SupportedVgaIo &= (UINT64)(EFI_PCI_IO_ATTRIBUTE_VGA_IO | >> EFI_PCI_IO_ATTRIBUTE_VGA_IO_16); >> + if (SupportedVgaIo == 0) { >> +Status = EFI_UNSUPPORTED; >> +goto ClosePciIo; >> + } >> + >>// >>// Set new PCI attributes >>// >>Status = Private->PciIo->Attributes ( >> Private->PciIo, >> EfiPciIoAttributeOperationEnable, >> -EFI_PCI_DEVICE_ENABLE | >> EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY | EFI_PCI_IO_ATTRIBUTE_VGA_IO, >> +EFI_PCI_DEVICE_ENABLE | >> EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY | SupportedVgaIo, >> NULL >> ); >>if (EFI_ERROR (Status)) { >> > > Reviewed-by: Laszlo Ersek > > I will keep this patch tagged on my end, so that I can push it once > edk2-stable201905 has been tagged. Should I forget, please ping me. Pushed as commit 662bd0da7fd7. Thanks Laszlo -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41997): https://edk2.groups.io/g/devel/message/41997 Mute This Topic: https://groups.io/mt/31948697/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [edk2-devel] [PATCH 2/2] KabylakeOpenBoardPkg: Switch to FSP Dispatch mode.
Reviewed-by: Nate DeSimone -Original Message- From: Chiu, Chasel Sent: Monday, June 3, 2019 8:04 PM To: devel@edk2.groups.io Cc: Kubacki, Michael A ; Desimone, Nathaniel L ; Gao, Liming Subject: [PATCH 2/2] KabylakeOpenBoardPkg: Switch to FSP Dispatch mode. REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1874 Now KabylakeOpenBoardPkg is building in FSP Dispatch mode as default. Test: Both FSP API and Dispatch mode can boot to Windows. Cc: Michael Kubacki Cc: Nate DeSimone Cc: Liming Gao Signed-off-by: Chasel Chiu --- Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgPcd.dsc | 2 +- Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/build_config.cfg| 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgPcd.dsc b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgPcd.dsc index 63d0c4c2e6..81244d7216 100644 --- a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgPcd.dsc +++ b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgPcd.d +++ sc @@ -32,7 +32,7 @@ # 0: FSP Wrapper is running in Dispatch mode. # 1: FSP Wrapper is running in API mode. # - gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection|1 + gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection|0 !if gMinPlatformPkgTokenSpaceGuid.PcdPerformanceEnable == TRUE gEfiMdePkgTokenSpaceGuid.PcdPerformanceLibraryPropertyMask|0x1 diff --git a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/build_config.cfg b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/build_config.cfg index 64e02f7f48..bf89ea399c 100644 --- a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/build_config.cfg +++ b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/build_config.cfg @@ -27,8 +27,9 @@ TARGET = DEBUG TARGET_SHORT = D PERFORMANCE_BUILD = FALSE FSP_WRAPPER_BUILD = TRUE -FSP_BIN_PKG = KabylakeFspBinPkg -FSP_PKG_NAME = KabylakeFspPkg +FSP_BIN_PKG = AmberLakeFspBinPkg +FSP_BIN_PKG_FOR_API_MODE = KabylakeFspBinPkg FSP_PKG_NAME = +AmberLakeFspPkg FSP_BINARY_BUILD = FALSE FSP_TEST_RELEASE = FALSE SECURE_BOOT_ENABLE = FALSE -- 2.13.3.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41996): https://edk2.groups.io/g/devel/message/41996 Mute This Topic: https://groups.io/mt/31918438/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/2] Platform/Intel: Switch to FSP Dispatch mode.
Reviewed-by: Nate DeSimone -Original Message- From: Chiu, Chasel Sent: Monday, June 3, 2019 8:04 PM To: devel@edk2.groups.io Cc: Kubacki, Michael A ; Desimone, Nathaniel L ; Gao, Liming Subject: [PATCH 1/2] Platform/Intel: Switch to FSP Dispatch mode. REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1874 Build configuration is updated to support different *FspBinPkg between FSP wrapper API and Dispatch modes. Default will be Dispatch mode and to build FSP wrapper for API mode: "py -2 build_bios.py --platform KabylakeRvp3 --fspapi" Cc: Michael Kubacki Cc: Nate DeSimone Cc: Liming Gao Signed-off-by: Chasel Chiu --- Platform/Intel/build_bios.py | 10 ++ 1 file changed, 10 insertions(+) diff --git a/Platform/Intel/build_bios.py b/Platform/Intel/build_bios.py index 9f8d78f6e8..09eceddeff 100644 --- a/Platform/Intel/build_bios.py +++ b/Platform/Intel/build_bios.py @@ -125,6 +125,16 @@ def pre_build(build_config, build_type="DEBUG", silent=False, toolchain=None): config["BASE_TOOLS_PATH"] = config["EDK_TOOLS_PATH"] config["EDK_TOOLS_BIN"] = os.path.join(config["WORKSPACE"], config["EDK_TOOLS_BIN"]) + +# +# Board may have different FSP binary between API and Dispatch modes. +# In API mode if FSP_BIN_PKG_FOR_API_MODE is assigned, it should +# override FSP_BIN_PKG. +# +if config.get("API_MODE_FSP_WRAPPER_BUILD", "FALSE") == "TRUE": +if config.get("FSP_BIN_PKG_FOR_API_MODE") is not None: +config['FSP_BIN_PKG'] = config['FSP_BIN_PKG_FOR_API_MODE'] + config["PLATFORM_FSP_BIN_PACKAGE"] = \ os.path.join(config['WORKSPACE_FSP_BIN'], config['FSP_BIN_PKG']) config['PROJECT_DSC'] = os.path.join(config["WORKSPACE_PLATFORM"], -- 2.13.3.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41995): https://edk2.groups.io/g/devel/message/41995 Mute This Topic: https://groups.io/mt/31918437/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/2] Intel/MinPlatformPkg: Support DXE drivers in FSP 2.1.
The FSP specification allows FSP-S to contain an arbitrary number of Firmware Volumes. Your attached patch makes the assumption that it only contains one. I'm OK if you decide to commit this as-is for now since it is better than nothing, but I expect a Bugzilla to be filed to fix the 1 FV assumption. Reviewed-by: Nate DeSimone -Original Message- From: Chiu, Chasel Sent: Monday, June 3, 2019 5:53 PM To: devel@edk2.groups.io Cc: Chiu, Chasel ; Kubacki, Michael A ; Desimone, Nathaniel L ; Gao, Liming Subject: [PATCH 1/2] Intel/MinPlatformPkg: Support DXE drivers in FSP 2.1. From: "Chasel, Chiu" REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1873 In dispatch mode FSP-S contains DXE drivers so needs to BuildFvHob for DXE dispatcher to dispatch this FV. Test: FSP API mode still boots successfully without impact. Cc: Michael Kubacki Cc: Nate DeSimone Cc: Liming Gao Signed-off-by: Chasel Chiu --- Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobProcessLib/FspWrapperHobProcessLib.c | 19 --- Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobProcessLib/PeiFspWrapperHobProcessLib.inf | 5 - 2 files changed, 20 insertions(+), 4 deletions(-) diff --git a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobProcessLib/FspWrapperHobProcessLib.c b/Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobProcessLib/FspWrapperHobProcessLib.c index e8df06dfb7..7ee4d3a31c 100644 --- a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobProcessLib/FspWrapperHobProcessLib.c +++ b/Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobP +++ rocessLib/FspWrapperHobProcessLib.c @@ -1,7 +1,7 @@ /** @file Provide FSP wrapper hob process related function. -Copyright (c) 2017, Intel Corporation. All rights reserved. +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent **/ @@ -653,8 +653,21 @@ PostFspsHobProcess ( { EFI_STATUS Status; - ProcessFspHobList (FspHobList); - + if (PcdGet8 (PcdFspModeSelection) == 1) { +// +// Only in FSP API mode the wrapper has to build hobs basing on FSP output data. +// +ASSERT (FspHobList != NULL); +ProcessFspHobList (FspHobList); + } else { +// +// Only in FSP Dispatch mode, FSP-S should be reported to DXE dispatcher. +// +BuildFvHob ( + (EFI_PHYSICAL_ADDRESS) (UINTN) PcdGet32 (PcdFlashFvFspSBase), + PcdGet32 (PcdFlashFvFspSSize) + ); + } CheckFspGraphicsDeviceInfoHob (); DEBUG_CODE_BEGIN (); DumpFspSmbiosMemoryInfoHob (); diff --git a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobProcessLib/PeiFspWrapperHobProcessLib.inf b/Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobProcessLib/PeiFspWrapperHobProcessLib.inf index a76e3195d6..64f3302959 100644 --- a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobProcessLib/PeiFspWrapperHobProcessLib.inf +++ b/Platform/Intel/MinPlatformPkg/FspWrapper/Library/PeiFspWrapperHobP +++ rocessLib/PeiFspWrapperHobProcessLib.inf @@ -1,7 +1,7 @@ ## @file # Provide FSP wrapper hob process related function. # -# Copyright (c) 2017, Intel Corporation. All rights reserved. +# Copyright (c) 2017 - 2019, Intel Corporation. All rights +reserved. # # SPDX-License-Identifier: BSD-2-Clause-Patent # @@ -65,6 +65,9 @@ gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress gMinPlatformPkgTokenSpaceGuid.PcdPciExpressRegionLength gMinPlatformPkgTokenSpaceGuid.PcdFspCpuPeiApWakeupBufferAddr + gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection + gMinPlatformPkgTokenSpaceGuid.PcdFlashFvFspSBase + gMinPlatformPkgTokenSpaceGuid.PcdFlashFvFspSSize [Guids] gFspReservedMemoryResourceHobGuid ## CONSUMES ## HOB -- 2.13.3.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41992): https://edk2.groups.io/g/devel/message/41992 Mute This Topic: https://groups.io/mt/31917294/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/2] KabylakeSiliconPkg: FSP 2.1 SEC handling.
Sounds good. Reviewed-by: Nate DeSimone -Original Message- From: Chiu, Chasel Sent: Wednesday, June 5, 2019 11:06 PM To: Desimone, Nathaniel L ; devel@edk2.groups.io Cc: Kubacki, Michael A ; Chaganty, Rangasai V Subject: RE: [edk2-devel] [PATCH 1/2] KabylakeSiliconPkg: FSP 2.1 SEC handling. Yes. I will add TempRamExitPpi.h to IntelFsp2Pkg in separate review later. Bugzilla filed: https://bugzilla.tianocore.org/show_bug.cgi?id=1883 Thanks! Chasel > -Original Message- > From: Desimone, Nathaniel L > Sent: Thursday, June 6, 2019 3:53 AM > To: devel@edk2.groups.io; Chiu, Chasel > Cc: Kubacki, Michael A ; Chaganty, > Rangasai V > Subject: RE: [edk2-devel] [PATCH 1/2] KabylakeSiliconPkg: FSP 2.1 SEC > handling. > > Hi Chasel, > > FSP_TEMP_RAM_EXIT_PPI is defined by the FSP 2.1 specification. The > definition for it should not go in KabyLakeSiliconPkg, it should be > placed in IntelFsp2Pkg/Include/Ppi. > > Thanks, > Nate > > -Original Message- > From: devel@edk2.groups.io On Behalf Of Chiu, > Chasel > Sent: Friday, May 31, 2019 4:43 AM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L > ; Kubacki, Michael A > ; Chaganty, Rangasai V > > Subject: [edk2-devel] [PATCH 1/2] KabylakeSiliconPkg: FSP 2.1 SEC handling. > > From: "Chasel, Chiu" > > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1865 > > To support FSP Dispatch mode, PlatformSecLib should consume > FSP_TEMP_RAM_EXIT_PPI to disable temporary memory. This patch added > the definition of this FSP_TEMP_RAM_EXIT_PPI. > > Test: API mode no impact and can still booted. > > Cc: Nate DeSimone > Cc: Michael A Kubacki > Cc: Sai Chaganty > Signed-off-by: Chasel Chiu > --- > Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/TempRamExitPpi.h | 50 > ++ > Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec| 2 ++ > 2 files changed, 52 insertions(+) > > diff --git > a/Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/TempRamExitPpi.h > b/Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/TempRamExitPpi.h > new file mode 100644 > index 00..9e728a5d4d > --- /dev/null > +++ b/Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/TempRamExitPpi.h > @@ -0,0 +1,50 @@ > +/** @file > + This file defines the Silicon Temp Ram Exit PPI which implements > +the > + required programming steps for disabling temporary memory. > + > +Copyright (c) 2019, Intel Corporation. All rights reserved. > +SPDX-License-Identifier: BSD-2-Clause-Patent > + > +**/ > + > +#ifndef _FSP_TEMP_RAM_EXIT_PPI_H_ > +#define _FSP_TEMP_RAM_EXIT_PPI_H_ > + > +/// > +/// Global ID for the FSP_TEMP_RAM_EXIT_PPI. > +/// > +#define FSP_TEMP_RAM_EXIT_GUID \ > + { \ > +0xbc1cfbdb, 0x7e50, 0x42be, { 0xb4, 0x87, 0x22, 0xe0, 0xa9, 0x0c, > +0xb0, 0x52 } \ > + } > + > +// > +// Forward declaration for the FSP_TEMP_RAM_EXIT_PPI. > +// > +typedef struct _FSP_TEMP_RAM_EXIT_PPI FSP_TEMP_RAM_EXIT_PPI; > + > +/** > + Silicon function for disabling temporary memory. > + @param[in] TempRamExitParamPtr - Pointer to the TempRamExit > +parameters > structure. > + This structure is normally defined in the > Integration > + Guide. If it is not defined in the > Integration Guide, > + pass NULL. > + @retval EFI_SUCCESS- Execution was completed successfully. > + @retval Status - Error status reported by sub-functions if > implemented. > +**/ > +typedef > +EFI_STATUS > +(EFIAPI *FSP_TEMP_RAM_EXIT) ( > + IN VOID*TempRamExitParamPtr > + ); > + > +/// > +/// This PPI provides function to disable temporary memory. > +/// > +struct _FSP_TEMP_RAM_EXIT_PPI { > + FSP_TEMP_RAM_EXIT TempRamExit; > +}; > + > +extern EFI_GUID gFspTempRamExitPpiGuid; > + > +#endif // _FSP_TEMP_RAM_EXIT_PPI_H_ > diff --git a/Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec > b/Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec > index a613079dd4..874cbee7a7 100644 > --- a/Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec > +++ b/Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec > @@ -347,6 +347,8 @@ gPeiTpmInitializationDonePpiGuid = {0xa030d115, > 0x54dd, 0x447b, { 0x90, 0x64, 0x ## gSiPolicyPpiGuid = > {0xaebffa01, 0x7edc, 0x49ff, {0x8d, 0x88, 0xcb, 0x84, 0x8c, 0x5e, > 0x86, 0x70}} gSiPreMemPolicyPpiGuid = {0xc133fe57, 0x17c7, 0x4b09, > {0x8b, 0x3c, 0x97, 0xc1, 0x89, 0xd0, 0xab, 0x8d}} > +gFspTempRamExitPpiGuid = {0xbc1cfbdb, 0x7e50, 0x42be, {0xb4, 0x87, > 0x22, 0xe0, 0xa9, 0x0c, 0xb0, 0x52}} > + > ## > ## SystemAgent > ## > -- > 2.19.1.windows.1 > > > -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41991): https://edk2.groups.io/g/devel/message/41991 Mute This Topic: https://groups.io/mt/31879182/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
Re: [edk2-devel] [PATCH 2/2] KabylakeOpenBoardPkg: Support DefaultPolicyInit PPI.
Reviewed-by: Nate DeSimone -Original Message- From: Chiu, Chasel Sent: Monday, June 3, 2019 9:47 AM To: devel@edk2.groups.io Cc: Chiu, Chasel ; Kubacki, Michael A ; Chaganty, Rangasai V ; Desimone, Nathaniel L Subject: [PATCH 2/2] KabylakeOpenBoardPkg: Support DefaultPolicyInit PPI. From: "Chasel, Chiu" REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1870 Basing on FSP modes the Fsp*WrapperPeim may not have dependency on PolicyPpi, instead it should report FSP-M or FPS-S FV to dispatcher so FSP can produce DefaultPolicyInit PPIs. A PEI policy update library was created to update policy PPI basing on board configuration. Test: Boot with FSP API mode successfully. Cc: Michael A Kubacki Cc: Sai Chaganty Cc: Nate DeSimone Signed-off-by: Chasel Chiu --- Platform/Intel/KabylakeOpenBoardPkg/Policy/Library/PeiSiliconPolicyUpdateLib/PeiSiliconPolicyUpdateLib.c | 564 Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc | 50 ++ Platform/Intel/KabylakeOpenBoardPkg/Policy/Library/PeiSiliconPolicyUpdateLib/PeiSiliconPolicyUpdateLib.inf | 86 ++ 3 files changed, 700 insertions(+) diff --git a/Platform/Intel/KabylakeOpenBoardPkg/Policy/Library/PeiSiliconPolicyUpdateLib/PeiSiliconPolicyUpdateLib.c b/Platform/Intel/KabylakeOpenBoardPkg/Policy/Library/PeiSiliconPolicyUpdateLib/PeiSiliconPolicyUpdateLib.c new file mode 100644 index 00..5cc7c03c61 --- /dev/null +++ b/Platform/Intel/KabylakeOpenBoardPkg/Policy/Library/PeiSiliconPolic +++ yUpdateLib/PeiSiliconPolicyUpdateLib.c @@ -0,0 +1,564 @@ +/** @file + Provides silicon policy update library functions. + +Copyright (c) 2019, Intel Corporation. All rights reserved. +SPDX-License-Identifier: BSD-2-Clause-Patent + +**/ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include #include + #include #include + #include #include + + +/** + Get the next microcode patch pointer. + + @param[in, out] MicrocodeData - Input is a pointer to the last microcode patch address found, + and output points to the next patch address found. + + @retval EFI_SUCCESS - Patch found. + @retval EFI_NOT_FOUND - Patch not found. +**/ +EFI_STATUS +EFIAPI +RetrieveMicrocode ( + IN OUT CPU_MICROCODE_HEADER **MicrocodeData + ) +{ + UINTNMicrocodeStart; + UINTNMicrocodeEnd; + UINTNTotalSize; + + if ((FixedPcdGet32 (PcdFlashMicrocodeFvBase) == 0) || (FixedPcdGet32 (PcdFlashMicrocodeFvSize) == 0)) { +return EFI_NOT_FOUND; + } + + /// + /// Microcode binary in SEC + /// + MicrocodeStart = (UINTN) FixedPcdGet32 (PcdFlashMicrocodeFvBase) + + ((EFI_FIRMWARE_VOLUME_HEADER *) (UINTN) FixedPcdGet32 (PcdFlashMicrocodeFvBase))->HeaderLength + + sizeof (EFI_FFS_FILE_HEADER); + + MicrocodeEnd = (UINTN) FixedPcdGet32 (PcdFlashMicrocodeFvBase) + + (UINTN) FixedPcdGet32 (PcdFlashMicrocodeFvSize); + + if (*MicrocodeData == NULL) { +*MicrocodeData = (CPU_MICROCODE_HEADER *) (UINTN) MicrocodeStart; + } else { +if (*MicrocodeData < (CPU_MICROCODE_HEADER *) (UINTN) MicrocodeStart) { + DEBUG ((DEBUG_INFO, "[CpuPolicy]*MicrocodeData < MicrocodeStart \n")); + return EFI_NOT_FOUND; +} + +TotalSize = (UINTN) ((*MicrocodeData)->TotalSize); +if (TotalSize == 0) { + TotalSize = 2048; +} + +*MicrocodeData = (CPU_MICROCODE_HEADER *) ((UINTN)*MicrocodeData + TotalSize); +if (*MicrocodeData >= (CPU_MICROCODE_HEADER *) (UINTN) (MicrocodeEnd) || (*MicrocodeData)->TotalSize == (UINT32) -1) { + DEBUG ((DEBUG_INFO, "[CpuPolicy]*MicrocodeData >= MicrocodeEnd \n")); + return EFI_NOT_FOUND; +} + } + return EFI_SUCCESS; +} + +/** + Get the microcode patch pointer. + + @retval EFI_PHYSICAL_ADDRESS - Address of the microcode patch, or NULL if not found. +**/ +EFI_PHYSICAL_ADDRESS +PlatformCpuLocateMicrocodePatch ( + VOID + ) +{ + EFI_STATUS Status; + CPU_MICROCODE_HEADER *MicrocodeData; + EFI_CPUID_REGISTER Cpuid; + UINT32 UcodeRevision; + UINTNMicrocodeBufferSize; + VOID
Re: [edk2-devel] [PATCH 1/2] KabylakeSiliconPkg: Support DefaultPolicyInit PPI.
Reviewed-by: Nate DeSimone -Original Message- From: Chiu, Chasel Sent: Monday, June 3, 2019 9:47 AM To: devel@edk2.groups.io Cc: Chiu, Chasel ; Kubacki, Michael A ; Chaganty, Rangasai V ; Desimone, Nathaniel L Subject: [PATCH 1/2] KabylakeSiliconPkg: Support DefaultPolicyInit PPI. From: "Chasel, Chiu" REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1870 FSP in dispatch mode will produce DefaultPolicyInit PPI for boot loader to consume and install policy with default settings built-in by FSP. Boot loader then may patch policy with per-board settings and then install PolicyReady PPI to start silicon initialization (policy consumer code) Since different version FSP has different version policy structure, the policy revision check code has been extended to support newer revision policy and the policy structure boot loader consuming has been aligned with the same structure inside FSP. (FSP will maintain policy structure backward compatibility) Also removed microcode location searching code from silicon scope because silicon code should not access hard-coded flash region unconditionally. This should be done by platform/boot loader side. Cc: Michael A Kubacki Cc: Sai Chaganty Cc: Nate DeSimone Signed-off-by: Chasel Chiu --- Silicon/Intel/KabylakeSiliconPkg/Cpu/Library/PeiCpuPolicyLib/PeiCpuPolicyLib.c | 133 +++-- Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiPolicyLib/PeiSiPolicyLib.c | 53 - Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiPolicyLib/PeiSiPolicyLibPreMem.c | 50 ++ Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLib/PeiPolicyInit.c | 32 +--- Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLib/PeiPolicyInitPreMem.c | 39 +++ Silicon/Intel/KabylakeSiliconPkg/Me/Library/PeiMePolicyLib/PeiMePolicyLib.c | 6 +++--- Silicon/Intel/KabylakeSiliconPkg/SystemAgent/Library/DxeSaPolicyLib/DxeSaPolicyLib.c | 4 ++-- Silicon/Intel/KabylakeSiliconPkg/SystemAgent/Library/PeiSaPolicyLib/SaPrintPolicy.c | 14 +++--- Silicon/Intel/KabylakeSiliconPkg/Cpu/Include/CpuDataStruct.h | 4 +++- Silicon/Intel/KabylakeSiliconPkg/Cpu/Library/PeiCpuPolicyLib/PeiCpuPolicyLibrary.h | 4 +--- Silicon/Intel/KabylakeSiliconPkg/Include/Library/SiPolicyLib.h | 32 Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/PeiPreMemSiDefaultPolicyInit.h | 36 Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/PeiSiDefaultPolicyInit.h | 36 Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiPolicyLib/PeiSiPolicyLib.inf | 8 +--- Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLib/PeiPolicyInit.h | 4 +++- Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLib/PeiPostMemSiliconPolicyInitLib.inf | 75 +++ Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLib/{PeiSiliconPolicyInitLib.inf => PeiPreMemSiliconPolicyInitLib.inf} | 11 --- Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFsp.inf | 5 +++-- Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFspAml.inf | 1 + Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec | 4 Silicon/Intel/KabylakeSiliconPkg/SystemAgent/Include/ConfigBlock/GraphicsPeiConfig.h | 16 ++-- Silicon/Intel/KabylakeSiliconPkg/SystemAgent/Library/PeiSaPolicyLib/PeiSaPolicyLib.inf | 3 ++- 22 files changed, 384
Re: [edk2-devel] [RFC PATCH 0/2] BaseTools: add script to set up git environment
Hi Bob, Ah, that is a very good point. Yes, I will do that for v2. Thanks!, Leif On Wed, Jun 05, 2019 at 10:37:31AM +, Feng, Bob C wrote: > Hi Leif, > > https://github.com/tianocore/tianocore.github.io/wiki/Laszlo's-unkempt-git-guide-for-edk2-contributors-and-maintainers > is a great resource. It's very useful. > > I tested this scripts. I found a minor issue that I have a local edk2 repo > which was cloned by the command: "git clone > https://github.com/tianocore/edk2; not "git clone > https://github.com/tianocore/edk2.git; and when I run this script, it > reported "Unknown upstream ". > > The script works well if the git url is https://github.com/tianocore/edk2.git > > So would you update the script to support the url with or without the ".git" > suffix? > > > Thanks, > Bob > > -Original Message- > From: Leif Lindholm [mailto:leif.lindh...@linaro.org] > Sent: Friday, May 31, 2019 12:00 AM > To: devel@edk2.groups.io > Cc: Feng, Bob C ; Gao, Liming ; > Zhu, Yonghong ; Andrew Fish ; Laszlo > Ersek ; Kinney, Michael D > Subject: [RFC PATCH 0/2] BaseTools: add script to set up git environment > > https://github.com/tianocore/tianocore.github.io/wiki/Laszlo's-unkempt-git-guide-for-edk2-contributors-and-maintainers > is a great resource, but it's a lot of manual steps to go through for each > repository (especially as the number seems to grow). > > Script works with python2/3 under both Posix and Windows. > > Note: the script does require the 'gitpython' module to be installed. > Under Linux, this can be achieved with your distribution package manager. > Under Windows, you can install this from the Visual Studio python > environment->packages (pypi), and searching for 'gitpython'. > > Note2: for simplicity's sake, the script uses a single copy of the > configuration files for each repository - pointing all of them to the copies > in edk2 BaseTools. > > Note3: we're hardcoding absolute paths here, so if you move repositories > around, you need to re-run the script. > > Note4: all of the settings are done only on a per-repository basis, so as not > to mess with environments for unlelated projects. This also means many > settings that are common across all repositories are set in each of them. > > Note4: the script identifies repositories based on their 'origin' URL, so if > someone had a good use-case for something cute, there may be more work > required. > > > Future plans: > It would be useful to also add common git-hook scripts to install. > I already have some for my own maintainer use. > > Even though we only modify settings for the current repository, it would also > make sense to add some sanity checking for global settings (name, email, mail > server config...). > > Leif Lindholm (2): > BaseTools: add centralized location for git config files > BaseTools: add script to configure local git options > > BaseTools/Conf/diff.order | 8 ++ > BaseTools/Conf/gitattributes | 14 BaseTools/Scripts/SetupGit.py | > 187 ++ > 3 files changed, 209 insertions(+) > create mode 100644 BaseTools/Conf/diff.order create mode 100644 > BaseTools/Conf/gitattributes create mode 100644 BaseTools/Scripts/SetupGit.py > > -- > 2.11.0 > -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41988): https://edk2.groups.io/g/devel/message/41988 Mute This Topic: https://groups.io/mt/31870254/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [edk2-devel] Printing git commit in build
On 06/06/19 07:38, Udit Kumar wrote: > Dear Community, > > I like to print git commit id, which printing UEFI firmware build > information. > Could you help, how I can collect ' git describe' information in C file. I think you should be able to do this in the PREBUILD hook in the DSC file. (Run "git describe" in a script for generating a simple C source file.) Another option would be to introduce a PCD in your platform package DEC file, with datum type (VOID*) and access method FixedAtBuild. For example: [PcdsFixedAtBuild] gMyPlatformPkgTokenSpaceGuid.PcdBuildIdentifier|""|VOID*| and when you build your platform DSC, you could pass the following option to the "build" utility: --pcd=gMyPlatformPkgTokenSpaceGuid.PcdBuildIdentifier="$(git describe)" Thanks Laszlo -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41987): https://edk2.groups.io/g/devel/message/41987 Mute This Topic: https://groups.io/mt/31948238/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] OvmfPkg/QemuVideoDxe: Shouldn't assume system in VGA alias mode.
On 06/06/19 09:42, Marc W Chen wrote: > Query the supported attributes firstly, then bitwise AND (&) both VGA_IO > and VGA_IO_16. Since the supported attributes should only have one of > VGA_IO or VGA_IO_16 set, the result of bitwise AND (&) is either VGA_IO > or IO_16. Then the result can be passed to PciIo->Attributes() to set the > attributes. > > Device driver should consider both since the mReserveVgaAliases in > PciBusDxe driver is default FALSE(implies that device driver can only set > VGA_IO_16 to PCI_ROOT_BRIDGE), and Platform code may not return > EFI_RESERVE_VGA_IO_ALIAS in GetPlatformPolicy of PciPlatformProtocol to > make mReserveVgaAliases become TRUE(implies that device driver can only > set VGA_IO to PCI_ROOT_BRIDGE), Currently OvmfPkg doesn't have problem > due to it has hard code value for PCI_ROOT_BRIDGE's attributes field, so > an IO access by PciIoProtocol will be successed due to > RootBridgeIoCheckParameter of PciRootBridgeIo.c will always get pass > result for legacy IO access. > > Usually the attributes field of PCI_ROOT_BRIDGE should be 0, in that case > it will have issue since the VGA_IO may not be able to be enabled, then > IO access by PciIoProtocol will be failed, hence the QemuVideoDxe driver > will not work fine. > > Signed-off-by: Marc Chen > Cc: Jordan Justen > Cc: Laszlo Ersek > Cc: Ard Biesheuvel > Cc: Anthony Perard > Cc: Julien Grall > Cc: Marc-André Lureau > Cc: Stefan Berger > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1880 > --- > OvmfPkg/QemuVideoDxe/Driver.c | 22 +- > 1 file changed, 21 insertions(+), 1 deletion(-) > > diff --git a/OvmfPkg/QemuVideoDxe/Driver.c b/OvmfPkg/QemuVideoDxe/Driver.c > index e8a613ef33..522110ef4e 100644 > --- a/OvmfPkg/QemuVideoDxe/Driver.c > +++ b/OvmfPkg/QemuVideoDxe/Driver.c > @@ -201,6 +201,7 @@ QemuVideoControllerDriverStart ( >PCI_TYPE00Pci; >QEMU_VIDEO_CARD *Card; >EFI_PCI_IO_PROTOCOL *ChildPciIo; > + UINT64SupportedVgaIo; > >OldTpl = gBS->RaiseTPL (TPL_CALLBACK); > > @@ -277,13 +278,32 @@ QemuVideoControllerDriverStart ( > goto ClosePciIo; >} > > + // > + // Get supported PCI attributes > + // > + Status = Private->PciIo->Attributes ( > + Private->PciIo, > + EfiPciIoAttributeOperationSupported, > + 0, > + > + ); > + if (EFI_ERROR (Status)) { > +goto ClosePciIo; > + } > + > + SupportedVgaIo &= (UINT64)(EFI_PCI_IO_ATTRIBUTE_VGA_IO | > EFI_PCI_IO_ATTRIBUTE_VGA_IO_16); > + if (SupportedVgaIo == 0) { > +Status = EFI_UNSUPPORTED; > +goto ClosePciIo; > + } > + >// >// Set new PCI attributes >// >Status = Private->PciIo->Attributes ( > Private->PciIo, > EfiPciIoAttributeOperationEnable, > -EFI_PCI_DEVICE_ENABLE | > EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY | EFI_PCI_IO_ATTRIBUTE_VGA_IO, > +EFI_PCI_DEVICE_ENABLE | > EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY | SupportedVgaIo, > NULL > ); >if (EFI_ERROR (Status)) { > Reviewed-by: Laszlo Ersek I will keep this patch tagged on my end, so that I can push it once edk2-stable201905 has been tagged. Should I forget, please ping me. Thanks Laszlo -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41986): https://edk2.groups.io/g/devel/message/41986 Mute This Topic: https://groups.io/mt/31948697/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [edk2-devel] Help needed in building UEFI qcow2 images
Hi Pavan, On 06/05/19 20:19, Pavan Kumar Aravapalli wrote: > Laszlo, > > Finally...! I am successfully able to boot guest vm in secure mode, attached > the screenshot for the same. Secure boot works fine with out enforcing keys > from UefiShell.iso, As suggested i have used the image > fedora-29-efi-grub2-x86_64.qcow2.xz. However i have learnt many new things > from these conversations. A big 'Thanks to you' for your support and > resolving my questionaries. > > Though I am yet to learn many things about 'UEFI' and it's different > specification this will be good motivation for me to proceed with further. Cool, thanks for reporting back :) Laszlo -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41983): https://edk2.groups.io/g/devel/message/41983 Mute This Topic: https://groups.io/mt/31718606/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[edk2-devel] [PATCH v2] OvmfPkg/QemuVideoDxe: Shouldn't assume system in VGA alias mode.
Query the supported attributes firstly, then bitwise AND (&) both VGA_IO and VGA_IO_16. Since the supported attributes should only have one of VGA_IO or VGA_IO_16 set, the result of bitwise AND (&) is either VGA_IO or IO_16. Then the result can be passed to PciIo->Attributes() to set the attributes. Device driver should consider both since the mReserveVgaAliases in PciBusDxe driver is default FALSE(implies that device driver can only set VGA_IO_16 to PCI_ROOT_BRIDGE), and Platform code may not return EFI_RESERVE_VGA_IO_ALIAS in GetPlatformPolicy of PciPlatformProtocol to make mReserveVgaAliases become TRUE(implies that device driver can only set VGA_IO to PCI_ROOT_BRIDGE), Currently OvmfPkg doesn't have problem due to it has hard code value for PCI_ROOT_BRIDGE's attributes field, so an IO access by PciIoProtocol will be successed due to RootBridgeIoCheckParameter of PciRootBridgeIo.c will always get pass result for legacy IO access. Usually the attributes field of PCI_ROOT_BRIDGE should be 0, in that case it will have issue since the VGA_IO may not be able to be enabled, then IO access by PciIoProtocol will be failed, hence the QemuVideoDxe driver will not work fine. Signed-off-by: Marc Chen Cc: Jordan Justen Cc: Laszlo Ersek Cc: Ard Biesheuvel Cc: Anthony Perard Cc: Julien Grall Cc: Marc-André Lureau Cc: Stefan Berger Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1880 --- OvmfPkg/QemuVideoDxe/Driver.c | 22 +- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/OvmfPkg/QemuVideoDxe/Driver.c b/OvmfPkg/QemuVideoDxe/Driver.c index e8a613ef33..522110ef4e 100644 --- a/OvmfPkg/QemuVideoDxe/Driver.c +++ b/OvmfPkg/QemuVideoDxe/Driver.c @@ -201,6 +201,7 @@ QemuVideoControllerDriverStart ( PCI_TYPE00Pci; QEMU_VIDEO_CARD *Card; EFI_PCI_IO_PROTOCOL *ChildPciIo; + UINT64SupportedVgaIo; OldTpl = gBS->RaiseTPL (TPL_CALLBACK); @@ -277,13 +278,32 @@ QemuVideoControllerDriverStart ( goto ClosePciIo; } + // + // Get supported PCI attributes + // + Status = Private->PciIo->Attributes ( + Private->PciIo, + EfiPciIoAttributeOperationSupported, + 0, + + ); + if (EFI_ERROR (Status)) { +goto ClosePciIo; + } + + SupportedVgaIo &= (UINT64)(EFI_PCI_IO_ATTRIBUTE_VGA_IO | EFI_PCI_IO_ATTRIBUTE_VGA_IO_16); + if (SupportedVgaIo == 0) { +Status = EFI_UNSUPPORTED; +goto ClosePciIo; + } + // // Set new PCI attributes // Status = Private->PciIo->Attributes ( Private->PciIo, EfiPciIoAttributeOperationEnable, -EFI_PCI_DEVICE_ENABLE | EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY | EFI_PCI_IO_ATTRIBUTE_VGA_IO, +EFI_PCI_DEVICE_ENABLE | EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY | SupportedVgaIo, NULL ); if (EFI_ERROR (Status)) { -- 2.16.2.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41984): https://edk2.groups.io/g/devel/message/41984 Mute This Topic: https://groups.io/mt/31948697/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/2] KabylakeSiliconPkg: FSP 2.1 SEC handling.
Yes. I will add TempRamExitPpi.h to IntelFsp2Pkg in separate review later. Bugzilla filed: https://bugzilla.tianocore.org/show_bug.cgi?id=1883 Thanks! Chasel > -Original Message- > From: Desimone, Nathaniel L > Sent: Thursday, June 6, 2019 3:53 AM > To: devel@edk2.groups.io; Chiu, Chasel > Cc: Kubacki, Michael A ; Chaganty, Rangasai V > > Subject: RE: [edk2-devel] [PATCH 1/2] KabylakeSiliconPkg: FSP 2.1 SEC > handling. > > Hi Chasel, > > FSP_TEMP_RAM_EXIT_PPI is defined by the FSP 2.1 specification. The definition > for it should not go in KabyLakeSiliconPkg, it should be placed in > IntelFsp2Pkg/Include/Ppi. > > Thanks, > Nate > > -Original Message- > From: devel@edk2.groups.io On Behalf Of Chiu, > Chasel > Sent: Friday, May 31, 2019 4:43 AM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L > ; Kubacki, Michael A > ; Chaganty, Rangasai V > > Subject: [edk2-devel] [PATCH 1/2] KabylakeSiliconPkg: FSP 2.1 SEC handling. > > From: "Chasel, Chiu" > > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1865 > > To support FSP Dispatch mode, PlatformSecLib should consume > FSP_TEMP_RAM_EXIT_PPI to disable temporary memory. This patch added the > definition of this FSP_TEMP_RAM_EXIT_PPI. > > Test: API mode no impact and can still booted. > > Cc: Nate DeSimone > Cc: Michael A Kubacki > Cc: Sai Chaganty > Signed-off-by: Chasel Chiu > --- > Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/TempRamExitPpi.h | 50 > ++ > Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec| 2 ++ > 2 files changed, 52 insertions(+) > > diff --git a/Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/TempRamExitPpi.h > b/Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/TempRamExitPpi.h > new file mode 100644 > index 00..9e728a5d4d > --- /dev/null > +++ b/Silicon/Intel/KabylakeSiliconPkg/Include/Ppi/TempRamExitPpi.h > @@ -0,0 +1,50 @@ > +/** @file > + This file defines the Silicon Temp Ram Exit PPI which implements the > + required programming steps for disabling temporary memory. > + > +Copyright (c) 2019, Intel Corporation. All rights reserved. > +SPDX-License-Identifier: BSD-2-Clause-Patent > + > +**/ > + > +#ifndef _FSP_TEMP_RAM_EXIT_PPI_H_ > +#define _FSP_TEMP_RAM_EXIT_PPI_H_ > + > +/// > +/// Global ID for the FSP_TEMP_RAM_EXIT_PPI. > +/// > +#define FSP_TEMP_RAM_EXIT_GUID \ > + { \ > +0xbc1cfbdb, 0x7e50, 0x42be, { 0xb4, 0x87, 0x22, 0xe0, 0xa9, 0x0c, > +0xb0, 0x52 } \ > + } > + > +// > +// Forward declaration for the FSP_TEMP_RAM_EXIT_PPI. > +// > +typedef struct _FSP_TEMP_RAM_EXIT_PPI FSP_TEMP_RAM_EXIT_PPI; > + > +/** > + Silicon function for disabling temporary memory. > + @param[in] TempRamExitParamPtr - Pointer to the TempRamExit parameters > structure. > + This structure is normally defined in the > Integration > + Guide. If it is not defined in the > Integration Guide, > + pass NULL. > + @retval EFI_SUCCESS- Execution was completed successfully. > + @retval Status - Error status reported by sub-functions if > implemented. > +**/ > +typedef > +EFI_STATUS > +(EFIAPI *FSP_TEMP_RAM_EXIT) ( > + IN VOID*TempRamExitParamPtr > + ); > + > +/// > +/// This PPI provides function to disable temporary memory. > +/// > +struct _FSP_TEMP_RAM_EXIT_PPI { > + FSP_TEMP_RAM_EXIT TempRamExit; > +}; > + > +extern EFI_GUID gFspTempRamExitPpiGuid; > + > +#endif // _FSP_TEMP_RAM_EXIT_PPI_H_ > diff --git a/Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec > b/Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec > index a613079dd4..874cbee7a7 100644 > --- a/Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec > +++ b/Silicon/Intel/KabylakeSiliconPkg/SiPkg.dec > @@ -347,6 +347,8 @@ gPeiTpmInitializationDonePpiGuid = {0xa030d115, > 0x54dd, 0x447b, { 0x90, 0x64, 0x ## gSiPolicyPpiGuid = {0xaebffa01, > 0x7edc, > 0x49ff, {0x8d, 0x88, 0xcb, 0x84, 0x8c, 0x5e, 0x86, 0x70}} > gSiPreMemPolicyPpiGuid = {0xc133fe57, 0x17c7, 0x4b09, {0x8b, 0x3c, 0x97, 0xc1, > 0x89, 0xd0, 0xab, 0x8d}} > +gFspTempRamExitPpiGuid = {0xbc1cfbdb, 0x7e50, 0x42be, {0xb4, 0x87, > 0x22, 0xe0, 0xa9, 0x0c, 0xb0, 0x52}} > + > ## > ## SystemAgent > ## > -- > 2.19.1.windows.1 > > > -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#41981): https://edk2.groups.io/g/devel/message/41981 Mute This Topic: https://groups.io/mt/31879182/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-