]> git.proxmox.com Git - mirror_edk2.git/log
mirror_edk2.git
7 years agoIntelSiliconPkg: Add Intel Firmware Version Info (FVI) definitions
Giri P Mudusuru [Wed, 12 Oct 2016 05:13:56 +0000 (22:13 -0700)]
IntelSiliconPkg: Add Intel Firmware Version Info (FVI) definitions

Adding Intel Firmware Version Info (FVI) related defines & structures.
FVI enables reporting the Firmware Versions using SMBIOS OEM Type.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Giri P Mudusuru <giri.p.mudusuru@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
7 years agoNetworkPkg: Record user configured TargetIP/Port in iBFT
Ye Ting [Thu, 29 Sep 2016 05:52:05 +0000 (13:52 +0800)]
NetworkPkg: Record user configured TargetIP/Port in iBFT

Current ISCSI driver records redirected iSCSI targetIP/Port in iBFT
once redirection occurs, which removes the possibility of the OS
to reconnect to the configured IP for load balancing. The behavior
is not explicitly described in IBFT spec, though the MSFT expert
confirm we should record original user setting rather than
publish the redirected IP.

Thanks Sriram for reviewing and validating this patch in his test-bed.

Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Cc: Zhang Lubo <lubo.zhang@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ye Ting <ting.ye@intel.com>
Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
Reviewed-by: Subramanian Sriram <sriram-s@hpe.com>
7 years agoIntelFsp2Pkg/FspSecCore: Make FSP functions position independent
Maurice Ma [Thu, 13 Oct 2016 01:00:44 +0000 (18:00 -0700)]
IntelFsp2Pkg/FspSecCore: Make FSP functions position independent

The current AsmGetFspInfoHeader function in FspHeader.nasm is
position dependent code since it uses absolute address. Change
to use relative address instead to make it position independent.

Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Giri P Mudusuru <giri.p.mudusuru@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Maurice Ma <maurice.ma@intel.com>
Reviewed-by: Giri P Mudusuru <giri.p.mudusuru@intel.com>
7 years agoShellPkg/UefiShellTftpCommandLib: Update TFTP help text
Thomas Palmer [Wed, 12 Oct 2016 20:14:34 +0000 (13:14 -0700)]
ShellPkg/UefiShellTftpCommandLib: Update TFTP help text

Clear up some help text for the TFTP shell command

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Thomas Palmer <thomas.palmer@hpe.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
7 years agoBaseTools/GenFds: Support FDF sections in any order
Michael Kinney [Fri, 7 Oct 2016 21:07:03 +0000 (14:07 -0700)]
BaseTools/GenFds: Support FDF sections in any order

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

This patch updates EDK II FDF parser in GenFds to allow sections
to be placed in any order in the FDF file.

Cc: Kelly Steele <kelly.steele@intel.com>
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
7 years agoShellPkg:?cd \? command fails to go back to the root directory of a file system
Tapan Shah [Fri, 7 Oct 2016 20:59:34 +0000 (13:59 -0700)]
ShellPkg:?cd \? command fails to go back to the root directory of a file system

Allows cd command to go back to the root directory when 'cd \' executed in system.

This change prevents last PathRemoveLastItem() call which truncates '\' from 'fs0:\'
in desired root path which is required to set CWD to the root directory.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Tapan Shah <tapandshah@hpe.com>
Reviewed-by: Jaben Carsey <Jaben.carsey@intel.com>
7 years agoMdeModulePkg RegularExpressionDxe: Add the missing EFIAPI for the function
Liming Gao [Sun, 9 Oct 2016 02:20:30 +0000 (10:20 +0800)]
MdeModulePkg RegularExpressionDxe: Add the missing EFIAPI for the function

The function with the variable parameters should have EFIAPI.

Cc: Feng Tian <feng.tian@intel.com>
Cc: Cinnamon Shia <cinnamon.shia@hpe.com>
Cc: Cecil Sheng <cecil.sheng@hpe.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
7 years agoDuetPkg DxeIpl and EfiLdr: Add the missing EFIAPI for the function
Liming Gao [Tue, 11 Oct 2016 01:44:07 +0000 (09:44 +0800)]
DuetPkg DxeIpl and EfiLdr: Add the missing EFIAPI for the function

The function with the variable parameters should have EFIAPI.

Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoIntelSiliconPkg: Fixing syntax bug in IGD_OPREGION_HEADER
Giri P Mudusuru [Wed, 12 Oct 2016 04:58:46 +0000 (21:58 -0700)]
IntelSiliconPkg: Fixing syntax bug in IGD_OPREGION_HEADER

Added missing ; for DVER in IGD_OPREGION_HEADER

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Giri P Mudusuru <giri.p.mudusuru@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
7 years agoMdeModulePkg/MdeModulePkg.dec: Fix EBC build failure of PciBus driver
Ruiyu Ni [Tue, 11 Oct 2016 05:00:48 +0000 (13:00 +0800)]
MdeModulePkg/MdeModulePkg.dec: Fix EBC build failure of PciBus driver

When PciBus is built as EBC, PcdPciDegradeResourceForOptionRom does
not have associated value resulting build failure.
The patch sets the default value to TRUE, covering the EBC ARCH.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Acked-by: Laszlo Ersek <lersek@redhat.com>
Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Feng Tian <feng.tian@intel.com>
7 years agoNetworkPkg: Remove redundant code in HTTP boot driver.
Fu Siyuan [Tue, 13 Sep 2016 02:25:27 +0000 (10:25 +0800)]
NetworkPkg: Remove redundant code in HTTP boot driver.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Fu Siyuan <siyuan.fu@intel.com>
Reviewed-by: Sriram Subramanian <sriram-s@hpe.com>
Reviewed-by: Wu Jiaxin <jiaxin.wu@intel.com>
Reviewed-by: Zhang Lubo <lubo.zhang@intel.com>
7 years agoArmPlatformPkg/ArmJunoPkg/Drivers/PciHostBridgeDxe: Fix for PCI Dual Address Cycle
Daniil Egranov [Thu, 22 Sep 2016 22:33:01 +0000 (17:33 -0500)]
ArmPlatformPkg/ArmJunoPkg/Drivers/PciHostBridgeDxe: Fix for PCI Dual Address Cycle

