1 /** @file 2 Main file for NULL named library for Profile1 shell command functions. 3 4 Copyright (c) 2010 - 2014, Intel Corporation. All rights reserved.<BR> 5 This program and the accompanying materials 6 are licensed and made available under the terms and conditions of the BSD License 7 which accompanies this distribution. The full text of the license may be found at 8 http://opensource.org/licenses/bsd-license.php 9 10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. 12 13 **/ 14 15 #ifndef _UEFI_SHELL_DRIVER1_COMMANDS_LIB_H_ 16 #define _UEFI_SHELL_DRIVER1_COMMANDS_LIB_H_ 17 18 #include <Uefi.h> 19 #include <ShellBase.h> 20 21 #include <Guid/GlobalVariable.h> 22 #include <Guid/ConsoleInDevice.h> 23 #include <Guid/ConsoleOutDevice.h> 24 #include <Guid/ShellLibHiiGuid.h> 25 26 #include <IndustryStandard/Pci.h> 27 28 #include <Protocol/EfiShell.h> 29 #include <Protocol/EfiShellParameters.h> 30 #include <Protocol/DevicePath.h> 31 #include <Protocol/LoadedImage.h> 32 #include <Protocol/UnicodeCollation.h> 33 #include <Protocol/DriverDiagnostics2.h> 34 #include <Protocol/DriverDiagnostics.h> 35 #include <Protocol/PlatformDriverOverride.h> 36 #include <Protocol/BusSpecificDriverOverride.h> 37 #include <Protocol/PlatformToDriverConfiguration.h> 38 #include <Protocol/DriverSupportedEfiVersion.h> 39 #include <Protocol/DriverFamilyOverride.h> 40 #include <Protocol/DriverHealth.h> 41 #include <Protocol/PciIo.h> 42 #include <Protocol/PciRootBridgeIo.h> 43 44 #include <Library/BaseLib.h> 45 #include <Library/BaseMemoryLib.h> 46 #include <Library/DebugLib.h> 47 #include <Library/MemoryAllocationLib.h> 48 #include <Library/PcdLib.h> 49 #include <Library/ShellCommandLib.h> 50 #include <Library/ShellLib.h> 51 #include <Library/SortLib.h> 52 #include <Library/UefiLib.h> 53 #include <Library/UefiRuntimeServicesTableLib.h> 54 #include <Library/UefiBootServicesTableLib.h> 55 #include <Library/HiiLib.h> 56 #include <Library/FileHandleLib.h> 57 #include <Library/DevicePathLib.h> 58 #include <Library/PrintLib.h> 59 #include <Library/HandleParsingLib.h> 60 #include <Library/PeCoffGetEntryPointLib.h> 61 #include <Library/HandleParsingLib.h> 62 63 64 extern EFI_HANDLE gShellDriver1HiiHandle; 65 extern BOOLEAN gInReconnect; 66 67 /** 68 Function for 'connect' command. 69 70 @param[in] ImageHandle Handle to the Image (NULL if Internal). 71 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 72 **/ 73 SHELL_STATUS 74 EFIAPI 75 ShellCommandRunConnect ( 76 IN EFI_HANDLE ImageHandle, 77 IN EFI_SYSTEM_TABLE *SystemTable 78 ); 79 80 /** 81 Function for 'devices' command. 82 83 @param[in] ImageHandle Handle to the Image (NULL if Internal). 84 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 85 **/ 86 SHELL_STATUS 87 EFIAPI 88 ShellCommandRunDevices ( 89 IN EFI_HANDLE ImageHandle, 90 IN EFI_SYSTEM_TABLE *SystemTable 91 ); 92 93 /** 94 Function for 'openinfo' command. 95 96 @param[in] ImageHandle Handle to the Image (NULL if Internal). 97 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 98 **/ 99 SHELL_STATUS 100 EFIAPI 101 ShellCommandRunOpenInfo ( 102 IN EFI_HANDLE ImageHandle, 103 IN EFI_SYSTEM_TABLE *SystemTable 104 ); 105 106 /** 107 Function for 'devtree' command. 108 109 @param[in] ImageHandle Handle to the Image (NULL if Internal). 110 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 111 **/ 112 SHELL_STATUS 113 EFIAPI 114 ShellCommandRunDevTree ( 115 IN EFI_HANDLE ImageHandle, 116 IN EFI_SYSTEM_TABLE *SystemTable 117 ); 118 119 /** 120 Function for 'dh' command. 121 122 @param[in] ImageHandle Handle to the Image (NULL if Internal). 123 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 124 **/ 125 SHELL_STATUS 126 EFIAPI 127 ShellCommandRunDh ( 128 IN EFI_HANDLE ImageHandle, 129 IN EFI_SYSTEM_TABLE *SystemTable 130 ); 131 132 /** 133 Function for 'disconnect' command. 134 135 @param[in] ImageHandle Handle to the Image (NULL if Internal). 136 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 137 **/ 138 SHELL_STATUS 139 EFIAPI 140 ShellCommandRunDisconnect ( 141 IN EFI_HANDLE ImageHandle, 142 IN EFI_SYSTEM_TABLE *SystemTable 143 ); 144 145 /** 146 Function for 'drivers' command. 147 148 @param[in] ImageHandle Handle to the Image (NULL if Internal). 149 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 150 **/ 151 SHELL_STATUS 152 EFIAPI 153 ShellCommandRunDrivers ( 154 IN EFI_HANDLE ImageHandle, 155 IN EFI_SYSTEM_TABLE *SystemTable 156 ); 157 158 /** 159 Function for 'drvcfg' command. 160 161 @param[in] ImageHandle Handle to the Image (NULL if Internal). 162 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 163 **/ 164 SHELL_STATUS 165 EFIAPI 166 ShellCommandRunDrvCfg ( 167 IN EFI_HANDLE ImageHandle, 168 IN EFI_SYSTEM_TABLE *SystemTable 169 ); 170 171 /** 172 Function for 'drvdiag' command. 173 174 @param[in] ImageHandle Handle to the Image (NULL if Internal). 175 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 176 **/ 177 SHELL_STATUS 178 EFIAPI 179 ShellCommandRunDrvDiag ( 180 IN EFI_HANDLE ImageHandle, 181 IN EFI_SYSTEM_TABLE *SystemTable 182 ); 183 184 /** 185 Function for 'reconnect' command. 186 187 @param[in] ImageHandle Handle to the Image (NULL if Internal). 188 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 189 **/ 190 SHELL_STATUS 191 EFIAPI 192 ShellCommandRunReconnect ( 193 IN EFI_HANDLE ImageHandle, 194 IN EFI_SYSTEM_TABLE *SystemTable 195 ); 196 197 /** 198 Function for 'unload' command. 199 200 @param[in] ImageHandle Handle to the Image (NULL if Internal). 201 @param[in] SystemTable Pointer to the System Table (NULL if Internal). 202 **/ 203 SHELL_STATUS 204 EFIAPI 205 ShellCommandRunUnload ( 206 IN EFI_HANDLE ImageHandle, 207 IN EFI_SYSTEM_TABLE *SystemTable 208 ); 209 210 /** 211 Do a connect from an EFI variable via it's key name. 212 213 @param[in] Key The name of the EFI Variable. 214 215 @retval EFI_SUCCESS The operation was successful. 216 **/ 217 EFI_STATUS 218 EFIAPI 219 ShellConnectFromDevPaths ( 220 IN CONST CHAR16 *Key 221 ); 222 223 224 225 #endif 226 227