1 /** @file 2 EFI PXE Base Code Protocol definitions, which is used to access PXE-compatible 3 devices for network access and network booting. 4 5 Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> 6 This program and the accompanying materials are licensed and made available under 7 the terms and conditions of the BSD License that accompanies this distribution. 8 The full text of the license may be found at 9 http://opensource.org/licenses/bsd-license.php. 10 11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. 13 14 @par Revision Reference: 15 This Protocol is introduced in EFI Specification 1.10. 16 17 **/ 18 #ifndef __PXE_BASE_CODE_PROTOCOL_H__ 19 #define __PXE_BASE_CODE_PROTOCOL_H__ 20 21 /// 22 /// PXE Base Code protocol. 23 /// 24 #define EFI_PXE_BASE_CODE_PROTOCOL_GUID \ 25 { \ 26 0x03c4e603, 0xac28, 0x11d3, {0x9a, 0x2d, 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d } \ 27 } 28 29 typedef struct _EFI_PXE_BASE_CODE_PROTOCOL EFI_PXE_BASE_CODE_PROTOCOL; 30 31 /// 32 /// Protocol defined in EFI1.1. 33 /// 34 typedef EFI_PXE_BASE_CODE_PROTOCOL EFI_PXE_BASE_CODE; 35 36 /// 37 /// Default IP TTL and ToS. 38 /// 39 #define DEFAULT_TTL 16 40 #define DEFAULT_ToS 0 41 42 /// 43 /// ICMP error format. 44 /// 45 typedef struct { 46 UINT8 Type; 47 UINT8 Code; 48 UINT16 Checksum; 49 union { 50 UINT32 reserved; 51 UINT32 Mtu; 52 UINT32 Pointer; 53 struct { 54 UINT16 Identifier; 55 UINT16 Sequence; 56 } Echo; 57 } u; 58 UINT8 Data[494]; 59 } EFI_PXE_BASE_CODE_ICMP_ERROR; 60 61 /// 62 /// TFTP error format. 63 /// 64 typedef struct { 65 UINT8 ErrorCode; 66 CHAR8 ErrorString[127]; 67 } EFI_PXE_BASE_CODE_TFTP_ERROR; 68 69 /// 70 /// IP Receive Filter definitions. 71 /// 72 #define EFI_PXE_BASE_CODE_MAX_IPCNT 8 73 74 /// 75 /// IP Receive Filter structure. 76 /// 77 typedef struct { 78 UINT8 Filters; 79 UINT8 IpCnt; 80 UINT16 reserved; 81 EFI_IP_ADDRESS IpList[EFI_PXE_BASE_CODE_MAX_IPCNT]; 82 } EFI_PXE_BASE_CODE_IP_FILTER; 83 84 #define EFI_PXE_BASE_CODE_IP_FILTER_STATION_IP 0x0001 85 #define EFI_PXE_BASE_CODE_IP_FILTER_BROADCAST 0x0002 86 #define EFI_PXE_BASE_CODE_IP_FILTER_PROMISCUOUS 0x0004 87 #define EFI_PXE_BASE_CODE_IP_FILTER_PROMISCUOUS_MULTICAST 0x0008 88 89 /// 90 /// ARP cache entries. 91 /// 92 typedef struct { 93 EFI_IP_ADDRESS IpAddr; 94 EFI_MAC_ADDRESS MacAddr; 95 } EFI_PXE_BASE_CODE_ARP_ENTRY; 96 97 /// 98 /// ARP route table entries. 99 /// 100 typedef struct { 101 EFI_IP_ADDRESS IpAddr; 102 EFI_IP_ADDRESS SubnetMask; 103 EFI_IP_ADDRESS GwAddr; 104 } EFI_PXE_BASE_CODE_ROUTE_ENTRY; 105 106 // 107 // UDP definitions 108 // 109 typedef UINT16 EFI_PXE_BASE_CODE_UDP_PORT; 110 111 #define EFI_PXE_BASE_CODE_UDP_OPFLAGS_ANY_SRC_IP 0x0001 112 #define EFI_PXE_BASE_CODE_UDP_OPFLAGS_ANY_SRC_PORT 0x0002 113 #define EFI_PXE_BASE_CODE_UDP_OPFLAGS_ANY_DEST_IP 0x0004 114 #define EFI_PXE_BASE_CODE_UDP_OPFLAGS_ANY_DEST_PORT 0x0008 115 #define EFI_PXE_BASE_CODE_UDP_OPFLAGS_USE_FILTER 0x0010 116 #define EFI_PXE_BASE_CODE_UDP_OPFLAGS_MAY_FRAGMENT 0x0020 117 118 // 119 // Discover() definitions 120 // 121 #define EFI_PXE_BASE_CODE_BOOT_TYPE_BOOTSTRAP 0 122 #define EFI_PXE_BASE_CODE_BOOT_TYPE_MS_WINNT_RIS 1 123 #define EFI_PXE_BASE_CODE_BOOT_TYPE_INTEL_LCM 2 124 #define EFI_PXE_BASE_CODE_BOOT_TYPE_DOSUNDI 3 125 #define EFI_PXE_BASE_CODE_BOOT_TYPE_NEC_ESMPRO 4 126 #define EFI_PXE_BASE_CODE_BOOT_TYPE_IBM_WSoD 5 127 #define EFI_PXE_BASE_CODE_BOOT_TYPE_IBM_LCCM 6 128 #define EFI_PXE_BASE_CODE_BOOT_TYPE_CA_UNICENTER_TNG 7 129 #define EFI_PXE_BASE_CODE_BOOT_TYPE_HP_OPENVIEW 8 130 #define EFI_PXE_BASE_CODE_BOOT_TYPE_ALTIRIS_9 9 131 #define EFI_PXE_BASE_CODE_BOOT_TYPE_ALTIRIS_10 10 132 #define EFI_PXE_BASE_CODE_BOOT_TYPE_ALTIRIS_11 11 133 #define EFI_PXE_BASE_CODE_BOOT_TYPE_NOT_USED_12 12 134 #define EFI_PXE_BASE_CODE_BOOT_TYPE_REDHAT_INSTALL 13 135 #define EFI_PXE_BASE_CODE_BOOT_TYPE_REDHAT_BOOT 14 136 #define EFI_PXE_BASE_CODE_BOOT_TYPE_REMBO 15 137 #define EFI_PXE_BASE_CODE_BOOT_TYPE_BEOBOOT 16 138 // 139 // 17 through 32767 are reserved 140 // 32768 through 65279 are for vendor use 141 // 65280 through 65534 are reserved 142 // 143 #define EFI_PXE_BASE_CODE_BOOT_TYPE_PXETEST 65535 144 145 #define EFI_PXE_BASE_CODE_BOOT_LAYER_MASK 0x7FFF 146 #define EFI_PXE_BASE_CODE_BOOT_LAYER_INITIAL 0x0000 147 148 // 149 // PXE Tag definition that identifies the processor 150 // and programming environment of the client system. 151 // These identifiers are defined by IETF: 152 // http://www.ietf.org/assignments/dhcpv6-parameters/dhcpv6-parameters.xml 153 // 154 #if defined (MDE_CPU_IA32) 155 #define EFI_PXE_CLIENT_SYSTEM_ARCHITECTURE 0x0006 156 #elif defined (MDE_CPU_IPF) 157 #define EFI_PXE_CLIENT_SYSTEM_ARCHITECTURE 0x0002 158 #elif defined (MDE_CPU_X64) 159 #define EFI_PXE_CLIENT_SYSTEM_ARCHITECTURE 0x0007 160 #elif defined (MDE_CPU_ARM) 161 #define EFI_PXE_CLIENT_SYSTEM_ARCHITECTURE 0x000A 162 #elif defined (MDE_CPU_AARCH64) 163 #define EFI_PXE_CLIENT_SYSTEM_ARCHITECTURE 0x000B 164 #endif 165 166 167 /// 168 /// Discover() server list structure. 169 /// 170 typedef struct { 171 UINT16 Type; 172 BOOLEAN AcceptAnyResponse; 173 UINT8 Reserved; 174 EFI_IP_ADDRESS IpAddr; 175 } EFI_PXE_BASE_CODE_SRVLIST; 176 177 /// 178 /// Discover() information override structure. 179 /// 180 typedef struct { 181 BOOLEAN UseMCast; 182 BOOLEAN UseBCast; 183 BOOLEAN UseUCast; 184 BOOLEAN MustUseList; 185 EFI_IP_ADDRESS ServerMCastIp; 186 UINT16 IpCnt; 187 EFI_PXE_BASE_CODE_SRVLIST SrvList[1]; 188 } EFI_PXE_BASE_CODE_DISCOVER_INFO; 189 190 /// 191 /// TFTP opcode definitions. 192 /// 193 typedef enum { 194 EFI_PXE_BASE_CODE_TFTP_FIRST, 195 EFI_PXE_BASE_CODE_TFTP_GET_FILE_SIZE, 196 EFI_PXE_BASE_CODE_TFTP_READ_FILE, 197 EFI_PXE_BASE_CODE_TFTP_WRITE_FILE, 198 EFI_PXE_BASE_CODE_TFTP_READ_DIRECTORY, 199 EFI_PXE_BASE_CODE_MTFTP_GET_FILE_SIZE, 200 EFI_PXE_BASE_CODE_MTFTP_READ_FILE, 201 EFI_PXE_BASE_CODE_MTFTP_READ_DIRECTORY, 202 EFI_PXE_BASE_CODE_MTFTP_LAST 203 } EFI_PXE_BASE_CODE_TFTP_OPCODE; 204 205 /// 206 /// MTFTP information. This information is required 207 /// to start or join a multicast TFTP session. It is also required to 208 /// perform the "get file size" and "read directory" operations of MTFTP. 209 /// 210 typedef struct { 211 EFI_IP_ADDRESS MCastIp; 212 EFI_PXE_BASE_CODE_UDP_PORT CPort; 213 EFI_PXE_BASE_CODE_UDP_PORT SPort; 214 UINT16 ListenTimeout; 215 UINT16 TransmitTimeout; 216 } EFI_PXE_BASE_CODE_MTFTP_INFO; 217 218 /// 219 /// DHCPV4 Packet structure. 220 /// 221 typedef struct { 222 UINT8 BootpOpcode; 223 UINT8 BootpHwType; 224 UINT8 BootpHwAddrLen; 225 UINT8 BootpGateHops; 226 UINT32 BootpIdent; 227 UINT16 BootpSeconds; 228 UINT16 BootpFlags; 229 UINT8 BootpCiAddr[4]; 230 UINT8 BootpYiAddr[4]; 231 UINT8 BootpSiAddr[4]; 232 UINT8 BootpGiAddr[4]; 233 UINT8 BootpHwAddr[16]; 234 UINT8 BootpSrvName[64]; 235 UINT8 BootpBootFile[128]; 236 UINT32 DhcpMagik; 237 UINT8 DhcpOptions[56]; 238 } EFI_PXE_BASE_CODE_DHCPV4_PACKET; 239 240 /// 241 /// DHCPV6 Packet structure. 242 /// 243 typedef struct { 244 UINT32 MessageType:8; 245 UINT32 TransactionId:24; 246 UINT8 DhcpOptions[1024]; 247 } EFI_PXE_BASE_CODE_DHCPV6_PACKET; 248 249 /// 250 /// Packet structure. 251 /// 252 typedef union { 253 UINT8 Raw[1472]; 254 EFI_PXE_BASE_CODE_DHCPV4_PACKET Dhcpv4; 255 EFI_PXE_BASE_CODE_DHCPV6_PACKET Dhcpv6; 256 } EFI_PXE_BASE_CODE_PACKET; 257 258 // 259 // PXE Base Code Mode structure 260 // 261 #define EFI_PXE_BASE_CODE_MAX_ARP_ENTRIES 8 262 #define EFI_PXE_BASE_CODE_MAX_ROUTE_ENTRIES 8 263 264 /// 265 /// EFI_PXE_BASE_CODE_MODE. 266 /// The data values in this structure are read-only and 267 /// are updated by the code that produces the 268 /// EFI_PXE_BASE_CODE_PROTOCOL functions. 269 /// 270 typedef struct { 271 BOOLEAN Started; 272 BOOLEAN Ipv6Available; 273 BOOLEAN Ipv6Supported; 274 BOOLEAN UsingIpv6; 275 BOOLEAN BisSupported; 276 BOOLEAN BisDetected; 277 BOOLEAN AutoArp; 278 BOOLEAN SendGUID; 279 BOOLEAN DhcpDiscoverValid; 280 BOOLEAN DhcpAckReceived; 281 BOOLEAN ProxyOfferReceived; 282 BOOLEAN PxeDiscoverValid; 283 BOOLEAN PxeReplyReceived; 284 BOOLEAN PxeBisReplyReceived; 285 BOOLEAN IcmpErrorReceived; 286 BOOLEAN TftpErrorReceived; 287 BOOLEAN MakeCallbacks; 288 UINT8 TTL; 289 UINT8 ToS; 290 EFI_IP_ADDRESS StationIp; 291 EFI_IP_ADDRESS SubnetMask; 292 EFI_PXE_BASE_CODE_PACKET DhcpDiscover; 293 EFI_PXE_BASE_CODE_PACKET DhcpAck; 294 EFI_PXE_BASE_CODE_PACKET ProxyOffer; 295 EFI_PXE_BASE_CODE_PACKET PxeDiscover; 296 EFI_PXE_BASE_CODE_PACKET PxeReply; 297 EFI_PXE_BASE_CODE_PACKET PxeBisReply; 298 EFI_PXE_BASE_CODE_IP_FILTER IpFilter; 299 UINT32 ArpCacheEntries; 300 EFI_PXE_BASE_CODE_ARP_ENTRY ArpCache[EFI_PXE_BASE_CODE_MAX_ARP_ENTRIES]; 301 UINT32 RouteTableEntries; 302 EFI_PXE_BASE_CODE_ROUTE_ENTRY RouteTable[EFI_PXE_BASE_CODE_MAX_ROUTE_ENTRIES]; 303 EFI_PXE_BASE_CODE_ICMP_ERROR IcmpError; 304 EFI_PXE_BASE_CODE_TFTP_ERROR TftpError; 305 } EFI_PXE_BASE_CODE_MODE; 306 307 // 308 // PXE Base Code Interface Function definitions 309 // 310 311 /** 312 Enables the use of the PXE Base Code Protocol functions. 313 314 This function enables the use of the PXE Base Code Protocol functions. If the 315 Started field of the EFI_PXE_BASE_CODE_MODE structure is already TRUE, then 316 EFI_ALREADY_STARTED will be returned. If UseIpv6 is TRUE, then IPv6 formatted 317 addresses will be used in this session. If UseIpv6 is FALSE, then IPv4 formatted 318 addresses will be used in this session. If UseIpv6 is TRUE, and the Ipv6Supported 319 field of the EFI_PXE_BASE_CODE_MODE structure is FALSE, then EFI_UNSUPPORTED will 320 be returned. If there is not enough memory or other resources to start the PXE 321 Base Code Protocol, then EFI_OUT_OF_RESOURCES will be returned. Otherwise, the 322 PXE Base Code Protocol will be started, and all of the fields of the EFI_PXE_BASE_CODE_MODE 323 structure will be initialized as follows: 324 StartedSet to TRUE. 325 Ipv6SupportedUnchanged. 326 Ipv6AvailableUnchanged. 327 UsingIpv6Set to UseIpv6. 328 BisSupportedUnchanged. 329 BisDetectedUnchanged. 330 AutoArpSet to TRUE. 331 SendGUIDSet to FALSE. 332 TTLSet to DEFAULT_TTL. 333 ToSSet to DEFAULT_ToS. 334 DhcpCompletedSet to FALSE. 335 ProxyOfferReceivedSet to FALSE. 336 StationIpSet to an address of all zeros. 337 SubnetMaskSet to a subnet mask of all zeros. 338 DhcpDiscoverZero-filled. 339 DhcpAckZero-filled. 340 ProxyOfferZero-filled. 341 PxeDiscoverValidSet to FALSE. 342 PxeDiscoverZero-filled. 343 PxeReplyValidSet to FALSE. 344 PxeReplyZero-filled. 345 PxeBisReplyValidSet to FALSE. 346 PxeBisReplyZero-filled. 347 IpFilterSet the Filters field to 0 and the IpCnt field to 0. 348 ArpCacheEntriesSet to 0. 349 ArpCacheZero-filled. 350 RouteTableEntriesSet to 0. 351 RouteTableZero-filled. 352 IcmpErrorReceivedSet to FALSE. 353 IcmpErrorZero-filled. 354 TftpErroReceivedSet to FALSE. 355 TftpErrorZero-filled. 356 MakeCallbacksSet to TRUE if the PXE Base Code Callback Protocol is available. 357 Set to FALSE if the PXE Base Code Callback Protocol is not available. 358 359 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 360 @param UseIpv6 Specifies the type of IP addresses that are to be used during the session 361 that is being started. Set to TRUE for IPv6 addresses, and FALSE for 362 IPv4 addresses. 363 364 @retval EFI_SUCCESS The PXE Base Code Protocol was started. 365 @retval EFI_DEVICE_ERROR The network device encountered an error during this oper 366 @retval EFI_UNSUPPORTED UseIpv6 is TRUE, but the Ipv6Supported field of the 367 EFI_PXE_BASE_CODE_MODE structure is FALSE. 368 @retval EFI_ALREADY_STARTED The PXE Base Code Protocol is already in the started state. 369 @retval EFI_INVALID_PARAMETER The This parameter is NULL or does not point to a valid 370 EFI_PXE_BASE_CODE_PROTOCOL structure. 371 @retval EFI_OUT_OF_RESOURCES Could not allocate enough memory or other resources to start the 372 PXE Base Code Protocol. 373 374 **/ 375 typedef 376 EFI_STATUS 377 (EFIAPI *EFI_PXE_BASE_CODE_START)( 378 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 379 IN BOOLEAN UseIpv6 380 ); 381 382 /** 383 Disables the use of the PXE Base Code Protocol functions. 384 385 This function stops all activity on the network device. All the resources allocated 386 in Start() are released, the Started field of the EFI_PXE_BASE_CODE_MODE structure is 387 set to FALSE and EFI_SUCCESS is returned. If the Started field of the EFI_PXE_BASE_CODE_MODE 388 structure is already FALSE, then EFI_NOT_STARTED will be returned. 389 390 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 391 392 @retval EFI_SUCCESS The PXE Base Code Protocol was stopped. 393 @retval EFI_NOT_STARTED The PXE Base Code Protocol is already in the stopped state. 394 @retval EFI_INVALID_PARAMETER The This parameter is NULL or does not point to a valid 395 EFI_PXE_BASE_CODE_PROTOCOL structure. 396 @retval EFI_DEVICE_ERROR The network device encountered an error during this operation. 397 398 **/ 399 typedef 400 EFI_STATUS 401 (EFIAPI *EFI_PXE_BASE_CODE_STOP)( 402 IN EFI_PXE_BASE_CODE_PROTOCOL *This 403 ); 404 405 /** 406 Attempts to complete a DHCPv4 D.O.R.A. (discover / offer / request / acknowledge) or DHCPv6 407 S.A.R.R (solicit / advertise / request / reply) sequence. 408 409 This function attempts to complete the DHCP sequence. If this sequence is completed, 410 then EFI_SUCCESS is returned, and the DhcpCompleted, ProxyOfferReceived, StationIp, 411 SubnetMask, DhcpDiscover, DhcpAck, and ProxyOffer fields of the EFI_PXE_BASE_CODE_MODE 412 structure are filled in. 413 If SortOffers is TRUE, then the cached DHCP offer packets will be sorted before 414 they are tried. If SortOffers is FALSE, then the cached DHCP offer packets will 415 be tried in the order in which they are received. Please see the Preboot Execution 416 Environment (PXE) Specification for additional details on the implementation of DHCP. 417 This function can take at least 31 seconds to timeout and return control to the 418 caller. If the DHCP sequence does not complete, then EFI_TIMEOUT will be returned. 419 If the Callback Protocol does not return EFI_PXE_BASE_CODE_CALLBACK_STATUS_CONTINUE, 420 then the DHCP sequence will be stopped and EFI_ABORTED will be returned. 421 422 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 423 @param SortOffers TRUE if the offers received should be sorted. Set to FALSE to try the 424 offers in the order that they are received. 425 426 @retval EFI_SUCCESS Valid DHCP has completed. 427 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 428 @retval EFI_INVALID_PARAMETER The This parameter is NULL or does not point to a valid 429 EFI_PXE_BASE_CODE_PROTOCOL structure. 430 @retval EFI_DEVICE_ERROR The network device encountered an error during this operation. 431 @retval EFI_OUT_OF_RESOURCES Could not allocate enough memory to complete the DHCP Protocol. 432 @retval EFI_ABORTED The callback function aborted the DHCP Protocol. 433 @retval EFI_TIMEOUT The DHCP Protocol timed out. 434 @retval EFI_ICMP_ERROR An ICMP error packet was received during the DHCP session. 435 @retval EFI_NO_RESPONSE Valid PXE offer was not received. 436 437 **/ 438 typedef 439 EFI_STATUS 440 (EFIAPI *EFI_PXE_BASE_CODE_DHCP)( 441 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 442 IN BOOLEAN SortOffers 443 ); 444 445 /** 446 Attempts to complete the PXE Boot Server and/or boot image discovery sequence. 447 448 This function attempts to complete the PXE Boot Server and/or boot image discovery 449 sequence. If this sequence is completed, then EFI_SUCCESS is returned, and the 450 PxeDiscoverValid, PxeDiscover, PxeReplyReceived, and PxeReply fields of the 451 EFI_PXE_BASE_CODE_MODE structure are filled in. If UseBis is TRUE, then the 452 PxeBisReplyReceived and PxeBisReply fields of the EFI_PXE_BASE_CODE_MODE structure 453 will also be filled in. If UseBis is FALSE, then PxeBisReplyValid will be set to FALSE. 454 In the structure referenced by parameter Info, the PXE Boot Server list, SrvList[], 455 has two uses: It is the Boot Server IP address list used for unicast discovery 456 (if the UseUCast field is TRUE), and it is the list used for Boot Server verification 457 (if the MustUseList field is TRUE). Also, if the MustUseList field in that structure 458 is TRUE and the AcceptAnyResponse field in the SrvList[] array is TRUE, any Boot 459 Server reply of that type will be accepted. If the AcceptAnyResponse field is 460 FALSE, only responses from Boot Servers with matching IP addresses will be accepted. 461 This function can take at least 10 seconds to timeout and return control to the 462 caller. If the Discovery sequence does not complete, then EFI_TIMEOUT will be 463 returned. Please see the Preboot Execution Environment (PXE) Specification for 464 additional details on the implementation of the Discovery sequence. 465 If the Callback Protocol does not return EFI_PXE_BASE_CODE_CALLBACK_STATUS_CONTINUE, 466 then the Discovery sequence is stopped and EFI_ABORTED will be returned. 467 468 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 469 @param Type The type of bootstrap to perform. 470 @param Layer The pointer to the boot server layer number to discover, which must be 471 PXE_BOOT_LAYER_INITIAL when a new server type is being 472 discovered. 473 @param UseBis TRUE if Boot Integrity Services are to be used. FALSE otherwise. 474 @param Info The pointer to a data structure that contains additional information on the 475 type of discovery operation that is to be performed. 476 477 @retval EFI_SUCCESS The Discovery sequence has been completed. 478 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 479 @retval EFI_INVALID_PARAMETER One or more parameters are invalid. 480 @retval EFI_DEVICE_ERROR The network device encountered an error during this operation. 481 @retval EFI_OUT_OF_RESOURCES Could not allocate enough memory to complete Discovery. 482 @retval EFI_ABORTED The callback function aborted the Discovery sequence. 483 @retval EFI_TIMEOUT The Discovery sequence timed out. 484 @retval EFI_ICMP_ERROR An ICMP error packet was received during the PXE discovery 485 session. 486 487 **/ 488 typedef 489 EFI_STATUS 490 (EFIAPI *EFI_PXE_BASE_CODE_DISCOVER)( 491 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 492 IN UINT16 Type, 493 IN UINT16 *Layer, 494 IN BOOLEAN UseBis, 495 IN EFI_PXE_BASE_CODE_DISCOVER_INFO *Info OPTIONAL 496 ); 497 498 /** 499 Used to perform TFTP and MTFTP services. 500 501 This function is used to perform TFTP and MTFTP services. This includes the 502 TFTP operations to get the size of a file, read a directory, read a file, and 503 write a file. It also includes the MTFTP operations to get the size of a file, 504 read a directory, and read a file. The type of operation is specified by Operation. 505 If the callback function that is invoked during the TFTP/MTFTP operation does 506 not return EFI_PXE_BASE_CODE_CALLBACK_STATUS_CONTINUE, then EFI_ABORTED will 507 be returned. 508 For read operations, the return data will be placed in the buffer specified by 509 BufferPtr. If BufferSize is too small to contain the entire downloaded file, 510 then EFI_BUFFER_TOO_SMALL will be returned and BufferSize will be set to zero 511 or the size of the requested file (the size of the requested file is only returned 512 if the TFTP server supports TFTP options). If BufferSize is large enough for the 513 read operation, then BufferSize will be set to the size of the downloaded file, 514 and EFI_SUCCESS will be returned. Applications using the PxeBc.Mtftp() services 515 should use the get-file-size operations to determine the size of the downloaded 516 file prior to using the read-file operations--especially when downloading large 517 (greater than 64 MB) files--instead of making two calls to the read-file operation. 518 Following this recommendation will save time if the file is larger than expected 519 and the TFTP server does not support TFTP option extensions. Without TFTP option 520 extension support, the client has to download the entire file, counting and discarding 521 the received packets, to determine the file size. 522 For write operations, the data to be sent is in the buffer specified by BufferPtr. 523 BufferSize specifies the number of bytes to send. If the write operation completes 524 successfully, then EFI_SUCCESS will be returned. 525 For TFTP "get file size" operations, the size of the requested file or directory 526 is returned in BufferSize, and EFI_SUCCESS will be returned. If the TFTP server 527 does not support options, the file will be downloaded into a bit bucket and the 528 length of the downloaded file will be returned. For MTFTP "get file size" operations, 529 if the MTFTP server does not support the "get file size" option, EFI_UNSUPPORTED 530 will be returned. 531 This function can take up to 10 seconds to timeout and return control to the caller. 532 If the TFTP sequence does not complete, EFI_TIMEOUT will be returned. 533 If the Callback Protocol does not return EFI_PXE_BASE_CODE_CALLBACK_STATUS_CONTINUE, 534 then the TFTP sequence is stopped and EFI_ABORTED will be returned. 535 The format of the data returned from a TFTP read directory operation is a null-terminated 536 filename followed by a null-terminated information string, of the form 537 "size year-month-day hour:minute:second" (i.e. %d %d-%d-%d %d:%d:%f - note that 538 the seconds field can be a decimal number), where the date and time are UTC. For 539 an MTFTP read directory command, there is additionally a null-terminated multicast 540 IP address preceding the filename of the form %d.%d.%d.%d for IP v4. The final 541 entry is itself null-terminated, so that the final information string is terminated 542 with two null octets. 543 544 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 545 @param Operation The type of operation to perform. 546 @param BufferPtr A pointer to the data buffer. 547 @param Overwrite Only used on write file operations. TRUE if a file on a remote server can 548 be overwritten. 549 @param BufferSize For get-file-size operations, *BufferSize returns the size of the 550 requested file. 551 @param BlockSize The requested block size to be used during a TFTP transfer. 552 @param ServerIp The TFTP / MTFTP server IP address. 553 @param Filename A Null-terminated ASCII string that specifies a directory name or a file 554 name. 555 @param Info The pointer to the MTFTP information. 556 @param DontUseBuffer Set to FALSE for normal TFTP and MTFTP read file operation. 557 558 @retval EFI_SUCCESS The TFTP/MTFTP operation was completed. 559 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 560 @retval EFI_INVALID_PARAMETER One or more parameters are invalid. 561 @retval EFI_DEVICE_ERROR The network device encountered an error during this operation. 562 @retval EFI_BUFFER_TOO_SMALL The buffer is not large enough to complete the read operation. 563 @retval EFI_ABORTED The callback function aborted the TFTP/MTFTP operation. 564 @retval EFI_TIMEOUT The TFTP/MTFTP operation timed out. 565 @retval EFI_ICMP_ERROR An ICMP error packet was received during the MTFTP session. 566 @retval EFI_TFTP_ERROR A TFTP error packet was received during the MTFTP session. 567 568 **/ 569 typedef 570 EFI_STATUS 571 (EFIAPI *EFI_PXE_BASE_CODE_MTFTP)( 572 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 573 IN EFI_PXE_BASE_CODE_TFTP_OPCODE Operation, 574 IN OUT VOID *BufferPtr OPTIONAL, 575 IN BOOLEAN Overwrite, 576 IN OUT UINT64 *BufferSize, 577 IN UINTN *BlockSize OPTIONAL, 578 IN EFI_IP_ADDRESS *ServerIp, 579 IN UINT8 *Filename OPTIONAL, 580 IN EFI_PXE_BASE_CODE_MTFTP_INFO *Info OPTIONAL, 581 IN BOOLEAN DontUseBuffer 582 ); 583 584 /** 585 Writes a UDP packet to the network interface. 586 587 This function writes a UDP packet specified by the (optional HeaderPtr and) 588 BufferPtr parameters to the network interface. The UDP header is automatically 589 built by this routine. It uses the parameters OpFlags, DestIp, DestPort, GatewayIp, 590 SrcIp, and SrcPort to build this header. If the packet is successfully built and 591 transmitted through the network interface, then EFI_SUCCESS will be returned. 592 If a timeout occurs during the transmission of the packet, then EFI_TIMEOUT will 593 be returned. If an ICMP error occurs during the transmission of the packet, then 594 the IcmpErrorReceived field is set to TRUE, the IcmpError field is filled in and 595 EFI_ICMP_ERROR will be returned. If the Callback Protocol does not return 596 EFI_PXE_BASE_CODE_CALLBACK_STATUS_CONTINUE, then EFI_ABORTED will be returned. 597 598 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 599 @param OpFlags The UDP operation flags. 600 @param DestIp The destination IP address. 601 @param DestPort The destination UDP port number. 602 @param GatewayIp The gateway IP address. 603 @param SrcIp The source IP address. 604 @param SrcPort The source UDP port number. 605 @param HeaderSize An optional field which may be set to the length of a header at 606 HeaderPtr to be prefixed to the data at BufferPtr. 607 @param HeaderPtr If HeaderSize is not NULL, a pointer to a header to be prefixed to the 608 data at BufferPtr. 609 @param BufferSize A pointer to the size of the data at BufferPtr. 610 @param BufferPtr A pointer to the data to be written. 611 612 @retval EFI_SUCCESS The UDP Write operation was completed. 613 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 614 @retval EFI_INVALID_PARAMETER One or more parameters are invalid. 615 @retval EFI_BAD_BUFFER_SIZE The buffer is too long to be transmitted. 616 @retval EFI_ABORTED The callback function aborted the UDP Write operation. 617 @retval EFI_TIMEOUT The UDP Write operation timed out. 618 @retval EFI_ICMP_ERROR An ICMP error packet was received during the UDP write session. 619 620 **/ 621 typedef 622 EFI_STATUS 623 (EFIAPI *EFI_PXE_BASE_CODE_UDP_WRITE)( 624 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 625 IN UINT16 OpFlags, 626 IN EFI_IP_ADDRESS *DestIp, 627 IN EFI_PXE_BASE_CODE_UDP_PORT *DestPort, 628 IN EFI_IP_ADDRESS *GatewayIp, OPTIONAL 629 IN EFI_IP_ADDRESS *SrcIp, OPTIONAL 630 IN OUT EFI_PXE_BASE_CODE_UDP_PORT *SrcPort, OPTIONAL 631 IN UINTN *HeaderSize, OPTIONAL 632 IN VOID *HeaderPtr, OPTIONAL 633 IN UINTN *BufferSize, 634 IN VOID *BufferPtr 635 ); 636 637 /** 638 Reads a UDP packet from the network interface. 639 640 This function reads a UDP packet from a network interface. The data contents 641 are returned in (the optional HeaderPtr and) BufferPtr, and the size of the 642 buffer received is returned in BufferSize. If the input BufferSize is smaller 643 than the UDP packet received (less optional HeaderSize), it will be set to the 644 required size, and EFI_BUFFER_TOO_SMALL will be returned. In this case, the 645 contents of BufferPtr are undefined, and the packet is lost. If a UDP packet is 646 successfully received, then EFI_SUCCESS will be returned, and the information 647 from the UDP header will be returned in DestIp, DestPort, SrcIp, and SrcPort if 648 they are not NULL. 649 Depending on the values of OpFlags and the DestIp, DestPort, SrcIp, and SrcPort 650 input values, different types of UDP packet receive filtering will be performed. 651 The following tables summarize these receive filter operations. 652 653 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 654 @param OpFlags The UDP operation flags. 655 @param DestIp The destination IP address. 656 @param DestPort The destination UDP port number. 657 @param SrcIp The source IP address. 658 @param SrcPort The source UDP port number. 659 @param HeaderSize An optional field which may be set to the length of a header at 660 HeaderPtr to be prefixed to the data at BufferPtr. 661 @param HeaderPtr If HeaderSize is not NULL, a pointer to a header to be prefixed to the 662 data at BufferPtr. 663 @param BufferSize A pointer to the size of the data at BufferPtr. 664 @param BufferPtr A pointer to the data to be read. 665 666 @retval EFI_SUCCESS The UDP Read operation was completed. 667 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 668 @retval EFI_INVALID_PARAMETER One or more parameters are invalid. 669 @retval EFI_DEVICE_ERROR The network device encountered an error during this operation. 670 @retval EFI_BUFFER_TOO_SMALL The packet is larger than Buffer can hold. 671 @retval EFI_ABORTED The callback function aborted the UDP Read operation. 672 @retval EFI_TIMEOUT The UDP Read operation timed out. 673 674 **/ 675 typedef 676 EFI_STATUS 677 (EFIAPI *EFI_PXE_BASE_CODE_UDP_READ)( 678 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 679 IN UINT16 OpFlags, 680 IN OUT EFI_IP_ADDRESS *DestIp, OPTIONAL 681 IN OUT EFI_PXE_BASE_CODE_UDP_PORT *DestPort, OPTIONAL 682 IN OUT EFI_IP_ADDRESS *SrcIp, OPTIONAL 683 IN OUT EFI_PXE_BASE_CODE_UDP_PORT *SrcPort, OPTIONAL 684 IN UINTN *HeaderSize, OPTIONAL 685 IN VOID *HeaderPtr, OPTIONAL 686 IN OUT UINTN *BufferSize, 687 IN VOID *BufferPtr 688 ); 689 690 /** 691 Updates the IP receive filters of a network device and enables software filtering. 692 693 The NewFilter field is used to modify the network device's current IP receive 694 filter settings and to enable a software filter. This function updates the IpFilter 695 field of the EFI_PXE_BASE_CODE_MODE structure with the contents of NewIpFilter. 696 The software filter is used when the USE_FILTER in OpFlags is set to UdpRead(). 697 The current hardware filter remains in effect no matter what the settings of OpFlags 698 are, so that the meaning of ANY_DEST_IP set in OpFlags to UdpRead() is from those 699 packets whose reception is enabled in hardware - physical NIC address (unicast), 700 broadcast address, logical address or addresses (multicast), or all (promiscuous). 701 UdpRead() does not modify the IP filter settings. 702 Dhcp(), Discover(), and Mtftp() set the IP filter, and return with the IP receive 703 filter list emptied and the filter set to EFI_PXE_BASE_CODE_IP_FILTER_STATION_IP. 704 If an application or driver wishes to preserve the IP receive filter settings, 705 it will have to preserve the IP receive filter settings before these calls, and 706 use SetIpFilter() to restore them after the calls. If incompatible filtering is 707 requested (for example, PROMISCUOUS with anything else), or if the device does not 708 support a requested filter setting and it cannot be accommodated in software 709 (for example, PROMISCUOUS not supported), EFI_INVALID_PARAMETER will be returned. 710 The IPlist field is used to enable IPs other than the StationIP. They may be 711 multicast or unicast. If IPcnt is set as well as EFI_PXE_BASE_CODE_IP_FILTER_STATION_IP, 712 then both the StationIP and the IPs from the IPlist will be used. 713 714 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 715 @param NewFilter The pointer to the new set of IP receive filters. 716 717 @retval EFI_SUCCESS The IP receive filter settings were updated. 718 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 719 @retval EFI_INVALID_PARAMETER One or more parameters are invalid. 720 721 **/ 722 typedef 723 EFI_STATUS 724 (EFIAPI *EFI_PXE_BASE_CODE_SET_IP_FILTER)( 725 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 726 IN EFI_PXE_BASE_CODE_IP_FILTER *NewFilter 727 ); 728 729 /** 730 Uses the ARP protocol to resolve a MAC address. 731 732 This function uses the ARP protocol to resolve a MAC address. The UsingIpv6 field 733 of the EFI_PXE_BASE_CODE_MODE structure is used to determine if IPv4 or IPv6 734 addresses are being used. The IP address specified by IpAddr is used to resolve 735 a MAC address. If the ARP protocol succeeds in resolving the specified address, 736 then the ArpCacheEntries and ArpCache fields of the EFI_PXE_BASE_CODE_MODE structure 737 are updated, and EFI_SUCCESS is returned. If MacAddr is not NULL, the resolved 738 MAC address is placed there as well. 739 If the PXE Base Code protocol is in the stopped state, then EFI_NOT_STARTED is 740 returned. If the ARP protocol encounters a timeout condition while attempting 741 to resolve an address, then EFI_TIMEOUT is returned. If the Callback Protocol 742 does not return EFI_PXE_BASE_CODE_CALLBACK_STATUS_CONTINUE, then EFI_ABORTED is 743 returned. 744 745 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 746 @param IpAddr The pointer to the IP address that is used to resolve a MAC address. 747 @param MacAddr If not NULL, a pointer to the MAC address that was resolved with the 748 ARP protocol. 749 750 @retval EFI_SUCCESS The IP or MAC address was resolved. 751 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 752 @retval EFI_INVALID_PARAMETER One or more parameters are invalid. 753 @retval EFI_DEVICE_ERROR The network device encountered an error during this operation. 754 @retval EFI_ABORTED The callback function aborted the ARP Protocol. 755 @retval EFI_TIMEOUT The ARP Protocol encountered a timeout condition. 756 757 **/ 758 typedef 759 EFI_STATUS 760 (EFIAPI *EFI_PXE_BASE_CODE_ARP)( 761 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 762 IN EFI_IP_ADDRESS *IpAddr, 763 IN EFI_MAC_ADDRESS *MacAddr OPTIONAL 764 ); 765 766 /** 767 Updates the parameters that affect the operation of the PXE Base Code Protocol. 768 769 This function sets parameters that affect the operation of the PXE Base Code Protocol. 770 The parameter specified by NewAutoArp is used to control the generation of ARP 771 protocol packets. If NewAutoArp is TRUE, then ARP Protocol packets will be generated 772 as required by the PXE Base Code Protocol. If NewAutoArp is FALSE, then no ARP 773 Protocol packets will be generated. In this case, the only mappings that are 774 available are those stored in the ArpCache of the EFI_PXE_BASE_CODE_MODE structure. 775 If there are not enough mappings in the ArpCache to perform a PXE Base Code Protocol 776 service, then the service will fail. This function updates the AutoArp field of 777 the EFI_PXE_BASE_CODE_MODE structure to NewAutoArp. 778 The SetParameters() call must be invoked after a Callback Protocol is installed 779 to enable the use of callbacks. 780 781 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 782 @param NewAutoArp If not NULL, a pointer to a value that specifies whether to replace the 783 current value of AutoARP. 784 @param NewSendGUID If not NULL, a pointer to a value that specifies whether to replace the 785 current value of SendGUID. 786 @param NewTTL If not NULL, a pointer to be used in place of the current value of TTL, 787 the "time to live" field of the IP header. 788 @param NewToS If not NULL, a pointer to be used in place of the current value of ToS, 789 the "type of service" field of the IP header. 790 @param NewMakeCallback If not NULL, a pointer to a value that specifies whether to replace the 791 current value of the MakeCallback field of the Mode structure. 792 793 @retval EFI_SUCCESS The new parameters values were updated. 794 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 795 @retval EFI_INVALID_PARAMETER One or more parameters are invalid. 796 797 **/ 798 typedef 799 EFI_STATUS 800 (EFIAPI *EFI_PXE_BASE_CODE_SET_PARAMETERS)( 801 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 802 IN BOOLEAN *NewAutoArp, OPTIONAL 803 IN BOOLEAN *NewSendGUID, OPTIONAL 804 IN UINT8 *NewTTL, OPTIONAL 805 IN UINT8 *NewToS, OPTIONAL 806 IN BOOLEAN *NewMakeCallback OPTIONAL 807 ); 808 809 /** 810 Updates the station IP address and/or subnet mask values of a network device. 811 812 This function updates the station IP address and/or subnet mask values of a network 813 device. 814 The NewStationIp field is used to modify the network device's current IP address. 815 If NewStationIP is NULL, then the current IP address will not be modified. Otherwise, 816 this function updates the StationIp field of the EFI_PXE_BASE_CODE_MODE structure 817 with NewStationIp. 818 The NewSubnetMask field is used to modify the network device's current subnet 819 mask. If NewSubnetMask is NULL, then the current subnet mask will not be modified. 820 Otherwise, this function updates the SubnetMask field of the EFI_PXE_BASE_CODE_MODE 821 structure with NewSubnetMask. 822 823 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 824 @param NewStationIp The pointer to the new IP address to be used by the network device. 825 @param NewSubnetMask The pointer to the new subnet mask to be used by the network device. 826 827 @retval EFI_SUCCESS The new station IP address and/or subnet mask were updated. 828 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 829 @retval EFI_INVALID_PARAMETER One or more parameters are invalid. 830 831 **/ 832 typedef 833 EFI_STATUS 834 (EFIAPI *EFI_PXE_BASE_CODE_SET_STATION_IP)( 835 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 836 IN EFI_IP_ADDRESS *NewStationIp, OPTIONAL 837 IN EFI_IP_ADDRESS *NewSubnetMask OPTIONAL 838 ); 839 840 /** 841 Updates the contents of the cached DHCP and Discover packets. 842 843 The pointers to the new packets are used to update the contents of the cached 844 packets in the EFI_PXE_BASE_CODE_MODE structure. 845 846 @param This The pointer to the EFI_PXE_BASE_CODE_PROTOCOL instance. 847 @param NewDhcpDiscoverValid The pointer to a value that will replace the current 848 DhcpDiscoverValid field. 849 @param NewDhcpAckReceived The pointer to a value that will replace the current 850 DhcpAckReceived field. 851 @param NewProxyOfferReceived The pointer to a value that will replace the current 852 ProxyOfferReceived field. 853 @param NewPxeDiscoverValid The pointer to a value that will replace the current 854 ProxyOfferReceived field. 855 @param NewPxeReplyReceived The pointer to a value that will replace the current 856 PxeReplyReceived field. 857 @param NewPxeBisReplyReceived The pointer to a value that will replace the current 858 PxeBisReplyReceived field. 859 @param NewDhcpDiscover The pointer to the new cached DHCP Discover packet contents. 860 @param NewDhcpAck The pointer to the new cached DHCP Ack packet contents. 861 @param NewProxyOffer The pointer to the new cached Proxy Offer packet contents. 862 @param NewPxeDiscover The pointer to the new cached PXE Discover packet contents. 863 @param NewPxeReply The pointer to the new cached PXE Reply packet contents. 864 @param NewPxeBisReply The pointer to the new cached PXE BIS Reply packet contents. 865 866 @retval EFI_SUCCESS The cached packet contents were updated. 867 @retval EFI_NOT_STARTED The PXE Base Code Protocol is in the stopped state. 868 @retval EFI_INVALID_PARAMETER This is NULL or not point to a valid EFI_PXE_BASE_CODE_PROTOCOL structure. 869 870 **/ 871 typedef 872 EFI_STATUS 873 (EFIAPI *EFI_PXE_BASE_CODE_SET_PACKETS)( 874 IN EFI_PXE_BASE_CODE_PROTOCOL *This, 875 BOOLEAN *NewDhcpDiscoverValid, OPTIONAL 876 BOOLEAN *NewDhcpAckReceived, OPTIONAL 877 BOOLEAN *NewProxyOfferReceived, OPTIONAL 878 BOOLEAN *NewPxeDiscoverValid, OPTIONAL 879 BOOLEAN *NewPxeReplyReceived, OPTIONAL 880 BOOLEAN *NewPxeBisReplyReceived, OPTIONAL 881 IN EFI_PXE_BASE_CODE_PACKET *NewDhcpDiscover, OPTIONAL 882 IN EFI_PXE_BASE_CODE_PACKET *NewDhcpAck, OPTIONAL 883 IN EFI_PXE_BASE_CODE_PACKET *NewProxyOffer, OPTIONAL 884 IN EFI_PXE_BASE_CODE_PACKET *NewPxeDiscover, OPTIONAL 885 IN EFI_PXE_BASE_CODE_PACKET *NewPxeReply, OPTIONAL 886 IN EFI_PXE_BASE_CODE_PACKET *NewPxeBisReply OPTIONAL 887 ); 888 889 // 890 // PXE Base Code Protocol structure 891 // 892 #define EFI_PXE_BASE_CODE_PROTOCOL_REVISION 0x00010000 893 894 // 895 // Revision defined in EFI1.1 896 // 897 #define EFI_PXE_BASE_CODE_INTERFACE_REVISION EFI_PXE_BASE_CODE_PROTOCOL_REVISION 898 899 /// 900 /// The EFI_PXE_BASE_CODE_PROTOCOL is used to control PXE-compatible devices. 901 /// An EFI_PXE_BASE_CODE_PROTOCOL will be layered on top of an 902 /// EFI_MANAGED_NETWORK_PROTOCOL protocol in order to perform packet level transactions. 903 /// The EFI_PXE_BASE_CODE_PROTOCOL handle also supports the 904 /// EFI_LOAD_FILE_PROTOCOL protocol. This provides a clean way to obtain control from the 905 /// boot manager if the boot path is from the remote device. 906 /// 907 struct _EFI_PXE_BASE_CODE_PROTOCOL { 908 /// 909 /// The revision of the EFI_PXE_BASE_CODE_PROTOCOL. All future revisions must 910 /// be backwards compatible. If a future version is not backwards compatible 911 /// it is not the same GUID. 912 /// 913 UINT64 Revision; 914 EFI_PXE_BASE_CODE_START Start; 915 EFI_PXE_BASE_CODE_STOP Stop; 916 EFI_PXE_BASE_CODE_DHCP Dhcp; 917 EFI_PXE_BASE_CODE_DISCOVER Discover; 918 EFI_PXE_BASE_CODE_MTFTP Mtftp; 919 EFI_PXE_BASE_CODE_UDP_WRITE UdpWrite; 920 EFI_PXE_BASE_CODE_UDP_READ UdpRead; 921 EFI_PXE_BASE_CODE_SET_IP_FILTER SetIpFilter; 922 EFI_PXE_BASE_CODE_ARP Arp; 923 EFI_PXE_BASE_CODE_SET_PARAMETERS SetParameters; 924 EFI_PXE_BASE_CODE_SET_STATION_IP SetStationIp; 925 EFI_PXE_BASE_CODE_SET_PACKETS SetPackets; 926 /// 927 /// The pointer to the EFI_PXE_BASE_CODE_MODE data for this device. 928 /// 929 EFI_PXE_BASE_CODE_MODE *Mode; 930 }; 931 932 extern EFI_GUID gEfiPxeBaseCodeProtocolGuid; 933 934 #endif 935