The fix handles the PCI Dual Address Cycle Attribute case. It allows
drivers using PCI DAC run on Juno.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Daniil Egranov <daniil.egranov@arm.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Tested-by: Ryan Harkin <ryan.harkin@linaro.org>
7 years agoOvmfPkg: add NOOPT build target for source level debugging
Bruce Cran [Mon, 10 Oct 2016 15:43:24 +0000 (09:43 -0600)]
OvmfPkg: add NOOPT build target for source level debugging

Contributed-under: TianoCore Contribution Agreement 1.0
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Signed-off-by: Bruce Cran <bruce.cran@sandisk.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
[lersek@redhat.com: beautify subject line]
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
7 years agoSecurityPkg OpalPasswordSmm: Fix S3 resume failure.
Eric Dong [Tue, 11 Oct 2016 08:00:21 +0000 (16:00 +0800)]
SecurityPkg OpalPasswordSmm: Fix S3 resume failure.

Changes includes:
1.Check SMM device list before update it to avoid duplicate creation.
2.Clean up the configuration buffer before use it in S3 resume phase.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
7 years agoBaseTools: Extend FMP to support FV statement and FD statement
Yonghong Zhu [Sun, 9 Oct 2016 01:30:06 +0000 (09:30 +0800)]
BaseTools: Extend FMP to support FV statement and FD statement

This patch extend the <FmpFileData> to support <FvStatements> and
<FdStatenents>, just like the normal [Capsule] section format.
In order to fix the bug https://bugzilla.tianocore.org/show_bug.cgi?id=132

Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
7 years agoArmVirtPkg: Remove unused BltLib reference
Ruiyu Ni [Tue, 11 Oct 2016 05:43:28 +0000 (13:43 +0800)]
ArmVirtPkg: Remove unused BltLib reference

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Laszlo Ersek <lersek at redhat.com>
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
7 years agoOvmfPkg: Remove unused BltLib reference
Ruiyu Ni [Tue, 11 Oct 2016 05:42:24 +0000 (13:42 +0800)]
OvmfPkg: Remove unused BltLib reference

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek at redhat.com>
7 years agoOvmfPkg: QemuVideoDxe uses MdeModulePkg/FrameBufferLib
Ruiyu Ni [Tue, 11 Oct 2016 05:26:27 +0000 (13:26 +0800)]
OvmfPkg: QemuVideoDxe uses MdeModulePkg/FrameBufferLib

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Laszlo Ersek <lersek at redhat.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
7 years agoArmVirtPkg: Include MdeModulePkg/FrameBufferLib in ArmVirtPkg
Ruiyu Ni [Tue, 11 Oct 2016 05:24:23 +0000 (13:24 +0800)]
ArmVirtPkg: Include MdeModulePkg/FrameBufferLib in ArmVirtPkg

One of the following patches will change QemuVideoDxe driver
to use the new FrameBufferLib.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Laszlo Ersek <lersek at redhat.com>
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
7 years agoOvmfPkg: Include MdeModulePkg/FrameBufferLib in OvmfPkg
Ruiyu Ni [Mon, 27 Jun 2016 09:28:54 +0000 (17:28 +0800)]
OvmfPkg: Include MdeModulePkg/FrameBufferLib in OvmfPkg

One of the following patches will change QemuVideoDxe driver
to use the new FrameBufferLib.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Laszlo Ersek <lersek at redhat.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
7 years agoMdeModulePkg: Add GraphicsOutputDxe driver.
Ruiyu Ni [Thu, 30 Jun 2016 05:01:56 +0000 (13:01 +0800)]
MdeModulePkg: Add GraphicsOutputDxe driver.

The driver uses the GraphicsInfo HOB and GraphicsDeviceInfo HOB
passed from PEI to find the graphics controller to manage and
produce the GraphicsOutput protocol.

GraphicsInfo HOB and GraphicsDeviceInfo HOB are created by
a PEIM which initializes the graphics controller hardware in
PEI phase.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
7 years agoMdeModulePkg: Add FrameBufferBltLib library instance
Ruiyu Ni [Thu, 7 Jul 2016 05:31:27 +0000 (13:31 +0800)]
MdeModulePkg: Add FrameBufferBltLib library instance

This library provides interfaces to perform UEFI Graphics
Output Protocol Video BLT operations.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Cc: Justen Jordan <jordan.l.justen@intel.com>
Tested-by: Laszlo Ersek <lersek at redhat.com>
7 years agoMdeModulePkg: Add FrameBufferBltLib library class
Ruiyu Ni [Thu, 30 Jun 2016 02:59:42 +0000 (10:59 +0800)]
MdeModulePkg: Add FrameBufferBltLib library class

This library provides interfaces to perform UEFI Graphics
Output Protocol Video BLT operations.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Cc: Justen Jordan <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
7 years agoMdePkg/GraphicsInfoHob: Add GraphicsDeviceInfo HOB GUID and structure
Ruiyu Ni [Wed, 29 Jun 2016 01:53:27 +0000 (09:53 +0800)]
MdePkg/GraphicsInfoHob: Add GraphicsDeviceInfo HOB GUID and structure

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
7 years agoFatPkg/FatPei: Use PcdRecoveryFileName PCD.
Jiewen Yao [Sat, 8 Oct 2016 01:55:59 +0000 (09:55 +0800)]
FatPkg/FatPei: Use PcdRecoveryFileName PCD.

