--- /dev/null
+/** @file\r
+ Library providing 'acpiview' functionality to display and\r
+ validate installed ACPI tables.\r
+\r
+ Copyright (c) 2016 - 2020, ARM Limited. All rights reserved.<BR>\r
+ SPDX-License-Identifier: BSD-2-Clause-Patent\r
+**/\r
+\r
+#ifndef ACPI_VIEW_COMMAND_LIB_H_\r
+#define ACPI_VIEW_COMMAND_LIB_H_\r
+\r
+/**\r
+ Dump a buffer to a file. Print error message if a file cannot be created.\r
+\r
+ @param[in] FileName The filename that shall be created to contain the buffer.\r
+ @param[in] Buffer Pointer to buffer that shall be dumped.\r
+ @param[in] BufferSize The size of buffer to be dumped in bytes.\r
+\r
+ @return The number of bytes that were written\r
+**/\r
+UINTN\r
+EFIAPI\r
+ShellDumpBufferToFile (\r
+ IN CONST CHAR16* FileNameBuffer,\r
+ IN CONST VOID* Buffer,\r
+ IN CONST UINTN BufferSize\r
+ );\r
+\r
+/**\r
+ Display and validate ACPI tables.\r
+\r
+ @param[in] ImageHandle Handle to the Image (NULL if internal).\r
+ @param[in] SystemTable Pointer to the System Table (NULL if internal).\r
+\r
+ @retval SHELL_INVALID_PARAMETER The command line invocation could not be parsed.\r
+ @retval SHELL_NOT_FOUND The command failed.\r
+ @retval SHELL_SUCCESS The command was successful.\r
+**/\r
+SHELL_STATUS\r
+EFIAPI\r
+ShellCommandRunAcpiView (\r
+ IN EFI_HANDLE ImageHandle,\r
+ IN EFI_SYSTEM_TABLE *SystemTable\r
+ );\r
+\r
+#endif // UEFI_SHELL_ACPIVIEW_COMMAND_LIB_H_\r
#include <Library/BaseMemoryLib.h>\r
#include <Library/DebugLib.h>\r
#include <Library/MemoryAllocationLib.h>\r
+#include <Library/AcpiViewCommandLib.h>\r
#include "AcpiParser.h"\r
#include "AcpiTableParser.h"\r
#include "AcpiView.h"\r
#include "AcpiViewConfig.h"\r
-#include "UefiShellAcpiViewCommandLib.h"\r
\r
#if defined(MDE_CPU_ARM) || defined (MDE_CPU_AARCH64)\r
#include "Arm/SbbrValidator.h"\r
#include <Library/ShellLib.h>\r
#include <Library/UefiBootServicesTableLib.h>\r
#include <Library/UefiLib.h>\r
+#include <Library/AcpiViewCommandLib.h>\r
#include <Uefi.h>\r
\r
#include "AcpiParser.h"\r
#include "AcpiTableParser.h"\r
#include "AcpiView.h"\r
#include "AcpiViewConfig.h"\r
-#include "UefiShellAcpiViewCommandLib.h"\r
\r
CONST CHAR16 gShellAcpiViewFileName[] = L"ShellCommand";\r
EFI_HII_HANDLE gShellAcpiViewHiiHandle = NULL;\r
+++ /dev/null
-/** @file\r
- Header file for 'acpiview' Shell command functions.\r
-\r
- Copyright (c) 2016 - 2020, ARM Limited. All rights reserved.<BR>\r
- SPDX-License-Identifier: BSD-2-Clause-Patent\r
-**/\r
-\r
-#ifndef UEFI_SHELL_ACPIVIEW_COMMAND_LIB_H_\r
-#define UEFI_SHELL_ACPIVIEW_COMMAND_LIB_H_\r
-\r
-/**\r
- Dump a buffer to a file. Print error message if a file cannot be created.\r
-\r
- @param[in] FileName The filename that shall be created to contain the buffer.\r
- @param[in] Buffer Pointer to buffer that shall be dumped.\r
- @param[in] BufferSize The size of buffer to be dumped in bytes.\r
-\r
- @return The number of bytes that were written\r
-**/\r
-UINTN\r
-EFIAPI\r
-ShellDumpBufferToFile (\r
- IN CONST CHAR16* FileNameBuffer,\r
- IN CONST VOID* Buffer,\r
- IN CONST UINTN BufferSize\r
- );\r
-\r
-/**\r
- Function for 'acpiview' command.\r
-\r
- @param[in] ImageHandle Handle to the Image (NULL if internal).\r
- @param[in] SystemTable Pointer to the System Table (NULL if internal).\r
-\r
- @retval SHELL_INVALID_PARAMETER The command line invocation could not be parsed\r
- @retval SHELL_NOT_FOUND The command failed\r
- @retval SHELL_SUCCESS The command was successful\r
-**/\r
-SHELL_STATUS\r
-EFIAPI\r
-ShellCommandRunAcpiView (\r
- IN EFI_HANDLE ImageHandle,\r
- IN EFI_SYSTEM_TABLE *SystemTable\r
- );\r
-\r
-#endif // UEFI_SHELL_ACPIVIEW_COMMAND_LIB_H_\r
FILE_GUID = FB5B305E-84F5-461F-940D-82D345757AFA\r
MODULE_TYPE = UEFI_APPLICATION\r
VERSION_STRING = 1.0\r
- LIBRARY_CLASS = NULL|UEFI_APPLICATION UEFI_DRIVER\r
+ LIBRARY_CLASS = AcpiViewCommandLib|UEFI_APPLICATION UEFI_DRIVER\r
CONSTRUCTOR = UefiShellAcpiViewCommandLibConstructor\r
DESTRUCTOR = UefiShellAcpiViewCommandLibDestructor\r
\r
Parsers/Ssdt/SsdtParser.c\r
Parsers/Xsdt/XsdtParser.c\r
UefiShellAcpiViewCommandLib.c\r
- UefiShellAcpiViewCommandLib.h\r
UefiShellAcpiViewCommandLib.uni\r
\r
[Sources.ARM, Sources.AARCH64]\r
## @libraryclass provides BCFG command\r
BcfgCommandLib|Include/Library/BcfgCommandLib.h\r
\r
+ ## @libraryclass provides the AcpiView command\r
+ AcpiViewCommandLib|Include/Library/AcpiViewCommandLib.h\r
+\r
[Guids]\r
gEfiShellEnvironment2ExtGuid = {0xd2c18636, 0x40e5, 0x4eb5, {0xa3, 0x1b, 0x36, 0x69, 0x5f, 0xd4, 0x2c, 0x87}}\r
gEfiShellPkgTokenSpaceGuid = {0x171e9188, 0x31d3, 0x40f5, {0xb1, 0x0c, 0x53, 0x9b, 0x2d, 0xb9, 0x40, 0xcd}}\r
# Shell Package\r
#\r
# Copyright (c) 2007 - 2019, Intel Corporation. All rights reserved.<BR>\r
-# Copyright (c) 2018, Arm Limited. All rights reserved.<BR>\r
+# Copyright (c) 2018 - 2020, Arm Limited. All rights reserved.<BR>\r
# Copyright (c) 2020, Hewlett Packard Enterprise Development LP. All rights reserved.<BR>\r
#\r
# SPDX-License-Identifier: BSD-2-Clause-Patent\r
\r
PeCoffGetEntryPointLib|MdePkg/Library/BasePeCoffGetEntryPointLib/BasePeCoffGetEntryPointLib.inf\r
BcfgCommandLib|ShellPkg/Library/UefiShellBcfgCommandLib/UefiShellBcfgCommandLib.inf\r
+ AcpiViewCommandLib|ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.inf\r
IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf\r
\r
UefiBootManagerLib|MdeModulePkg/Library/UefiBootManagerLib/UefiBootManagerLib.inf\r