]> git.proxmox.com Git - mirror_edk2.git/log
mirror_edk2.git
9 years agoOvmfPkg: VirtioScsiDxe: drop 64-bit shift in PopulateRequest() (VS2010)
Scott Duplichan [Fri, 14 Nov 2014 10:24:08 +0000 (10:24 +0000)]
OvmfPkg: VirtioScsiDxe: drop 64-bit shift in PopulateRequest() (VS2010)

"Lun" has type UINT64 in this function. The result of the expression

  (UINT8) ((Lun >> 8) | 0x40)

depends only on bits [15:8] of "Lun", therefore we can cast "Lun" to
UINT32 before shifting it.

This eliminates an intrinsic when building with VS2010 for Ia32 / NOOPT.

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Scott Duplichan <scott@notabs.org>
[lersek@redhat.com: added commit message]

Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Build-tested-by: Scott Duplichan <scott@notabs.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16386 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: QemuVideoDxe: the VBE shim needs no 64-bit shifts (VS2010)
Scott Duplichan [Fri, 14 Nov 2014 10:23:55 +0000 (10:23 +0000)]
OvmfPkg: QemuVideoDxe: the VBE shim needs no 64-bit shifts (VS2010)

The SegmentC local variable has type EFI_PHYSICAL_ADDRESS for (justified)
style reasons. However, the 64-bit bit-shifts that it undergoes result in
intrinsic calls when built with VS2010 for Ia32 / NOOPT.

The concrete value of SegmentC, 0xC0000, and the results  of the bitops
that are based on it, are statically computeable. Cast SegmentC to UINT32
before subjecting it to bitwise operations; we can see in advance that
this won't lead to range loss.

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Scott Duplichan <scott@notabs.org>
[lersek@redhat.com: dropped now superfluous outermost parens; commit msg]

Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Build-tested-by: Scott Duplichan <scott@notabs.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16385 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: flash driver: drop needlessly wide multiplication (VS2010)
Scott Duplichan [Fri, 14 Nov 2014 10:23:43 +0000 (10:23 +0000)]
OvmfPkg: flash driver: drop needlessly wide multiplication (VS2010)

The current types of subexpressions used in QemuFlashPtr() are as follows.
(We also show the types of "larger" subexpressions, according to operator
binding.)

  mFlashBase + (Lba * mFdBlockSize) + Offset
      ^          ^         ^            ^
      |          |         |            |
   (UINT8*)   EFI_LBA    UINTN        UINTN
              (UINT64)

  ---------------------------------   ------
              (UINT8*)                UINTN

  ------------------------------------------
                    (UINT8*)

When building with VS2010 for Ia32 / NOOPT, the 64-by-32 bit
multiplication is translated to an intrinsic, which is not allowed in
edk2.

Recognize that "Lba" is always bounded by "mFdBlockCount" (an UINTN) here
-- all callers of QemuFlashPtr() ensure that. In addition, the flash chip
in question is always under 4GB, which is why we can address it at all on
Ia32. Narrow "Lba" to UINTN, without any loss of range.

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Scott Duplichan <scott@notabs.org>
[commit message by lersek@redhat.com]

Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Build-tested-by: Scott Duplichan <scott@notabs.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16384 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPg: flash driver: drop gratuitous 64-by-32 bit divisions (VS2010)
Laszlo Ersek [Fri, 14 Nov 2014 10:23:33 +0000 (10:23 +0000)]
OvmfPg: flash driver: drop gratuitous 64-by-32 bit divisions (VS2010)

In the InitializeVariableFvHeader() function, all three of "Offset",
"Start" and "BlockSize" have type UINTN. Therefore the (Offset /
BlockSize) and (Start / BlockSize) divisions can be compiled on all
platforms without intrinsics.

In the current expressions

  (EFI_LBA) Offset / BlockSize
  (EFI_LBA) Start / BlockSize

"Offset" and "Start" are cast to UINT64 (== EFI_LBA), which leads to
64-by-32 bit divisions on Ia32, breaking the VS2010 / NOOPT / Ia32 build.
The simplest way to fix them is to realize we don't need casts at all.
(The prototypes of QemuFlashEraseBlock() and QemuFlashWrite() are visible
via "QemuFlash.h", and they will easily take our UINTN quotients as
UINT64.)

Suggested-by: Scott Duplichan <scott@notabs.org>
Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Build-tested-by: Scott Duplichan <scott@notabs.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16383 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPg: flash driver: fix type of EFI_SIZE_TO_PAGES argument (VS2010)
Laszlo Ersek [Fri, 14 Nov 2014 10:23:21 +0000 (10:23 +0000)]
OvmfPg: flash driver: fix type of EFI_SIZE_TO_PAGES argument (VS2010)

The MarkMemoryRangeForRuntimeAccess() function passes the Length parameter
(of type UINT64) to the macro EFI_SIZE_TO_PAGES(). When building for the
Ia32 platform, this violates the interface contract of the macro:

    [...] Passing in a parameter that is larger than UINTN may produce
    unexpected results.

In addition, it trips up compilation by VS2010 for the Ia32 platform and
the NOOPT target -- it generates calls to intrinsics, which are not
allowed in edk2.

Fix both issues with the following steps:

(1) Demote the Length parameter of MarkMemoryRangeForRuntimeAccess() to
UINTN. Even a UINT32 value is plenty for representing the size of the
flash chip holding the variable store. Length parameter is used in the
following contexts:
- passed to gDS->RemoveMemorySpace() -- takes an UINT64
- passed to gDS->AddMemorySpace() -- ditto
- passed to EFI_SIZE_TO_PAGES() -- requires an UINTN. This also guarantees
  that the return type of EFI_SIZE_TO_PAGES() will be UINTN, hence we can
  drop the outer cast.

(2) The only caller of MarkMemoryRangeForRuntimeAccess() is
FvbInitialize(). The latter function populates the local Length variable
(passed to MarkMemoryRangeForRuntimeAccess()) from
PcdGet32(PcdOvmfFirmwareFdSize). Therefore we can simply demote the local
variable to UINTN in this function as well.
- There's only one other use of Length in FvbInitialize(): it is passed to
  GetFvbInfo(). GetFvbInfo() takes an UINT64, so passing an UINTN is fine.

