Re: [edk2] [PATCH v4 4/6] OvmfPkg: AcpiTimerLib: Split into multiple phase-specific instances

2014-11-04 Thread Laszlo Ersek
On 11/04/14 01:22, Gabriel Somlo wrote: > On Mon, Nov 03, 2014 at 08:09:28PM +0100, Laszlo Ersek wrote: >> comments below: >> >> On 11/01/14 23:20, Gabriel L. Somlo wrote: >>> Remove local power management register access macros in favor of >>> factored-out ones in OvmfPkg/Include/OvmfPlatforms.h >

Re: [edk2] Device path for Nand Flash BlockIo

2014-11-04 Thread Laszlo Ersek
On 11/04/14 07:34, sakar.ar...@freescale.com wrote: > > I have a Nand Flash driver that installs BlockIo protocol. I want to use > it to get the linux kernel image from NAND to system memory, in BDS phase. > > An ideal solution would be abstracting BlockIo with DiskIo, which in > turn is abstract

Re: [edk2] [PATCH] MdePkg: fix comments typo about EFIAPI for X64

2014-11-04 Thread Gao, Liming
Fan: The patch is good. Reviewed-by: Gao, Liming I have committed it at 16299. Thanks Liming -Original Message- From: Chen Fan [mailto:chen.fan.f...@cn.fujitsu.com] Sent: Monday, November 03, 2014 5:59 PM To: edk2-devel@lists.sourceforge.net Cc: Fan, Jeff Subject: [edk2] [PATCH] M

[edk2] [RFC PATCH V7 09/27] UefiCpuPkg/CpuDxe: introduce MP_SYSTEM_DATA for Mp Service Protocol

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuDxe.inf | 1 + UefiCpuPkg/CpuDxe/CpuMp.c| 89 +++- UefiCpuPkg/CpuDxe/CpuMp.h| 47 +++ UefiCpuPkg/UefiCpuPkg.dsc| 1 +

[edk2] [RFC PATCH V7 04/27] UefiCpuPkg/CpuDxe: Move GDT structures into CpuGdt.h

2014-11-04 Thread Chen Fan
From: Jordan Justen 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 --- UefiCpuPkg/CpuDxe/CpuGdt.c | 52 +-

[edk2] [RFC PATCH V7 01/27] UefiCpuPkg/CpuDxe: Add no-op InitializeMpSupport

2014-11-04 Thread Chen Fan
From: Jordan Justen Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jordan Justen Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuDxe.c | 3 +++ UefiCpuPkg/CpuDxe/CpuDxe.inf | 2 ++ UefiCpuPkg/CpuDxe/CpuMp.c| 28 UefiCpuPkg/CpuDxe/Cp

[edk2] [RFC PATCH V7 00/27] Introduce Mp Service protocol to UefiCpuPkg

2014-11-04 Thread Chen Fan
This series patchsets try to implement Mp Service protocol in UefiCpuPkg, Jordan had implemented the startup APs code, and I try to add more initialization code to let all APs work up, this Mp Service protocol's implementation used EmulatorPkg/MpService for reference. this patches works on my githu

[edk2] [RFC PATCH V7 10/27] UefiCpuPkg/CpuDxe: implement Mp Protocol: WhoAmI()

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 51 ++- UefiCpuPkg/CpuDxe/CpuMp.h | 31 2 files changed, 81 insertions(+), 1 deletion(-) diff --git a/UefiCpuPk

[edk2] [RFC PATCH V7 02/27] UefiCpuPkg/CpuDxe: Add ApEntryPointInC

2014-11-04 Thread Chen Fan
From: Jordan Justen 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 ApEntryPo

[edk2] [RFC PATCH V7 05/27] UefiCpuPkg/CpuDxe: Add StartApsStackless routine

2014-11-04 Thread Chen Fan
From: Jordan Justen 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 --- UefiCpuPkg/CpuDxe/ApStartup.asm | 111 +++

[edk2] [RFC PATCH V7 19/27] UefiCpuPkg/MpService: Simply Lock usage

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 89 +-- 1 file changed, 47 insertions(+), 42 deletions(-) diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index baab253..

[edk2] [RFC PATCH V7 21/27] UefiCpuPkg/CpuDxe: split out StartupCode from StartApsStackless()

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/ApStartup.c | 54 --- UefiCpuPkg/CpuDxe/CpuMp.c | 3 +++ UefiCpuPkg/CpuDxe/CpuMp.h | 27 ++ 3 files changed, 66 insertions(+),

