[edk2-devel] [PATCH 0/2] Reserve page 0 for NULL pointer detection

Wang, Jian J jian.j.wang at intel.com
Sat Nov 9 03:03:58 UTC 2019


Pushed at fb92fe9e1817a53ca0fc985447f3c534201a62fa

Regards,
Jian

> -----Original Message-----
> From: Ni, Ray <ray.ni at intel.com>
> Sent: Thursday, November 07, 2019 10:11 AM
> To: Wang, Jian J <jian.j.wang at intel.com>; devel at edk2.groups.io
> Cc: Bi, Dandan <dandan.bi at intel.com>; Gao, Liming <liming.gao at intel.com>;
> Wu, Hao A <hao.a.wu at intel.com>; Sean Brogan <sean.brogan at microsoft.com>
> Subject: RE: [PATCH 0/2] Reserve page 0 for NULL pointer detection
> 
> Reviewed-by: Ray Ni <ray.ni at intel.com>
> 
> > -----Original Message-----
> > From: Wang, Jian J <jian.j.wang at intel.com>
> > Sent: Wednesday, November 6, 2019 9:14 PM
> > To: devel at edk2.groups.io
> > Cc: Bi, Dandan <dandan.bi at intel.com>; Gao, Liming <liming.gao at intel.com>;
> Ni, Ray <ray.ni at intel.com>; Wu, Hao A
> > <hao.a.wu at intel.com>; Sean Brogan <sean.brogan at microsoft.com>
> > Subject: [PATCH 0/2] Reserve page 0 for NULL pointer detection
> >
> > When a boot loader examines the memory map, it can see that location 0
> > is available memory. If it chooses to use that memory, and
> > PcdNullPointerDetectionPropertyMask is enabled, use of memory in page 0
> > will cause an exception. This does occur when running the memtest86
> > program.
> >
> > Leaving page 0 available is for legacy support purpose. Since we have
> > deprecated the support of legacy, the solution is just reserving it so
> > that it cannot be allocated for other uses.
> >
> > Tests:
> >   - run memtest86 with PcdNullPointerDetectionPropertyMask set to 0x03
> >   - run memtest86 with PcdNullPointerDetectionPropertyMask set to 0x83
> >   - boot OVMF into Windows 7 with PcdNullPointerDetectionPropertyMask set
> to 0x83
> >
> > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1885
> > Cc: Dandan Bi <dandan.bi at intel.com>
> > Cc: Liming Gao <liming.gao at intel.com>
> > Cc: Ray Ni <ray.ni at intel.com>
> > Cc: Hao A Wu <hao.a.wu at intel.com>
> > Cc: Sean Brogan <sean.brogan at microsoft.com>
> >
> > Jian J Wang (2):
> >   MdeModulePkg/DxeIplPeim: reserve page 0 for NULL pointer detection
> >   MdeModulePkg/Core/Dxe: free page 0 after disabling NULL pointer
> >     detection
> >
> >  MdeModulePkg/Core/Dxe/Misc/MemoryProtection.c   | 5 +++++
> >  MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c | 4 ++++
> >  MdeModulePkg/Core/DxeIplPeim/X64/DxeLoadFunc.c  | 4 ++++
> >  3 files changed, 13 insertions(+)
> >
> > --
> > 2.17.1.windows.2


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50316): https://edk2.groups.io/g/devel/message/50316
Mute This Topic: https://groups.io/mt/44036050/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-





More information about the edk2-devel-archive mailing list