Suggested-by: Scott Duplichan <scott@notabs.org>
Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Build-tested-by: Scott Duplichan <scott@notabs.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16382 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoMdeModulePkg/Core/PiSmmCore/PiSmmCore.c: Fix compiler warning about variable set...
Garrett Kirkendall [Fri, 14 Nov 2014 08:44:41 +0000 (08:44 +0000)]
MdeModulePkg/Core/PiSmmCore/PiSmmCore.c: Fix compiler warning about variable set but unused

Fix compiler warning about variable set but unused by returning status
of last operation.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Garrett Kirkendall <garrett.kirkendall@amd.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16381 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUEFI 2.4 X509 Certificate Hash and RFC3161 Timestamp Verification support for Secure...
Qin Long [Fri, 14 Nov 2014 08:41:12 +0000 (08:41 +0000)]
UEFI 2.4 X509 Certificate Hash and RFC3161 Timestamp Verification support for Secure Boot

Main ChangeLogs includes:
1. Introduce the new GUID and structure definitions for certificate hash and timestamp support;
2. Update Image Verification Library to support DBT signature checking;
3. Update the related SecureBoot Configuration Pages;

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Qin Long <qin.long@intel.com>
Reviewed-by: Guo Dong <guo.dong@intel.com>
Reviewed-by: Siyuan Fu <siyuan.fu@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16380 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: PlatformBdsLib: Platform dependent PCI/IRQ initialization
Gabriel Somlo [Fri, 14 Nov 2014 00:39:04 +0000 (00:39 +0000)]
OvmfPkg: PlatformBdsLib: Platform dependent PCI/IRQ initialization

Merge PciInitialization() and AcpiInitialization() into a single
function, PciAcpiInitialization(), and use a PCD set during PEI to
detect the underlying platform type (PIIX4 or Q35/MCH) and therefore
the addresses of the registers to be initialized.

Add LNK[A-H] routing target initialization for the Q35 platform.

Additionally, initialize PCI_INTERRUPT_LINE registers for the typical
set of PCI devices included by QEMU with the Q35 machine type. The
corresponding PIIX4 initialization of PCI_INTERRUPT_LINE registers is
cleaned up and the list of PIIX4 PCI devices updated to the list
typically included with QEMU.

NOTE: The list of PCI devices for which we initialize PCI_INTERRUPT_LINE
is hard-coded, and, depending on how QEMU devices are configured on
the command line, may miss some devices, or (harmlessly) attempt to
initialize devices which are not present in the system. A subsequent
patch will replace this hard-coded list with a mechanism to correctly
initialize PCI_INTERRUPT_LINE for applicable present PCI devices only.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16379 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: AcpiTimerLib: Switch additional stages to PCD-based Dxe instance
Gabriel Somlo [Fri, 14 Nov 2014 00:38:53 +0000 (00:38 +0000)]
OvmfPkg: AcpiTimerLib: Switch additional stages to PCD-based Dxe instance

Link DXE_SMM_DRIVER, UEFI_DRIVER, UEFI_APPLICATION, and SMM_CORE against
a valid, non-asserting version of PcdLib, then switch them over to using
the "Dxe" instance of AcpiTimerLib (instead of the "Base" version).

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16378 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: AcpiTimerLib: Use global variable during PEI_CORE and PEIM
Gabriel Somlo [Fri, 14 Nov 2014 00:38:35 +0000 (00:38 +0000)]
OvmfPkg: AcpiTimerLib: Use global variable during PEI_CORE and PEIM

Since in OVMF both PEI_CORE and PEIM run from RAM, and thus may
utilize global variables, use the "Base" AcpiTimerLib instance
(instead of BaseRom) to take advantage of the improved efficiency
of storing the timer register IO address in a global variable.

This leaves only SEC using the BaseRomAcpiTimerLib instance.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16377 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: AcpiTimerLib: Split into multiple phase-specific instances
Gabriel Somlo [Fri, 14 Nov 2014 00:38:17 +0000 (00:38 +0000)]
OvmfPkg: AcpiTimerLib: Split into multiple phase-specific instances

Remove local power management register access macros in favor of
factored-out ones in OvmfPkg/Include/OvmfPlatforms.h

Next, AcpiTimerLib is split out into three instances, for use during
various stages:

  - BaseRom: used during SEC, PEI_CORE, and PEIM;
  - Dxe:     used during DXE_DRIVER and DXE_RUNTIME_DRIVER;
  - Base:    used by default during all other stages.

Most of the code remains in AcpiTimerLib.c, to be shared by all
instances. The two platform-dependent methods (constructor and
InternalAcpiGetTimerTick) are provided separately by source files
specific to each instance, namely [BaseRom|Base|Dxe]AcpiTimerLib.c.

Since pre-DXE stages can't rely on storing data in global variables,
methods specific to the "BaseRom" instance will call platform
detection macros each time they're invoked.

The "Base" instance calls platform detection macros only from its
constructor, and caches the address required by InternalAcpiTimerTick
in a global variable.

The "Dxe" instance is very similar to "Base", except no platform
detection macros are called at all; instead, the platform type is
read via a dynamic PCD set from PlatformPei.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16376 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: CsmSupportLib: Set/use platform specific legacy interrupt device
Gabriel Somlo [Fri, 14 Nov 2014 00:38:00 +0000 (00:38 +0000)]
OvmfPkg: CsmSupportLib: Set/use platform specific legacy interrupt device

Use a PCD set from PEI to determine the legacy interrupt device
number appropriate for the underlying platform type during protocol
initialization.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16375 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: Add PCD for Host Bridge dev. ID (PcdOvmfHostBridgePciDevId)
Gabriel Somlo [Fri, 14 Nov 2014 00:37:39 +0000 (00:37 +0000)]
OvmfPkg: Add PCD for Host Bridge dev. ID (PcdOvmfHostBridgePciDevId)

