summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Medhurst <tixy@linaro.org>2012-01-27 14:40:33 +0000
committerJon Medhurst <tixy@linaro.org>2012-01-27 14:40:33 +0000
commit0e7b8cbd79e281b956a8706bfcbe08493bd8a7bd (patch)
tree6388d9d1d75eae1fae92ea18a473c9b4a4459112
parent9134f82797b14368305c9d424f42fec00376cf3a (diff)
parent7c00d189a686329426c7ed353255e13606f0c5e2 (diff)
Merge branch 'armlt-tracking' of git://git.linaro.org/arm/uefi/uefi-nextlinaro-uefi-2012.01
-rw-r--r--edk2/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc2
-rw-r--r--edk2/ArmPlatformPkg/ArmPlatformPkg.dsc2
-rw-r--r--edk2/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc2
-rw-r--r--edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEb.c49
-rw-r--r--edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf2
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc4
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf25
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc4
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf6
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc4
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf6
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc4
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf8
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc2
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressSecLib.inf2
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpress.c193
-rw-r--r--edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf4
-rw-r--r--edk2/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c2
-rw-r--r--edk2/ArmPlatformPkg/Include/Library/LcdPlatformLib.h2
-rw-r--r--edk2/ArmPlatformPkg/Sec/Sec.c2
-rw-r--r--edk2/BaseTools/Bin/Win32/BPDG.exebin579301 -> 579301 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/BootSectImage.exebin434176 -> 434176 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/EfiLdrImage.exebin421888 -> 421888 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/EfiRom.exebin446464 -> 446464 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/Fpd2Dsc.exebin1432708 -> 1432708 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenBootSector.exebin425984 -> 425984 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenCrc32.exebin425984 -> 425984 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenDepex.exebin637672 -> 637672 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenFds.exebin1646441 -> 1646631 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenFfs.exebin430080 -> 430080 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenFv.exebin479232 -> 479232 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenFw.exebin495616 -> 495616 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenPage.exebin421888 -> 421888 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenPatchPcdTable.exebin631676 -> 631676 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenSec.exebin446464 -> 446464 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/GenVtf.exebin446464 -> 446464 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/LzmaCompress.exebin397312 -> 397312 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/MigrationMsa2Inf.exebin1378094 -> 1378094 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/PatchPcdValue.exebin563443 -> 563443 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/Spd2Dec.exebin665034 -> 665034 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/Split.exebin425984 -> 425984 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/TargetTool.exebin585291 -> 585291 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/TianoCompress.exebin434176 -> 434176 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/Trim.exebin843112 -> 843112 bytes
-rw-r--r--edk2/BaseTools/Bin/Win32/UPT.exebin2331847 -> 2331295 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/VfrCompile.exebin1277952 -> 1277952 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/VolInfo.exebin471040 -> 471040 bytes
-rwxr-xr-xedk2/BaseTools/Bin/Win32/build.exebin3065710 -> 3066339 bytes
-rw-r--r--edk2/BaseTools/Source/C/Include/Common/BuildVersion.h20
-rw-r--r--edk2/BaseTools/Source/Python/AutoGen/AutoGen.py22
-rw-r--r--edk2/BaseTools/Source/Python/AutoGen/GenC.py29
-rw-r--r--edk2/BaseTools/Source/Python/Common/BuildVersion.py17
-rw-r--r--edk2/BaseTools/Source/Python/Ecc/Ecc.py42
-rw-r--r--edk2/BaseTools/Source/Python/Ecc/MetaFileWorkspace/MetaFileParser.py8
-rw-r--r--edk2/BaseTools/Source/Python/GenFds/FdfParser.py2
-rw-r--r--edk2/BaseTools/Source/Python/GenFds/Fv.py2
-rw-r--r--edk2/BaseTools/Source/Python/UPT/BuildVersion.py21
-rw-r--r--edk2/BaseTools/Source/Python/UPT/InstallPkg.py2
-rw-r--r--edk2/BaseTools/Source/Python/UPT/Library/ParserValidate.py2
-rw-r--r--edk2/BaseTools/Source/Python/UPT/Library/String.py29
-rw-r--r--edk2/BaseTools/Source/Python/UPT/Parser/InfParser.py2
-rw-r--r--edk2/BaseTools/Source/Python/UPT/PomAdapter/InfPomAlignment.py1
-rw-r--r--edk2/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py19
-rw-r--r--edk2/BaseTools/Source/Python/build/build.py19
-rw-r--r--edk2/BeagleBoardPkg/BeagleBoardPkg.fdf2
-rwxr-xr-xedk2/BeagleBoardPkg/build.sh21
-rw-r--r--edk2/BuildNotes2.txt15
-rw-r--r--edk2/CryptoPkg/Library/OpensslLib/OpensslLib.inf2
-rw-r--r--edk2/DuetPkg/BootSector/GNUmakefile34
-rw-r--r--edk2/DuetPkg/BootSector/Mbr.S4
-rw-r--r--edk2/DuetPkg/BootSector/bin/bs32.combin512 -> 512 bytes
-rw-r--r--edk2/DuetPkg/BootSector/bs32.S12
-rw-r--r--edk2/DuetPkg/BootSector/bs32.asm12
-rw-r--r--edk2/DuetPkg/BootSector/efi64.S96
-rw-r--r--edk2/DuetPkg/BootSector/st16_64.S21
-rw-r--r--edk2/DuetPkg/BootSector/st32_64.S23
-rw-r--r--edk2/DuetPkg/BootSector/start32.S8
-rw-r--r--edk2/DuetPkg/BootSector/start64.S15
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Framework/Guid/DataHubRecords/DataHubSubClassCache.h7
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Include/EfiDebug.h8
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Include/Library/EdkIIGlueDebugLib.h7
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.S33
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.asm5
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.S5
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.asm5
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.S5
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.asm5
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.S2
-rw-r--r--edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.asm2
-rw-r--r--edk2/EmbeddedPkg/Library/PrePiLib/FwVol.c1
-rw-r--r--edk2/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf2
-rw-r--r--edk2/EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf2
-rw-r--r--edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.c286
-rw-r--r--edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.inf3
-rw-r--r--edk2/EmulatorPkg/CpuRuntimeDxe/CpuDriver.h8
-rw-r--r--edk2/EmulatorPkg/CpuRuntimeDxe/CpuIo.c5
-rw-r--r--edk2/EmulatorPkg/CpuRuntimeDxe/MpService.c12
-rw-r--r--edk2/EmulatorPkg/CpuRuntimeDxe/Strings.unibin1712 -> 0 bytes
-rw-r--r--edk2/EmulatorPkg/EmuSnpDxe/EmuSnpDxe.c48
-rw-r--r--edk2/EmulatorPkg/EmulatorPkg.dec4
-rw-r--r--edk2/EmulatorPkg/Unix/Host/BlockIo.c2
-rw-r--r--edk2/EmulatorPkg/Unix/Host/Host.c109
-rw-r--r--edk2/EmulatorPkg/Unix/Host/Host.inf3
-rw-r--r--edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec2
-rw-r--r--edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dsc2
-rw-r--r--edk2/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsMisc.c118
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c14
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Bm.vfr16
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c167
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FileExplorer.c50
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FormGuid.h1
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/UpdatePage.c12
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Variable.c5
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.c2
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManager.c53
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManagerVfr.h1
-rw-r--r--edk2/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPage.c47
-rw-r--r--edk2/IntelFrameworkPkg/Include/Guid/DataHubRecords.h5
-rw-r--r--edk2/IntelFrameworkPkg/IntelFrameworkPkg.dec2
-rw-r--r--edk2/IntelFrameworkPkg/IntelFrameworkPkg.dsc4
-rw-r--r--edk2/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.c6
-rw-r--r--edk2/MdeModulePkg/Bus/Pci/PciBusDxe/PciIo.c18
-rw-r--r--edk2/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c111
-rw-r--r--edk2/MdeModulePkg/Core/Dxe/DxeMain.h61
-rw-r--r--edk2/MdeModulePkg/Core/Dxe/FwVol/FwVol.c2
-rw-r--r--edk2/MdeModulePkg/Core/Dxe/FwVol/FwVolDriver.h16
-rw-r--r--edk2/MdeModulePkg/Core/Pei/Image/Image.c4
-rw-r--r--edk2/MdeModulePkg/Include/Protocol/FormBrowserEx.h2
-rw-r--r--edk2/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.c3
-rw-r--r--edk2/MdeModulePkg/MdeModulePkg.dec2
-rw-r--r--edk2/MdeModulePkg/MdeModulePkg.dsc2
-rw-r--r--edk2/MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableProtocol.c14
-rw-r--r--edk2/MdeModulePkg/Universal/DevicePathDxe/DevicePathToText.c8
-rw-r--r--edk2/MdeModulePkg/Universal/DriverSampleDxe/DriverSample.c95
-rw-r--r--edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c85
-rw-r--r--edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxe.vfr13
-rw-r--r--edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.vfr15
-rw-r--r--edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigNv.c2
-rw-r--r--edk2/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c11
-rw-r--r--edk2/MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigImpl.c37
-rw-r--r--edk2/MdeModulePkg/Universal/PCD/Dxe/Service.c1
-rw-r--r--edk2/MdeModulePkg/Universal/PCD/Pei/Service.c1
-rw-r--r--edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/PlatDriOverrideDxe.c73
-rw-r--r--edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/Vfr.vfr11
-rw-r--r--edk2/MdeModulePkg/Universal/SetupBrowserDxe/Expression.c4
-rw-r--r--edk2/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c4
-rw-r--r--edk2/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c71
-rw-r--r--edk2/MdePkg/Include/IndustryStandard/SmBios.h60
-rw-r--r--edk2/MdePkg/Include/Library/DebugLib.h6
-rw-r--r--edk2/MdePkg/Include/Pi/PiDxeCis.h3
-rw-r--r--edk2/MdePkg/Include/Uefi/UefiInternalFormRepresentation.h4
-rw-r--r--edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.S9
-rw-r--r--edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.asm5
-rw-r--r--edk2/MdePkg/Library/BaseLib/X64/Thunk16.S5
-rw-r--r--edk2/MdePkg/Library/BaseLib/X64/Thunk16.asm5
-rw-r--r--edk2/MdePkg/MdePkg.dec7
-rw-r--r--edk2/NetworkPkg/IScsiDxe/IScsiConfig.c228
-rw-r--r--edk2/NetworkPkg/IScsiDxe/IScsiConfigVfr.vfr39
-rw-r--r--edk2/NetworkPkg/Ip6Dxe/Ip6Config.vfr22
-rw-r--r--edk2/NetworkPkg/Ip6Dxe/Ip6ConfigNv.c384
-rw-r--r--edk2/NetworkPkg/NetworkPkg.dec2
-rw-r--r--edk2/NetworkPkg/NetworkPkg.dsc2
-rw-r--r--edk2/NetworkPkg/UefiPxeBcDxe/PxeBcDhcp6.c12
-rw-r--r--edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c38
-rw-r--r--edk2/OptionRomPkg/Library/FrameBufferBltLib/FrameBufferBltLib.inf4
-rw-r--r--edk2/OptionRomPkg/Library/GopBltLib/GopBltLib.inf4
-rw-r--r--edk2/OvmfPkg/QemuVideoDxe/QemuVideoDxe.inf4
-rw-r--r--edk2/SecurityPkg/SecurityPkg.dec2
-rw-r--r--edk2/SecurityPkg/SecurityPkg.dsc2
-rw-r--r--edk2/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c2
-rw-r--r--edk2/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c2
-rw-r--r--edk2/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.c6
-rw-r--r--edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c16
-rw-r--r--edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h1
-rw-r--r--edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c268
-rw-r--r--edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr24
-rw-r--r--edk2/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c2
-rw-r--r--edk2/ShellBinPkg/ShellBinPkg.dec6
-rw-r--r--edk2/ShellPkg/Application/Shell/Shell.c11
-rw-r--r--edk2/ShellPkg/Application/Shell/Shell.unibin4416 -> 4618 bytes
-rw-r--r--edk2/ShellPkg/Application/Shell/ShellProtocol.c12
-rw-r--r--edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c205
-rw-r--r--edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h33
-rw-r--r--edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf229
-rw-r--r--edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.unibin17334 -> 24050 bytes
-rw-r--r--edk2/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c14
-rw-r--r--edk2/ShellPkg/Library/UefiShellLevel1CommandsLib/For.c8
-rw-r--r--edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Ls.c15
-rw-r--r--edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Parse.c36
-rw-r--r--edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c10
-rw-r--r--edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c7
-rw-r--r--edk2/ShellPkg/Library/UefiShellLib/UefiShellLib.c10
-rw-r--r--edk2/ShellPkg/Readme.txt5
-rw-r--r--edk2/ShellPkg/ShellPkg.dec8
-rw-r--r--edk2/SourceLevelDebugPkg/Readme.txt22
-rw-r--r--edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dec4
-rw-r--r--edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dsc2
-rw-r--r--edk2/StdLib/Include/netinet/tcp.h132
-rw-r--r--edk2/UefiCpuPkg/UefiCpuPkg.dec4
-rw-r--r--edk2/UefiCpuPkg/UefiCpuPkg.dsc2
-rw-r--r--edk2/UnixPkg/UnixSnpDxe/UnixSnpDxe.inf4
201 files changed, 2844 insertions, 1672 deletions
diff --git a/edk2/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc b/edk2/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc
index a1b7929c2..76eb187a3 100644
--- a/edk2/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc
+++ b/edk2/ArmPlatformPkg/ArmPlatformPkg-2ndstage.dsc
@@ -117,7 +117,7 @@
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/PrePi/PrePiArmPlatformGlobalVariableLib.inf
- DebugSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
+ ArmPlatformSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
DebugAgentLib|ArmPkg/Library/DebugAgentSymbolsOnlyLib/DebugAgentSymbolsOnlyLib.inf
PrePiLib|EmbeddedPkg/Library/PrePiLib/PrePiLib.inf
diff --git a/edk2/ArmPlatformPkg/ArmPlatformPkg.dsc b/edk2/ArmPlatformPkg/ArmPlatformPkg.dsc
index e83e1030c..551e73936 100644
--- a/edk2/ArmPlatformPkg/ArmPlatformPkg.dsc
+++ b/edk2/ArmPlatformPkg/ArmPlatformPkg.dsc
@@ -116,7 +116,7 @@
ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7LibSec.inf
ArmPlatformLib|ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNullSec.inf
- DebugSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
+ ArmPlatformSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf
DebugAgentLib|ArmPkg/Library/DebugAgentSymbolsOnlyLib/DebugAgentSymbolsOnlyLib.inf
diff --git a/edk2/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc b/edk2/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc
index 2c162edef..1ef593f08 100644
--- a/edk2/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc
+++ b/edk2/ArmPlatformPkg/ArmRealViewEbPkg/ArmRealViewEb.dsc.inc
@@ -99,7 +99,7 @@
BdsLib|ArmPkg/Library/BdsLib/BdsLib.inf
[LibraryClasses.common.SEC]
- DebugSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
+ ArmPlatformSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf
DebugAgentLib|ArmPkg/Library/DebugAgentSymbolsOnlyLib/DebugAgentSymbolsOnlyLib.inf
diff --git a/edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEb.c b/edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEb.c
index c4140150f..713ff0cf2 100644
--- a/edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEb.c
+++ b/edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEb.c
@@ -13,9 +13,13 @@
#include <PiDxe.h>
-#include <Library/LcdPlatformLib.h>
-#include <Library/IoLib.h>
#include <Library/DebugLib.h>
+#include <Library/IoLib.h>
+#include <Library/LcdPlatformLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+
+#include <Protocol/EdidDiscovered.h>
+#include <Protocol/EdidActive.h>
#include <Drivers/PL111Lcd.h>
@@ -38,26 +42,45 @@ typedef struct {
CLCD_RESOLUTION mResolutions[] = {
- { // Mode 0 : VGA : 640 x 480 x 24 bpp
- VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, 0x2C77,
- VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
- VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
- },
- { // Mode 1 : SVGA : 800 x 600 x 24 bpp
- SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, 0x2CAC,
- SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
- SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
- }
+ { // Mode 0 : VGA : 640 x 480 x 24 bpp
+ VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, 0x2C77,
+ VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
+ VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
+ },
+ { // Mode 1 : SVGA : 800 x 600 x 24 bpp
+ SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, 0x2CAC,
+ SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
+ SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
+ }
};
+EFI_EDID_DISCOVERED_PROTOCOL mEdidDiscovered = {
+ 0,
+ NULL
+};
+
+EFI_EDID_ACTIVE_PROTOCOL mEdidActive = {
+ 0,
+ NULL
+};
EFI_STATUS
LcdPlatformInitializeDisplay (
- VOID
+ IN EFI_HANDLE Handle
)
{
+ EFI_STATUS Status;
+
MmioWrite32(ARM_EB_SYS_CLCD_REG, 1);
+ // Install the EDID Protocols
+ Status = gBS->InstallMultipleProtocolInterfaces(
+ &Handle,
+ &gEfiEdidDiscoveredProtocolGuid, &mEdidDiscovered,
+ &gEfiEdidActiveProtocolGuid, &mEdidActive,
+ NULL
+ );
+
return EFI_SUCCESS;
}
diff --git a/edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf b/edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf
index f2a441994..667f2c745 100644
--- a/edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf
+++ b/edk2/ArmPlatformPkg/ArmRealViewEbPkg/Library/PL111LcdArmRealViewEbLib/PL111LcdArmRealViewEbLib.inf
@@ -36,6 +36,8 @@
[Guids]
[Protocols]
+ gEfiEdidDiscoveredProtocolGuid # Produced
+ gEfiEdidActiveProtocolGuid # Produced
[FixedPcd.common]
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc
index d2c13a9ff..24ba96a94 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.dsc
@@ -21,8 +21,8 @@
PLATFORM_GUID = eb2bd5ff-2379-4a06-9c12-db905cdee9ea
PLATFORM_VERSION = 0.1
DSC_SPECIFICATION = 0x00010005
-!ifdef $(EDK2_ARMVE_STANDALONE)
- OUTPUT_DIRECTORY = Build/ArmVExpress-CTA9x4-Standalone
+!ifdef $(EDK2_OUT_DIR)
+ OUTPUT_DIRECTORY = $(EDK2_OUT_DIR)
!else
OUTPUT_DIRECTORY = Build/ArmVExpress-CTA9x4
!endif
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf
index 84d4fc590..67057d709 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA9x4.fdf
@@ -25,6 +25,7 @@
#
################################################################################
+!ifndef $(EDK2_ARMVE_SINGLE_BINARY)
[FD.Sec_ArmVExpress_EFI]
BaseAddress = 0x44000000|gArmTokenSpaceGuid.PcdSecureFdBaseAddress #The base address of the Secure FLASH Device.
Size = 0x00080000|gArmTokenSpaceGuid.PcdSecureFdSize #The size in bytes of the Secure FLASH Device
@@ -51,20 +52,32 @@ NumBlocks = 0x80
0x00000000|0x00080000
gArmTokenSpaceGuid.PcdSecureFvBaseAddress|gArmTokenSpaceGuid.PcdSecureFvSize
FV = FVMAIN_SEC
-
+!endif // RMH - EDK2_ARMVE_SINGLE_BINARY
[FD.ArmVExpress_EFI]
!if $(EDK2_ARMVE_STANDALONE) == 1
+!if $(EDK2_ARMVE_SINGLE_BINARY) == 1
+BaseAddress = 0x44000000|gArmTokenSpaceGuid.PcdFdBaseAddress # The base address of the Firmware in NOR Flash.
+!else
BaseAddress = 0x45000000|gArmTokenSpaceGuid.PcdFdBaseAddress # The base address of the Firmware in NOR Flash.
+!endif // RMH - EDK2_ARMVE_SINGLE_BINARY
!else
BaseAddress = 0x80000000|gArmTokenSpaceGuid.PcdFdBaseAddress # The base address of the Firmware in remapped DRAM.
!endif
+!if $(EDK2_ARMVE_SINGLE_BINARY) == 1
+Size = 0x00280000|gArmTokenSpaceGuid.PcdFdSize # The size in bytes of the FLASH Device
+!else
Size = 0x00200000|gArmTokenSpaceGuid.PcdFdSize # The size in bytes of the FLASH Device
+!endif // RMH - EDK2_ARMVE_SINGLE_BINARY
ErasePolarity = 1
# This one is tricky, it must be: BlockSize * NumBlocks = Size
BlockSize = 0x00001000
+!if $(EDK2_ARMVE_SINGLE_BINARY) == 1
+NumBlocks = 0x280
+!else
NumBlocks = 0x200
+!endif // RMH - EDK2_ARMVE_SINGLE_BINARY
################################################################################
#
@@ -81,11 +94,19 @@ NumBlocks = 0x200
# RegionType <FV, DATA, or FILE>
#
################################################################################
+!if $(EDK2_ARMVE_SINGLE_BINARY) == 1
+0x00000000|0x00080000
+gArmTokenSpaceGuid.PcdSecureFvBaseAddress|gArmTokenSpaceGuid.PcdSecureFvSize
+FV = FVMAIN_SEC
+0x00080000|0x00280000
+gArmTokenSpaceGuid.PcdFvBaseAddress|gArmTokenSpaceGuid.PcdFvSize
+FV = FVMAIN_COMPACT
+!else
0x00000000|0x00200000
gArmTokenSpaceGuid.PcdFvBaseAddress|gArmTokenSpaceGuid.PcdFvSize
FV = FVMAIN_COMPACT
-
+!endif // RMH - EDK2_ARMVE_SINGLE_BINARY
################################################################################
#
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc
index 28527dcd8..7de7da234 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.dsc
@@ -136,6 +136,10 @@
## PL111 Versatile Express Motherboard controller
gArmPlatformTokenSpaceGuid.PcdPL111LcdBase|0x1C1F0000
+ ## PL180 MMC/SD card controller
+ gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x1C010048
+ gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x1C050000
+
#
# ARM PL390 General Interrupt Controller
#
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf
index b7b40b20f..3d5d4fc78 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15.fdf
@@ -158,6 +158,12 @@ READ_LOCK_STATUS = TRUE
INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
#
+ # Multimedia Card Interface
+ #
+ INF EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf
+ INF ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf
+
+ #
# UEFI application (Shell Embedded Boot Loader)
#
INF EmbeddedPkg/Ebl/Ebl.inf
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc
index 6f0e6bbee..2bb5aaf86 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.dsc
@@ -136,6 +136,10 @@
## PL111 Versatile Express Motherboard controller
gArmPlatformTokenSpaceGuid.PcdPL111LcdBase|0x1C1F0000
+ ## PL180 MMC/SD card controller
+ gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x1C010048
+ gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x1C050000
+
#
# ARM PL390 General Interrupt Controller
#
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf
index 246d9fd30..0624a5dfe 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A15_MPCore.fdf
@@ -158,6 +158,12 @@ READ_LOCK_STATUS = TRUE
INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
#
+ # Multimedia Card Interface
+ #
+ INF EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf
+ INF ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf
+
+ #
# UEFI application (Shell Embedded Boot Loader)
#
INF EmbeddedPkg/Ebl/Ebl.inf
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc
index 300c303c5..6287cc966 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.dsc
@@ -146,6 +146,10 @@
## PL111 Versatile Express Motherboard controller
gArmPlatformTokenSpaceGuid.PcdPL111LcdBase|0x1C1F0000
+
+ ## PL180 MMC/SD card controller
+ gArmPlatformTokenSpaceGuid.PcdPL180SysMciRegAddress|0x1C010048
+ gArmPlatformTokenSpaceGuid.PcdPL180MciBaseAddress|0x1C050000
#
# ARM PL390 General Interrupt Controller
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf
index b59f8be8e..d930b18fc 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-RTSM-A9x4.fdf
@@ -155,7 +155,13 @@ READ_LOCK_STATUS = TRUE
INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
INF FatPkg/EnhancedFatDxe/Fat.inf
INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
-
+
+ #
+ # Multimedia Card Interface
+ #
+ INF EmbeddedPkg/Universal/MmcDxe/MmcDxe.inf
+ INF ArmPlatformPkg/Drivers/PL180MciDxe/PL180MciDxe.inf
+
#
# UEFI application (Shell Embedded Boot Loader)
#
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc
index 6d8c828c7..6242891c5 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/ArmVExpress.dsc.inc
@@ -101,7 +101,7 @@
BdsLib|ArmPkg/Library/BdsLib/BdsLib.inf
[LibraryClasses.common.SEC]
- DebugSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
+ ArmPlatformSecExtraActionLib|ArmPlatformPkg/Library/DebugSecExtraActionLib/DebugSecExtraActionLib.inf
ArmPlatformGlobalVariableLib|ArmPlatformPkg/Library/ArmPlatformGlobalVariableLib/Sec/SecArmPlatformGlobalVariableLib.inf
DebugAgentLib|ArmPkg/Library/DebugAgentSymbolsOnlyLib/DebugAgentSymbolsOnlyLib.inf
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressSecLib.inf b/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressSecLib.inf
index 9d9c237c2..03aee0378 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressSecLib.inf
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA9x4/ArmVExpressSecLib.inf
@@ -30,7 +30,7 @@
ArmLib
ArmTrustZoneLib
ArmPlatformSysConfigLib
- DebugSecExtraActionLib
+ ArmPlatformSecExtraActionLib
IoLib
L2X0CacheLib
PL301AxiLib
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpress.c b/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpress.c
index 31a3549f1..f6f01fa20 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpress.c
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpress.c
@@ -21,6 +21,8 @@
#include <Library/UefiBootServicesTableLib.h>
#include <Protocol/Cpu.h>
+#include <Protocol/EdidDiscovered.h>
+#include <Protocol/EdidActive.h>
#include <ArmPlatform.h>
@@ -41,94 +43,119 @@ typedef struct {
LCD_RESOLUTION mResolutions[] = {
- { // Mode 0 : VGA : 640 x 480 x 24 bpp
- VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, VGA_OSC_FREQUENCY,
- VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
- VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
- },
- { // Mode 1 : SVGA : 800 x 600 x 24 bpp
- SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, SVGA_OSC_FREQUENCY,
- SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
- SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
- },
- { // Mode 2 : XGA : 1024 x 768 x 24 bpp
- XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, XGA_OSC_FREQUENCY,
- XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
- XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
- },
- { // Mode 3 : SXGA : 1280 x 1024 x 24 bpp
- SXGA, SXGA_H_RES_PIXELS, SXGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, (SXGA_OSC_FREQUENCY/2),
- SXGA_H_SYNC, SXGA_H_BACK_PORCH, SXGA_H_FRONT_PORCH,
- SXGA_V_SYNC, SXGA_V_BACK_PORCH, SXGA_V_FRONT_PORCH
- },
- { // Mode 4 : UXGA : 1600 x 1200 x 24 bpp
- UXGA, UXGA_H_RES_PIXELS, UXGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, (UXGA_OSC_FREQUENCY/2),
- UXGA_H_SYNC, UXGA_H_BACK_PORCH, UXGA_H_FRONT_PORCH,
- UXGA_V_SYNC, UXGA_V_BACK_PORCH, UXGA_V_FRONT_PORCH
- },
- { // Mode 5 : HD : 1920 x 1080 x 24 bpp
- HD, HD_H_RES_PIXELS, HD_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, (HD_OSC_FREQUENCY/2),
- HD_H_SYNC, HD_H_BACK_PORCH, HD_H_FRONT_PORCH,
- HD_V_SYNC, HD_V_BACK_PORCH, HD_V_FRONT_PORCH
- },
- { // Mode 6 : VGA : 640 x 480 x 16 bpp (565 Mode)
- VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_565, VGA_OSC_FREQUENCY,
- VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
- VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
- },
- { // Mode 7 : SVGA : 800 x 600 x 16 bpp (565 Mode)
- SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_565, SVGA_OSC_FREQUENCY,
- SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
- SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
- },
- { // Mode 8 : XGA : 1024 x 768 x 16 bpp (565 Mode)
- XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_565, XGA_OSC_FREQUENCY,
- XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
- XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
- },
- { // Mode 9 : VGA : 640 x 480 x 15 bpp
- VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_555, VGA_OSC_FREQUENCY,
- VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
- VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
- },
- { // Mode 10 : SVGA : 800 x 600 x 15 bpp
- SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_555, SVGA_OSC_FREQUENCY,
- SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
- SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
- },
- { // Mode 11 : XGA : 1024 x 768 x 15 bpp
- XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_555, XGA_OSC_FREQUENCY,
- XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
- XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
- },
- { // Mode 12 : XGA : 1024 x 768 x 15 bpp - All the timing info is derived from Linux Kernel Driver Settings
- XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_555, 63500000,
- XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
- XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
- },
- { // Mode 13 : VGA : 640 x 480 x 12 bpp (444 Mode)
- VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_12_444, VGA_OSC_FREQUENCY,
- VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
- VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
- },
- { // Mode 14 : SVGA : 800 x 600 x 12 bpp (444 Mode)
- SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_12_444, SVGA_OSC_FREQUENCY,
- SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
- SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
- },
- { // Mode 15 : XGA : 1024 x 768 x 12 bpp (444 Mode)
- XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_12_444, XGA_OSC_FREQUENCY,
- XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
- XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
- }
+ { // Mode 0 : VGA : 640 x 480 x 24 bpp
+ VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, VGA_OSC_FREQUENCY,
+ VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
+ VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
+ },
+ { // Mode 1 : SVGA : 800 x 600 x 24 bpp
+ SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, SVGA_OSC_FREQUENCY,
+ SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
+ SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
+ },
+ { // Mode 2 : XGA : 1024 x 768 x 24 bpp
+ XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, XGA_OSC_FREQUENCY,
+ XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
+ XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
+ },
+ { // Mode 3 : SXGA : 1280 x 1024 x 24 bpp
+ SXGA, SXGA_H_RES_PIXELS, SXGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, (SXGA_OSC_FREQUENCY/2),
+ SXGA_H_SYNC, SXGA_H_BACK_PORCH, SXGA_H_FRONT_PORCH,
+ SXGA_V_SYNC, SXGA_V_BACK_PORCH, SXGA_V_FRONT_PORCH
+ },
+ { // Mode 4 : UXGA : 1600 x 1200 x 24 bpp
+ UXGA, UXGA_H_RES_PIXELS, UXGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, (UXGA_OSC_FREQUENCY/2),
+ UXGA_H_SYNC, UXGA_H_BACK_PORCH, UXGA_H_FRONT_PORCH,
+ UXGA_V_SYNC, UXGA_V_BACK_PORCH, UXGA_V_FRONT_PORCH
+ },
+ { // Mode 5 : HD : 1920 x 1080 x 24 bpp
+ HD, HD_H_RES_PIXELS, HD_V_RES_PIXELS, LCD_BITS_PER_PIXEL_24, (HD_OSC_FREQUENCY/2),
+ HD_H_SYNC, HD_H_BACK_PORCH, HD_H_FRONT_PORCH,
+ HD_V_SYNC, HD_V_BACK_PORCH, HD_V_FRONT_PORCH
+ },
+ { // Mode 6 : VGA : 640 x 480 x 16 bpp (565 Mode)
+ VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_565, VGA_OSC_FREQUENCY,
+ VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
+ VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
+ },
+ { // Mode 7 : SVGA : 800 x 600 x 16 bpp (565 Mode)
+ SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_565, SVGA_OSC_FREQUENCY,
+ SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
+ SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
+ },
+ { // Mode 8 : XGA : 1024 x 768 x 16 bpp (565 Mode)
+ XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_565, XGA_OSC_FREQUENCY,
+ XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
+ XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
+ },
+ { // Mode 9 : VGA : 640 x 480 x 15 bpp
+ VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_555, VGA_OSC_FREQUENCY,
+ VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
+ VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
+ },
+ { // Mode 10 : SVGA : 800 x 600 x 15 bpp
+ SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_555, SVGA_OSC_FREQUENCY,
+ SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
+ SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
+ },
+ { // Mode 11 : XGA : 1024 x 768 x 15 bpp
+ XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_555, XGA_OSC_FREQUENCY,
+ XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
+ XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
+ },
+ { // Mode 12 : XGA : 1024 x 768 x 15 bpp - All the timing info is derived from Linux Kernel Driver Settings
+ XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_16_555, 63500000,
+ XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
+ XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
+ },
+ { // Mode 13 : VGA : 640 x 480 x 12 bpp (444 Mode)
+ VGA, VGA_H_RES_PIXELS, VGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_12_444, VGA_OSC_FREQUENCY,
+ VGA_H_SYNC, VGA_H_BACK_PORCH, VGA_H_FRONT_PORCH,
+ VGA_V_SYNC, VGA_V_BACK_PORCH, VGA_V_FRONT_PORCH
+ },
+ { // Mode 14 : SVGA : 800 x 600 x 12 bpp (444 Mode)
+ SVGA, SVGA_H_RES_PIXELS, SVGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_12_444, SVGA_OSC_FREQUENCY,
+ SVGA_H_SYNC, SVGA_H_BACK_PORCH, SVGA_H_FRONT_PORCH,
+ SVGA_V_SYNC, SVGA_V_BACK_PORCH, SVGA_V_FRONT_PORCH
+ },
+ { // Mode 15 : XGA : 1024 x 768 x 12 bpp (444 Mode)
+ XGA, XGA_H_RES_PIXELS, XGA_V_RES_PIXELS, LCD_BITS_PER_PIXEL_12_444, XGA_OSC_FREQUENCY,
+ XGA_H_SYNC, XGA_H_BACK_PORCH, XGA_H_FRONT_PORCH,
+ XGA_V_SYNC, XGA_V_BACK_PORCH, XGA_V_FRONT_PORCH
+ }
+};
+
+EFI_EDID_DISCOVERED_PROTOCOL mEdidDiscovered = {
+ 0,
+ NULL
};
+EFI_EDID_ACTIVE_PROTOCOL mEdidActive = {
+ 0,
+ NULL
+};
+
+
EFI_STATUS
LcdPlatformInitializeDisplay (
- VOID
- ) {
+ IN EFI_HANDLE Handle
+ )
+{
+ EFI_STATUS Status;
+
// Set the FPGA multiplexer to select the video output from the motherboard or the daughterboard
- return ArmPlatformSysConfigSet (SYS_CFG_MUXFPGA, PL111_CLCD_SITE);
+ Status = ArmPlatformSysConfigSet (SYS_CFG_MUXFPGA, PL111_CLCD_SITE);
+ if (!EFI_ERROR(Status)) {
+ // Install the EDID Protocols
+ Status = gBS->InstallMultipleProtocolInterfaces(
+ &Handle,
+ &gEfiEdidDiscoveredProtocolGuid, &mEdidDiscovered,
+ &gEfiEdidActiveProtocolGuid, &mEdidActive,
+ NULL
+ );
+ }
+
+ return Status;
}
EFI_STATUS
diff --git a/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf b/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf
index eca42752b..0f2d4321d 100644
--- a/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf
+++ b/edk2/ArmPlatformPkg/ArmVExpressPkg/Library/PL111LcdArmVExpressLib/PL111LcdArmVExpressLib.inf
@@ -33,6 +33,10 @@
BaseLib
ArmPlatformSysConfigLib
+[Protocols]
+ gEfiEdidDiscoveredProtocolGuid # Produced
+ gEfiEdidActiveProtocolGuid # Produced
+
[Pcd]
gArmVExpressTokenSpaceGuid.PcdPL111LcdMaxMode
gArmVExpressTokenSpaceGuid.PcdPL111LcdVideoModeOscId
diff --git a/edk2/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c b/edk2/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c
index a0cf9afe2..229d2a6aa 100644
--- a/edk2/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c
+++ b/edk2/ArmPlatformPkg/Drivers/LcdGraphicsOutputDxe/LcdGraphicsOutputDxe.c
@@ -125,7 +125,7 @@ InitializeDisplay (
goto EXIT_ERROR_LCD_SHUTDOWN;
}
- Status = LcdPlatformInitializeDisplay ();
+ Status = LcdPlatformInitializeDisplay (Instance->Handle);
if (EFI_ERROR(Status)) {
goto EXIT_ERROR_LCD_SHUTDOWN;
}
diff --git a/edk2/ArmPlatformPkg/Include/Library/LcdPlatformLib.h b/edk2/ArmPlatformPkg/Include/Library/LcdPlatformLib.h
index 93afa6322..7a424c0ad 100644
--- a/edk2/ArmPlatformPkg/Include/Library/LcdPlatformLib.h
+++ b/edk2/ArmPlatformPkg/Include/Library/LcdPlatformLib.h
@@ -158,7 +158,7 @@ typedef enum {
EFI_STATUS
LcdPlatformInitializeDisplay (
- VOID
+ IN EFI_HANDLE Handle
);
EFI_STATUS
diff --git a/edk2/ArmPlatformPkg/Sec/Sec.c b/edk2/ArmPlatformPkg/Sec/Sec.c
index b32f4ffb5..a32cd3857 100644
--- a/edk2/ArmPlatformPkg/Sec/Sec.c
+++ b/edk2/ArmPlatformPkg/Sec/Sec.c
@@ -112,7 +112,7 @@ CEntryPoint (
}
// Enter Monitor Mode
- enter_monitor_mode ((VOID*)(PcdGet32(PcdCPUCoresSecMonStackBase) + (PcdGet32(PcdCPUCoreSecMonStackSize) * GET_CORE_POS(MpId))));
+ enter_monitor_mode ((VOID*)(PcdGet32(PcdCPUCoresSecMonStackBase) + (PcdGet32(PcdCPUCoreSecMonStackSize) * (GET_CORE_POS(MpId) + 1))));
//Write the monitor mode vector table address
ArmWriteVMBar((UINT32) &monitor_vector_table);
diff --git a/edk2/BaseTools/Bin/Win32/BPDG.exe b/edk2/BaseTools/Bin/Win32/BPDG.exe
index d67e1b67d..8cb7362fa 100644
--- a/edk2/BaseTools/Bin/Win32/BPDG.exe
+++ b/edk2/BaseTools/Bin/Win32/BPDG.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/BootSectImage.exe b/edk2/BaseTools/Bin/Win32/BootSectImage.exe
index 7af47afbf..368c26955 100755
--- a/edk2/BaseTools/Bin/Win32/BootSectImage.exe
+++ b/edk2/BaseTools/Bin/Win32/BootSectImage.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/EfiLdrImage.exe b/edk2/BaseTools/Bin/Win32/EfiLdrImage.exe
index 69de8394f..604f850f0 100755
--- a/edk2/BaseTools/Bin/Win32/EfiLdrImage.exe
+++ b/edk2/BaseTools/Bin/Win32/EfiLdrImage.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/EfiRom.exe b/edk2/BaseTools/Bin/Win32/EfiRom.exe
index 4b3de9281..5de62fd78 100755
--- a/edk2/BaseTools/Bin/Win32/EfiRom.exe
+++ b/edk2/BaseTools/Bin/Win32/EfiRom.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/Fpd2Dsc.exe b/edk2/BaseTools/Bin/Win32/Fpd2Dsc.exe
index 2c48bc05f..d774971d6 100755
--- a/edk2/BaseTools/Bin/Win32/Fpd2Dsc.exe
+++ b/edk2/BaseTools/Bin/Win32/Fpd2Dsc.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenBootSector.exe b/edk2/BaseTools/Bin/Win32/GenBootSector.exe
index 51603b91e..cb57ba77e 100755
--- a/edk2/BaseTools/Bin/Win32/GenBootSector.exe
+++ b/edk2/BaseTools/Bin/Win32/GenBootSector.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenCrc32.exe b/edk2/BaseTools/Bin/Win32/GenCrc32.exe
index 8f84be236..d545e7e8b 100755
--- a/edk2/BaseTools/Bin/Win32/GenCrc32.exe
+++ b/edk2/BaseTools/Bin/Win32/GenCrc32.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenDepex.exe b/edk2/BaseTools/Bin/Win32/GenDepex.exe
index d2013b73e..b17f12ed7 100755
--- a/edk2/BaseTools/Bin/Win32/GenDepex.exe
+++ b/edk2/BaseTools/Bin/Win32/GenDepex.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenFds.exe b/edk2/BaseTools/Bin/Win32/GenFds.exe
index 92bebfa6b..bd270d63f 100755
--- a/edk2/BaseTools/Bin/Win32/GenFds.exe
+++ b/edk2/BaseTools/Bin/Win32/GenFds.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenFfs.exe b/edk2/BaseTools/Bin/Win32/GenFfs.exe
index 37a069e26..bf3ab699b 100755
--- a/edk2/BaseTools/Bin/Win32/GenFfs.exe
+++ b/edk2/BaseTools/Bin/Win32/GenFfs.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenFv.exe b/edk2/BaseTools/Bin/Win32/GenFv.exe
index 03b80f3bf..96f973129 100755
--- a/edk2/BaseTools/Bin/Win32/GenFv.exe
+++ b/edk2/BaseTools/Bin/Win32/GenFv.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenFw.exe b/edk2/BaseTools/Bin/Win32/GenFw.exe
index 6df993458..33c08bcd4 100755
--- a/edk2/BaseTools/Bin/Win32/GenFw.exe
+++ b/edk2/BaseTools/Bin/Win32/GenFw.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenPage.exe b/edk2/BaseTools/Bin/Win32/GenPage.exe
index 3f70426fc..e7f673252 100755
--- a/edk2/BaseTools/Bin/Win32/GenPage.exe
+++ b/edk2/BaseTools/Bin/Win32/GenPage.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenPatchPcdTable.exe b/edk2/BaseTools/Bin/Win32/GenPatchPcdTable.exe
index cd9ec7556..aa9bf405a 100755
--- a/edk2/BaseTools/Bin/Win32/GenPatchPcdTable.exe
+++ b/edk2/BaseTools/Bin/Win32/GenPatchPcdTable.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenSec.exe b/edk2/BaseTools/Bin/Win32/GenSec.exe
index f8f11e82c..1274d352b 100755
--- a/edk2/BaseTools/Bin/Win32/GenSec.exe
+++ b/edk2/BaseTools/Bin/Win32/GenSec.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/GenVtf.exe b/edk2/BaseTools/Bin/Win32/GenVtf.exe
index 6e60e8c36..4f1868ff8 100755
--- a/edk2/BaseTools/Bin/Win32/GenVtf.exe
+++ b/edk2/BaseTools/Bin/Win32/GenVtf.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/LzmaCompress.exe b/edk2/BaseTools/Bin/Win32/LzmaCompress.exe
index 8d97bcb2d..244237a2e 100755
--- a/edk2/BaseTools/Bin/Win32/LzmaCompress.exe
+++ b/edk2/BaseTools/Bin/Win32/LzmaCompress.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/MigrationMsa2Inf.exe b/edk2/BaseTools/Bin/Win32/MigrationMsa2Inf.exe
index 6a96e513f..219b181d1 100755
--- a/edk2/BaseTools/Bin/Win32/MigrationMsa2Inf.exe
+++ b/edk2/BaseTools/Bin/Win32/MigrationMsa2Inf.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/PatchPcdValue.exe b/edk2/BaseTools/Bin/Win32/PatchPcdValue.exe
index ac5121474..c635d3ac1 100755
--- a/edk2/BaseTools/Bin/Win32/PatchPcdValue.exe
+++ b/edk2/BaseTools/Bin/Win32/PatchPcdValue.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/Spd2Dec.exe b/edk2/BaseTools/Bin/Win32/Spd2Dec.exe
index e003096aa..072f64822 100755
--- a/edk2/BaseTools/Bin/Win32/Spd2Dec.exe
+++ b/edk2/BaseTools/Bin/Win32/Spd2Dec.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/Split.exe b/edk2/BaseTools/Bin/Win32/Split.exe
index 5285c71db..c5fead378 100755
--- a/edk2/BaseTools/Bin/Win32/Split.exe
+++ b/edk2/BaseTools/Bin/Win32/Split.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/TargetTool.exe b/edk2/BaseTools/Bin/Win32/TargetTool.exe
index 5eecbeb9a..19ff3a832 100755
--- a/edk2/BaseTools/Bin/Win32/TargetTool.exe
+++ b/edk2/BaseTools/Bin/Win32/TargetTool.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/TianoCompress.exe b/edk2/BaseTools/Bin/Win32/TianoCompress.exe
index 58d2972ec..e47070c24 100755
--- a/edk2/BaseTools/Bin/Win32/TianoCompress.exe
+++ b/edk2/BaseTools/Bin/Win32/TianoCompress.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/Trim.exe b/edk2/BaseTools/Bin/Win32/Trim.exe
index 563ca64a8..25f919877 100755
--- a/edk2/BaseTools/Bin/Win32/Trim.exe
+++ b/edk2/BaseTools/Bin/Win32/Trim.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/UPT.exe b/edk2/BaseTools/Bin/Win32/UPT.exe
index 3dad60db6..8f08ca3ef 100644
--- a/edk2/BaseTools/Bin/Win32/UPT.exe
+++ b/edk2/BaseTools/Bin/Win32/UPT.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/VfrCompile.exe b/edk2/BaseTools/Bin/Win32/VfrCompile.exe
index 4a14a12c0..ccb69a263 100755
--- a/edk2/BaseTools/Bin/Win32/VfrCompile.exe
+++ b/edk2/BaseTools/Bin/Win32/VfrCompile.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/VolInfo.exe b/edk2/BaseTools/Bin/Win32/VolInfo.exe
index ad84ee10d..0befe01e7 100755
--- a/edk2/BaseTools/Bin/Win32/VolInfo.exe
+++ b/edk2/BaseTools/Bin/Win32/VolInfo.exe
Binary files differ
diff --git a/edk2/BaseTools/Bin/Win32/build.exe b/edk2/BaseTools/Bin/Win32/build.exe
index 4158f832a..1bb30e7a3 100755
--- a/edk2/BaseTools/Bin/Win32/build.exe
+++ b/edk2/BaseTools/Bin/Win32/build.exe
Binary files differ
diff --git a/edk2/BaseTools/Source/C/Include/Common/BuildVersion.h b/edk2/BaseTools/Source/C/Include/Common/BuildVersion.h
index 64bce0916..22327e7ec 100644
--- a/edk2/BaseTools/Source/C/Include/Common/BuildVersion.h
+++ b/edk2/BaseTools/Source/C/Include/Common/BuildVersion.h
@@ -1,3 +1,17 @@
-//This file is for build version number auto generation
-//
-#define __BUILD_VERSION "Build 2460"
+/** @file
+ This file is for build version number auto generation
+
+ Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+ File Name: BuildVersion.h
+
+**/
+
+#define __BUILD_VERSION "Build 2474"
diff --git a/edk2/BaseTools/Source/Python/AutoGen/AutoGen.py b/edk2/BaseTools/Source/Python/AutoGen/AutoGen.py
index cb3369ffd..894ec8dcd 100644
--- a/edk2/BaseTools/Source/Python/AutoGen/AutoGen.py
+++ b/edk2/BaseTools/Source/Python/AutoGen/AutoGen.py
@@ -173,7 +173,8 @@ class WorkspaceAutoGen(AutoGen):
# @param SkuId SKU id from command line
#
def _Init(self, WorkspaceDir, ActivePlatform, Target, Toolchain, ArchList, MetaFileDb,
- BuildConfig, ToolDefinition, FlashDefinitionFile='', Fds=None, Fvs=None, Caps=None, SkuId='', UniFlag=None):
+ BuildConfig, ToolDefinition, FlashDefinitionFile='', Fds=None, Fvs=None, Caps=None, SkuId='', UniFlag=None,
+ Progress=None, BuildModule=None):
if Fds is None:
Fds = []
if Fvs is None:
@@ -236,8 +237,25 @@ class WorkspaceAutoGen(AutoGen):
# parse FDF file to get PCDs in it, if any
if not self.FdfFile:
self.FdfFile = self.Platform.FlashDefinition
- EdkLogger.verbose("\nFLASH_DEFINITION = %s" % self.FdfFile)
+
+ EdkLogger.info("")
+ if self.ArchList:
+ EdkLogger.info('%-16s = %s' % ("Architecture(s)", ' '.join(self.ArchList)))
+ EdkLogger.info('%-16s = %s' % ("Build target", self.BuildTarget))
+ EdkLogger.info('%-16s = %s' % ("Toolchain",self.ToolChain))
+
+ EdkLogger.info('\n%-24s = %s' % ("Active Platform", self.Platform))
+ if BuildModule:
+ EdkLogger.info('%-24s = %s' % ("Active Module", BuildModule))
+
+ if self.FdfFile:
+ EdkLogger.info('%-24s = %s' % ("Flash Image Definition", self.FdfFile))
+ EdkLogger.verbose("\nFLASH_DEFINITION = %s" % self.FdfFile)
+
+ if Progress:
+ Progress.Start("\nProcessing meta-data")
+
if self.FdfFile:
#
# Mark now build in AutoGen Phase
diff --git a/edk2/BaseTools/Source/Python/AutoGen/GenC.py b/edk2/BaseTools/Source/Python/AutoGen/GenC.py
index 530dfd7c9..63131cee2 100644
--- a/edk2/BaseTools/Source/Python/AutoGen/GenC.py
+++ b/edk2/BaseTools/Source/Python/AutoGen/GenC.py
@@ -1575,6 +1575,35 @@ def CreatePcdDatabasePhaseSpecificAutoGen (Platform, Phase):
if NumberOfLocalTokens == 0:
AutoGenC.Append(gEmptyPcdDatabaseAutoGenC.Replace(Dict))
else:
+ #
+ # Update Size Table to the right order, it should be same with LocalTokenNumberTable
+ #
+ SizeCNameTempList = []
+ SizeGuidTempList = []
+ SizeCurLenTempList = []
+ SizeMaxLenTempList = []
+ ReOrderFlag = True
+
+ if len(Dict['SIZE_TABLE_CNAME']) == 1:
+ if not (Dict['SIZE_TABLE_CNAME'][0] and Dict['SIZE_TABLE_GUID'][0]):
+ ReOrderFlag = False
+
+ if ReOrderFlag:
+ for Count in range(len(Dict['TOKEN_CNAME'])):
+ for Count1 in range(len(Dict['SIZE_TABLE_CNAME'])):
+ if Dict['TOKEN_CNAME'][Count] == Dict['SIZE_TABLE_CNAME'][Count1] and \
+ Dict['TOKEN_GUID'][Count] == Dict['SIZE_TABLE_GUID'][Count1]:
+ SizeCNameTempList.append(Dict['SIZE_TABLE_CNAME'][Count1])
+ SizeGuidTempList.append(Dict['SIZE_TABLE_GUID'][Count1])
+ SizeCurLenTempList.append(Dict['SIZE_TABLE_CURRENT_LENGTH'][Count1])
+ SizeMaxLenTempList.append(Dict['SIZE_TABLE_MAXIMUM_LENGTH'][Count1])
+
+ for Count in range(len(Dict['SIZE_TABLE_CNAME'])):
+ Dict['SIZE_TABLE_CNAME'][Count] = SizeCNameTempList[Count]
+ Dict['SIZE_TABLE_GUID'][Count] = SizeGuidTempList[Count]
+ Dict['SIZE_TABLE_CURRENT_LENGTH'][Count] = SizeCurLenTempList[Count]
+ Dict['SIZE_TABLE_MAXIMUM_LENGTH'][Count] = SizeMaxLenTempList[Count]
+
AutoGenC.Append(gPcdDatabaseAutoGenC.Replace(Dict))
return AutoGenH, AutoGenC
diff --git a/edk2/BaseTools/Source/Python/Common/BuildVersion.py b/edk2/BaseTools/Source/Python/Common/BuildVersion.py
index fc3239135..b6b02cf8a 100644
--- a/edk2/BaseTools/Source/Python/Common/BuildVersion.py
+++ b/edk2/BaseTools/Source/Python/Common/BuildVersion.py
@@ -1,3 +1,16 @@
-#This file is for build version number auto generation
+## @file
#
-gBUILD_VERSION = "Build 2460"
+# This file is for build version number auto generation
+#
+# Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
+#
+# This program and the accompanying materials are licensed and made available
+# under the terms and conditions of the BSD License which accompanies this
+# distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
+
+gBUILD_VERSION = "Build 2474"
diff --git a/edk2/BaseTools/Source/Python/Ecc/Ecc.py b/edk2/BaseTools/Source/Python/Ecc/Ecc.py
index ab438c7e8..e2e92ef67 100644
--- a/edk2/BaseTools/Source/Python/Ecc/Ecc.py
+++ b/edk2/BaseTools/Source/Python/Ecc/Ecc.py
@@ -22,12 +22,12 @@ from MetaDataParser import *
from optparse import OptionParser
from Configuration import Configuration
from Check import Check
-
+import Common.GlobalData as GlobalData
from Common.String import NormPath
from Common.BuildVersion import gBUILD_VERSION
from Common import BuildToolError
-
+from Common.Misc import PathClass
from MetaFileWorkspace.MetaFileParser import DscParser
from MetaFileWorkspace.MetaFileParser import DecParser
from MetaFileWorkspace.MetaFileParser import InfParser
@@ -61,7 +61,41 @@ class Ecc(object):
# Parse the options and args
self.ParseOption()
-
+
+ #
+ # Check EFI_SOURCE (Edk build convention). EDK_SOURCE will always point to ECP
+ #
+ WorkspaceDir = os.path.normcase(os.path.normpath(os.environ["WORKSPACE"]))
+ os.environ["WORKSPACE"] = WorkspaceDir
+ if "ECP_SOURCE" not in os.environ:
+ os.environ["ECP_SOURCE"] = os.path.join(WorkspaceDir, GlobalData.gEdkCompatibilityPkg)
+ if "EFI_SOURCE" not in os.environ:
+ os.environ["EFI_SOURCE"] = os.environ["ECP_SOURCE"]
+ if "EDK_SOURCE" not in os.environ:
+ os.environ["EDK_SOURCE"] = os.environ["ECP_SOURCE"]
+
+ #
+ # Unify case of characters on case-insensitive systems
+ #
+ EfiSourceDir = os.path.normcase(os.path.normpath(os.environ["EFI_SOURCE"]))
+ EdkSourceDir = os.path.normcase(os.path.normpath(os.environ["EDK_SOURCE"]))
+ EcpSourceDir = os.path.normcase(os.path.normpath(os.environ["ECP_SOURCE"]))
+
+ os.environ["EFI_SOURCE"] = EfiSourceDir
+ os.environ["EDK_SOURCE"] = EdkSourceDir
+ os.environ["ECP_SOURCE"] = EcpSourceDir
+
+ GlobalData.gWorkspace = WorkspaceDir
+ GlobalData.gEfiSource = EfiSourceDir
+ GlobalData.gEdkSource = EdkSourceDir
+ GlobalData.gEcpSource = EcpSourceDir
+
+ GlobalData.gGlobalDefines["WORKSPACE"] = WorkspaceDir
+ GlobalData.gGlobalDefines["EFI_SOURCE"] = EfiSourceDir
+ GlobalData.gGlobalDefines["EDK_SOURCE"] = EdkSourceDir
+ GlobalData.gGlobalDefines["ECP_SOURCE"] = EcpSourceDir
+
+
# Generate checkpoints list
EccGlobalData.gConfig = Configuration(self.ConfigFile)
@@ -152,7 +186,7 @@ class Ecc(object):
EdkLogger.quiet("Parsing %s" % Filename)
Op.write("%s\r" % Filename)
#Dsc(Filename, True, True, EccGlobalData.gWorkspace, EccGlobalData.gDb)
- self.MetaFile = DscParser(Filename, MODEL_FILE_DSC, MetaFileStorage(EccGlobalData.gDb.TblDsc.Cur, Filename, MODEL_FILE_DSC, True))
+ self.MetaFile = DscParser(PathClass(Filename, Root), MODEL_FILE_DSC, MetaFileStorage(EccGlobalData.gDb.TblDsc.Cur, Filename, MODEL_FILE_DSC, True))
# alwasy do post-process, in case of macros change
self.MetaFile.DoPostProcess()
self.MetaFile.Start()
diff --git a/edk2/BaseTools/Source/Python/Ecc/MetaFileWorkspace/MetaFileParser.py b/edk2/BaseTools/Source/Python/Ecc/MetaFileWorkspace/MetaFileParser.py
index fc29bafc5..9ca00f043 100644
--- a/edk2/BaseTools/Source/Python/Ecc/MetaFileWorkspace/MetaFileParser.py
+++ b/edk2/BaseTools/Source/Python/Ecc/MetaFileWorkspace/MetaFileParser.py
@@ -770,13 +770,13 @@ class DscParser(MetaFileParser):
def Start(self):
Content = ''
try:
- Content = open(str(self.MetaFile), 'r').readlines()
+ Content = open(str(self.MetaFile.Path), 'r').readlines()
except:
EdkLogger.error("Parser", FILE_READ_FAILURE, ExtraData=self.MetaFile)
#
# Insert a record for file
#
- Filename = NormPath(self.MetaFile)
+ Filename = NormPath(self.MetaFile.Path)
FileID = self.TblFile.GetFileId(Filename)
if FileID:
self.FileID = FileID
@@ -1162,6 +1162,8 @@ class DscParser(MetaFileParser):
self._IdMapping[Id] = self._LastItem
RecordList = self._Table.GetAll()
+ self._Table.Drop()
+ self._RawTable.Drop()
for Record in RecordList:
EccGlobalData.gDb.TblDsc.Insert(Record[1],Record[2],Record[3],Record[4],Record[5],Record[6],Record[7],Record[8],Record[9],Record[10],Record[11],Record[12],Record[13],Record[14])
GlobalData.gPlatformDefines.update(self._FileLocalMacros)
@@ -1300,7 +1302,7 @@ class DscParser(MetaFileParser):
#
elif "ECP_SOURCE" in GlobalData.gCommandLineDefines.keys():
__IncludeMacros['ECP_SOURCE'] = GlobalData.gCommandLineDefines['ECP_SOURCE']
-
+
__IncludeMacros['EFI_SOURCE'] = GlobalData.gGlobalDefines['EFI_SOURCE']
__IncludeMacros['EDK_SOURCE'] = GlobalData.gGlobalDefines['EDK_SOURCE']
#
diff --git a/edk2/BaseTools/Source/Python/GenFds/FdfParser.py b/edk2/BaseTools/Source/Python/GenFds/FdfParser.py
index bdb7a7777..7a569e88d 100644
--- a/edk2/BaseTools/Source/Python/GenFds/FdfParser.py
+++ b/edk2/BaseTools/Source/Python/GenFds/FdfParser.py
@@ -679,7 +679,7 @@ class FdfParser:
PreIndex = 0
StartPos = CurLine.find('$(', PreIndex)
EndPos = CurLine.find(')', StartPos+2)
- while StartPos != -1 and EndPos != -1:
+ while StartPos != -1 and EndPos != -1 and not (self.__Token == '!ifdef' or self.__Token == '!ifndef'):
MacroName = CurLine[StartPos+2 : EndPos]
MacorValue = self.__GetMacroValue(MacroName)
if MacorValue != None:
diff --git a/edk2/BaseTools/Source/Python/GenFds/Fv.py b/edk2/BaseTools/Source/Python/GenFds/Fv.py
index fd5ad0e9a..6c7a0503c 100644
--- a/edk2/BaseTools/Source/Python/GenFds/Fv.py
+++ b/edk2/BaseTools/Source/Python/GenFds/Fv.py
@@ -316,7 +316,7 @@ class FV (FvClassObject):
Buffer += pack('B', int(ByteList[Index1], 16))
Guid = self.FvNameGuid.split('-')
- Buffer = pack('LHHBBBBBBBBL',
+ Buffer = pack('=LHHBBBBBBBBL',
int(Guid[0], 16),
int(Guid[1], 16),
int(Guid[2], 16),
diff --git a/edk2/BaseTools/Source/Python/UPT/BuildVersion.py b/edk2/BaseTools/Source/Python/UPT/BuildVersion.py
index fc3239135..bd5876dd5 100644
--- a/edk2/BaseTools/Source/Python/UPT/BuildVersion.py
+++ b/edk2/BaseTools/Source/Python/UPT/BuildVersion.py
@@ -1,3 +1,20 @@
-#This file is for build version number auto generation
+## @file
#
-gBUILD_VERSION = "Build 2460"
+# This file is for build version number auto generation
+#
+# Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
+#
+# This program and the accompanying materials are licensed and made available
+# under the terms and conditions of the BSD License which accompanies this
+# distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
+
+'''
+Build version information
+'''
+
+gBUILD_VERSION = "Build 2474"
diff --git a/edk2/BaseTools/Source/Python/UPT/InstallPkg.py b/edk2/BaseTools/Source/Python/UPT/InstallPkg.py
index 1c75dad80..776196e8e 100644
--- a/edk2/BaseTools/Source/Python/UPT/InstallPkg.py
+++ b/edk2/BaseTools/Source/Python/UPT/InstallPkg.py
@@ -403,7 +403,7 @@ def Main(Options = None):
DestFile = os.path.normpath(os.path.join(DestDir, DistFileName))
if os.path.exists(DestFile):
FileName, Ext = os.path.splitext(DistFileName)
- NewFileName = FileName + '_' + DistPkg.Header.GetGuid() + '_' + DistPkg.Header.GetVersion() + '.' + Ext
+ NewFileName = FileName + '_' + DistPkg.Header.GetGuid() + '_' + DistPkg.Header.GetVersion() + Ext
DestFile = os.path.normpath(os.path.join(DestDir, NewFileName))
if os.path.exists(DestFile):
#
diff --git a/edk2/BaseTools/Source/Python/UPT/Library/ParserValidate.py b/edk2/BaseTools/Source/Python/UPT/Library/ParserValidate.py
index 8efb56a61..860fb4f1d 100644
--- a/edk2/BaseTools/Source/Python/UPT/Library/ParserValidate.py
+++ b/edk2/BaseTools/Source/Python/UPT/Library/ParserValidate.py
@@ -286,7 +286,7 @@ def IsValidInstallPath(Path):
if os.path.isabs(Path):
return False
else:
- if Path[1:2] == ':' or Path.find('\\') >=0:
+ if Path[1:2] == ':':
return False
if os.path.isabs(Path):
return False
diff --git a/edk2/BaseTools/Source/Python/UPT/Library/String.py b/edk2/BaseTools/Source/Python/UPT/Library/String.py
index 526b2e66b..2c5853ca9 100644
--- a/edk2/BaseTools/Source/Python/UPT/Library/String.py
+++ b/edk2/BaseTools/Source/Python/UPT/Library/String.py
@@ -643,35 +643,6 @@ def ConvertToSqlString(StringList):
def ConvertToSqlString2(String):
return String.replace("'", "''")
-## RemoveBlockComment
-#
-# Remove comment block
-#
-# @param Lines: Block Comment Lines
-#
-def RemoveBlockComment(Lines):
- IsFindBlockComment = False
- ReservedLine = ''
- NewLines = []
-
- for Line in Lines:
- Line = Line.strip()
- #
- # Remove comment block
- #
- if Line.find(DataType.TAB_COMMENT_EDK1_START) > -1:
- ReservedLine = GetSplitList(Line, DataType.TAB_COMMENT_EDK1_START, 1)[0]
- IsFindBlockComment = True
- if Line.find(DataType.TAB_COMMENT_EDK1_END) > -1:
- Line = ReservedLine + GetSplitList(Line, DataType.TAB_COMMENT_EDK1_END, 1)[1]
- ReservedLine = ''
- IsFindBlockComment = False
- if IsFindBlockComment:
- NewLines.append('')
- continue
- NewLines.append(Line)
- return NewLines
-
## GetStringOfList
#
# Get String of a List
diff --git a/edk2/BaseTools/Source/Python/UPT/Parser/InfParser.py b/edk2/BaseTools/Source/Python/UPT/Parser/InfParser.py
index 79f71448e..fb90c396f 100644
--- a/edk2/BaseTools/Source/Python/UPT/Parser/InfParser.py
+++ b/edk2/BaseTools/Source/Python/UPT/Parser/InfParser.py
@@ -339,7 +339,7 @@ class InfParser(InfSectionParser):
#
# Found the first section, No file header.
#
- if not DefineSectionParsedFlag:
+ if DefineSectionParsedFlag and not HeaderCommentEnd:
Logger.Error("InfParser",
FORMAT_INVALID,
ST.ERR_INF_PARSER_HEADER_MISSGING,
diff --git a/edk2/BaseTools/Source/Python/UPT/PomAdapter/InfPomAlignment.py b/edk2/BaseTools/Source/Python/UPT/PomAdapter/InfPomAlignment.py
index 20daff0d3..a4a310736 100644
--- a/edk2/BaseTools/Source/Python/UPT/PomAdapter/InfPomAlignment.py
+++ b/edk2/BaseTools/Source/Python/UPT/PomAdapter/InfPomAlignment.py
@@ -750,7 +750,6 @@ class InfPomAlignment(ModuleObject):
BinaryObj = self.Parser.InfBinariesSection.GetBinary()
BinaryData = BinaryObj.keys()
- BinaryData.sort()
#
# If the INF file does not contain a [Sources] section, and the INF file does contain a [Binaries] section,
diff --git a/edk2/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py b/edk2/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py
index a8452a9f8..6ff33db32 100644
--- a/edk2/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py
+++ b/edk2/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py
@@ -383,10 +383,21 @@ class DscBuildData(PlatformBuildClassObject):
self._LoadFixAddress = int (self._LoadFixAddress, 0)
except:
EdkLogger.error("build", PARAMETER_INVALID, "FIX_LOAD_TOP_MEMORY_ADDRESS %s is not valid dec or hex string" % (self._LoadFixAddress))
- if self._LoadFixAddress < 0:
- EdkLogger.error("build", PARAMETER_INVALID, "FIX_LOAD_TOP_MEMORY_ADDRESS is set to the invalid negative value %s" % (self._LoadFixAddress))
- if self._LoadFixAddress != 0xFFFFFFFFFFFFFFFF and self._LoadFixAddress % 0x1000 != 0:
- EdkLogger.error("build", PARAMETER_INVALID, "FIX_LOAD_TOP_MEMORY_ADDRESS is set to the invalid unaligned 4K value %s" % (self._LoadFixAddress))
+
+ #
+ # If command line defined, should override the value in DSC file.
+ #
+ if 'FIX_LOAD_TOP_MEMORY_ADDRESS' in GlobalData.gCommandLineDefines.keys():
+ try:
+ self._LoadFixAddress = int(GlobalData.gCommandLineDefines['FIX_LOAD_TOP_MEMORY_ADDRESS'], 0)
+ except:
+ EdkLogger.error("build", PARAMETER_INVALID, "FIX_LOAD_TOP_MEMORY_ADDRESS %s is not valid dec or hex string" % (GlobalData.gCommandLineDefines['FIX_LOAD_TOP_MEMORY_ADDRESS']))
+
+ if self._LoadFixAddress < 0:
+ EdkLogger.error("build", PARAMETER_INVALID, "FIX_LOAD_TOP_MEMORY_ADDRESS is set to the invalid negative value 0x%x" % (self._LoadFixAddress))
+ if self._LoadFixAddress != 0xFFFFFFFFFFFFFFFF and self._LoadFixAddress % 0x1000 != 0:
+ EdkLogger.error("build", PARAMETER_INVALID, "FIX_LOAD_TOP_MEMORY_ADDRESS is set to the invalid unaligned 4K value 0x%x" % (self._LoadFixAddress))
+
return self._LoadFixAddress
## Retrieve RFCLanguage filter
diff --git a/edk2/BaseTools/Source/Python/build/build.py b/edk2/BaseTools/Source/Python/build/build.py
index 4abf611a0..ef52162ea 100644
--- a/edk2/BaseTools/Source/Python/build/build.py
+++ b/edk2/BaseTools/Source/Python/build/build.py
@@ -745,17 +745,8 @@ class Build():
EdkLogger.quiet("%-16s = %s" % ("EDK_TOOLS_PATH", os.environ["EDK_TOOLS_PATH"]))
EdkLogger.info("")
- if self.ArchList:
- EdkLogger.info('%-16s = %s' % ("Architecture(s)", ' '.join(self.ArchList)))
- EdkLogger.info('%-16s = %s' % ("Build target", ' '.join(self.BuildTargetList)))
- EdkLogger.info('%-16s = %s' % ("Toolchain", ' '.join(self.ToolChainList)))
-
- EdkLogger.info('\n%-16s = %s' % ("Active Platform", self.PlatformFile))
- if self.ModuleFile:
- EdkLogger.info('%-16s = %s' % ("Active Module", self.ModuleFile))
os.chdir(self.WorkspaceDir)
- self.Progress.Start("\nProcessing meta-data")
## Load configuration
#
@@ -1241,7 +1232,8 @@ class Build():
self.FvList,
self.CapList,
self.SkuId,
- self.UniFlag
+ self.UniFlag,
+ self.Progress
)
self.Fdf = Wa.FdfFile
self.LoadFixAddress = Wa.Platform.LoadFixAddress
@@ -1316,7 +1308,9 @@ class Build():
self.FvList,
self.CapList,
self.SkuId,
- self.UniFlag
+ self.UniFlag,
+ self.Progress,
+ self.ModuleFile
)
self.Fdf = Wa.FdfFile
self.LoadFixAddress = Wa.Platform.LoadFixAddress
@@ -1401,7 +1395,8 @@ class Build():
self.FvList,
self.CapList,
self.SkuId,
- self.UniFlag
+ self.UniFlag,
+ self.Progress
)
self.Fdf = Wa.FdfFile
self.LoadFixAddress = Wa.Platform.LoadFixAddress
diff --git a/edk2/BeagleBoardPkg/BeagleBoardPkg.fdf b/edk2/BeagleBoardPkg/BeagleBoardPkg.fdf
index fc73f4b38..653e78197 100644
--- a/edk2/BeagleBoardPkg/BeagleBoardPkg.fdf
+++ b/edk2/BeagleBoardPkg/BeagleBoardPkg.fdf
@@ -157,8 +157,6 @@ READ_LOCK_STATUS = TRUE
INF Omap35xxPkg/PciEmulation/PciEmulation.inf
- #NOTE: Open source EHCI stack doesn't work on Beagleboard.
- #NOTE: UsbBus and UsbMassStorage don't work using iPhond SDK tool chain.
INF MdeModulePkg/Bus/Pci/EhciDxe/EhciDxe.inf
INF MdeModulePkg/Bus/Usb/UsbBusDxe/UsbBusDxe.inf
INF MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMassStorageDxe.inf
diff --git a/edk2/BeagleBoardPkg/build.sh b/edk2/BeagleBoardPkg/build.sh
index f2592b9c7..ad8e69fc2 100755
--- a/edk2/BeagleBoardPkg/build.sh
+++ b/edk2/BeagleBoardPkg/build.sh
@@ -37,7 +37,7 @@ function process_debug_scripts {
#
# Setup workspace if it is not set
#
-if [ -z "$WORKSPACE" ]
+if [ -z "${WORKSPACE:-}" ]
then
echo Initializing workspace
cd ..
@@ -51,20 +51,22 @@ else
fi
#
-# Pick a default tool type for a given OS
+# Pick a default tool type for a given OS if no toolchain already defined
#
-case `uname` in
- CYGWIN*)
+if [ -z "${TARGET_TOOLS:-}" ]
+then
+ case `uname` in
+ CYGWIN*)
TARGET_TOOLS=RVCT31CYGWIN
;;
- Linux*)
+ Linux*)
if [[ ! -z `locate arm-linux-gnueabi-gcc` ]]; then
TARGET_TOOLS=ARMLINUXGCC
else
TARGET_TOOLS=ARMGCC
fi
;;
- Darwin*)
+ Darwin*)
Major=$(uname -r | cut -f 1 -d '.')
if [[ $Major == 9 ]]
then
@@ -74,7 +76,8 @@ case `uname` in
TARGET_TOOLS=XCODE32
fi
;;
-esac
+ esac
+fi
TARGET=DEBUG
for arg in "$@"
@@ -102,9 +105,9 @@ fi
# Build the edk2 BeagleBoard code
#
if [[ $TARGET == RELEASE ]]; then
- build -p $WORKSPACE/BeagleBoardPkg/BeagleBoardPkg.dsc -a ARM -t $TARGET_TOOLS -b $TARGET -D DEBUG_TARGET=RELEASE $2 $3 $4 $5 $6 $7 $8
+ build -p $WORKSPACE/BeagleBoardPkg/BeagleBoardPkg.dsc -a ARM -t $TARGET_TOOLS -b $TARGET -D DEBUG_TARGET=RELEASE ${2:-} ${3:-} ${4:-} ${5:-} ${6:-} ${7:-} ${8:-}
else
- build -p $WORKSPACE/BeagleBoardPkg/BeagleBoardPkg.dsc -a ARM -t $TARGET_TOOLS -b $TARGET $1 $2 $3 $4 $5 $6 $7 $8
+ build -p ${WORKSPACE:-}/BeagleBoardPkg/BeagleBoardPkg.dsc -a ARM -t $TARGET_TOOLS -b $TARGET ${1:-} ${2:-} ${3:-} ${4:-} ${5:-} ${6:-} ${7:-} ${8:-}
fi
diff --git a/edk2/BuildNotes2.txt b/edk2/BuildNotes2.txt
index 579893846..87673e57a 100644
--- a/edk2/BuildNotes2.txt
+++ b/edk2/BuildNotes2.txt
@@ -1,11 +1,11 @@
Intel(R) Platform Innovation Framework for EFI
EFI Development Kit II (EDK II)
-2010-03-31
+2011-12-14
Intel is a trademark or registered trademark of Intel Corporation or its
subsidiaries in the United States and other countries.
* Other names and brands may be claimed as the property of others.
-Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.
+Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.
EDK II packages can be checked out from the following SVN address:
http://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2
@@ -45,15 +45,16 @@ dlls are not required for normal development.
c:\MyWork\edk2\> edksetup --nt32
-The default tool chain (named MYTOOLS) is pre-configured to use VS2005 for IA32
-and X64 target architectures and the DDK for IPF target architectures. To use a
+The default tool chain (named MYTOOLS) is pre-configured to use VS2008 for IA32
+and X64 target architectures and DDK3790 for IPF target architectures. To use a
different tool chain, either modify the tools_def.txt file's MYTOOLS entries,
or modify the %WORKSPACE%\Conf\target.txt file's TOOL_CHAIN_TAG. The pre-defined
tags are listed near the top of the %WORKSPACE%\Conf\tools_def.txt file, below
the Supported Tool Chains comment.
Alternatively, you may use the build command's -t option to specify a different
-tool chain tag name: build -t VS2003 ... , for example. Using this method will
-require that you always use the build command's -t option.
+tool chain tag name: build -t VS2008 ... , for example. Using this method will
+require that you always use the build command's -t option. If you use 64-bit
+windows OS, you should use tool chain tag name with x86, such as VS2008x86.
Next, go to the module directory and begin to build. This example is for the
@@ -120,7 +121,7 @@ Tools in Python
* Run buld tool written in Python from source
The build tool written in Python can be executed from its source directly as
- long as you have the Python interpreter (version 2.5) installed. The source
+ long as you have the Python interpreter (version 2.5.4) installed. The source
of Python code is locating at:
http://edk2-buildtools.svn.sourceforge.net/svnroot/edk2-buildtools/trunk/BaseTools
diff --git a/edk2/CryptoPkg/Library/OpensslLib/OpensslLib.inf b/edk2/CryptoPkg/Library/OpensslLib/OpensslLib.inf
index 8d54f5bcd..203445736 100644
--- a/edk2/CryptoPkg/Library/OpensslLib/OpensslLib.inf
+++ b/edk2/CryptoPkg/Library/OpensslLib/OpensslLib.inf
@@ -602,7 +602,7 @@
MSFT:NOOPT_*_IPF_CC_FLAGS == /nologo /c /WX /GS- /X /EHs-c- /GR- /Gy /Od /FIAutoGen.h /QIPF_fr32 /Zi -U_WIN32 -U_WIN64 -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
INTEL:*_*_IA32_CC_FLAGS = -U_WIN32 -U_WIN64 -U_MSC_VER -U__ICC $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
INTEL:*_*_X64_CC_FLAGS = -U_WIN32 -U_WIN64 -U_MSC_VER -U__ICC $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
- INTEL:*_*_IPF_CC_FLAGS = -U_WIN32 -U_WIN64 -U_MSC_VER -U__ICC $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
+ INTEL:*_*_IPF_CC_FLAGS = -U_WIN32 -U_WIN64 -U_MSC_VER -U__ICC $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
GCC:*_*_IA32_CC_FLAGS = -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w -DTHIRTY_TWO_BIT
GCC:*_*_X64_CC_FLAGS = -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT
GCC:*_*_IPF_CC_FLAGS = -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT
diff --git a/edk2/DuetPkg/BootSector/GNUmakefile b/edk2/DuetPkg/BootSector/GNUmakefile
index 66298daf3..dc26e1f9e 100644
--- a/edk2/DuetPkg/BootSector/GNUmakefile
+++ b/edk2/DuetPkg/BootSector/GNUmakefile
@@ -1,7 +1,7 @@
## @file
# Just use host GCC to compile boot sector image.
#
-# Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
@@ -20,11 +20,15 @@ ASSEMBLY_CODE_FILE_LIST = $(MODULE_DIR)/bootsect.S \
$(MODULE_DIR)/bs16.S \
$(MODULE_DIR)/bs32.S \
$(MODULE_DIR)/efi32.S \
+ $(MODULE_DIR)/efi64.S \
$(MODULE_DIR)/Gpt.S \
$(MODULE_DIR)/Mbr.S \
$(MODULE_DIR)/start.S \
$(MODULE_DIR)/start16.S \
- $(MODULE_DIR)/start32.S
+ $(MODULE_DIR)/start32.S \
+ $(MODULE_DIR)/start64.S \
+ $(MODULE_DIR)/st16_64.S \
+ $(MODULE_DIR)/st32_64.S
TARGET_FILES = $(OUTPUT_DIR)/bootsect.com \
$(OUTPUT_DIR)/bs16.com \
@@ -34,11 +38,11 @@ TARGET_FILES = $(OUTPUT_DIR)/bootsect.com \
$(OUTPUT_DIR)/start.com \
$(OUTPUT_DIR)/start16.com \
$(OUTPUT_DIR)/start32.com \
- $(OUTPUT_DIR)/efi32.com2
- #$(OUTPUT_DIR)/start64.com \
- #$(OUTPUT_DIR)/st16_64.com \
- #$(OUTPUT_DIR)/st32_64.com \
- #$(OUTPUT_DIR)/efi64.com2
+ $(OUTPUT_DIR)/efi32.com2 \
+ $(OUTPUT_DIR)/start64.com \
+ $(OUTPUT_DIR)/st16_64.com \
+ $(OUTPUT_DIR)/st32_64.com \
+ $(OUTPUT_DIR)/efi64.com2
.PHONY : all
all: $(TARGET_FILES)
@@ -98,16 +102,16 @@ $(OUTPUT_DIR)/start64.com: $(OUTPUT_DIR)/start64.o
$(DLINK) --oformat binary -o $(OUTPUT_DIR)/start64.com $(OUTPUT_DIR)/start64.o -Ttext 0 -Map $(OUTPUT_DIR)/start64.map
# start16_64.S
-$(OUTPUT_DIR)/start16_64.o: $(MODULE_DIR)/start16_64.S
- $(ASM) -c -o $(OUTPUT_DIR)/start16_64.o $(MODULE_DIR)/start16_64.S
-$(OUTPUT_DIR)/start16_64.com: $(OUTPUT_DIR)/start16_64.o
- $(DLINK) --oformat binary -o $(OUTPUT_DIR)/start16_64.com $(OUTPUT_DIR)/start16_64.o -Ttext 0 -Map $(OUTPUT_DIR)/start16_64.map
+$(OUTPUT_DIR)/st16_64.o: $(MODULE_DIR)/st16_64.S
+ $(ASM) -c -o $(OUTPUT_DIR)/st16_64.o $(MODULE_DIR)/st16_64.S
+$(OUTPUT_DIR)/st16_64.com: $(OUTPUT_DIR)/st16_64.o
+ $(DLINK) --oformat binary -o $(OUTPUT_DIR)/st16_64.com $(OUTPUT_DIR)/st16_64.o -Ttext 0 -Map $(OUTPUT_DIR)/st16_64.map
# start32_64.S
-$(OUTPUT_DIR)/start32_64.o: $(MODULE_DIR)/start32_64.S
- $(ASM) -c -o $(OUTPUT_DIR)/start32_64.o $(MODULE_DIR)/start32_64.S
-$(OUTPUT_DIR)/start32_64.com: $(OUTPUT_DIR)/start32_64.o
- $(DLINK) --oformat binary -o $(OUTPUT_DIR)/start32_64.com $(OUTPUT_DIR)/start32_64.o -Ttext 0 -Map $(OUTPUT_DIR)/start32_64.map
+$(OUTPUT_DIR)/st32_64.o: $(MODULE_DIR)/st32_64.S
+ $(ASM) -c -o $(OUTPUT_DIR)/st32_64.o $(MODULE_DIR)/st32_64.S
+$(OUTPUT_DIR)/st32_64.com: $(OUTPUT_DIR)/st32_64.o
+ $(DLINK) --oformat binary -o $(OUTPUT_DIR)/st32_64.com $(OUTPUT_DIR)/st32_64.o -Ttext 0 -Map $(OUTPUT_DIR)/st32_64.map
# efi32.S
$(OUTPUT_DIR)/efi32.o: $(MODULE_DIR)/efi32.S
diff --git a/edk2/DuetPkg/BootSector/Mbr.S b/edk2/DuetPkg/BootSector/Mbr.S
index a1ebe06ca..65c97ea97 100644
--- a/edk2/DuetPkg/BootSector/Mbr.S
+++ b/edk2/DuetPkg/BootSector/Mbr.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#*
-#* Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
+#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
#* This program and the accompanying materials
#* are licensed and made available under the terms and conditions of the BSD License
#* which accompanies this distribution. The full text of the license may be found at
@@ -54,7 +54,7 @@ _start:
xorw %ax, %ax # AX = 0x0000
movw $0x7c00, %bx # BX = 0x7C00
movw $0x600, %bp # BP = 0x0600
- movw RelocatedStart, %si # SI = Offset(RelocatedStart)
+ movw $RelocatedStart, %si # SI = Offset(RelocatedStart)
movw $0x200, %cx # CX = 0x0200
subw %si, %cx # CS = 0x0200 - Offset(RelocatedStart)
leaw (%bp,%si,), %di # DI = 0x0600 + Offset(RelocatedStart)
diff --git a/edk2/DuetPkg/BootSector/bin/bs32.com b/edk2/DuetPkg/BootSector/bin/bs32.com
index 0255c82e8..9cd368aaa 100644
--- a/edk2/DuetPkg/BootSector/bin/bs32.com
+++ b/edk2/DuetPkg/BootSector/bin/bs32.com
Binary files differ
diff --git a/edk2/DuetPkg/BootSector/bs32.S b/edk2/DuetPkg/BootSector/bs32.S
index d768518e8..95424f3d6 100644
--- a/edk2/DuetPkg/BootSector/bs32.S
+++ b/edk2/DuetPkg/BootSector/bs32.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#*
-#* Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
+#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
#* This program and the accompanying materials
#* are licensed and made available under the terms and conditions of the BSD License
#* which accompanies this distribution. The full text of the license may be found at
@@ -207,7 +207,7 @@ PrintString:
movw %ax, %es
movw $0x7c0, %ax
movw %ax, %ds
- movw $7, %cx
+ movw $6, %cx
movw $160, %di
rep
movsw
@@ -288,15 +288,15 @@ Halt:
jmp Halt
StartString:
- .byte 'B', 0x0c, 'S', 0x0c, 't', 0x0c, 'a', 0x0c, 'r', 0x0c, 't', 0x0c, '!', 0x0c
+ .byte 'B', 0x0c, 'S', 0x0c, 't', 0x0c, 'a', 0x0c, 'r', 0x0c, 't', 0x0c
ErrorString:
- .byte 'B', 0x0c, 'E', 0x0c, 'r', 0x0c, 'r', 0x0c, 'o', 0x0c, 'r', 0x0c, '!', 0x0c
+ .byte 'B', 0x0c, 'E', 0x0c, 'r', 0x0c, 'r', 0x0c, 'o', 0x0c, 'r', 0x0c
# ****************************************************************************
# LBA Offset for BootSector, need patched by tool for HD boot.
# ****************************************************************************
- #.org 0x01fa
+ .org 0x01fa
LBAOffsetForBootSector:
.long 0x0
@@ -304,7 +304,7 @@ LBAOffsetForBootSector:
# Sector Signature
# ****************************************************************************
- #.org 0x01fe
+ .org 0x01fe
SectorSignature:
.word 0xaa55 # Boot Sector Signature
diff --git a/edk2/DuetPkg/BootSector/bs32.asm b/edk2/DuetPkg/BootSector/bs32.asm
index f26668982..d23ba071b 100644
--- a/edk2/DuetPkg/BootSector/bs32.asm
+++ b/edk2/DuetPkg/BootSector/bs32.asm
@@ -1,6 +1,6 @@
;------------------------------------------------------------------------------
;*
-;* Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
+;* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
;* This program and the accompanying materials
;* are licensed and made available under the terms and conditions of the BSD License
;* which accompanies this distribution. The full text of the license may be found at
@@ -78,7 +78,7 @@ BootSectorEntryPoint:
; ****************************************************************************
; Start Print
; ****************************************************************************
- lea si, cs:[StartString]
+ mov si, offset StartString
call PrintString
; ****************************************************************************
@@ -206,7 +206,7 @@ PrintString:
mov es,ax
mov ax, 07c0h
mov ds, ax
- mov cx, 7
+ mov cx, 6
mov di, 160
rep movsw
ret
@@ -280,15 +280,15 @@ NotFoundAll:
jne FoundEFILDR
BadBootSector:
DiskError:
- lea si, cs:[ErrorString]
+ mov si, offset ErrorString
call PrintString
Halt:
jmp Halt
StartString:
- db 'B', 0ch, 'S', 0ch, 't', 0ch, 'a', 0ch, 'r', 0ch, 't', 0ch, '!', 0ch
+ db 'B', 0ch, 'S', 0ch, 't', 0ch, 'a', 0ch, 'r', 0ch, 't', 0ch
ErrorString:
- db 'B', 0ch, 'E', 0ch, 'r', 0ch, 'r', 0ch, 'o', 0ch, 'r', 0ch, '!', 0ch
+ db 'B', 0ch, 'E', 0ch, 'r', 0ch, 'r', 0ch, 'o', 0ch, 'r', 0ch
; ****************************************************************************
; LBA Offset for BootSector, need patched by tool for HD boot.
diff --git a/edk2/DuetPkg/BootSector/efi64.S b/edk2/DuetPkg/BootSector/efi64.S
index fe7a3647a..34bd7521b 100644
--- a/edk2/DuetPkg/BootSector/efi64.S
+++ b/edk2/DuetPkg/BootSector/efi64.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#*
-#* Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
+#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
#* This program and the accompanying materials
#* are licensed and made available under the terms and conditions of the BSD License
#* which accompanies this distribution. The full text of the license may be found at
@@ -24,6 +24,9 @@
.code:
.org 0x21000
+.global _start
+_start:
+
.equ DEFAULT_HANDLER_SIZE, INT1 - INT0
.macro jmpCommonIdtEntry
@@ -56,15 +59,16 @@ Start:
call ClearScreen
# Populate IDT with meaningful offsets for exception handlers...
- sidt Idtr
+ movl $Idtr, %eax
+ sidt (%eax) # get fword address of IDT
- movl Halt, %eax
+ movl $Halt, %eax
movl %eax,%ebx # use bx to copy 15..0 to descriptors
shrl $16,%eax # use ax to copy 31..16 to descriptors
# 63..32 of descriptors is 0
movl $0x78,%ecx # 78h IDT entries to initialize with unique entry points (exceptions)
- movl (Idtr + 2), %esi
+ movl $(Idtr + 2), %esi
movl (%esi),%edi
LOOP_1: # loop through all IDT entries exception handlers and initialize to default handler
@@ -74,7 +78,7 @@ LOOP_1: # loop through all IDT entries e
movw %ax, 6(%edi) # write bits 31..16 of offset
movl $0, 8(%edi) # write bits 31..16 of offset
addl $16, %edi # move up to next descriptor
- addw DEFAULT_HANDLER_SIZE, %bx # move to next entry point
+ addw $DEFAULT_HANDLER_SIZE, %bx # move to next entry point
loopl LOOP_1 # loop back through again until all descriptors are initialized
## at this point edi contains the offset of the descriptor for INT 20
@@ -123,7 +127,7 @@ LOOP_1: # loop through all IDT entries e
movl 0x30(%ebp),%edi # edi = [[22000 + [22014] + 3c] + 2c] = ImageBase (63..32 is zero, ignore)
movl 0x28(%ebp),%eax # eax = [[22000 + [22014] + 3c] + 24] = EntryPoint
addl %edi,%eax # eax = ImageBase + EntryPoint
- movl %ebx, EfiLdrOffset
+ movl $EfiLdrOffset, %ebx
movl %eax, (%ebx) # Modify far jump instruction for correct entry point
movw 6(%ebp), %bx # bx = Number of sections
@@ -155,8 +159,8 @@ SectionLoop:
cmpw $0,%bx
jne SectionLoop
- movl (Idtr), %eax # get size of IDT
- movzx (%edx), %eax
+ movl $Idtr, %edx # get size of IDT
+ movzxw (%edx), %eax
.byte 0xff
.byte 0xc0
# inc eax
@@ -965,7 +969,7 @@ commonIdtEntry:
##
call ClearScreen
- mov String1, %esi
+ movl $String1, %esi
call PrintString
.byte 0x48
movl 16*8(%ebp),%eax ## move Int number into RAX
@@ -974,11 +978,11 @@ commonIdtEntry:
ja PrintDefaultString
PrintExceptionString:
shll $3,%eax ## multiply by 8 to get offset from StringTable to actual string address
- addl StringTable, %eax
+ addl $StringTable, %eax
movl (%eax),%esi
jmp PrintTheString
PrintDefaultString:
- movl IntUnknownString, %esi
+ movl $IntUnknownString, %esi
# patch Int number
movl %eax,%edx
call A2C
@@ -989,7 +993,7 @@ PrintDefaultString:
movb %al,(%esi)
PrintTheString:
call PrintString
- movl String2, %esi
+ movl $String2, %esi
call PrintString
.byte 0x48
movl 19*8(%ebp),%eax # CS
@@ -1000,24 +1004,24 @@ PrintTheString:
.byte 0x48
movl 18*8(%ebp),%eax # RIP
call PrintQword
- movl String3, %esi
+ movl $String3, %esi
call PrintString
movl $0xb8140,%edi
- movl StringRax, %esi
+ movl $StringRax, %esi
call PrintString
.byte 0x48
movl 15*8(%ebp),%eax
call PrintQword
- movl StringRcx, %esi
+ movl $StringRcx, %esi
call PrintString
.byte 0x48
movl 14*8(%ebp),%eax
call PrintQword
- movl StringRdx, %esi
+ movl $StringRdx, %esi
call PrintString
.byte 0x48
movl 13*8(%ebp),%eax
@@ -1025,19 +1029,19 @@ PrintTheString:
movl $0xb81e0,%edi
- movl StringRbx, %esi
+ movl $StringRbx, %esi
call PrintString
.byte 0x48
movl 12*8(%ebp),%eax
call PrintQword
- movl StringRsp, %esi
+ movl $StringRsp, %esi
call PrintString
.byte 0x48
movl 21*8(%ebp),%eax
call PrintQword
- movl StringRbp, %esi
+ movl $StringRbp, %esi
call PrintString
.byte 0x48
movl 10*8(%ebp),%eax
@@ -1045,19 +1049,19 @@ PrintTheString:
movl $0xb8280,%edi
- movl StringRsi, %esi
+ movl $StringRsi, %esi
call PrintString
.byte 0x48
movl 9*8(%ebp),%eax
call PrintQword
- movl StringRdi, %esi
+ movl $StringRdi, %esi
call PrintString
.byte 0x48
movl 8*8(%ebp),%eax
call PrintQword
- movl StringEcode, %esi
+ movl $StringEcode, %esi
call PrintString
.byte 0x48
movl 17*8(%ebp),%eax
@@ -1065,19 +1069,19 @@ PrintTheString:
movl $0xb8320,%edi
- movl StringR8, %esi
+ movl $StringR8, %esi
call PrintString
.byte 0x48
movl 7*8(%ebp),%eax
call PrintQword
- movl StringR9, %esi
+ movl $StringR9, %esi
call PrintString
.byte 0x48
movl 6*8(%ebp),%eax
call PrintQword
- movl StringR10, %esi
+ movl $StringR10, %esi
call PrintString
.byte 0x48
movl 5*8(%ebp),%eax
@@ -1085,19 +1089,19 @@ PrintTheString:
movl $0xb83c0,%edi
- movl StringR11, %esi
+ movl $StringR11, %esi
call PrintString
.byte 0x48
movl 4*8(%ebp),%eax
call PrintQword
- movl StringR12, %esi
+ movl $StringR12, %esi
call PrintString
.byte 0x48
movl 3*8(%ebp),%eax
call PrintQword
- movl StringR13, %esi
+ movl $StringR13, %esi
call PrintString
.byte 0x48
movl 2*8(%ebp),%eax
@@ -1105,19 +1109,19 @@ PrintTheString:
movl $0xb8460,%edi
- movl StringR14, %esi
+ movl $StringR14, %esi
call PrintString
.byte 0x48
movl 1*8(%ebp),%eax
call PrintQword
- movl StringR15, %esi
+ movl $StringR15, %esi
call PrintString
.byte 0x48
movl 0*8(%ebp),%eax
call PrintQword
- movl StringSs, %esi
+ movl $StringSs, %esi
call PrintString
.byte 0x48
movl 22*8(%ebp),%eax
@@ -1125,7 +1129,7 @@ PrintTheString:
movl $0xb8500,%edi
- movl StringRflags, %esi
+ movl $StringRflags, %esi
call PrintString
.byte 0x48
movl 20*8(%ebp),%eax
@@ -1149,7 +1153,7 @@ InnerLoop:
movl (%esi),%eax
call PrintQword
addl $8,%esi
- mov $0x00, %al
+ movb $0x20, %al # blank character
movb %al,(%edi)
addl $2,%edi
loop InnerLoop
@@ -1180,7 +1184,7 @@ InnerLoop1:
movl (%esi),%eax
call PrintQword
addl $8,%esi
- movb $0x00, %al
+ movb $0x20, %al # blank character
movb %al,(%edi)
addl $2,%edi
loop InnerLoop1
@@ -1279,9 +1283,9 @@ looptop:
andb $0xf,%bl
addb $'0', %bl
cmpb $'9', %bl
- jle @f
+ jle LN_C4
addb $7,%bl
-@@:
+LN_C4:
movb %bl, (%edi)
addl $2,%edi
loop looptop
@@ -1296,14 +1300,14 @@ ClearScreen:
pushl %eax
pushl %ecx
- movb $0x00, %al
+ movb $0x20, %al # blank character
movb $0xc,%ah
movl $0xb8000,%edi
movl $80*24,%ecx
-LN_C4:
+LN_C5:
movw %ax, (%edi)
addl $2,%edi
- loop LN_C4
+ loop LN_C5
movl $0xb8000,%edi
popl %ecx
@@ -1315,9 +1319,9 @@ A2C:
andb $0xf,%al
addb $'0', %al
cmpb $'9', %al
- jle @f
+ jle LN_C6
addb $7,%al
-LN_C5:
+LN_C6:
ret
String1: .asciz "*** INT "
@@ -1344,11 +1348,11 @@ Int18String: .asciz "12h Machine check -"
Int19String: .asciz "13h SIMD Floating-Point Exception -"
IntUnknownString: .asciz "??h Unknown interrupt -"
-StringTable: .long Int0String, Int1String, Int2String, Int3String, \
- Int4String, Int5String, Int6String, Int7String, \
- Int8String, Int9String, Int10String, Int11String, \
- Int12String, Int13String, Int14String, Int15String,\
- Int16String, Int17String, Int18String, Int19String
+StringTable: .long Int0String, 0, Int1String, 0, Int2String, 0, Int3String, 0, \
+ Int4String, 0, Int5String, 0, Int6String, 0, Int7String, 0, \
+ Int8String, 0, Int9String, 0, Int10String, 0, Int11String, 0, \
+ Int12String, 0, Int13String, 0, Int14String, 0, Int15String, 0, \
+ Int16String, 0, Int17String, 0, Int18String, 0, Int19String, 0
String2: .asciz " HALT!! *** ("
String3: .asciz ")"
diff --git a/edk2/DuetPkg/BootSector/st16_64.S b/edk2/DuetPkg/BootSector/st16_64.S
index c6cc5169f..8eadd28d3 100644
--- a/edk2/DuetPkg/BootSector/st16_64.S
+++ b/edk2/DuetPkg/BootSector/st16_64.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#*
-#* Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
+#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
#* This program and the accompanying materials
#* are licensed and made available under the terms and conditions of the BSD License
#* which accompanies this distribution. The full text of the license may be found at
@@ -27,6 +27,10 @@
.equ BLOCK_SHIFT, 9
.org 0x0
+
+.global _start
+_start:
+
Ia32Jump:
jmp BootSectorEntryPoint # JMP inst - 3 bytes
nop
@@ -123,11 +127,11 @@ CheckEm64T:
movw $18,%cx
jmp PrintStringAndHalt
CheckEm64TPass:
-jumpFarInstruction:
+JumpFarInstruction:
.byte 0xea
-jumpOffset:
+JumpOffset:
.word 0x200
-jumpSegment:
+JumpSegment:
.word 0x2000
@@ -431,7 +435,7 @@ A20GateEnabled:
#
# Enable Protect Mode (set CR0.PE=1)
#
- movl $cr0, %eax # Read CR0.
+ movl %cr0, %eax # Read CR0.
orl $0x1,%eax # Set PE=1
movl %eax, %cr0 # Write CR0.
.byte 0x66
@@ -503,7 +507,7 @@ In32BitProtectedMode:
#
# Enable paging to activate long mode (set CR0.PG=1)
#
- movl $cr0, %eax # Read CR0.
+ movl %cr0, %eax # Read CR0.
.byte 0xf
.byte 0xba
.byte 0xe8
@@ -1099,9 +1103,8 @@ MemoryMap: .long 0,0,0,0,0,0,0,0
.long 0,0,0,0,0,0,0,0
.long 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
- .long 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
- #.org 0x0fe0 #Just for pass build
+ .org 0x0fe0
MyStack:
# below is the pieces of the IVT that is used to redirect INT 68h - 6fh
# back to INT 08h - 0fh when in real mode... It is 'org'ed to a
@@ -1133,7 +1136,7 @@ MyStack:
iret
- #.org 0x0ffe #Just for pass build
+ .org 0x0ffe
BlockSignature:
.word 0xaa55
diff --git a/edk2/DuetPkg/BootSector/st32_64.S b/edk2/DuetPkg/BootSector/st32_64.S
index f1ebf67d1..18c53f81f 100644
--- a/edk2/DuetPkg/BootSector/st32_64.S
+++ b/edk2/DuetPkg/BootSector/st32_64.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#*
-#* Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
+#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
#* This program and the accompanying materials
#* are licensed and made available under the terms and conditions of the BSD License
#* which accompanies this distribution. The full text of the license may be found at
@@ -27,6 +27,10 @@
.equ BLOCK_SHIFT, 9
.org 0x0
+
+.global _start
+_start:
+
Ia32Jump:
jmp BootSectorEntryPoint # JMP inst - 3 bytes
nop
@@ -138,11 +142,11 @@ CheckEm64T:
movw $18,%cx
jmp PrintStringAndHalt
CheckEm64TPass:
-jumpFarInstruction:
+JumpFarInstruction:
.byte 0xea
-jumpOffset:
+JumpOffset:
.word 0x200
-jumpSegment:
+JumpSegment:
.word 0x2000
@@ -446,7 +450,7 @@ A20GateEnabled:
#
# Enable Protect Mode (set CR0.PE=1)
#
- movl $cr0, %eax # Read CR0.
+ movl %cr0, %eax # Read CR0.
orl $0x1,%eax # Set PE=1
movl %eax, %cr0 # Write CR0.
.byte 0x66
@@ -518,7 +522,7 @@ In32BitProtectedMode:
#
# Enable paging to activate long mode (set CR0.PG=1)
#
- movl $cr0, %eax # Read CR0.
+ movl %cr0, %eax # Read CR0.
.byte 0xf
.byte 0xba
.byte 0xe8
@@ -597,7 +601,7 @@ Empty8042Loop:
.p2align 1
- gdtr: .long GDT_END - GDT_BASE - 1 # GDT limit
+ gdtr: .word GDT_END - GDT_BASE - 1 # GDT limit
.long 0 # (GDT base gets set above)
##############################################################################
# global descriptor table (GDT)
@@ -1114,9 +1118,8 @@ MemoryMap: .long 0,0,0,0,0,0,0,0
.long 0,0,0,0,0,0,0,0
.long 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
- .long 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
- #.org 0x0fe0 #Just for pass build
+ .org 0x0fe0
MyStack:
# below is the pieces of the IVT that is used to redirect INT 68h - 6fh
# back to INT 08h - 0fh when in real mode... It is 'org'ed to a
@@ -1148,7 +1151,7 @@ MyStack:
iret
- #.org 0x0ffe #Just for pass build
+ .org 0x0ffe
BlockSignature:
.word 0xaa55
diff --git a/edk2/DuetPkg/BootSector/start32.S b/edk2/DuetPkg/BootSector/start32.S
index 5296414f2..dc683f585 100644
--- a/edk2/DuetPkg/BootSector/start32.S
+++ b/edk2/DuetPkg/BootSector/start32.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#*
-#* Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
+#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
#* This program and the accompanying materials
#* are licensed and made available under the terms and conditions of the BSD License
#* which accompanies this distribution. The full text of the license may be found at
@@ -311,11 +311,11 @@ Halt:
ErrorString:
.byte 'S', 0x0c, 'E', 0x0c, 'r', 0x0c, 'r', 0x0c, 'o', 0x0c, 'r', 0x0c, '!', 0x0c
- # .org 0x01fa # Will cause build break
+ .org 0x01fa
LBAOffsetForBootSector:
.long 0x0
- # .org 0x01fe # Will cause build break
+ .org 0x01fe
.word 0xaa55
#******************************************************************************
@@ -328,7 +328,7 @@ LBAOffsetForBootSector:
.equ WRITE_DATA_PORT_CMD, 0x0d1 # 8042 command to write the data port
.equ ENABLE_A20_CMD, 0x0df # 8042 command to enable A20
-# .org 0x200 # Will cause build break
+ .org 0x200
jmp start
Em64String:
.byte 'E', 0x0c, 'm', 0x0c, '6', 0x0c, '4', 0x0c, 'T', 0x0c, ' ', 0x0c, 'U', 0x0c, 'n', 0x0c, 's', 0x0c, 'u', 0x0c, 'p', 0x0c, 'p', 0x0c, 'o', 0x0c, 'r', 0x0c, 't', 0x0c, 'e', 0x0c, 'd', 0x0c, '!', 0x0c
diff --git a/edk2/DuetPkg/BootSector/start64.S b/edk2/DuetPkg/BootSector/start64.S
index b8f1e60f8..75626b86a 100644
--- a/edk2/DuetPkg/BootSector/start64.S
+++ b/edk2/DuetPkg/BootSector/start64.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#*
-#* Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
+#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
#* This program and the accompanying materials
#* are licensed and made available under the terms and conditions of the BSD License
#* which accompanies this distribution. The full text of the license may be found at
@@ -27,6 +27,10 @@
.equ BLOCK_SHIFT, 9
.org 0x0
+
+.global _start
+_start:
+
Ia32Jump:
jmp BootSectorEntryPoint # JMP inst - 3 bytes
nop
@@ -123,11 +127,11 @@ CheckEm64T:
movw $18,%cx
jmp PrintStringAndHalt
CheckEm64TPass:
-jumpFarInstruction:
+JumpFarInstruction:
.byte 0xea
-jumpOffset:
+JumpOffset:
.word 0x200
-jumpSegment:
+JumpSegment:
.word 0x2000
@@ -510,7 +514,7 @@ In32BitProtectedMode:
#
# Enable paging to activate long mode (set CR0.PG=1)
#
- movl $cr0, %eax # Read CR0.
+ movl %cr0, %eax # Read CR0.
.byte 0xf
.byte 0xba
.byte 0xe8
@@ -1106,7 +1110,6 @@ MemoryMap: .long 0,0,0,0,0,0,0,0
.long 0,0,0,0,0,0,0,0
.long 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
- .long 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
.org 0x0fe0
MyStack:
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Framework/Guid/DataHubRecords/DataHubSubClassCache.h b/edk2/EdkCompatibilityPkg/Foundation/Framework/Guid/DataHubRecords/DataHubSubClassCache.h
index 87e5f0acd..0ae8ed993 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Framework/Guid/DataHubRecords/DataHubSubClassCache.h
+++ b/edk2/EdkCompatibilityPkg/Foundation/Framework/Guid/DataHubRecords/DataHubSubClassCache.h
@@ -1,6 +1,6 @@
/*++
-Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -43,6 +43,11 @@ typedef struct {
UINT32 NonBurst :1;
UINT32 Burst :1;
UINT32 PipelineBurst :1;
+ //
+ // Inconsistent between CacheSubclass 0.9 and SMBIOS specifications here:
+ // In CacheSubclass specification 0.9, the sequence of Asynchronous and Synchronous fileds
+ // are opposite to SMBIOS specification.
+ //
UINT32 Asynchronous :1;
UINT32 Synchronous :1;
UINT32 Reserved :25;
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Include/EfiDebug.h b/edk2/EdkCompatibilityPkg/Foundation/Include/EfiDebug.h
index a1a1637e9..3e67b93dd 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Include/EfiDebug.h
+++ b/edk2/EdkCompatibilityPkg/Foundation/Include/EfiDebug.h
@@ -1,6 +1,6 @@
/*++
-Copyright (c) 2004, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -146,7 +146,7 @@ Abstract:
#define EFI_D_FS 0x00000008 // EFI File system
#define EFI_D_POOL 0x00000010 // Alloc & Free's
#define EFI_D_PAGE 0x00000020 // Alloc & Free's
-#define EFI_D_INFO 0x00000040 // Verbose
+#define EFI_D_INFO 0x00000040 // Informational debug messages
#define EFI_D_VARIABLE 0x00000100 // Variable
#define EFI_D_BM 0x00000400 // Boot Manager (BDS)
#define EFI_D_BLKIO 0x00001000 // BlkIo Driver
@@ -154,11 +154,11 @@ Abstract:
#define EFI_D_UNDI 0x00010000 // UNDI Driver
#define EFI_D_LOADFILE 0x00020000 // UNDI Driver
#define EFI_D_EVENT 0x00080000 // Event messages
-
+#define EFI_D_VERBOSE 0x00400000 // Detailed debug messages that may significantly impact boot performance
#define EFI_D_ERROR 0x80000000 // Error
#define EFI_D_GENERIC (EFI_D_ERROR | EFI_D_INIT | EFI_D_WARN | EFI_D_INFO | \
- EFI_D_BLKIO | EFI_D_NET | EFI_D_UNDI )
+ EFI_D_BLKIO | EFI_D_NET | EFI_D_UNDI | EFI_D_VERBOSE)
#define EFI_D_INTRINSIC ( EFI_D_EVENT | EFI_D_POOL | EFI_D_PAGE | \
EFI_D_BM | EFI_D_LOAD | EFI_D_VARIABLE )
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Include/Library/EdkIIGlueDebugLib.h b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Include/Library/EdkIIGlueDebugLib.h
index 27e597403..3c42a05f1 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Include/Library/EdkIIGlueDebugLib.h
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Include/Library/EdkIIGlueDebugLib.h
@@ -1,6 +1,6 @@
/*++
-Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -47,6 +47,7 @@ Abstract:
#undef EFI_D_UNDI
#undef EFI_D_LOADFILE
#undef EFI_D_EVENT
+#undef EFI_D_VERBOSE
#undef EFI_D_ERROR
//
@@ -68,7 +69,7 @@ Abstract:
#define DEBUG_FS 0x00000008 // EFI File system
#define DEBUG_POOL 0x00000010 // Alloc & Free's
#define DEBUG_PAGE 0x00000020 // Alloc & Free's
-#define DEBUG_INFO 0x00000040 // Verbose
+#define DEBUG_INFO 0x00000040 // Informational debug messages
#define DEBUG_VARIABLE 0x00000100 // Variable
#define DEBUG_BM 0x00000400 // Boot Manager
#define DEBUG_BLKIO 0x00001000 // BlkIo Driver
@@ -76,6 +77,7 @@ Abstract:
#define DEBUG_UNDI 0x00010000 // UNDI Driver
#define DEBUG_LOADFILE 0x00020000 // UNDI Driver
#define DEBUG_EVENT 0x00080000 // Event messages
+#define DEBUG_VERBOSE 0x00400000 // Detailed debug messages that may significantly impact boot performance
#define DEBUG_ERROR 0x80000000 // Error
//
@@ -95,6 +97,7 @@ Abstract:
#define EFI_D_UNDI DEBUG_UNDI
#define EFI_D_LOADFILE DEBUG_LOADFILE
#define EFI_D_EVENT DEBUG_EVENT
+#define EFI_D_VERBOSE DEBUG_VERBOSE
#define EFI_D_ERROR DEBUG_ERROR
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.S b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.S
index 6055ca663..0f144e714 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.S
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -55,7 +55,8 @@ ASM_PFX(ThunkAttr): .space 4
orb $2, %al
outb %al, $0x92 # deactivate A20M#
2:
- movw %ss, %ax
+ xorw %ax, %ax # xor eax, eax
+ movl %ss, %eax # mov ax, ss
.byte 0x67, 0x66, 0x8d, 0x6c, 0x24, 0x34, 0x66
mov %ebp, 0xffffffd8(%esi)
mov 0xfffffff8(%esi), %ebx
@@ -134,8 +135,8 @@ _16DsDesc:
GdtEnd:
#
-# @param RegSet Pointer to a IA32_DWORD_REGS structure
-# @param Transition Pointer to the transition code
+# @param RegSet The pointer to a IA32_DWORD_REGS structure
+# @param Transition The pointer to the transition code
# @return The address of the 16-bit stack after returning from user code
#
ASM_PFX(InternalAsmThunk16):
@@ -160,14 +161,14 @@ ASM_PFX(InternalAsmThunk16):
movsl # copy RegSet
movl 40(%esp), %eax # eax <- address of transition code
movl %edx, %esi # esi <- 16-bit stack segment
- lea 0x5e(%eax), %edx
+ lea 0x61(%eax), %edx
movl %eax, %ecx
andl $0xf, %ecx
shll $12, %eax
lea 0x6(%ecx), %ecx
movw %cx, %ax
stosl # [edi] <- return address of user code
- sgdtl 0xffffffa2(%edx)
+ sgdtl 0xffffff9f(%edx)
sidtl 0x24(%esp)
movl %cr0, %eax
movl %eax, (%edx) # save CR0 in SavedCr0
@@ -183,20 +184,20 @@ ASM_PFX(InternalAsmThunk16):
popfl
lidtl 0x24(%esp)
lea 0xffffffcc(%ebp), %eax
- pop %gs
- pop %fs
- pop %es
- pop %ds
- pop %edi
- pop %esi
- pop %ebx
- pop %ebp
+ pop %gs
+ pop %fs
+ pop %es
+ pop %ds
+ pop %edi
+ pop %esi
+ pop %ebx
+ pop %ebp
ret
.const:
-ASM_PFX(m16Size): .word _InternalAsmThunk16 - ASM_PFX(m16Start)
-ASM_PFX(mThunk16Attr): .word _ThunkAttr - ASM_PFX(m16Start)
+ASM_PFX(m16Size): .word ASM_PFX(InternalAsmThunk16) - ASM_PFX(m16Start)
+ASM_PFX(mThunk16Attr): .word ASM_PFX(ThunkAttr) - ASM_PFX(m16Start)
ASM_PFX(m16Gdt): .word _NullSegDesc - ASM_PFX(m16Start)
ASM_PFX(m16GdtrBase): .word _16GdtrBase - ASM_PFX(m16Start)
ASM_PFX(mTransition): .word _EntryPoint - ASM_PFX(m16Start)
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.asm b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.asm
index 61508d73b..8b22e0f33 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.asm
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/Ia32/Thunk16.asm
@@ -1,4 +1,4 @@
-; Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
+; Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
; This program and the accompanying materials
; are licensed and made available under the terms and conditions of the BSD License
; which accompanies this distribution. The full text of the license may be found at
@@ -108,7 +108,8 @@ _ThunkAttr DD ?
or al, 2
out 92h, al ; deactivate A20M#
@2:
- mov ax, ss
+ xor ax, ax ; xor eax, eax
+ mov eax, ss ; mov ax, ss
DB 67h
lea bp, [esp + sizeof (IA32_REGS)]
;
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.S b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.S
index 1de788a18..038cc75a6 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.S
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -109,7 +109,8 @@ L_1:
orb $2,%al
outb %al, $0x92 # deactivate A20M#
L_2:
- movw %ss,%ax
+ xorw %ax,%ax # xor eax, eax
+ movl %ss,%eax # mov ax, ss
lea IA32_REGS_SIZE(%esp), %bp
#
# rsi in the following 2 instructions is indeed bp in 16-bit code
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.asm b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.asm
index c7d9caefe..b181a4ccf 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.asm
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/Thunk16.asm
@@ -1,4 +1,4 @@
-; Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
+; Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
; This program and the accompanying materials
; are licensed and made available under the terms and conditions of the BSD License
; which accompanies this distribution. The full text of the license may be found at
@@ -103,7 +103,8 @@ _ThunkAttr DD ?
or al, 2
out 92h, al ; deactivate A20M#
@2:
- mov ax, ss
+ xor ax, ax ; xor eax, eax
+ mov eax, ss ; mov ax, ss
lea bp, [esp + sizeof (IA32_REGS)]
;
; rsi in the following 2 instructions is indeed bp in 16-bit code
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.S b/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.S
index 55415d870..cf7776a6a 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.S
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.S
@@ -1,6 +1,6 @@
#*****************************************************************************
#*
-#* Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+#* Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
#* This program and the accompanying materials
#* are licensed and made available under the terms and conditions of the BSD License
#* which accompanies this distribution. The full text of the license may be found at
@@ -116,7 +116,8 @@ L_16Bit:
.byte 0xfc
L_Lable1:
- movl %ss,%eax
+ xor %eax,%eax
+ movw %ss,%ax
shl $0x4,%eax
add %esp,%eax
lss 0x3c(%esp),%esp
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.asm b/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.asm
index 76c131746..0a796ed23 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.asm
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/Ia32/Thunk16.asm
@@ -1,6 +1,6 @@
;*****************************************************************************
;*
-;* Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+;* Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
;* This program and the accompanying materials
;* are licensed and made available under the terms and conditions of the BSD License
;* which accompanies this distribution. The full text of the license may be found at
@@ -141,7 +141,8 @@ __Thunk16 PROC USES ebp ebx esi edi ds es fs gs
mov cr4, eax ; disable PAE & PSE
db 67h, 0FFh, 06Ch, 024h, 0FCh ; jmp dword ptr [esp-4]
@@:
- mov eax, ss
+ xor eax, eax
+ mov ax, ss
shl eax, 4
add eax, esp ; eax <- address of 16-bit stack
lss esp, fword ptr (_STK16 ptr [esp + sizeof (IA32_REGS)]).SavedEsp
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.S b/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.S
index 7328ab764..f77388d81 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.S
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.S
@@ -148,7 +148,7 @@ Label_16Bit:
Label:
xor %rax,%rax
- movl %ss,%eax
+ movw %ss,%ax
shl $0x4,%eax
add %esp,%eax
mov %r15,%rsp
diff --git a/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.asm b/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.asm
index 0638d5faa..6b74bbe7c 100644
--- a/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.asm
+++ b/edk2/EdkCompatibilityPkg/Foundation/Library/Thunk16/X64/Thunk16.asm
@@ -144,7 +144,7 @@ _Thunk16 PROC USES rbp rbx rsi rdi r12 r13 r14 r15
retf
@@:
xor rax, rax
- mov eax, ss
+ mov ax, ss
shl eax, 4
add eax, esp ; rax <- address of 16-bit stack
mov rsp, r15
diff --git a/edk2/EmbeddedPkg/Library/PrePiLib/FwVol.c b/edk2/EmbeddedPkg/Library/PrePiLib/FwVol.c
index 92be836e3..75d28a725 100644
--- a/edk2/EmbeddedPkg/Library/PrePiLib/FwVol.c
+++ b/edk2/EmbeddedPkg/Library/PrePiLib/FwVol.c
@@ -792,6 +792,7 @@ FfsProcessFvFile (
//
// Collect FvImage Info.
//
+ ZeroMem (&FvImageInfo, sizeof (FvImageInfo));
Status = FfsGetVolumeInfo (FvImageHandle, &FvImageInfo);
ASSERT_EFI_ERROR (Status);
diff --git a/edk2/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf b/edk2/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
index 177e6f381..14bf26f53 100644
--- a/edk2/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
+++ b/edk2/EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
@@ -18,7 +18,7 @@
INF_VERSION = 0x00010005
BASE_NAME = RealTimeClock
FILE_GUID = B336F62D-4135-4A55-AE4E-4971BBF0885D
- MODULE_TYPE = DXE_DRIVER
+ MODULE_TYPE = DXE_RUNTIME_DRIVER
VERSION_STRING = 1.0
ENTRY_POINT = InitializeRealTimeClock
diff --git a/edk2/EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf b/edk2/EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
index f7c5ead9a..95cdee4c1 100644
--- a/edk2/EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
+++ b/edk2/EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
@@ -18,7 +18,7 @@
INF_VERSION = 0x00010005
BASE_NAME = Reset
FILE_GUID = 16036A73-E8EF-46D0-953C-9B8E96527D13
- MODULE_TYPE = DXE_DRIVER
+ MODULE_TYPE = DXE_RUNTIME_DRIVER
VERSION_STRING = 1.0
ENTRY_POINT = InitializeReset
diff --git a/edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.c b/edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.c
index 07d642080..7be4146b4 100644
--- a/edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.c
+++ b/edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.c
@@ -2,7 +2,7 @@
Emu driver to produce CPU Architectural Protocol.
Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
-Portions copyright (c) 2011, Apple Inc. All rights reserved.
+Portions copyright (c) 2011 - 2012, Apple Inc. All rights reserved.
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -47,6 +47,179 @@ CPU_ARCH_PROTOCOL_PRIVATE mCpuTemplate = {
#define EFI_CPU_DATA_MAXIMUM_LENGTH 0x100
+SMBIOS_TABLE_TYPE4 mCpuSmbiosType4 = {
+ { EFI_SMBIOS_TYPE_PROCESSOR_INFORMATION, sizeof (SMBIOS_TABLE_TYPE4), 0},
+ 1, // Socket String
+ ProcessorOther, // ProcessorType; ///< The enumeration value from PROCESSOR_TYPE_DATA.
+ ProcessorFamilyOther, // ProcessorFamily; ///< The enumeration value from PROCESSOR_FAMILY_DATA.
+ 2, // ProcessorManufacture String;
+ { // ProcessorId;
+ { // PROCESSOR_SIGNATURE
+ 0, // ProcessorSteppingId:4;
+ 0, // ProcessorModel: 4;
+ 0, // ProcessorFamily: 4;
+ 0, // ProcessorType: 2;
+ 0, // ProcessorReserved1: 2;
+ 0, // ProcessorXModel: 4;
+ 0, // ProcessorXFamily: 8;
+ 0, // ProcessorReserved2: 4;
+ },
+ { // PROCESSOR_FEATURE_FLAGS
+ 0, // ProcessorFpu :1;
+ 0, // ProcessorVme :1;
+ 0, // ProcessorDe :1;
+ 0, // ProcessorPse :1;
+ 0, // ProcessorTsc :1;
+ 0, // ProcessorMsr :1;
+ 0, // ProcessorPae :1;
+ 0, // ProcessorMce :1;
+ 0, // ProcessorCx8 :1;
+ 0, // ProcessorApic :1;
+ 0, // ProcessorReserved1 :1;
+ 0, // ProcessorSep :1;
+ 0, // ProcessorMtrr :1;
+ 0, // ProcessorPge :1;
+ 0, // ProcessorMca :1;
+ 0, // ProcessorCmov :1;
+ 0, // ProcessorPat :1;
+ 0, // ProcessorPse36 :1;
+ 0, // ProcessorPsn :1;
+ 0, // ProcessorClfsh :1;
+ 0, // ProcessorReserved2 :1;
+ 0, // ProcessorDs :1;
+ 0, // ProcessorAcpi :1;
+ 0, // ProcessorMmx :1;
+ 0, // ProcessorFxsr :1;
+ 0, // ProcessorSse :1;
+ 0, // ProcessorSse2 :1;
+ 0, // ProcessorSs :1;
+ 0, // ProcessorReserved3 :1;
+ 0, // ProcessorTm :1;
+ 0, // ProcessorReserved4 :2;
+ }
+ },
+ 3, // ProcessorVersion String;
+ { // Voltage;
+ 1, // ProcessorVoltageCapability5V :1;
+ 1, // ProcessorVoltageCapability3_3V :1;
+ 1, // ProcessorVoltageCapability2_9V :1;
+ 0, // ProcessorVoltageCapabilityReserved :1; ///< Bit 3, must be zero.
+ 0, // ProcessorVoltageReserved :3; ///< Bits 4-6, must be zero.
+ 0 // ProcessorVoltageIndicateLegacy :1;
+ },
+ 0, // ExternalClock;
+ 0, // MaxSpeed;
+ 0, // CurrentSpeed;
+ 0x41, // Status;
+ ProcessorUpgradeOther, // ProcessorUpgrade; ///< The enumeration value from PROCESSOR_UPGRADE.
+ 0, // L1CacheHandle;
+ 0, // L2CacheHandle;
+ 0, // L3CacheHandle;
+ 4, // SerialNumber;
+ 5, // AssetTag;
+ 6, // PartNumber;
+ 0, // CoreCount;
+ 0, // EnabledCoreCount;
+ 0, // ThreadCount;
+ 0, // ProcessorCharacteristics;
+ 0, // ProcessorFamily2;
+};
+
+CHAR8 *mCpuSmbiosType4Strings[] = {
+ "Socket",
+ "edk2.svn.sourceforge.net",
+ "Emulated Processor",
+ "1.0",
+ "1.0",
+ "1.0",
+ NULL
+};
+
+
+/**
+ Logs SMBIOS record.
+
+ Note: This should be a genric library function.
+
+ @param Template Fixed SMBIOS structure
+ @param StringPack Array of strings to convert to an SMBIOS string pack.
+
+**/
+EFI_STATUS
+LogSmbiosData (
+ IN EFI_SMBIOS_TABLE_HEADER *Template,
+ IN CHAR8 **StringPack
+ )
+{
+ EFI_STATUS Status;
+ EFI_SMBIOS_PROTOCOL *Smbios;
+ EFI_SMBIOS_HANDLE SmbiosHandle;
+ EFI_SMBIOS_TABLE_HEADER *Record;
+ UINTN Index;
+ UINTN StringSize;
+ UINTN Size;
+ CHAR8 *Str;
+
+ //
+ // Locate Smbios protocol.
+ //
+ Status = gBS->LocateProtocol (&gEfiSmbiosProtocolGuid, NULL, (VOID **)&Smbios);
+ if (EFI_ERROR (Status)) {
+ return Status;
+ }
+
+ // Calculate the size of the fixed record and optional string pack
+ Size = Template->Length;
+ for (Index = 0; StringPack[Index] != NULL; Index++) {
+ StringSize = AsciiStrSize (StringPack[Index]);
+ Size += StringSize;
+ }
+ // Don't forget the terminating double null
+ Size += 1;
+
+ // Copy over Template
+ Record = (EFI_SMBIOS_TABLE_HEADER *)AllocateZeroPool (Size);
+ if (Record == NULL) {
+ return EFI_OUT_OF_RESOURCES;
+ }
+ CopyMem (Record, Template, Template->Length);
+
+ // Append string pack
+ Str = ((CHAR8 *)Record) + Record->Length;
+ for (Index = 0; StringPack[Index] != NULL; Index++) {
+ StringSize = AsciiStrSize (StringPack[Index]);
+ CopyMem (Str, StringPack[Index], StringSize);
+ Str += StringSize;
+ }
+ *Str = 0;
+
+ SmbiosHandle = SMBIOS_HANDLE_PI_RESERVED;
+ Status = Smbios->Add (
+ Smbios,
+ gImageHandle,
+ &SmbiosHandle,
+ Record
+ );
+ ASSERT_EFI_ERROR (Status);
+
+ FreePool (Record);
+ return Status;
+}
+
+
+
+
+VOID
+CpuUpdateSmbios (
+ IN UINTN MaxCpus
+ )
+{
+ mCpuSmbiosType4.CoreCount = MaxCpus;
+ mCpuSmbiosType4.EnabledCoreCount = MaxCpus;
+ mCpuSmbiosType4.ThreadCount = MaxCpus;
+
+ LogSmbiosData ((EFI_SMBIOS_TABLE_HEADER *)&mCpuSmbiosType4, mCpuSmbiosType4Strings);
+}
//
@@ -127,6 +300,9 @@ EmuInit (
IN EFI_CPU_INIT_TYPE InitType
)
{
+ CPU_ARCH_PROTOCOL_PRIVATE *Private;
+
+ Private = CPU_ARCH_PROTOCOL_PRIVATE_DATA_FROM_THIS (This);
return EFI_UNSUPPORTED;
}
@@ -138,6 +314,8 @@ EmuRegisterInterruptHandler (
IN EFI_CPU_INTERRUPT_HANDLER InterruptHandler
)
{
+ CPU_ARCH_PROTOCOL_PRIVATE *Private;
+
//
// Do parameter checking for EFI spec conformance
//
@@ -147,6 +325,7 @@ EmuRegisterInterruptHandler (
//
// Do nothing for Emu emulation
//
+ Private = CPU_ARCH_PROTOCOL_PRIVATE_DATA_FROM_THIS (This);
return EFI_UNSUPPORTED;
}
@@ -186,6 +365,8 @@ EmuSetMemoryAttributes (
IN UINT64 Attributes
)
{
+ CPU_ARCH_PROTOCOL_PRIVATE *Private;
+
//
// Check for invalid parameter for Spec conformance
//
@@ -196,107 +377,12 @@ EmuSetMemoryAttributes (
//
// Do nothing for Nt32 emulation
//
+ Private = CPU_ARCH_PROTOCOL_PRIVATE_DATA_FROM_THIS (This);
return EFI_UNSUPPORTED;
}
-/**
- Logs SMBIOS record.
-
- @param Smbios Pointer to SMBIOS protocol instance.
- @param Buffer Pointer to the data buffer.
-
-**/
-VOID
-LogSmbiosData (
- IN EFI_SMBIOS_PROTOCOL *Smbios,
- IN UINT8 *Buffer
- )
-{
- EFI_STATUS Status;
- EFI_SMBIOS_HANDLE SmbiosHandle;
-
- SmbiosHandle = SMBIOS_HANDLE_PI_RESERVED;
- Status = Smbios->Add (
- Smbios,
- NULL,
- &SmbiosHandle,
- (EFI_SMBIOS_TABLE_HEADER*)Buffer
- );
- ASSERT_EFI_ERROR (Status);
-}
-
-VOID
-CpuUpdateSmbios (
- VOID
- )
-{
- EFI_STATUS Status;
- UINT32 TotalSize;
- EFI_SMBIOS_PROTOCOL *Smbios;
- EFI_HII_HANDLE HiiHandle;
- STRING_REF Token;
- UINTN CpuVerStrLen;
- EFI_STRING CpuVerStr;
- SMBIOS_TABLE_TYPE4 *SmbiosRecord;
- CHAR8 *OptionalStrStart;
-
- //
- // Locate Smbios protocol.
- //
- Status = gBS->LocateProtocol (&gEfiSmbiosProtocolGuid, NULL, (VOID **)&Smbios);
-
- if (EFI_ERROR (Status)) {
- return;
- }
-
- //
- // Initialize strings to HII database
- //
- HiiHandle = HiiAddPackages (
- &gEfiCallerIdGuid,
- NULL,
- CpuStrings,
- NULL
- );
- ASSERT (HiiHandle != NULL);
-
- Token = STRING_TOKEN (STR_PROCESSOR_VERSION);
- CpuVerStr = HiiGetPackageString(&gEfiCallerIdGuid, Token, NULL);
- CpuVerStrLen = StrLen(CpuVerStr);
- ASSERT (CpuVerStrLen <= SMBIOS_STRING_MAX_LENGTH);
-
- TotalSize = sizeof(SMBIOS_TABLE_TYPE4) + CpuVerStrLen + 1 + 1;
- SmbiosRecord = AllocatePool(TotalSize);
- ZeroMem(SmbiosRecord, TotalSize);
-
- SmbiosRecord->Hdr.Type = EFI_SMBIOS_TYPE_PROCESSOR_INFORMATION;
- SmbiosRecord->Hdr.Length = sizeof (SMBIOS_TABLE_TYPE4);
- //
- // Make handle chosen by smbios protocol.add automatically.
- //
- SmbiosRecord->Hdr.Handle = 0;
- //
- // Processor version is the 1st string.
- //
- SmbiosRecord->ProcessorVersion = 1;
- //
- // Store CPU frequency data record to data hub - It's an emulator so make up a value
- //
- SmbiosRecord->CurrentSpeed = 1234;
-
- OptionalStrStart = (CHAR8 *)(SmbiosRecord + 1);
- UnicodeStrToAsciiStr(CpuVerStr, OptionalStrStart);
-
- //
- // Now we have got the full smbios record, call smbios protocol to add this record.
- //
- LogSmbiosData(Smbios, (UINT8 *) SmbiosRecord);
- FreePool (SmbiosRecord);
-}
-
-
/**
Callback function for idle events.
@@ -327,6 +413,7 @@ InitializeCpu (
EFI_STATUS Status;
UINT64 Frequency;
EFI_EVENT IdleLoopEvent;
+ UINTN MaxCpu;
//
// Retrieve the frequency of the performance counter in Hz.
@@ -338,9 +425,10 @@ InitializeCpu (
//
mTimerPeriod = DivU64x64Remainder (1000000000000000ULL, Frequency, NULL);
- CpuUpdateSmbios ();
+ CpuMpServicesInit (&MaxCpu);
+
+ CpuUpdateSmbios (MaxCpu);
- CpuMpServicesInit ();
Status = gBS->CreateEventEx (
EVT_NOTIFY_SIGNAL,
diff --git a/edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.inf b/edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.inf
index e87c50a6f..b8e8ebd8e 100644
--- a/edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.inf
+++ b/edk2/EmulatorPkg/CpuRuntimeDxe/Cpu.inf
@@ -34,14 +34,12 @@
CpuIo.c
Cpu.c
CpuDriver.h
- Strings.uni
MpService.c
[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
- IntelFrameworkPkg/IntelFrameworkPkg.dec
EmulatorPkg/EmulatorPkg.dec
@@ -60,7 +58,6 @@
[Protocols]
gEmuIoThunkProtocolGuid # PROTOCOL_NOTIFY SOMETIMES_CONSUMED
gEfiSmbiosProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
- gEfiHiiProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
gEfiCpuIo2ProtocolGuid # PROTOCOL ALWAYS_PRODUCED
gEfiCpuArchProtocolGuid # PROTOCOL ALWAYS_PRODUCED
gEmuThreadThunkProtocolGuid
diff --git a/edk2/EmulatorPkg/CpuRuntimeDxe/CpuDriver.h b/edk2/EmulatorPkg/CpuRuntimeDxe/CpuDriver.h
index 3ede8473d..5ec515dcb 100644
--- a/edk2/EmulatorPkg/CpuRuntimeDxe/CpuDriver.h
+++ b/edk2/EmulatorPkg/CpuRuntimeDxe/CpuDriver.h
@@ -17,22 +17,19 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#define _CPU_ARCHITECTURAL_PROTOCOL_DRIVER_H_
-#include <FrameworkDxe.h>
+#include <PiDxe.h>
#include <IndustryStandard/SmBios.h>
#include <Protocol/Cpu.h>
#include <Protocol/Smbios.h>
-#include <Protocol/FrameworkHii.h>
#include <Protocol/MpService.h>
#include <Protocol/EmuThread.h>
#include <Protocol/CpuIo2.h>
-#include <Guid/DataHubRecords.h>
#include <Guid/IdleLoopEvent.h>
#include <Library/BaseLib.h>
#include <Library/DebugLib.h>
-#include <Library/HiiLib.h>
#include <Library/UefiDriverEntryPoint.h>
#include <Library/BaseMemoryLib.h>
#include <Library/MemoryAllocationLib.h>
@@ -42,7 +39,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <Library/PcdLib.h>
-extern UINT8 CpuStrings[];
//
// Internal Data Structures
@@ -230,7 +226,7 @@ EmuSetMemoryAttributes (
EFI_STATUS
CpuMpServicesInit (
- VOID
+ OUT UINTN *MaxCores
);
EFI_STATUS
diff --git a/edk2/EmulatorPkg/CpuRuntimeDxe/CpuIo.c b/edk2/EmulatorPkg/CpuRuntimeDxe/CpuIo.c
index a8c10ba55..3d4309d42 100644
--- a/edk2/EmulatorPkg/CpuRuntimeDxe/CpuIo.c
+++ b/edk2/EmulatorPkg/CpuRuntimeDxe/CpuIo.c
@@ -18,12 +18,9 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
-#include <FrameworkDxe.h>
+#include <PiDxe.h>
#include <Protocol/Cpu.h>
-#include <Protocol/DataHub.h>
-#include <Guid/DataHubRecords.h>
#include <Protocol/CpuIo2.h>
-#include <Protocol/FrameworkHii.h>
#include <Library/BaseLib.h>
#include <Library/DebugLib.h>
diff --git a/edk2/EmulatorPkg/CpuRuntimeDxe/MpService.c b/edk2/EmulatorPkg/CpuRuntimeDxe/MpService.c
index ba0ad8250..6eecbbc9b 100644
--- a/edk2/EmulatorPkg/CpuRuntimeDxe/MpService.c
+++ b/edk2/EmulatorPkg/CpuRuntimeDxe/MpService.c
@@ -1308,35 +1308,33 @@ CpuReadToBootFunction (
EFI_STATUS
CpuMpServicesInit (
- VOID
+ OUT UINTN *MaxCpus
)
{
EFI_STATUS Status;
EFI_HANDLE Handle;
EMU_IO_THUNK_PROTOCOL *IoThunk;
- UINTN MaxCpus;
-
- MaxCpus = 1; // BSP
+ *MaxCpus = 1; // BSP
IoThunk = GetIoThunkInstance (&gEmuThreadThunkProtocolGuid, 0);
if (IoThunk != NULL) {
Status = IoThunk->Open (IoThunk);
if (!EFI_ERROR (Status)) {
if (IoThunk->ConfigString != NULL) {
- MaxCpus += StrDecimalToUintn (IoThunk->ConfigString);
+ *MaxCpus += StrDecimalToUintn (IoThunk->ConfigString);
gThread = IoThunk->Interface;
}
}
}
- if (MaxCpus == 1) {
+ if (*MaxCpus == 1) {
// We are not MP so nothing to do
return EFI_SUCCESS;
}
gPollInterval = PcdGet64 (PcdEmuMpServicesPollingInterval);
- Status = InitializeMpSystemData (MaxCpus);
+ Status = InitializeMpSystemData (*MaxCpus);
if (EFI_ERROR (Status)) {
return Status;
}
diff --git a/edk2/EmulatorPkg/CpuRuntimeDxe/Strings.uni b/edk2/EmulatorPkg/CpuRuntimeDxe/Strings.uni
deleted file mode 100644
index f5aa4ddb4..000000000
--- a/edk2/EmulatorPkg/CpuRuntimeDxe/Strings.uni
+++ /dev/null
Binary files differ
diff --git a/edk2/EmulatorPkg/EmuSnpDxe/EmuSnpDxe.c b/edk2/EmulatorPkg/EmuSnpDxe/EmuSnpDxe.c
index 7f8a643e8..09d16fd8b 100644
--- a/edk2/EmulatorPkg/EmuSnpDxe/EmuSnpDxe.c
+++ b/edk2/EmulatorPkg/EmuSnpDxe/EmuSnpDxe.c
@@ -42,7 +42,35 @@ EFI_SIMPLE_NETWORK_PROTOCOL gEmuSnpTemplate = {
NULL // Mode
};
-
+EFI_SIMPLE_NETWORK_MODE gEmuSnpModeTemplate = {
+ EfiSimpleNetworkStopped, // State
+ NET_ETHER_ADDR_LEN, // HwAddressSize
+ NET_ETHER_HEADER_SIZE, // MediaHeaderSize
+ 1500, // MaxPacketSize
+ 0, // NvRamSize
+ 0, // NvRamAccessSize
+ 0, // ReceiveFilterMask
+ 0, // ReceiveFilterSetting
+ MAX_MCAST_FILTER_CNT, // MaxMCastFilterCount
+ 0, // MCastFilterCount
+ {
+ { { 0 } }
+ }, // MCastFilter
+ {
+ { 0 }
+ }, // CurrentAddress
+ {
+ { 0 }
+ }, // BroadcastAddress
+ {
+ { 0 }
+ }, // PermanentAddress
+ NET_IFTYPE_ETHERNET, // IfType
+ FALSE, // MacAddressChangeable
+ FALSE, // MultipleTxSupported
+ FALSE, // MediaPresentSupported
+ TRUE // MediaPresent
+};
/**
@@ -586,14 +614,6 @@ EmuSnpDriverBindingSupported (
}
//
- // Make sure GUID is for a File System handle.
- //
- Status = EFI_UNSUPPORTED;
- if (CompareGuid (EmuIoThunk->Protocol, &gEmuSnpProtocolGuid)) {
- Status = EFI_SUCCESS;
- }
-
- //
// Close the I/O Abstraction(s) used to perform the supported test
//
gBS->CloseProtocol (
@@ -624,6 +644,14 @@ EmuSnpDriverBindingSupported (
}
//
+ // Make sure GUID is for a SNP handle.
+ //
+ Status = EFI_UNSUPPORTED;
+ if (CompareGuid (EmuIoThunk->Protocol, &gEmuSnpProtocolGuid)) {
+ Status = EFI_SUCCESS;
+ }
+
+ //
// Close protocol, don't use device path protocol in the Support() function
//
gBS->CloseProtocol (
@@ -715,6 +743,7 @@ EmuSnpDriverBindingStart (
}
CopyMem (&Private->Snp, &gEmuSnpTemplate, sizeof (EFI_SIMPLE_NETWORK_PROTOCOL));
+ CopyMem (&Private->Mode, &gEmuSnpModeTemplate, sizeof (EFI_SIMPLE_NETWORK_MODE));
Private->Signature = EMU_SNP_PRIVATE_DATA_SIGNATURE;
Private->IoThunk = EmuIoThunk;
@@ -944,7 +973,6 @@ InitializeEmuSnpDriver (
//
// Install the Driver Protocols
//
-
Status = EfiLibInstallDriverBindingComponentName2(
ImageHandle,
SystemTable,
diff --git a/edk2/EmulatorPkg/EmulatorPkg.dec b/edk2/EmulatorPkg/EmulatorPkg.dec
index f005c792c..b3d461de3 100644
--- a/edk2/EmulatorPkg/EmulatorPkg.dec
+++ b/edk2/EmulatorPkg/EmulatorPkg.dec
@@ -48,6 +48,10 @@
gEmuVirtualDisksGuid = { 0xf2ba331a, 0x8985, 0x11db, { 0xa4, 0x06, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35 } }
gEmuPhysicalDisksGuid = { 0xf2bdcc96, 0x8985, 0x11db, { 0x87, 0x19, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35 } }
+[PcdsFeatureFlag]
+ ## If TRUE, if symbols only load on breakpoints and gdb entry
+ gEmulatorPkgTokenSpaceGuid.PcdEmulatorLazyLoadSymbols|TRUE|BOOLEAN|0x00020000
+
[PcdsFixedAtBuild]
gEmulatorPkgTokenSpaceGuid.PcdEmuFlashNvStorageVariableBase|0x0|UINT64|0x00001014
gEmulatorPkgTokenSpaceGuid.PcdEmuFlashNvStorageFtwSpareBase|0x0|UINT64|0x00001015
diff --git a/edk2/EmulatorPkg/Unix/Host/BlockIo.c b/edk2/EmulatorPkg/Unix/Host/BlockIo.c
index 50fe9b575..fa05fbc10 100644
--- a/edk2/EmulatorPkg/Unix/Host/BlockIo.c
+++ b/edk2/EmulatorPkg/Unix/Host/BlockIo.c
@@ -661,6 +661,8 @@ EmuBlockIoThunkOpen (
}
}
+ Private->Mode = Private->WriteProtected ? O_RDONLY : O_RDWR;
+
This->Interface = &Private->EmuBlockIo;
This->Private = Private;
return EFI_SUCCESS;
diff --git a/edk2/EmulatorPkg/Unix/Host/Host.c b/edk2/EmulatorPkg/Unix/Host/Host.c
index 17130168f..7eecbceaa 100644
--- a/edk2/EmulatorPkg/Unix/Host/Host.c
+++ b/edk2/EmulatorPkg/Unix/Host/Host.c
@@ -287,6 +287,12 @@ main (
printf ("\n");
}
+
+ if (SecFile == NULL) {
+ printf ("ERROR : SEC not found!\n");
+ exit (1);
+ }
+
//
// Calculate memory regions and store the information in the gSystemMemory
// global for later use. The autosizing code will use this data to
@@ -1113,6 +1119,18 @@ DlLoadImage (
}
+VOID
+SecGdbScriptBreak (
+ char *FileName,
+ int FileNameLength,
+ long unsigned int LoadAddress,
+ int AddSymbolFlag
+ )
+{
+ return;
+}
+
+
/**
Adds the image to a gdb script so it's symbols can be loaded.
The AddFirmwareSymbolFile helper macro is used.
@@ -1130,20 +1148,41 @@ GdbScriptAddImage (
if (ImageContext->PdbPointer != NULL && !IsPdbFile (ImageContext->PdbPointer)) {
FILE *GdbTempFile;
- GdbTempFile = fopen (gGdbWorkingFileName, "a");
- if (GdbTempFile != NULL) {
- long unsigned int SymbolsAddr = (long unsigned int)(ImageContext->ImageAddress + ImageContext->SizeOfHeaders);
- mScriptSymbolChangesCount++;
- fprintf (
- GdbTempFile,
- "AddFirmwareSymbolFile 0x%x %s 0x%08lx\n",
- mScriptSymbolChangesCount,
- ImageContext->PdbPointer,
- SymbolsAddr
- );
- fclose (GdbTempFile);
+ if (FeaturePcdGet (PcdEmulatorLazyLoadSymbols)) {
+ GdbTempFile = fopen (gGdbWorkingFileName, "a");
+ if (GdbTempFile != NULL) {
+ long unsigned int SymbolsAddr = (long unsigned int)(ImageContext->ImageAddress + ImageContext->SizeOfHeaders);
+ mScriptSymbolChangesCount++;
+ fprintf (
+ GdbTempFile,
+ "AddFirmwareSymbolFile 0x%x %s 0x%08lx\n",
+ mScriptSymbolChangesCount,
+ ImageContext->PdbPointer,
+ SymbolsAddr
+ );
+ fclose (GdbTempFile);
+ } else {
+ ASSERT (FALSE);
+ }
} else {
- ASSERT (FALSE);
+ GdbTempFile = fopen (gGdbWorkingFileName, "w");
+ if (GdbTempFile != NULL) {
+ fprintf (
+ GdbTempFile,
+ "add-symbol-file %s 0x%08lx\n",
+ ImageContext->PdbPointer,
+ (long unsigned int)(ImageContext->ImageAddress + ImageContext->SizeOfHeaders)
+ );
+ fclose (GdbTempFile);
+
+ //
+ // Target for gdb breakpoint in a script that uses gGdbWorkingFileName to set a breakpoint.
+ // Hey what can you say scripting in gdb is not that great....
+ //
+ SecGdbScriptBreak (ImageContext->PdbPointer, strlen (ImageContext->PdbPointer), (long unsigned int)(ImageContext->ImageAddress + ImageContext->SizeOfHeaders), 1);
+ } else {
+ ASSERT (FALSE);
+ }
}
}
}
@@ -1182,21 +1221,37 @@ GdbScriptRemoveImage (
return;
}
- //
- // Write the file we need for the gdb script
- //
- GdbTempFile = fopen (gGdbWorkingFileName, "a");
- if (GdbTempFile != NULL) {
- mScriptSymbolChangesCount++;
- fprintf (
- GdbTempFile,
- "RemoveFirmwareSymbolFile 0x%x %s\n",
- mScriptSymbolChangesCount,
- ImageContext->PdbPointer
- );
- fclose (GdbTempFile);
+ if (FeaturePcdGet (PcdEmulatorLazyLoadSymbols)) {
+ //
+ // Write the file we need for the gdb script
+ //
+ GdbTempFile = fopen (gGdbWorkingFileName, "a");
+ if (GdbTempFile != NULL) {
+ mScriptSymbolChangesCount++;
+ fprintf (
+ GdbTempFile,
+ "RemoveFirmwareSymbolFile 0x%x %s\n",
+ mScriptSymbolChangesCount,
+ ImageContext->PdbPointer
+ );
+ fclose (GdbTempFile);
+ } else {
+ ASSERT (FALSE);
+ }
} else {
- ASSERT (FALSE);
+ GdbTempFile = fopen (gGdbWorkingFileName, "w");
+ if (GdbTempFile != NULL) {
+ fprintf (GdbTempFile, "remove-symbol-file %s\n", ImageContext->PdbPointer);
+ fclose (GdbTempFile);
+
+ //
+ // Target for gdb breakpoint in a script that uses gGdbWorkingFileName to set a breakpoint.
+ // Hey what can you say scripting in gdb is not that great....
+ //
+ SecGdbScriptBreak (ImageContext->PdbPointer, strlen (ImageContext->PdbPointer), 0, 0);
+ } else {
+ ASSERT (FALSE);
+ }
}
}
diff --git a/edk2/EmulatorPkg/Unix/Host/Host.inf b/edk2/EmulatorPkg/Unix/Host/Host.inf
index 018ed8673..496bd770b 100644
--- a/edk2/EmulatorPkg/Unix/Host/Host.inf
+++ b/edk2/EmulatorPkg/Unix/Host/Host.inf
@@ -111,6 +111,9 @@
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
gEmulatorPkgTokenSpaceGuid.PcdPeiServicesTablePage
+[FeaturePcd]
+ gEmulatorPkgTokenSpaceGuid.PcdEmulatorLazyLoadSymbols
+
[BuildOptions]
GCC:*_*_IA32_DLINK_FLAGS == -o $(BIN_DIR)/Host -m elf_i386 -dynamic-linker $(HOST_DLINK_PATHS) -L/usr/X11R6/lib -lXext -lX11
diff --git a/edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec b/edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
index e81379d48..0c4688528 100644
--- a/edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
+++ b/edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
@@ -18,7 +18,7 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = IntelFrameworkModulePkg
PACKAGE_GUID = 88894582-7553-4822-B484-624E24B6DECF
- PACKAGE_VERSION = 0.91
+ PACKAGE_VERSION = 0.92
[Includes]
Include # Root include for the package
diff --git a/edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dsc b/edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dsc
index 83e43d2cc..70a8a39ef 100644
--- a/edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dsc
+++ b/edk2/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dsc
@@ -22,7 +22,7 @@
[Defines]
PLATFORM_NAME = IntelFrameworkModuleAll
PLATFORM_GUID = FFF87D9A-E5BB-4AFF-9ADE-8645492E8087
- PLATFORM_VERSION = 0.91
+ PLATFORM_VERSION = 0.92
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/IntelFrameworkModuleAll
SUPPORTED_ARCHITECTURES = IA32|IPF|X64|EBC|ARM
diff --git a/edk2/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsMisc.c b/edk2/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsMisc.c
index 68ddfc334..904e968db 100644
--- a/edk2/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsMisc.c
+++ b/edk2/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsMisc.c
@@ -1,7 +1,7 @@
/** @file
Misc BDS library function
-Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -390,6 +390,95 @@ BdsLibRegisterNewOption (
return Status;
}
+/**
+ Returns the size of a device path in bytes.
+
+ This function returns the size, in bytes, of the device path data structure
+ specified by DevicePath including the end of device path node. If DevicePath
+ is NULL, then 0 is returned. If the length of the device path is bigger than
+ MaxSize, also return 0 to indicate this is an invalidate device path.
+
+ @param DevicePath A pointer to a device path data structure.
+ @param MaxSize Max valid device path size. If big than this size,
+ return error.
+
+ @retval 0 An invalid device path.
+ @retval Others The size of a device path in bytes.
+
+**/
+UINTN
+GetDevicePathSizeEx (
+ IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath,
+ IN UINTN MaxSize
+ )
+{
+ UINTN Size;
+ UINTN NodeSize;
+
+ if (DevicePath == NULL) {
+ return 0;
+ }
+
+ //
+ // Search for the end of the device path structure
+ //
+ Size = 0;
+ while (!IsDevicePathEnd (DevicePath)) {
+ NodeSize = DevicePathNodeLength (DevicePath);
+ if (NodeSize == 0) {
+ return 0;
+ }
+ Size += NodeSize;
+ if (Size > MaxSize) {
+ return 0;
+ }
+ DevicePath = NextDevicePathNode (DevicePath);
+ }
+ Size += DevicePathNodeLength (DevicePath);
+ if (Size > MaxSize) {
+ return 0;
+ }
+
+ return Size;
+}
+
+/**
+ Returns the length of a Null-terminated Unicode string. If the length is
+ bigger than MaxStringLen, return length 0 to indicate that this is an
+ invalidate string.
+
+ This function returns the number of Unicode characters in the Null-terminated
+ Unicode string specified by String.
+
+ If String is NULL, then ASSERT().
+ If String is not aligned on a 16-bit boundary, then ASSERT().
+
+ @param String A pointer to a Null-terminated Unicode string.
+ @param MaxStringLen Max string len in this string.
+
+ @retval 0 An invalid string.
+ @retval Others The length of String.
+
+**/
+UINTN
+StrSizeEx (
+ IN CONST CHAR16 *String,
+ IN UINTN MaxStringLen
+ )
+{
+ UINTN Length;
+
+ ASSERT (String != NULL && MaxStringLen != 0);
+ ASSERT (((UINTN) String & BIT0) == 0);
+
+ for (Length = 0; *String != L'\0' && MaxStringLen != Length; String++, Length++);
+
+ if (*String != L'\0' && MaxStringLen == Length) {
+ return 0;
+ }
+
+ return (Length + 1) * sizeof (*String);
+}
/**
Build the boot#### or driver#### option from the VariableName, the
@@ -417,11 +506,13 @@ BdsLibVariableToOption (
UINT8 *TempPtr;
UINTN VariableSize;
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
+ EFI_DEVICE_PATH_PROTOCOL *TempPath;
BDS_COMMON_OPTION *Option;
VOID *LoadOptions;
UINT32 LoadOptionsSize;
CHAR16 *Description;
UINT8 NumOff;
+ UINTN TempSize;
//
// Read the variable. We will never free this data.
//
@@ -458,7 +549,11 @@ BdsLibVariableToOption (
//
// Get the option's description string size
//
- TempPtr += StrSize ((CHAR16 *) TempPtr);
+ TempSize = StrSizeEx ((CHAR16 *) TempPtr, VariableSize);
+ if (TempSize == 0) {
+ return NULL;
+ }
+ TempPtr += TempSize;
//
// Get the option's device path
@@ -466,7 +561,26 @@ BdsLibVariableToOption (
DevicePath = (EFI_DEVICE_PATH_PROTOCOL *) TempPtr;
TempPtr += FilePathSize;
+ //
+ // Validation device path.
+ //
+ TempPath = DevicePath;
+ while (FilePathSize > 0) {
+ TempSize = GetDevicePathSizeEx (TempPath, FilePathSize);
+ if (TempSize == 0) {
+ return NULL;
+ }
+ FilePathSize = (UINT16) (FilePathSize - TempSize);
+ TempPath += TempSize;
+ }
+
+ //
+ // Get load opion data.
+ //
LoadOptions = TempPtr;
+ if (VariableSize < (UINTN)(TempPtr - Variable)) {
+ return NULL;
+ }
LoadOptionsSize = (UINT32) (VariableSize - (UINTN) (TempPtr - Variable));
//
diff --git a/edk2/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c b/edk2/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c
index f919911ff..a54cffb16 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c
+++ b/edk2/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c
@@ -390,8 +390,6 @@ InstallAcpiTable (
EFI_ACPI_SUPPORT_PROTOCOL *AcpiSupport;
EFI_STATUS Status;
VOID *AcpiTableBufferConst;
- UINT32 Length;
- UINT8 Checksum;
//
// Check for invalid input parameters
@@ -401,16 +399,6 @@ InstallAcpiTable (
return EFI_INVALID_PARAMETER;
}
- Length = ((EFI_ACPI_COMMON_HEADER *) AcpiTableBuffer)->Length;
- Checksum = CalculateCheckSum8 ((UINT8 *)AcpiTableBuffer, Length);
- if (Checksum != 0) {
- AcpiPlatformChecksum (
- (VOID *)AcpiTableBuffer,
- (UINTN)Length,
- OFFSET_OF (EFI_ACPI_DESCRIPTION_HEADER, Checksum)
- );
- }
-
//
// Get the instance of the ACPI support protocol
//
@@ -425,7 +413,7 @@ InstallAcpiTable (
Status = AcpiSupport->SetAcpiTable (
AcpiSupport,
AcpiTableBufferConst,
- FALSE,
+ TRUE,
EFI_ACPI_TABLE_VERSION_1_0B | EFI_ACPI_TABLE_VERSION_2_0 | EFI_ACPI_TABLE_VERSION_3_0,
TableKey
);
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Bm.vfr b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Bm.vfr
index fd14a7714..afbbfdddf 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Bm.vfr
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Bm.vfr
@@ -55,7 +55,7 @@ formset
subtitle text = STRING_TOKEN(STR_NULL_STRING);
- goto FORM_CON_MAIN_ID,
+ goto FORM_BOOT_FROM_FILE_ID,
prompt = STRING_TOKEN(STR_BOOT_FROM_FILE),
help = STRING_TOKEN(STR_BOOT_FROM_FILE_HELP),
flags = INTERACTIVE,
@@ -154,13 +154,6 @@ formset
key = FORM_DRV_CHG_ID;
endform;
- form formid = FORM_BOOT_ADD_ID,
- title = STRING_TOKEN(STR_FORM_BOOT_ADD_TITLE);
-
- label FORM_BOOT_ADD_ID;
- label LABEL_END;
- endform;
-
form formid = FORM_BOOT_DEL_ID,
title = STRING_TOKEN(STR_FORM_BOOT_DEL_TITLE);
@@ -298,13 +291,6 @@ formset
label LABEL_END;
endform;
- form formid = FORM_DRV_ADD_FILE_ID,
- title = STRING_TOKEN(STR_FORM_DRV_ADD_FILE_TITLE);
-
- label FORM_DRV_ADD_FILE_ID;
- label LABEL_END;
- endform;
-
form formid = FORM_DRV_ADD_HANDLE_ID,
title = STRING_TOKEN(STR_FORM_DRV_ADD_HANDLE_TITLE);
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c
index 4c8e3c8a4..1186c0cb1 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c
@@ -280,92 +280,71 @@ BootMaintCallback (
UINTN Pos;
UINTN Bit;
UINT16 NewValuePos;
+ UINT16 Index3;
UINT16 Index2;
UINT16 Index;
UINT8 *OldLegacyDev;
UINT8 *NewLegacyDev;
UINT8 *DisMap;
- EFI_FORM_ID FormId;
- Status = EFI_SUCCESS;
+ if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {
+ //
+ // All other action return unsupported.
+ //
+ return EFI_UNSUPPORTED;
+ }
+
+ Status = EFI_SUCCESS;
+ OldValue = 0;
+ NewValue = 0;
+ Number = 0;
+ OldLegacyDev = NULL;
+ NewLegacyDev = NULL;
+ NewValuePos = 0;
+ DisMap = NULL;
+
+ Private = BMM_CALLBACK_DATA_FROM_THIS (This);
+ //
+ // Retrive uncommitted data from Form Browser
+ //
+ CurrentFakeNVMap = &Private->BmmFakeNvData;
+ HiiGetBrowserData (&gBootMaintFormSetGuid, mBootMaintStorageName, sizeof (BMM_FAKE_NV_DATA), (UINT8 *) CurrentFakeNVMap);
if (Action == EFI_BROWSER_ACTION_CHANGING) {
- if ((Value == NULL) || (ActionRequest == NULL)) {
+ if (Value == NULL) {
return EFI_INVALID_PARAMETER;
}
-
- OldValue = 0;
- NewValue = 0;
- Number = 0;
- OldLegacyDev = NULL;
- NewLegacyDev = NULL;
- NewValuePos = 0;
- DisMap = NULL;
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_NONE;
-
- Private = BMM_CALLBACK_DATA_FROM_THIS (This);
+
UpdatePageId (Private, QuestionId);
//
- // Retrive uncommitted data from Form Browser
- //
- CurrentFakeNVMap = &Private->BmmFakeNvData;
- HiiGetBrowserData (&gBootMaintFormSetGuid, mBootMaintStorageName, sizeof (BMM_FAKE_NV_DATA), (UINT8 *) CurrentFakeNVMap);
-
- //
// need to be subtituded.
//
// Update Select FD/HD/CD/NET/BEV Order Form
//
- if (FORM_SET_FD_ORDER_ID == Private->BmmPreviousPageId ||
- FORM_SET_HD_ORDER_ID == Private->BmmPreviousPageId ||
- FORM_SET_CD_ORDER_ID == Private->BmmPreviousPageId ||
- FORM_SET_NET_ORDER_ID == Private->BmmPreviousPageId ||
- FORM_SET_BEV_ORDER_ID == Private->BmmPreviousPageId ||
- ((FORM_BOOT_SETUP_ID == Private->BmmPreviousPageId) &&
- (QuestionId >= LEGACY_FD_QUESTION_ID) &&
- (QuestionId < (LEGACY_BEV_QUESTION_ID + 100)) )
- ) {
+ if ((QuestionId >= LEGACY_FD_QUESTION_ID) && (QuestionId < LEGACY_BEV_QUESTION_ID + MAX_MENU_NUMBER)) {
DisMap = Private->BmmOldFakeNVData.DisableMap;
- FormId = Private->BmmPreviousPageId;
- if (FormId == FORM_BOOT_SETUP_ID) {
- FormId = Private->BmmCurrentPageId;
- }
-
- switch (FormId) {
- case FORM_SET_FD_ORDER_ID:
+ if (QuestionId >= LEGACY_FD_QUESTION_ID && QuestionId < LEGACY_FD_QUESTION_ID + MAX_MENU_NUMBER) {
Number = (UINT16) LegacyFDMenu.MenuNumber;
OldLegacyDev = Private->BmmOldFakeNVData.LegacyFD;
NewLegacyDev = CurrentFakeNVMap->LegacyFD;
- break;
-
- case FORM_SET_HD_ORDER_ID:
+ } else if (QuestionId >= LEGACY_HD_QUESTION_ID && QuestionId < LEGACY_HD_QUESTION_ID + MAX_MENU_NUMBER) {
Number = (UINT16) LegacyHDMenu.MenuNumber;
OldLegacyDev = Private->BmmOldFakeNVData.LegacyHD;
NewLegacyDev = CurrentFakeNVMap->LegacyHD;
- break;
-
- case FORM_SET_CD_ORDER_ID:
+ } else if (QuestionId >= LEGACY_CD_QUESTION_ID && QuestionId < LEGACY_CD_QUESTION_ID + MAX_MENU_NUMBER) {
Number = (UINT16) LegacyCDMenu.MenuNumber;
OldLegacyDev = Private->BmmOldFakeNVData.LegacyCD;
NewLegacyDev = CurrentFakeNVMap->LegacyCD;
- break;
-
- case FORM_SET_NET_ORDER_ID:
+ } else if (QuestionId >= LEGACY_NET_QUESTION_ID && QuestionId < LEGACY_NET_QUESTION_ID + MAX_MENU_NUMBER) {
Number = (UINT16) LegacyNETMenu.MenuNumber;
OldLegacyDev = Private->BmmOldFakeNVData.LegacyNET;
NewLegacyDev = CurrentFakeNVMap->LegacyNET;
- break;
-
- case FORM_SET_BEV_ORDER_ID:
+ } else if (QuestionId >= LEGACY_BEV_QUESTION_ID && QuestionId < LEGACY_BEV_QUESTION_ID + MAX_MENU_NUMBER) {
Number = (UINT16) LegacyBEVMenu.MenuNumber;
OldLegacyDev = Private->BmmOldFakeNVData.LegacyBEV;
NewLegacyDev = CurrentFakeNVMap->LegacyBEV;
- break;
-
- default:
- break;
}
//
// First, find the different position
@@ -450,6 +429,7 @@ BootMaintCallback (
// To prevent DISABLE appears in the middle of the list
// we should perform a re-ordering
//
+ Index3 = Index;
Index = 0;
while (Index < Number) {
if (0xFF != NewLegacyDev[Index]) {
@@ -480,6 +460,11 @@ BootMaintCallback (
NewLegacyDev,
Number
);
+
+ //
+ // Return correct question value.
+ //
+ Value->u8 = NewLegacyDev[Index3];
}
}
@@ -488,29 +473,14 @@ BootMaintCallback (
switch (QuestionId) {
case KEY_VALUE_BOOT_FROM_FILE:
Private->FeCurrentState = FileExplorerStateBootFromFile;
-
- //
- // Exit Bmm main formset to send File Explorer formset.
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
break;
case FORM_BOOT_ADD_ID:
Private->FeCurrentState = FileExplorerStateAddBootOption;
-
- //
- // Exit Bmm main formset to send File Explorer formset.
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
break;
case FORM_DRV_ADD_FILE_ID:
Private->FeCurrentState = FileExplorerStateAddDriverOptionState;
-
- //
- // Exit Bmm main formset to send File Explorer formset.
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
break;
case FORM_DRV_ADD_HANDLE_ID:
@@ -543,10 +513,6 @@ BootMaintCallback (
UpdateTimeOutPage (Private);
break;
- case FORM_RESET:
- gRT->ResetSystem (EfiResetCold, EFI_SUCCESS, 0, NULL);
- return EFI_UNSUPPORTED;
-
case FORM_CON_IN_ID:
case FORM_CON_OUT_ID:
case FORM_CON_ERR_ID:
@@ -572,25 +538,6 @@ BootMaintCallback (
UpdateSetLegacyDeviceOrderPage (QuestionId, Private);
break;
- case KEY_VALUE_SAVE_AND_EXIT:
- case KEY_VALUE_NO_SAVE_AND_EXIT:
-
- if (QuestionId == KEY_VALUE_SAVE_AND_EXIT) {
- Status = ApplyChangeHandler (Private, CurrentFakeNVMap, Private->BmmPreviousPageId);
- if (EFI_ERROR (Status)) {
- return Status;
- }
- } else if (QuestionId == KEY_VALUE_NO_SAVE_AND_EXIT) {
- DiscardChangeHandler (Private, CurrentFakeNVMap);
- }
-
- //
- // Tell browser not to ask for confirmation of changes,
- // since we have already applied or discarded.
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
- break;
-
default:
break;
}
@@ -616,18 +563,44 @@ BootMaintCallback (
UpdateDriverAddHandleDescPage (Private);
}
}
+ } else if (Action == EFI_BROWSER_ACTION_CHANGED) {
+ if ((Value == NULL) || (ActionRequest == NULL)) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ switch (QuestionId) {
+ case KEY_VALUE_SAVE_AND_EXIT:
+ case KEY_VALUE_NO_SAVE_AND_EXIT:
+ if (QuestionId == KEY_VALUE_SAVE_AND_EXIT) {
+ Status = ApplyChangeHandler (Private, CurrentFakeNVMap, Private->BmmPreviousPageId);
+ if (EFI_ERROR (Status)) {
+ return Status;
+ }
+ } else if (QuestionId == KEY_VALUE_NO_SAVE_AND_EXIT) {
+ DiscardChangeHandler (Private, CurrentFakeNVMap);
+ }
- //
- // Pass changed uncommitted data back to Form Browser
- //
- Status = HiiSetBrowserData (&gBootMaintFormSetGuid, mBootMaintStorageName, sizeof (BMM_FAKE_NV_DATA), (UINT8 *) CurrentFakeNVMap, NULL);
- return Status;
+ //
+ // Tell browser not to ask for confirmation of changes,
+ // since we have already applied or discarded.
+ //
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
+ break;
+
+ case FORM_RESET:
+ gRT->ResetSystem (EfiResetCold, EFI_SUCCESS, 0, NULL);
+ return EFI_UNSUPPORTED;
+
+ default:
+ break;
+ }
}
//
- // All other action return unsupported.
+ // Pass changed uncommitted data back to Form Browser
//
- return EFI_UNSUPPORTED;
+ HiiSetBrowserData (&gBootMaintFormSetGuid, mBootMaintStorageName, sizeof (BMM_FAKE_NV_DATA), (UINT8 *) CurrentFakeNVMap, NULL);
+ return EFI_SUCCESS;
}
/**
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FileExplorer.c b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FileExplorer.c
index b77e909ad..733632b9f 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FileExplorer.c
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FileExplorer.c
@@ -253,21 +253,27 @@ FileExplorerCallback (
FILE_EXPLORER_NV_DATA *NvRamMap;
EFI_STATUS Status;
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
- if ((Value == NULL) || (ActionRequest == NULL)) {
- return EFI_INVALID_PARAMETER;
- }
-
- Status = EFI_SUCCESS;
- Private = FE_CALLBACK_DATA_FROM_THIS (This);
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_NONE;
-
+ if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {
//
- // Retrieve uncommitted data from Form Browser
+ // All other action return unsupported.
//
- NvRamMap = &Private->FeFakeNvData;
- HiiGetBrowserData (&gFileExploreFormSetGuid, mFileExplorerStorageName, sizeof (FILE_EXPLORER_NV_DATA), (UINT8 *) NvRamMap);
+ return EFI_UNSUPPORTED;
+ }
+
+ Status = EFI_SUCCESS;
+ Private = FE_CALLBACK_DATA_FROM_THIS (This);
+ //
+ // Retrieve uncommitted data from Form Browser
+ //
+ NvRamMap = &Private->FeFakeNvData;
+ HiiGetBrowserData (&gFileExploreFormSetGuid, mFileExplorerStorageName, sizeof (FILE_EXPLORER_NV_DATA), (UINT8 *) NvRamMap);
+
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
+ if ((Value == NULL) || (ActionRequest == NULL)) {
+ return EFI_INVALID_PARAMETER;
+ }
+
if (QuestionId == KEY_VALUE_SAVE_AND_EXIT_BOOT || QuestionId == KEY_VALUE_SAVE_AND_EXIT_DRIVER) {
//
// Apply changes and exit formset
@@ -309,16 +315,16 @@ FileExplorerCallback (
// Exit File Explorer formset
//
*ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
- } else {
- if (UpdateFileExplorer (Private, QuestionId)) {
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
- }
}
-
- return Status;
+ } else if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if (Value == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ if (QuestionId >= FILE_OPTION_OFFSET) {
+ UpdateFileExplorer (Private, QuestionId);
+ }
}
- //
- // All other action return unsupported.
- //
- return EFI_UNSUPPORTED;
+
+ return Status;
}
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FormGuid.h b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FormGuid.h
index 1087db847..f0049a304 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FormGuid.h
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FormGuid.h
@@ -49,6 +49,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#define FORM_BOOT_ADD_DESCRIPTION_ID 0x101F
#define FORM_DRIVER_ADD_FILE_DESCRIPTION_ID 0x1020
#define FORM_CON_MODE_ID 0x1021
+#define FORM_BOOT_FROM_FILE_ID 0x1022
#define MAXIMUM_FORM_ID 0x10FF
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/UpdatePage.c b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/UpdatePage.c
index f77b9f82e..7d4f33d40 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/UpdatePage.c
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/UpdatePage.c
@@ -99,26 +99,26 @@ UpdatePageEnd (
0
);
- HiiCreateGotoOpCode (
+ HiiCreateActionOpCode (
mStartOpCodeHandle,
- FORM_MAIN_ID,
+ KEY_VALUE_SAVE_AND_EXIT,
STRING_TOKEN (STR_SAVE_AND_EXIT),
STRING_TOKEN (STR_NULL_STRING),
EFI_IFR_FLAG_CALLBACK,
- KEY_VALUE_SAVE_AND_EXIT
+ 0
);
}
//
// Ensure user can return to the main page.
//
- HiiCreateGotoOpCode (
+ HiiCreateActionOpCode (
mStartOpCodeHandle,
- FORM_MAIN_ID,
+ KEY_VALUE_NO_SAVE_AND_EXIT,
STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
STRING_TOKEN (STR_NULL_STRING),
EFI_IFR_FLAG_CALLBACK,
- KEY_VALUE_NO_SAVE_AND_EXIT
+ 0
);
HiiUpdateForm (
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Variable.c b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Variable.c
index ac7e61496..c4b83ba0f 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Variable.c
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Variable.c
@@ -673,14 +673,13 @@ Var_UpdateDriverOption (
&gEfiGlobalVariableGuid,
&DriverOrderListSize
);
- ASSERT (DriverOrderList != NULL);
NewDriverOrderList = AllocateZeroPool (DriverOrderListSize + sizeof (UINT16));
ASSERT (NewDriverOrderList != NULL);
- CopyMem (NewDriverOrderList, DriverOrderList, DriverOrderListSize);
- NewDriverOrderList[DriverOrderListSize / sizeof (UINT16)] = Index;
if (DriverOrderList != NULL) {
+ CopyMem (NewDriverOrderList, DriverOrderList, DriverOrderListSize);
EfiLibDeleteVariable (L"DriverOrder", &gEfiGlobalVariableGuid);
}
+ NewDriverOrderList[DriverOrderListSize / sizeof (UINT16)] = Index;
Status = gRT->SetVariable (
L"DriverOrder",
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.c b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.c
index 0a7561b18..f86d55594 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.c
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.c
@@ -95,7 +95,7 @@ BootManagerCallback (
LIST_ENTRY *Link;
UINT16 KeyCount;
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
if ((Value == NULL) || (ActionRequest == NULL)) {
return EFI_INVALID_PARAMETER;
}
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManager.c b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManager.c
index d0bf76466..6cb9d6b7a 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManager.c
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManager.c
@@ -133,35 +133,30 @@ DeviceManagerCallback (
{
UINTN CurIndex;
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
- if ((Value == NULL) || (ActionRequest == NULL)) {
- return EFI_INVALID_PARAMETER;
- }
-
- gCallbackKey = QuestionId;
- if ((QuestionId < MAX_KEY_SECTION_LEN + NETWORK_DEVICE_LIST_KEY_OFFSET) && (QuestionId >= NETWORK_DEVICE_LIST_KEY_OFFSET)) {
- //
- // If user select the mac address, need to record mac address string to support next form show.
- //
- for (CurIndex = 0; CurIndex < mMacDeviceList.CurListLen; CurIndex ++) {
- if (mMacDeviceList.NodeList[CurIndex].QuestionId == QuestionId) {
- mSelectedMacAddrString = HiiGetString (gDeviceManagerPrivate.HiiHandle, mMacDeviceList.NodeList[CurIndex].PromptId, NULL);
- }
- }
- }
-
+ if (Action != EFI_BROWSER_ACTION_CHANGING) {
//
- // Request to exit SendForm(), so as to switch to selected form
+ // All other action return unsupported.
//
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
+ return EFI_UNSUPPORTED;
+ }
- return EFI_SUCCESS;
+ if (Value == NULL) {
+ return EFI_INVALID_PARAMETER;
}
- //
- // All other action return unsupported.
- //
- return EFI_UNSUPPORTED;
+ gCallbackKey = QuestionId;
+ if ((QuestionId < MAX_KEY_SECTION_LEN + NETWORK_DEVICE_LIST_KEY_OFFSET) && (QuestionId >= NETWORK_DEVICE_LIST_KEY_OFFSET)) {
+ //
+ // If user select the mac address, need to record mac address string to support next form show.
+ //
+ for (CurIndex = 0; CurIndex < mMacDeviceList.CurListLen; CurIndex ++) {
+ if (mMacDeviceList.NodeList[CurIndex].QuestionId == QuestionId) {
+ mSelectedMacAddrString = HiiGetString (gDeviceManagerPrivate.HiiHandle, mMacDeviceList.NodeList[CurIndex].PromptId, NULL);
+ }
+ }
+ }
+
+ return EFI_SUCCESS;
}
/**
@@ -873,7 +868,7 @@ CallDeviceManager (
AddNetworkMenu = TRUE;
HiiCreateGotoOpCode (
StartOpCodeHandle,
- DEVICE_MANAGER_FORM_ID,
+ INVALID_FORM_ID,
STRING_TOKEN (STR_FORM_NETWORK_DEVICE_LIST_TITLE),
STRING_TOKEN (STR_FORM_NETWORK_DEVICE_LIST_HELP),
EFI_IFR_FLAG_CALLBACK,
@@ -887,7 +882,7 @@ CallDeviceManager (
while (AddItemCount > 0) {
HiiCreateGotoOpCode (
StartOpCodeHandle,
- NETWORK_DEVICE_LIST_FORM_ID,
+ INVALID_FORM_ID,
mMacDeviceList.NodeList[mMacDeviceList.CurListLen - AddItemCount].PromptId,
STRING_TOKEN (STR_NETWORK_DEVICE_HELP),
EFI_IFR_FLAG_CALLBACK,
@@ -901,7 +896,7 @@ CallDeviceManager (
//
HiiCreateGotoOpCode (
StartOpCodeHandle,
- NETWORK_DEVICE_FORM_ID,
+ INVALID_FORM_ID,
Token,
TokenHelp,
EFI_IFR_FLAG_CALLBACK,
@@ -916,7 +911,7 @@ CallDeviceManager (
if (mNextShowFormId == DEVICE_MANAGER_FORM_ID) {
HiiCreateGotoOpCode (
StartOpCodeHandle,
- DEVICE_MANAGER_FORM_ID,
+ INVALID_FORM_ID,
Token,
TokenHelp,
EFI_IFR_FLAG_CALLBACK,
@@ -1097,7 +1092,7 @@ DriverHealthCallback (
OUT EFI_BROWSER_ACTION_REQUEST *ActionRequest
)
{
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
if ((Value == NULL) || (ActionRequest == NULL)) {
return EFI_INVALID_PARAMETER;
}
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManagerVfr.h b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManagerVfr.h
index 96e2c0a2c..b6b086600 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManagerVfr.h
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManagerVfr.h
@@ -31,6 +31,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#define LABEL_VBIOS 0x0040
+#define INVALID_FORM_ID 0x0FFF
#define DEVICE_MANAGER_FORM_ID 0x1000
#define NETWORK_DEVICE_LIST_FORM_ID 0x1001
#define NETWORK_DEVICE_FORM_ID 0x1002
diff --git a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPage.c b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPage.c
index 8a8286a70..efecf7bec 100644
--- a/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPage.c
+++ b/edk2/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPage.c
@@ -175,23 +175,26 @@ FrontPageCallback (
CHAR8 *PlatformSupportedLanguages;
CHAR8 *BestLanguage;
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {
+ //
+ // All other action return unsupported.
+ //
+ return EFI_UNSUPPORTED;
+ }
+
+ gCallbackKey = QuestionId;
+
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
if ((Value == NULL) || (ActionRequest == NULL)) {
return EFI_INVALID_PARAMETER;
}
- gCallbackKey = QuestionId;
-
- //
- // The first 4 entries in the Front Page are to be GUARANTEED to remain constant so IHV's can
- // describe to their customers in documentation how to find their setup information (namely
- // under the device manager and specific buckets)
- //
switch (QuestionId) {
case FRONT_PAGE_KEY_CONTINUE:
//
// This is the continue - clear the screen and return an error to get out of FrontPage loop
//
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
break;
case FRONT_PAGE_KEY_LANGUAGE:
@@ -250,11 +253,27 @@ FrontPageCallback (
ASSERT (FALSE);
}
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
+
FreePool (PlatformSupportedLanguages);
FreePool (Lang);
FreePool (LanguageString);
break;
+ default:
+ break;
+ }
+ } else if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if (Value == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ //
+ // The first 4 entries in the Front Page are to be GUARANTEED to remain constant so IHV's can
+ // describe to their customers in documentation how to find their setup information (namely
+ // under the device manager and specific buckets)
+ //
+ switch (QuestionId) {
case FRONT_PAGE_KEY_BOOT_MANAGER:
//
// Boot Manager
@@ -277,16 +296,9 @@ FrontPageCallback (
gCallbackKey = 0;
break;
}
-
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
-
- return EFI_SUCCESS;
}
- //
- // All other action return unsupported.
- //
- return EFI_UNSUPPORTED;
+ return EFI_SUCCESS;
}
/**
@@ -1181,6 +1193,7 @@ PlatformBdsEnterFrontPage (
BootLogo->SetBootLogo (BootLogo, NULL, 0, 0, 0, 0);
}
+ Status = EFI_SUCCESS;
do {
//
// Set proper video resolution and text mode for setup
@@ -1195,7 +1208,7 @@ PlatformBdsEnterFrontPage (
UpdateFrontPageStrings ();
gCallbackKey = 0;
- Status = CallFrontPage ();
+ CallFrontPage ();
//
// If gCallbackKey is greater than 1 and less or equal to 5,
diff --git a/edk2/IntelFrameworkPkg/Include/Guid/DataHubRecords.h b/edk2/IntelFrameworkPkg/Include/Guid/DataHubRecords.h
index d898953ea..05b393b5e 100644
--- a/edk2/IntelFrameworkPkg/Include/Guid/DataHubRecords.h
+++ b/edk2/IntelFrameworkPkg/Include/Guid/DataHubRecords.h
@@ -859,6 +859,11 @@ typedef struct {
UINT32 NonBurst :1;
UINT32 Burst :1;
UINT32 PipelineBurst :1;
+ ///
+ /// Inconsistent between CacheSubclass 0.9 and SMBIOS specifications here:
+ /// In CacheSubclass specification 0.9, the sequence of Asynchronous and Synchronous fileds
+ /// are opposite to SMBIOS specification.
+ ///
UINT32 Asynchronous :1;
UINT32 Synchronous :1;
UINT32 Reserved :25;
diff --git a/edk2/IntelFrameworkPkg/IntelFrameworkPkg.dec b/edk2/IntelFrameworkPkg/IntelFrameworkPkg.dec
index 71654b039..e949b8a62 100644
--- a/edk2/IntelFrameworkPkg/IntelFrameworkPkg.dec
+++ b/edk2/IntelFrameworkPkg/IntelFrameworkPkg.dec
@@ -16,7 +16,7 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = IntelFrameworkPkg
PACKAGE_GUID = 2759ded5-bb57-4b06-af4f-c398fa552719
- PACKAGE_VERSION = 0.91
+ PACKAGE_VERSION = 0.92
[Includes]
Include # Root include for the package
diff --git a/edk2/IntelFrameworkPkg/IntelFrameworkPkg.dsc b/edk2/IntelFrameworkPkg/IntelFrameworkPkg.dsc
index 459aecea8..6a0623f28 100644
--- a/edk2/IntelFrameworkPkg/IntelFrameworkPkg.dsc
+++ b/edk2/IntelFrameworkPkg/IntelFrameworkPkg.dsc
@@ -3,7 +3,7 @@
#
# This DSC file is used for Package Level build.
#
-# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
@@ -23,7 +23,7 @@
[Defines]
PLATFORM_NAME = IntelFramework
PLATFORM_GUID = E76EB141-6EDB-43f3-A455-EF24A79673DD
- PLATFORM_VERSION = 0.91
+ PLATFORM_VERSION = 0.92
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/IntelFramework
SUPPORTED_ARCHITECTURES = IA32|IPF|X64|EBC|ARM
diff --git a/edk2/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.c b/edk2/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.c
index 72196a004..2494c6abf 100644
--- a/edk2/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.c
+++ b/edk2/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.c
@@ -2028,7 +2028,8 @@ ExtScsiPassThruGetNextTargetLun (
if ((DeviceInfo->Type == EfiIdeCdrom) &&
((Target8[0] < DeviceInfo->Port) ||
- (Target8[1] < DeviceInfo->PortMultiplier))) {
+ ((Target8[0] == DeviceInfo->Port) &&
+ (Target8[1] < DeviceInfo->PortMultiplier)))) {
Target8[0] = (UINT8)DeviceInfo->Port;
Target8[1] = (UINT8)DeviceInfo->PortMultiplier;
goto Exit;
@@ -2366,7 +2367,8 @@ ExtScsiPassThruGetNextTarget (
if ((DeviceInfo->Type == EfiIdeCdrom) &&
((Target8[0] < DeviceInfo->Port) ||
- (Target8[1] < DeviceInfo->PortMultiplier))) {
+ ((Target8[0] == DeviceInfo->Port) &&
+ (Target8[1] < DeviceInfo->PortMultiplier)))) {
Target8[0] = (UINT8)DeviceInfo->Port;
Target8[1] = (UINT8)DeviceInfo->PortMultiplier;
goto Exit;
diff --git a/edk2/MdeModulePkg/Bus/Pci/PciBusDxe/PciIo.c b/edk2/MdeModulePkg/Bus/Pci/PciBusDxe/PciIo.c
index 64f1f1b7c..08ecaa4d1 100644
--- a/edk2/MdeModulePkg/Bus/Pci/PciBusDxe/PciIo.c
+++ b/edk2/MdeModulePkg/Bus/Pci/PciBusDxe/PciIo.c
@@ -1580,24 +1580,6 @@ PciIoAttributes (
}
//
- // workaround for PCI drivers which always set ISA_IO or VGA_IO attribute without detecting support of
- // ISA_IO/ISA_IO_16 or VGA_IO/VGA_IO_16 to maintain backward-compatibility.
- //
- if (((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO) != 0) &&
- ((PciIoDevice->Supports & (EFI_PCI_IO_ATTRIBUTE_VGA_IO | EFI_PCI_IO_ATTRIBUTE_VGA_IO_16)) \
- == EFI_PCI_IO_ATTRIBUTE_VGA_IO_16)) {
- Attributes &= ~(UINT64)EFI_PCI_IO_ATTRIBUTE_VGA_IO;
- Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_IO_16;
- }
-
- if (((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO) != 0) &&
- ((PciIoDevice->Supports & (EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO | EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16)) \
- == EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16)) {
- Attributes &= ~(UINT64)EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO;
- Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16;
- }
-
- //
// If no attributes can be supported, then return.
// Otherwise, set the attributes that it can support.
//
diff --git a/edk2/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c b/edk2/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c
index 68f5ef5d6..16fd793c1 100644
--- a/edk2/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c
+++ b/edk2/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c
@@ -708,25 +708,104 @@ FvHasBeenProcessed (
/**
Remember that Fv protocol on FvHandle has had it's drivers placed on the
- mDiscoveredList. This fucntion adds entries on the mFvHandleList. Items are
- never removed/freed from the mFvHandleList.
+ mDiscoveredList. This fucntion adds entries on the mFvHandleList if new
+ entry is different from one in mFvHandleList by checking FvImage Guid.
+ Items are never removed/freed from the mFvHandleList.
@param FvHandle The handle of a FV that has been processed
+ @return A point to new added FvHandle entry. If FvHandle with the same FvImage guid
+ has been added, NULL will return.
+
**/
-VOID
+KNOWN_HANDLE *
FvIsBeingProcesssed (
IN EFI_HANDLE FvHandle
)
{
- KNOWN_HANDLE *KnownHandle;
+ EFI_STATUS Status;
+ EFI_GUID FvNameGuid;
+ BOOLEAN FvNameGuidIsFound;
+ UINT32 ExtHeaderOffset;
+ EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL *Fvb;
+ EFI_FIRMWARE_VOLUME_HEADER *FwVolHeader;
+ EFI_FV_BLOCK_MAP_ENTRY *BlockMap;
+ UINTN LbaOffset;
+ UINTN Index;
+ EFI_LBA LbaIndex;
+ LIST_ENTRY *Link;
+ KNOWN_HANDLE *KnownHandle;
- KnownHandle = AllocatePool (sizeof (KNOWN_HANDLE));
+ //
+ // Get the FirmwareVolumeBlock protocol on that handle
+ //
+ FvNameGuidIsFound = FALSE;
+ Status = CoreHandleProtocol (FvHandle, &gEfiFirmwareVolumeBlockProtocolGuid, (VOID **)&Fvb);
+ if (!EFI_ERROR (Status)) {
+ //
+ // Get the full FV header based on FVB protocol.
+ //
+ ASSERT (Fvb != NULL);
+ Status = GetFwVolHeader (Fvb, &FwVolHeader);
+ if (!EFI_ERROR (Status)) {
+ ASSERT (FwVolHeader != NULL);
+ if (VerifyFvHeaderChecksum (FwVolHeader) && FwVolHeader->ExtHeaderOffset != 0) {
+ ExtHeaderOffset = (UINT32) FwVolHeader->ExtHeaderOffset;
+ BlockMap = FwVolHeader->BlockMap;
+ LbaIndex = 0;
+ LbaOffset = 0;
+ //
+ // Find LbaIndex and LbaOffset for FV extension header based on BlockMap.
+ //
+ while ((BlockMap->NumBlocks != 0) || (BlockMap->Length != 0)) {
+ for (Index = 0; Index < BlockMap->NumBlocks && ExtHeaderOffset >= BlockMap->Length; Index ++) {
+ ExtHeaderOffset -= BlockMap->Length;
+ LbaIndex ++;
+ }
+ //
+ // Check whether FvExtHeader is crossing the multi block range.
+ //
+ if (Index < BlockMap->NumBlocks) {
+ LbaOffset = ExtHeaderOffset;
+ break;
+ }
+ BlockMap++;
+ }
+ //
+ // Read FvNameGuid from FV extension header.
+ //
+ Status = ReadFvbData (Fvb, &LbaIndex, &LbaOffset, sizeof (FvNameGuid), (UINT8 *) &FvNameGuid);
+ if (!EFI_ERROR (Status)) {
+ FvNameGuidIsFound = TRUE;
+ }
+ }
+ CoreFreePool (FwVolHeader);
+ }
+ }
+
+ if (FvNameGuidIsFound) {
+ //
+ // Check whether the FV image with the found FvNameGuid has been processed.
+ //
+ for (Link = mFvHandleList.ForwardLink; Link != &mFvHandleList; Link = Link->ForwardLink) {
+ KnownHandle = CR(Link, KNOWN_HANDLE, Link, KNOWN_HANDLE_SIGNATURE);
+ if (CompareGuid (&FvNameGuid, &KnownHandle->FvNameGuid)) {
+ DEBUG ((EFI_D_ERROR, "FvImage on FvHandle %p and %p has the same FvNameGuid %g.\n", FvHandle, KnownHandle->Handle, FvNameGuid));
+ return NULL;
+ }
+ }
+ }
+
+ KnownHandle = AllocateZeroPool (sizeof (KNOWN_HANDLE));
ASSERT (KnownHandle != NULL);
KnownHandle->Signature = KNOWN_HANDLE_SIGNATURE;
KnownHandle->Handle = FvHandle;
+ if (FvNameGuidIsFound) {
+ CopyGuid (&KnownHandle->FvNameGuid, &FvNameGuid);
+ }
InsertTailList (&mFvHandleList, &KnownHandle->Link);
+ return KnownHandle;
}
@@ -844,7 +923,7 @@ CoreAddToDriverList (
Check if a FV Image type file (EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE) is
described by a EFI_HOB_FIRMWARE_VOLUME2 Hob.
- @param FvHandle The handle which FVB protocol installed on.
+ @param FvNameGuid The FV image guid specified.
@param DriverName The driver guid specified.
@retval TRUE This file is found in a EFI_HOB_FIRMWARE_VOLUME2
@@ -854,7 +933,7 @@ CoreAddToDriverList (
**/
BOOLEAN
FvFoundInHobFv2 (
- IN EFI_HANDLE FvHandle,
+ IN CONST EFI_GUID *FvNameGuid,
IN CONST EFI_GUID *DriverName
)
{
@@ -863,7 +942,11 @@ FvFoundInHobFv2 (
HobFv2.Raw = GetHobList ();
while ((HobFv2.Raw = GetNextHob (EFI_HOB_TYPE_FV2, HobFv2.Raw)) != NULL) {
- if (CompareGuid (DriverName, &HobFv2.FirmwareVolume2->FileName)) {
+ //
+ // Compare parent FvNameGuid and FileGuid both.
+ //
+ if (CompareGuid (DriverName, &HobFv2.FirmwareVolume2->FileName) &&
+ CompareGuid (FvNameGuid, &HobFv2.FirmwareVolume2->FvName)) {
return TRUE;
}
HobFv2.Raw = GET_NEXT_HOB (HobFv2);
@@ -1021,6 +1104,7 @@ CoreFwVolEventProtocolNotify (
UINT32 AuthenticationStatus;
UINTN SizeOfBuffer;
VOID *DepexBuffer;
+ KNOWN_HANDLE *KnownHandle;
while (TRUE) {
BufferSize = sizeof (EFI_HANDLE);
@@ -1048,7 +1132,14 @@ CoreFwVolEventProtocolNotify (
//
// Since we are about to process this Fv mark it as processed.
//
- FvIsBeingProcesssed (FvHandle);
+ KnownHandle = FvIsBeingProcesssed (FvHandle);
+ if (KnownHandle == NULL) {
+ //
+ // The FV with the same FV name guid has already been processed.
+ // So lets skip it!
+ //
+ continue;
+ }
Status = CoreHandleProtocol (FvHandle, &gEfiFirmwareVolume2ProtocolGuid, (VOID **)&Fv);
if (EFI_ERROR (Status) || Fv == NULL) {
@@ -1131,7 +1222,7 @@ CoreFwVolEventProtocolNotify (
// Check if this EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE file has already
// been extracted.
//
- if (FvFoundInHobFv2 (FvHandle, &NameGuid)) {
+ if (FvFoundInHobFv2 (&KnownHandle->FvNameGuid, &NameGuid)) {
continue;
}
diff --git a/edk2/MdeModulePkg/Core/Dxe/DxeMain.h b/edk2/MdeModulePkg/Core/Dxe/DxeMain.h
index 8cdfe0605..cf65c1526 100644
--- a/edk2/MdeModulePkg/Core/Dxe/DxeMain.h
+++ b/edk2/MdeModulePkg/Core/Dxe/DxeMain.h
@@ -134,6 +134,7 @@ typedef struct {
UINTN Signature;
LIST_ENTRY Link; // mFvHandleList
EFI_HANDLE Handle;
+ EFI_GUID FvNameGuid;
} KNOWN_HANDLE;
@@ -2489,4 +2490,64 @@ CoreEmptyCallbackFunction (
IN VOID *Context
);
+/**
+ Read data from Firmware Block by FVB protocol Read.
+ The data may cross the multi block ranges.
+
+ @param Fvb The FW_VOL_BLOCK_PROTOCOL instance from which to read data.
+ @param StartLba Pointer to StartLba.
+ On input, the start logical block index from which to read.
+ On output,the end logical block index after reading.
+ @param Offset Pointer to Offset
+ On input, offset into the block at which to begin reading.
+ On output, offset into the end block after reading.
+ @param DataSize Size of data to be read.
+ @param Data Pointer to Buffer that the data will be read into.
+
+ @retval EFI_SUCCESS Successfully read data from firmware block.
+ @retval others
+**/
+EFI_STATUS
+ReadFvbData (
+ IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL *Fvb,
+ IN OUT EFI_LBA *StartLba,
+ IN OUT UINTN *Offset,
+ IN UINTN DataSize,
+ OUT UINT8 *Data
+ );
+
+/**
+ Given the supplied FW_VOL_BLOCK_PROTOCOL, allocate a buffer for output and
+ copy the real length volume header into it.
+
+ @param Fvb The FW_VOL_BLOCK_PROTOCOL instance from which to
+ read the volume header
+ @param FwVolHeader Pointer to pointer to allocated buffer in which
+ the volume header is returned.
+
+ @retval EFI_OUT_OF_RESOURCES No enough buffer could be allocated.
+ @retval EFI_SUCCESS Successfully read volume header to the allocated
+ buffer.
+
+**/
+EFI_STATUS
+GetFwVolHeader (
+ IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL *Fvb,
+ OUT EFI_FIRMWARE_VOLUME_HEADER **FwVolHeader
+ );
+
+/**
+ Verify checksum of the firmware volume header.
+
+ @param FvHeader Points to the firmware volume header to be checked
+
+ @retval TRUE Checksum verification passed
+ @retval FALSE Checksum verification failed
+
+**/
+BOOLEAN
+VerifyFvHeaderChecksum (
+ IN EFI_FIRMWARE_VOLUME_HEADER *FvHeader
+ );
+
#endif
diff --git a/edk2/MdeModulePkg/Core/Dxe/FwVol/FwVol.c b/edk2/MdeModulePkg/Core/Dxe/FwVol/FwVol.c
index 1e1cbae36..07cbbb94d 100644
--- a/edk2/MdeModulePkg/Core/Dxe/FwVol/FwVol.c
+++ b/edk2/MdeModulePkg/Core/Dxe/FwVol/FwVol.c
@@ -357,7 +357,7 @@ FvCheck (
//
// Check whether FvHeader is crossing the multi block range.
//
- if (HeaderSize > BlockMap->Length) {
+ if (Index >= BlockMap->NumBlocks) {
BlockMap++;
continue;
} else if (HeaderSize > 0) {
diff --git a/edk2/MdeModulePkg/Core/Dxe/FwVol/FwVolDriver.h b/edk2/MdeModulePkg/Core/Dxe/FwVol/FwVolDriver.h
index 7cc775f69..a614b93d1 100644
--- a/edk2/MdeModulePkg/Core/Dxe/FwVol/FwVolDriver.h
+++ b/edk2/MdeModulePkg/Core/Dxe/FwVol/FwVolDriver.h
@@ -366,22 +366,6 @@ SetFileState (
IN EFI_FFS_FILE_HEADER *FfsHeader
);
-
-/**
- Verify checksum of the firmware volume header.
-
- @param FvHeader Points to the firmware volume header to be checked
-
- @retval TRUE Checksum verification passed
- @retval FALSE Checksum verification failed
-
-**/
-BOOLEAN
-VerifyFvHeaderChecksum (
- IN EFI_FIRMWARE_VOLUME_HEADER *FvHeader
- );
-
-
/**
Check if it's a valid FFS file header.
diff --git a/edk2/MdeModulePkg/Core/Pei/Image/Image.c b/edk2/MdeModulePkg/Core/Pei/Image/Image.c
index 0906548ed..843e02014 100644
--- a/edk2/MdeModulePkg/Core/Pei/Image/Image.c
+++ b/edk2/MdeModulePkg/Core/Pei/Image/Image.c
@@ -1,7 +1,7 @@
/** @file
Pei Core Load Image Support
-Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -572,7 +572,7 @@ PeiLoadImageLoadImage (
if (AsciiString != NULL) {
for (Index = (INT32) AsciiStrLen (AsciiString) - 1; Index >= 0; Index --) {
- if (AsciiString[Index] == '\\') {
+ if (AsciiString[Index] == '\\' || AsciiString[Index] == '/') {
break;
}
}
diff --git a/edk2/MdeModulePkg/Include/Protocol/FormBrowserEx.h b/edk2/MdeModulePkg/Include/Protocol/FormBrowserEx.h
index a42039871..afeb7c0c0 100644
--- a/edk2/MdeModulePkg/Include/Protocol/FormBrowserEx.h
+++ b/edk2/MdeModulePkg/Include/Protocol/FormBrowserEx.h
@@ -22,7 +22,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
typedef struct _EFI_FORM_BROWSER_EXTENSION_PROTOCOL EFI_FORM_BROWSER_EXTENSION_PROTOCOL;
//
-// Return value of EXIT_REMINDER() that describes whether the changed data is saved or discarded.
+// Return value of SAVE_REMINDER() that describes whether the changed data is saved or discarded.
//
#define BROWSER_NO_CHANGES 0
#define BROWSER_SAVE_CHANGES 1
diff --git a/edk2/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.c b/edk2/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.c
index 51e6930a7..79cdf7e94 100644
--- a/edk2/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.c
+++ b/edk2/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.c
@@ -1,6 +1,6 @@
/** @file
-Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions
@@ -265,6 +265,7 @@ SaveLockBox (
CopyMem (&LockBox->Guid, Guid, sizeof(EFI_GUID));
LockBox->Buffer = (EFI_PHYSICAL_ADDRESS)(UINTN)Buffer;
LockBox->Length = (UINT64)Length;
+ LockBox->Attributes = 0;
LockBox->SmramBuffer = SmramBuffer;
LockBoxQueue = InternalGetLockBoxQueue ();
diff --git a/edk2/MdeModulePkg/MdeModulePkg.dec b/edk2/MdeModulePkg/MdeModulePkg.dec
index 4ccf8897e..b65e98841 100644
--- a/edk2/MdeModulePkg/MdeModulePkg.dec
+++ b/edk2/MdeModulePkg/MdeModulePkg.dec
@@ -20,7 +20,7 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = MdeModulePkg
PACKAGE_GUID = BA0D78D6-2CAF-414b-BD4D-B6762A894288
- PACKAGE_VERSION = 0.91
+ PACKAGE_VERSION = 0.92
[Includes]
Include
diff --git a/edk2/MdeModulePkg/MdeModulePkg.dsc b/edk2/MdeModulePkg/MdeModulePkg.dsc
index ac0e694dd..215600dab 100644
--- a/edk2/MdeModulePkg/MdeModulePkg.dsc
+++ b/edk2/MdeModulePkg/MdeModulePkg.dsc
@@ -16,7 +16,7 @@
[Defines]
PLATFORM_NAME = MdeModule
PLATFORM_GUID = 587CE499-6CBE-43cd-94E2-186218569478
- PLATFORM_VERSION = 0.91
+ PLATFORM_VERSION = 0.92
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/MdeModule
SUPPORTED_ARCHITECTURES = IA32|IPF|X64|EBC|ARM
diff --git a/edk2/MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableProtocol.c b/edk2/MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableProtocol.c
index b911a346c..6505de8be 100644
--- a/edk2/MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableProtocol.c
+++ b/edk2/MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableProtocol.c
@@ -317,8 +317,6 @@ InstallAcpiTable (
EFI_ACPI_TABLE_INSTANCE *AcpiTableInstance;
EFI_STATUS Status;
VOID *AcpiTableBufferConst;
- UINT32 Length;
- UINT8 Checksum;
//
// Check for invalid input parameters
@@ -328,16 +326,6 @@ InstallAcpiTable (
return EFI_INVALID_PARAMETER;
}
- Length = ((EFI_ACPI_COMMON_HEADER *) AcpiTableBuffer)->Length;
- Checksum = CalculateCheckSum8 ((UINT8 *)AcpiTableBuffer, Length);
- if (Checksum != 0) {
- AcpiPlatformChecksum (
- (VOID *)AcpiTableBuffer,
- (UINTN)Length,
- OFFSET_OF (EFI_ACPI_DESCRIPTION_HEADER, Checksum)
- );
- }
-
//
// Get the instance of the ACPI table protocol
//
@@ -351,7 +339,7 @@ InstallAcpiTable (
Status = SetAcpiTable (
AcpiTableInstance,
AcpiTableBufferConst,
- FALSE,
+ TRUE,
EFI_ACPI_TABLE_VERSION_1_0B | EFI_ACPI_TABLE_VERSION_2_0 | EFI_ACPI_TABLE_VERSION_3_0,
TableKey
);
diff --git a/edk2/MdeModulePkg/Universal/DevicePathDxe/DevicePathToText.c b/edk2/MdeModulePkg/Universal/DevicePathDxe/DevicePathToText.c
index 2cfd6730d..1f90f6420 100644
--- a/edk2/MdeModulePkg/Universal/DevicePathDxe/DevicePathToText.c
+++ b/edk2/MdeModulePkg/Universal/DevicePathDxe/DevicePathToText.c
@@ -690,7 +690,7 @@ DevPathToTextSasEx (
CatPrint (Str, L",0x%x,", SasEx->RelativeTargetPort);
if ((SasEx->DeviceTopology & 0x0f) == 0) {
- CatPrint (Str, L"NoTopology,0,0,0,");
+ CatPrint (Str, L"NoTopology,0,0,0");
} else if (((SasEx->DeviceTopology & 0x0f) == 1) || ((SasEx->DeviceTopology & 0x0f) == 2)) {
CatPrint (
Str,
@@ -700,12 +700,12 @@ DevPathToTextSasEx (
((SasEx->DeviceTopology & (0x1 << 6)) != 0) ? L"Expanded" : L"Direct"
);
if ((SasEx->DeviceTopology & 0x0f) == 1) {
- CatPrint (Str, L"0,");
+ CatPrint (Str, L"0");
} else {
- CatPrint (Str, L"0x%x,", (SasEx->DeviceTopology >> 8) & 0xff);
+ CatPrint (Str, L"0x%x", (SasEx->DeviceTopology >> 8) & 0xff);
}
} else {
- CatPrint (Str, L"0,0,0,0,");
+ CatPrint (Str, L"0,0,0,0");
}
CatPrint (Str, L")");
diff --git a/edk2/MdeModulePkg/Universal/DriverSampleDxe/DriverSample.c b/edk2/MdeModulePkg/Universal/DriverSampleDxe/DriverSample.c
index 4b44330ec..e7c1202ec 100644
--- a/edk2/MdeModulePkg/Universal/DriverSampleDxe/DriverSample.c
+++ b/edk2/MdeModulePkg/Universal/DriverSampleDxe/DriverSample.c
@@ -1667,50 +1667,6 @@ DriverCallback (
}
break;
- case 0x1237:
- //
- // User press "Exit now", request Browser to exit
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
- break;
-
- case 0x1238:
- //
- // User press "Save now", request Browser to save the uncommitted data.
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_SUBMIT;
- break;
-
- case 0x1241:
- case 0x1246:
- //
- // User press "Submit current form and Exit now", request Browser to submit current form and exit
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
- break;
-
- case 0x1242:
- //
- // User press "Discard current form now", request Browser to discard the uncommitted data.
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD;
- break;
-
- case 0x1243:
- //
- // User press "Submit current form now", request Browser to save the uncommitted data.
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
- break;
-
- case 0x1244:
- case 0x1245:
- //
- // User press "Discard current form and Exit now", request Browser to discard the uncommitted data and exit.
- //
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT;
- break;
-
case 0x2000:
//
// Only used to update the state.
@@ -1751,6 +1707,57 @@ DriverCallback (
}
break;
+ case EFI_BROWSER_ACTION_CHANGED:
+ switch (QuestionId) {
+ case 0x1237:
+ //
+ // User press "Exit now", request Browser to exit
+ //
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
+ break;
+
+ case 0x1238:
+ //
+ // User press "Save now", request Browser to save the uncommitted data.
+ //
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_SUBMIT;
+ break;
+
+ case 0x1241:
+ case 0x1246:
+ //
+ // User press "Submit current form and Exit now", request Browser to submit current form and exit
+ //
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
+ break;
+
+ case 0x1242:
+ //
+ // User press "Discard current form now", request Browser to discard the uncommitted data.
+ //
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD;
+ break;
+
+ case 0x1243:
+ //
+ // User press "Submit current form now", request Browser to save the uncommitted data.
+ //
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
+ break;
+
+ case 0x1244:
+ case 0x1245:
+ //
+ // User press "Discard current form and Exit now", request Browser to discard the uncommitted data and exit.
+ //
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT;
+ break;
+
+ default:
+ break;
+ }
+ break;
+
default:
Status = EFI_UNSUPPORTED;
break;
diff --git a/edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c b/edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c
index 81d9583bc..4fdb5adf2 100644
--- a/edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c
+++ b/edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c
@@ -676,20 +676,40 @@ IScsiFormCallback (
EFI_STATUS Status;
EFI_INPUT_KEY Key;
+ if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {
+ return EFI_UNSUPPORTED;
+ }
+
+ Private = ISCSI_FORM_CALLBACK_INFO_FROM_FORM_CALLBACK (This);
+ //
+ // Retrive uncommitted data from Browser
+ //
+ IfrNvData = AllocateZeroPool (sizeof (ISCSI_CONFIG_IFR_NVDATA));
+ ASSERT (IfrNvData != NULL);
+ if (!HiiGetBrowserData (&gIp4IScsiConfigGuid, mVendorStorageName, sizeof (ISCSI_CONFIG_IFR_NVDATA), (UINT8 *) IfrNvData)) {
+ FreePool (IfrNvData);
+ return EFI_NOT_FOUND;
+ }
+ Status = EFI_SUCCESS;
+
if (Action == EFI_BROWSER_ACTION_CHANGING) {
- Private = ISCSI_FORM_CALLBACK_INFO_FROM_FORM_CALLBACK (This);
- //
- // Retrive uncommitted data from Browser
- //
- IfrNvData = AllocateZeroPool (sizeof (ISCSI_CONFIG_IFR_NVDATA));
- ASSERT (IfrNvData != NULL);
- if (!HiiGetBrowserData (&gIp4IScsiConfigGuid, mVendorStorageName, sizeof (ISCSI_CONFIG_IFR_NVDATA), (UINT8 *) IfrNvData)) {
- FreePool (IfrNvData);
- return EFI_NOT_FOUND;
- }
- Status = EFI_SUCCESS;
+ if ((QuestionId >= KEY_DEVICE_ENTRY_BASE) && (QuestionId < (mNumberOfIScsiDevices + KEY_DEVICE_ENTRY_BASE))) {
+ //
+ // In case goto the device configuration form, update the device form title.
+ //
+ ConfigFormEntry = IScsiGetConfigFormEntryByIndex ((UINT32) (QuestionId - KEY_DEVICE_ENTRY_BASE));
+ ASSERT (ConfigFormEntry != NULL);
+
+ UnicodeSPrint (PortString, (UINTN) 128, L"Port %s", ConfigFormEntry->MacString);
+ DeviceFormTitleToken = (EFI_STRING_ID) STR_ISCSI_DEVICE_FORM_TITLE;
+ HiiSetString (Private->RegisteredHandle, DeviceFormTitleToken, PortString, NULL);
- switch (QuestionId) {
+ IScsiConvertDeviceConfigDataToIfrNvData (ConfigFormEntry, IfrNvData);
+
+ Private->Current = ConfigFormEntry;
+ }
+ } else if (Action == EFI_BROWSER_ACTION_CHANGED) {
+ switch (QuestionId) {
case KEY_INITIATOR_NAME:
IScsiUnicodeStrToAsciiStr (IfrNvData->InitiatorName, IScsiName);
BufferSize = AsciiStrSize (IScsiName);
@@ -889,41 +909,20 @@ IScsiFormCallback (
break;
default:
- if ((QuestionId >= KEY_DEVICE_ENTRY_BASE) && (QuestionId < (mNumberOfIScsiDevices + KEY_DEVICE_ENTRY_BASE))) {
- //
- // In case goto the device configuration form, update the device form title.
- //
- ConfigFormEntry = IScsiGetConfigFormEntryByIndex ((UINT32) (QuestionId - KEY_DEVICE_ENTRY_BASE));
- ASSERT (ConfigFormEntry != NULL);
-
- UnicodeSPrint (PortString, (UINTN) 128, L"Port %s", ConfigFormEntry->MacString);
- DeviceFormTitleToken = (EFI_STRING_ID) STR_ISCSI_DEVICE_FORM_TITLE;
- HiiSetString (Private->RegisteredHandle, DeviceFormTitleToken, PortString, NULL);
-
- IScsiConvertDeviceConfigDataToIfrNvData (ConfigFormEntry, IfrNvData);
-
- Private->Current = ConfigFormEntry;
- }
-
break;
}
-
- if (!EFI_ERROR (Status)) {
- //
- // Pass changed uncommitted data back to Form Browser
- //
- HiiSetBrowserData (&gIp4IScsiConfigGuid, mVendorStorageName, sizeof (ISCSI_CONFIG_IFR_NVDATA), (UINT8 *) IfrNvData, NULL);
- }
-
- FreePool (IfrNvData);
-
- return Status;
}
- //
- // All other action return unsupported.
- //
- return EFI_UNSUPPORTED;
+ if (!EFI_ERROR (Status)) {
+ //
+ // Pass changed uncommitted data back to Form Browser
+ //
+ HiiSetBrowserData (&gIp4IScsiConfigGuid, mVendorStorageName, sizeof (ISCSI_CONFIG_IFR_NVDATA), (UINT8 *) IfrNvData, NULL);
+ }
+
+ FreePool (IfrNvData);
+
+ return Status;
}
/**
diff --git a/edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxe.vfr b/edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxe.vfr
index 82364a8b4..719353de2 100644
--- a/edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxe.vfr
+++ b/edk2/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxe.vfr
@@ -204,12 +204,13 @@ formset
subtitle text = STRING_TOKEN(STR_NULL);
- goto FORMID_DEVICE_FORM,
- prompt = STRING_TOKEN (STR_SAVE_CHANGES),
- help = STRING_TOKEN (STR_SAVE_CHANGES),
- flags = INTERACTIVE,
- key = KEY_SAVE_CHANGES;
-
+ text
+ help = STRING_TOKEN (STR_SAVE_CHANGES),
+ text = STRING_TOKEN (STR_SAVE_CHANGES),
+ text = STRING_TOKEN (STR_SAVE_CHANGES),
+ flags = INTERACTIVE,
+ key = KEY_SAVE_CHANGES;
+
goto FORMID_MAIN_FORM,
prompt = STRING_TOKEN (STR_RETURN_MAIN_FORM),
help = STRING_TOKEN (STR_RETURN_MAIN_FORM),
diff --git a/edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.vfr b/edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.vfr
index 5b5685db4..c5d74b06d 100644
--- a/edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.vfr
+++ b/edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.vfr
@@ -78,13 +78,14 @@ formset
endif;
subtitle text = STRING_TOKEN(STR_NULL);
-
- goto FORMID_DEVICE_FORM,
- prompt = STRING_TOKEN (STR_SAVE_CHANGES),
- help = STRING_TOKEN (STR_SAVE_CHANGES),
- flags = INTERACTIVE,
- key = KEY_SAVE_CHANGES;
-
+
+ text
+ help = STRING_TOKEN(STR_SAVE_CHANGES),
+ text = STRING_TOKEN(STR_SAVE_CHANGES),
+ text = STRING_TOKEN(STR_SAVE_CHANGES),
+ flags = INTERACTIVE,
+ key = KEY_SAVE_CHANGES;
+
endform;
endformset;
diff --git a/edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigNv.c b/edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigNv.c
index 59e5127b4..58c4c1a02 100644
--- a/edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigNv.c
+++ b/edk2/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigNv.c
@@ -689,7 +689,7 @@ Ip4FormCallback (
EFI_STATUS Status;
EFI_INPUT_KEY Key;
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
Ip4ConfigInstance = IP4_CONFIG_INSTANCE_FROM_CONFIG_ACCESS (This);
IfrFormNvData = AllocateZeroPool (sizeof (IP4_CONFIG_IFR_NVDATA));
diff --git a/edk2/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c b/edk2/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c
index 6f6d7f92a..511e06487 100644
--- a/edk2/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c
+++ b/edk2/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c
@@ -727,7 +727,7 @@ ON_EXIT:
}
}
- Status = Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
+ Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
//
// Dhcp(), Discover(), and Mtftp() set the IP filter, and return with the IP
@@ -1024,7 +1024,7 @@ EfiPxeBcDiscover (
} else {
Status = EFI_DEVICE_ERROR;
}
- return Status;
+ goto ON_EXIT;
} else {
PxeBcParseCachedDhcpPacket (&Private->PxeReply);
}
@@ -1043,7 +1043,7 @@ EfiPxeBcDiscover (
ON_EXIT:
- Status = Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
+ Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
//
// Dhcp(), Discover(), and Mtftp() set the IP filter, and return with the IP
@@ -1280,10 +1280,11 @@ EfiPxeBcMtftp (
}
if (EFI_ERROR (Status)) {
- return Status;
+ goto ON_EXIT;
}
- Status = Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
+ON_EXIT:
+ Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
//
// Dhcp(), Discover(), and Mtftp() set the IP filter, and return with the IP
// receive filter list emptied and the filter set to EFI_PXE_BASE_CODE_IP_FILTER_STATION_IP.
diff --git a/edk2/MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigImpl.c b/edk2/MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigImpl.c
index ea70d5e28..f992cea07 100644
--- a/edk2/MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigImpl.c
+++ b/edk2/MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigImpl.c
@@ -239,16 +239,23 @@ VlanCallback (
return EFI_SUCCESS;
}
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if ((Action != EFI_BROWSER_ACTION_CHANGED) && (Action != EFI_BROWSER_ACTION_CHANGING)) {
//
- // Get Browser data
+ // All other action return unsupported.
//
- Configuration = AllocateZeroPool (sizeof (VLAN_CONFIGURATION));
- ASSERT (Configuration != NULL);
- HiiGetBrowserData (&gVlanConfigFormSetGuid, mVlanStorageName, sizeof (VLAN_CONFIGURATION), (UINT8 *) Configuration);
+ return EFI_UNSUPPORTED;
+ }
+
+ //
+ // Get Browser data
+ //
+ Configuration = AllocateZeroPool (sizeof (VLAN_CONFIGURATION));
+ ASSERT (Configuration != NULL);
+ HiiGetBrowserData (&gVlanConfigFormSetGuid, mVlanStorageName, sizeof (VLAN_CONFIGURATION), (UINT8 *) Configuration);
- VlanConfig = PrivateData->VlanConfig;
+ VlanConfig = PrivateData->VlanConfig;
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
switch (QuestionId) {
case VLAN_ADD_QUESTION_ID:
//
@@ -304,6 +311,11 @@ VlanCallback (
ZeroMem (Configuration->VlanList, MAX_VLAN_NUMBER);
break;
+ default:
+ break;
+ }
+ } else if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ switch (QuestionId) {
case VLAN_UPDATE_QUESTION_ID:
//
// Update current VLAN list into Form.
@@ -314,16 +326,11 @@ VlanCallback (
default:
break;
}
-
- HiiSetBrowserData (&gVlanConfigFormSetGuid, mVlanStorageName, sizeof (VLAN_CONFIGURATION), (UINT8 *) Configuration, NULL);
- FreePool (Configuration);
- return EFI_SUCCESS;
}
-
- //
- // All other action return unsupported.
- //
- return EFI_UNSUPPORTED;
+
+ HiiSetBrowserData (&gVlanConfigFormSetGuid, mVlanStorageName, sizeof (VLAN_CONFIGURATION), (UINT8 *) Configuration, NULL);
+ FreePool (Configuration);
+ return EFI_SUCCESS;
}
diff --git a/edk2/MdeModulePkg/Universal/PCD/Dxe/Service.c b/edk2/MdeModulePkg/Universal/PCD/Dxe/Service.c
index bf8e74dfb..8bfd199e4 100644
--- a/edk2/MdeModulePkg/Universal/PCD/Dxe/Service.c
+++ b/edk2/MdeModulePkg/Universal/PCD/Dxe/Service.c
@@ -746,6 +746,7 @@ SetWorker (
//
GetPtrTypeSize (TokenNumber, &MaxSize);
if (*Size > MaxSize) {
+ *Size = MaxSize;
return EFI_INVALID_PARAMETER;
}
} else {
diff --git a/edk2/MdeModulePkg/Universal/PCD/Pei/Service.c b/edk2/MdeModulePkg/Universal/PCD/Pei/Service.c
index 4e7366e75..4769600da 100644
--- a/edk2/MdeModulePkg/Universal/PCD/Pei/Service.c
+++ b/edk2/MdeModulePkg/Universal/PCD/Pei/Service.c
@@ -391,6 +391,7 @@ SetWorker (
//
GetPtrTypeSize (TokenNumber, &MaxSize, PeiPcdDb);
if (*Size > MaxSize) {
+ *Size = MaxSize;
return EFI_INVALID_PARAMETER;
}
} else {
diff --git a/edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/PlatDriOverrideDxe.c b/edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/PlatDriOverrideDxe.c
index 20bc43c34..ab8a000f1 100644
--- a/edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/PlatDriOverrideDxe.c
+++ b/edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/PlatDriOverrideDxe.c
@@ -1334,17 +1334,25 @@ PlatOverMngrCallback (
EFI_INPUT_KEY Key;
PLAT_OVER_MNGR_DATA *FakeNvData;
+ if ((Action != EFI_BROWSER_ACTION_CHANGING) && (Action != EFI_BROWSER_ACTION_CHANGED)) {
+ //
+ // All other action return unsupported.
+ //
+ return EFI_UNSUPPORTED;
+ }
+
+ Private = EFI_CALLBACK_INFO_FROM_THIS (This);
+ FakeNvData = &Private->FakeNvData;
+ if (!HiiGetBrowserData (&gPlatformOverridesManagerGuid, mVariableName, sizeof (PLAT_OVER_MNGR_DATA), (UINT8 *) FakeNvData)) {
+ return EFI_NOT_FOUND;
+ }
+
if (Action == EFI_BROWSER_ACTION_CHANGING) {
- Private = EFI_CALLBACK_INFO_FROM_THIS (This);
- FakeNvData = &Private->FakeNvData;
- if (!HiiGetBrowserData (&gPlatformOverridesManagerGuid, mVariableName, sizeof (PLAT_OVER_MNGR_DATA), (UINT8 *) FakeNvData)) {
- return EFI_NOT_FOUND;
+ if (Value == NULL) {
+ return EFI_INVALID_PARAMETER;
}
-
- if (KeyValue == KEY_VALUE_DEVICE_REFRESH ||
- KeyValue == KEY_VALUE_DEVICE_FILTER ||
- KeyValue == KEY_VALUE_DRIVER_GOTO_PREVIOUS
- ) {
+
+ if (KeyValue == KEY_VALUE_DRIVER_GOTO_PREVIOUS) {
UpdateDeviceSelectPage (Private, KeyValue, FakeNvData);
//
// Update page title string
@@ -1380,15 +1388,6 @@ PlatOverMngrCallback (
}
}
- if (KeyValue == KEY_VALUE_ORDER_SAVE_AND_EXIT) {
- Status = CommintChanges (Private, KeyValue, FakeNvData);
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_SUBMIT;
- if (EFI_ERROR (Status)) {
- CreatePopUp (EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE, &Key, L"Single Override Info too large, Saving Error!", NULL);
- return EFI_DEVICE_ERROR;
- }
- }
-
if (KeyValue == KEY_VALUE_DEVICE_CLEAR) {
//
// Deletes all environment variable(s) that contain the override mappings info
@@ -1397,18 +1396,40 @@ PlatOverMngrCallback (
Status = SaveOverridesMapping (&mMappingDataBase);
UpdateDeviceSelectPage (Private, KeyValue, FakeNvData);
}
- //
- // Pass changed uncommitted data back to Form Browser
- //
- HiiSetBrowserData (&gPlatformOverridesManagerGuid, mVariableName, sizeof (PLAT_OVER_MNGR_DATA), (UINT8 *) FakeNvData, NULL);
+ } else if (Action == EFI_BROWSER_ACTION_CHANGED) {
+ switch (KeyValue) {
+ case KEY_VALUE_DEVICE_REFRESH:
+ case KEY_VALUE_DEVICE_FILTER:
+ UpdateDeviceSelectPage (Private, KeyValue, FakeNvData);
+ //
+ // Update page title string
+ //
+ NewStringToken = STRING_TOKEN (STR_TITLE);
+ if (HiiSetString (Private->RegisteredHandle, NewStringToken, L"First, Select the controller by device path", NULL) == 0) {
+ ASSERT (FALSE);
+ }
+ break;
+
+ case KEY_VALUE_ORDER_SAVE_AND_EXIT:
+ Status = CommintChanges (Private, KeyValue, FakeNvData);
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_SUBMIT;
+ if (EFI_ERROR (Status)) {
+ CreatePopUp (EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE, &Key, L"Single Override Info too large, Saving Error!", NULL);
+ return EFI_DEVICE_ERROR;
+ }
+ break;
- return EFI_SUCCESS;
- }
+ default:
+ break;
+ }
+ }
//
- // All other action return unsupported.
+ // Pass changed uncommitted data back to Form Browser
//
- return EFI_UNSUPPORTED;
+ HiiSetBrowserData (&gPlatformOverridesManagerGuid, mVariableName, sizeof (PLAT_OVER_MNGR_DATA), (UINT8 *) FakeNvData, NULL);
+
+ return EFI_SUCCESS;
}
/**
diff --git a/edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/Vfr.vfr b/edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/Vfr.vfr
index 0f5064594..a4eede18d 100644
--- a/edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/Vfr.vfr
+++ b/edk2/MdeModulePkg/Universal/PlatformDriOverrideDxe/Vfr.vfr
@@ -99,11 +99,12 @@ formset
subtitle text = STRING_TOKEN(STR_NULL_STRING);
- goto FORM_ID_ORDER,
- prompt = STRING_TOKEN(STR_SAVE_AND_EXIT),
- help = STRING_TOKEN(STR_NULL_STRING),
- flags = INTERACTIVE | RESET_REQUIRED,
- key = KEY_VALUE_ORDER_SAVE_AND_EXIT;
+ text
+ help = STRING_TOKEN (STR_NULL_STRING),
+ text = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ flags = INTERACTIVE | RESET_REQUIRED,
+ key = KEY_VALUE_ORDER_SAVE_AND_EXIT;
endform;
endformset;
diff --git a/edk2/MdeModulePkg/Universal/SetupBrowserDxe/Expression.c b/edk2/MdeModulePkg/Universal/SetupBrowserDxe/Expression.c
index b6028cb31..1420f9182 100644
--- a/edk2/MdeModulePkg/Universal/SetupBrowserDxe/Expression.c
+++ b/edk2/MdeModulePkg/Universal/SetupBrowserDxe/Expression.c
@@ -1,7 +1,7 @@
/** @file
Utility functions for expression evaluation.
-Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2007 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -1909,7 +1909,7 @@ EvaluateExpression (
Value->Value.b = (BOOLEAN) ((Result == 0) ? TRUE : FALSE);
break;
- case EFI_IFR_EQ_ID_LIST_OP:
+ case EFI_IFR_EQ_ID_VAL_LIST_OP:
Question = IdToQuestion (FormSet, Form, OpCode->QuestionId);
if (Question == NULL) {
Status = EFI_NOT_FOUND;
diff --git a/edk2/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c b/edk2/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c
index 8e55b9970..a2befcb66 100644
--- a/edk2/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c
+++ b/edk2/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c
@@ -1,7 +1,7 @@
/** @file
Parser for IFR binary encoding.
-Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2007 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -1063,7 +1063,7 @@ ParseOpCodes (
CopyMem (&ExpressionOpCode->QuestionId2, &((EFI_IFR_EQ_ID_ID *) OpCodeData)->QuestionId2, sizeof (EFI_QUESTION_ID));
break;
- case EFI_IFR_EQ_ID_LIST_OP:
+ case EFI_IFR_EQ_ID_VAL_LIST_OP:
CopyMem (&ExpressionOpCode->QuestionId, &((EFI_IFR_EQ_ID_VAL_LIST *) OpCodeData)->QuestionId, sizeof (EFI_QUESTION_ID));
CopyMem (&ExpressionOpCode->ListLength, &((EFI_IFR_EQ_ID_VAL_LIST *) OpCodeData)->ListLength, sizeof (UINT16));
ExpressionOpCode->ValueList = AllocateCopyPool (ExpressionOpCode->ListLength * sizeof (UINT16), &((EFI_IFR_EQ_ID_VAL_LIST *) OpCodeData)->ValueList);
diff --git a/edk2/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c b/edk2/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c
index ba39f3025..2ba216597 100644
--- a/edk2/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c
+++ b/edk2/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c
@@ -1248,45 +1248,50 @@ ProcessCallBackFunction (
&ActionRequest
);
if (!EFI_ERROR (Status)) {
- switch (ActionRequest) {
- case EFI_BROWSER_ACTION_REQUEST_RESET:
- gResetRequired = TRUE;
- Selection->Action = UI_ACTION_EXIT;
- break;
+ //
+ // Only for EFI_BROWSER_ACTION_CHANGED need to handle this ActionRequest.
+ //
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
+ switch (ActionRequest) {
+ case EFI_BROWSER_ACTION_REQUEST_RESET:
+ gResetRequired = TRUE;
+ Selection->Action = UI_ACTION_EXIT;
+ break;
- case EFI_BROWSER_ACTION_REQUEST_SUBMIT:
- SubmitFormIsRequired = TRUE;
- Selection->Action = UI_ACTION_EXIT;
- break;
+ case EFI_BROWSER_ACTION_REQUEST_SUBMIT:
+ SubmitFormIsRequired = TRUE;
+ Selection->Action = UI_ACTION_EXIT;
+ break;
- case EFI_BROWSER_ACTION_REQUEST_EXIT:
- Selection->Action = UI_ACTION_EXIT;
- break;
+ case EFI_BROWSER_ACTION_REQUEST_EXIT:
+ Selection->Action = UI_ACTION_EXIT;
+ break;
- case EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT:
- SubmitFormIsRequired = TRUE;
- SettingLevel = FormLevel;
- NeedExit = TRUE;
- break;
+ case EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT:
+ SubmitFormIsRequired = TRUE;
+ SettingLevel = FormLevel;
+ NeedExit = TRUE;
+ break;
- case EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT:
- DiscardFormIsRequired = TRUE;
- SettingLevel = FormLevel;
- NeedExit = TRUE;
- break;
+ case EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT:
+ DiscardFormIsRequired = TRUE;
+ SettingLevel = FormLevel;
+ NeedExit = TRUE;
+ break;
- case EFI_BROWSER_ACTION_REQUEST_FORM_APPLY:
- SubmitFormIsRequired = TRUE;
- SettingLevel = FormLevel;
- break;
+ case EFI_BROWSER_ACTION_REQUEST_FORM_APPLY:
+ SubmitFormIsRequired = TRUE;
+ SettingLevel = FormLevel;
+ break;
- case EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD:
- DiscardFormIsRequired = TRUE;
- SettingLevel = FormLevel;
- break;
+ case EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD:
+ DiscardFormIsRequired = TRUE;
+ SettingLevel = FormLevel;
+ break;
- default:
- break;
+ default:
+ break;
+ }
}
//
@@ -1555,7 +1560,7 @@ SetupBrowser (
}
}
- if ((Status == EFI_SUCCESS) && (Statement->Operand != EFI_IFR_REF_OP)) {
+ if (!EFI_ERROR (Status) && Statement->Operand != EFI_IFR_REF_OP) {
ProcessCallBackFunction(Selection, Statement, EFI_BROWSER_ACTION_CHANGED, FALSE);
}
}
diff --git a/edk2/MdePkg/Include/IndustryStandard/SmBios.h b/edk2/MdePkg/Include/IndustryStandard/SmBios.h
index 694ee3361..c74e18a7f 100644
--- a/edk2/MdePkg/Include/IndustryStandard/SmBios.h
+++ b/edk2/MdePkg/Include/IndustryStandard/SmBios.h
@@ -135,7 +135,7 @@ typedef struct {
UINT8 AcpiIsSupported :1;
UINT8 UsbLegacyIsSupported :1;
UINT8 AgpIsSupported :1;
- UINT8 I20BootIsSupported :1;
+ UINT8 I2OBootIsSupported :1;
UINT8 Ls120BootIsSupported :1;
UINT8 AtapiZipDriveBootIsSupported :1;
UINT8 Boot1394IsSupported :1;
@@ -400,10 +400,8 @@ typedef enum {
ProcessorFamilyPentiumIII = 0x11,
ProcessorFamilyM1 = 0x12,
ProcessorFamilyM2 = 0x13,
- ProcessorFamilyM1Reserved2 = 0x14,
- ProcessorFamilyM1Reserved3 = 0x15,
- ProcessorFamilyM1Reserved4 = 0x16,
- ProcessorFamilyM1Reserved5 = 0x17,
+ ProcessorFamilyIntelCeleronM = 0x14,
+ ProcessorFamilyIntelPentium4Ht = 0x15,
ProcessorFamilyAmdDuron = 0x18,
ProcessorFamilyK5 = 0x19,
ProcessorFamilyK6 = 0x1A,
@@ -857,8 +855,8 @@ typedef struct {
UINT16 NonBurst :1;
UINT16 Burst :1;
UINT16 PipelineBurst :1;
- UINT16 Asynchronous :1;
UINT16 Synchronous :1;
+ UINT16 Asynchronous :1;
UINT16 Reserved :9;
} CACHE_SRAM_TYPE_DATA;
@@ -945,7 +943,7 @@ typedef enum {
PortConnectorTypeRJ45 = 0x0B,
PortConnectorType50PinMiniScsi = 0x0C,
PortConnectorTypeMiniDin = 0x0D,
- PortConnectorTypeMicriDin = 0x0E,
+ PortConnectorTypeMicroDin = 0x0E,
PortConnectorTypePS2 = 0x0F,
PortConnectorTypeInfrared = 0x10,
PortConnectorTypeHpHil = 0x11,
@@ -965,6 +963,7 @@ typedef enum {
PortConnectorTypeHeadPhoneMiniJack = 0x1F,
PortConnectorTypeBNC = 0x20,
PortConnectorType1394 = 0x21,
+ PortConnectorTypeSasSata = 0x22,
PortConnectorTypePC98 = 0xA0,
PortConnectorTypePC98Hireso = 0xA1,
PortConnectorTypePCH98 = 0xA2,
@@ -1176,7 +1175,10 @@ typedef enum {
OnBoardDeviceTypeScsiController = 0x04,
OnBoardDeviceTypeEthernet = 0x05,
OnBoardDeviceTypeTokenRing = 0x06,
- OnBoardDeviceTypeSound = 0x07
+ OnBoardDeviceTypeSound = 0x07,
+ OnBoardDeviceTypePATAController = 0x08,
+ OnBoardDeviceTypeSATAController = 0x09,
+ OnBoardDeviceTypeSASController = 0x0A
} MISC_ONBOARD_DEVICE_TYPE;
///
@@ -1238,6 +1240,27 @@ typedef struct {
} SMBIOS_TABLE_TYPE13;
///
+/// Group Item Entry
+///
+typedef struct {
+ UINT8 ItemType;
+ UINT16 ItemHandle;
+} GROUP_STRUCT;
+
+///
+/// Group Associations (Type 14).
+///
+/// The Group Associations structure is provided for OEMs who want to specify
+/// the arrangement or hierarchy of certain components (including other Group Associations)
+/// within the system.
+///
+typedef struct {
+ SMBIOS_STRUCTURE Hdr;
+ SMBIOS_TABLE_STRING GroupName;
+ GROUP_STRUCT Group[1];
+} SMBIOS_TABLE_TYPE14;
+
+///
/// System Event Log - Event Log Types.
///
typedef enum {
@@ -1285,14 +1308,6 @@ typedef enum {
} EVENT_LOG_VARIABLE_DATA;
///
-/// Group Item Entry
-///
-typedef struct {
- UINT8 ItemType;
- UINT16 ItemHandle;
-} GROUP_STRUCT;
-
-///
/// Event Log Type Descriptors
///
typedef struct {
@@ -1301,19 +1316,6 @@ typedef struct {
} EVENT_LOG_TYPE;
///
-/// Group Associations (Type 14).
-///
-/// The Group Associations structure is provided for OEMs who want to specify
-/// the arrangement or hierarchy of certain components (including other Group Associations)
-/// within the system.
-///
-typedef struct {
- SMBIOS_STRUCTURE Hdr;
- SMBIOS_TABLE_STRING GroupName;
- GROUP_STRUCT Group[1];
-} SMBIOS_TABLE_TYPE14;
-
-///
/// System Event Log (Type 15).
///
/// The presence of this structure within the SMBIOS data returned for a system indicates
diff --git a/edk2/MdePkg/Include/Library/DebugLib.h b/edk2/MdePkg/Include/Library/DebugLib.h
index 7bb964faa..f969ce231 100644
--- a/edk2/MdePkg/Include/Library/DebugLib.h
+++ b/edk2/MdePkg/Include/Library/DebugLib.h
@@ -8,7 +8,7 @@
of size reduction when compiler optimization is disabled. If MDEPKG_NDEBUG is
defined, then debug and assert related macros wrapped by it are the NULL implementations.
-Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available under
the terms and conditions of the BSD License that accompanies this distribution.
The full text of the license may be found at
@@ -41,7 +41,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#define DEBUG_FS 0x00000008 // EFI File system
#define DEBUG_POOL 0x00000010 // Alloc & Free's
#define DEBUG_PAGE 0x00000020 // Alloc & Free's
-#define DEBUG_INFO 0x00000040 // Verbose
+#define DEBUG_INFO 0x00000040 // Informational debug messages
#define DEBUG_DISPATCH 0x00000080 // PEI/DXE/SMM Dispatchers
#define DEBUG_VARIABLE 0x00000100 // Variable
#define DEBUG_BM 0x00000400 // Boot Manager
@@ -52,6 +52,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#define DEBUG_EVENT 0x00080000 // Event messages
#define DEBUG_GCD 0x00100000 // Global Coherency Database changes
#define DEBUG_CACHE 0x00200000 // Memory range cachability changes
+#define DEBUG_VERBOSE 0x00400000 // Detailed debug messages that may significantly impact boot performance
#define DEBUG_ERROR 0x80000000 // Error
//
@@ -72,6 +73,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#define EFI_D_UNDI DEBUG_UNDI
#define EFI_D_LOADFILE DEBUG_LOADFILE
#define EFI_D_EVENT DEBUG_EVENT
+#define EFI_D_VERBOSE DEBUG_VERBOSE
#define EFI_D_ERROR DEBUG_ERROR
/**
diff --git a/edk2/MdePkg/Include/Pi/PiDxeCis.h b/edk2/MdePkg/Include/Pi/PiDxeCis.h
index 17543fa72..caed14bd8 100644
--- a/edk2/MdePkg/Include/Pi/PiDxeCis.h
+++ b/edk2/MdePkg/Include/Pi/PiDxeCis.h
@@ -369,7 +369,8 @@ EFI_STATUS
BaseAddress and Length cannot be modified.
@retval EFI_OUT_OF_RESOURCES There are not enough system resources to modify the attributes of
the memory resource range.
-
+ @retval EFI_NOT_AVAILABLE_YET The attributes cannot be set because CPU architectural protocol is
+ not available yet.
**/
typedef
EFI_STATUS
diff --git a/edk2/MdePkg/Include/Uefi/UefiInternalFormRepresentation.h b/edk2/MdePkg/Include/Uefi/UefiInternalFormRepresentation.h
index 8c026de2d..d01a7dcad 100644
--- a/edk2/MdePkg/Include/Uefi/UefiInternalFormRepresentation.h
+++ b/edk2/MdePkg/Include/Uefi/UefiInternalFormRepresentation.h
@@ -3,7 +3,7 @@
IFR is primarily consumed by the EFI presentation engine, and produced by EFI
internal application and drivers as well as all add-in card option-ROM drivers
-Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available under
the terms and conditions of the BSD License that accompanies this distribution.
The full text of the license may be found at
@@ -700,7 +700,7 @@ typedef union {
#define EFI_IFR_INCONSISTENT_IF_OP 0x11
#define EFI_IFR_EQ_ID_VAL_OP 0x12
#define EFI_IFR_EQ_ID_ID_OP 0x13
-#define EFI_IFR_EQ_ID_LIST_OP 0x14
+#define EFI_IFR_EQ_ID_VAL_LIST_OP 0x14
#define EFI_IFR_AND_OP 0x15
#define EFI_IFR_OR_OP 0x16
#define EFI_IFR_NOT_OP 0x17
diff --git a/edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.S b/edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.S
index df205e9a1..0555cf1bf 100644
--- a/edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.S
+++ b/edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -55,7 +55,8 @@ ASM_PFX(ThunkAttr): .space 4
orb $2, %al
outb %al, $0x92 # deactivate A20M#
2:
- movw %ss, %ax
+ xorw %ax, %ax # xor eax, eax
+ movl %ss, %eax # mov ax, ss
.byte 0x67, 0x66, 0x8d, 0x6c, 0x24, 0x34, 0x66
mov %ebp, 0xffffffd8(%esi)
mov 0xfffffff8(%esi), %ebx
@@ -160,14 +161,14 @@ ASM_PFX(InternalAsmThunk16):
movsl # copy RegSet
movl 40(%esp), %eax # eax <- address of transition code
movl %edx, %esi # esi <- 16-bit stack segment
- lea 0x5f(%eax), %edx
+ lea 0x61(%eax), %edx
movl %eax, %ecx
andl $0xf, %ecx
shll $12, %eax
lea 0x6(%ecx), %ecx
movw %cx, %ax
stosl # [edi] <- return address of user code
- sgdtl 0xffffffa1(%edx)
+ sgdtl 0xffffff9f(%edx)
sidtl 0x24(%esp)
movl %cr0, %eax
movl %eax, (%edx) # save CR0 in SavedCr0
diff --git a/edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.asm b/edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.asm
index 31f9254ad..6df0a4a46 100644
--- a/edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.asm
+++ b/edk2/MdePkg/Library/BaseLib/Ia32/Thunk16.asm
@@ -3,7 +3,7 @@
;------------------------------------------------------------------------------
;
-; Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+; Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
; This program and the accompanying materials
; are licensed and made available under the terms and conditions of the BSD License
; which accompanies this distribution. The full text of the license may be found at
@@ -109,7 +109,8 @@ _ThunkAttr DD ?
or al, 2
out 92h, al ; deactivate A20M#
@2:
- mov ax, ss
+ xor ax, ax ; xor eax, eax
+ mov eax, ss ; mov ax, ss
DB 67h
lea bp, [esp + sizeof (IA32_REGS)]
;
diff --git a/edk2/MdePkg/Library/BaseLib/X64/Thunk16.S b/edk2/MdePkg/Library/BaseLib/X64/Thunk16.S
index 4c3c5605f..d037a7104 100644
--- a/edk2/MdePkg/Library/BaseLib/X64/Thunk16.S
+++ b/edk2/MdePkg/Library/BaseLib/X64/Thunk16.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -109,7 +109,8 @@ L_1:
orb $2,%al
outb %al, $0x92 # deactivate A20M#
L_2:
- movw %ss,%ax
+ xorw %ax, %ax # xor eax, eax
+ movl %ss, %eax # mov ax, ss
lea IA32_REGS_SIZE(%esp), %bp
#
# rsi in the following 2 instructions is indeed bp in 16-bit code
diff --git a/edk2/MdePkg/Library/BaseLib/X64/Thunk16.asm b/edk2/MdePkg/Library/BaseLib/X64/Thunk16.asm
index 829df1c2a..8b208fdb5 100644
--- a/edk2/MdePkg/Library/BaseLib/X64/Thunk16.asm
+++ b/edk2/MdePkg/Library/BaseLib/X64/Thunk16.asm
@@ -3,7 +3,7 @@
;------------------------------------------------------------------------------
;
-; Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+; Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
; This program and the accompanying materials
; are licensed and made available under the terms and conditions of the BSD License
; which accompanies this distribution. The full text of the license may be found at
@@ -105,7 +105,8 @@ _ThunkAttr DD ?
or al, 2
out 92h, al ; deactivate A20M#
@2:
- mov ax, ss
+ xor ax, ax ; xor eax, eax
+ mov eax, ss ; mov ax, ss
lea bp, [esp + sizeof (IA32_REGS)]
;
; rsi in the following 2 instructions is indeed bp in 16-bit code
diff --git a/edk2/MdePkg/MdePkg.dec b/edk2/MdePkg/MdePkg.dec
index 17b7d423a..70553fe81 100644
--- a/edk2/MdePkg/MdePkg.dec
+++ b/edk2/MdePkg/MdePkg.dec
@@ -3,9 +3,9 @@
# This Package provides all definitions(including functions, MACROs, structures and library classes)
# and libraries instances, which are defined in MDE Specification.
# It also provides the definitions(including PPIs/PROTOCOLs/GUIDs) of
-# EFI1.10/UEFI2.3/PI1.2 and some Industry Standards.
+# EFI1.10/UEFI2.3.1/PI1.2 and some Industry Standards.
#
-# Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2007 - 2012, Intel Corporation. All rights reserved.<BR>
# Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
#
# This program and the accompanying materials are licensed and made available under
@@ -216,6 +216,9 @@
# operatation to be replayed during an S3 resume. This
# library class maps directly on top of the Timer class.
S3StallLib|Include/Library/S3StallLib.h
+
+ ## @libraryclass Defines library APIs used by modules to get/set print error level.
+ DebugPrintErrorLevelLib|Include/Library/DebugPrintErrorLevelLib.h
[LibraryClasses.IA32, LibraryClasses.X64]
## @libraryclass Abstracts both S/W SMI generation and detection.
diff --git a/edk2/NetworkPkg/IScsiDxe/IScsiConfig.c b/edk2/NetworkPkg/IScsiDxe/IScsiConfig.c
index d347d8dc7..eea73a8ff 100644
--- a/edk2/NetworkPkg/IScsiDxe/IScsiConfig.c
+++ b/edk2/NetworkPkg/IScsiDxe/IScsiConfig.c
@@ -1606,14 +1606,6 @@ IScsiConfigProcessDefault (
UINTN Index;
//
- // Free any attempt that is previously created but not saved to system.
- //
- if (mPrivate->NewAttempt != NULL) {
- FreePool (mPrivate->NewAttempt);
- mPrivate->NewAttempt = NULL;
- }
-
- //
// Is User creating a new attempt?
//
NewAttempt = FALSE;
@@ -1637,6 +1629,14 @@ IScsiConfigProcessDefault (
//
return EFI_SUCCESS;
}
+
+ //
+ // Free any attempt that is previously created but not saved to system.
+ //
+ if (mPrivate->NewAttempt != NULL) {
+ FreePool (mPrivate->NewAttempt);
+ mPrivate->NewAttempt = NULL;
+ }
if (NewAttempt) {
//
@@ -2103,37 +2103,75 @@ IScsiFormCallback (
return EFI_SUCCESS;
}
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
- if (This == NULL || Value == NULL || ActionRequest == NULL) {
- return EFI_INVALID_PARAMETER;
- }
-
- Private = ISCSI_FORM_CALLBACK_INFO_FROM_FORM_CALLBACK (This);
-
+ if ((Action != EFI_BROWSER_ACTION_CHANGING) && (Action != EFI_BROWSER_ACTION_CHANGED)) {
//
- // Retrieve uncommitted data from Browser
+ // All other type return unsupported.
//
+ return EFI_UNSUPPORTED;
+ }
- BufferSize = sizeof (ISCSI_CONFIG_IFR_NVDATA);
- IfrNvData = AllocateZeroPool (BufferSize);
- if (IfrNvData == NULL) {
- return EFI_OUT_OF_RESOURCES;
- }
-
- IScsiName = (CHAR8 *) AllocateZeroPool (ISCSI_NAME_MAX_SIZE);
- if (IScsiName == NULL) {
- FreePool (IfrNvData);
- return EFI_OUT_OF_RESOURCES;
- }
-
- Status = EFI_SUCCESS;
+ if ((Value == NULL) || (ActionRequest == NULL)) {
+ return EFI_INVALID_PARAMETER;
+ }
- ZeroMem (&OldIfrNvData, BufferSize);
+ Private = ISCSI_FORM_CALLBACK_INFO_FROM_FORM_CALLBACK (This);
+
+ //
+ // Retrieve uncommitted data from Browser
+ //
+
+ BufferSize = sizeof (ISCSI_CONFIG_IFR_NVDATA);
+ IfrNvData = AllocateZeroPool (BufferSize);
+ if (IfrNvData == NULL) {
+ return EFI_OUT_OF_RESOURCES;
+ }
+
+ IScsiName = (CHAR8 *) AllocateZeroPool (ISCSI_NAME_MAX_SIZE);
+ if (IScsiName == NULL) {
+ FreePool (IfrNvData);
+ return EFI_OUT_OF_RESOURCES;
+ }
+
+ Status = EFI_SUCCESS;
+
+ ZeroMem (&OldIfrNvData, BufferSize);
+
+ HiiGetBrowserData (NULL, NULL, BufferSize, (UINT8 *) IfrNvData);
+
+ CopyMem (&OldIfrNvData, IfrNvData, BufferSize);
- HiiGetBrowserData (NULL, NULL, BufferSize, (UINT8 *) IfrNvData);
+ if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ switch (QuestionId) {
+ case KEY_ADD_ATTEMPT:
+ Status = IScsiConfigAddAttempt ();
+ break;
- CopyMem (&OldIfrNvData, IfrNvData, BufferSize);
+ case KEY_DELETE_ATTEMPT:
+ CopyMem (
+ OldIfrNvData.DeleteAttemptList,
+ IfrNvData->DeleteAttemptList,
+ sizeof (IfrNvData->DeleteAttemptList)
+ );
+ Status = IScsiConfigDisplayDeleteAttempts (IfrNvData);
+ break;
+ case KEY_ORDER_ATTEMPT_CONFIG:
+ //
+ // Order the attempt according to user input.
+ //
+ CopyMem (
+ OldIfrNvData.DynamicOrderedList,
+ IfrNvData->DynamicOrderedList,
+ sizeof (IfrNvData->DynamicOrderedList)
+ );
+ IScsiConfigDisplayOrderAttempts ();
+ break;
+
+ default:
+ Status = IScsiConfigProcessDefault (QuestionId, IfrNvData);
+ break;
+ }
+ } else if (Action == EFI_BROWSER_ACTION_CHANGED) {
switch (QuestionId) {
case KEY_INITIATOR_NAME:
UnicodeStrToAsciiStr (IfrNvData->InitiatorName, IScsiName);
@@ -2151,54 +2189,34 @@ IScsiFormCallback (
*ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
break;
+ case KEY_ATTEMPT_NAME:
+ if (StrLen (IfrNvData->AttemptName) > ATTEMPT_NAME_SIZE) {
+ CopyMem (AttemptName, IfrNvData->AttemptName, ATTEMPT_NAME_SIZE * sizeof (CHAR16));
+ CopyMem (&AttemptName[ATTEMPT_NAME_SIZE], L"...", 4 * sizeof (CHAR16));
+ } else {
+ CopyMem (
+ AttemptName,
+ IfrNvData->AttemptName,
+ (StrLen (IfrNvData->AttemptName) + 1) * sizeof (CHAR16)
+ );
+ }
- case KEY_ADD_ATTEMPT:
- Status = IScsiConfigAddAttempt ();
- break;
+ UnicodeStrToAsciiStr (IfrNvData->AttemptName, Private->Current->AttemptName);
- case KEY_DELETE_ATTEMPT:
- CopyMem (
- OldIfrNvData.DeleteAttemptList,
- IfrNvData->DeleteAttemptList,
- sizeof (IfrNvData->DeleteAttemptList)
- );
- Status = IScsiConfigDisplayDeleteAttempts (IfrNvData);
- break;
+ IScsiConfigUpdateAttempt ();
- case KEY_SAVE_DELETE_ATTEMPT:
- //
- // Delete the Attempt Order from NVR
- //
- Status = IScsiConfigDeleteAttempts (IfrNvData);
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
+ break;
+
+ case KEY_SAVE_ATTEMPT_CONFIG:
+ Status = IScsiConvertIfrNvDataToAttemptConfigData (IfrNvData, Private->Current);
if (EFI_ERROR (Status)) {
break;
}
- IScsiConfigUpdateAttempt ();
*ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
break;
- case KEY_IGNORE_DELETE_ATTEMPT:
- CopyMem (
- IfrNvData->DeleteAttemptList,
- OldIfrNvData.DeleteAttemptList,
- sizeof (IfrNvData->DeleteAttemptList)
- );
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD;
- break;
-
- case KEY_ORDER_ATTEMPT_CONFIG:
- //
- // Order the attempt according to user input.
- //
- CopyMem (
- OldIfrNvData.DynamicOrderedList,
- IfrNvData->DynamicOrderedList,
- sizeof (IfrNvData->DynamicOrderedList)
- );
- IScsiConfigDisplayOrderAttempts ();
- break;
-
case KEY_SAVE_ORDER_CHANGES:
//
// Sync the Attempt Order to NVR.
@@ -2209,7 +2227,7 @@ IScsiFormCallback (
}
IScsiConfigUpdateAttempt ();
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
break;
case KEY_IGNORE_ORDER_CHANGES:
@@ -2218,26 +2236,29 @@ IScsiFormCallback (
OldIfrNvData.DynamicOrderedList,
sizeof (IfrNvData->DynamicOrderedList)
);
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD;
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT;
break;
- case KEY_ATTEMPT_NAME:
- if (StrLen (IfrNvData->AttemptName) > ATTEMPT_NAME_SIZE) {
- CopyMem (AttemptName, IfrNvData->AttemptName, ATTEMPT_NAME_SIZE * sizeof (CHAR16));
- CopyMem (&AttemptName[ATTEMPT_NAME_SIZE], L"...", 4 * sizeof (CHAR16));
- } else {
- CopyMem (
- AttemptName,
- IfrNvData->AttemptName,
- (StrLen (IfrNvData->AttemptName) + 1) * sizeof (CHAR16)
- );
+ case KEY_SAVE_DELETE_ATTEMPT:
+ //
+ // Delete the Attempt Order from NVR
+ //
+ Status = IScsiConfigDeleteAttempts (IfrNvData);
+ if (EFI_ERROR (Status)) {
+ break;
}
- UnicodeStrToAsciiStr (IfrNvData->AttemptName, Private->Current->AttemptName);
-
IScsiConfigUpdateAttempt ();
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
+ break;
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
+ case KEY_IGNORE_DELETE_ATTEMPT:
+ CopyMem (
+ IfrNvData->DeleteAttemptList,
+ OldIfrNvData.DeleteAttemptList,
+ sizeof (IfrNvData->DeleteAttemptList)
+ );
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT;
break;
case KEY_IP_MODE:
@@ -2409,38 +2430,23 @@ IScsiFormCallback (
break;
- case KEY_SAVE_ATTEMPT_CONFIG:
- Status = IScsiConvertIfrNvDataToAttemptConfigData (IfrNvData, Private->Current);
- if (EFI_ERROR (Status)) {
- break;
- }
-
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
- break;
-
default:
- Status = IScsiConfigProcessDefault (QuestionId, IfrNvData);
break;
}
+ }
- if (!EFI_ERROR (Status)) {
- //
- // Pass changed uncommitted data back to Form Browser.
- //
- BufferSize = sizeof (ISCSI_CONFIG_IFR_NVDATA);
- HiiSetBrowserData (NULL, NULL, BufferSize, (UINT8 *) IfrNvData, NULL);
- }
-
- FreePool (IfrNvData);
- FreePool (IScsiName);
-
- return Status;
+ if (!EFI_ERROR (Status)) {
+ //
+ // Pass changed uncommitted data back to Form Browser.
+ //
+ BufferSize = sizeof (ISCSI_CONFIG_IFR_NVDATA);
+ HiiSetBrowserData (NULL, NULL, BufferSize, (UINT8 *) IfrNvData, NULL);
}
- //
- // All other action return unsupported.
- //
- return EFI_UNSUPPORTED;
+ FreePool (IfrNvData);
+ FreePool (IScsiName);
+
+ return Status;
}
diff --git a/edk2/NetworkPkg/IScsiDxe/IScsiConfigVfr.vfr b/edk2/NetworkPkg/IScsiDxe/IScsiConfigVfr.vfr
index 0cf4ffeed..4a322cfd6 100644
--- a/edk2/NetworkPkg/IScsiDxe/IScsiConfigVfr.vfr
+++ b/edk2/NetworkPkg/IScsiDxe/IScsiConfigVfr.vfr
@@ -85,18 +85,19 @@ formset
label ORDER_ENTRY_LABEL;
label LABEL_END;
- goto FORMID_MAIN_FORM,
- prompt = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text
help = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_SAVE_AND_EXIT),
flags = INTERACTIVE,
key = KEY_SAVE_ORDER_CHANGES;
-
- goto FORMID_MAIN_FORM,
- prompt = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+
+ text
help = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
flags = INTERACTIVE,
key = KEY_IGNORE_ORDER_CHANGES;
-
endform;
form formid = FORMID_DELETE_FORM,
@@ -105,18 +106,19 @@ formset
label DELETE_ENTRY_LABEL;
label LABEL_END;
- goto FORMID_MAIN_FORM,
- prompt = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text
help = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_SAVE_AND_EXIT),
flags = INTERACTIVE,
key = KEY_SAVE_DELETE_ATTEMPT;
-
- goto FORMID_MAIN_FORM,
- prompt = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+
+ text
help = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
flags = INTERACTIVE,
key = KEY_IGNORE_DELETE_ATTEMPT;
-
endform;
form formid = FORMID_ATTEMPT_FORM,
@@ -348,12 +350,13 @@ formset
subtitle text = STRING_TOKEN(STR_NULL);
- goto FORMID_ATTEMPT_FORM,
- prompt = STRING_TOKEN (STR_SAVE_CHANGES),
- help = STRING_TOKEN (STR_SAVE_CHANGES_HELP),
- flags = INTERACTIVE,
- key = KEY_SAVE_ATTEMPT_CONFIG;
-
+ text
+ help = STRING_TOKEN (STR_SAVE_CHANGES_HELP),
+ text = STRING_TOKEN (STR_SAVE_CHANGES),
+ text = STRING_TOKEN (STR_SAVE_CHANGES),
+ flags = INTERACTIVE,
+ key = KEY_SAVE_ATTEMPT_CONFIG;
+
goto FORMID_MAIN_FORM,
prompt = STRING_TOKEN (STR_RETURN_MAIN_FORM),
help = STRING_TOKEN (STR_RETURN_MAIN_FORM),
diff --git a/edk2/NetworkPkg/Ip6Dxe/Ip6Config.vfr b/edk2/NetworkPkg/Ip6Dxe/Ip6Config.vfr
index 7639f5a0f..de63f4dad 100644
--- a/edk2/NetworkPkg/Ip6Dxe/Ip6Config.vfr
+++ b/edk2/NetworkPkg/Ip6Dxe/Ip6Config.vfr
@@ -163,17 +163,19 @@ formset
maxsize = ADDRESS_STR_MAX_SIZE,
endstring;
- goto FORMID_MAIN_FORM,
- prompt = STRING_TOKEN (STR_SAVE_AND_EXIT),
- help = STRING_TOKEN (STR_SAVE_AND_EXIT),
- flags = INTERACTIVE,
- key = KEY_SAVE_CONFIG_CHANGES;
+ text
+ help = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_SAVE_AND_EXIT),
+ flags = INTERACTIVE,
+ key = KEY_SAVE_CONFIG_CHANGES;
- goto FORMID_MAIN_FORM,
- prompt = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
- help = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
- flags = INTERACTIVE,
- key = KEY_IGNORE_CONFIG_CHANGES;
+ text
+ help = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+ text = STRING_TOKEN (STR_NO_SAVE_AND_EXIT),
+ flags = INTERACTIVE,
+ key = KEY_IGNORE_CONFIG_CHANGES;
endform;
diff --git a/edk2/NetworkPkg/Ip6Dxe/Ip6ConfigNv.c b/edk2/NetworkPkg/Ip6Dxe/Ip6ConfigNv.c
index b383488ff..db2155e14 100644
--- a/edk2/NetworkPkg/Ip6Dxe/Ip6ConfigNv.c
+++ b/edk2/NetworkPkg/Ip6Dxe/Ip6ConfigNv.c
@@ -1651,7 +1651,7 @@ Ip6FormCallback (
return EFI_SUCCESS;
}
- if (Action != EFI_BROWSER_ACTION_CHANGING) {
+ if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {
return EFI_UNSUPPORTED;
}
@@ -1677,224 +1677,230 @@ Ip6FormCallback (
CopyMem (&OldIfrNvData, IfrNvData, BufferSize);
- switch (QuestionId) {
- case KEY_INTERFACE_ID:
- Status = Ip6ParseInterfaceIdFromString (IfrNvData->InterfaceId, &Ip6NvData->InterfaceId);
- if (EFI_ERROR (Status)) {
- CreatePopUp (
- EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
- &Key,
- L"Invalid Interface ID!",
- NULL
- );
- }
-
- break;
-
- case KEY_MANUAL_ADDRESS:
- Status = Ip6ParseAddressListFromString (
- IfrNvData->ManualAddress,
- &Ip6NvData->ManualAddress,
- &Ip6NvData->ManualAddressCount
- );
- if (EFI_ERROR (Status)) {
- CreatePopUp (
- EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
- &Key,
- L"Invalid Host Addresses!",
- NULL
- );
- }
-
- break;
-
- case KEY_GATEWAY_ADDRESS:
- Status = Ip6ParseAddressListFromString (
- IfrNvData->GatewayAddress,
- &Ip6NvData->GatewayAddress,
- &Ip6NvData->GatewayAddressCount
- );
- if (EFI_ERROR (Status)) {
- CreatePopUp (
- EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
- &Key,
- L"Invalid Gateway Addresses!",
- NULL
- );
- }
-
- break;
-
- case KEY_DNS_ADDRESS:
- Status = Ip6ParseAddressListFromString (
- IfrNvData->DnsAddress,
- &Ip6NvData->DnsAddress,
- &Ip6NvData->DnsAddressCount
- );
- if (EFI_ERROR (Status)) {
- CreatePopUp (
- EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
- &Key,
- L"Invalid DNS Addresses!",
- NULL
- );
- }
-
- break;
-
- case KEY_SAVE_CONFIG_CHANGES:
- CopyMem (&OldIfrNvData, IfrNvData, sizeof (IP6_CONFIG_IFR_NVDATA));
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
- break;
-
- case KEY_IGNORE_CONFIG_CHANGES:
- CopyMem (IfrNvData, &OldIfrNvData, sizeof (IP6_CONFIG_IFR_NVDATA));
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD;
- break;
-
- case KEY_SAVE_CHANGES:
- Status = Ip6ConvertIfrNvDataToConfigNvData (IfrNvData, Instance);
- if (EFI_ERROR (Status)) {
- break;
- }
-
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_SUBMIT;
- break;
-
- case KEY_GET_CURRENT_SETTING:
- Ip6Config = &Instance->Ip6Config;
- HiiHandle = Instance->CallbackInfo.RegisteredHandle;
- Data = NULL;
-
- //
- // Get current interface info.
- //
- Status = Ip6ConfigNvGetData (
- Ip6Config,
- Ip6ConfigDataTypeInterfaceInfo,
- &DataSize,
- (VOID **) &Data
- );
- if (EFI_ERROR (Status)) {
- return Status;
- }
-
- //
- // Generate dynamic text opcode for host address and draw it.
- //
- IfInfo = (EFI_IP6_CONFIG_INTERFACE_INFO *) Data;
- Status = Ip6ConvertAddressListToString (
- PortString,
- HiiHandle,
- Ip6ConfigNvHostAddress,
- IfInfo->AddressInfo,
- IfInfo->AddressInfoCount
- );
- if (EFI_ERROR (Status)) {
- FreePool (Data);
- return Status;
- }
-
- //
- // Generate the dynamic text opcode for route table and draw it.
- //
- Status = Ip6ConvertAddressListToString (
- PortString,
- HiiHandle,
- Ip6ConfigNvRouteTable,
- IfInfo->RouteTable,
- IfInfo->RouteCount
- );
- if (EFI_ERROR (Status)) {
- FreePool (Data);
- return Status;
- }
+ if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ switch (QuestionId) {
+ case KEY_GET_CURRENT_SETTING:
+ Ip6Config = &Instance->Ip6Config;
+ HiiHandle = Instance->CallbackInfo.RegisteredHandle;
+ Data = NULL;
- //
- // Get DNS server list.
- //
- FreePool (Data);
- DataSize = 0;
- Data = NULL;
- Status = Ip6ConfigNvGetData (
- Ip6Config,
- Ip6ConfigDataTypeDnsServer,
- &DataSize,
- (VOID **) &Data
- );
- if (EFI_ERROR (Status) && (Status != EFI_NOT_FOUND)) {
- if (Data != NULL) {
- FreePool (Data);
+ //
+ // Get current interface info.
+ //
+ Status = Ip6ConfigNvGetData (
+ Ip6Config,
+ Ip6ConfigDataTypeInterfaceInfo,
+ &DataSize,
+ (VOID **) &Data
+ );
+ if (EFI_ERROR (Status)) {
+ return Status;
}
- return Status;
- }
- if (DataSize > 0) {
//
- // Generate the dynamic text opcode for DNS server and draw it.
+ // Generate dynamic text opcode for host address and draw it.
//
+ IfInfo = (EFI_IP6_CONFIG_INTERFACE_INFO *) Data;
Status = Ip6ConvertAddressListToString (
PortString,
HiiHandle,
- Ip6ConfigNvDnsAddress,
- Data,
- DataSize / sizeof (EFI_IPv6_ADDRESS)
+ Ip6ConfigNvHostAddress,
+ IfInfo->AddressInfo,
+ IfInfo->AddressInfoCount
);
if (EFI_ERROR (Status)) {
FreePool (Data);
return Status;
}
- }
-
- //
- // Get gateway adderss list.
- //
- if (Data != NULL) {
- FreePool (Data);
- }
-
- DataSize = 0;
- Data = NULL;
- Status = Ip6ConfigNvGetData (
- Ip6Config,
- Ip6ConfigDataTypeGateway,
- &DataSize,
- (VOID **) &Data
- );
- if (EFI_ERROR (Status) && (Status != EFI_NOT_FOUND)) {
- if (Data != NULL) {
- FreePool (Data);
- }
- return Status;
- }
- if (DataSize > 0) {
//
- // Generate the dynamic text opcode for gateway and draw it.
+ // Generate the dynamic text opcode for route table and draw it.
//
Status = Ip6ConvertAddressListToString (
PortString,
HiiHandle,
- Ip6ConfigNvGatewayAddress,
- Data,
- DataSize / sizeof (EFI_IPv6_ADDRESS)
+ Ip6ConfigNvRouteTable,
+ IfInfo->RouteTable,
+ IfInfo->RouteCount
);
if (EFI_ERROR (Status)) {
FreePool (Data);
return Status;
}
- }
- if (Data != NULL) {
+ //
+ // Get DNS server list.
+ //
FreePool (Data);
+ DataSize = 0;
+ Data = NULL;
+ Status = Ip6ConfigNvGetData (
+ Ip6Config,
+ Ip6ConfigDataTypeDnsServer,
+ &DataSize,
+ (VOID **) &Data
+ );
+ if (EFI_ERROR (Status) && (Status != EFI_NOT_FOUND)) {
+ if (Data != NULL) {
+ FreePool (Data);
+ }
+ return Status;
+ }
+
+ if (DataSize > 0) {
+ //
+ // Generate the dynamic text opcode for DNS server and draw it.
+ //
+ Status = Ip6ConvertAddressListToString (
+ PortString,
+ HiiHandle,
+ Ip6ConfigNvDnsAddress,
+ Data,
+ DataSize / sizeof (EFI_IPv6_ADDRESS)
+ );
+ if (EFI_ERROR (Status)) {
+ FreePool (Data);
+ return Status;
+ }
+ }
+
+ //
+ // Get gateway adderss list.
+ //
+ if (Data != NULL) {
+ FreePool (Data);
+ }
+
+ DataSize = 0;
+ Data = NULL;
+ Status = Ip6ConfigNvGetData (
+ Ip6Config,
+ Ip6ConfigDataTypeGateway,
+ &DataSize,
+ (VOID **) &Data
+ );
+ if (EFI_ERROR (Status) && (Status != EFI_NOT_FOUND)) {
+ if (Data != NULL) {
+ FreePool (Data);
+ }
+ return Status;
+ }
+
+ if (DataSize > 0) {
+ //
+ // Generate the dynamic text opcode for gateway and draw it.
+ //
+ Status = Ip6ConvertAddressListToString (
+ PortString,
+ HiiHandle,
+ Ip6ConfigNvGatewayAddress,
+ Data,
+ DataSize / sizeof (EFI_IPv6_ADDRESS)
+ );
+ if (EFI_ERROR (Status)) {
+ FreePool (Data);
+ return Status;
+ }
+ }
+
+ if (Data != NULL) {
+ FreePool (Data);
+ }
+
+ Status = EFI_SUCCESS;
+
+ break;
+
+ default:
+ break;
}
+ } else if (Action == EFI_BROWSER_ACTION_CHANGED) {
+ switch (QuestionId) {
+ case KEY_SAVE_CONFIG_CHANGES:
+ CopyMem (&OldIfrNvData, IfrNvData, sizeof (IP6_CONFIG_IFR_NVDATA));
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
+ break;
- Status = EFI_SUCCESS;
+ case KEY_IGNORE_CONFIG_CHANGES:
+ CopyMem (IfrNvData, &OldIfrNvData, sizeof (IP6_CONFIG_IFR_NVDATA));
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT;
+ break;
- break;
+ case KEY_SAVE_CHANGES:
+ Status = Ip6ConvertIfrNvDataToConfigNvData (IfrNvData, Instance);
+ if (EFI_ERROR (Status)) {
+ break;
+ }
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_SUBMIT;
+ break;
+
+ case KEY_INTERFACE_ID:
+ Status = Ip6ParseInterfaceIdFromString (IfrNvData->InterfaceId, &Ip6NvData->InterfaceId);
+ if (EFI_ERROR (Status)) {
+ CreatePopUp (
+ EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
+ &Key,
+ L"Invalid Interface ID!",
+ NULL
+ );
+ }
+
+ break;
+
+ case KEY_MANUAL_ADDRESS:
+ Status = Ip6ParseAddressListFromString (
+ IfrNvData->ManualAddress,
+ &Ip6NvData->ManualAddress,
+ &Ip6NvData->ManualAddressCount
+ );
+ if (EFI_ERROR (Status)) {
+ CreatePopUp (
+ EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
+ &Key,
+ L"Invalid Host Addresses!",
+ NULL
+ );
+ }
+
+ break;
+
+ case KEY_GATEWAY_ADDRESS:
+ Status = Ip6ParseAddressListFromString (
+ IfrNvData->GatewayAddress,
+ &Ip6NvData->GatewayAddress,
+ &Ip6NvData->GatewayAddressCount
+ );
+ if (EFI_ERROR (Status)) {
+ CreatePopUp (
+ EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
+ &Key,
+ L"Invalid Gateway Addresses!",
+ NULL
+ );
+ }
+
+ break;
+
+ case KEY_DNS_ADDRESS:
+ Status = Ip6ParseAddressListFromString (
+ IfrNvData->DnsAddress,
+ &Ip6NvData->DnsAddress,
+ &Ip6NvData->DnsAddressCount
+ );
+ if (EFI_ERROR (Status)) {
+ CreatePopUp (
+ EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
+ &Key,
+ L"Invalid DNS Addresses!",
+ NULL
+ );
+ }
+
+ break;
- default:
- break;
+ default:
+ break;
+ }
}
if (!EFI_ERROR (Status)) {
diff --git a/edk2/NetworkPkg/NetworkPkg.dec b/edk2/NetworkPkg/NetworkPkg.dec
index e4d7eb131..5d2979d47 100644
--- a/edk2/NetworkPkg/NetworkPkg.dec
+++ b/edk2/NetworkPkg/NetworkPkg.dec
@@ -18,7 +18,7 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = NetworkPkg
PACKAGE_GUID = 947988BE-8D5C-471a-893D-AD181C46BEBB
- PACKAGE_VERSION = 0.92
+ PACKAGE_VERSION = 0.93
[Includes]
Include
diff --git a/edk2/NetworkPkg/NetworkPkg.dsc b/edk2/NetworkPkg/NetworkPkg.dsc
index 44e45a59f..3055cf675 100644
--- a/edk2/NetworkPkg/NetworkPkg.dsc
+++ b/edk2/NetworkPkg/NetworkPkg.dsc
@@ -16,7 +16,7 @@
[Defines]
PLATFORM_NAME = NetworkPkg
PLATFORM_GUID = 3FD34E9B-E90C-44e1-B510-1F632A509F10
- PLATFORM_VERSION = 0.92
+ PLATFORM_VERSION = 0.93
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/NetworkPkg
SUPPORTED_ARCHITECTURES = IA32|IPF|X64|EBC|ARM
diff --git a/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcDhcp6.c b/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcDhcp6.c
index 3e59f3f23..871567547 100644
--- a/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcDhcp6.c
+++ b/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcDhcp6.c
@@ -1626,6 +1626,14 @@ PxeBcDhcp6Discover (
}
ReadSize = (UINTN) Reply->Size;
+ //
+ // Start Udp6Read instance
+ //
+ Status = Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
+ if (EFI_ERROR (Status)) {
+ return Status;
+ }
+
Status = PxeBc->UdpRead (
PxeBc,
OpFlags,
@@ -1638,6 +1646,10 @@ PxeBcDhcp6Discover (
&ReadSize,
(VOID *) &Reply->Dhcp6
);
+ //
+ // Stop Udp6Read instance
+ //
+ Private->Udp6Read->Configure (Private->Udp6Read, NULL);
if (EFI_ERROR (Status)) {
return Status;
}
diff --git a/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c b/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c
index 00f1e4d39..67abd48f4 100644
--- a/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c
+++ b/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c
@@ -430,13 +430,8 @@ EfiPxeBcDhcp (
Status = PxeBcDhcp6Sarr (Private, Private->Dhcp6);
if (EFI_ERROR (Status)) {
- return Status;
+ goto ON_EXIT;
}
-
- //
- // Configure Udp6Read instance
- //
- Status = Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
} else {
//
@@ -450,15 +445,16 @@ EfiPxeBcDhcp (
Status = PxeBcDhcp4Dora (Private, Private->Dhcp4);
if (EFI_ERROR (Status)) {
- return Status;
+ goto ON_EXIT;
}
-
- //
- // Configure Udp4Read instance
- //
- Status = Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
}
-
+
+ON_EXIT:
+ if (Mode->UsingIpv6) {
+ Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
+ } else {
+ Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
+ }
//
// Dhcp(), Discover(), and Mtftp() set the IP filter, and return with the IP
// receive filter list emptied and the filter set to EFI_PXE_BASE_CODE_IP_FILTER_STATION_IP.
@@ -692,7 +688,7 @@ EfiPxeBcDiscover (
}
if (EFI_ERROR (Status)) {
- return Status;
+ goto ON_EXIT;
} else {
//
// Parse the cached PXE reply packet, and store it into mode data if valid.
@@ -725,9 +721,9 @@ EfiPxeBcDiscover (
ON_EXIT:
if (Mode->UsingIpv6) {
- Status = Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
+ Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
} else {
- Status = Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
+ Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
}
//
@@ -962,15 +958,15 @@ EfiPxeBcMtftp (
}
if (EFI_ERROR (Status)) {
- return Status;
+ goto ON_EXIT;
}
-
+
+ON_EXIT:
if (Mode->UsingIpv6) {
- Status = Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
+ Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
} else {
- Status = Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
+ Private->Udp4Read->Configure (Private->Udp4Read, &Private->Udp4CfgData);
}
-
//
// Dhcp(), Discover(), and Mtftp() set the IP filter, and return with the IP
// receive filter list emptied and the filter set to EFI_PXE_BASE_CODE_IP_FILTER_STATION_IP.
diff --git a/edk2/OptionRomPkg/Library/FrameBufferBltLib/FrameBufferBltLib.inf b/edk2/OptionRomPkg/Library/FrameBufferBltLib/FrameBufferBltLib.inf
index cdeb014a2..b94b52aa7 100644
--- a/edk2/OptionRomPkg/Library/FrameBufferBltLib/FrameBufferBltLib.inf
+++ b/edk2/OptionRomPkg/Library/FrameBufferBltLib/FrameBufferBltLib.inf
@@ -1,4 +1,4 @@
-#/** @file
+## @file
# FrameBufferBltLib - Library to perform blt operations on a frame buffer.
#
# Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
@@ -11,7 +11,7 @@
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
-#**/
+##
[Defines]
INF_VERSION = 0x00010005
diff --git a/edk2/OptionRomPkg/Library/GopBltLib/GopBltLib.inf b/edk2/OptionRomPkg/Library/GopBltLib/GopBltLib.inf
index 9ec200db2..8a096966e 100644
--- a/edk2/OptionRomPkg/Library/GopBltLib/GopBltLib.inf
+++ b/edk2/OptionRomPkg/Library/GopBltLib/GopBltLib.inf
@@ -1,4 +1,4 @@
-#/** @file
+## @file
# GopBltLib - Library to perform blt using the UEFI Graphics Output Protocol.
#
# Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
@@ -11,7 +11,7 @@
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
-#**/
+##
[Defines]
INF_VERSION = 0x00010005
diff --git a/edk2/OvmfPkg/QemuVideoDxe/QemuVideoDxe.inf b/edk2/OvmfPkg/QemuVideoDxe/QemuVideoDxe.inf
index 044893b67..fde743b04 100644
--- a/edk2/OvmfPkg/QemuVideoDxe/QemuVideoDxe.inf
+++ b/edk2/OvmfPkg/QemuVideoDxe/QemuVideoDxe.inf
@@ -1,4 +1,4 @@
-#/** @file
+## @file
# This driver is a sample implementation of the Graphics Output Protocol for
# the QEMU (Cirrus Logic 5446) video controller.
#
@@ -12,7 +12,7 @@
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
-#**/
+##
[Defines]
INF_VERSION = 0x00010005
diff --git a/edk2/SecurityPkg/SecurityPkg.dec b/edk2/SecurityPkg/SecurityPkg.dec
index 4ed4f406d..f9382788f 100644
--- a/edk2/SecurityPkg/SecurityPkg.dec
+++ b/edk2/SecurityPkg/SecurityPkg.dec
@@ -17,7 +17,7 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = SecurityPkg
PACKAGE_GUID = 24369CAC-6AA6-4fb8-88DB-90BF061668AD
- PACKAGE_VERSION = 0.91
+ PACKAGE_VERSION = 0.92
[Includes]
Include
diff --git a/edk2/SecurityPkg/SecurityPkg.dsc b/edk2/SecurityPkg/SecurityPkg.dsc
index f089e3308..c41f22e16 100644
--- a/edk2/SecurityPkg/SecurityPkg.dsc
+++ b/edk2/SecurityPkg/SecurityPkg.dsc
@@ -15,7 +15,7 @@
[Defines]
PLATFORM_NAME = SecurityPkg
PLATFORM_GUID = B2C4614D-AE76-47ba-B876-5988BFED064F
- PLATFORM_VERSION = 0.91
+ PLATFORM_VERSION = 0.92
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/SecurityPkg
SUPPORTED_ARCHITECTURES = IA32|IPF|X64|EBC
diff --git a/edk2/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c b/edk2/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
index 20eb3eee0..f884226d9 100644
--- a/edk2/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
+++ b/edk2/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
@@ -404,7 +404,7 @@ TcgCallback (
return EFI_INVALID_PARAMETER;
}
- if ((Action != EFI_BROWSER_ACTION_CHANGING) || (QuestionId != KEY_TPM_ACTION)) {
+ if ((Action != EFI_BROWSER_ACTION_CHANGED) || (QuestionId != KEY_TPM_ACTION)) {
return EFI_UNSUPPORTED;
}
diff --git a/edk2/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c b/edk2/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c
index afb090a91..cf7fe4079 100644
--- a/edk2/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c
+++ b/edk2/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c
@@ -548,7 +548,7 @@ CredentialDriverCallback (
CHAR8 Password[CREDENTIAL_LEN];
CHAR16 *PromptStr;
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
if (QuestionId == KEY_GET_PASSWORD) {
//
// Get and check password.
diff --git a/edk2/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.c b/edk2/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.c
index 327a2b038..f851bb2e2 100644
--- a/edk2/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.c
+++ b/edk2/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.c
@@ -1,7 +1,7 @@
/** @file
Usb Credential Provider driver implemenetation.
-Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -894,7 +894,6 @@ CredentialUser (
UINT8 *UserToken;
UINT8 ReadToken[HASHED_CREDENTIAL_LEN];
EFI_INPUT_KEY Key;
- EFI_TPL OldTpl;
CHAR16 *QuestionStr;
CHAR16 *PromptStr;
@@ -943,8 +942,6 @@ CredentialUser (
if (EFI_ERROR (Status)) {
QuestionStr = GetStringById (STRING_TOKEN (STR_READ_USB_TOKEN_ERROR));
PromptStr = GetStringById (STRING_TOKEN (STR_INSERT_USB_TOKEN));
- OldTpl = gBS->RaiseTPL (TPL_HIGH_LEVEL);
- gBS->RestoreTPL (TPL_APPLICATION);
CreatePopUp (
EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
&Key,
@@ -953,7 +950,6 @@ CredentialUser (
PromptStr,
NULL
);
- gBS->RaiseTPL (OldTpl);
FreePool (QuestionStr);
FreePool (PromptStr);
return EFI_NOT_FOUND;
diff --git a/edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c b/edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c
index 268dfab46..adcf9bf65 100644
--- a/edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c
+++ b/edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c
@@ -2411,8 +2411,7 @@ UserIdentifyManagerCallback (
Status = EFI_SUCCESS;
break;
- case EFI_BROWSER_ACTION_CHANGING:
- {
+ case EFI_BROWSER_ACTION_CHANGED:
if (QuestionId >= LABEL_PROVIDER_NAME) {
//
// QuestionId comes from the second Form (Select a Credential Provider if identity
@@ -2425,10 +2424,16 @@ UserIdentifyManagerCallback (
}
return EFI_SUCCESS;
}
-
+ break;
+
+ case EFI_BROWSER_ACTION_CHANGING:
//
// QuestionId comes from the first Form (Select a user to identify).
//
+ if (QuestionId >= LABEL_PROVIDER_NAME) {
+ return EFI_SUCCESS;
+ }
+
User = (USER_PROFILE_ENTRY *) mUserProfileDb->UserProfile[QuestionId & 0xFFF];
Status = GetIdentifyType (User, &PolicyType);
if (EFI_ERROR (Status)) {
@@ -2456,9 +2461,10 @@ UserIdentifyManagerCallback (
mCurrentUser = (EFI_USER_PROFILE_HANDLE) User;
mIdentified = TRUE;
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
+ if (Type == EFI_IFR_TYPE_REF) {
+ Value->ref.FormId = FORMID_INVALID_FORM;
+ }
}
- }
break;
default:
diff --git a/edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h b/edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h
index 5efc50d16..b08ac4643 100644
--- a/edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h
+++ b/edk2/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h
@@ -22,6 +22,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
#define FORMID_USER_FORM 1
#define FORMID_PROVIDER_FORM 2
+#define FORMID_INVALID_FORM 0x0FFF
//
// Labels definition.
diff --git a/edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c b/edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c
index 6e5bd0650..4bba0824c 100644
--- a/edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c
+++ b/edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c
@@ -309,7 +309,7 @@ UserProfileManagerCallback (
Status = EFI_SUCCESS;
break;
- case EFI_BROWSER_ACTION_CHANGING:
+ case EFI_BROWSER_ACTION_CHANGED:
{
//
// Handle the request from form.
@@ -338,13 +338,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_SECOND_FORM_MASK) {
//
- // Enter delete user profile form.
- //
- case KEY_ENTER_NEXT_FORM:
- SelectUserToDelete ();
- break;
-
- //
// Delete specified user profile.
//
case KEY_SELECT_USER:
@@ -369,13 +362,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_SECOND_FORM_MASK) {
//
- // Enter modify user profile form.
- //
- case KEY_ENTER_NEXT_FORM:
- SelectUserToModify ();
- break;
-
- //
// Enter user profile information form.
//
case KEY_SELECT_USER:
@@ -384,13 +370,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_MODIFY_INFO_MASK) {
//
- // Display user information form.
- //
- case KEY_ENTER_NEXT_FORM:
- ModifyUserInfo ((UINT8) QuestionId);
- break;
-
- //
// Modify user name.
//
case KEY_MODIFY_NAME:
@@ -410,13 +389,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_MODIFY_IP_MASK) {
//
- // Display identity policy modify form.
- //
- case KEY_ENTER_NEXT_FORM:
- ModifyIdentityPolicy ();
- break;
-
- //
// Change credential provider option.
//
case KEY_MODIFY_PROV:
@@ -442,7 +414,7 @@ UserProfileManagerCallback (
//
case KEY_IP_RETURN_UIF:
SaveIdentityPolicy ();
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
break;
default:
@@ -459,13 +431,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_MODIFY_AP_MASK) {
//
- // Display access policy modify form.
- //
- case KEY_ENTER_NEXT_FORM:
- ModidyAccessPolicy ();
- break;
-
- //
// Change access right choice.
//
case KEY_MODIFY_RIGHT:
@@ -487,65 +452,11 @@ UserProfileManagerCallback (
break;
//
- // Load device path form.
- //
- case KEY_MODIFY_LOAD:
- //
- // Judge next 2 bits.
- //
- switch (QuestionId & KEY_DISPLAY_DP_MASK) {
- //
- // Permit load device path.
- //
- case KEY_PERMIT_MODIFY:
- DisplayLoadPermit ();
- break;
-
- //
- // Forbid load device path.
- //
- case KEY_FORBID_MODIFY:
- DisplayLoadForbid ();
- break;
-
- default:
- break;
- }
- break;
-
- //
- // Connect device path form.
- //
- case KEY_MODIFY_CONNECT:
- //
- // Judge next 2 bits.
- //
- switch (QuestionId & KEY_DISPLAY_DP_MASK) {
- //
- // Permit connect device path.
- //
- case KEY_PERMIT_MODIFY:
- DisplayConnectPermit ();
- break;
-
- //
- // Forbid connect device path.
- //
- case KEY_FORBID_MODIFY:
- DisplayConnectForbid ();
- break;
-
- default:
- break;
- }
- break;
-
- //
// Return to user profile information form.
//
case KEY_AP_RETURN_UIF:
SaveAccessPolicy ();
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
break;
default:
@@ -642,6 +553,179 @@ UserProfileManagerCallback (
}
break;
+
+ case EFI_BROWSER_ACTION_CHANGING:
+ {
+ //
+ // Handle the request from form.
+ //
+ if (Value == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ //
+ // Judge first 2 bits.
+ //
+ switch (QuestionId & KEY_FIRST_FORM_MASK) {
+ //
+ // Delete user profile operation.
+ //
+ case KEY_DEL_USER:
+ //
+ // Judge next 2 bits.
+ //
+ switch (QuestionId & KEY_SECOND_FORM_MASK) {
+ //
+ // Enter delete user profile form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ SelectUserToDelete ();
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ //
+ // Modify user profile operation.
+ //
+ case KEY_MODIFY_USER:
+ //
+ // Judge next 2 bits.
+ //
+ switch (QuestionId & KEY_SECOND_FORM_MASK) {
+ //
+ // Enter modify user profile form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ SelectUserToModify ();
+ break;
+
+ //
+ // Enter user profile information form.
+ //
+ case KEY_SELECT_USER:
+ //
+ // Judge next 3 bits.
+ //
+ switch (QuestionId & KEY_MODIFY_INFO_MASK) {
+ //
+ // Display user information form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ ModifyUserInfo ((UINT8) QuestionId);
+ break;
+
+ //
+ // Modify identity policy.
+ //
+ case KEY_MODIFY_IP:
+ //
+ // Judge next 3 bits
+ //
+ switch (QuestionId & KEY_MODIFY_IP_MASK) {
+ //
+ // Display identity policy modify form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ ModifyIdentityPolicy ();
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ //
+ // Modify access policy.
+ //
+ case KEY_MODIFY_AP:
+ //
+ // Judge next 3 bits.
+ //
+ switch (QuestionId & KEY_MODIFY_AP_MASK) {
+ //
+ // Display access policy modify form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ ModidyAccessPolicy ();
+ break;
+ //
+ // Load device path form.
+ //
+ case KEY_MODIFY_LOAD:
+ //
+ // Judge next 2 bits.
+ //
+ switch (QuestionId & KEY_DISPLAY_DP_MASK) {
+ //
+ // Permit load device path.
+ //
+ case KEY_PERMIT_MODIFY:
+ DisplayLoadPermit ();
+ break;
+
+ //
+ // Forbid load device path.
+ //
+ case KEY_FORBID_MODIFY:
+ DisplayLoadForbid ();
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ //
+ // Connect device path form.
+ //
+ case KEY_MODIFY_CONNECT:
+ //
+ // Judge next 2 bits.
+ //
+ switch (QuestionId & KEY_DISPLAY_DP_MASK) {
+ //
+ // Permit connect device path.
+ //
+ case KEY_PERMIT_MODIFY:
+ DisplayConnectPermit ();
+ break;
+
+ //
+ // Forbid connect device path.
+ //
+ case KEY_FORBID_MODIFY:
+ DisplayConnectForbid ();
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ default:
+ break;
+ }
+ }
+ break;
+
default:
//
// All other action return unsupported.
diff --git a/edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr b/edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr
index d094d78a7..fa6d9e4a8 100644
--- a/edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr
+++ b/edk2/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr
@@ -114,12 +114,12 @@ formset
subtitle
text = STRING_TOKEN(STR_NULL_STRING);
- goto FORMID_USER_INFO,
- prompt = STRING_TOKEN(STR_SAVE),
- help = STRING_TOKEN(STR_IDENTIFY_SAVE_HELP),
- flags = INTERACTIVE,
- key = KEY_IP_RETURN;
-
+ text
+ help = STRING_TOKEN(STR_IDENTIFY_SAVE_HELP),
+ text = STRING_TOKEN(STR_SAVE),
+ flags = INTERACTIVE,
+ key = KEY_IP_RETURN;
+
endform;
//
@@ -146,12 +146,12 @@ formset
subtitle
text = STRING_TOKEN(STR_NULL_STRING);
- goto FORMID_USER_INFO,
- prompt = STRING_TOKEN(STR_SAVE),
- help = STRING_TOKEN(STR_ACCESS_SAVE_HELP),
- flags = INTERACTIVE,
- key = KEY_AP_RETURN;
-
+ text
+ help = STRING_TOKEN(STR_ACCESS_SAVE_HELP),
+ text = STRING_TOKEN(STR_SAVE),
+ flags = INTERACTIVE,
+ key = KEY_AP_RETURN;
+
endform;
//
diff --git a/edk2/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c b/edk2/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
index 1d6d7aa2c..f846a72ca 100644
--- a/edk2/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
+++ b/edk2/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
@@ -314,7 +314,7 @@ SecureBootCallback (
return EFI_INVALID_PARAMETER;
}
- if ((Action != EFI_BROWSER_ACTION_CHANGING) || (QuestionId != KEY_SECURE_BOOT_ENABLE)) {
+ if ((Action != EFI_BROWSER_ACTION_CHANGED) || (QuestionId != KEY_SECURE_BOOT_ENABLE)) {
return EFI_UNSUPPORTED;
}
diff --git a/edk2/ShellBinPkg/ShellBinPkg.dec b/edk2/ShellBinPkg/ShellBinPkg.dec
index b276814bb..34575ab15 100644
--- a/edk2/ShellBinPkg/ShellBinPkg.dec
+++ b/edk2/ShellBinPkg/ShellBinPkg.dec
@@ -1,11 +1,11 @@
## @file
# UEFI 2.0 Shell Binary Package
#
-# This package contains binary shell application that follows
+# This package contains binary shell application that follows
# UEFI specification and UEFI Shell 2.0 specification.
# Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
#
-# This program and the accompanying materials are licensed and made available
+# This program and the accompanying materials are licensed and made available
# under the terms and conditions of the BSD License which accompanies this distribution.
# The full text of the license may be found at http://opensource.org/licenses/bsd-license.php
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES
@@ -17,5 +17,5 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = ShellBinPkg
PACKAGE_GUID = 4B34AD9D-1324-41e5-8B1D-359AA7BCA62C
- PACKAGE_VERSION = 0.1
+ PACKAGE_VERSION = 0.5
diff --git a/edk2/ShellPkg/Application/Shell/Shell.c b/edk2/ShellPkg/Application/Shell/Shell.c
index 05a3cb5b8..878a3852a 100644
--- a/edk2/ShellPkg/Application/Shell/Shell.c
+++ b/edk2/ShellPkg/Application/Shell/Shell.c
@@ -1224,8 +1224,11 @@ RunSplitCommand(
SHELL_FREE_NON_NULL(OurCommandLine);
SHELL_FREE_NON_NULL(NextCommandLine);
return (EFI_OUT_OF_RESOURCES);
- }
- if (NextCommandLine[0] != CHAR_NULL &&
+ } else if (StrStr(OurCommandLine, L"|") != NULL || Size1 == 0 || Size2 == 0) {
+ SHELL_FREE_NON_NULL(OurCommandLine);
+ SHELL_FREE_NON_NULL(NextCommandLine);
+ return (EFI_INVALID_PARAMETER);
+ } else if (NextCommandLine[0] != CHAR_NULL &&
NextCommandLine[0] == L'a' &&
NextCommandLine[1] == L' '
){
@@ -1246,7 +1249,6 @@ RunSplitCommand(
ASSERT(Split->SplitStdOut != NULL);
InsertHeadList(&ShellInfoObject.SplitList.Link, &Split->Link);
- ASSERT(StrStr(OurCommandLine, L"|") == NULL);
Status = RunCommand(OurCommandLine);
//
@@ -1432,6 +1434,9 @@ RunCommand(
} else {
Status = RunSplitCommand(PostVariableCmdLine, Split->SplitStdIn, Split->SplitStdOut);
}
+ if (EFI_ERROR(Status)) {
+ ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_SHELL_INVALID_SPLIT), ShellInfoObject.HiiHandle, PostVariableCmdLine);
+ }
} else {
//
diff --git a/edk2/ShellPkg/Application/Shell/Shell.uni b/edk2/ShellPkg/Application/Shell/Shell.uni
index 215da1cd7..c4eb546af 100644
--- a/edk2/ShellPkg/Application/Shell/Shell.uni
+++ b/edk2/ShellPkg/Application/Shell/Shell.uni
Binary files differ
diff --git a/edk2/ShellPkg/Application/Shell/ShellProtocol.c b/edk2/ShellPkg/Application/Shell/ShellProtocol.c
index 00bbc358f..3371e58b1 100644
--- a/edk2/ShellPkg/Application/Shell/ShellProtocol.c
+++ b/edk2/ShellPkg/Application/Shell/ShellProtocol.c
@@ -2,7 +2,7 @@
Member functions of EFI_SHELL_PROTOCOL and functions for creation,
manipulation, and initialization of EFI_SHELL_PROTOCOL.
- Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -3336,8 +3336,8 @@ NotificationFunction(
IN EFI_KEY_DATA *KeyData
)
{
-// ShellPrintEx(-1,-1,L" <Notify> ");
- if ((KeyData->Key.UnicodeChar == L'c' || KeyData->Key.UnicodeChar == 3) &&
+ EFI_INPUT_KEY Key;
+ if ((KeyData->Key.UnicodeChar == L'c' || KeyData->Key.UnicodeChar == 3) &&
(KeyData->KeyState.KeyShiftState == (EFI_SHIFT_STATE_VALID|EFI_LEFT_CONTROL_PRESSED) || KeyData->KeyState.KeyShiftState == (EFI_SHIFT_STATE_VALID|EFI_RIGHT_CONTROL_PRESSED))
){
if (ShellInfoObject.NewEfiShellProtocol->ExecutionBreak == NULL) {
@@ -3348,6 +3348,12 @@ NotificationFunction(
(KeyData->KeyState.KeyShiftState == (EFI_SHIFT_STATE_VALID|EFI_LEFT_CONTROL_PRESSED) || KeyData->KeyState.KeyShiftState == (EFI_SHIFT_STATE_VALID|EFI_RIGHT_CONTROL_PRESSED))
){
ShellInfoObject.HaltOutput = TRUE;
+
+ //
+ // Make sure that there are no pending keystrokes to pervent the pause.
+ //
+ gST->ConIn->Reset(gST->ConIn, FALSE);
+ while (gST->ConIn->ReadKeyStroke (gST->ConIn, &Key)==EFI_SUCCESS);
}
return (EFI_SUCCESS);
}
diff --git a/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c
index 9e5164821..6e44bcec7 100644
--- a/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c
+++ b/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c
@@ -1,7 +1,7 @@
/** @file
Provides interface to advanced shell functionality for parsing both handle and protocol database.
- Copyright (c) 2010 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -13,6 +13,7 @@
**/
#include "UefiHandleParsingLib.h"
+#include "IndustryStandard/Acpi10.h"
EFI_HANDLE mHandleParsingHiiHandle;
HANDLE_INDEX_LIST mHandleList = {{{NULL,NULL},0,0},0};
@@ -161,6 +162,125 @@ LoadedImageProtocolDumpInformation(
*/
/**
+ Function to dump information about PciRootBridgeIo.
+
+ This will allocate the return buffer from boot services pool.
+
+ @param[in] TheHandle The handle that has PciRootBridgeIo installed.
+ @param[in] Verbose TRUE for additional information, FALSE otherwise.
+
+ @retval A poitner to a string containing the information.
+**/
+CHAR16*
+EFIAPI
+PciRootBridgeIoDumpInformation(
+ IN CONST EFI_HANDLE TheHandle,
+ IN CONST BOOLEAN Verbose
+ )
+{
+ EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *PciRootBridgeIo;
+ EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR *Configuration;
+ UINT64 Supports;
+ UINT64 Attributes;
+ CHAR16 *Temp;
+ CHAR16 *Temp2;
+ CHAR16 *RetVal;
+ EFI_STATUS Status;
+
+ RetVal = NULL;
+
+ if (!Verbose) {
+ return (CatSPrint(NULL, L"PciRootBridgeIo"));
+ }
+
+ Status = gBS->HandleProtocol(
+ TheHandle,
+ &gEfiPciRootBridgeIoProtocolGuid,
+ (VOID**)&PciRootBridgeIo);
+
+ if (EFI_ERROR(Status)) {
+ return NULL;
+ }
+
+ Temp = HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_PCIRB_DUMP_PH), NULL);
+ Temp2 = CatSPrint(L"\r\n", Temp, PciRootBridgeIo->ParentHandle);
+ FreePool(Temp);
+ RetVal = Temp2;
+ Temp2 = NULL;
+
+ Temp = HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_PCIRB_DUMP_SEG), NULL);
+ Temp2 = CatSPrint(RetVal, Temp, PciRootBridgeIo->SegmentNumber);
+ FreePool(Temp);
+ FreePool(RetVal);
+ RetVal = Temp2;
+ Temp2 = NULL;
+
+ Supports = 0;
+ Attributes = 0;
+ Status = PciRootBridgeIo->GetAttributes (PciRootBridgeIo, &Supports, &Attributes);
+ if (!EFI_ERROR(Status)) {
+ Temp = HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_PCIRB_DUMP_ATT), NULL);
+ Temp2 = CatSPrint(RetVal, Temp, Attributes);
+ FreePool(Temp);
+ FreePool(RetVal);
+ RetVal = Temp2;
+ Temp2 = NULL;
+
+ Temp = HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_PCIRB_DUMP_SUPPORTS), NULL);
+ Temp2 = CatSPrint(RetVal, Temp, Supports);
+ FreePool(Temp);
+ FreePool(RetVal);
+ RetVal = Temp2;
+ Temp2 = NULL;
+ }
+
+ Configuration = NULL;
+ Status = PciRootBridgeIo->Configuration (PciRootBridgeIo, (VOID **) &Configuration);
+ if (!EFI_ERROR(Status) && Configuration != NULL) {
+ Temp = HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_PCIRB_DUMP_TITLE), NULL);
+ Temp2 = CatSPrint(RetVal, Temp, Supports);
+ FreePool(Temp);
+ FreePool(RetVal);
+ RetVal = Temp2;
+ Temp2 = NULL;
+ while (Configuration->Desc == ACPI_ADDRESS_SPACE_DESCRIPTOR) {
+ Temp = NULL;
+ switch (Configuration->ResType) {
+ case ACPI_ADDRESS_SPACE_TYPE_MEM:
+ Temp = HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_PCIRB_DUMP_MEM), NULL);
+ break;
+ case ACPI_ADDRESS_SPACE_TYPE_IO:
+ Temp = HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_PCIRB_DUMP_IO), NULL);
+ break;
+ case ACPI_ADDRESS_SPACE_TYPE_BUS:
+ Temp = HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_PCIRB_DUMP_BUS), NULL);
+ break;
+ }
+ if (Temp != NULL) {
+ Temp2 = CatSPrint(RetVal, L"%s", Temp);
+ FreePool(Temp);
+ FreePool(RetVal);
+ RetVal = Temp2;
+ Temp2 = NULL;
+ }
+
+ Temp2 = CatSPrint(RetVal,
+ L"%H%02x %016lx %016lx %02x%N\r\n",
+ Configuration->SpecificFlag,
+ Configuration->AddrRangeMin,
+ Configuration->AddrRangeMax,
+ Configuration->AddrSpaceGranularity
+ );
+ FreePool(RetVal);
+ RetVal = Temp2;
+ Temp2 = NULL;
+ Configuration++;
+ }
+ }
+ return (RetVal);
+}
+
+/**
Function to dump information about SimpleTextOut.
This will allocate the return buffer from boot services pool.
@@ -333,14 +453,14 @@ STATIC CONST EFI_GUID WinNtThunkProtocolGuid = LOCAL_EFI_WIN_NT_THUNK_PROTOCOL_G
STATIC CONST EFI_GUID WinNtIoProtocolGuid = LOCAL_EFI_WIN_NT_BUS_DRIVER_IO_PROTOCOL_GUID;
STATIC CONST EFI_GUID WinNtSerialPortGuid = LOCAL_EFI_WIN_NT_SERIAL_PORT_GUID;
-STATIC CONST PROTOCOL_INFO_BLOCK mGuidStringListNT[] = {
+STATIC CONST GUID_INFO_BLOCK mGuidStringListNT[] = {
{STRING_TOKEN(STR_WINNT_THUNK), (EFI_GUID*)&WinNtThunkProtocolGuid, NULL},
{STRING_TOKEN(STR_WINNT_DRIVER_IO), (EFI_GUID*)&WinNtIoProtocolGuid, NULL},
{STRING_TOKEN(STR_WINNT_SERIAL_PORT), (EFI_GUID*)&WinNtSerialPortGuid, NULL},
{STRING_TOKEN(STR_UNKNOWN_DEVICE), NULL, NULL},
};
-STATIC CONST PROTOCOL_INFO_BLOCK mGuidStringList[] = {
+STATIC CONST GUID_INFO_BLOCK mGuidStringList[] = {
{STRING_TOKEN(STR_LOADED_IMAGE), &gEfiLoadedImageProtocolGuid, NULL},
{STRING_TOKEN(STR_DEVICE_PATH), &gEfiDevicePathProtocolGuid, DevicePathProtocolDumpInformation},
{STRING_TOKEN(STR_IMAGE_PATH), &gEfiLoadedImageDevicePathProtocolGuid, DevicePathProtocolDumpInformation},
@@ -376,14 +496,12 @@ STATIC CONST PROTOCOL_INFO_BLOCK mGuidStringList[] = {
{STRING_TOKEN(STR_LOAD_FILE), &gEfiLoadFileProtocolGuid, NULL},
{STRING_TOKEN(STR_LOAD_FILE2), &gEfiLoadFile2ProtocolGuid, NULL},
{STRING_TOKEN(STR_SIMPLE_FILE_SYS), &gEfiSimpleFileSystemProtocolGuid, NULL},
- {STRING_TOKEN(STR_FILE_INFO), &gEfiFileInfoGuid, NULL},
- {STRING_TOKEN(STR_FILE_SYS_INFO), &gEfiFileSystemInfoGuid, NULL},
{STRING_TOKEN(STR_TAPE_IO), &gEfiTapeIoProtocolGuid, NULL},
{STRING_TOKEN(STR_DISK_IO), &gEfiDiskIoProtocolGuid, NULL},
{STRING_TOKEN(STR_BLK_IO), &gEfiBlockIoProtocolGuid, NULL},
{STRING_TOKEN(STR_UC), &gEfiUnicodeCollationProtocolGuid, NULL},
{STRING_TOKEN(STR_UC2), &gEfiUnicodeCollation2ProtocolGuid, NULL},
- {STRING_TOKEN(STR_PCIRB_IO), &gEfiPciRootBridgeIoProtocolGuid, NULL},
+ {STRING_TOKEN(STR_PCIRB_IO), &gEfiPciRootBridgeIoProtocolGuid, PciRootBridgeIoDumpInformation},
{STRING_TOKEN(STR_PCI_IO), &gEfiPciIoProtocolGuid, NULL},
{STRING_TOKEN(STR_SCSI_PT), &gEfiScsiPassThruProtocolGuid, NULL},
{STRING_TOKEN(STR_SCSI_IO), &gEfiScsiIoProtocolGuid, NULL},
@@ -416,7 +534,6 @@ STATIC CONST PROTOCOL_INFO_BLOCK mGuidStringList[] = {
{STRING_TOKEN(STR_IPV4_CFG), &gEfiIp4ConfigProtocolGuid, NULL},
{STRING_TOKEN(STR_SHELL_PARAMETERS), &gEfiShellParametersProtocolGuid, NULL},
{STRING_TOKEN(STR_SHELL), &gEfiShellProtocolGuid, NULL},
- {STRING_TOKEN(STR_EFI_GLOBAL_VARIABLE), &gEfiGlobalVariableGuid, NULL},
{STRING_TOKEN(STR_UDPV4_SB), &gEfiUdp4ServiceBindingProtocolGuid, NULL},
{STRING_TOKEN(STR_UDPV4), &gEfiUdp4ProtocolGuid, NULL},
{STRING_TOKEN(STR_MTFTPV4_SB), &gEfiMtftp4ServiceBindingProtocolGuid, NULL},
@@ -431,6 +548,14 @@ STATIC CONST PROTOCOL_INFO_BLOCK mGuidStringList[] = {
{STRING_TOKEN(STR_HII_CONFIG_ROUT), &gEfiHiiConfigRoutingProtocolGuid, NULL},
{STRING_TOKEN(STR_HII_CONFIG_ACC), &gEfiHiiConfigAccessProtocolGuid, NULL},
{STRING_TOKEN(STR_HII_FORM_BROWSER2), &gEfiFormBrowser2ProtocolGuid, NULL},
+ {STRING_TOKEN(STR_DRIVER_FAM_OVERRIDE), &gEfiDriverFamilyOverrideProtocolGuid, NULL},
+ {STRING_TOKEN(STR_PCD), &gPcdProtocolGuid, NULL},
+ {STRING_TOKEN(STR_TCG), &gEfiTcgProtocolGuid, NULL},
+ {STRING_TOKEN(STR_HII_PACKAGE_LIST), &gEfiHiiPackageListProtocolGuid, NULL},
+
+//
+// the ones under this are deprecated by the current UEFI Spec, but may be found anyways...
+//
{STRING_TOKEN(STR_SHELL_INTERFACE), &gEfiShellInterfaceGuid, NULL},
{STRING_TOKEN(STR_SHELL_ENV2), &gEfiShellEnvironment2Guid, NULL},
{STRING_TOKEN(STR_SHELL_ENV), &gEfiShellEnvironment2Guid, NULL},
@@ -441,6 +566,62 @@ STATIC CONST PROTOCOL_INFO_BLOCK mGuidStringList[] = {
{STRING_TOKEN(STR_GPT_NBR), &gEfiPartTypeLegacyMbrGuid, NULL},
{STRING_TOKEN(STR_DRIVER_CONFIG), &gEfiDriverConfigurationProtocolGuid, NULL},
{STRING_TOKEN(STR_DRIVER_CONFIG2), &gEfiDriverConfiguration2ProtocolGuid, NULL},
+
+//
+// the ones under this are GUID identified structs, not protocols
+//
+ {STRING_TOKEN(STR_FILE_INFO), &gEfiFileInfoGuid, NULL},
+ {STRING_TOKEN(STR_FILE_SYS_INFO), &gEfiFileSystemInfoGuid, NULL},
+
+//
+// the ones under this are misc GUIDS.
+//
+ {STRING_TOKEN(STR_EFI_GLOBAL_VARIABLE), &gEfiGlobalVariableGuid, NULL},
+
+//
+// UEFI 2.2
+//
+ {STRING_TOKEN(STR_IP6_SB), &gEfiIp6ServiceBindingProtocolGuid, NULL},
+ {STRING_TOKEN(STR_IP6), &gEfiIp6ProtocolGuid, NULL},
+ {STRING_TOKEN(STR_IP6_CONFIG), &gEfiIp6ConfigProtocolGuid, NULL},
+ {STRING_TOKEN(STR_MTFTP6_SB), &gEfiMtftp6ServiceBindingProtocolGuid, NULL},
+ {STRING_TOKEN(STR_MTFTP6), &gEfiMtftp6ProtocolGuid, NULL},
+ {STRING_TOKEN(STR_DHCP6_SB), &gEfiDhcp6ServiceBindingProtocolGuid, NULL},
+ {STRING_TOKEN(STR_DHCP6), &gEfiDhcp6ProtocolGuid, NULL},
+ {STRING_TOKEN(STR_UDP6_SB), &gEfiUdp6ServiceBindingProtocolGuid, NULL},
+ {STRING_TOKEN(STR_UDP6), &gEfiUdp6ProtocolGuid, NULL},
+ {STRING_TOKEN(STR_TCP6_SB), &gEfiTcp6ServiceBindingProtocolGuid, NULL},
+ {STRING_TOKEN(STR_TCP6), &gEfiTcp6ProtocolGuid, NULL},
+ {STRING_TOKEN(STR_VLAN_CONFIG), &gEfiVlanConfigProtocolGuid, NULL},
+ {STRING_TOKEN(STR_EAP), &gEfiEapProtocolGuid, NULL},
+ {STRING_TOKEN(STR_EAP_MGMT), &gEfiEapManagementProtocolGuid, NULL},
+ {STRING_TOKEN(STR_FTP4_SB), &gEfiFtp4ServiceBindingProtocolGuid, NULL},
+ {STRING_TOKEN(STR_FTP4), &gEfiFtp4ProtocolGuid, NULL},
+ {STRING_TOKEN(STR_IP_SEC_CONFIG), &gEfiIpSecConfigProtocolGuid, NULL},
+ {STRING_TOKEN(STR_DH), &gEfiDriverHealthProtocolGuid, NULL},
+ {STRING_TOKEN(STR_DEF_IMG_LOAD), &gEfiDeferredImageLoadProtocolGuid, NULL},
+ {STRING_TOKEN(STR_USER_CRED), &gEfiUserCredentialProtocolGuid, NULL},
+ {STRING_TOKEN(STR_USER_MNGR), &gEfiUserManagerProtocolGuid, NULL},
+ {STRING_TOKEN(STR_ATA_PASS_THRU), &gEfiAtaPassThruProtocolGuid, NULL},
+
+//
+// UEFI 2.3
+//
+ {STRING_TOKEN(STR_FW_MGMT), &gEfiFirmwareManagementProtocolGuid, NULL},
+ {STRING_TOKEN(STR_IP_SEC), &gEfiIpSecProtocolGuid, NULL},
+ {STRING_TOKEN(STR_IP_SEC2), &gEfiIpSec2ProtocolGuid, NULL},
+
+//
+// UEFI 2.3.1
+//
+ {STRING_TOKEN(STR_KMS), &gEfiKmsProtocolGuid, NULL},
+ {STRING_TOKEN(STR_BLK_IO2), &gEfiBlockIo2ProtocolGuid, NULL},
+ {STRING_TOKEN(STR_SSC), &gEfiStorageSecurityCommandProtocolGuid, NULL},
+ {STRING_TOKEN(STR_UC2), &gEfiUserCredential2ProtocolGuid, NULL},
+
+//
+// terminator
+//
{STRING_TOKEN(STR_UNKNOWN_DEVICE), NULL, NULL},
};
@@ -453,13 +634,13 @@ STATIC CONST PROTOCOL_INFO_BLOCK mGuidStringList[] = {
@return The node.
**/
-CONST PROTOCOL_INFO_BLOCK *
+CONST GUID_INFO_BLOCK *
EFIAPI
InternalShellGetNodeFromGuid(
IN CONST EFI_GUID* Guid
)
{
- CONST PROTOCOL_INFO_BLOCK *ListWalker;
+ CONST GUID_INFO_BLOCK *ListWalker;
ASSERT(Guid != NULL);
@@ -496,7 +677,7 @@ GetStringNameFromGuid(
IN CONST CHAR8 *Lang OPTIONAL
)
{
- CONST PROTOCOL_INFO_BLOCK *Id;
+ CONST GUID_INFO_BLOCK *Id;
Id = InternalShellGetNodeFromGuid(Guid);
return (HiiGetString(mHandleParsingHiiHandle, Id->StringId, Lang));
@@ -526,7 +707,7 @@ GetProtocolInformationDump(
IN CONST BOOLEAN Verbose
)
{
- CONST PROTOCOL_INFO_BLOCK *Id;
+ CONST GUID_INFO_BLOCK *Id;
ASSERT(TheHandle != NULL);
ASSERT(Guid != NULL);
@@ -559,7 +740,7 @@ GetGuidFromStringName(
IN EFI_GUID **Guid
)
{
- CONST PROTOCOL_INFO_BLOCK *ListWalker;
+ CONST GUID_INFO_BLOCK *ListWalker;
CHAR16 *String;
ASSERT(Guid != NULL);
diff --git a/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h b/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h
index 39b2e6535..3b1ad2bac 100644
--- a/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h
+++ b/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h
@@ -1,7 +1,7 @@
/** @file
Provides interface to advanced shell functionality for parsing both handle and protocol database.
- Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2011 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -104,6 +104,32 @@
#include <Protocol/DevicePathUtilities.h>
//#include <Protocol/FirmwareVolume.h>
//#include <Protocol/FirmwareVolume2.h>
+#include <Protocol/DriverFamilyOverride.h>
+#include <Protocol/Pcd.h>
+#include <Protocol/TcgService.h>
+#include <Protocol/HiiPackageList.h>
+#include <Protocol/Ip6.h>
+#include <Protocol/Ip6Config.h>
+#include <Protocol/Mtftp6.h>
+#include <Protocol/Dhcp6.h>
+#include <Protocol/Udp6.h>
+#include <Protocol/Tcp6.h>
+#include <Protocol/VlanConfig.h>
+#include <Protocol/Eap.h>
+#include <Protocol/EapManagement.h>
+#include <Protocol/Ftp4.h>
+#include <Protocol/IpSecConfig.h>
+#include <Protocol/DriverHealth.h>
+#include <Protocol/DeferredImageLoad.h>
+#include <Protocol/UserCredential.h>
+#include <Protocol/UserManager.h>
+#include <Protocol/AtaPassThru.h>
+#include <Protocol/FirmwareManagement.h>
+#include <Protocol/IpSec.h>
+#include <Protocol/Kms.h>
+#include <Protocol/BlockIo2.h>
+#include <Protocol/StorageSecurityCommand.h>
+#include <Protocol/UserCredential2.h>
#include <Library/HandleParsingLib.h>
#include <Library/UefiBootServicesTableLib.h>
@@ -136,12 +162,11 @@ CHAR16 *
IN CONST BOOLEAN Verbose
);
-
-typedef struct {
+typedef struct _GUID_INFO_BLOCK{
EFI_STRING_ID StringId;
EFI_GUID *GuidId;
DUMP_PROTOCOL_INFO DumpInfo;
-} PROTOCOL_INFO_BLOCK;
+} GUID_INFO_BLOCK;
#endif
diff --git a/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf b/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf
index 46d918611..ddba0cfa1 100644
--- a/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf
+++ b/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf
@@ -1,6 +1,6 @@
## @file
# Provides interface to advanced shell functionality for parsing both handle and protocol database.
-# Copyright (c) 2010 - 2011, Intel Corporation. All rights reserved. <BR>
+# Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved. <BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
@@ -49,109 +49,142 @@
HiiLib
[Protocols]
- gEfiSimpleFileSystemProtocolGuid # ALWAYS_CONSUMED
+ gEfiSimpleFileSystemProtocolGuid ##CONSUMES
# shell 2.0
- gEfiShellProtocolGuid # SOMETIMES_CONSUMED
- gEfiShellParametersProtocolGuid # SOMETIMES_CONSUMED
+ gEfiShellProtocolGuid ##SOMETIMES_CONSUMED
+ gEfiShellParametersProtocolGuid ##SOMETIMES_CONSUMED
# 'old' shell
- gEfiShellEnvironment2Guid # SOMETIMES_CONSUMED
- gEfiShellInterfaceGuid # SOMETIMES_CONSUMED
+ gEfiShellEnvironment2Guid ##SOMETIMES_CONSUMED
+ gEfiShellInterfaceGuid ##SOMETIMES_CONSUMED
- gEfiUnicodeCollation2ProtocolGuid # ALWAYS_CONSUMED
- gEfiDevicePathToTextProtocolGuid # ALWAYS_CONSUMED
- gEfiBusSpecificDriverOverrideProtocolGuid # ALWAYS_CONSUMED
- gEfiDevicePathUtilitiesProtocolGuid # ALWAYS_CONSUMED
- gEfiDevicePathFromTextProtocolGuid # ALWAYS_CONSUMED
- gEfiPlatformDriverOverrideProtocolGuid # ALWAYS_CONSUMED
- gEfiSimpleTextInProtocolGuid # ALWAYS_CONSUMED
- gEfiPlatformToDriverConfigurationProtocolGuid # ALWAYS_CONSUMED
- gEfiDriverSupportedEfiVersionProtocolGuid # ALWAYS_CONSUMED
- gEfiLoadedImageProtocolGuid # ALWAYS_CONSUMED
- gEfiDevicePathProtocolGuid # ALWAYS_CONSUMED
- gEfiLoadedImageDevicePathProtocolGuid # ALWAYS_CONSUMED
- gEfiSimpleTextOutProtocolGuid
- gEfiSimplePointerProtocolGuid
- gEfiAbsolutePointerProtocolGuid
- gEfiSerialIoProtocolGuid
- gEfiEdidDiscoveredProtocolGuid
- gEfiEdidActiveProtocolGuid
- gEfiEdidOverrideProtocolGuid
- gEfiLoadFileProtocolGuid
- gEfiLoadFile2ProtocolGuid
- gEfiTapeIoProtocolGuid
- gEfiDiskIoProtocolGuid
- gEfiBlockIoProtocolGuid
- gEfiUnicodeCollationProtocolGuid
- gEfiPciRootBridgeIoProtocolGuid
- gEfiPciIoProtocolGuid
- gEfiScsiPassThruProtocolGuid
- gEfiScsiIoProtocolGuid
- gEfiExtScsiPassThruProtocolGuid
- gEfiIScsiInitiatorNameProtocolGuid
- gEfiUsbIoProtocolGuid
- gEfiUsbHcProtocolGuid
- gEfiUsb2HcProtocolGuid
- gEfiDebugSupportProtocolGuid
- gEfiDebugPortProtocolGuid
- gEfiDecompressProtocolGuid
- gEfiAcpiTableProtocolGuid
- gEfiEbcProtocolGuid
- gEfiSimpleNetworkProtocolGuid
- gEfiNetworkInterfaceIdentifierProtocolGuid
- gEfiNetworkInterfaceIdentifierProtocolGuid_31
- gEfiPxeBaseCodeProtocolGuid
- gEfiPxeBaseCodeCallbackProtocolGuid
- gEfiBisProtocolGuid
- gEfiManagedNetworkServiceBindingProtocolGuid
- gEfiManagedNetworkProtocolGuid
- gEfiArpServiceBindingProtocolGuid
- gEfiArpProtocolGuid
- gEfiDhcp4ServiceBindingProtocolGuid
- gEfiDhcp4ProtocolGuid
- gEfiTcp4ServiceBindingProtocolGuid
- gEfiTcp4ProtocolGuid
- gEfiIp4ServiceBindingProtocolGuid
- gEfiIp4ProtocolGuid
- gEfiIp4ConfigProtocolGuid
- gEfiUdp4ServiceBindingProtocolGuid
- gEfiUdp4ProtocolGuid
- gEfiMtftp4ServiceBindingProtocolGuid
- gEfiMtftp4ProtocolGuid
- gEfiAuthenticationInfoProtocolGuid
- gEfiHashServiceBindingProtocolGuid
- gEfiHashProtocolGuid
- gEfiHiiFontProtocolGuid
- gEfiHiiStringProtocolGuid
- gEfiHiiImageProtocolGuid
- gEfiHiiConfigRoutingProtocolGuid
- gEfiHiiConfigAccessProtocolGuid
- gEfiFormBrowser2ProtocolGuid
- gEfiDeviceIoProtocolGuid
- gEfiUgaDrawProtocolGuid
- gEfiUgaIoProtocolGuid
- gEfiDriverConfigurationProtocolGuid
- gEfiDriverConfiguration2ProtocolGuid
- gEfiSimpleTextInputExProtocolGuid
+ gEfiUnicodeCollation2ProtocolGuid ##CONSUMES
+ gEfiDevicePathToTextProtocolGuid ##CONSUMES
+ gEfiBusSpecificDriverOverrideProtocolGuid ##CONSUMES
+ gEfiDevicePathUtilitiesProtocolGuid ##CONSUMES
+ gEfiDevicePathFromTextProtocolGuid ##CONSUMES
+ gEfiPlatformDriverOverrideProtocolGuid ##CONSUMES
+ gEfiSimpleTextInProtocolGuid ##CONSUMES
+ gEfiPlatformToDriverConfigurationProtocolGuid ##CONSUMES
+ gEfiDriverSupportedEfiVersionProtocolGuid ##CONSUMES
+ gEfiLoadedImageProtocolGuid ##CONSUMES
+ gEfiDevicePathProtocolGuid ##CONSUMES
+ gEfiLoadedImageDevicePathProtocolGuid ##CONSUMES
+ gEfiSimpleTextOutProtocolGuid ##UNDEFINED
+ gEfiSimplePointerProtocolGuid ##UNDEFINED
+ gEfiAbsolutePointerProtocolGuid ##UNDEFINED
+ gEfiSerialIoProtocolGuid ##UNDEFINED
+ gEfiEdidDiscoveredProtocolGuid ##UNDEFINED
+ gEfiEdidActiveProtocolGuid ##UNDEFINED
+ gEfiEdidOverrideProtocolGuid ##UNDEFINED
+ gEfiLoadFileProtocolGuid ##UNDEFINED
+ gEfiLoadFile2ProtocolGuid ##UNDEFINED
+ gEfiTapeIoProtocolGuid ##UNDEFINED
+ gEfiDiskIoProtocolGuid ##UNDEFINED
+ gEfiBlockIoProtocolGuid ##UNDEFINED
+ gEfiUnicodeCollationProtocolGuid ##UNDEFINED
+ gEfiPciRootBridgeIoProtocolGuid ##UNDEFINED
+ gEfiPciIoProtocolGuid ##UNDEFINED
+ gEfiScsiPassThruProtocolGuid ##UNDEFINED
+ gEfiScsiIoProtocolGuid ##UNDEFINED
+ gEfiExtScsiPassThruProtocolGuid ##UNDEFINED
+ gEfiIScsiInitiatorNameProtocolGuid ##UNDEFINED
+ gEfiUsbIoProtocolGuid ##UNDEFINED
+ gEfiUsbHcProtocolGuid ##UNDEFINED
+ gEfiUsb2HcProtocolGuid ##UNDEFINED
+ gEfiDebugSupportProtocolGuid ##UNDEFINED
+ gEfiDebugPortProtocolGuid ##UNDEFINED
+ gEfiDecompressProtocolGuid ##UNDEFINED
+ gEfiAcpiTableProtocolGuid ##UNDEFINED
+ gEfiEbcProtocolGuid ##UNDEFINED
+ gEfiSimpleNetworkProtocolGuid ##UNDEFINED
+ gEfiNetworkInterfaceIdentifierProtocolGuid ##UNDEFINED
+ gEfiNetworkInterfaceIdentifierProtocolGuid_31 ##UNDEFINED
+ gEfiPxeBaseCodeProtocolGuid ##UNDEFINED
+ gEfiPxeBaseCodeCallbackProtocolGuid ##UNDEFINED
+ gEfiBisProtocolGuid ##UNDEFINED
+ gEfiManagedNetworkServiceBindingProtocolGuid ##UNDEFINED
+ gEfiManagedNetworkProtocolGuid ##UNDEFINED
+ gEfiArpServiceBindingProtocolGuid ##UNDEFINED
+ gEfiArpProtocolGuid ##UNDEFINED
+ gEfiDhcp4ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiDhcp4ProtocolGuid ##UNDEFINED
+ gEfiTcp4ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiTcp4ProtocolGuid ##UNDEFINED
+ gEfiIp4ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiIp4ProtocolGuid ##UNDEFINED
+ gEfiIp4ConfigProtocolGuid ##UNDEFINED
+ gEfiUdp4ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiUdp4ProtocolGuid ##UNDEFINED
+ gEfiMtftp4ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiMtftp4ProtocolGuid ##UNDEFINED
+ gEfiAuthenticationInfoProtocolGuid ##UNDEFINED
+ gEfiHashServiceBindingProtocolGuid ##UNDEFINED
+ gEfiHashProtocolGuid ##UNDEFINED
+ gEfiHiiFontProtocolGuid ##UNDEFINED
+ gEfiHiiStringProtocolGuid ##UNDEFINED
+ gEfiHiiImageProtocolGuid ##UNDEFINED
+ gEfiHiiConfigRoutingProtocolGuid ##UNDEFINED
+ gEfiHiiConfigAccessProtocolGuid ##UNDEFINED
+ gEfiFormBrowser2ProtocolGuid ##UNDEFINED
+ gEfiDeviceIoProtocolGuid ##UNDEFINED
+ gEfiUgaDrawProtocolGuid ##UNDEFINED
+ gEfiUgaIoProtocolGuid ##UNDEFINED
+ gEfiDriverConfigurationProtocolGuid ##UNDEFINED
+ gEfiDriverConfiguration2ProtocolGuid ##UNDEFINED
+ gEfiSimpleTextInputExProtocolGuid ##UNDEFINED
+ gEfiIp6ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiIp6ProtocolGuid ##UNDEFINED
+ gEfiIp6ConfigProtocolGuid ##UNDEFINED
+ gEfiMtftp6ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiMtftp6ProtocolGuid ##UNDEFINED
+ gEfiDhcp6ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiDhcp6ProtocolGuid ##UNDEFINED
+ gEfiUdp6ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiUdp6ProtocolGuid ##UNDEFINED
+ gEfiTcp6ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiTcp6ProtocolGuid ##UNDEFINED
+ gEfiVlanConfigProtocolGuid ##UNDEFINED
+ gEfiEapProtocolGuid ##UNDEFINED
+ gEfiEapManagementProtocolGuid ##UNDEFINED
+ gEfiFtp4ServiceBindingProtocolGuid ##UNDEFINED
+ gEfiFtp4ProtocolGuid ##UNDEFINED
+ gEfiIpSecConfigProtocolGuid ##UNDEFINED
+ gEfiDriverHealthProtocolGuid ##UNDEFINED
+ gEfiDeferredImageLoadProtocolGuid ##UNDEFINED
+ gEfiUserCredentialProtocolGuid ##UNDEFINED
+ gEfiUserManagerProtocolGuid ##UNDEFINED
+ gEfiAtaPassThruProtocolGuid ##UNDEFINED
+ gEfiFirmwareManagementProtocolGuid ##UNDEFINED
+ gEfiIpSecProtocolGuid ##UNDEFINED
+ gEfiIpSec2ProtocolGuid ##UNDEFINED
+ gEfiKmsProtocolGuid ##UNDEFINED
+ gEfiBlockIo2ProtocolGuid ##UNDEFINED
+ gEfiStorageSecurityCommandProtocolGuid ##UNDEFINED
+ gEfiUserCredential2ProtocolGuid ##UNDEFINED
+ gPcdProtocolGuid ##UNDEFINED
+ gEfiTcgProtocolGuid ##UNDEFINED
+ gEfiHiiPackageListProtocolGuid ##UNDEFINED
+ gEfiDriverFamilyOverrideProtocolGuid ##UNDEFINED
[Guids]
- gEfiFileInfoGuid # ALWAYS_CONSUMED
- gEfiShellEnvironment2ExtGuid # ALWAYS_CONSUMED
- gEfiPcAnsiGuid
- gEfiVT100Guid
- gEfiVT100PlusGuid
- gEfiVTUTF8Guid
- gEfiStandardErrorDeviceGuid
- gEfiConsoleInDeviceGuid
- gEfiConsoleOutDeviceGuid
- gEfiFileSystemInfoGuid
- gEfiGlobalVariableGuid
- gEfiPartTypeSystemPartGuid
- gEfiPartTypeLegacyMbrGuid
- gHandleParsingHiiGuid
+ gEfiFileInfoGuid ##CONSUMES
+ gEfiShellEnvironment2ExtGuid ##CONSUMES
+ gEfiPcAnsiGuid ##UNDEFINED
+ gEfiVT100Guid ##UNDEFINED
+ gEfiVT100PlusGuid ##UNDEFINED
+ gEfiVTUTF8Guid ##UNDEFINED
+ gEfiStandardErrorDeviceGuid ##UNDEFINED
+ gEfiConsoleInDeviceGuid ##UNDEFINED
+ gEfiConsoleOutDeviceGuid ##UNDEFINED
+ gEfiFileSystemInfoGuid ##UNDEFINED
+ gEfiGlobalVariableGuid ##UNDEFINED
+ gEfiPartTypeSystemPartGuid ##UNDEFINED
+ gEfiPartTypeLegacyMbrGuid ##UNDEFINED
+ gHandleParsingHiiGuid ##UNDEFINED
[Pcd.common]
- gEfiShellPkgTokenSpaceGuid.PcdShellLibAutoInitialize # ALWAYS_CONSUMED
- gEfiShellPkgTokenSpaceGuid.PcdShellPrintBufferSize # ALWAYS_CONSUMED
- gEfiShellPkgTokenSpaceGuid.PcdShellIncludeNtGuids # ALWAYS_CONSUMED \ No newline at end of file
+ gEfiShellPkgTokenSpaceGuid.PcdShellLibAutoInitialize ##CONSUMES
+ gEfiShellPkgTokenSpaceGuid.PcdShellPrintBufferSize ##CONSUMES
+ gEfiShellPkgTokenSpaceGuid.PcdShellIncludeNtGuids ##CONSUMES \ No newline at end of file
diff --git a/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni b/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni
index 0ce6935b9..6a9074eaf 100644
--- a/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni
+++ b/edk2/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni
Binary files differ
diff --git a/edk2/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c b/edk2/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c
index 852ba1d1e..1b42b23ad 100644
--- a/edk2/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c
+++ b/edk2/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c
@@ -202,7 +202,7 @@ GetProtocolInfoString(
if (!Verbose) {
StrnCatGrow(&RetVal, &Size, L"(", 0);
StrnCatGrow(&RetVal, &Size, Temp, 0);
- StrnCatGrow(&RetVal, &Size, L")", 0);
+ StrnCatGrow(&RetVal, &Size, L")\r\n", 0);
} else {
StrnCatGrow(&RetVal, &Size, Seperator, 0);
StrnCatGrow(&RetVal, &Size, Temp, 0);
@@ -728,6 +728,7 @@ DoDhByHandle(
Display information for all handles on a list.
@param[in] HandleList The NULL-terminated list of handles.
+ @param[in] Verbose TRUE for extra info, FALSE otherwise.
@param[in] Sfo TRUE to output in standard format output (spec).
@param[in] Language Language string per UEFI specification.
@param[in] DriverInfo TRUE to show all info about the handle.
@@ -739,6 +740,7 @@ SHELL_STATUS
EFIAPI
DoDhForHandleList(
IN CONST EFI_HANDLE *HandleList,
+ IN CONST BOOLEAN Verbose,
IN CONST BOOLEAN Sfo,
IN CONST CHAR8 *Language,
IN CONST BOOLEAN DriverInfo
@@ -752,7 +754,7 @@ DoDhForHandleList(
for (HandleWalker = HandleList ; HandleWalker != NULL && *HandleWalker != NULL && ShellStatus == SHELL_SUCCESS; HandleWalker++) {
ShellStatus = DoDhByHandle(
*HandleWalker,
- FALSE,
+ Verbose,
Sfo,
Language,
DriverInfo,
@@ -766,6 +768,7 @@ DoDhForHandleList(
Display information for all handles.
@param[in] Sfo TRUE to output in standard format output (spec).
+ @param[in] Verbose TRUE for extra info, FALSE otherwise.
@param[in] Language Language string per UEFI specification.
@param[in] DriverInfo TRUE to show all info about the handle.
@@ -776,6 +779,7 @@ SHELL_STATUS
EFIAPI
DoDhForAll(
IN CONST BOOLEAN Sfo,
+ IN CONST BOOLEAN Verbose,
IN CONST CHAR8 *Language,
IN CONST BOOLEAN DriverInfo
)
@@ -787,6 +791,7 @@ DoDhForAll(
ShellStatus = DoDhForHandleList(
HandleList,
+ Verbose,
Sfo,
Language,
DriverInfo);
@@ -800,6 +805,7 @@ DoDhForAll(
Display information for all handles which have a specific protocol.
@param[in] ProtocolName The pointer to the name of the protocol.
+ @param[in] Verbose TRUE for extra info, FALSE otherwise.
@param[in] Sfo TRUE to output in standard format output (spec).
@param[in] Language Language string per UEFI specification.
@param[in] DriverInfo TRUE to show all info about the handle.
@@ -811,6 +817,7 @@ SHELL_STATUS
EFIAPI
DoDhByProtocol(
IN CONST CHAR16 *ProtocolName,
+ IN CONST BOOLEAN Verbose,
IN CONST BOOLEAN Sfo,
IN CONST CHAR8 *Language,
IN CONST BOOLEAN DriverInfo
@@ -835,6 +842,7 @@ DoDhByProtocol(
ShellStatus = DoDhForHandleList(
HandleList,
+ Verbose,
Sfo,
Language,
DriverInfo);
@@ -932,6 +940,7 @@ ShellCommandRunDh (
//
ShellStatus = DoDhByProtocol(
ShellCommandLineGetValue(Package, L"-p"),
+ Verbose,
SfoMode,
Lang==NULL?NULL:Language,
FlagD
@@ -945,6 +954,7 @@ ShellCommandRunDh (
//
ShellStatus = DoDhForAll(
SfoMode,
+ Verbose,
Lang==NULL?NULL:Language,
FlagD
);
diff --git a/edk2/ShellPkg/Library/UefiShellLevel1CommandsLib/For.c b/edk2/ShellPkg/Library/UefiShellLevel1CommandsLib/For.c
index 7d91d2348..b01c69d3d 100644
--- a/edk2/ShellPkg/Library/UefiShellLevel1CommandsLib/For.c
+++ b/edk2/ShellPkg/Library/UefiShellLevel1CommandsLib/For.c
@@ -1,7 +1,7 @@
/** @file
Main file for endfor and for shell level 1 functions.
- Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -425,6 +425,7 @@ ShellCommandRunFor (
//
Info = AllocateZeroPool(sizeof(SHELL_FOR_INFO)+StrSize(gEfiShellParametersProtocol->Argv[1]));
ASSERT(Info != NULL);
+ Info->Signature = SHELL_FOR_INFO_SIGNATURE;
CopyMem(Info->Set, gEfiShellParametersProtocol->Argv[1], StrSize(gEfiShellParametersProtocol->Argv[1]));
Info->ReplacementName = Info->Set;
Info->CurrentValue = NULL;
@@ -659,12 +660,9 @@ ShellCommandRunFor (
//
ASSERT(Info->Set != NULL);
if (Info->CurrentValue != NULL && *Info->CurrentValue != CHAR_NULL) {
- if (Info->CurrentValue[0] == L'\"') {
+ if (Info->CurrentValue[0] == L' ') {
Info->CurrentValue++;
}
-// while (Info->CurrentValue[0] == L' ') {
-// Info->CurrentValue++;
-// }
if (Info->CurrentValue[0] == L'\"') {
Info->CurrentValue++;
}
diff --git a/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Ls.c b/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Ls.c
index a93b54c42..379934142 100644
--- a/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Ls.c
+++ b/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Ls.c
@@ -1,7 +1,7 @@
/** @file
Main file for ls shell level 2 function.
- Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -354,9 +354,14 @@ PrintLsOutput(
ShellStatus = SHELL_OUT_OF_RESOURCES;
} else {
for ( Node = (EFI_SHELL_FILE_INFO *)GetFirstNode(&ListHead->Link)
- ; !IsNull(&ListHead->Link, &Node->Link)
+ ; !IsNull(&ListHead->Link, &Node->Link) && ShellStatus == SHELL_SUCCESS
; Node = (EFI_SHELL_FILE_INFO *)GetNextNode(&ListHead->Link, &Node->Link)
){
+ if (ShellGetExecutionBreakFlag ()) {
+ ShellStatus = SHELL_ABORTED;
+ break;
+ }
+
//
// recurse on any directory except the traversing ones...
//
@@ -366,7 +371,7 @@ PrintLsOutput(
){
StrCpy(DirectoryName, Node->FullName);
StrCat(DirectoryName, L"\\*");
- PrintLsOutput(
+ ShellStatus = PrintLsOutput(
Rec,
Attribs,
Sfo,
@@ -558,6 +563,10 @@ ShellCommandRunLs (
ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_NO_FILES), gShellLevel2HiiHandle);
} else if (ShellStatus == SHELL_INVALID_PARAMETER) {
ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_PARAM_INV), gShellLevel2HiiHandle);
+ } else if (ShellStatus == SHELL_ABORTED) {
+ //
+ // Ignore aborting.
+ //
} else if (ShellStatus != SHELL_SUCCESS) {
ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_PARAM_INV), gShellLevel2HiiHandle);
}
diff --git a/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Parse.c b/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Parse.c
index 1cdc9e32e..4072b9469 100644
--- a/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Parse.c
+++ b/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Parse.c
@@ -1,7 +1,7 @@
/** @file
Main file for Parse shell level 2 function.
- Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -91,22 +91,26 @@ PerformParsing(
}
}
if (ColumnLoop == ColumnIndex) {
- ASSERT(ColumnPointer != NULL);
- TempSpot = StrStr(ColumnPointer, L",");
- if (TempSpot != NULL) {
- *TempSpot = CHAR_NULL;
+ if (ColumnPointer == NULL) {
+ ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_PROBLEM_VAL), gShellLevel2HiiHandle, L"Column Index");
+ ShellStatus = SHELL_INVALID_PARAMETER;
+ } else {
+ TempSpot = StrStr(ColumnPointer, L",");
+ if (TempSpot != NULL) {
+ *TempSpot = CHAR_NULL;
+ }
+ while (ColumnPointer != NULL && *ColumnPointer != CHAR_NULL && ColumnPointer[0] == L' '){
+ ColumnPointer++;
+ }
+ if (ColumnPointer != NULL && *ColumnPointer != CHAR_NULL && ColumnPointer[0] == L'\"'){
+ ColumnPointer++;
+ }
+ if (ColumnPointer != NULL && *ColumnPointer != CHAR_NULL && ColumnPointer[StrLen(ColumnPointer)-1] == L'\"'){
+ ColumnPointer[StrLen(ColumnPointer)-1] = CHAR_NULL;
+ }
+
+ ShellPrintEx(-1, -1, L"%s\r\n", ColumnPointer);
}
- while (ColumnPointer != NULL && *ColumnPointer != CHAR_NULL && ColumnPointer[0] == L' '){
- ColumnPointer++;
- }
- if (ColumnPointer != NULL && *ColumnPointer != CHAR_NULL && ColumnPointer[0] == L'\"'){
- ColumnPointer++;
- }
- if (ColumnPointer != NULL && *ColumnPointer != CHAR_NULL && ColumnPointer[StrLen(ColumnPointer)-1] == L'\"'){
- ColumnPointer[StrLen(ColumnPointer)-1] = CHAR_NULL;
- }
-
- ShellPrintEx(-1, -1, L"%s\r\n", ColumnPointer);
}
}
SHELL_FREE_NON_NULL(TempLine);
diff --git a/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c b/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c
index f69a79b71..ff9c9d691 100644
--- a/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c
+++ b/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c
@@ -1,7 +1,7 @@
/** @file
Main file for attrib shell level 2 function.
- Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -81,9 +81,9 @@ ShellCommandRunReset (
} else {
String = ShellCommandLineGetValue(Package, L"-w");
if (String != NULL) {
- gRT->ResetSystem(EfiResetCold, EFI_SUCCESS, StrSize(String), (VOID*)String);
+ gRT->ResetSystem(EfiResetWarm, EFI_SUCCESS, StrSize(String), (VOID*)String);
} else {
- gRT->ResetSystem(EfiResetCold, EFI_SUCCESS, 0, NULL);
+ gRT->ResetSystem(EfiResetWarm, EFI_SUCCESS, 0, NULL);
}
}
} else if (ShellCommandLineGetFlag(Package, L"-s")) {
@@ -105,9 +105,9 @@ ShellCommandRunReset (
//
String = ShellCommandLineGetValue(Package, L"-c");
if (String != NULL) {
- gRT->ResetSystem(EfiResetWarm, EFI_SUCCESS, StrSize(String), (VOID*)String);
+ gRT->ResetSystem(EfiResetCold, EFI_SUCCESS, StrSize(String), (VOID*)String);
} else {
- gRT->ResetSystem(EfiResetWarm, EFI_SUCCESS, 0, NULL);
+ gRT->ResetSystem(EfiResetCold, EFI_SUCCESS, 0, NULL);
}
}
}
diff --git a/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c b/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c
index 32b758010..d167b36fb 100644
--- a/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c
+++ b/edk2/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c
@@ -1,7 +1,7 @@
/** @file
Main file for attrib shell level 2 function.
- Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -202,7 +202,10 @@ IsValidDeleteTarget(
Size = 0;
Pattern = StrnCatGrow(&Pattern , NULL, TempLocation , 0);
SearchString = StrnCatGrow(&SearchString, &Size, Node->FullName, 0);
- SearchString = StrnCatGrow(&SearchString, &Size, L"*", 0);
+ if (!EFI_ERROR(ShellIsDirectory(SearchString))) {
+ SearchString = StrnCatGrow(&SearchString, &Size, L"\\", 0);
+ SearchString = StrnCatGrow(&SearchString, &Size, L"*", 0);
+ }
if (Pattern == NULL || SearchString == NULL) {
RetVal = FALSE;
diff --git a/edk2/ShellPkg/Library/UefiShellLib/UefiShellLib.c b/edk2/ShellPkg/Library/UefiShellLib/UefiShellLib.c
index 77cf5e779..74f1cd3ba 100644
--- a/edk2/ShellPkg/Library/UefiShellLib/UefiShellLib.c
+++ b/edk2/ShellPkg/Library/UefiShellLib/UefiShellLib.c
@@ -2587,10 +2587,12 @@ InternalPrintTo (
return (gEfiShellProtocol->WriteFile(gEfiShellParametersProtocol->StdOut, &Size, (VOID*)String));
}
if (mEfiShellInterface != NULL) {
- //
- // Divide in half for old shell. Must be string length not size.
- //
- Size /= 2;
+ if (mEfiShellInterface->RedirArgc == 0) {
+ //
+ // Divide in half for old shell. Must be string length not size.
+ //
+ Size /=2; // Divide in half only when no redirection.
+ }
return (mEfiShellInterface->StdOut->Write(mEfiShellInterface->StdOut, &Size, (VOID*)String));
}
ASSERT(FALSE);
diff --git a/edk2/ShellPkg/Readme.txt b/edk2/ShellPkg/Readme.txt
index 945d30a2a..77841c0a2 100644
--- a/edk2/ShellPkg/Readme.txt
+++ b/edk2/ShellPkg/Readme.txt
@@ -25,10 +25,5 @@ developer may integrate this code into an existing platform:
5. Build NT32
-============================================================================
- KNOWN LIMITATIONS
-============================================================================
-1. Redirecting StdErr is not completely functional.
-2. CTRL-C is not functional.
============================================================================
diff --git a/edk2/ShellPkg/ShellPkg.dec b/edk2/ShellPkg/ShellPkg.dec
index a96e60677..4a29f4afb 100644
--- a/edk2/ShellPkg/ShellPkg.dec
+++ b/edk2/ShellPkg/ShellPkg.dec
@@ -18,7 +18,7 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = ShellPkg
PACKAGE_GUID = 9FB7587C-93F7-40a7-9C04-FD7BA94EE646
- PACKAGE_VERSION = 0.40
+ PACKAGE_VERSION = 0.50
[Includes]
Include
@@ -41,7 +41,7 @@
## @libraryclass Provides advanced parsing functions
HandleParsingLib|Include/Library/HandleParsingLib.h
-
+
## @libraryclass Provides path manipulation functions
PathLib|Include/Library/PathLib.h
@@ -59,7 +59,7 @@
gShellLevel2HiiGuid = {0xf95a7ccc, 0x4c55, 0x4426, {0xa7, 0xb4, 0xdc, 0x89, 0x61, 0x95, 0xb, 0xae}}
gShellLevel3HiiGuid = {0x4344558d, 0x4ef9, 0x4725, {0xb1, 0xe4, 0x33, 0x76, 0xe8, 0xd6, 0x97, 0x4f}}
gShellNetwork1HiiGuid = {0xf3d301bb, 0xf4a5, 0x45a8, {0xb0, 0xb7, 0xfa, 0x99, 0x9c, 0x62, 0x37, 0xae}}
-
+
[Protocols]
gEfiShellProtocolGuid = {0x6302d008, 0x7f9b, 0x4f30, {0x87, 0xac, 0x60, 0xc9, 0xfe, 0xf5, 0xda, 0x4e}}
gEfiShellParametersProtocolGuid = {0x752f3136, 0x4e16, 0x4fdc, {0xa2, 0x2a, 0xe5, 0xf4, 0x68, 0x12, 0xf4, 0xca}}
@@ -76,7 +76,7 @@
## This flag is used to control HII required by the shell
gEfiShellPkgTokenSpaceGuid.PcdShellSupportFrameworkHii|FALSE|BOOLEAN|0x00000004
-
+
## This flag forces the shell to present a user console. Allows for earlier debugging of platforms.
gEfiShellPkgTokenSpaceGuid.PcdShellForceConsole|FALSE|BOOLEAN|0x0000000F
diff --git a/edk2/SourceLevelDebugPkg/Readme.txt b/edk2/SourceLevelDebugPkg/Readme.txt
index a1a2ffe18..7dcd6d538 100644
--- a/edk2/SourceLevelDebugPkg/Readme.txt
+++ b/edk2/SourceLevelDebugPkg/Readme.txt
@@ -1,16 +1,14 @@
-UDK based firmware on UEFI IA-32 and UEFI x64 platforms may be debugged using
-Microsoft(R) Debugging Tools for Windows(R) (WinDbg). Debug capability is enabled
-with SourceLevelDebugPkg in conjunction with the Intel(R) UEFI Development Kit
-Debugger Tool (Intel(R) UDK Debugger Tool).
+UDK based firmware on UEFI IA-32 and UEFI x64 platforms can be debugged with
+SourceLevelDebugPkg in conjunction with Intel(R) UEFI Development Kit Debugger
+Tool (Intel (R) UDK Debugger Tool).
-The Intel(R) UDK Debugger Tool and its detailed user manual may be obtained from:
-http://www.intel.com/technology/efi.
+The Intel(R) UDK Debugger Tool and its detailed user manual can be obtained
+from: http://www.intel.com/technology/efi.
-NOTE: In addition to the known issues listed in the user manual, the following
+NOTE: In addition to the known issues listed in the user manual, the following
anomalies have been observed:
-1) When using a USB debug cable, after the TARGET completes a reset during memory
- initialization, the connection between the HOST and the TARGET may be lost
- (e.g. WinDbg reports busy status and does not respond to a break request). A
- work around for this issue is to unplug the USB debug cable and then plug the
- cable back in. A new debug session may then be started.
+1) When using a USB debug cable, after the TARGET completes a reset during
+ memory initialization, the connection between the HOST and the TARGET may be
+ lost. A work around for this issue is to unplug the USB debug cable and then
+ plug the cable back in. A new debug session can then be started.
diff --git a/edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dec b/edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dec
index 798c0672c..50f98cc4f 100644
--- a/edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dec
+++ b/edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dec
@@ -7,7 +7,7 @@
# and host, PeCoffExtraActionLib instance to report symbol path information,
# etc.
#
-# Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2010 - 2011, Intel Corporation. All rights reserved.<BR>
# This program and the accompanying materials are licensed and made available under
# the terms and conditions of the BSD License that accompanies this distribution.
# The full text of the license may be found at
@@ -22,7 +22,7 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = SourceLevelDebugtPkg
PACKAGE_GUID = DBF00C27-D8D7-443d-918B-4E85CDA1373B
- PACKAGE_VERSION = 0.70
+ PACKAGE_VERSION = 0.71
[Includes]
Include
diff --git a/edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dsc b/edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dsc
index a54cff517..0833e6304 100644
--- a/edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dsc
+++ b/edk2/SourceLevelDebugPkg/SourceLevelDebugPkg.dsc
@@ -22,7 +22,7 @@
[Defines]
PLATFORM_NAME = SourceLevelDebugtPkg
PLATFORM_GUID = 38C85805-883F-4ee8-A854-95B966ED73AA
- PLATFORM_VERSION = 0.70
+ PLATFORM_VERSION = 0.71
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/SourceLevelDebugtPkg
SUPPORTED_ARCHITECTURES = IA32|X64
diff --git a/edk2/StdLib/Include/netinet/tcp.h b/edk2/StdLib/Include/netinet/tcp.h
new file mode 100644
index 000000000..8bb8f61ec
--- /dev/null
+++ b/edk2/StdLib/Include/netinet/tcp.h
@@ -0,0 +1,132 @@
+/* $NetBSD: tcp.h,v 1.28 2007/12/25 18:33:47 perry Exp $ */
+
+/*
+ * Copyright (c) 1982, 1986, 1993
+ * The Regents of the University of California. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * @(#)tcp.h 8.1 (Berkeley) 6/10/93
+ */
+
+#ifndef _NETINET_TCP_H_
+#define _NETINET_TCP_H_
+
+#include <sys/featuretest.h>
+
+#if defined(_NETBSD_SOURCE)
+
+typedef u_int32_t tcp_seq;
+/*
+ * TCP header.
+ * Per RFC 793, September, 1981.
+ * Updated by RFC 3168, September, 2001.
+ */
+struct tcphdr {
+ u_int16_t th_sport; /* source port */
+ u_int16_t th_dport; /* destination port */
+ tcp_seq th_seq; /* sequence number */
+ tcp_seq th_ack; /* acknowledgement number */
+#if BYTE_ORDER == LITTLE_ENDIAN
+ /*LINTED non-portable bitfields*/
+ u_int8_t th_x2:4, /* (unused) */
+ th_off:4; /* data offset */
+#endif
+#if BYTE_ORDER == BIG_ENDIAN
+ /*LINTED non-portable bitfields*/
+ u_int8_t th_off:4, /* data offset */
+ th_x2:4; /* (unused) */
+#endif
+ u_int8_t th_flags;
+#define TH_FIN 0x01
+#define TH_SYN 0x02
+#define TH_RST 0x04
+#define TH_PUSH 0x08
+#define TH_ACK 0x10
+#define TH_URG 0x20
+#define TH_ECE 0x40
+#define TH_CWR 0x80
+ u_int16_t th_win; /* window */
+ u_int16_t th_sum; /* checksum */
+ u_int16_t th_urp; /* urgent pointer */
+} __packed;
+
+#define TCPOPT_EOL 0
+#define TCPOPT_NOP 1
+#define TCPOPT_MAXSEG 2
+#define TCPOLEN_MAXSEG 4
+#define TCPOPT_WINDOW 3
+#define TCPOLEN_WINDOW 3
+#define TCPOPT_SACK_PERMITTED 4 /* Experimental */
+#define TCPOLEN_SACK_PERMITTED 2
+#define TCPOPT_SACK 5 /* Experimental */
+#define TCPOPT_TIMESTAMP 8
+#define TCPOLEN_TIMESTAMP 10
+#define TCPOLEN_TSTAMP_APPA (TCPOLEN_TIMESTAMP+2) /* appendix A */
+
+#define TCPOPT_TSTAMP_HDR \
+ (TCPOPT_NOP<<24|TCPOPT_NOP<<16|TCPOPT_TIMESTAMP<<8|TCPOLEN_TIMESTAMP)
+
+#define TCPOPT_SIGNATURE 19 /* Keyed MD5: RFC 2385 */
+#define TCPOLEN_SIGNATURE 18
+#define TCPOLEN_SIGLEN (TCPOLEN_SIGNATURE+2) /* padding */
+
+#define MAX_TCPOPTLEN 40 /* max # bytes that go in options */
+
+/*
+ * Default maximum segment size for TCP.
+ * This is defined by RFC 1112 Sec 4.2.2.6.
+ */
+#define TCP_MSS 536
+
+#define TCP_MINMSS 216
+
+#define TCP_MAXWIN 65535 /* largest value for (unscaled) window */
+
+#define TCP_MAX_WINSHIFT 14 /* maximum window shift */
+
+#define TCP_MAXBURST 4 /* maximum segments in a burst */
+
+#endif /* _NETBSD_SOURCE */
+
+/*
+ * User-settable options (used with setsockopt).
+ */
+#define TCP_NODELAY 1 /* don't delay send to coalesce packets */
+#define TCP_MAXSEG 2 /* set maximum segment size */
+#define TCP_KEEPIDLE 3
+#ifdef notyet
+#define TCP_NOPUSH 4 /* reserved for FreeBSD compat */
+#endif
+#define TCP_KEEPINTVL 5
+#define TCP_KEEPCNT 6
+#define TCP_KEEPINIT 7
+#ifdef notyet
+#define TCP_NOOPT 8 /* reserved for FreeBSD compat */
+#endif
+#define TCP_MD5SIG 0x10 /* use MD5 digests (RFC2385) */
+#define TCP_CONGCTL 0x20 /* selected congestion control */
+
+#endif /* !_NETINET_TCP_H_ */
diff --git a/edk2/UefiCpuPkg/UefiCpuPkg.dec b/edk2/UefiCpuPkg/UefiCpuPkg.dec
index 31b7303e6..b3858b19b 100644
--- a/edk2/UefiCpuPkg/UefiCpuPkg.dec
+++ b/edk2/UefiCpuPkg/UefiCpuPkg.dec
@@ -2,7 +2,7 @@
#
# This Package provides UEFI compatible CPU modules and libraries.
#
-# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
#
# This program and the accompanying materials are licensed and made available under
# the terms and conditions of the BSD License which accompanies this distribution.
@@ -18,7 +18,7 @@
DEC_SPECIFICATION = 0x00010005
PACKAGE_NAME = UefiCpuPkg
PACKAGE_GUID = 2171df9b-0d39-45aa-ac37-2de190010d23
- PACKAGE_VERSION = 0.1
+ PACKAGE_VERSION = 0.2
[Includes]
Include
diff --git a/edk2/UefiCpuPkg/UefiCpuPkg.dsc b/edk2/UefiCpuPkg/UefiCpuPkg.dsc
index d4a81755b..8d049bbc8 100644
--- a/edk2/UefiCpuPkg/UefiCpuPkg.dsc
+++ b/edk2/UefiCpuPkg/UefiCpuPkg.dsc
@@ -16,7 +16,7 @@
[Defines]
PLATFORM_NAME = UefiCpu
PLATFORM_GUID = a1b7be22-78b3-4260-9569-8649e8c17d49
- PLATFORM_VERSION = 0.1
+ PLATFORM_VERSION = 0.2
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/UefiCpu
SUPPORTED_ARCHITECTURES = IA32|IPF|X64
diff --git a/edk2/UnixPkg/UnixSnpDxe/UnixSnpDxe.inf b/edk2/UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
index c73aeedb0..21e833bc7 100644
--- a/edk2/UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
+++ b/edk2/UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
@@ -1,4 +1,4 @@
-#/** @file
+## @file
# Component name for module UnixSnpDxe
#
# Copyright (c) 2010, Apple, Inc. All rights reserved.<BR>
@@ -12,7 +12,7 @@
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
-#**/
+##
[Defines]
INF_VERSION = 0x00010005