Reviewed-by: Ray Ni <ray.ni@intel.com>
> -----Original Message-----
> From: Xu, Min M <min.m.xu@intel.com>
> Sent: Monday, June 6, 2022 11:00 AM
> To: devel@edk2.groups.io
> Cc: Xu, Min M <min.m.xu@intel.com>; Ni, Ray <ray.ni@intel.com>; Gao, Zhichao <zhichao.gao@intel.com>; Aktas, Erdem
> <erdemaktas@google.com>; Gerd Hoffmann <kraxel@redhat.com>; James Bottomley <jejb@linux.ibm.com>; Yao, Jiewen
> <jiewen.yao@intel.com>; Tom Lendacky <thomas.lendacky@amd.com>
> Subject: [PATCH 06/14] ShellPkg: Update shell command memmap to show unaccepted memory
>
> From: Min M Xu <min.m.xu@intel.com>
>
> RFC: https://bugzilla.tianocore.org/show_bug.cgi?id=3937
>
> ShellCommandRunMemMap() is updated to handle the case of unaccepted
> memory type.
>
> Cc: Ray Ni <ray.ni@intel.com>
> Cc: Zhichao Gao <zhichao.gao@intel.com>
> Cc: Erdem Aktas <erdemaktas@google.com>
> Cc: Gerd Hoffmann <kraxel@redhat.com>
> Cc: James Bottomley <jejb@linux.ibm.com>
> Cc: Jiewen Yao <jiewen.yao@intel.com>
> Cc: Tom Lendacky <thomas.lendacky@amd.com>
> Signed-off-by: Min Xu <min.m.xu@intel.com>
> ---
> ShellPkg/Library/UefiShellDebug1CommandsLib/MemMap.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/MemMap.c
> b/ShellPkg/Library/UefiShellDebug1CommandsLib/MemMap.c
> index 72f3c58b0970..41994ae709ce 100644
> --- a/ShellPkg/Library/UefiShellDebug1CommandsLib/MemMap.c
> +++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/MemMap.c
> @@ -26,6 +26,7 @@ STATIC CONST CHAR16 NameEfiACPIMemoryNVS[] = L"ACPIMemoryNVS";
> STATIC CONST CHAR16 NameEfiMemoryMappedIO[] = L"MemoryMappedIO";
> STATIC CONST CHAR16 NameEfiMemoryMappedIOPortSpace[] = L"MemoryMappedIOPortSpace";
> STATIC CONST CHAR16 NameEfiPalCode[] = L"PalCode";
> +STATIC CONST CHAR16 NameEfiUnacceptedMemory[] = L"Unaccepted";
>
> //
> // Need short names for some memory types
> @@ -303,6 +304,11 @@ ShellCommandRunMemMap (
> TotalPages += Walker->NumberOfPages;
> PalCodePages += Walker->NumberOfPages;
> break;
> + case EfiUnacceptedMemory:
> + ShellPrintHiiEx (-1, -1, NULL, (EFI_STRING_ID)(!Sfo ? STRING_TOKEN (STR_MEMMAP_LIST_ITEM) : STRING_TOKEN
> (STR_MEMMAP_LIST_ITEM_SFO)), gShellDebug1HiiHandle, NameEfiUnacceptedMemory, Walker->PhysicalStart, Walker-
> >PhysicalStart+MultU64x64 (SIZE_4KB, Walker->NumberOfPages)-1, Walker->NumberOfPages, Walker->Attribute);
> + TotalPages += Walker->NumberOfPages;
> + PalCodePages += Walker->NumberOfPages;
> + break;
> default:
> //
> // Shell Spec defines the SFO format.
> --
> 2.29.2.windows.2
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#90231): https://edk2.groups.io/g/devel/message/90231
Mute This Topic: https://groups.io/mt/91570201/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-