Set from PEI, this PCD allows subsequent stages (specifically
DXE_DRIVER and DXE_RUNTIME_DRIVER) to infer the underlying platform
type (e.g. PIIX4 or Q35/MCH) without the need to further query the
Host Bridge for its Device ID.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16374 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: PlatformPei: Platform specific ACPI power management setup
Gabriel Somlo [Fri, 14 Nov 2014 00:37:26 +0000 (00:37 +0000)]
OvmfPkg: PlatformPei: Platform specific ACPI power management setup

Set up ACPI power management using registers determined based on
the underlying (PIIX4 or Q35/MCH) platform type.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16373 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: Factor out platform detection (q35 vs. piix4)
Gabriel Somlo [Fri, 14 Nov 2014 00:37:16 +0000 (00:37 +0000)]
OvmfPkg: Factor out platform detection (q35 vs. piix4)

Introduce macros to detect the underlying platform and access its
ACPI power management registers, based on querying the host bridge
device ID.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16372 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: install Mp Service protocol
Chen Fan [Thu, 13 Nov 2014 18:30:18 +0000 (18:30 +0000)]
UefiCpuPkg/CpuDxe: install Mp Service protocol

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16371 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: Startup APs
Jordan Justen [Thu, 13 Nov 2014 18:30:09 +0000 (18:30 +0000)]
UefiCpuPkg/CpuDxe: Startup APs

This sequence should happen:
* CpuMp.c: Allocate a stack for the APs
* ApStartup.c: Send Start IPI to wake APs in 16-bit real mode
* MpAsm.S: AP enters CpuDxe driver code without stack
  - AP grabs a lock
  - AP sets up stack
  - AP calls CpuMp.c:ApEntryPointInC

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16370 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/MpService: avoid dead lock caused by CheckAllAPsStatus
Chen Fan [Thu, 13 Nov 2014 18:29:54 +0000 (18:29 +0000)]
UefiCpuPkg/MpService: avoid dead lock caused by CheckAllAPsStatus

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16369 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/MpService: avoid reset AP still hold a lock
Chen Fan [Thu, 13 Nov 2014 18:29:40 +0000 (18:29 +0000)]
UefiCpuPkg/MpService: avoid reset AP still hold a lock

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16368 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/MpService: free the unused cpu data buffer
Chen Fan [Thu, 13 Nov 2014 18:29:31 +0000 (18:29 +0000)]
UefiCpuPkg/MpService: free the unused cpu data buffer

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16367 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: introduce ResetApStackless()
Chen Fan [Thu, 13 Nov 2014 18:29:13 +0000 (18:29 +0000)]
UefiCpuPkg/CpuDxe: introduce ResetApStackless()

If timeout expires before AP returns from Procedure, the AP should
be terminated, we introduce ResetApStackLess() to send init IPI
to let AP exit Procedurce and re-available.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16366 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: split out StartupCode from StartApsStackless()
Chen Fan [Thu, 13 Nov 2014 18:29:01 +0000 (18:29 +0000)]
UefiCpuPkg/CpuDxe: split out StartupCode from StartApsStackless()

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16365 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/MpService: avoid next timer getting into CheckAllAPsStatus()
Chen Fan [Thu, 13 Nov 2014 18:28:48 +0000 (18:28 +0000)]
UefiCpuPkg/MpService: avoid next timer getting into CheckAllAPsStatus()

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16364 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/MpService: Simply Lock usage
Chen Fan [Thu, 13 Nov 2014 18:28:33 +0000 (18:28 +0000)]
UefiCpuPkg/MpService: Simply Lock usage

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16363 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/MpService: move settimer out to InitMpSystemData
Chen Fan [Thu, 13 Nov 2014 18:28:20 +0000 (18:28 +0000)]
UefiCpuPkg/MpService: move settimer out to InitMpSystemData

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16362 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: Ap do loop routine to execute procedure
Chen Fan [Thu, 13 Nov 2014 18:28:10 +0000 (18:28 +0000)]
UefiCpuPkg/CpuDxe: Ap do loop routine to execute procedure

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16361 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: implement Mp Services:SwitchBSP()
Chen Fan [Thu, 13 Nov 2014 18:27:52 +0000 (18:27 +0000)]
UefiCpuPkg/CpuDxe: implement Mp Services:SwitchBSP()

by now, SwitchBSP() always return UNSUPPORTED

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16360 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: implement Mp Services:StartupAllAPs()
Chen Fan [Thu, 13 Nov 2014 18:27:34 +0000 (18:27 +0000)]
UefiCpuPkg/CpuDxe: implement Mp Services:StartupAllAPs()

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16359 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: implement Mp Protocol:StartupThisAP()
Chen Fan [Thu, 13 Nov 2014 18:27:21 +0000 (18:27 +0000)]
UefiCpuPkg/CpuDxe: implement Mp Protocol:StartupThisAP()

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16358 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: implement Mp Protocol:EnableDisableAP()
Chen Fan [Thu, 13 Nov 2014 18:27:09 +0000 (18:27 +0000)]
UefiCpuPkg/CpuDxe: implement Mp Protocol:EnableDisableAP()

Due to the implementation of  AcquireSpinLock() is not MP safe,
so we should use AcquireSpinLockOrFail directly instead.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16357 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: implement Mp Services:GetProcessorInfo()
Chen Fan [Thu, 13 Nov 2014 18:26:53 +0000 (18:26 +0000)]
UefiCpuPkg/CpuDxe: implement Mp Services:GetProcessorInfo()

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16356 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: implement Mp Protocol:GetNumberOfProcessors()
Chen Fan [Thu, 13 Nov 2014 18:26:42 +0000 (18:26 +0000)]
UefiCpuPkg/CpuDxe: implement Mp Protocol:GetNumberOfProcessors()

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16355 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: implement Mp Protocol: WhoAmI()
Chen Fan [Thu, 13 Nov 2014 18:26:32 +0000 (18:26 +0000)]
UefiCpuPkg/CpuDxe: implement Mp Protocol: WhoAmI()

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16354 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: introduce MP_SYSTEM_DATA for Mp Service Protocol
Chen Fan [Thu, 13 Nov 2014 18:26:23 +0000 (18:26 +0000)]
UefiCpuPkg/CpuDxe: introduce MP_SYSTEM_DATA for Mp Service Protocol

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16353 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: introduce EFI_MP_SERVICES_PROTOCOL
Chen Fan [Thu, 13 Nov 2014 18:26:13 +0000 (18:26 +0000)]
UefiCpuPkg/CpuDxe: introduce EFI_MP_SERVICES_PROTOCOL

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16352 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: Switch Ap Stack to NewStack
Chen Fan [Thu, 13 Nov 2014 18:26:03 +0000 (18:26 +0000)]
UefiCpuPkg/CpuDxe: Switch Ap Stack to NewStack

