TianoCore EDK2 master
Loading...
Searching...
No Matches
HttpBootClient.h
Go to the documentation of this file.
1
10#ifndef __EFI_HTTP_BOOT_HTTP_H__
11#define __EFI_HTTP_BOOT_HTTP_H__
12
13#define HTTP_BOOT_BLOCK_SIZE 32000
14#define HTTP_USER_AGENT_EFI_HTTP_BOOT "UefiHttpBoot/1.0"
15#define HTTP_BOOT_AUTHENTICATION_INFO_MAX_LEN 255
16
17//
18// Record the data length and start address of a data block.
19//
20typedef struct {
21 LIST_ENTRY Link; // Link to the EntityDataList in HTTP_BOOT_CACHE_CONTENT
22 UINT8 *Block; // If NULL, the data is in previous data block.
23 UINT8 *DataStart; // Point to somewhere in the Block
24 UINTN DataLength;
26
27//
28// Structure for a cache item
29//
30typedef struct {
31 LIST_ENTRY Link; // Link to the CacheList in driver's private data.
32 EFI_HTTP_REQUEST_DATA *RequestData;
33 HTTP_IO_RESPONSE_DATA *ResponseData; // Not include any message-body data.
34 HTTP_BOOT_IMAGE_TYPE ImageType;
35 UINTN EntityLength;
36 LIST_ENTRY EntityDataList; // Entity data (message-body)
38
39//
40// Callback data for HTTP_BODY_PARSER_CALLBACK()
41//
42typedef struct {
43 EFI_STATUS Status;
44 //
45 // Cache info.
46 //
48 BOOLEAN NewBlock;
49 UINT8 *Block;
50
51 //
52 // Caller provided buffer to load the file in.
53 //
54 UINTN CopyedSize;
55 UINTN BufferSize;
56 UINT8 *Buffer;
57
60
73 );
74
87 );
88
117 IN HTTP_BOOT_PRIVATE_DATA *Private,
118 IN BOOLEAN HeaderOnly,
119 IN OUT UINTN *BufferSize,
120 OUT UINT8 *Buffer,
121 OUT HTTP_BOOT_IMAGE_TYPE *ImageType
122 );
123
130VOID
133 );
134
135#endif
UINT64 UINTN
EFI_STATUS HttpBootCreateHttpIo(IN HTTP_BOOT_PRIVATE_DATA *Private)
EFI_STATUS HttpBootDiscoverBootInfo(IN OUT HTTP_BOOT_PRIVATE_DATA *Private)
EFI_STATUS HttpBootGetBootFile(IN HTTP_BOOT_PRIVATE_DATA *Private, IN BOOLEAN HeaderOnly, IN OUT UINTN *BufferSize, OUT UINT8 *Buffer, OUT HTTP_BOOT_IMAGE_TYPE *ImageType)
VOID HttpBootFreeCacheList(IN HTTP_BOOT_PRIVATE_DATA *Private)
#define IN
Definition: Base.h:279
#define OUT
Definition: Base.h:284
RETURN_STATUS EFI_STATUS
Definition: UefiBaseType.h:29