]> git.proxmox.com Git - mirror_edk2.git/blame - ShellPkg/DynamicCommand/TftpDynamicCommand/Tftp.h
ShellPkg/tftp: Convert from NULL class library to Dynamic Command
[mirror_edk2.git] / ShellPkg / DynamicCommand / TftpDynamicCommand / Tftp.h
CommitLineData
68074260 1/** @file\r
09610023 2 Header file for 'tftp' command functions.\r
68074260 3\r
09610023 4 Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved. <BR>\r
68074260
RC
5 Copyright (c) 2015, ARM Ltd. All rights reserved.<BR>\r
6\r
7 This program and the accompanying materials\r
8 are licensed and made available under the terms and conditions of the BSD License\r
9 which accompanies this distribution. The full text of the license may be found at\r
10 http://opensource.org/licenses/bsd-license.php\r
11\r
12 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
13 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
14\r
15**/\r
16\r
09610023
RN
17#ifndef _TFTP_H_\r
18#define _TFTP_H_\r
68074260
RC
19\r
20#include <Uefi.h>\r
68074260 21\r
09610023 22#include <Protocol/HiiPackageList.h>\r
68074260
RC
23#include <Protocol/ServiceBinding.h>\r
24#include <Protocol/Mtftp4.h>\r
25\r
26#include <Library/BaseLib.h>\r
27#include <Library/BaseMemoryLib.h>\r
28#include <Library/DebugLib.h>\r
29#include <Library/MemoryAllocationLib.h>\r
68074260
RC
30#include <Library/ShellLib.h>\r
31#include <Library/UefiLib.h>\r
32#include <Library/UefiRuntimeServicesTableLib.h>\r
33#include <Library/UefiBootServicesTableLib.h>\r
34#include <Library/HiiLib.h>\r
35#include <Library/NetLib.h>\r
36#include <Library/PrintLib.h>\r
09610023 37#include <Library/UefiHiiServicesLib.h>\r
68074260 38\r
09610023 39extern EFI_HANDLE mTftpHiiHandle;\r
68074260
RC
40\r
41typedef struct {\r
6add86ab
JC
42 UINTN FileSize;\r
43 UINTN DownloadedNbOfBytes;\r
44 UINTN LastReportedNbOfBytes;\r
68074260
RC
45} DOWNLOAD_CONTEXT;\r
46\r
47/**\r
48 Function for 'tftp' command.\r
49\r
09610023
RN
50 @param[in] ImageHandle The image handle.\r
51 @param[in] SystemTable The system table.\r
52\r
53 @retval SHELL_SUCCESS Command completed successfully.\r
54 @retval SHELL_INVALID_PARAMETER Command usage error.\r
55 @retval SHELL_ABORTED The user aborts the operation.\r
56 @retval value Unknown error.\r
68074260
RC
57**/\r
58SHELL_STATUS\r
09610023 59RunTftp (\r
68074260
RC
60 IN EFI_HANDLE ImageHandle,\r
61 IN EFI_SYSTEM_TABLE *SystemTable\r
62 );\r
63\r
09610023
RN
64/**\r
65 Retrive HII package list from ImageHandle and publish to HII database.\r
66\r
67 @param ImageHandle The image handle of the process.\r
68\r
69 @return HII handle.\r
70**/\r
71EFI_HANDLE\r
72InitializeHiiPackage (\r
73 EFI_HANDLE ImageHandle\r
74 );\r
75#endif // _TFTP_H_\r