All APs use the same common stack to initialization. after
initialization, APs should switch to the stack of its own.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16351 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: introduce two PCD value
Chen Fan [Thu, 13 Nov 2014 18:25:48 +0000 (18:25 +0000)]
UefiCpuPkg/CpuDxe: introduce two PCD value

introduce PCD value: PcdCpuMaxLogicalProcessorNumber and PcdCpuApStackSize,
used for initialize APs stacks.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16350 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: Add StartApsStackless routine
Jordan Justen [Thu, 13 Nov 2014 18:25:29 +0000 (18:25 +0000)]
UefiCpuPkg/CpuDxe: Add StartApsStackless routine

This routine starts the APs and directs them to run the specified
code.

The specified code is entered without a stack being available.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16349 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: Move GDT structures into CpuGdt.h
Jordan Justen [Thu, 13 Nov 2014 18:25:10 +0000 (18:25 +0000)]
UefiCpuPkg/CpuDxe: Move GDT structures into CpuGdt.h

We'll want to use the structures for AP startup.

Note: It seems previously we were not using '#pragma pack ()' in
      CpuGdt.c.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16348 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: Add stackless assembly AP entry points
Jordan Justen [Thu, 13 Nov 2014 18:24:59 +0000 (18:24 +0000)]
UefiCpuPkg/CpuDxe: Add stackless assembly AP entry points

The AP startup code simply jumps into this code with the CpuDxe driver
without setting up a stack for the processor.

Therefore, this code must setup the stack before calling into C code.

This is the basic flow:
* AP enters CpuDxe driver code (AsmApEntryPoint) without stack
  - AP grabs a lock
  - AP sets up stack
  - AP calls CpuMp.c:ApEntryPointInC
  - If ApEntryPointInC returns, the lock is freed, and another AP may
    run
  - The AP C code may call AsmApDoneWithCommonStack to indicate that
    the AP is no longer using the stack, and another may therefore
    proceed to use the stack and then call ApEntryPointInC

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16347 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: Add ApEntryPointInC
Jordan Justen [Thu, 13 Nov 2014 18:24:43 +0000 (18:24 +0000)]
UefiCpuPkg/CpuDxe: Add ApEntryPointInC

This is the function the AP assembly code will expect to call after
getting a lock and setting up the stack.

Only one AP will enter this routine at a time.

If ApEntryPointInC exits, then the assembly code will loop around to
grab the lock, setup the stack, and call ApEntryPointInC again.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16346 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoUefiCpuPkg/CpuDxe: Add no-op InitializeMpSupport
Jordan Justen [Thu, 13 Nov 2014 18:24:25 +0000 (18:24 +0000)]
UefiCpuPkg/CpuDxe: Add no-op InitializeMpSupport

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16345 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoArmPkg/ArmGicLib: select GICv2 mode if SRE is present but unavailable
Ard Biesheuvel [Thu, 13 Nov 2014 16:41:51 +0000 (16:41 +0000)]
ArmPkg/ArmGicLib: select GICv2 mode if SRE is present but unavailable

Even if the CPU id registers indicate hardware support for the
System Register interface to the GIC, higher exception levels
may disable that interface and only allow access through MMIO.

So move the enabling of the SRE bit to the GIC version detection
routine: if we trigger an exception, we would have anyway at a
later stage, so the net effect is the same. However, if setting
the bit doesn't stick, it means we can switch to MMIO and proceed
normally otherwise.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16344 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoArmPkg/ArmGic: Removed 'GCC' toolchain to build assembly files
Olivier Martin [Thu, 13 Nov 2014 11:06:00 +0000 (11:06 +0000)]
ArmPkg/ArmGic: Removed 'GCC' toolchain to build assembly files

ARMCC6 toolchain (LLVM based) understands the GNU assembly language.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16343 6f19259b-4bc3-4df7-8a09-765794883524

9 years ago[PATHC] ShellPkg: control code flow with a PCD
Jaben Carsey [Wed, 12 Nov 2014 21:28:51 +0000 (21:28 +0000)]
[PATHC] ShellPkg: control code flow with a PCD

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16342 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg/XenPvBlkDxe: Don't include system inttypes.h
Jordan Justen [Wed, 12 Nov 2014 20:33:36 +0000 (20:33 +0000)]
OvmfPkg/XenPvBlkDxe: Don't include system inttypes.h

EDK II code should not include system include files.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Anthony PERARD <anthony.perard@citrix.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16341 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoArmPlatformPkg: fix undefined reference to memcpy
Scott Duplichan [Wed, 12 Nov 2014 10:01:41 +0000 (10:01 +0000)]
ArmPlatformPkg: fix undefined reference to memcpy

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Scott Duplichan <scott@notabs.org>
Reviewed-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16340 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoCryptoPkg Updates to support RFC3161 timestamp signature verification.
Qin Long [Wed, 12 Nov 2014 08:51:45 +0000 (08:51 +0000)]
CryptoPkg Updates to support RFC3161 timestamp signature verification.