[edk2] [RFC PATCH V7 23/27] UefiCpuPkg/MpService: free the unused cpu data buffer

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 15 --- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index 96513e8..d657152 100644 --- a/UefiCpuPkg/C

[edk2] [RFC PATCH V7 22/27] UefiCpuPkg/CpuDxe: introduce ResetApStackless()

2014-11-04 Thread Chen Fan
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 --- UefiCpuPkg/CpuDxe/ApStartup.c | 19 ++

[edk2] [RFC PATCH V7 07/27] UefiCpuPkg/CpuDxe: Switch Ap Stack to NewStack

2014-11-04 Thread Chen Fan
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 --- UefiCpuPkg/CpuDxe/CpuMp.c | 29 + 1 file changed, 29 insertions(+)

[edk2] [RFC PATCH V7 11/27] UefiCpuPkg/CpuDxe: implement Mp Protocol:GetNumberOfProcessors()

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 82 ++- UefiCpuPkg/CpuDxe/CpuMp.h | 44 + 2 files changed, 125 insertions(+), 1 deletion(-) diff --git a/UefiCpuPkg/

[edk2] [RFC PATCH V7 12/27] UefiCpuPkg/CpuDxe: implement Mp Services:GetProcessorInfo()

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 52 ++- UefiCpuPkg/CpuDxe/CpuMp.h | 34 +++ 2 files changed, 85 insertions(+), 1 deletion(-) diff --git a/UefiCp

[edk2] [RFC PATCH V7 06/27] UefiCpuPkg/CpuDxe: introduce two PCD value

2014-11-04 Thread Chen Fan
introduce PCD value: PcdCpuMaxLogicalProcessorNumber and PcdCpuApStackSize, used for initialize APs stacks. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuDxe.inf | 4 UefiCpuPkg/CpuDxe/CpuMp.c| 42 ++

[edk2] [RFC PATCH V7 24/27] UefiCpuPkg/MpService: avoid reset AP still hold a lock

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 9 + UefiCpuPkg/CpuDxe/CpuMp.h | 1 + 2 files changed, 10 insertions(+) diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index d657152..183a27d 100644 --- a/U

[edk2] [RFC PATCH V7 14/27] UefiCpuPkg/CpuDxe: implement Mp Protocol:StartupThisAP()

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 345 +- UefiCpuPkg/CpuDxe/CpuMp.h | 117 2 files changed, 461 insertions(+), 1 deletion(-) diff --git a/UefiCpuPkg/CpuDxe/C

[edk2] [RFC PATCH V7 15/27] UefiCpuPkg/CpuDxe: implement Mp Services:StartupAllAPs()

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 436 +- UefiCpuPkg/CpuDxe/CpuMp.h | 160 + 2 files changed, 595 insertions(+), 1 deletion(-) diff --git a/UefiCpuPkg/CpuDxe/

[edk2] [RFC PATCH V7 13/27] UefiCpuPkg/CpuDxe: implement Mp Protocol:EnableDisableAP()

2014-11-04 Thread Chen Fan
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 --- UefiCpuPkg/CpuDxe/CpuMp.c | 186 +- UefiCpuPkg/

[edk2] [RFC PATCH V7 26/27] UefiCpuPkg/CpuDxe: Startup APs

2014-11-04 Thread Chen Fan
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 Contri

[edk2] [RFC PATCH V7 27/27] UefiCpuPkg/CpuDxe: install Mp Service protocol

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index 1eaf7b3..2692ebc 100644 --- a/UefiCpuPkg/CpuDxe/CpuMp.c +++ b/U

[edk2] [RFC PATCH V7 17/27] UefiCpuPkg/CpuDxe: Ap do loop routine to execute procedure

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 33 - 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index ee25eac..f5de832 100644 -

[edk2] [RFC PATCH V7 25/27] UefiCpuPkg/MpService: avoid dead lock caused by CheckAllAPsStatus

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 55 ++- 1 file changed, 31 insertions(+), 24 deletions(-) diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index 183a27d..

[edk2] [RFC PATCH V7 03/27] UefiCpuPkg/CpuDxe: Add stackless assembly AP entry points

2014-11-04 Thread Chen Fan
From: Jordan Justen 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