This PCD is used to indicated the recovery file name.
The previous name - FvMain.Fv is hardcoded in FatPei.
It does not make sense to force the name.

Now a platform may use any recovery file name.

Tested-by: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Feng Tian <feng.tian@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
7 years agoMdeModulePkg/CdExpressPei: Use PcdRecoveryFileName PCD.
Jiewen Yao [Sat, 8 Oct 2016 01:55:20 +0000 (09:55 +0800)]
MdeModulePkg/CdExpressPei: Use PcdRecoveryFileName PCD.

This PCD is used to indicated the recovery file name.
The previous name - FvMain.Fv is hardcoded in CdExpressPei.
It does not make sense to force the name.

Now a platform may use any recovery file name.

Cc: Feng Tian <feng.tian@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
7 years agoMdeModulePkg/dec: Add PcdRecoveryFileName PCD.
Jiewen Yao [Sat, 8 Oct 2016 01:54:33 +0000 (09:54 +0800)]
MdeModulePkg/dec: Add PcdRecoveryFileName PCD.

This PCD is used to indicated the recovery file name.
The previous name - FvMain.Fv is hardcoded in FatPei and CdExpressPei.
It does not make sense to force the name.

Now a platform may use any recovery file name.

Tested-by: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Feng Tian <feng.tian@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
7 years agoBaseTools: support the NOOPT target with the GCC tool chains
Yonghong Zhu [Fri, 30 Sep 2016 07:30:59 +0000 (15:30 +0800)]
BaseTools: support the NOOPT target with the GCC tool chains

Update the tools_def.template to add NOOPT support with GCC tool chains.
Also disable -flto and -Os in NOOPT target for GCC5.

Cc: Liming Gao <liming.gao@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Tested-by: Bruce Cran <bruce.cran@sandisk.com>
7 years agoArmPlatformPkg: Remove UINTN cast when setting BaudRate.
Alexei [Wed, 21 Sep 2016 20:33:15 +0000 (21:33 +0100)]
ArmPlatformPkg: Remove UINTN cast when setting BaudRate.

SerialPortInitialize() set the BaudRate variable (type UINT64) as:
BaudRate = (UINTN)FixedPcdGet64 (PcdUartDefaultBaudRate);

This commit fixes a potential problem on ARM 32-bit builds, where the
UINTN type is defined as UINT32, by removing the cast:

BaudRate = FixedPcdGet64 (PcdUartDefaultBaudRate);

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Alexei Fedorov <alexei.fedorov@arm.com>
Signed-off-by: Evan Lloyd <evan.lloyd@arm.com>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
7 years agoArmPlatformPkg: Correct mendacious comments.
Alexei [Wed, 21 Sep 2016 20:33:14 +0000 (21:33 +0100)]
ArmPlatformPkg: Correct mendacious comments.

Correct some obviously incorrect comments that have invalid details for
the returned values.  (Copy /Paste problem?)
There are no functional changes in this commit.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Alexei Fedorov <alexei.fedorov@arm.com>
Signed-off-by: Evan Lloyd <evan.lloyd@arm.com>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
7 years agoArmPlatformPkg: Fix PL011 FIFO size test
Evan Lloyd [Wed, 21 Sep 2016 20:33:13 +0000 (21:33 +0100)]
ArmPlatformPkg: Fix PL011 FIFO size test

This change updates PL011UartInitializePort to compare ReceiveFifoDepth
with the correct hardware FIFO size instead of the constant 32 used
previously.
This corrects a minor bug where a request for a fifo size > 15 and < 32
would not have been honoured on a system with a 16 byte FIFO.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
Signed-off-by: Evan Lloyd <evan.lloyd@arm.com>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
7 years agoPcAtChipsetPkg AcpiTimerLib: Clear bits [31:24] after reading by IoRead32()
Star Zeng [Wed, 28 Sep 2016 10:17:55 +0000 (18:17 +0800)]
PcAtChipsetPkg AcpiTimerLib: Clear bits [31:24] after reading by IoRead32()

Clear bits [31:24] after reading ACPI timer count by IoRead32(), and also add
comments "Note: The implementation uses the lower 24-bits of the ACPI timer
and is compatible with both 24-bit and 32-bit ACPI timers." in INF.

Cc: Michael Kinney <michael.d.kinney@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
7 years agoNt32Pkg WinNtSimpleFileSystemDxe: Correct file length.
Dong, Eric [Mon, 10 Oct 2016 08:36:18 +0000 (16:36 +0800)]
Nt32Pkg WinNtSimpleFileSystemDxe: Correct file length.

In GetInfo interface, current code copy real file name buffer
with full path file length. It should use real file name
length. This patch fix this error.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoSecurityPkg: SmmTcg2PhysicalPresenceLib: Fix GCC build failure
Zhang, Chao B [Mon, 10 Oct 2016 08:42:01 +0000 (16:42 +0800)]
SecurityPkg: SmmTcg2PhysicalPresenceLib: Fix GCC build failure

GCC is case sensitive. Also add BaseMemoryLib in INF.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chao Zhang <chao.b.zhang@intel.com>
Reviewed-by: Gao Liming <liming.gao@intel.com>
Reviewed-by: Long Qin <qin.long@intel.com>
7 years agoNt32Pkg/PlatformBootManagerLib: Signal the End of DXE Event
Cinnamon Shia [Mon, 3 Oct 2016 09:28:30 +0000 (17:28 +0800)]
Nt32Pkg/PlatformBootManagerLib: Signal the End of DXE Event