The main changes includes:
1. Enabling SHA384 and SHA512 digest algorithm; (Sha512.c)
2. RFC 3161 timestamp signature verification support; (CryptTs.c)
3. Fixed one ASN.1 length encoding issue in Authenticode verification routine. (CryptAuthenticode.c)
4. Add the corresponding test cases in Cryptest utility (SHA384 & SHA512 & Timestamp verification)

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Qin Long <qin.long@intel.com>
Reviewed-by: Guo Dong <guo.dong@intel.com>
Reviewed-by: Ting Ye <ting.ye@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16339 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoBaseTools: Fix a cleanall issue.
Yingke Liu [Wed, 12 Nov 2014 08:26:03 +0000 (08:26 +0000)]
BaseTools: Fix a cleanall issue.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Yingke Liu <yingke.d.liu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16338 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoFix a bug in DHCP6 driver when using DUID LLT.
Fu Siyuan [Wed, 12 Nov 2014 05:14:07 +0000 (05:14 +0000)]
Fix a bug in DHCP6 driver when using DUID LLT.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Fu Siyuan <siyuan.fu@intel.com>
Reviewed-by: Dong Eric <eric.dong@intel.com>
Reviewed-by: Wu Jiaxin <jiaxin.wu@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16337 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoEdkCompatibilityPkg: Add UEFI memory and SMRAM profile support.
Star Zeng [Wed, 12 Nov 2014 03:30:11 +0000 (03:30 +0000)]
EdkCompatibilityPkg: Add UEFI memory and SMRAM profile support.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16336 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoMdeModulePkg DxeCore/PiSmmCore: Add UEFI memory and SMRAM profile support.
Star Zeng [Wed, 12 Nov 2014 03:27:48 +0000 (03:27 +0000)]
MdeModulePkg DxeCore/PiSmmCore: Add UEFI memory and SMRAM profile support.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16335 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoMdePkg: Add RETURN_ADDRESS macro into Base.h.
Star Zeng [Wed, 12 Nov 2014 03:18:09 +0000 (03:18 +0000)]
MdePkg: Add RETURN_ADDRESS macro into Base.h.

Based on compiler intrinsic function.
MSVC: _ReturnAddress
GCC: __builtin_return_address

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16334 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoShellPkg: Add type cast to avoid build failure in VS2005.
Qiu Shumin [Wed, 12 Nov 2014 01:07:23 +0000 (01:07 +0000)]
ShellPkg: Add type cast to avoid build failure in VS2005.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Qiu Shumin <shumin.qiu@intel.com>
Reviewed-by: Jaben Carsey <Jaben.carsey@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16333 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoAppPkg: Disable Lua builds by default. Update the ReadMe file.
Daryl McDaniel [Tue, 11 Nov 2014 23:15:32 +0000 (23:15 +0000)]
AppPkg: Disable Lua builds by default.  Update the ReadMe file.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Daryl McDaniel <daryl.mcdaniel@intel.com>
Reviewed-by: Bruce Maynard <Bruce.Maynard@Emulex.Com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16332 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoStdLib/AppPkg: Add the NOOPT build target and fix a type conversion problem with...
Daryl McDaniel [Tue, 11 Nov 2014 22:56:58 +0000 (22:56 +0000)]
StdLib/AppPkg: Add the NOOPT build target and fix a type conversion problem with VS2005.

AppPkg.dsc: Remove IPF support and add NOOPT build target.
StdLib.dsc: Add NOOPT build target.
daConsole.c: Cast a comparison to BOOLEAN before assigning it to a BOOLEAN.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Daryl McDaniel <daryl.mcdaniel@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16331 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoBaseTool: Support EDKII style GUID definition for VFR function.
Yingke Liu [Tue, 11 Nov 2014 07:33:50 +0000 (07:33 +0000)]
BaseTool: Support EDKII style GUID definition for VFR function.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Yingke Liu <yingke.d.liu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16330 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoArmPkg/ArmArchTimerLib: Promotes 32bit value to prevent overflow
Olivier Martin [Tue, 11 Nov 2014 00:52:46 +0000 (00:52 +0000)]
ArmPkg/ArmArchTimerLib: Promotes 32bit value to prevent overflow

Both MicroSeconds and PcdArmArchTimerFreqInHz are 32-bit values on
AArch32 so their multiplication produces 32-bit result that might
cause wrong calculation.

Example: With MicroSeconds = 200 us, PcdArmArchTimerFreqInHz = 24MHz.
200*24000000 = 0x1_1E1A_3000 => So 0x1E1A_3000 when the type is UINT32.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16329 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoArmPkg/CompilerIntrinsicesLib: Fixed memmove() and memset()
Olivier Martin [Tue, 11 Nov 2014 00:52:11 +0000 (00:52 +0000)]
ArmPkg/CompilerIntrinsicesLib: Fixed memmove() and memset()

- Fixed memmove when going backward: the copy started one byte
  after the end of the region to copy
- memset: - removed unused register
          - fixed arguments size and character arguments were
            actually reversed
- Added memmove() to ARM32 GCC

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16328 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoArmPkg: Ensured the stack is always quad-word aligned
Olivier Martin [Tue, 11 Nov 2014 00:51:11 +0000 (00:51 +0000)]
ArmPkg: Ensured the stack is always quad-word aligned

From the AArch64 Procedure Call Standard (ARM IHI 0055B):

  5.2.2.1 Universal stack constraints
  At all times the following basic constraints must hold:
  - SP mod 16 = 0. The stack must be quad-word aligned.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16327 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoEmbeddedPkg/Lan9118Dxe: Remove link check in SNP initialization
Ronald Cron [Tue, 11 Nov 2014 00:49:50 +0000 (00:49 +0000)]
EmbeddedPkg/Lan9118Dxe: Remove link check in SNP initialization

The UEFI specification does not require the initialisation and reset
interface to check if an Ethernet cable is connected or not, and provides
the GetStatus() interface to do this. Furthermore, the 'Managed Network
Protocol' take care of the cable connection check in edk2 network stack.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ronald Cron <ronald.cron@arm.com>
Reviewed-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16326 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoArmPlatformPkg: Increase more ARM address Pcd entries to 64-bit.
Leif Lindholm [Tue, 11 Nov 2014 00:43:03 +0000 (00:43 +0000)]
ArmPlatformPkg: Increase more ARM address Pcd entries to 64-bit.

Some AArch64 platforms have RAM and flash devices >4GB.
Update some additional Pcd entries to 64-bit, and change
the corresponding PcdGet32 calls to PcdGet64.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16325 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoStdLib: Fix a "potentially uninitialized variable" error.
Daryl McDaniel [Mon, 10 Nov 2014 23:05:45 +0000 (23:05 +0000)]
StdLib: Fix a "potentially uninitialized variable" error.

