#define EFI_DHCP6_IA_TYPE_TA 4\r
\r
#pragma pack(1)\r
+///\r
+/// EFI_DHCP6_PACKET_OPTION\r
+/// defines the format of the DHCPv6 option, See RFC 3315 for more information.\r
+/// This data structure is used to reference option data that is packed in the DHCPv6 packet. \r
+///\r
typedef struct {\r
///\r
- /// The DHCPv6 option code.\r
+ /// The DHCPv6 option code, stored in network order.\r
///\r
UINT16 OpCode;\r
///\r
- /// Length of the DHCPv6 option data. From the first byte to the last byte of the Data field.\r
+ /// Length of the DHCPv6 option data, stored in network order.\r
+ /// From the first byte to the last byte of the Data field.\r
///\r
UINT16 OpLen;\r
///\r
- /// The data for the DHCPv6 option.\r
+ /// The data for the DHCPv6 option, stored in network order.\r
///\r
UINT8 Data[1];\r
} EFI_DHCP6_PACKET_OPTION;\r
\r
+///\r
+/// EFI_DHCP6_HEADER\r
+/// defines the format of the DHCPv6 header. See RFC 3315 for more information. \r
+///\r
typedef struct{\r
///\r
/// The DHCPv6 transaction ID.\r
UINT32 TransactionId:24;\r
} EFI_DHCP6_HEADER;\r
\r
+///\r
+/// EFI_DHCP6_PACKET \r
+/// defines the format of the DHCPv6 packet. See RFC 3315 for more information.\r
+///\r
typedef struct {\r
///\r
/// Size of the EFI_DHCP6_PACKET buffer.\r
\r
typedef struct _EFI_IP6_PROTOCOL EFI_IP6_PROTOCOL;\r
\r
+///\r
+/// EFI_IP6_ADDRESS_PAIR \r
+///\r
+typedef struct{ \r
+ ///\r
+ /// The EFI IPv6 Protocol instance handle that is using this address/prefix pair.\r
+ ///\r
+ EFI_HANDLE InstanceHandle;\r
+ ///\r
+ /// IPv6 address in network byte order.\r
+ ///\r
+ EFI_IPv6_ADDRESS Ip6Address;\r
+ ///\r
+ /// The length of the prefix associated with the Ip6Address.\r
+ ///\r
+ UINT8 PrefixLength;\r
+} EFI_IP6_ADDRESS_PAIR; \r
+\r
+///\r
+/// EFI_IP6_VARIABLE_DATA\r
+///\r
+typedef struct {\r
+ ///\r
+ /// The handle of the driver that creates this entry.\r
+ ///\r
+ EFI_HANDLE DriverHandle;\r
+ ///\r
+ /// The number of IPv6 address pairs that follow this data structure.\r
+ ///\r
+ UINT32 AddressCount;\r
+ ///\r
+ /// List of IPv6 address pairs that are currently in use.\r
+ ///\r
+ EFI_IP6_ADDRESS_PAIR AddressPairs[1];\r
+} EFI_IP6_VARIABLE_DATA;\r
+\r
///\r
/// ICMPv6 type definitions for error messages\r
///\r
@param Packet The pointer to the received packet. This buffer must be freed by\r
the caller.\r
\r
- @retval EFI_SUCCESS An MTFTPv4 OACK packet was received and is in the Buffer.\r
- @retval EFI_INVALID_PARAMETER One or more parameters are invalid.\r
- @retval EFI_UNSUPPORTED One or more options in the OptionList are in the\r
- unsupported list of structure EFI_MTFTP4_MODE_DATA.\r
- @retval EFI_NOT_STARTED The EFI MTFTPv4 Protocol driver has not been started.\r
- @retval EFI_NO_MAPPING When using a default address, configuration (DHCP, BOOTP,\r
- RARP, etc.) has not finished yet.\r
- @retval EFI_ACCESS_DENIED The previous operation has not completed yet.\r
- @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
- @retval EFI_TFTP_ERROR An MTFTPv4 ERROR packet was received and is in the buffer.\r
- @retval EFI_ICMP_ERROR An ICMP ERROR packet was received and is in the Buffer.\r
- @retval EFI_PROTOCOL_ERROR An unexpected MTFTPv4 packet was received and is in the buffer.\r
- @retval EFI_TIMEOUT No responses were received from the MTFTPv4 server.\r
- @retval EFI_DEVICE_ERROR An unexpected network error or system error occurred.\r
+ @retval EFI_SUCCESS An MTFTPv4 OACK packet was received and is in the Packet.\r
+ @retval EFI_INVALID_PARAMETER One or more of the following conditions is TRUE:\r
+ - This is NULL.\r
+ - Filename is NULL.\r
+ - OptionCount is not zero and OptionList is NULL.\r
+ - One or more options in OptionList have wrong format.\r
+ - PacketLength is NULL.\r
+ - One or more IPv4 addresses in OverrideData are not valid\r
+ unicast IPv4 addresses if OverrideData is not NULL.\r
+ @retval EFI_UNSUPPORTED One or more options in the OptionList are in the\r
+ unsupported list of structure EFI_MTFTP4_MODE_DATA.\r
+ @retval EFI_NOT_STARTED The EFI MTFTPv4 Protocol driver has not been started.\r
+ @retval EFI_NO_MAPPING When using a default address, configuration (DHCP, BOOTP,\r
+ RARP, etc.) has not finished yet.\r
+ @retval EFI_ACCESS_DENIED The previous operation has not completed yet.\r
+ @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
+ @retval EFI_TFTP_ERROR An MTFTPv4 ERROR packet was received and is in the Packet.\r
+ @retval EFI_NETWORK_UNREACHABLE An ICMP network unreachable error packet was received and the Packet is set to NULL.\r
+ @retval EFI_HOST_UNREACHABLE An ICMP host unreachable error packet was received and the Packet is set to NULL.\r
+ @retval EFI_PROTOCOL_UNREACHABLE An ICMP protocol unreachable error packet was received and the Packet is set to NULL.\r
+ @retval EFI_PORT_UNREACHABLE An ICMP port unreachable error packet was received and the Packet is set to NULL.\r
+ @retval EFI_ICMP_ERROR Some other ICMP ERROR packet was received and is in the Buffer.\r
+ @retval EFI_PROTOCOL_ERROR An unexpected MTFTPv4 packet was received and is in the Packet.\r
+ @retval EFI_TIMEOUT No responses were received from the MTFTPv4 server.\r
+ @retval EFI_DEVICE_ERROR An unexpected network error or system error occurred.\r
\r
**/\r
typedef \r
@param Token Pointer to the token structure to provide the parameters that are\r
used in this operation.\r
\r
- @retval EFI_SUCCESS The data file has been transferred successfully.\r
- @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
- @retval EFI_BUFFER_TOO_SMALL BufferSize is not large enough to hold the downloaded data\r
- in downloading process.\r
- @retval EFI_ABORTED Current operation is aborted by user.\r
- @retval EFI_ICMP_ERROR An ICMP ERROR packet was received.\r
- @retval EFI_TIMEOUT No responses were received from the MTFTPv4 server.\r
- @retval EFI_TFTP_ERROR An MTFTPv4 ERROR packet was received.\r
- @retval EFI_DEVICE_ERROR An unexpected network error or system error occurred.\r
+ @retval EFI_SUCCESS The data file has been transferred successfully.\r
+ @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
+ @retval EFI_BUFFER_TOO_SMALL BufferSize is not zero but not large enough to hold the\r
+ downloaded data in downloading process.\r
+ @retval EFI_ABORTED Current operation is aborted by user.\r
+ @retval EFI_NETWORK_UNREACHABLE An ICMP network unreachable error packet was received.\r
+ @retval EFI_HOST_UNREACHABLE An ICMP host unreachable error packet was received.\r
+ @retval EFI_PROTOCOL_UNREACHABLE An ICMP protocol unreachable error packet was received.\r
+ @retval EFI_PORT_UNREACHABLE An ICMP port unreachable error packet was received.\r
+ @retval EFI_ICMP_ERROR Some other ICMP ERROR packet was received.\r
+ @retval EFI_TIMEOUT No responses were received from the MTFTPv4 server.\r
+ @retval EFI_TFTP_ERROR An MTFTPv4 ERROR packet was received.\r
+ @retval EFI_DEVICE_ERROR An unexpected network error or system error occurred.\r
\r
**/\r
typedef \r
- MtftpConfigData.StationIp is neither zero nor one \r
of the configured IP addresses in the underlying IPv6 driver.\r
- MtftpCofigData.ServerIp is not a valid IPv6 unicast address.\r
- - The StationIP and LocalPort is already in use\r
- @retval EFI_ACCESS_DENIED The configuration could not be changed at this time because there \r
- is some MTFTP background operation in progress.\r
+ @retval EFI_ACCESS_DENIED - The configuration could not be changed at this time because there \r
+ is some MTFTP background operation in progress.\r
+ - MtftpCofigData.LocalPort is already in use.\r
@retval EFI_NO_MAPPING The underlying IPv6 driver was responsible for choosing a source \r
- address for this instance, but no source address was available for use\r
+ address for this instance, but no source address was available for use.\r
+ @retval EFI_OUT_OF_RESOURCES The EFI MTFTPv6 Protocol driver instance data could not be \r
+ allocated.\r
+ @retval EFI_DEVICE_ERROR An unexpected system or network error occurred. The EFI \r
+ MTFTPv6 Protocol driver instance is not configured.\r
+\r
\r
**/\r
typedef \r
@param[out] Packet The pointer to the received packet. This buffer must be freed by \r
the caller.\r
\r
- @retval EFI_SUCCESS An MTFTPv6 OACK packet was received and is in the Buffer.\r
- @retval EFI_INVALID_PARAMETER One or more of the following conditions is TRUE:\r
- - This is NULL.\r
- - Filename is NULL\r
- - OptionCount is not zero and OptionList is NULL.\r
- - One or more options in OptionList have wrong format.\r
- - PacketLength is NULL.\r
- - OverrideData.ServerIp is not valid unicast IPv6 addresses.\r
- @retval EFI_UNSUPPORTED One or more options in the OptionList are unsupported by \r
- this implementation.\r
- @retval EFI_NOT_STARTED The EFI MTFTPv6 Protocol driver has not been started.\r
- @retval EFI_NO_MAPPING The underlying IPv6 driver was responsible for choosing a source \r
- address for this instance, but no source address was available for use.\r
- @retval EFI_ACCESS_DENIED The previous operation has not completed yet.\r
- @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
- @retval EFI_TFTP_ERROR An MTFTPv6 ERROR packet was received and is in the Packet.\r
- @retval EFI_ICMP_ERROR An ICMP ERROR packet was received and the Packet is set to NULL.\r
- @retval EFI_PROTOCOL_ERROR An unexpected MTFTPv6 packet was received and is in the Packet.\r
- @retval EFI_TIMEOUT No responses were received from the MTFTPv6 server.\r
- @retval EFI_DEVICE_ERROR An unexpected network error or system error occurred.\r
+ @retval EFI_SUCCESS An MTFTPv6 OACK packet was received and is in the Packet.\r
+ @retval EFI_INVALID_PARAMETER One or more of the following conditions is TRUE:\r
+ - This is NULL.\r
+ - Filename is NULL\r
+ - OptionCount is not zero and OptionList is NULL.\r
+ - One or more options in OptionList have wrong format.\r
+ - PacketLength is NULL.\r
+ - OverrideData.ServerIp is not valid unicast IPv6 addresses.\r
+ @retval EFI_UNSUPPORTED One or more options in the OptionList are unsupported by \r
+ this implementation.\r
+ @retval EFI_NOT_STARTED The EFI MTFTPv6 Protocol driver has not been started.\r
+ @retval EFI_NO_MAPPING The underlying IPv6 driver was responsible for choosing a source \r
+ address for this instance, but no source address was available for use.\r
+ @retval EFI_ACCESS_DENIED The previous operation has not completed yet.\r
+ @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
+ @retval EFI_TFTP_ERROR An MTFTPv6 ERROR packet was received and is in the Packet.\r
+ @retval EFI_NETWORK_UNREACHABLE An ICMP network unreachable error packet was received and the Packet is set to NULL.\r
+ @retval EFI_HOST_UNREACHABLE An ICMP host unreachable error packet was received and the Packet is set to NULL.\r
+ @retval EFI_PROTOCOL_UNREACHABLE An ICMP protocol unreachable error packet was received and the Packet is set to NULL.\r
+ @retval EFI_PORT_UNREACHABLE An ICMP port unreachable error packet was received and the Packet is set to NULL.\r
+ @retval EFI_ICMP_ERROR Some other ICMP ERROR packet was received and the Packet is set to NULL.\r
+ @retval EFI_PROTOCOL_ERROR An unexpected MTFTPv6 packet was received and is in the Packet.\r
+ @retval EFI_TIMEOUT No responses were received from the MTFTPv6 server.\r
+ @retval EFI_DEVICE_ERROR An unexpected network error or system error occurred.\r
\r
**/\r
typedef \r
@param[in] Token Pointer to the token structure to provide the parameters that are \r
used in this operation.\r
\r
- @retval EFI_SUCCESS The data file has been transferred successfully.\r
- @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
- @retval EFI_BUFFER_TOO_SMALL BufferSize is not large enough to hold the downloaded data \r
- in downloading process.\r
- @retval EFI_ABORTED Current operation is aborted by user.\r
- @retval EFI_ICMP_ERROR An ICMP ERROR packet was received.\r
- @retval EFI_TIMEOUT No responses were received from the MTFTPv6 server.\r
- @retval EFI_TFTP_ERROR An MTFTPv6 ERROR packet was received.\r
- @retval EFI_DEVICE_ERROR An unexpected network error or system error occurred.\r
+ @retval EFI_SUCCESS The data file has been transferred successfully.\r
+ @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
+ @retval EFI_BUFFER_TOO_SMALL BufferSize is not zero but not large enough to hold the\r
+ downloaded data in downloading process.\r
+ @retval EFI_ABORTED Current operation is aborted by user.\r
+ @retval EFI_NETWORK_UNREACHABLE An ICMP network unreachable error packet was received.\r
+ @retval EFI_HOST_UNREACHABLE An ICMP host unreachable error packet was received.\r
+ @retval EFI_PROTOCOL_UNREACHABLE An ICMP protocol unreachable error packet was received.\r
+ @retval EFI_PORT_UNREACHABLE An ICMP port unreachable error packet was received.\r
+ @retval EFI_ICMP_ERROR An ICMP ERROR packet was received.\r
+ @retval EFI_TIMEOUT No responses were received from the MTFTPv6 server.\r
+ @retval EFI_TFTP_ERROR An MTFTPv6 ERROR packet was received.\r
+ @retval EFI_DEVICE_ERROR An unexpected network error or system error occurred.\r
\r
**/\r
typedef \r
} EFI_TCP4_COMPLETION_TOKEN;\r
\r
typedef struct {\r
+ ///\r
+ /// The Status in the CompletionToken will be set to one of \r
+ /// the following values if the active open succeeds or an unexpected \r
+ /// error happens:\r
+ /// EFI_SUCCESS: The active open succeeds and the instance's \r
+ /// state is Tcp4StateEstablished.\r
+ /// EFI_CONNECTION_RESET: The connect fails because the connection is reset\r
+ /// either by instance itself or the communication peer.\r
+ /// EFI_CONNECTION_REFUSED: The connect fails because this connection is initiated with\r
+ /// an active open and the connection is refused.\r
+ /// EFI_ABORTED: The active open is aborted.\r
+ /// EFI_TIMEOUT: The connection establishment timer expires and \r
+ /// no more specific information is available.\r
+ /// EFI_NETWORK_UNREACHABLE: The active open fails because \r
+ /// an ICMP network unreachable error is received. \r
+ /// EFI_HOST_UNREACHABLE: The active open fails because an \r
+ /// ICMP host unreachable error is received. \r
+ /// EFI_PROTOCOL_UNREACHABLE: The active open fails \r
+ /// because an ICMP protocol unreachable error is received.\r
+ /// EFI_PORT_UNREACHABLE: The connection establishment \r
+ /// timer times out and an ICMP port unreachable error is received.\r
+ /// EFI_ICMP_ERROR: The connection establishment timer timeout and some other ICMP\r
+ /// error is received.\r
+ /// EFI_DEVICE_ERROR: An unexpected system or network error occurred.\r
+ /// \r
EFI_TCP4_COMPLETION_TOKEN CompletionToken;\r
} EFI_TCP4_CONNECTION_TOKEN;\r
\r
} EFI_TCP4_TRANSMIT_DATA;\r
\r
typedef struct {\r
+ /// \r
+ /// When transmission finishes or meets any unexpected error it will \r
+ /// be set to one of the following values:\r
+ /// EFI_SUCCESS: The receiving or transmission operation \r
+ /// completes successfully.\r
+ /// EFI_CONNECTION_FIN: The receiving operation fails because the communication peer \r
+ /// has closed the connection and there is no more data in the \r
+ /// receive buffer of the instance.\r
+ /// EFI_CONNECTION_RESET: The receiving or transmission operation fails\r
+ /// because this connection is reset either by instance \r
+ /// itself or the communication peer.\r
+ /// EFI_ABORTED: The receiving or transmission is aborted.\r
+ /// EFI_TIMEOUT: The transmission timer expires and no more \r
+ /// specific information is available.\r
+ /// EFI_NETWORK_UNREACHABLE: The transmission fails \r
+ /// because an ICMP network unreachable error is received. \r
+ /// EFI_HOST_UNREACHABLE: The transmission fails because an \r
+ /// ICMP host unreachable error is received. \r
+ /// EFI_PROTOCOL_UNREACHABLE: The transmission fails \r
+ /// because an ICMP protocol unreachable error is received. \r
+ /// EFI_PORT_UNREACHABLE: The transmission fails and an \r
+ /// ICMP port unreachable error is received. \r
+ /// EFI_ICMP_ERROR: The transmission fails and some other \r
+ /// ICMP error is received. \r
+ /// EFI_DEVICE_ERROR: An unexpected system or network error occurs.\r
+ /// EFI_NO_MEDIA: There was a media error.\r
+ ///\r
EFI_TCP4_COMPLETION_TOKEN CompletionToken;\r
union {\r
+ ///\r
+ /// When this token is used for receiving, RxData is a pointer to EFI_TCP4_RECEIVE_DATA.\r
+ ///\r
EFI_TCP4_RECEIVE_DATA *RxData;\r
+ ///\r
+ /// When this token is used for transmitting, TxData is a pointer to EFI_TCP4_TRANSMIT_DATA.\r
+ ///\r
EFI_TCP4_TRANSMIT_DATA *TxData;\r
} Packet;\r
} EFI_TCP4_IO_TOKEN;\r
@retval EFI_NOT_FOUND The asynchronous I/O request isn't found in the \r
transmission or receive queue. It has either \r
completed or wasn't issued by Transmit() and Receive().\r
+ @retval EFI_UNSUPPORTED The implementation does not support this function.\r
\r
**/\r
typedef\r
/// state is Tcp6StateEstablished.\r
/// EFI_CONNECTION_RESET: The connect fails because the connection is reset\r
/// either by instance itself or the communication peer.\r
+ /// EFI_CONNECTION_REFUSED: The receiving or transmission operation fails because this \r
+ /// connection is refused.\r
/// EFI_ABORTED: The active open is aborted.\r
/// EFI_TIMEOUT: The connection establishment timer expires and \r
/// no more specific information is available.\r
/// be set to one of the following values:\r
/// EFI_SUCCESS: The receiving or transmission operation \r
/// completes successfully.\r
+ /// EFI_CONNECTION_FIN: The receiving operation fails because the communication peer \r
+ /// has closed the connection and there is no more data in the \r
+ /// receive buffer of the instance.\r
/// EFI_CONNECTION_RESET: The receiving or transmission operation fails\r
/// because this connection is reset either by instance \r
/// itself or the communication peer.\r
@retval EFI_NOT_FOUND The asynchronous I/O request isn't found in the transmission or \r
receive queue. It has either completed or wasn't issued by \r
Transmit() and Receive().\r
+ @retval EFI_UNSUPPORTED The implementation does not support this function.\r
\r
**/\r
typedef\r