]> git.proxmox.com Git - mirror_edk2.git/blame_incremental - ShellPkg/DynamicCommand/TftpDynamicCommand/Tftp.h
ShellPkg: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / ShellPkg / DynamicCommand / TftpDynamicCommand / Tftp.h
... / ...
CommitLineData
1/** @file\r
2 Header file for 'tftp' command functions.\r
3\r
4 Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved. <BR>\r
5 Copyright (c) 2015, ARM Ltd. All rights reserved.<BR>\r
6\r
7 SPDX-License-Identifier: BSD-2-Clause-Patent\r
8\r
9**/\r
10\r
11#ifndef _TFTP_H_\r
12#define _TFTP_H_\r
13\r
14#include <Uefi.h>\r
15\r
16#include <Protocol/HiiPackageList.h>\r
17#include <Protocol/ServiceBinding.h>\r
18#include <Protocol/Mtftp4.h>\r
19\r
20#include <Library/BaseLib.h>\r
21#include <Library/BaseMemoryLib.h>\r
22#include <Library/DebugLib.h>\r
23#include <Library/MemoryAllocationLib.h>\r
24#include <Library/ShellLib.h>\r
25#include <Library/UefiLib.h>\r
26#include <Library/UefiRuntimeServicesTableLib.h>\r
27#include <Library/UefiBootServicesTableLib.h>\r
28#include <Library/HiiLib.h>\r
29#include <Library/NetLib.h>\r
30#include <Library/PrintLib.h>\r
31#include <Library/UefiHiiServicesLib.h>\r
32\r
33extern EFI_HANDLE mTftpHiiHandle;\r
34\r
35typedef struct {\r
36 UINTN FileSize;\r
37 UINTN DownloadedNbOfBytes;\r
38 UINTN LastReportedNbOfBytes;\r
39} DOWNLOAD_CONTEXT;\r
40\r
41/**\r
42 Function for 'tftp' command.\r
43\r
44 @param[in] ImageHandle The image handle.\r
45 @param[in] SystemTable The system table.\r
46\r
47 @retval SHELL_SUCCESS Command completed successfully.\r
48 @retval SHELL_INVALID_PARAMETER Command usage error.\r
49 @retval SHELL_ABORTED The user aborts the operation.\r
50 @retval value Unknown error.\r
51**/\r
52SHELL_STATUS\r
53RunTftp (\r
54 IN EFI_HANDLE ImageHandle,\r
55 IN EFI_SYSTEM_TABLE *SystemTable\r
56 );\r
57\r
58/**\r
59 Retrive HII package list from ImageHandle and publish to HII database.\r
60\r
61 @param ImageHandle The image handle of the process.\r
62\r
63 @return HII handle.\r
64**/\r
65EFI_HANDLE\r
66InitializeHiiPackage (\r
67 EFI_HANDLE ImageHandle\r
68 );\r
69#endif // _TFTP_H_\r