2 Include flie for basic command line parser for EBL (Embedded Boot Loader)
4 Copyright (c) 2007, Intel Corporation<BR>
5 Portions copyright (c) 2008-2009 Apple Inc. All rights reserved.<BR>
7 All rights reserved. This program and the accompanying materials
8 are licensed and made available under the terms and conditions of the BSD License
9 which accompanies this distribution. The full text of the license may be found at
10 http://opensource.org/licenses/bsd-license.php
12 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
13 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
21 #include <Protocol/BlockIo.h>
22 #include <Protocol/SimpleFileSystem.h>
23 #include <Protocol/FirmwareVolume2.h>
24 #include <Protocol/LoadFile.h>
25 #include <Protocol/FirmwareVolumeBlock.h>
26 #include <Protocol/PxeBaseCode.h>
27 #include <Protocol/LoadedImage.h>
28 #include <Protocol/EblAddCommand.h>
29 #include <Protocol/PciIo.h>
30 #include <Protocol/DevicePath.h>
32 #include <Guid/FileInfo.h>
33 #include <Guid/DxeServices.h>
34 #include <Guid/MemoryTypeInformation.h>
35 #include <Guid/MemoryAllocationHob.h>
36 #include <Library/BaseLib.h>
37 #include <Library/MemoryAllocationLib.h>
38 #include <Library/DevicePathLib.h>
39 #include <Library/PrintLib.h>
40 #include <Library/BaseMemoryLib.h>
41 #include <Library/UefiLib.h>
42 #include <Library/UefiBootServicesTableLib.h>
43 #include <Library/UefiRuntimeServicesTableLib.h>
44 #include <Library/DebugLib.h>
45 #include <Library/EfiFileLib.h>
46 #include <Library/HobLib.h>
47 #include <Library/DebugLib.h>
48 #include <Library/IoLib.h>
49 #include <Library/PcdLib.h>
50 #include <Library/EblCmdLib.h>
51 #include <Library/DevicePathLib.h>
52 #include <Library/UefiLib.h>
53 #include <Library/EblNetworkLib.h>
55 #include <IndustryStandard/Pci.h>
58 // Prompt for the command line
60 #define CMD_SEPERATOR ';'
61 #define EBL_MAX_COMMAND_COUNT 0x100
62 #define MAX_CMD_HISTORY 16
63 #define MAX_CMD_LINE 256
69 #define EFI_SET_TIMER_TO_SECOND 10000000
82 OUT EFI_HANDLE
*DeviceHandle
,
83 OUT EFI_DEVICE_PATH_PROTOCOL
**PathDevicePath
,
89 EblAnyKeyToContinueQtoQuit (
91 IN BOOLEAN PrefixNewline
95 EblUpdateDeviceLists (
100 EblInitializeCmdTable (
105 EblShutdownExternalCmdTable (
117 IN OUT EFI_INPUT_KEY
*Key
,
118 IN UINTN TimoutInSec
,
119 IN EBL_GET_CHAR_CALL_BACK CallBack OPTIONAL
122 // BugBug: Move me to a library
126 IN CONST CHAR8
*FirstString
,
127 IN CONST CHAR8
*SecondString
,
133 EblInitializeDeviceCmd (
138 EblInitializemdHwDebugCmds (
143 EblInitializeDirCmd (
148 EblInitializeHobCmd (
153 EblInitializemdHwIoDebugCmds (
158 EblInitializeScriptCmd (
163 EblInitializeNetworkCmd (
177 IN UINTN MaxCmdLineSize
189 WidthFromCommandName (
195 extern UINTN gScreenColumns
;
196 extern UINTN gScreenRows
;
197 extern BOOLEAN gPageBreak
;
198 extern CHAR8
*gMemMapType
[];