gdtoa/gdtoa.c:  Several "goto" paths allowed the initialization of a variable to be bypassed.  Initialized it at the top of the function in order to eliminate the error.

Updated the file header and copyright notices.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Daryl McDaniel <daryl.mcdaniel@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16324 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoShellPkg: Fixed variable set but never used
Olivier Martin [Mon, 10 Nov 2014 10:20:25 +0000 (10:20 +0000)]
ShellPkg: Fixed variable set but never used

This warning/error raised by ARM toolchain prevents to build
the EFI Shell for ARM 32-bit with this toolchain.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16323 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoFix a bug in DebugAgent that hang happens when the ACK for GO is lost.
Ruiyu Ni [Mon, 10 Nov 2014 08:47:49 +0000 (08:47 +0000)]
Fix a bug in DebugAgent that hang happens when the ACK for GO is lost.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16322 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoMdeModulePkg/AtaAtapiPassThru: don't write read-only AHCI MMIO register
Feng Tian [Mon, 10 Nov 2014 05:46:21 +0000 (05:46 +0000)]
MdeModulePkg/AtaAtapiPassThru: don't write read-only AHCI MMIO register

Per AHCI 1.1 spec, AE bit of GHC register is read-only if CAP.SAM is 1

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16321 6f19259b-4bc3-4df7-8a09-765794883524

9 years ago Fix execution status & DEBUG message level mismatch. EFI_D_ERROR is used only...
Chao Zhang [Mon, 10 Nov 2014 05:01:15 +0000 (05:01 +0000)]
   Fix execution status & DEBUG message level mismatch. EFI_D_ERROR is used only when failure/case can’t be resolved by code.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chao Zhang <chao.b.zhang@intel.com>
Reviewed-by: Dong Guo <guo.dong@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16320 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg XenBusDxe: Convert X64/TestAndClearBit.asm to NASM
Anthony PERARD [Sat, 8 Nov 2014 02:41:35 +0000 (02:41 +0000)]
OvmfPkg XenBusDxe: Convert X64/TestAndClearBit.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
X64/TestAndClearBit.asm to X64/TestAndClearBit.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16319 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg XenBusDxe: Convert X64/InterlockedCompareExchange16.asm to NASM
Anthony PERARD [Sat, 8 Nov 2014 02:41:28 +0000 (02:41 +0000)]
OvmfPkg XenBusDxe: Convert X64/InterlockedCompareExchange16.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
X64/InterlockedCompareExchange16.asm to X64/InterlockedCompareExchange16.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16318 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg XenBusDxe: Convert X64/hypercall.asm to NASM
Anthony PERARD [Sat, 8 Nov 2014 02:41:15 +0000 (02:41 +0000)]
OvmfPkg XenBusDxe: Convert X64/hypercall.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
X64/hypercall.asm to X64/hypercall.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16317 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg XenBusDxe: Convert Ia32/TestAndClearBit.asm to NASM
Anthony PERARD [Sat, 8 Nov 2014 02:41:07 +0000 (02:41 +0000)]
OvmfPkg XenBusDxe: Convert Ia32/TestAndClearBit.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
Ia32/TestAndClearBit.asm to Ia32/TestAndClearBit.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16316 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg XenBusDxe: Convert Ia32/InterlockedCompareExchange16.asm to NASM
Anthony PERARD [Sat, 8 Nov 2014 02:40:58 +0000 (02:40 +0000)]
OvmfPkg XenBusDxe: Convert Ia32/InterlockedCompareExchange16.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
Ia32/InterlockedCompareExchange16.asm to Ia32/InterlockedCompareExchange16.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16315 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg XenBusDxe: Convert Ia32/hypercall.asm to NASM
Anthony PERARD [Sat, 8 Nov 2014 02:40:44 +0000 (02:40 +0000)]
OvmfPkg XenBusDxe: Convert Ia32/hypercall.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
Ia32/hypercall.asm to Ia32/hypercall.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16314 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoAppPkg: Add the Lua interpreter and library.
darylm503 [Fri, 7 Nov 2014 20:18:01 +0000 (20:18 +0000)]
AppPkg: Add the Lua interpreter and library.
StdLib: Add support and include files for Lua.

The sources for the Lua standalone interpreter, as well as its library, have been added to AppPkg/Applications/Lua.  The Lua library, LuaLib, can be used to embed Lua into new applications.

The Lua header files, needed for both building and embedding, are located in StdLib/Include/Lua.  The original versions of these header files, in the source directory, have been converted into stubs that reference the include files in StdLib.  This allows us to keep the Lua sources as close to the distributed version as possible.

Documentation is contained in the Lua/doc directory.  Further information is available at www.lua.org.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed Off by:  Bruce Maynard <Bruce.Maynard@Emulex.Com>
Reviewed by:    Daryl McDaniel <daryl.mcdaniel@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16313 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoAdd safe string function to base lib.
jyao1 [Fri, 7 Nov 2014 13:43:05 +0000 (13:43 +0000)]
Add safe string function to base lib.

Contributed-under: TianoCore Contribution Agreement 1.0

signed off by: Yao, Jiewen <jiewen.yao@intel.com>
reviewed by: Ni, Ruiyu <ruiyu.ni@intel.com>
reviewed by: Long, Qin <qin.long@intel.com>
reviewed by: Kinney, Michael D <michael.d.kinney@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16312 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: set video resolution of text setup to 640x480
Laszlo Ersek [Thu, 6 Nov 2014 14:21:21 +0000 (14:21 +0000)]
OvmfPkg: set video resolution of text setup to 640x480

On a physical screen such a low graphics resolution would lead to huge
glyphs (the text resolution is 80x25, centered, with 8x19 pixel glyphs).
But in a virtual machine it just saves screen real estate on the client,
by removing the black bands.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16311 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: BDS: drop custom boot timeout, revert to IntelFrameworkModulePkg's
Laszlo Ersek [Thu, 6 Nov 2014 14:21:15 +0000 (14:21 +0000)]
OvmfPkg: BDS: drop custom boot timeout, revert to IntelFrameworkModulePkg's