From PI spec vol2:
Prior to invoking any UEFI drivers, applications, or connecting consoles,
the platform should signal the event EFI_END_OF_DXE_EVENT_GUID

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Cinnamon Shia <cinnamon.shia@hpe.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdePkg:Correct the comment for the DEBUG_NET.
Zhang Lubo [Fri, 23 Sep 2016 04:08:46 +0000 (12:08 +0800)]
MdePkg:Correct the comment for the DEBUG_NET.

Generalize the comment for the DEBUG_NET
#define DEBUG_NET  0x00004000  // SNP Driver
to Network IO Driver.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Zhang Lubo <lubo.zhang@intel.com>
Cc: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Cc: Ye Ting <ting.ye@intel.com>
Reviewed-by: Sriram Subramanian <sriram-s@hpe.com>
7 years agoMdeModulePkg:TcpDriver need to use EFI_D_NET for DEBUG maessage.
Zhang Lubo [Fri, 23 Sep 2016 04:01:28 +0000 (12:01 +0800)]
MdeModulePkg:TcpDriver need to use EFI_D_NET for DEBUG maessage.

Tcp driver need to use EFI_D_NET to log DEBUG message,
So it becomes easy to separate/filter out debug messages
from network stack versus generic EFI_D_INFO debugs.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Zhang Lubo <lubo.zhang@intel.com>
Cc: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Cc: Ye Ting <ting.ye@intel.com>
Reviewed-by: Sriram Subramanian <sriram-s@hpe.com>
7 years agoNetworkPkg: TcpDriver use EFI_D_NET for DEBUG maessage.
Zhang Lubo [Fri, 23 Sep 2016 03:55:01 +0000 (11:55 +0800)]
NetworkPkg: TcpDriver use EFI_D_NET for DEBUG maessage.

Tcp driver need to use EFI_D_NET to log DEBUG message,
So it becomes easy to separate/filter out debug messages
from network stack versus generic EFI_D_INFO debugs.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Zhang Lubo <lubo.zhang@intel.com>
Cc: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Cc: Ye Ting <ting.ye@intel.com>
Reviewed-by: Sriram Subramanian <sriram-s@hpe.com>
7 years agoOptionRomPkg: Fix GCC build failure
Bi, Dandan [Thu, 22 Sep 2016 02:51:10 +0000 (10:51 +0800)]
OptionRomPkg: Fix GCC build failure

Remove the variable which is set but not used to pass GCC build.

Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dandan Bi <dandan.bi@intel.com>
7 years agoShellPkg/UefiShellNetwork1CommandsLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:55:26 +0000 (14:55 +0800)]
ShellPkg/UefiShellNetwork1CommandsLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:54:40 +0000 (14:54 +0800)]
ShellPkg/UefiShellLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellCommandLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:53:47 +0000 (14:53 +0800)]
ShellPkg/UefiShellCommandLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellBcfgCommandLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:51:57 +0000 (14:51 +0800)]
ShellPkg/UefiShellBcfgCommandLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellParsingLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:51:08 +0000 (14:51 +0800)]
ShellPkg/UefiShellParsingLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellLevel3CommandsLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:50:01 +0000 (14:50 +0800)]
ShellPkg/UefiShellLevel3CommandsLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellLevel2CommandsLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:44:22 +0000 (14:44 +0800)]
ShellPkg/UefiShellLevel2CommandsLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellLevel1CommandsLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:43:38 +0000 (14:43 +0800)]
ShellPkg/UefiShellLevel1CommandsLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellDriver1CommandsLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:42:39 +0000 (14:42 +0800)]
ShellPkg/UefiShellDriver1CommandsLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/UefiShellDebug1CommandsLib: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 06:41:41 +0000 (14:41 +0800)]
ShellPkg/UefiShellDebug1CommandsLib: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoShellPkg/Application: Remove unnecessary EFIAPI
Chen A Chen [Thu, 29 Sep 2016 07:15:15 +0000 (15:15 +0800)]
ShellPkg/Application: Remove unnecessary EFIAPI

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDataBase: Fix NULL deference bug in HiiGetImageInfo
Ruiyu Ni [Fri, 30 Sep 2016 04:29:24 +0000 (12:29 +0800)]
MdeModulePkg/HiiDataBase: Fix NULL deference bug in HiiGetImageInfo

The return value of GetImageIdOrAddress() could be NULL if the
ImageId is invalid. The patch fixes the bug to return EFI_NOT_FOUND
when GetImageIdOrAddress() returns NULL.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
7 years agoBaseTools Makefile: Enable O2 option for GCC tool chain
Liming Gao [Thu, 29 Sep 2016 07:59:09 +0000 (15:59 +0800)]
BaseTools Makefile: Enable O2 option for GCC tool chain

Enable O2 option to generate fast code for performance improvement.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
7 years agoBaseTools GenVtf: Initialize the return point as NULL
Liming Gao [Thu, 29 Sep 2016 07:58:23 +0000 (15:58 +0800)]
BaseTools GenVtf: Initialize the return point as NULL

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
7 years agoBaseTools Makefile: Enable O2 option to replace Od for VS tool chain
Liming Gao [Wed, 28 Sep 2016 06:18:56 +0000 (14:18 +0800)]
BaseTools Makefile: Enable O2 option to replace Od for VS tool chain

