]> git.proxmox.com Git - mirror_edk2.git/blob - ShellPkg/DynamicCommand/DpDynamicCommand/DpApp.c
UefiCpuPkg: Move AsmRelocateApLoopStart from Mpfuncs.nasm to AmdSev.nasm
[mirror_edk2.git] / ShellPkg / DynamicCommand / DpDynamicCommand / DpApp.c
1 /** @file
2 Entrypoint of "dp" shell standalone application.
3
4 Copyright (c) 2017, Intel Corporation. All rights reserved. <BR>
5
6 SPDX-License-Identifier: BSD-2-Clause-Patent
7
8 **/
9 #include "Dp.h"
10
11 //
12 // String token ID of help message text.
13 // Shell supports to find help message in the resource section of an application image if
14 // .MAN file is not found. This global variable is added to make build tool recognizes
15 // that the help string is consumed by user and then build tool will add the string into
16 // the resource section. Thus the application can use '-?' option to show help message in
17 // Shell.
18 //
19 GLOBAL_REMOVE_IF_UNREFERENCED EFI_STRING_ID mStringHelpTokenId = STRING_TOKEN (STR_GET_HELP_DP);
20
21 /**
22 Entry point of Tftp standalone application.
23
24 @param ImageHandle The image handle of the process.
25 @param SystemTable The EFI System Table pointer.
26
27 @retval EFI_SUCCESS Tftp command is executed successfully.
28 @retval EFI_ABORTED HII package was failed to initialize.
29 @retval others Other errors when executing tftp command.
30 **/
31 EFI_STATUS
32 EFIAPI
33 DpAppInitialize (
34 IN EFI_HANDLE ImageHandle,
35 IN EFI_SYSTEM_TABLE *SystemTable
36 )
37 {
38 EFI_STATUS Status;
39
40 mDpHiiHandle = InitializeHiiPackage (ImageHandle);
41 if (mDpHiiHandle == NULL) {
42 return EFI_ABORTED;
43 }
44
45 Status = (EFI_STATUS)RunDp (ImageHandle, SystemTable);
46 HiiRemovePackages (mDpHiiHandle);
47 return Status;
48 }