]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Universal/Network/IScsiDxe/IScsiProto.h
unified "iSCSI" in all comments
[mirror_edk2.git] / MdeModulePkg / Universal / Network / IScsiDxe / IScsiProto.h
index 870e6ded449cd1e32031ecab5088f715b552f8c9..e6a6588d84065581f1da1f2946c2adaa414598b3 100644 (file)
@@ -1,5 +1,5 @@
 /** @file\r
-  The header file of IScsi Protocol that defines many specific data structures.\r
+  The header file of iSCSI Protocol that defines many specific data structures.\r
 \r
 Copyright (c) 2004 - 2008, Intel Corporation.<BR>\r
 All rights reserved. This program and the accompanying materials\r
@@ -631,29 +631,29 @@ typedef struct _ISCSI_KEY_VALUE_PAIR {
 /**\r
   Attach the iSCSI connection to the iSCSI session. \r
 \r
-  @param[in]  Session The iSCSI session.\r
-  @param[in]  Conn    The iSCSI connection.\r
+  @param[in, out]  Session The iSCSI session.\r
+  @param[in, out]  Conn    The iSCSI connection.\r
 **/\r
 VOID\r
 IScsiAttatchConnection (\r
-  IN ISCSI_SESSION     *Session,\r
-  IN ISCSI_CONNECTION  *Conn\r
+  IN OUT ISCSI_SESSION     *Session,\r
+  IN OUT ISCSI_CONNECTION  *Conn\r
   );\r
 \r
 /**\r
   Detach the iSCSI connection from the session it belongs to. \r
 \r
-  @param[in]  Conn The iSCSI connection.\r
+  @param[in, out]  Conn The iSCSI connection.\r
 **/\r
 VOID\r
 IScsiDetatchConnection (\r
-  IN ISCSI_CONNECTION  *Conn\r
+  IN OUT ISCSI_CONNECTION  *Conn\r
   );\r
 \r
 /**\r
   This function does the iSCSI connection login.\r
 \r
-  @param[in]  Conn           The iSCSI connection to login.\r
+  @param[in, out]  Conn      The iSCSI connection to login.\r
 \r
   @retval EFI_SUCCESS        The iSCSI connection is logged into the iSCSI target.\r
   @retval EFI_TIMEOUT        Timeout happened during the login procedure.\r
@@ -661,7 +661,7 @@ IScsiDetatchConnection (
 **/\r
 EFI_STATUS\r
 IScsiConnLogin (\r
-  IN ISCSI_CONNECTION  *Conn\r
+  IN OUT ISCSI_CONNECTION  *Conn\r
   );\r
 \r
 /**\r
@@ -736,10 +736,10 @@ IScsiReceiveLoginRsp (
   The DataSegmentLength and the actual size of the net buffer containing this PDU will be\r
   updated.\r
 \r
-  @param[in]  Pdu              The iSCSI PDU whose data segment the key-value pair will\r
+  @param[in, out]  Pdu         The iSCSI PDU whose data segment the key-value pair will\r
                                be added to.\r
-  @param[in]  Key              The key name string.\r
-  @param[in]  Value            The value string.\r
+  @param[in]       Key         The key name string.\r
+  @param[in]       Value       The value string.\r
 \r
   @retval EFI_SUCCESS          The key-valu pair is added to the PDU's datasegment and\r
                                the correspondence length fields are updated.\r
@@ -748,7 +748,7 @@ IScsiReceiveLoginRsp (
 **/\r
 EFI_STATUS\r
 IScsiAddKeyValuePair (\r
-  IN NET_BUF          *Pdu,\r
+  IN OUT NET_BUF      *Pdu,\r
   IN CHAR8            *Key,\r
   IN CHAR8            *Value\r
   );\r