Enable O2 option to generate fast code for performance improvement.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Acked-by: Jordan Justen <jordan.l.justen@intel.com>
7 years agoBaseTools EfiLdrImage: Remove unnecessary exit (0)
Liming Gao [Wed, 28 Sep 2016 06:14:37 +0000 (14:14 +0800)]
BaseTools EfiLdrImage: Remove unnecessary exit (0)

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
7 years agoMdeModulePkg/HiiDataBase: Fix incorrect local variable type
Dandan Bi [Mon, 26 Sep 2016 06:25:33 +0000 (14:25 +0800)]
MdeModulePkg/HiiDataBase: Fix incorrect local variable type

The type of variable "SmallestIdFromFlag" should be BOOLEAN,
this patch fix the incorrect type.

Cc: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dandan Bi <dandan.bi@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
7 years agoMdeModulePkg/CdExpressPei: Fix capsule size mismatch issue.
Jiewen Yao [Fri, 30 Sep 2016 02:42:26 +0000 (10:42 +0800)]
MdeModulePkg/CdExpressPei: Fix capsule size mismatch issue.

Current PeiCdExpress driver will return capsule size to
be block aligned.
It will fail if we check the capsuleImageSize field.

The patch correct the returned capsule size.

Tested-by: Eric Dong <eric.dong@intel.com>
Cc: Feng Tian <feng.tian@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
7 years agoMdePkg: Fix some typing errors in the header files
Thomas Huth [Mon, 12 Sep 2016 08:35:39 +0000 (01:35 -0700)]
MdePkg: Fix some typing errors in the header files

Correct the typos in some header files of MdePkg.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Michael Kinney <michael.d.kinney@intel.com>
7 years agoMdePkg: Fix some typing errors
Thomas Huth [Fri, 9 Sep 2016 20:33:09 +0000 (13:33 -0700)]
MdePkg: Fix some typing errors

Correct the typos in some files of MdePkg.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Michael Kinney <michael.d.kinney@intel.com>
7 years agoQuarkPlatformPkg/RecoveryOemHookLib: Remove RecoveryOemHookLib
Michael Kinney [Mon, 3 Oct 2016 18:16:46 +0000 (11:16 -0700)]
QuarkPlatformPkg/RecoveryOemHookLib: Remove RecoveryOemHookLib

Remove the RecoveryOemHookLib class and instance that is no
longer used by any modules.

Cc: Kelly Steele <kelly.steele@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Kelly Steele <kelly.steele@intel.com>
7 years agoQuarkPlatformPkg: Add ForceRecovery UEFI application
Michael Kinney [Mon, 3 Oct 2016 18:16:19 +0000 (11:16 -0700)]
QuarkPlatformPkg: Add ForceRecovery UEFI application

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

Add the ForceRecovery UEFI application to the Quark.dsc file
so this application can be put onto an SD card or USB drive
to test the Galileo firmware recovery feature.

The library mappings to the RecoveryOemHookLib are also
removed becuse this library is not longer used by any modules.

Cc: Kelly Steele <kelly.steele@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Kelly Steele <kelly.steele@intel.com>
7 years agoQuarkPlatformPkg/PlatformHelperLib: Remove PlatformDebugPortGetChar8()
Michael Kinney [Mon, 3 Oct 2016 18:15:02 +0000 (11:15 -0700)]
QuarkPlatformPkg/PlatformHelperLib: Remove PlatformDebugPortGetChar8()

Remove the library function PlatformDebugPortGetChar8() from the
PlatformHelperLib that is no longer used by any modules.

Cc: Kelly Steele <kelly.steele@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Kelly Steele <kelly.steele@intel.com>
7 years agoQuarkPlatformPkg/PlatformInit: Fix recovery detection issues
Michael Kinney [Mon, 3 Oct 2016 18:13:42 +0000 (11:13 -0700)]
QuarkPlatformPkg/PlatformInit: Fix recovery detection issues

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

There are four supported methods to generate a boot mode of
BOOT_IN_RECOVERY_MODE on the Galileo platforms:

* Detect a corrupt FV
* Detect a forced recovery from the ForceRecovery UEFI application
  that sets a bit in a sticky R/W register
* The RESET button for the Arduino shield is held while the system
  is powered up
* The RESET button for the Arduino shield is held while the system
  is rebooted using the REBOOT button.

The logic in the PlatformInit module is cleaned up and updated to
support all three of the recovery detection methods.  The clean
ups include:

* Remove extra debug messages
* Remove user input from serial port

In addition, once one of the recovery methods is detected and a
boot mode of BOOT_IN_RECOVERY_MODE is set, the Galileo platforms
would get an error attempting to use the USB host controller to
detect and read a recovery image from a USB drive.  The issue is
the IMR protection registers are programmed to prevent DMA to
memory owned by the PEI Core. The IMR register programming is
updated to allow DMA to memory that is allocated by the recovery
modules using the PEI AllocatePages() service.

Cc: Kelly Steele <kelly.steele@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Kelly Steele <kelly.steele@intel.com>
7 years agoQuarkPlatformPkg/ForceRecovery: Add UEFI application to force recovery
Michael Kinney [Mon, 3 Oct 2016 18:09:58 +0000 (11:09 -0700)]
QuarkPlatformPkg/ForceRecovery: Add UEFI application to force recovery

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

This UEFI Application sets a sticky bit that persists across reset
to force a boot mode of BOOT_IN_RECOVERY_MODE.  It then performs
a warm reset using the UEFI Runtime Service ResetSystem().

Cc: Kelly Steele <kelly.steele@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Kelly Steele <kelly.steele@intel.com>
7 years agoQuarkSocPkg/QncSmmDispatcher: Fix use after free issue
Michael Kinney [Tue, 4 Oct 2016 17:55:24 +0000 (10:55 -0700)]
QuarkSocPkg/QncSmmDispatcher: Fix use after free issue

Update Quark North Cluster SMM dispatcher logic to handle
case where an SMI handler unregisters itself.

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

