Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-04 Thread Ni, Ruiyu
On 3/3/2018 11:10 PM, Laszlo Ersek wrote: Hi Ray, On 03/02/18 12:57, Ni, Ruiyu wrote: On 3/2/2018 7:45 PM, Laszlo Ersek wrote: On 03/02/18 06:58, Jian J Wang wrote: if PcdDxeNxMemoryProtectionPolicy is enabled for EfiReservedMemoryType of memory, #PF will be triggered for each APs after ExitB

Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-03 Thread Laszlo Ersek
Hi Ray, On 03/02/18 12:57, Ni, Ruiyu wrote: > On 3/2/2018 7:45 PM, Laszlo Ersek wrote: >> On 03/02/18 06:58, Jian J Wang wrote: >>> if PcdDxeNxMemoryProtectionPolicy is enabled for EfiReservedMemoryType >>> of memory, #PF will be triggered for each APs after ExitBootServices >>> in SCRT test. The

[edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-03 Thread Jian J Wang
> v2 changes: > a. Reserve memory of mReservedApLoopFunc and mReservedTopOfApStack >separately to avoid making mReservedTopOfApStack executable. if PcdDxeNxMemoryProtectionPolicy is enabled for EfiReservedMemoryType of memory, #PF will be triggered for each APs after ExitBootServices in SCRT t

Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-03 Thread Wang, Jian J
Ruiyu ; Laszlo Ersek ; edk2- > de...@lists.01.org > Cc: Dong, Eric > Subject: Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc > in executable memory > > > Will MEMORY_XP be recorded in GCD in future? > > Based on today's implementation, I prefer to

Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-03 Thread Wang, Jian J
> Will MEMORY_XP be recorded in GCD in future? > Based on today's implementation, I prefer to not check. > Yes, it's in plan. Since it will impact the memory map layout, we have to be very careful to make those changes and do thorough OS boot tests. Regards, Jian > -Original Message- >

Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-02 Thread Ni, Ruiyu
Thanks/Ray > -Original Message- > From: Wang, Jian J > Sent: Saturday, March 3, 2018 9:32 AM > To: Ni, Ruiyu ; Laszlo Ersek ; > edk2-devel@lists.01.org > Cc: Dong, Eric > Subject: RE: [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in > executable memory > > > > Regards, > Jian

Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-02 Thread Wang, Jian J
Regards, Jian > -Original Message- > From: Ni, Ruiyu > Sent: Friday, March 02, 2018 7:58 PM > To: Laszlo Ersek ; Wang, Jian J ; > edk2-devel@lists.01.org > Cc: Dong, Eric > Subject: Re: [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in > executable memory > > On 3/2/2018 7:45 P

Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-02 Thread Ni, Ruiyu
On 3/2/2018 7:45 PM, Laszlo Ersek wrote: On 03/02/18 06:58, Jian J Wang wrote: if PcdDxeNxMemoryProtectionPolicy is enabled for EfiReservedMemoryType of memory, #PF will be triggered for each APs after ExitBootServices in SCRT test. The root cause is that AP wakeup code executed at that time is

Re: [edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-02 Thread Laszlo Ersek
On 03/02/18 06:58, Jian J Wang wrote: > if PcdDxeNxMemoryProtectionPolicy is enabled for EfiReservedMemoryType > of memory, #PF will be triggered for each APs after ExitBootServices > in SCRT test. The root cause is that AP wakeup code executed at that > time is stored in memory of type EfiReserved

[edk2] [PATCH] UefiCpuPkg/MpInitLib: put mReservedApLoopFunc in executable memory

2018-03-01 Thread Jian J Wang
if PcdDxeNxMemoryProtectionPolicy is enabled for EfiReservedMemoryType of memory, #PF will be triggered for each APs after ExitBootServices in SCRT test. The root cause is that AP wakeup code executed at that time is stored in memory of type EfiReservedMemoryType (referenced by global mReservedApLo