PlatformBdsEnterFrontPage() already implements a keypress wait (for
entering the setup utility at boot) with a nice progress bar, only OVMF
has not been using it.

Removing our custom code and utilizing PlatformBdsEnterFrontPage()'s
builtin wait has the following benefits:

- It simplifies OVMF's BDS code.

- Because now we call PlatformBdsEnterFrontPage() unconditionally, it
  actually has a chance to look at the EFI_OS_INDICATIONS_BOOT_TO_FW_UI
  bit of the "OsIndications" variable, improving compliance with the UEFI
  specification. References:
  - https://bugzilla.redhat.com/show_bug.cgi?id=1153927
  - http://thread.gmane.org/gmane.comp.bios.tianocore.devel/10487

- The progress bar looks nice. (And it keeps the earlier behavior intact,
  when the user presses a key on the TianoCore splash screen.)

  In any case, we set the timeout to 0 (which doesn't show the progress
  bar and proceeds to the boot options immediately) in order to keep the
  boot time down.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16310 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: BDS: drop superfluous "connect first boot option" logic
Laszlo Ersek [Thu, 6 Nov 2014 14:21:09 +0000 (14:21 +0000)]
OvmfPkg: BDS: drop superfluous "connect first boot option" logic

This is again obviated by our earlier BdsLibConnectAll() call.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16309 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: BDS: optimize second argument in PlatformBdsEnterFrontPage() call
Laszlo Ersek [Thu, 6 Nov 2014 14:21:03 +0000 (14:21 +0000)]
OvmfPkg: BDS: optimize second argument in PlatformBdsEnterFrontPage() call

The second parameter of said function is "ConnectAllHappened", and if set
to TRUE, the function sets "gConnectAllHappened" to TRUE.

This global variable in turn controls whether Intel BDS code *itself*
calls BdsLibConnectAllDriversToAllControllers() in various places -- if
the indicator is TRUE, then the "connect all" is assumed to have been
performed, and Intel BDS doesn't do it itself.

OVMF should pass TRUE as "ConnectAllHappened", because a few lines before
our call to PlatformBdsEnterFrontPage(), we already connect everything
with BdsLibConnectAll(), which includes the effects of
BdsLibConnectAllDriversToAllControllers():

PlatformBdsPolicyBehavior()                   [OvmfPkg/Library/PlatformBdsLib/BdsPlatform.c]
  BdsLibConnectAll()                          [IntelFrameworkModulePkg/Library/GenericBdsLib/BdsConnect.c]
    BdsLibConnectAllDriversToAllControllers()
  PlatformBdsEnterFrontPage()                 [IntelFrameworkModulePkg/Universal/BdsDxe/FrontPage.c]

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16308 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: BDS: don't overwrite the BDS Front Page timeout
Laszlo Ersek [Thu, 6 Nov 2014 14:20:58 +0000 (14:20 +0000)]
OvmfPkg: BDS: don't overwrite the BDS Front Page timeout

The PlatformBdsEnterFrontPage() function's first parameter,
"TimeoutDefault", determines the behavior of the setup utility:

- If (TimeoutDefault == 0), then the usual boot order is to be acted upon
  immediately.

- If (TimeoutDefault == 0xFFFF), then the setup utility is entered
  unconditionally.

- If (0 < TimeoutDefault && TimeoutDefault < 0xFFFF), then the
  PlatformBdsEnterFrontPage() function displays a progress bar, waiting
  for TimeoutDefault seconds. If the user presses a key, then the setup
  utility is entered, otherwise the normal boot option processing takes
  place.

The TimeoutDefault parameter is supposed to be set from

  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdPlatformBootTimeOut

which has the following (matching) documentation in
"IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec":

  The number of seconds that the firmware will wait before initiating the
  original default boot selection.
  A value of 0 indicates that the default boot selection is to be
  initiated immediately on boot.
  The value of 0xFFFF then firmware will wait for user input before
  booting.

OVMF does this actually -- see the Timeout variable in
PlatformBdsPolicyBehavior() -- but right before calling
PlatformBdsEnterFrontPage(), OVMF hardwires TimeoutDefault to 0xFFFF.

This has been acceptable until now, because OVMF implements its own "wait
for keypress at the splash screen" logic in PlatformBdsPolicyBehavior(),
completely avoiding the progress bar mentioned above. OVMF only calls
PlatformBdsEnterFrontPage() when the user presses a key during its own
"splash screen wait", and *then* it indeed makes sense to enter the setup
utility unconditionally.

However, even that way, the

  Timeout = 0xffff;

assignment is superfluous, because 0xFFFF is already the default value of
PcdPlatformBootTimeOut in "IntelFrameworkModulePkg.dec", and OvmfPkg
doesn't override it in its DSC files.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16307 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: BDS: drop useless return statement
Laszlo Ersek [Thu, 6 Nov 2014 14:20:52 +0000 (14:20 +0000)]
OvmfPkg: BDS: drop useless return statement

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16306 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg: BDS: remove dead call to PlatformBdsEnterFrontPage()
Laszlo Ersek [Thu, 6 Nov 2014 14:20:44 +0000 (14:20 +0000)]
OvmfPkg: BDS: remove dead call to PlatformBdsEnterFrontPage()

This call has been dead since the conception of OvmfPkg (git commit
49ba9447 / SVN r8398), and only confuses readers -- let's remove it.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16305 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoTry to read key strike even when the TimeOuts value is zero, this will avoid BDS...
Eric Dong [Thu, 6 Nov 2014 08:56:54 +0000 (08:56 +0000)]
Try to read key strike even when the TimeOuts value is zero, this will avoid BDS not get user input when TimeOuts value set to zero.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16304 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoRemove un-used PPI reference.
Jeff Fan [Thu, 6 Nov 2014 06:13:22 +0000 (06:13 +0000)]
Remove un-used PPI reference.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16303 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoBaseTools/GenFw: Fixed R_AARCH64_CALL26/R_AARCH64_JUMP26 when referring to start...
Olivier Martin [Wed, 5 Nov 2014 18:56:17 +0000 (18:56 +0000)]
BaseTools/GenFw: Fixed R_AARCH64_CALL26/R_AARCH64_JUMP26 when referring to start of a section