This issue was reproduced using the unit test at:

https://github.com/mdkinney/edk2/tree/Bug51/Reproduce

An ASSERT() is generated the 4th time the periodic SMI
handler is triggered when the periodic SMI handler
unregisters itself.  After applying this patch, the
DEBUG() message from the periodic SMI handler in this
unit test is generated 4 times, the periodic SMI handler
is unregistered, and the UEFI Shell works as expected.

Cc: Kelly Steele <kelly.steele@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Kelly Steele <kelly.steele@intel.com>
7 years agoQuarkSocPkg/QncSmmDispatcher: Fix context passed to SMI handlers
Michael Kinney [Wed, 5 Oct 2016 03:03:24 +0000 (20:03 -0700)]
QuarkSocPkg/QncSmmDispatcher: Fix context passed to SMI handlers

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

1) Add CallbackContext field to the DATABASE_RECORD structure that
   is set to the RegisterContent value passed to QNCSmmCoreRegister().
   This is the content that must be passed to the SMI handler when
   its source is triggered.

2) Update usage of ChildContext field in the DATABASE_RECOD to use
   CopyMem() instead of structure assignments to avoid compiler
   use of memcpy() intrinsics

This issue was reproduced using the unit test at:

https://github.com/mdkinney/edk2/tree/Bug51/Reproduce

An ASSERT() is generated the first time the periodic SMI
handler is triggered.  After applying this patch, the
DEBUG() messages from the periodic SMI handler in this
unit test are generated.

Cc: Kelly Steele <kelly.steele@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Kelly Steele <kelly.steele@intel.com>
7 years agoShellPkg: Fix erroneous Status returned by ShellOpenFileByName()
Vladimir Olovyannikov [Thu, 6 Oct 2016 22:02:26 +0000 (15:02 -0700)]
ShellPkg: Fix erroneous Status returned by ShellOpenFileByName()

In ShellOpenFileByName() the file is opened using
gEfiShellProtocol->OpenFileByName().
It is supposed that if this call returns an EFI_ERROR, the function
should return that error immediately. However, this return was missing,
and if UnicodeCollationProtocol has not been located by this time, the
Status gets overwritten with LocateProtocol() call result, which
eventually erroneously returns EFI_SUCCESS to the Shell.c, and this
leads to attempt to execute a non-existent startup script, which fails,
and which in turn leads to Shell being unloaded with "Invalid parameter"
error. This patch fixes the bug.

Cc: Tapan Shah <tapandshah@hpe.com>
Cc: Jaben Carsey <jaben.carsey@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Vladimir Olovyannikov <vladimir.olovyannikov@broadcom.com>
Reviewed-by: Tapan Shah <tapandshah@hpe.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
7 years agoIntelSiliconPkg: Updated IgdOpregion.h based on latest spec
Giri P Mudusuru [Fri, 30 Sep 2016 17:35:18 +0000 (10:35 -0700)]
IntelSiliconPkg: Updated IgdOpregion.h based on latest spec

Updated IgdOpregion.h to align with latest specification
https://01.org/sites/default/files/documentation/skl_opregion_rev0p5.pdf

1) Updated Mailbox structures to align with latest spec
2) Added Mailbox 5 structure
3) Added defines for Signature and Mailbox support

Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Maurice Ma <maurice.ma@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Giri P Mudusuru <giri.p.mudusuru@intel.com>
7 years agoIntelFsp2Pkg/Tools: Add PE32 section rebasing support
Maurice Ma [Wed, 5 Oct 2016 00:02:24 +0000 (17:02 -0700)]
IntelFsp2Pkg/Tools: Add PE32 section rebasing support

The current SplitFspBin.py can only support TE image format
rebasing in an FSP binary. This patch adds PE32 image format
rebasing support.

Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Giri P Mudusuru <giri.p.mudusuru@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Maurice Ma <maurice.ma@intel.com>
Reviewed-by: Satya Yarlagadda <Satya.p.yarlagadda@intel.com>
7 years agoShellPkg: Move UnicodeCollation2 Protcol locate out of UefiShellLib constructor
Tapan Shah [Wed, 5 Oct 2016 20:58:05 +0000 (13:58 -0700)]
ShellPkg: Move UnicodeCollation2 Protcol locate out of UefiShellLib constructor

Move gEfiUnicodeCollation2ProtocolGuid protocol outside of UefiShellLib constructor
function.
Locate gEfiUnicodeCollation2ProtocolGuid protocol in ShellOpenFileByName() which
consumes this protocol API.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Tapan Shah <tapandshah@hpe.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
7 years agoShellPkg/Hexedit: Fix FreePool() ASSERT() when writing disk
Michael Kinney [Thu, 29 Sep 2016 00:33:43 +0000 (17:33 -0700)]
ShellPkg/Hexedit: Fix FreePool() ASSERT() when writing disk

The HDiskImageSave() function copies a device path using
DuplicateDevicePath() and passes that device path to
gBS->LocateDevicePath() that changes the value of the
device path pointer.  When FreePool() is called with the
modified device path pointer, the FreePool() service
generates an ASSERT() because the signature for the pool
head can not be found.

The function HDiskImageRead() immediately above
HDiskImageSave() has the correct algorithm that uses an
additional local variable called DupDevicePathForFree to
preserve the pointer to the allocated buffer so it can
be used in the call to FreePool().

Bug: <https://bugzilla.tianocore.org/show_bug.cgi?id=131>

Cc: Jaben Carsey <jaben.carsey@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Jaben Carsey <Jaben.carsey@intel.com>
7 years agoShellPkg/Shell: Update CRC32 in the EFI System Table header
Cinnamon Shia [Mon, 3 Oct 2016 16:37:17 +0000 (09:37 -0700)]
ShellPkg/Shell: Update CRC32 in the EFI System Table header

