summaryrefslogtreecommitdiff
path: root/MdePkg
AgeCommit message (Collapse)AuthorFilesLines
2017-12-22MdePkg Acpi60.h: Add missing PCCT subspace type 1 and 2 definitionsStar Zeng2-2/+94
Same change is done for Acpi61.h. Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Chasel Chiu <chasel.chiu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Jiewen Yao <jiewen.yao@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-12-19MdePkg MemoryOverwriteControl.h: Correct typo 'bi' to 'bit'Star Zeng1-1/+1
Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Chao Zhang <chao.b.zhang@intel.com> Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
2017-12-15MdePkg/Include/Pi: Modify specification number encodingHao Wu2-5/+5
Change the PEI and DXE service table revisions to 1.6. The SMM part is already done by commit: 07c6a47e70ba54709b0e26237770f3c38685e860 & 2f208e59e4b994978a1a24affc306eb694a00327 Cc: Michael D Kinney <michael.d.kinney@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-12-15MdePkg/UefiSpec.h: Update the UEFI version to reflect new revisionHao Wu1-3/+4
Cc: Michael D Kinney <michael.d.kinney@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-12-12MdePkg: correct and clarify documentation of VA_LIST in Base.hZenith4321-8/+17
This is to resolve bug 457. https://bugzilla.tianocore.org/show_bug.cgi?id=457 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zenith432 <zenith432@users.sourceforge.net> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Liming Gao <liming.gao@intel.com> [lersek@redhat.com: reconstruct commit from patch pasted into email] Signed-off-by: Laszlo Ersek <lersek@redhat.com>
2017-12-12MdePkg PciIo.h: Correct function description for ALLOCATE_BUFFERStar Zeng1-2/+2
DUAL_ADDRESS_CYCLE is missing in the EFI_UNSUPPORTED return status description. Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Ruiyu Ni <ruiyu.ni@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Jiewen Yao <jiewen.yao@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
2017-12-11MdePkg/Uefi ARM: only support native ARM/Thumb imagesArd Biesheuvel1-3/+2
The ARM calling convention is fundamentally incompatible with EBC, and having a cross compatible machine type identical to the native type does not make a lot of sense either. So restrict the compatible machine type for ARM to EFI_IMAGE_MACHINE_ARMTHUMB_MIXED, and remove the cross compatible. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-12-08MdePkg/BaseLib: Add stack switch related definitions for IA32Jian J Wang4-0/+193
The new definitions include two structures IA32_TASK_STATE_SEGMENT IA32_TSS_DESCRIPTOR two macros IA32_GDT_TYPE_TSS IA32_GDT_ALIGNMENT and one API VOID EFIAPI AsmWriteTr ( IN UINT16 Selector ); They're needed to setup task gate and interrupt stack table for stack switch. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Jiewen Yao <jiewen.yao@intel.com> Suggested-by: Ayellet Wolman <ayellet.wolman@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Jian J Wang <jian.j.wang@intel.com> Reviewed-by: Jeff Fan <vanjeff_919@hotmail.com> Reviewed-by: Jiewen.yao@intel.com
2017-12-07MdePkg: Arm/AArch64 - filter #pragma pack() when __ASSEMBLER__Leif Lindholm2-2/+2
clang, when used as a preprocessor for dtc, does not discard #pragma statements although -x assembler-with-cpp is specified. This causes dtc to barf at a #pragma pack() statement that is already filtered out for __GNUC__. So add a check to also filter this out if __ASSEMBLER__. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-12-07MdePkg MmCommunication.h: Follow PI spec to update EFI_MM_COMMUNICATEStar Zeng1-2/+12
Follow PI spec (>= 1.5) to add new return status code description and make CommSize OPTIONAL. Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
2017-12-01MdePkg PiFirmwareVolume.h: Add USED_SIZE FV_EXT_TYPE definitionsStar Zeng1-2/+21
The definitions are introduced by PI 1.6 spec. The EFI_FIRMWARE_VOLUME_EXT_ENTRY_USED_SIZE_TYPE can be used to find out how many EFI_FVB2_ERASE_POLARITY bytes are at the end of the FV. When the FV gets shadowed into memory you only need to copy the used bytes into memory and fill the rest of the memory buffer with the erase value. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-11-30MdeModulePkg/SerialDxe: Fix return valued in SerialSetAttributesJulien Grall1-2/+3
SerialSetAttributes is meant to match the behavior of the function EFI_SERIAL_IO_PROTOCOL.SetAttributes() in the UEFI spec (v2.7). This means the function can only return: - EFI_SUCCESS - EFI_INVALID_PARAMETER - EFI_DEVICE_ERROR However the function SerialPortSetAttributes may also validly return EFI_UNSUPPORTED. For instance this is the case of the Xen Console driver. EFI_UNSUPPORTED could be also interpreted as "One or more of the attributes has an unsupported value". So return EFI_INVALID_PARAMETER in that case. Lastly, to prevent another return slipping in the future, all the errors but EFI_INVALID_PARAMETER and EFI_UNSUPPORTED will return EFI_DEVICE_ERROR. Contributed-under: Tianocore Contribution Agreement 1.1 Signed-off-by: Julien Grall <julien.grall@linaro.org> Reviewed-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
2017-11-30MdeModulePkg/SerialDxe: Describe correctly EFI_DEVICE_ERROR for SetAttributesJulien Grall1-1/+1
Per the UEFIv2.7 spec, EFI_DEVICE_ERROR is returned when the serial device is not functioning correctly. Update the description to avoid confusion. Contributed-under: Tianocore Contribution Agreement 1.1 Signed-off-by: Julien Grall <julien.grall@linaro.org> Reviewed-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
2017-11-29MdePkg: Disable VS warning 4701 & 4703 for VS2017Liming Gao2-4/+4
Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
2017-11-14MdePkg: Fix MSFT C4255 warningSong, BinX3-2/+3
V2: Fix MSFT C4255 warning V1: Enable MSFT C4255 warning. From MSDN: Compiler Warning (level 4) C4255 function' : no function prototype given: converting '()' to '(void)' The compiler did not find an explicit list of arguments to a function. This warning is for the C compiler only. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Bell Song <binx.song@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-11-13MdePkg: Add definitions for the SPI protocols introduced in PI 1.6.Marvin.Haeuser@outlook.com12-0/+1721
This commit adds header files for the SPI protocols introduced in the UEFI PI 1.6 specification, as well as their GUIDs to MdePkg.dec. EFI_SPI_TRANSACTION_TYPE assumes an enum with its members ordered the way they are listed in the specification, as there are no values given explicitely. EFI_LEGACY_SPI_CONTROLLER_GUID assumes the character 'l' used in the specification was meant to be '1'. V2: - Fixed LegacySpiFlash.h's header guard. - Fixed LegacySpiSmmController's GUID name. - Removed EFI_SPI_NOR_FLASH_PROTOCOL_LF_READ_DATA as it's unused. - Added the missing SpiSmmNorFlash header. - Fixed all file endings to be CRLF. - Removed trailing whitespaces. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Marvin Haeuser <Marvin.Haeuser@outlook.com> Reviewed-by: Dandan Bi <dandan.bi@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-11-09MdePkg/NvdimmLabel.h: Add NVDIMM_LABEL protocol definitionRuiyu Ni2-0/+354
NVDIMM_LABEL protocol is defined in UEFI 2.7 spec, to provide services that allow management of labels contained in a Label Storage Area in NVDIMM. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-11-09MdePkg/Btt.h: Add Block Translation Table definitionsRuiyu Ni2-0/+234
BTT definitions are defined in UEFI spec 2.7, to defines a layout and set of rules for doing block I/O that provide powerfail write atomicity of a single block in NVDIMM. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-11-08MdePkg/PciExpress21.h: Fix typo in PCI_REG_PCIE_SLOT_CONTROLRuiyu Ni1-12/+12
PCI_REG_PCIE_SLOT_CONTROL contains a typo. It is defined as: typedef union { struct { UINT32 AttentionButtonPressed : 1; UINT32 ... ... } Bits; UINT16 Uint16; } PCI_REG_PCIE_SLOT_CONTROL; The bit field data type should be UINT16 instead of UINT32, results sizeof (PCI_REG_PCIE_SLOT_CONTROL) equals to 4 instead of 2. Because this structure is used in PCI_CAPABILITY_PCIEXP as below: typedef struct { ... PCI_REG_PCIE_SLOT_CONTROL SlotControl; PCI_REG_PCIE_SLOT_STATUS SlotStatus; } PCI_CAPABILITY_PCIEXP; It cause the OFFSET_OF (PCI_CAPABILITY_PCIEXP, SlotStatus) equal to a wrong value. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-11-01MdePkg: Deprecate EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESSZhang, Chao B3-10/+10
Mark EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS as deprecated. Also update some function descriptors accordingly. Cc: Long Qin <qin.long@intel.com> Cc: Star Zeng <star.zeng@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chao Zhang <chao.b.zhang@intel.com> Reviewed-by: Long Qin <qin.long@intel.com>
2017-10-18SecurityPkg/Pkcs7Verify: Add the comments to address security problemLong Qin1-1/+9
Add the comments to address security problems in the Pkcs7Verify Protocol per UEFI 2.7 updates. The Pkcs7Verifier function VerifySignature() has problematic use cases where it might be used to unwittingly bypass security checks. The specific problem is that if the supplied hash is a different algorithm from the blacklist hash, the hash will be approved even if it should have been denied. The added comments place a strong warning about the problem. It is possible to use the protocol reliably, either by agreeing a hash to use for all time (like sha256) or by looping over all supported hashes when using the protocol. Cc: Chao Zhang <chao.b.zhang@intel.com> Cc: James Bottomley <James.Bottomley@HansenPartnership.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qin Long <qin.long@intel.com> Reviewed-by: Chao Zhang <chao.b.zhang@intel.com>
2017-10-10MdePkg HobLib: Add BuildFv3Hob APIStar Zeng4-4/+159
Add BuildFv3Hob API in HobLib.h and implement the API in HobLib instances PeiHobLib, DxeHobLib and DxeCoreHobLib. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-10-10MdePkg PiHob.h: Add FV3 HOB definitionsStar Zeng1-2/+41
Follow PI 1.6 spec to add FV3 HOB definitions Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-10-10MdePkg: Add definitions for ACPI 6.2Star Zeng2-2/+2944
Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-10-10MdePkg: Correct BaseS3PciSegmentLib module name to match its uni fileLiming Gao1-2/+2
Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao <liming.gao@intel.com> Cc: Ruiyu Ni <ruiyu.ni@intel.com>
2017-10-10MdePkg BaseLib: Add new API CalculateCrc32()Liming Gao2-0/+314
CalculateCrc32() bases on the initialized mCrcTable. When CalculateCrc32() is used, mCrcTable will take 1KB size in the image. When CalculateCrc32() is not used, mCrcTable will not be built in the image, and no size impact. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao <liming.gao@intel.com>
2017-10-10MdePkg: Correct EfiGcdMemoryTypePersistent name to follow PI specLiming Gao1-1/+5
PI spec defines EfiGcdMemoryTypePersistent name, MdePkg uses EfiGcdMemoryTypePersistentMemory name. So, EfiGcdMemoryTypePersistent is added. And, EfiGcdMemoryTypePersistentMemory is kept for compatility. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com>
2017-10-03MdePkg/IndustryStandard/Pci23: add vendor-specific capability headerLaszlo Ersek1-0/+10
Revision 2.2 of the PCI Spec defines Capability IDs 0 through 6, inclusive, in Appendix H. It reserves IDs 7 through 255. Revision 2.3 of the PCI Spec adds Capability IDs 7 through 0xC, inclusive, in Appendix H. Capability ID 9 stands for "Vendor Specific". Add the EFI_PCI_CAPABILITY_ID_VENDOR macro and the EFI_PCI_CAPABILITY_VENDOR_HDR structure type to MdePkg/IndustryStandard, in order to describe this capability header. Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Marcel Apfelbaum <marcel@redhat.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Ruiyu Ni <ruiyu.ni@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2017-09-29MdePkg/PrintLib: Fix possible negative value left shiftHao Wu1-1/+1
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=702 Within function InternalPrintLibSPrintMarker(), possible left shift of a negative value is found in: "(*(ArgumentString + 1) << 8)" which involves undefined behavior. Since '*(ArgumentString + 1)' is of type CONST CHAR8 (signed), it will be promoted to type int (signed) during the left shift operation. If '*(ArgumentString + 1)' is a negative value, the behavior will be undefined. According to the C11 spec, Section 6.5.7: > 4 The result of E1 << E2 is E1 left-shifted E2 bit positions; vacated > bits are filled with zeros. If E1 has an unsigned type, the value > of the result is E1 * 2^E2 , reduced modulo one more than the > maximum value representable in the result type. If E1 has a signed > type and nonnegative value, and E1 * 2^E2 is representable in the > result type, then that is the resulting value; otherwise, the > behavior is undefined. This commit explicitly cast '*(ArgumentString + 1)' with UINT8 to resolve this issue. Cc: Steven Shi <steven.shi@intel.com> Cc: Michael Kinney <michael.d.kinney@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-09-29MdePkg/Http.h: Clarify the usage of HttpConfigData in HTTP protocolJiaxin Wu1-7/+9
Cc: Ye Ting <ting.ye@intel.com> Cc: Fu Siyuan <siyuan.fu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com> Reviewed-by: Fu Siyuan <siyuan.fu@intel.com> Reviewed-by: Ye Ting <ting.ye@intel.com>
2017-09-26MdePkg PiFirmwareFile.h: Add FFS_ATTRIB_DATA_ALIGNMENT_2 definitionStar Zeng1-2/+3
Follow PI 1.6 spec to add FFS_ATTRIB_DATA_ALIGNMENT_2 definition for FFS alignment extended to support maximum 16MB. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-09-25MdePkg: Add UDF volume structure definitionsPaulo Alcantara1-5/+92
This patch adds a few more UDF volume structures in order to detect an UDF file system which is supported by current EDK2 UDF file system implementation in Partition driver. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Laszlo Ersek <lersek@redhat.com> Cc: Ruiyu Ni <ruiyu.ni@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Paulo Alcantara <pcacjr@zytor.com> Build-tested-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Star Zeng <star.zeng@intel.com> Tested-by: Hao Wu <hao.a.wu@intel.com> Build-tested-by: Star Zeng <star.zeng@intel.com> Build-tested-by: Paulo Alcantara <paulo@hp.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
2017-09-21MdePkg/BaseLib: Avoid reading content beyond string boundaryHao Wu1-2/+2
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=705 As mentioned in the above Bugzilla link by Steven, within the function PathCleanUpDirectories(), when executing command: "cd ." under Shell, the input parameter 'Path' string will have string length less than 2. Hence, it is possible for the below statement: "if (StrCmp (Path + StrLen (Path) - 2, L"\\.") == 0) {" to read contents before the string boundary. This commit adds additional checks to avoid this. Cc: Steven Shi <steven.shi@intel.com> Cc: Michael Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
2017-09-20MdePkg/include: Add Acpi.h to DMAR table.Jiewen Yao1-0/+2
Suggested-by: Star Zeng <star.zeng@intel.com> Cc: Star Zeng <star.zeng@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Jiewen Yao <jiewen.yao@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com>
2017-09-11MdePkg/BaseIoLibIntrinsic: fix SEV (=unrolled) variants of IoWriteFifoXX()Laszlo Ersek2-6/+6
In commit b6d11d7c4678 ("MdePkg: BaseIoLibIntrinsic (IoLib class) library", 2017-04-12), the MOV instructions in the write loops were probably copied from the read loops. However, the operand order was not adjusted. As a result, the IoWriteFifoXX() routines, when invoked in SEV guests, now overwrite the source buffer with value 0x01 / 0x0001 / 0x00000001 -- the SevNoRepIo() function returns value 1 in EAX, in SEV guests --, and write the same value to the target IO port. Fix this by putting the target operand (AL / AX / EAX) first, and the source operand (BYTE / WORD / DWORD [ESI/RSI]) second. Cc: Brijesh Singh <brijesh.singh@amd.com> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Fixes: b6d11d7c467810ea7f2e2eda46ef0bdc57bf1475 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Brijesh Singh <brijesh.singh@amd.com>
2017-09-08MdePkg: Add UDF volume structure definitionsPaulo Alcantara1-0/+60
This patch adds basic volume structure definitions necessary to identify a valid UDF file system on a block device, as specified by OSTA Universal Disk Format Specification 2.60. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Laszlo Ersek <lersek@redhat.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Paulo Alcantara <pcacjr@zytor.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
2017-09-06MdePkg/PiMmCis.h: Fix build failure.Eric Dong1-0/+1
Include the missed header file to fix build failure. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-09-06MdePkg: Add UEFI 2.7 defined GUID and structure for AIP network media type.Wang Fan1-1/+20
Reviewed-by: Fu Siyuan <siyuan.fu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Wang Fan <fan.wang@intel.com>
2017-09-06MdePkg/PciSegmentLibSegmentInfo: fix typo in PciSegmentBitFieldAnd*()Ruiyu Ni1-3/+3
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
2017-09-04MdePkg PeiMemoryAllocationLib: Update InternalAllocateAlignedPagesStar Zeng1-132/+40
Update InternalAllocateAlignedPages to use PeiServicesFreePages. Let the InternalAllocateAlignedPages in PeiMemoryAllocationLib use same algorithm with InternalAllocateAlignedPages in UefiMemoryAllocationLib. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-09-04MdePkg PeiMemoryAllocationLib: Update Free(Aligned)PagesStar Zeng1-7/+9
Update Free(Aligned)Pages to use PeiServicesFreePages. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-09-04MdePkg PeiServicesLib: Add PeiServicesFreePagesStar Zeng2-11/+55
Add PeiServicesFreePages and update comments for PeiServicesAllocatePages. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-09-04MdePkg PiPeiCis.h: Add FreePages definitionStar Zeng1-0/+27
Follow PI 1.6 spec to add FreePages definition and comments for AllocatePages that will support pre permanent memory page allocation. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-08-29MdePkg: Reference new definitions for Management Mode.Eric Dong23-1360/+257
In PI 1.5 version, system management mode name(SMM) has been changed to Management Mode(MM). It impacts the current code which still use SMM/Smram/SMI keywords. This patch update the original files which related to old SMM modules, also keep the compatible with old SMM related drivers. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-08-29MdePkg: Add new definitions for Management Mode.Eric Dong24-0/+2618
In PI 1.5 version, system management mode name(SMM) has been changed to Management Mode(MM). It impacts the current code which still use SMM/Smram/SMI keywords. This patch add new definition which use MM/MmRam/MMI keywords to follow new spec definitions. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-08-28MdePkg/S3PciSegmentLib: Add S3PciSegmentLib class and instance.Ruiyu Ni6-0/+2360
The patch adds the new library class S3PciSegmentLib to carry out PCI configuration and enable the PCI operations to be replayed during an S3 resume. This library class maps directly on top of the PciSegmentLib class. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-08-28MdePkg/PciSegmentLib: Add instances that consumes PciSegmentInfoLibRuiyu Ni9-0/+1969
The patch adds two PciSegmentLib instances that consumes PciSegmentInfoLib to provide multiple segments PCI configuration access. BasePciSegmentLibSegmentInfo instance is a BASE library. DxeRuntimePciSegmentLibSegmentInfo instance is to be linked with runtime drivers to provide not only boot time but also runtime PCI configuration access. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-08-28MdePkg/PciSegmentInfoLib: Add PciSegmentInfoLib class and instance.Ruiyu Ni6-0/+144
The patch adds PciSegmentInfoLib library class which is used by PciSegmentLib (commit in next patch) to support multiple segment PCI configuration access. BasePciSegmentInfoLibNull instance is added but it shouldn't be used by any real platform. Any single segment platform that wants to use PciSegmentLib could use BasePciSegmentLibPci instance. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-08-28MdePkg/PciExpress: Add macro PCI_ECAM_ADDRESSRuiyu Ni2-4/+20
The patch adds new macro PCI_ECAM_ADDRESS into PciExpress21.h, to align to the PCIE spec, and also update PciExpressLib.h to redirect PCI_EXPRESS_LIB_ADDRESS to the new macro. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
2017-08-28MdePkg/PciSegmentLib: Fix typo in function header commentsRuiyu Ni4-297/+308
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>