[edk2] [RFC PATCH V7 16/27] UefiCpuPkg/CpuDxe: implement Mp Services:SwitchBSP()

2014-11-04 Thread Chen Fan
by now, SwitchBSP() always return UNSUPPORTED Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 51 ++- UefiCpuPkg/CpuDxe/CpuMp.h | 43 +++ 2 files change

[edk2] [RFC PATCH V7 20/27] UefiCpuPkg/MpService: avoid next timer getting into CheckAllAPsStatus()

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 23 ++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index 950db38..ba62aea 100644 --- a/UefiC

[edk2] [RFC PATCH V7 18/27] UefiCpuPkg/MpService: move settimer out to InitMpSystemData

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuMp.c | 128 -- 1 file changed, 78 insertions(+), 50 deletions(-) diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index f5de832..

[edk2] [RFC PATCH V7 08/27] UefiCpuPkg/CpuDxe: introduce EFI_MP_SERVICES_PROTOCOL

2014-11-04 Thread Chen Fan
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chen Fan --- UefiCpuPkg/CpuDxe/CpuDxe.inf | 1 + UefiCpuPkg/CpuDxe/CpuMp.c| 10 ++ UefiCpuPkg/CpuDxe/CpuMp.h| 2 ++ 3 files changed, 13 insertions(+) diff --git a/UefiCpuPkg/CpuDxe/CpuDxe.inf b/UefiCpuPkg/Cp

[edk2] enable PcdSupportUpdateCapsuleReset feature

2014-11-04 Thread Sam Protsenko
Hi guys, While working on UpdateCapsule I found out that I can't run neither UpdateCapsule(), nor QueryCapsuleCapabilities() runtime services because PcdSupportUpdateCapsuleReset feature disabled by default in edk2. Is there any particular reason for this? Anyway, I propose to enable this by defa

Re: [edk2] BaseTools: Add MINGW tool chain

2014-11-04 Thread David Woodhouse
On Wed, 2014-10-15 at 01:47 -0500, Scott Duplichan wrote: > > I agree completely about redundant tool chains. For example, EDK2 > currently has separate tool chains for VS2008 on Win32 and VS2008 > on Win64. This particular problem is easily solved using environment > variables to handle the tool

Re: [edk2] BaseTools: Add MINGW tool chain

2014-11-04 Thread Bruce Cran
I believe designated initializers are available in Visual Studio 2013 ( http://blogs.msdn.com/b/vcblog/archive/2013/07/19/c99-library-support-in-visual-studio-2013.aspx . -- Bruce On Tuesday, November 4, 2014, David Woodhouse wrote: > On Wed, 2014-10-15 at 01:47 -0500, Scott Duplichan wrote: >

Re: [edk2] Enable optimization for gcc x64 builds

2014-11-04 Thread Andrew Fish
> On Nov 4, 2014, at 5:48 AM, Laszlo Ersek wrote: > > diff --git a/MdePkg/Library/BasePrintLib/PrintLibInternal.c > b/MdePkg/Library/BasePrintLib/PrintLibInternal.c > index 8dc5ec7..fbb3726 100644 > --- a/MdePkg/Library/BasePrintLib/PrintLibInternal.c > +++ b/MdePkg/Library/BasePrintLib/PrintLib

Re: [edk2] BaseTools: Add MINGW tool chain

2014-11-04 Thread Scott Duplichan
David Woodhouse [mailto:dw...@infradead.org] wrote: ]On Wed, 2014-10-15 at 01:47 -0500, Scott Duplichan wrote: ]> ]> I agree completely about redundant tool chains. For example, EDK2 ]> currently has separate tool chains for VS2008 on Win32 and VS2008 ]> on Win64. This particular problem is easil

Re: [edk2] Enable optimization for gcc x64 builds

2014-11-04 Thread Laszlo Ersek
On 11/04/14 18:28, Andrew Fish wrote: > >> On Nov 4, 2014, at 5:48 AM, Laszlo Ersek > > wrote: >> >> diff --git a/MdePkg/Library/BasePrintLib/PrintLibInternal.c >> b/MdePkg/Library/BasePrintLib/PrintLibInternal.c >> index 8dc5ec7..fbb3726 100644 >> --- a/MdePkg/Library/Ba

Re: [edk2] [PATCH v2 2/9] IntelFrameworkModulePkg: BdsDxe: poll keyboard at front page with zero timeout

