]> git.proxmox.com Git - mirror_edk2.git/blobdiff - NetworkPkg/IScsiDxe/IScsiMisc.h
OvmfPkg/AcpiPlatformDxe: sort [Sources*] sections in the INF files
[mirror_edk2.git] / NetworkPkg / IScsiDxe / IScsiMisc.h
index 912a8711fab3de1d7077868b91fba97c5686362a..659c0268b582d52e9ce49458917da0810a332be3 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   Miscellaneous definitions for iSCSI driver.\r
 \r
-Copyright (c) 2004 - 2016, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2004 - 2017, 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
@@ -33,6 +33,7 @@ typedef struct _ISCSI_DRIVER_DATA ISCSI_DRIVER_DATA;
 ///\r
 #define IP6_OLD_IPADDRESS_OFFSET      42\r
 \r
+\r
 #pragma pack(1)\r
 typedef struct _ISCSI_SESSION_CONFIG_NVDATA {\r
   UINT16            TargetPort;\r
@@ -45,6 +46,7 @@ typedef struct _ISCSI_SESSION_CONFIG_NVDATA {
 \r
   BOOLEAN           InitiatorInfoFromDhcp;\r
   BOOLEAN           TargetInfoFromDhcp;\r
+\r
   CHAR8             TargetName[ISCSI_NAME_MAX_SIZE];\r
   EFI_IP_ADDRESS    TargetIp;\r
   UINT8             PrefixLength;\r
@@ -57,6 +59,9 @@ typedef struct _ISCSI_SESSION_CONFIG_NVDATA {
   BOOLEAN           RedirectFlag;\r
   UINT16            OriginalTargetPort;     // The port of proxy/virtual target.\r
   EFI_IP_ADDRESS    OriginalTargetIp;       // The address of proxy/virtual target.\r
+\r
+  BOOLEAN           DnsMode;  // Flag indicate whether the Target address is expressed as URL format.\r
+  CHAR8             TargetUrl[ISCSI_TARGET_URI_MAX_SIZE];\r
   \r
 } ISCSI_SESSION_CONFIG_NVDATA;\r
 #pragma pack()\r
@@ -212,6 +217,7 @@ IScsiGenRandom (
   Record the NIC information in a global structure.\r
 \r
   @param[in]  Controller         The handle of the controller.\r
+  @param[in]  Image              Handle of the image.\r
 \r
   @retval EFI_SUCCESS            The operation is completed.\r
   @retval EFI_OUT_OF_RESOURCES   Do not have sufficient resource to finish this\r
@@ -220,7 +226,8 @@ IScsiGenRandom (
 **/\r
 EFI_STATUS\r
 IScsiAddNic (\r
-  IN EFI_HANDLE  Controller\r
+  IN EFI_HANDLE  Controller,\r
+  IN EFI_HANDLE  Image\r
   );\r
 \r
 /**\r
@@ -238,6 +245,44 @@ IScsiRemoveNic (
   IN EFI_HANDLE  Controller\r
   );\r
 \r
+/**\r
+  Create and initialize the Attempts.\r
+\r
+  @param[in]  AttemptNum          The number of Attempts will be created.\r
+\r
+  @retval EFI_SUCCESS             The Attempts have been created successfully.\r
+  @retval Others                  Failed to create the Attempt.\r
+\r
+**/\r
+EFI_STATUS\r
+IScsiCreateAttempts (\r
+  IN UINTN            AttemptNum\r
+  );\r
+\r
+/**\r
+  Create the iSCSI configuration Keywords for each attempt.\r
+\r
+  @param[in]  KeywordNum          The number Sets of Keywords will be created.\r
+\r
+  @retval EFI_SUCCESS             The operation is completed.\r
+  @retval Others                  Failed to create the Keywords.\r
+\r
+**/\r
+EFI_STATUS\r
+IScsiCreateKeywords (\r
+  IN UINTN            KeywordNum\r
+  );\r
+\r
+/**\r
+\r
+  Free the attempt configure data variable.\r
+\r
+**/\r
+VOID\r
+IScsiCleanAttemptVariable (\r
+  IN   VOID\r
+  );\r
+\r
 /**\r
   Get the recorded NIC information from a global structure by the Index.\r
 \r
@@ -338,6 +383,20 @@ IScsiDhcpIsConfigured (
   IN UINT8       IpVersion\r
   );\r
 \r
+/**\r
+  Check wheather the Controller handle is configured to use DNS protocol.\r
+\r
+  @param[in]  Controller           The handle of the controller.\r
+  \r
+  @retval TRUE                     The handle of the controller need the DNS protocol.\r
+  @retval FALSE                    The handle of the controller does not need the DNS protocol.\r
+  \r
+**/\r
+BOOLEAN\r
+IScsiDnsIsConfigured (\r
+  IN EFI_HANDLE  Controller\r
+  );\r
+\r
 /**\r
   Get the various configuration data of this iSCSI instance.\r
 \r