]> git.proxmox.com Git - mirror_edk2.git/blobdiff - NetworkPkg/IScsiDxe/IScsiIbft.c
1. Add EFI_COMPONENT_NAME2_PROTOCOL.GetControllerName() support.
[mirror_edk2.git] / NetworkPkg / IScsiDxe / IScsiIbft.c
index e90c982bc229265c4b93af7aa8e9ed9a8adfc8c8..9dba4e6f365ca2bad35fce5a38599663422dcc25 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   Implementation for iSCSI Boot Firmware Table publication.\r
 \r
-Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>\r
 This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
@@ -310,25 +310,21 @@ IScsiFillNICAndTargetSections (
       //\r
       // Map the various v4 addresses into v6 addresses.\r
       //\r
-      IScsiMapV4ToV6Addr (&NvData->LocalIp, &Nic->Ip);\r
-      IScsiMapV4ToV6Addr (&NvData->Gateway, &Nic->Gateway);\r
+      IScsiMapV4ToV6Addr (&NvData->LocalIp.v4, &Nic->Ip);\r
+      IScsiMapV4ToV6Addr (&NvData->Gateway.v4, &Nic->Gateway);\r
       IScsiMapV4ToV6Addr (&Attempt->PrimaryDns.v4, &Nic->PrimaryDns);\r
       IScsiMapV4ToV6Addr (&Attempt->SecondaryDns.v4, &Nic->SecondaryDns);\r
       IScsiMapV4ToV6Addr (&Attempt->DhcpServer.v4, &Nic->DhcpServer);\r
 \r
     } else if (NvData->IpMode == IP_MODE_IP6 || NvData->IpMode == IP_MODE_AUTOCONFIG) {\r
-      //\r
-      // TODO: The subnet mask/local ip/gateway/dhcpserver for iBFT-IPv6 needs to be \r
-      // confirmed with spec owner.\r
-      //\r
 \r
+      Nic->SubnetMaskPrefixLength = NvData->PrefixLength;\r
+      CopyMem (&Nic->Ip, &NvData->LocalIp, sizeof (EFI_IPv6_ADDRESS));\r
+      CopyMem (&Nic->Gateway, &NvData->Gateway, sizeof (EFI_IPv6_ADDRESS));\r
       CopyMem (&Nic->PrimaryDns, &Attempt->PrimaryDns, sizeof (EFI_IPv6_ADDRESS));\r
       CopyMem (&Nic->SecondaryDns, &Attempt->SecondaryDns, sizeof (EFI_IPv6_ADDRESS));\r
-      //\r
-      // TODO: DHCP server address cannot be retrieved by DHCPv6 process since \r
-      // DHCP server option is removed.\r
-      //CopyMem (&Nic->DhcpServer, &Attempt->DhcpServer, sizeof (EFI_IPv6_ADDRESS));\r
-      //\r
+      CopyMem (&Nic->DhcpServer, &Attempt->DhcpServer, sizeof (EFI_IPv6_ADDRESS));\r
+\r
     } else {\r
       ASSERT (FALSE);\r
     }\r