Update CRC32 in the EFI System Table header after shell changes the
value of gST->ConsoleOutHandle and gST->ConOut

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Cinnamon Shia <cinnamon.shia@hpe.com>
Reviewed-By: Tapan Shah <tapandshah@hpe.com>
Reviewed-By: Jaben Carsey <Jaben.carsey@intel.com>
7 years agoBaseTools Build: Fix build break for clean target in Linux
Hao Wu [Thu, 29 Sep 2016 14:47:38 +0000 (22:47 +0800)]
BaseTools Build: Fix build break for clean target in Linux

In Linux, Command needs to be String instead of list when Command run
as shell with True.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
7 years agoBaseTools VS Makefile: Don't include ms.common in ms.app
Liming Gao [Thu, 29 Sep 2016 14:00:42 +0000 (22:00 +0800)]
BaseTools VS Makefile: Don't include ms.common in ms.app

ms.common is included by every tool Makefile. it is not necessary to be placed
in ms.app again.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
7 years agoBaseTools Makefile: Missing LFAGS in app.makefile
Liming Gao [Thu, 29 Sep 2016 14:00:22 +0000 (22:00 +0800)]
BaseTools Makefile: Missing LFAGS in app.makefile

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
7 years agoCryptoPkg/OpensslLib: Upgrade OpenSSL version to 1.0.2j
Qin Long [Tue, 27 Sep 2016 08:54:04 +0000 (16:54 +0800)]
CryptoPkg/OpensslLib: Upgrade OpenSSL version to 1.0.2j

Two official releases (OpenSSL 1.0.2i and 1.0.2j) were available
with several severity fixes at 22-Sep-2016 and 26-Sep-2016.
Refer to
https://www.openssl.org/news/secadv/20160922.txt and
https://www.openssl.org/news/secadv/20160926.txt.
This patch is to upgrade the supported OpenSSL version in
CryptoPkg/OpensslLib to catch the latest release 1.0.2j.

Cc: Ting Ye <ting.ye@intel.com>
Cc: David Woodhouse <David.Woodhouse@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Qin Long <qin.long@intel.com>
Reviewed-by: Ting Ye <ting.ye@intel.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
7 years agoMdeModulePkg/ImageDecoderLib: Retire it due to new BootLogoLib
Ruiyu Ni [Thu, 29 Sep 2016 02:37:44 +0000 (10:37 +0800)]
MdeModulePkg/ImageDecoderLib: Retire it due to new BootLogoLib

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
7 years agoMdeModulePkg/BmpImageDecoderLib: Retire it due to new BootLogoLib
Ruiyu Ni [Thu, 29 Sep 2016 02:38:35 +0000 (10:38 +0800)]
MdeModulePkg/BmpImageDecoderLib: Retire it due to new BootLogoLib

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
7 years agoMdeModulePkg: Remove ImageDecoderLib and BmpImageDecoderLib
Ruiyu Ni [Thu, 29 Sep 2016 02:40:28 +0000 (10:40 +0800)]
MdeModulePkg: Remove ImageDecoderLib and BmpImageDecoderLib

The two libraries are created to support old BootLogoLib to
decode the images. Due to the new BootLogoLib starts using
HiiImageEx interfaces, the two libraries are not needed.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
7 years agoSecurityPkg: Tcg2: Fix TCG2 PP issues
Zhang, Chao B [Tue, 27 Sep 2016 01:46:40 +0000 (09:46 +0800)]
SecurityPkg: Tcg2: Fix TCG2 PP issues

Several issues exist in TCG2 PP
1. TCG2 PP use NVS PPRQ/PPRM as PP parameter as well as current
PP state cache. But it doesn't handle PP set failure case
2. TCG2 PP Submit TPM Operation Request to Pre-OS Environment forgets
to clean PPRM
3. Potential alignment issue

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chao Zhang <chao.b.zhang@intel.com>
Reviewed-by: Qin Long <qin.long@intel.com>
7 years agoOvmfPkg: Use the new LogoDxe driver
Ruiyu Ni [Mon, 26 Sep 2016 06:45:06 +0000 (14:45 +0800)]
OvmfPkg: Use the new LogoDxe driver

Contributed-under: TianoCore Contribution Agreement 1.0
Cc: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoArmVirtPkg: Use the new LogoDxe driver
Ruiyu Ni [Mon, 26 Sep 2016 06:49:40 +0000 (14:49 +0800)]
ArmVirtPkg: Use the new LogoDxe driver

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoNt32Pkg: Use the new LogoDxe driver
Ruiyu Ni [Fri, 23 Sep 2016 08:07:58 +0000 (16:07 +0800)]
Nt32Pkg: Use the new LogoDxe driver

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/Logo: Add LogoDxe module
Ruiyu Ni [Fri, 23 Sep 2016 08:03:47 +0000 (16:03 +0800)]
MdeModulePkg/Logo: Add LogoDxe module

LogoDxe embeds the image resource in the PE resource section, then
it produces Platform Logo protocol which can return the images
in pixel format.
HiiImageEx protocol is responsible to decode the JPEG/PNG images
to pixel format. LogoDxe driver uses HiiImageEx protocol.

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/BootLogoLib&PlatformLogo: Use HII data types in parameters
Ruiyu Ni [Fri, 23 Sep 2016 07:54:01 +0000 (15:54 +0800)]
MdeModulePkg/BootLogoLib&PlatformLogo: Use HII data types in parameters

1. Change PlatformLogo protocol to return EFI_IMAGE_INPUT instead of
   RAW image data. PlatformLogo implementation can use HiiImageEx to
   decode the image if it's JPEG or PNG format.