2014-11-04 Thread Laszlo Ersek
Hi Eric On 10/28/14 08:01, Dong, Eric wrote: > Laszlo, > > I refine the code in ShowProgress(). when TimeoutDefault is zero, BDS > also read key. I have verified it works. Please check this new code. > > Thanks, > Eric > -Original Message- > From: Laszlo Ersek [mailto:ler...@redhat.com]

Re: [edk2] Enable optimization for gcc x64 builds

2014-11-04 Thread Scott Duplichan
Andrew Fish [mailto:af...@apple.com] wrote: Sent: Tuesday, November 04, 2014 11:29 AM To: edk2-devel@lists.sourceforge.net Cc: Paolo Bonzini Subject: Re: [edk2] Enable optimization for gcc x64 builds On Nov 4, 2014, at 5:48 AM, Laszlo Ersek mailto:ler...@redhat.com> > wrote: diff --gi

Re: [edk2] Enable optimization for gcc x64 builds

2014-11-04 Thread Andrew Fish
> On Nov 4, 2014, at 12:15 PM, Scott Duplichan wrote: > > But pedantically you need change the definition of BasePrintLibSPrint() to > include EFIAPI. > > If you look at BasePrintLibSPrintMarker() (and some of the other routines) > you will notice a BASE_LIST and a VA_LIST. We had an API th

[edk2] [PATCH] ShellPkg: Fix timezone command

2014-11-04 Thread Carsey, Jaben
Erik and Tapan, Can you review? [PATCH] ShellPkg: Fix timezone command Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by : Jaben Carsey timezone.patch Description: timezone.patch -- __

Re: [edk2] [PATCH] ShellPkg: Fix timezone command

2014-11-04 Thread Bjorge, Erik C
Reviewed-by: Erik Bjorge From: Carsey, Jaben Sent: Tuesday, November 04, 2014 1:43 PM To: Bjorge, Erik C; Shah, Tapan (tapands...@hp.com) Cc: edk2-devel@lists.sourceforge.net; Carsey, Jaben Subject: [PATCH] ShellPkg: Fix timezone command Erik and Tapan, Can you review? [PATCH] ShellPkg: Fix t

Re: [edk2] [PATCH] ShellPkg: Fix timezone command

2014-11-04 Thread Shah, Tapan
Reviewed-by: Tapan Shah mailto:tapands...@hp.com>> From: Carsey, Jaben [mailto:jaben.car...@intel.com] Sent: Tuesday, November 04, 2014 3:43 PM To: Bjorge, Erik C; Shah, Tapan Cc: edk2-devel@lists.sourceforge.net; Carsey, Jaben Subject: [PATCH] ShellPkg: Fix timezone command Erik and Tapan, Can

Re: [edk2] Enable optimization for gcc x64 builds

2014-11-04 Thread Jordan Justen
On Tue, Nov 4, 2014 at 9:28 AM, Andrew Fish wrote: > So my 1st question is why do you need to mix calling conventions, and depend > on EFIAPI for interoperability. Why not just change the ABI on all > functions? GCC 4.4 doesn't support the command line option to change everything over. So, EFIAPI

Re: [edk2] Enable optimization for gcc x64 builds

2014-11-04 Thread Tim Lewis
Another note (from the archives): vendors used mixed builds for VS2003/VS2005 on 32-bit in order to use __fastcall for internal function calls and then EFIABI for all the various UEFI calls. Tim -Original Message- From: Jordan Justen [mailto:jljus...@gmail.com] Sent: Tuesday, November

Re: [edk2] Enable optimization for gcc x64 builds

2014-11-04 Thread Andrew Fish
> On Nov 4, 2014, at 2:32 PM, Jordan Justen wrote: > > On Tue, Nov 4, 2014 at 9:28 AM, Andrew Fish wrote: >> So my 1st question is why do you need to mix calling conventions, and depend >> on EFIAPI for interoperability. Why not just change the ABI on all >> functions? > > GCC 4.4 doesn't supp

[edk2] [PATCH RFC v2] MdeModulePkg/PartitionDxe: Add UDF/ECMA-167 filesystem support

2014-11-04 Thread Paulo Alcantara
The UDF bridge format allows UDF discs to be used with other filesystems. The UDF filesystem must be located in the last disc session as per specification. An UDF bridge disc will normally contain both ISO-9660 and UDF filesystems. Since the first sectors from 0 up to 15 are reserved as System are