When R_AARCH64_CALL26/R_AARCH64_JUMP26 relocations referred to static
functions, they sometime refer to the start of the '.text' section + addend.
It means the addend is different of '0'.
The non-patched code (before applying the relocation) already contains
the correct offset.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
Reviewed-by: Yingke Liu <yingke.d.liu@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16302 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoMdeModulePkg: Add InSmm() API in PiSmmCoreSmmServicesTableLib instance
Gao, Liming [Wed, 5 Nov 2014 12:09:22 +0000 (12:09 +0000)]
MdeModulePkg: Add InSmm() API in PiSmmCoreSmmServicesTableLib instance

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gao, Liming <liming.gao@intel.com>
Reviewed-by: Fan, Jeff <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16301 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoShellPkg: Fix timezone command
jcarsey [Tue, 4 Nov 2014 22:33:16 +0000 (22:33 +0000)]
ShellPkg: Fix timezone command

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by : Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Tapan Shah <tapandshah@hp.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16300 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoMdePkg: fix comments typo about EFIAPI for X64
Chen Fan [Tue, 4 Nov 2014 09:17:37 +0000 (09:17 +0000)]
MdePkg: fix comments typo about EFIAPI for X64

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chen Fan <chen.fan.fnst@cn.fujitsu.com>
Reviewed-by: Gao, Liming <liming.gao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16299 6f19259b-4bc3-4df7-8a09-765794883524

9 years ago1. Remove any references on other files from DebugTimer.c, to avoid un-used symbols...
Jeff Fan [Tue, 4 Nov 2014 01:29:20 +0000 (01:29 +0000)]
1. Remove any references on other files from DebugTimer.c, to avoid un-used symbols linked.
2. Add GLOBAL_REMOVE_IF_UNREFERENCED for all global variables.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16298 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoEDK II Contributions.txt: Update patch format information
Jordan Justen [Fri, 31 Oct 2014 22:05:50 +0000 (22:05 +0000)]
EDK II Contributions.txt: Update patch format information

Update to show what the patch looks like in email form.

NOTE: This does not modify the wording of the "TianoCore Contribution
      Agreement 1.0" section

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16297 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg/XenBusDxe: Fix initialisation of gXenBusDevicePathTemplate
Anthony PERARD [Fri, 31 Oct 2014 21:25:44 +0000 (21:25 +0000)]
OvmfPkg/XenBusDxe: Fix initialisation of gXenBusDevicePathTemplate

.. to avoid the use .member = value syntax as VS does not support it.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16296 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg/XenBusDxe: Fix initialisation of gXenBusPrivateData
Anthony PERARD [Fri, 31 Oct 2014 21:25:36 +0000 (21:25 +0000)]
OvmfPkg/XenBusDxe: Fix initialisation of gXenBusPrivateData

.. to avoid the use .member = value syntax as VS does not support it.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16295 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg/Xen*: Pass struct XENSTORE_TRANSACTION argument as a pointer
Anthony PERARD [Fri, 31 Oct 2014 21:25:23 +0000 (21:25 +0000)]
OvmfPkg/Xen*: Pass struct XENSTORE_TRANSACTION argument as a pointer

As EDK II does not allow calls with a struct.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16294 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg/Include/...Xen: Convert __i386__/__x86_64__ to MDE_CPU_IA32/MDE_CPU_X64.
Anthony PERARD [Fri, 31 Oct 2014 21:25:11 +0000 (21:25 +0000)]
OvmfPkg/Include/...Xen: Convert __i386__/__x86_64__ to MDE_CPU_IA32/MDE_CPU_X64.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16293 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg Sec: Convert X64/SecEntry.asm to NASM
Jordan Justen [Fri, 31 Oct 2014 20:55:16 +0000 (20:55 +0000)]
OvmfPkg Sec: Convert X64/SecEntry.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
X64/SecEntry.asm to X64/SecEntry.nasm

Note: Manually collapsed .inf sources

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16292 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg Sec: Convert Ia32/SecEntry.asm to NASM
Jordan Justen [Fri, 31 Oct 2014 20:55:06 +0000 (20:55 +0000)]
OvmfPkg Sec: Convert Ia32/SecEntry.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
Ia32/SecEntry.asm to Ia32/SecEntry.nasm

Note: Manually collapsed .inf sources

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16291 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg QemuFwCfgLib: Convert X64/IoLibExAsm.asm to NASM
Jordan Justen [Fri, 31 Oct 2014 20:54:54 +0000 (20:54 +0000)]
OvmfPkg QemuFwCfgLib: Convert X64/IoLibExAsm.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
X64/IoLibExAsm.asm to X64/IoLibExAsm.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16290 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg QemuFwCfgLib: Convert Ia32/IoLibExAsm.asm to NASM
Jordan Justen [Fri, 31 Oct 2014 20:54:41 +0000 (20:54 +0000)]
OvmfPkg QemuFwCfgLib: Convert Ia32/IoLibExAsm.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
Ia32/IoLibExAsm.asm to Ia32/IoLibExAsm.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16289 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg LoadLinuxLib: Convert X64/JumpToKernel.asm to NASM
Jordan Justen [Fri, 31 Oct 2014 20:54:31 +0000 (20:54 +0000)]
OvmfPkg LoadLinuxLib: Convert X64/JumpToKernel.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
X64/JumpToKernel.asm to X64/JumpToKernel.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16288 6f19259b-4bc3-4df7-8a09-765794883524

9 years agoOvmfPkg LoadLinuxLib: Convert Ia32/JumpToKernel.asm to NASM
Jordan Justen [Fri, 31 Oct 2014 20:54:16 +0000 (20:54 +0000)]
OvmfPkg LoadLinuxLib: Convert Ia32/JumpToKernel.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
Ia32/JumpToKernel.asm to Ia32/JumpToKernel.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16287 6f19259b-4bc3-4df7-8a09-765794883524