/** @file\r
Functions declaration related with DHCPv4 for HTTP boot driver.\r
\r
-Copyright (c) 2015 - 2016, Intel Corporation. All rights reserved.<BR>\r
-This program and the accompanying materials are licensed and made available under \r
-the terms and conditions of the BSD License that accompanies this distribution. \r
-The full text of the license may be found at\r
-http://opensource.org/licenses/bsd-license.php. \r
- \r
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+Copyright (c) 2015 - 2018, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2020, Hewlett Packard Enterprise Development LP. All rights reserved.<BR>\r
+SPDX-License-Identifier: BSD-2-Clause-Patent\r
\r
**/\r
\r
#define HTTP_BOOT_DHCP4_OVERLOAD_SERVER_NAME 2\r
\r
///\r
-/// HTTP Tag definition that identifies the processor \r
+/// HTTP Tag definition that identifies the processor\r
/// and programming environment of the client system.\r
/// These identifiers are defined by IETF:\r
/// http://www.ietf.org/assignments/dhcpv6-parameters/dhcpv6-parameters.xml\r
#define EFI_HTTP_BOOT_CLIENT_SYSTEM_ARCHITECTURE HTTP_CLIENT_ARCH_ARM\r
#elif defined (MDE_CPU_AARCH64)\r
#define EFI_HTTP_BOOT_CLIENT_SYSTEM_ARCHITECTURE HTTP_CLIENT_ARCH_AARCH64\r
+#elif defined (MDE_CPU_RISCV64)\r
+#define EFI_HTTP_BOOT_CLIENT_SYSTEM_ARCHITECTURE HTTP_CLIENT_ARCH_RISCV64\r
#elif defined (MDE_CPU_EBC)\r
#define EFI_HTTP_BOOT_CLIENT_SYSTEM_ARCHITECTURE HTTP_CLIENT_ARCH_EBC\r
#endif\r
\r
/// DHCP offer types among HTTP boot.\r
/// Dhcp4 and Dhcp6 share this definition, and corresponding\r
-/// relatioinship is as follows:\r
+/// relationship is as follows:\r
/// Dhcp4Discover <> Dhcp6Solicit\r
/// Dhcp4Offer <> Dhcp6Advertise\r
/// Dhcp4Request <> Dhcp6Request\r
UINT32 Reserved;\r
} HTTP_BOOT_VENDOR_OPTION;\r
\r
+#define HTTP_CACHED_DHCP4_PACKET_MAX_SIZE (OFFSET_OF (EFI_DHCP4_PACKET, Dhcp4) + HTTP_BOOT_DHCP4_PACKET_MAX_SIZE)\r
+\r
typedef union {\r
EFI_DHCP4_PACKET Offer;\r
EFI_DHCP4_PACKET Ack;\r
- UINT8 Buffer[HTTP_BOOT_DHCP4_PACKET_MAX_SIZE];\r
+ UINT8 Buffer[HTTP_CACHED_DHCP4_PACKET_MAX_SIZE];\r
} HTTP_BOOT_DHCP4_PACKET;\r
\r
typedef struct {\r
\r
/**\r
This function will register the default DNS addresses to the network device.\r
- \r
+\r
@param[in] Private The pointer to HTTP_BOOT_PRIVATE_DATA.\r
@param[in] DataLength Size of the buffer pointed to by DnsServerData in bytes.\r
@param[in] DnsServerData Point a list of DNS server address in an array\r