]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Universal/Network/SnpDxe/Mcast_ip_to_mac.c
BaseTools:Change the path of the file that Binary Cache
[mirror_edk2.git] / MdeModulePkg / Universal / Network / SnpDxe / Mcast_ip_to_mac.c
index f4294c03d1ee1a2a155c35e2901b79c74c6dc090..9863c1f9ead75906b5096f21e3fba8c3c521ca7d 100644 (file)
@@ -1,15 +1,9 @@
 /** @file\r
-               Implementation of converting an multicast IP address to multicast HW MAC\r
-               address.\r
\r
-Copyright (c) 2004 - 2007, Intel Corporation. All rights reserved.<BR>\r
-This program and the accompanying materials are licensed \r
-and made available under the terms and conditions of the BSD License which \r
-accompanies this distribution. 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
+     Implementation of converting an multicast IP address to multicast HW MAC\r
+     address.\r
+\r
+Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>\r
+SPDX-License-Identifier: BSD-2-Clause-Patent\r
 \r
 **/\r
 \r
@@ -23,11 +17,11 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
   @param  IP    Multicast IP address.\r
   @param  MAC   Pointer to hold the return MAC address.\r
 \r
-  @retval EFI_SUCCESS           The multicast IP address was mapped to the \r
+  @retval EFI_SUCCESS           The multicast IP address was mapped to the\r
                                 multicast HW MAC address.\r
-  @retval EFI_INVALID_PARAMETER Invalid UNDI command. \r
-  @retval EFI_UNSUPPORTED       Command is not supported by UNDI. \r
-  @retval EFI_DEVICE_ERROR      Fail to execute UNDI command. \r
+  @retval EFI_INVALID_PARAMETER Invalid UNDI command.\r
+  @retval EFI_UNSUPPORTED       Command is not supported by UNDI.\r
+  @retval EFI_DEVICE_ERROR      Fail to execute UNDI command.\r
 \r
 **/\r
 EFI_STATUS\r
@@ -45,8 +39,8 @@ PxeIp2Mac (
   Db                  = Snp->Db;\r
   Snp->Cdb.OpCode     = PXE_OPCODE_MCAST_IP_TO_MAC;\r
   Snp->Cdb.OpFlags    = (UINT16) (IPv6 ? PXE_OPFLAGS_MCAST_IPV6_TO_MAC : PXE_OPFLAGS_MCAST_IPV4_TO_MAC);\r
-  Snp->Cdb.CPBsize    = sizeof (PXE_CPB_MCAST_IP_TO_MAC);\r
-  Snp->Cdb.DBsize     = sizeof (PXE_DB_MCAST_IP_TO_MAC);\r
+  Snp->Cdb.CPBsize    = (UINT16) sizeof (PXE_CPB_MCAST_IP_TO_MAC);\r
+  Snp->Cdb.DBsize     = (UINT16) sizeof (PXE_DB_MCAST_IP_TO_MAC);\r
 \r
   Snp->Cdb.CPBaddr    = (UINT64)(UINTN) Cpb;\r
   Snp->Cdb.DBaddr     = (UINT64)(UINTN) Db;\r
@@ -103,29 +97,29 @@ PxeIp2Mac (
 \r
 /**\r
   Converts a multicast IP address to a multicast HW MAC address.\r
-  \r
-  This function converts a multicast IP address to a multicast HW MAC address \r
+\r
+  This function converts a multicast IP address to a multicast HW MAC address\r
   for all packet transactions. If the mapping is accepted, then EFI_SUCCESS will\r
   be returned.\r
 \r
   @param This A pointer to the EFI_SIMPLE_NETWORK_PROTOCOL instance.\r
   @param IPv6 Set to TRUE if the multicast IP address is IPv6 [RFC 2460].\r
-              Set to FALSE if the multicast IP address is IPv4 [RFC 791]. \r
-  @param IP   The multicast IP address that is to be converted to a multicast \r
+              Set to FALSE if the multicast IP address is IPv4 [RFC 791].\r
+  @param IP   The multicast IP address that is to be converted to a multicast\r
               HW MAC address.\r
   @param MAC  The multicast HW MAC address that is to be generated from IP.\r
 \r
   @retval EFI_SUCCESS           The multicast IP address was mapped to the\r
                                 multicast HW MAC address.\r
-  @retval EFI_NOT_STARTED       The Simple Network Protocol interface has not \r
+  @retval EFI_NOT_STARTED       The Simple Network Protocol interface has not\r
                                 been started by calling Start().\r
   @retval EFI_INVALID_PARAMETER IP is NULL.\r
   @retval EFI_INVALID_PARAMETER MAC is NULL.\r
-  @retval EFI_INVALID_PARAMETER IP does not point to a valid IPv4 or IPv6 \r
+  @retval EFI_INVALID_PARAMETER IP does not point to a valid IPv4 or IPv6\r
                                 multicast address.\r
-  @retval EFI_DEVICE_ERROR      The Simple Network Protocol interface has not \r
+  @retval EFI_DEVICE_ERROR      The Simple Network Protocol interface has not\r
                                 been initialized by calling Initialize().\r
-  @retval EFI_UNSUPPORTED       IPv6 is TRUE and the implementation does not \r
+  @retval EFI_UNSUPPORTED       IPv6 is TRUE and the implementation does not\r
                                 support IPv6 multicast to MAC address conversion.\r
 \r
 **/\r