@@ -756,21 +756,21 @@ IScsiAddKeyValuePair (
 /**\r
   Prepare the iSCSI login request to be sent according to the current login status.\r
 \r
-  @param[in]  Conn The connection in the iSCSI login phase.\r
+  @param[in, out]  Conn The connection in the iSCSI login phase.\r
 \r
   @return The pointer to the net buffer containing the iSCSI login request built.\r
   @retval Others    Other errors as indicated.\r
 **/\r
 NET_BUF *\r
 IScsiPrepareLoginReq (\r
-  IN ISCSI_CONNECTION  *Conn\r
+  IN OUT ISCSI_CONNECTION  *Conn\r
   );\r
 \r
 /**\r
   Process the iSCSI Login Response.\r
 \r
-  @param[in]  Conn The connection on which the iSCSI login response is received.\r
-  @param[in]  Pdu  The iSCSI login response PDU.\r
+  @param[in, out]  Conn The connection on which the iSCSI login response is received.\r
+  @param[in, out]  Pdu  The iSCSI login response PDU.\r
 \r
   @retval EFI_SUCCESS        The iSCSI login response PDU is processed and all check are passed.\r
   @retval EFI_PROTOCOL_ERROR Some kind of iSCSI protocol error happened.\r
@@ -779,18 +779,18 @@ IScsiPrepareLoginReq (
 **/\r
 EFI_STATUS\r
 IScsiProcessLoginRsp (\r
-  IN ISCSI_CONNECTION  *Conn,\r
-  IN NET_BUF           *Pdu\r
+  IN OUT ISCSI_CONNECTION  *Conn,\r
+  IN OUT NET_BUF           *Pdu\r
   );\r
 \r
 /**\r
   Updated the target information according the data received in the iSCSI\r
   login response with an target redirection status.\r
 \r
-  @param[in] Session          The iSCSI session.\r
-  @param[in] Data             The data segment which should contain the\r
-                              TargetAddress key-value list.\r
-  @param[in] Len              Length of the data.\r
+  @param[in, out] Session      The iSCSI session.\r
+  @param[in]      Data         The data segment which should contain the\r
+                               TargetAddress key-value list.\r
+  @param[in]      Len          Length of the data.\r
   \r
   @retval EFI_SUCCESS          The target address is updated.\r
   @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.\r
@@ -799,9 +799,9 @@ IScsiProcessLoginRsp (
 **/\r
 EFI_STATUS\r
 IScsiUpdateTargetAddress (\r
-  IN ISCSI_SESSION  *Session,\r
-  IN CHAR8          *Data,\r
-  IN UINT32         Len\r
+  IN OUT ISCSI_SESSION  *Session,\r
+  IN CHAR8              *Data,\r
+  IN UINT32             Len\r
   );\r
 \r
 /**\r
@@ -846,8 +846,7 @@ IScsiReceivePdu (
 /**\r
   Check and get the result of the prameter negotiation.\r
 \r
-  @param[in]  Conn          The connection in iSCSI login.\r
-  @param[in]  Transit       Whether need transit.\r
+  @param[in, out]  Conn          The connection in iSCSI login.\r
 \r
   @retval EFI_SUCCESS          The parmeter check is passed and negotiation is finished.\r
   @retval EFI_PROTOCOL_ERROR   Some kind of iSCSI protocol error happened.\r
@@ -855,29 +854,28 @@ IScsiReceivePdu (
 **/\r
 EFI_STATUS\r
 IScsiCheckOpParams (\r
-  IN ISCSI_CONNECTION  *Conn,\r
-  IN BOOLEAN           Transit\r
+  IN OUT ISCSI_CONNECTION  *Conn\r
   );\r
 \r
 /**\r
   Fill the oprational prameters.\r
 \r
-  @param[in]  Conn            The connection in iSCSI login.\r
-  @param[in]  Pdu             The iSCSI login request PDU to fill the parameters.\r
+  @param[in]       Conn        The connection in iSCSI login.\r
+  @param[in, out]  Pdu         The iSCSI login request PDU to fill the parameters.\r
 \r
   @retval EFI_SUCCESS          The parmeters are filled into the iSCSI login request PDU.\r
 **/\r
 EFI_STATUS\r
 IScsiFillOpParams (\r
   IN ISCSI_CONNECTION  *Conn,\r
-  IN NET_BUF           *Pdu\r
+  IN OUT NET_BUF       *Pdu\r
   );\r
 \r
 /**\r
   Pad the iSCSI AHS or data segment to an integer number of 4 byte words.\r
 \r
-  @param[in]   Pdu             The iSCSI pdu which contains segments to pad.\r
-  @param[in]   Len             The length of the last semgnet in the PDU.\r
+  @param[in, out]  Pdu         The iSCSI pdu which contains segments to pad.\r
+  @param[in]       Len         The length of the last semgnet in the PDU.\r
 \r
   @retval EFI_SUCCESS          The segment is padded or no need to pad it.\r
   @retval EFI_OUT_OF_RESOURCES There is not enough remaining free space to add the\r
@@ -885,8 +883,8 @@ IScsiFillOpParams (
 **/\r
 EFI_STATUS\r
 IScsiPadSegment (\r
-  IN NET_BUF  *Pdu,\r
-  IN UINT32   Len\r
+  IN OUT NET_BUF  *Pdu,\r
+  IN UINT32       Len\r
   );\r
 \r
 /**\r
@@ -908,14 +906,14 @@ IScsiBuildKeyValueList (
   Get the value string by the key name from the key-value list. If found,\r
   the key-value entry will be removed from the list.\r
 \r
-  @param[in]  KeyValueList The key-value list.\r
-  @param[in]  Key          The key name to find.\r
+  @param[in, out]  KeyValueList  The key-value list.\r
+  @param[in]       Key           The key name to find.\r
 \r
   @return The value string.\r
 **/\r
 CHAR8 *\r
 IScsiGetValueByKeyFromList (\r
-  IN LIST_ENTRY      *KeyValueList,\r
+  IN OUT LIST_ENTRY  *KeyValueList,\r
   IN CHAR8           *Key\r
   );\r
 \r
@@ -932,16 +930,16 @@ IScsiFreeKeyValueList (
 /**\r
   Normalize the iSCSI name according to RFC.\r
 \r
-  @param[in]  Name          The iSCSI name.\r
-  @param[in]  Len           length of the iSCSI name.\r
+  @param[in, out]  Name       The iSCSI name.\r
+  @param[in]       Len        length of the iSCSI name.\r
 \r
   @retval EFI_SUCCESS        The iSCSI name is valid and normalized.\r
   @retval EFI_PROTOCOL_ERROR The iSCSI name is mal-formatted or not in the IQN format.\r
 **/\r
 EFI_STATUS\r
 IScsiNormalizeName (\r
-  IN CHAR8  *Name,\r
-  IN UINTN  Len\r
+  IN OUT CHAR8  *Name,\r
+  IN UINTN      Len\r
   );\r
 \r
 /**\r
@@ -955,7 +953,7 @@ IScsiNormalizeName (
                              \r
   @retval EFI_SUCCES           The SCSI command is executed and the result is updated to \r
                                the Packet.\r
-  @retval EFI_DEVICE_ERROR     Other errors as indicated.\r
+  @retval EFI_DEVICE_ERROR     Session state was not as required.\r
   @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.\r
   @retval Others               Other errors as indicated.\r
 **/\r
@@ -970,14 +968,14 @@ IScsiExecuteScsiCommand (
 /**\r
   Reinstate the session on some error.\r
 \r
-  @param[in]  Private The iSCSI driver data.\r
+  @param[in, out]  Private The iSCSI driver data.\r
 \r
   @retval EFI_SUCCES  The session is reinstated from some error.\r
   @retval Other       Reinstatement failed.\r
 **/\r
 EFI_STATUS\r
 IScsiSessionReinstatement (\r
-  IN ISCSI_DRIVER_DATA  *Private\r
+  IN OUT ISCSI_DRIVER_DATA  *Private\r
   );\r
 \r
 /**\r
@@ -996,13 +994,13 @@ IScsiSessionInit (
   Abort the iSCSI session, that is, reset all the connection and free the\r
   resources.\r
 \r
-  @param[in]  Session The iSCSI session.\r
+  @param[in, out]  Session The iSCSI session.\r
 \r
   @retval EFI_SUCCES  The session is aborted.\r
 **/\r
 EFI_STATUS\r
 IScsiSessionAbort (\r
-  IN ISCSI_SESSION  *Session\r
+  IN OUT ISCSI_SESSION  *Session\r
   );\r
 \r
 #endif\r