2. Change BootLogoLib to consume the new PlatformLogo protocol.
3. Change BootLogoEnableLogo() to only use images returned from
   PlatformLogo protocol.

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoOvmfPkg/PlatformBds: Do not call BootLogoEnableLogo
Ruiyu Ni [Mon, 26 Sep 2016 06:40:32 +0000 (14:40 +0800)]
OvmfPkg/PlatformBds: Do not call BootLogoEnableLogo

Prototype of BootLogoEnableLogo will change in following patches, so
do not call BootLogoEnableLogo to avoid build failure.

Contributed-under: TianoCore Contribution Agreement 1.0
Cc: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoArmVirtPkg/PlatformBds: Do not call BootLogoEnableLogo
Ruiyu Ni [Mon, 26 Sep 2016 06:39:04 +0000 (14:39 +0800)]
ArmVirtPkg/PlatformBds: Do not call BootLogoEnableLogo

Prototype of BootLogoEnableLogo will change in following patches, so
do not call BootLogoEnableLogo to avoid build failure.

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoNt32Pkg/PlatformBds: Do not call BootLogoEnableLogo
Ruiyu Ni [Fri, 23 Sep 2016 07:21:47 +0000 (15:21 +0800)]
Nt32Pkg/PlatformBds: Do not call BootLogoEnableLogo

Prototype of BootLogoEnableLogo will change in following patches, so
do not call BootLogoEnableLogo to avoid build failure.

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDatabase: Add HiiImageEx implementation.
Ruiyu Ni [Wed, 21 Sep 2016 09:48:13 +0000 (17:48 +0800)]
MdeModulePkg/HiiDatabase: Add HiiImageEx implementation.

According to UEFI spec, NewImageEx()/SetImageEx()/DrawImageEx()
implicitly call the non-Ex version interface
of HiiImage protocol.
GetImageEx()/DrawImageIdEx() are the enhanced version of
GetImage()/DrawImageId(), which can support decoding JPEG/PNG
through the help of HiiImageDecoder protocol.

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDatabase: Update HiiImage to support PNG/JPEG
Ruiyu Ni [Wed, 21 Sep 2016 04:55:00 +0000 (12:55 +0800)]
MdeModulePkg/HiiDatabase: Update HiiImage to support PNG/JPEG

1. Update GetImageIdOrAddress() to recognize PNG/JPEG image block.
   A offset calculation bug was fixed.
2. Update HiiGetImage() comments to say PNG/JPEG support is provided
   by HiiImageEx
3. Update HiiSetImage() to support replacing a PNG/JPEG image block
   with a new image

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdePkg/HiiImage.h: Include GraphicsOutput.h
Ruiyu Ni [Mon, 26 Sep 2016 07:39:54 +0000 (15:39 +0800)]
MdePkg/HiiImage.h: Include GraphicsOutput.h

HiiImage.h uses EFI_GRAPHICS_OUTPUT_BLT_PIXEL which is defined in
GraphicsOutput.h. Include GraphicsOutput.h to avoid build failure
from consumer of HiiImage protocol.

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdemodulePkg/HiiDatabase: Correct typo in comments.
Ruiyu Ni [Wed, 21 Sep 2016 04:48:10 +0000 (12:48 +0800)]
MdemodulePkg/HiiDatabase: Correct typo in comments.

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDatabase: Refine HiiDrawImage()
Ruiyu Ni [Wed, 21 Sep 2016 03:31:49 +0000 (11:31 +0800)]
MdeModulePkg/HiiDatabase: Refine HiiDrawImage()

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDatabase: Refine HiiSetImage()
Ruiyu Ni [Wed, 21 Sep 2016 03:29:08 +0000 (11:29 +0800)]
MdeModulePkg/HiiDatabase: Refine HiiSetImage()

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDatabase: Refine HiiGetImage()
Ruiyu Ni [Wed, 21 Sep 2016 03:27:05 +0000 (11:27 +0800)]
MdeModulePkg/HiiDatabase: Refine HiiGetImage()

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDatabase: Refine HiiNewImage()
Ruiyu Ni [Wed, 21 Sep 2016 03:18:15 +0000 (11:18 +0800)]
MdeModulePkg/HiiDatabase: Refine HiiNewImage()

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDatabase: Move common code to LocatePackageList()
Ruiyu Ni [Wed, 21 Sep 2016 03:14:01 +0000 (11:14 +0800)]
MdeModulePkg/HiiDatabase: Move common code to LocatePackageList()

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdeModulePkg/HiiDatabase: Refine GetImageIdOrAddress
Ruiyu Ni [Wed, 21 Sep 2016 03:10:38 +0000 (11:10 +0800)]
MdeModulePkg/HiiDatabase: Refine GetImageIdOrAddress

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
7 years agoMdePkg/HiiImageDecoder.h: Add missing EFI_HII_IMAGE_DECODER_OTHER_INFO
Ruiyu Ni [Tue, 27 Sep 2016 02:09:05 +0000 (10:09 +0800)]
MdePkg/HiiImageDecoder.h: Add missing EFI_HII_IMAGE_DECODER_OTHER_INFO

Besides adding the missing structure
EFI_HII_IMAGE_DECODER_OTHER_INFO, the patch also correct some typo.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
7 years agoMdePkg/HiiImageDecoder.h: Rename from ImageDecoder.h
Ruiyu Ni [Tue, 27 Sep 2016 01:56:34 +0000 (09:56 +0800)]
MdePkg/HiiImageDecoder.h: Rename from ImageDecoder.h

Rename the protocol header file to follow EDKII file
name rule before the HiiImageDecoder protocol is used
by anyone.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>