summaryrefslogtreecommitdiff
path: root/EmulatorPkg/Library
AgeCommit message (Collapse)AuthorFilesLines
2023-04-10EmulatorPkg: Update code to be more C11 compliant by using __func__Rebecca Cran1-1/+1
__FUNCTION__ is a pre-standard extension that gcc and Visual C++ among others support, while __func__ was standardized in C99. Since it's more standard, replace __FUNCTION__ with __func__ throughout EmulatorPkg. Signed-off-by: Rebecca Cran <rebecca@bsdio.com> Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Ard Biesheuvel <ardb@kernel.org> Reviewed-by: Abner Chang <Abner.Chang@amd.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
2023-02-09EmulatorPkg/PeiTimerLib: Bug fix in NanoSecondDelayDeric Cole1-2/+2
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4339 Thunk->Sleep is expecting nanoseconds, no need to multiply by 100. Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Signed-off-by: Deric Cole <deric.cole@intel.com> Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
2022-12-20EmulatorPkg/RedfishHostInterface: Add NULL functionAbner Chang1-0/+24
Add NULL function RedfishPlatformHostInterfaceNotification that returns EFI_UNSUPPORTED. Signed-off-by: Abner Chang <abner.chang@amd.com> Cc: Nickle Wang <nicklew@nvidia.com> Cc: Igor Kulchytskyy <igork@ami.com> Reviewed-by: Nickle Wang <nicklew@nvidia.com>
2022-12-08EmulatorPkg: Remove unnecessary dependency on EmbeddedPkgLiu, Zhiguang2-4/+2
EmulatorPkg doesn't need depend on EmbeddedPkg, so remove the dependency. Cc: Andrew Fish <afish@apple.com> Reviewed-by: Ray Ni <ray.ni@intel.com> Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com>
2022-03-16EmulatorPkg/RedfishPlatformCredentialLib: Don't stop Redfish serviceAbner Chang1-2/+0
https://bugzilla.tianocore.org/show_bug.cgi?id=3859 Platform Redfish credential library shouldn't stop the service at either EndOfDXE or ExitBootService notification. RedfishConfigureHandler UEFI driver is responsible to stop the Redfish service when EndOfDXE or ExitBootService event is triggered. Signed-off-by: Abner Chang <abner.chang@hpe.com> Cc: Nickle Wang <nickle.wang@hpe.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Reviewed-by: Nickle Wang <nickle.wang@hpe.com>
2022-03-16EmulatorPkg/RedfishPlatformCredentialLib: Check EFI_SECURE_BOOT_MODE_NAMEAbner Chang1-16/+16
https://bugzilla.tianocore.org/show_bug.cgi?id=3858 Check EFI_SECURE_BOOT_MODE_NAME before setting the flags to prohibit acquiring Redfish service credential and using Redfish service. Signed-off-by: Abner Chang <abner.chang@hpe.com> Cc: Nickle Wang <nickle.wang@hpe.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Reviewed-by: Nickle Wang <nickle.wang@hpe.com>
2021-12-07EmulatorPkg: Apply uncrustify changesMichael Kubacki28-723/+674
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3737 Apply uncrustify changes to .c/.h files in the EmulatorPkg package Cc: Andrew Fish <afish@apple.com> Cc: Leif Lindholm <leif@nuviainc.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
2021-12-07EmulatorPkg: Change OPTIONAL keyword usage styleMichael D Kinney4-6/+5
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3760 Update all use of ', OPTIONAL' to ' OPTIONAL,' for function params. Cc: Andrew Fish <afish@apple.com> Cc: Leif Lindholm <leif@nuviainc.com> Cc: Michael Kubacki <michael.kubacki@microsoft.com> Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
2021-01-16EmulatorPkg/library: RedfishPlatformCredentialLibAbner Chang2-0/+286
Platform specific implementation of acquiring credential to access to Redfish service. This is the platform library which incorporates with Redfish Credential DXE driver under Redfish package. Signed-off-by: Abner Chang <abner.chang@hpe.com> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Cc: Nickle Wang <nickle.wang@hpe.com> Cc: Peter O'Hanley <peter.ohanley@hpe.com> Acked-by: Ray Ni <ray.ni@intel.com>
2020-12-03EmulatorPkg/RedfishPlatformHostInterfaceLib libraryAbner Chang2-0/+575
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3102 Platform specific implementation of providing Redfish host interface information. Signed-off-by: Jiaxin Wu <jiaxin.wu@intel.com> Signed-off-by: Ting Ye <ting.ye@intel.com> Signed-off-by: Siyuan Fu <siyuan.fu@intel.com> Signed-off-by: Fan Wang <fan.wang@intel.com> Signed-off-by: Abner Chang <abner.chang@hpe.com> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Cc: Nickle Wang <nickle.wang@hpe.com> Cc: Peter O'Hanley <peter.ohanley@hpe.com> Acked-by: Ray Ni <ray.ni@intel.com>
2019-10-09EmulatorPkg/DxeTimerLib: drop superfluous castLaszlo Ersek1-1/+1
"gTimerEvent" has type EFI_EVENT already, drop the superfluous cast. Cc: Andrew Fish <afish@apple.com> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Ray Ni <ray.ni@intel.com> Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Ray Ni <ray.ni@intel.com> Reviewed-by: Philippe Mathieu-Daude <philmd@redhat.com>
2019-09-19EmulatorPkg/TimerLib: Add missing GetTimeInNanoSecond functionMichael Johnson3-3/+134
Add GetTimeInNanoSecond, already declared in the TimerLib API, to EmulatorPkg implementations of TimerLib. Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Signed-off-by: Michael Johnson <michael.johnson@intel.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
2019-09-17EmulatorPkg/PeiEmuSerialPortLib: Update the INF file Guidshenglei1-1/+1
FILE GUID in PeiEmuSerialPortLib.inf is same to MdePkg\Library\BaseSerialPortLibNull\BaseSerialPortLibNull.inf. PeiEmuSerialPortLib.inf FILE_GUID should be updated. https://bugzilla.tianocore.org/show_bug.cgi?id=2144 Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Signed-off-by: Shenglei Zhang <shenglei.zhang@intel.com> Reviewed-by: Ray Ni <ray.ni@Intel.com>
2019-08-19EmulatorPkg: Add -D DISABLE_NEW_DEPRECATED_INTERFACESMichael D Kinney2-5/+10
https://bugzilla.tianocore.org/show_bug.cgi?id=162 Update EmulatorPkg specific modules and libraries to use safe string functions in BaseLib and safe PcdSetxx() functions in PcdLib. With these updates, the define DISABLE_NEW_DEPRECATED_INTERFACES is enabled in the DSC file. Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Hao A Wu <hao.a.wu@intel.com> Acked-by: Jordan Justen <jordan.l.justen@intel.com> Tested-by: Andrew Fish <afish@apple.com>
2019-05-10EmulatorPkg: Make the shell be the first boot optionZhiguang Liu1-0/+30
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=1649 Make the shell be the first boot option by default, So it can boot into UEFI Internal Shell directly Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
2019-05-08EmulatorPkg: Support a second GOP windowZhiguang Liu1-0/+36
Two GOP screens will be created if PcdEmuGop is set in EmulatorPkg.dsc: gEmulatorPkgTokenSpaceGuid.PcdEmuGop|L"GOP Window 1!GOP Window 2" REF:https://bugzilla.tianocore.org/show_bug.cgi?id=1687 Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2019-04-09EmulatorPkg: Replace BSD License with BSD+Patent LicenseMichael D Kinney48-316/+48
https://bugzilla.tianocore.org/show_bug.cgi?id=1373 Replace BSD 2-Clause License with BSD+Patent License. This change is based on the following emails: https://lists.01.org/pipermail/edk2-devel/2019-February/036260.html https://lists.01.org/pipermail/edk2-devel/2018-October/030385.html RFCs with detailed process for the license change: V3: https://lists.01.org/pipermail/edk2-devel/2019-March/038116.html V2: https://lists.01.org/pipermail/edk2-devel/2019-March/037669.html V1: https://lists.01.org/pipermail/edk2-devel/2019-March/037500.html Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
2018-09-25EmulatorPkg: Removing ipf which is no longer supported from edk2.Chen A Chen15-31/+31
Removing rules for Ipf sources file: * Remove the source file which path with "ipf" and also listed in [Sources.IPF] section of INF file. * Remove the source file which listed in [Components.IPF] section of DSC file and not listed in any other [Components] section. * Remove the embedded Ipf code for MDE_CPU_IPF. Removing rules for Inf file: * Remove IPF from VALID_ARCHITECTURES comments. * Remove DXE_SAL_DRIVER from LIBRARY_CLASS in [Defines] section. * Remove the INF which only listed in [Components.IPF] section in DSC. * Remove statements from [BuildOptions] that provide IPF specific flags. * Remove any IPF sepcific sections. Removing rules for Dec file: * Remove [Includes.IPF] section from Dec. Removing rules for Dsc file: * Remove IPF from SUPPORTED_ARCHITECTURES in [Defines] section of DSC. * Remove any IPF specific sections. * Remove statements from [BuildOptions] that provide IPF specific flags. Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Chen A Chen <chen.a.chen@intel.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2018-09-06EmulatorPkg/PlatformBmLib: Fix GCC build failureRuiyu Ni1-14/+0
Some local variables are initialized but never used. GCC complains about that. The patch fixes this issue. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Dandan Bi <dandan.bi@intel.com>
2018-08-31EmulatorPkg: Use MdeModulePkg/Bds moduleRuiyu Ni6-614/+617
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1120 Logo is enabled by adding a separate core driver LogoDxe. UiApp and BootManagerMenuApp are added to provide two UIs. LoadFileOnFv2 is added to auto-install LoadFile protocol for applications in FV so the boot options for applications can be auto-created from LoadFile. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Hao Wu <hao.a.wu@intel.com> Cc: Andrew Fish <afish@apple.com>
2018-08-30EmulatorPkg: formalize line endingsRuiyu Ni15-818/+818
The patch is the result of running "BaseTools/Scripts/FormatDosFiles.py EmulatorPkg/" No functionality impact. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Hao A Wu <hao.a.wu@intel.com> Cc: Liming Gao <liming.gao@intel.com>
2018-08-27EmulatorPkg/PlatformBds: Signal EndOfDxe in platform BDSRuiyu Ni3-4/+9
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1079 Without signal of EndOfDxe, the 3rd party code (.efi from non-flash storage) cannot run. It's forbidden by 8be37a5cee700777ca8e8e8a34cc2225b21931a7 *MdeModulePkg/SecurityStubDxe: Defer 3rd party image before EndOfDxe The patch enables running of SCT from internal shell. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Hao A Wu <hao.a.wu@intel.com> Cc: Andrew Fish <afish@apple.com>
2018-08-27EmulatorPkg/ThunkProtocolList: Fix VS build failureRuiyu Ni1-2/+2
VS compiler complains converting UINTN to UINT16 causes data lost. Add typecast to fix the build failure. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Cc: Andrdw Fish <afish@apple.com> Reviewed-by: Hao A Wu <hao.a.wu@intel.com>
2018-05-24EmulatorPkg/SmbiosLib: Declare the correct library class.Marvin Häuser1-1/+1
Currently, SmbiosLib declares the PcdLib library class. Update the declaration to declare SmbiosLib. V2: - Do not change the copyright date as requested. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Marvin Haeuser <Marvin.Haeuser@outlook.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2016-10-19EmulatorPkg: Fix typos in comments and variablesGary Lin1-4/+4
- Predfined -> Predefined - minimue -> minimum - predeined -> predefined - excute -> execute - availible -> available - discontiguous -> discontinuous - permenent -> permanent - immediatly -> immediately - environmemt -> environment - Seperator -> Separator - remmeber -> remember - initailized -> initialized Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Gary Lin <glin@suse.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2015-11-26EmulatorPkg: Use SerialDxe in MdeModulePkg instead of EmbeddedPkgStar Zeng1-1/+90
It is also to add GetControl/SetControl/SetAttributes implementation for DxeEmuSerialPortLib. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@18967 6f19259b-4bc3-4df7-8a09-765794883524
2015-05-06EmulatorPkg: Use the new PCDs defined in MdePkg.Ruiyu Ni1-2/+2
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17319 6f19259b-4bc3-4df7-8a09-765794883524
2014-07-04EmulatorPkg: Add structure braces { } to fix build warningJordan Justen1-4/+6
The GCC parameter -Wno-missing-braces was recently removed. This caused build warnings where structures were instantiated without proper brace usage. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15632 6f19259b-4bc3-4df7-8a09-765794883524
2014-01-16Update PeiServicesTablePointerLib instance to add new API ↵Gao, Liming3-0/+78
MigratePeiServicesTablePointer Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Gao, Liming <liming.gao@intel.com> Reviewed-By: Andrew Fish <afish@apple.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15128 6f19259b-4bc3-4df7-8a09-765794883524
2013-05-14EmulatorPkg/(Pei|Dxe)EmuSerialPortLib: Remove the SerialPortExtLib functions ↵oliviermartin2-111/+0
from SerialPortLib SerialPortSetControl, SerialPortGetControl and SerialPortSetAttributes are functions of the SerialPortExtLib library interface. They should not be implemented by the SerialPortLib library. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <Olivier.martin@arm.com> Reviewed-by: Andrew Fish <afish@apple.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14357 6f19259b-4bc3-4df7-8a09-765794883524
2012-12-22Sync with EmulatorPkg changes.andrewfish4-0/+111
signed-off-by:afish@apple.com git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14015 6f19259b-4bc3-4df7-8a09-765794883524
2012-12-22Fix structure init issues.andrewfish2-3/+7
signed-off-by:afish@apple.com git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14014 6f19259b-4bc3-4df7-8a09-765794883524
2012-08-15EmulatorPkg: Fix Visual Studio build for IA32 & X64jljusten2-4/+6
This code is untested since there is currently no 'host' component for Win32/Win64. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13633 6f19259b-4bc3-4df7-8a09-765794883524
2012-01-31Update based on review feedback.andrewfish1-7/+8
signed-off-by:andrewfish reviewed-by:Elvin git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12976 6f19259b-4bc3-4df7-8a09-765794883524
2012-01-30cleanup SmbiosLib.h definitions, and the code that depends on them. andrewfish1-25/+17
signed-off-by:andrewfish reviewed-by:mikekinney git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12970 6f19259b-4bc3-4df7-8a09-765794883524
2012-01-30Oops missed these items in 12966. Also forgot the signoff, this signoff ↵andrewfish2-0/+404
includes svn 12966. signed-off-by:andrewfish git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12967 6f19259b-4bc3-4df7-8a09-765794883524
2011-08-11EmulatorPkg: Make the library work with DXE Core.andrewfish1-0/+4
The DXE core calls library constructors after it calls DEBUG macros, so we need more error handling in the lib. signed-off-by: andrewfish git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12118 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-28EmulatorPkg: Remove all trailing whitespacejljusten42-348/+348
Signed-off-by: jljusten git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11919 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-28InOsEmuPkg: Rename package to EmulatorPkg & Sec to Hostjljusten45-0/+5576
* Rename InOsEmuPkg to EmulatorPkg * Rename Unix/Sec to Unix/Host Signed-off-by: jljusten Reviewed-by: andrewfish Reviewed-by: geekboy15a git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11918 6f19259b-4bc3-4df7-8a09-765794883524