[edk2-devel] [PATCH v2 41/78] NetworkPkg/IScsiDxe: Fix various typos

Philippe Mathieu-Daudé philmd at redhat.com
Fri Jan 3 09:07:35 UTC 2020


From: Antoine Coeur <coeur at gmx.fr>

Fix various typos in comments and documentation.

Cc: Jiaxin Wu <jiaxin.wu at intel.com>
Cc: Siyuan Fu <siyuan.fu at intel.com>
Cc: Maciej Rabeda <maciej.rabeda at intel.com>
Signed-off-by: Antoine Coeur <coeur at gmx.fr>
Reviewed-by: Philippe Mathieu-Daude <philmd at redhat.com>
Signed-off-by: Philippe Mathieu-Daude <philmd at redhat.com>
---
 NetworkPkg/IScsiDxe/IScsiMisc.h     |  8 +++---
 NetworkPkg/IScsiDxe/IScsiProto.h    | 10 ++++----
 NetworkPkg/IScsiDxe/ComponentName.c |  2 +-
 NetworkPkg/IScsiDxe/IScsiCHAP.c     |  4 +--
 NetworkPkg/IScsiDxe/IScsiConfig.c   |  6 ++---
 NetworkPkg/IScsiDxe/IScsiDhcp.c     |  4 +--
 NetworkPkg/IScsiDxe/IScsiDriver.c   | 10 ++++----
 NetworkPkg/IScsiDxe/IScsiMisc.c     |  6 ++---
 NetworkPkg/IScsiDxe/IScsiProto.c    | 40 ++++++++++++++---------------
 9 files changed, 45 insertions(+), 45 deletions(-)

diff --git a/NetworkPkg/IScsiDxe/IScsiMisc.h b/NetworkPkg/IScsiDxe/IScsiMisc.h
index 92f42e140ace..46c725aab3a4 100644
--- a/NetworkPkg/IScsiDxe/IScsiMisc.h
+++ b/NetworkPkg/IScsiDxe/IScsiMisc.h
@@ -46,7 +46,7 @@ typedef struct _ISCSI_SESSION_CONFIG_NVDATA {
   UINT8             PrefixLength;
   UINT8             BootLun[8];
 
-  UINT16            ConnectTimeout; ///< timout value in milliseconds.
+  UINT16            ConnectTimeout; ///< timeout value in milliseconds.
   UINT8             ConnectRetryCount;
   UINT8             IsId[6];
 
@@ -104,7 +104,7 @@ IScsiLunToUnicodeStr (
   );
 
 /**
-  Convert the mac address into a hexadecimal encoded "-" seperated string.
+  Convert the mac address into a hexadecimal encoded "-" separated string.
 
   @param[in]  Mac     The mac address.
   @param[in]  Len     Length in bytes of the mac address.
@@ -352,7 +352,7 @@ IScsiCreateDriverData (
 
   @param[in]              Private The iSCSI driver data.
 
-  @retval EFI_SUCCES      The clean operation is successful.
+  @retval EFI_SUCCESS     The clean operation is successful.
   @retval Others          Other errors as indicated.
 
 **/
@@ -439,7 +439,7 @@ IScsiOnExitBootService (
 
   This function tests whether the driver specified by DriverBindingHandle is
   currently managing the controller specified by ControllerHandle.  This test
-  is performed by evaluating if the the protocol specified by ProtocolGuid is
+  is performed by evaluating if the protocol specified by ProtocolGuid is
   present on ControllerHandle and is was opened by DriverBindingHandle and Nic
   Device handle with an attribute of EFI_OPEN_PROTOCOL_BY_DRIVER.
   If ProtocolGuid is NULL, then ASSERT().
diff --git a/NetworkPkg/IScsiDxe/IScsiProto.h b/NetworkPkg/IScsiDxe/IScsiProto.h
index 34b682b68df1..3b8e66221524 100644
--- a/NetworkPkg/IScsiDxe/IScsiProto.h
+++ b/NetworkPkg/IScsiDxe/IScsiProto.h
@@ -308,7 +308,7 @@ typedef struct _ISCSI_SENSE_DATA {
 } ISCSI_SENSE_DATA;
 
 ///
-/// iSCSI Task Managment Function Request.
+/// iSCSI Task Management Function Request.
 ///
 typedef struct _ISCSI_TMF_REQUEST {
   UINT8   OpCode;
@@ -870,7 +870,7 @@ IScsiReceivePdu (
 
   @param[in, out]  Conn          The connection in iSCSI login.
 
-  @retval EFI_SUCCESS          The parmeter check is passed and negotiation is finished.
+  @retval EFI_SUCCESS          The parameter check is passed and negotiation is finished.
   @retval EFI_PROTOCOL_ERROR   Some kind of iSCSI protocol error occurred.
   @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.
 
@@ -897,7 +897,7 @@ IScsiFillOpParams (
   Pad the iSCSI AHS or data segment to an integer number of 4 byte words.
 
   @param[in, out]  Pdu         The iSCSI pdu which contains segments to pad.
-  @param[in]       Len         The length of the last semgnet in the PDU.
+  @param[in]       Len         The length of the last segment in the PDU.
 
   @retval EFI_SUCCESS          The segment is padded or no need to pad it.
   @retval EFI_OUT_OF_RESOURCES There is not enough remaining free space to add the
@@ -978,7 +978,7 @@ IScsiNormalizeName (
   @param[in, out]  Packet    The request packet containing IO request, SCSI command
                              buffer and buffers to read/write.
 
-  @retval EFI_SUCCES           The SCSI command is executed and the result is updated to
+  @retval EFI_SUCCESS          The SCSI command is executed and the result is updated to
                                the Packet.
   @retval EFI_DEVICE_ERROR     Session state was not as required.
   @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.
@@ -999,7 +999,7 @@ IScsiExecuteScsiCommand (
 
   @param[in]  Session           The iSCSI session
 
-  @retval EFI_SUCCES            The session is reinstated from some error.
+  @retval EFI_SUCCESS           The session is reinstated from some error.
   @retval Other                 Reinstatement failed.
 
 **/
diff --git a/NetworkPkg/IScsiDxe/ComponentName.c b/NetworkPkg/IScsiDxe/ComponentName.c
index 77e6f3858a29..8572ac281d1d 100644
--- a/NetworkPkg/IScsiDxe/ComponentName.c
+++ b/NetworkPkg/IScsiDxe/ComponentName.c
@@ -249,7 +249,7 @@ IScsiComponentNameGetControllerName (
   }
 
   //
-  // Get the handle of the controller we are controling.
+  // Get the handle of the controller we are controlling.
   //
   IScsiController = NetLibGetNicHandle (ControllerHandle, &gEfiTcp4ProtocolGuid);
   if (IScsiController != NULL) {
diff --git a/NetworkPkg/IScsiDxe/IScsiCHAP.c b/NetworkPkg/IScsiDxe/IScsiCHAP.c
index 627882af0058..355c6f129f68 100644
--- a/NetworkPkg/IScsiDxe/IScsiCHAP.c
+++ b/NetworkPkg/IScsiDxe/IScsiCHAP.c
@@ -9,7 +9,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
 #include "IScsiImpl.h"
 
 /**
-  Initator calculates its own expected hash value.
+  Initiator calculates its own expected hash value.
 
   @param[in]   ChapIdentifier     iSCSI CHAP identifier sent by authenticator.
   @param[in]   ChapSecret         iSCSI CHAP secret of the authenticator.
@@ -88,7 +88,7 @@ Exit:
 }
 
 /**
-  The initator checks the CHAP response replied by target against its own
+  The initiator checks the CHAP response replied by target against its own
   calculation of the expected hash value.
 
   @param[in]   AuthData             iSCSI CHAP authentication data.
diff --git a/NetworkPkg/IScsiDxe/IScsiConfig.c b/NetworkPkg/IScsiDxe/IScsiConfig.c
index d773849fd3b0..326b1da39ea3 100644
--- a/NetworkPkg/IScsiDxe/IScsiConfig.c
+++ b/NetworkPkg/IScsiDxe/IScsiConfig.c
@@ -293,7 +293,7 @@ IScsiConvertIsIdToString (
   @param[in]  String             The string is "&OFFSET=".
   @param[out] Value              The Offset value.
 
-  @retval EFI_OUT_OF_RESOURCES   Insufficient resources to store neccessary
+  @retval EFI_OUT_OF_RESOURCES   Insufficient resources to store necessary
                                  structures.
   @retval EFI_SUCCESS            Value of <Number> is outputted in Number
                                  successfully.
@@ -2229,7 +2229,7 @@ IScsiConfigAddAttemptsByKeywords (
 
   @retval EFI_NOT_FOUND          Cannot find the corresponding variable.
   @retval EFI_SUCCESS            The operation is completed successfully.
-  @retval EFI_ABOTRED            This operation is aborted cause of error
+  @retval EFI_ABORTED            This operation is aborted cause of error
                                  configuration.
   @retval EFI_OUT_OF_RESOURCES   Fail to finish the operation due to lack of
                                  resources.
@@ -3024,7 +3024,7 @@ IScsiFormExtractConfig (
   }
 
   //
-  // Extract all AttemptConfigData to Keyword stroage of IfrNvData.
+  // Extract all AttemptConfigData to Keyword storage of IfrNvData.
   //
   IScsiConvertAttemptConfigDataToIfrNvDataByKeyword (IfrNvData);
 
diff --git a/NetworkPkg/IScsiDxe/IScsiDhcp.c b/NetworkPkg/IScsiDxe/IScsiDhcp.c
index d8c9fff6c65d..7ce9bf575012 100644
--- a/NetworkPkg/IScsiDxe/IScsiDhcp.c
+++ b/NetworkPkg/IScsiDxe/IScsiDhcp.c
@@ -193,7 +193,7 @@ ON_EXIT:
 }
 
 /**
-  The callback function registerd to the DHCP4 instance that is used to select
+  The callback function registered to the DHCP4 instance that is used to select
   the qualified DHCP OFFER.
 
   @param[in]  This         The DHCP4 protocol.
@@ -460,7 +460,7 @@ IScsiDoDhcp (
   // the active state, If the DHCP4 D.O.R.A started by IP4 auto
   // configuration and has not been completed, the Dhcp4 state machine
   // will not be in the right state for the iSCSI to start a new round D.O.R.A.
-  // So, we need to switch it's policy to static.
+  // So, we need to switch its policy to static.
   //
   Status = gBS->HandleProtocol (Controller, &gEfiIp4Config2ProtocolGuid, (VOID **) &Ip4Config2);
   if (!EFI_ERROR (Status)) {
diff --git a/NetworkPkg/IScsiDxe/IScsiDriver.c b/NetworkPkg/IScsiDxe/IScsiDriver.c
index 94c9b228c241..98b73308c118 100644
--- a/NetworkPkg/IScsiDxe/IScsiDriver.c
+++ b/NetworkPkg/IScsiDxe/IScsiDriver.c
@@ -334,7 +334,7 @@ IScsiSupported (
   @param[in]  ControllerHandle     Handle of the controller.
   @param[in]  IpVersion            IP_VERSION_4 or IP_VERSION_6.
 
-  @retval EFI_SUCCES            This driver was started.
+  @retval EFI_SUCCESS           This driver was started.
   @retval EFI_ALREADY_STARTED   This driver is already running on this device.
   @retval EFI_INVALID_PARAMETER Any input parameter is invalid.
   @retval EFI_NOT_FOUND         There is no sufficient information to establish
@@ -720,7 +720,7 @@ IScsiStart (
     }
 
     //
-    // Restore the origial user setting which specifies the proxy/virtual iSCSI target to NV region.
+    // Restore the original user setting which specifies the proxy/virtual iSCSI target to NV region.
     //
     NvData = &AttemptConfigData->SessionConfigData;
     if (NvData->RedirectFlag) {
@@ -1091,7 +1091,7 @@ IScsiStop (
   }
 
   //
-  // Get the handle of the controller we are controling.
+  // Get the handle of the controller we are controlling.
   //
   if (IpVersion == IP_VERSION_4) {
     ProtocolGuid            = &gIScsiV4PrivateGuid;
@@ -1154,7 +1154,7 @@ IScsiStop (
   IScsiRemoveNic (IScsiController);
 
   //
-  // Update the iSCSI Boot Firware Table.
+  // Update the iSCSI Boot Firmware Table.
   //
   IScsiPublishIbft ();
 
@@ -1504,7 +1504,7 @@ IScsiUnload (
   EFI_COMPONENT_NAME2_PROTOCOL      *ComponentName2;
 
   //
-  // Try to disonnect the driver from the devices it's controlling.
+  // Try to disconnect the driver from the devices it's controlling.
   //
   Status = gBS->LocateHandleBuffer (
                   AllHandles,
diff --git a/NetworkPkg/IScsiDxe/IScsiMisc.c b/NetworkPkg/IScsiDxe/IScsiMisc.c
index 38ad67917c30..b8fef3ff6f5a 100644
--- a/NetworkPkg/IScsiDxe/IScsiMisc.c
+++ b/NetworkPkg/IScsiDxe/IScsiMisc.c
@@ -272,7 +272,7 @@ IScsiAsciiStrToIp (
 }
 
 /**
-  Convert the mac address into a hexadecimal encoded "-" seperated string.
+  Convert the mac address into a hexadecimal encoded "-" separated string.
 
   @param[in]  Mac     The mac address.
   @param[in]  Len     Length in bytes of the mac address.
@@ -2412,7 +2412,7 @@ IScsiGetTcpConnDevicePath (
         //  Add a judgement here to support previous versions of IPv4_DEVICE_PATH.
         //  In previous versions of IPv4_DEVICE_PATH, GatewayIpAddress and SubnetMask
         //  do not exist.
-        //  In new version of IPv4_DEVICE_PATH, structcure length is 27.
+        //  In new version of IPv4_DEVICE_PATH, structure length is 27.
         //
 
         PathLen = DevicePathNodeLength (&DPathNode->Ipv4);
@@ -2502,7 +2502,7 @@ IScsiOnExitBootService (
 
   This function tests whether the driver specified by DriverBindingHandle is
   currently managing the controller specified by ControllerHandle.  This test
-  is performed by evaluating if the the protocol specified by ProtocolGuid is
+  is performed by evaluating if the protocol specified by ProtocolGuid is
   present on ControllerHandle and is was opened by DriverBindingHandle and Nic
   Device handle with an attribute of EFI_OPEN_PROTOCOL_BY_DRIVER.
   If ProtocolGuid is NULL, then ASSERT().
diff --git a/NetworkPkg/IScsiDxe/IScsiProto.c b/NetworkPkg/IScsiDxe/IScsiProto.c
index 6fbf973e35f3..6983f0fa5973 100644
--- a/NetworkPkg/IScsiDxe/IScsiProto.c
+++ b/NetworkPkg/IScsiDxe/IScsiProto.c
@@ -468,7 +468,7 @@ IScsiSessionLogin (
     IScsiAttatchConnection (Session, Conn);
 
     //
-    // Login througth the newly created connection.
+    // Login through the newly created connection.
     //
     Status = IScsiConnLogin (Conn, Session->ConfigData->SessionConfigData.ConnectTimeout);
     if (EFI_ERROR (Status)) {
@@ -765,7 +765,7 @@ IScsiPrepareLoginReq (
   LoginReq->CmdSN             = HTONL (Session->CmdSN);
 
   //
-  // For the first Login Request on a coonection this is ExpStatSN for the
+  // For the first Login Request on a connection this is ExpStatSN for the
   // old connection, and this field is only valid if the Login Request restarts
   // a connection.
   // For subsequent Login Requests it is used to acknowledge the Login Responses
@@ -941,7 +941,7 @@ IScsiProcessLoginRsp (
     // A Login Response with the C bit set to 1 MUST have the T bit set to 0.
     // The CSG in the Login Response MUST be the same with the I-end of this connection.
     // The T bit can't be 1 if the last Login Response sent by the initiator doesn't
-    // initiate the transistion.
+    // initiate the transition.
     // The NSG MUST be the same with the I-end of this connection if Transit is required.
     // The ISID in the Login Response MUST be the same with this session.
     //
@@ -1152,13 +1152,13 @@ IScsiUpdateTargetAddress (
     }
 
     //
-    // Save the origial user setting which specifies the proxy/virtual iSCSI target.
+    // Save the original user setting which specifies the proxy/virtual iSCSI target.
     //
     NvData->OriginalTargetPort = NvData->TargetPort;
 
     if (*TargetAddress == ',') {
       //
-      // Comma and the portal group tag MUST be ommitted if the TargetAddress is sent
+      // Comma and the portal group tag MUST be omitted if the TargetAddress is sent
       // as the result of a redirection.
       //
       continue;
@@ -1181,7 +1181,7 @@ IScsiUpdateTargetAddress (
     }
 
     //
-    // Save the origial user setting which specifies the proxy/virtual iSCSI target.
+    // Save the original user setting which specifies the proxy/virtual iSCSI target.
     //
     CopyMem (&NvData->OriginalTargetIp, &NvData->TargetIp, sizeof (EFI_IP_ADDRESS));
 
@@ -1471,7 +1471,7 @@ ON_EXIT:
 
   @param[in, out]  Conn          The connection in iSCSI login.
 
-  @retval EFI_SUCCESS          The parmeter check is passed and negotiation is finished.
+  @retval EFI_SUCCESS          The parameter check is passed and negotiation is finished.
   @retval EFI_PROTOCOL_ERROR   Some kind of iSCSI protocol error occurred.
   @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.
 
@@ -1546,7 +1546,7 @@ IScsiCheckOpParams (
     goto ON_ERROR;
   }
   //
-  // ErrorRecoveryLevel: result fuction is Minimum.
+  // ErrorRecoveryLevel: result function is Minimum.
   //
   Value = IScsiGetValueByKeyFromList (KeyValueList, ISCSI_KEY_ERROR_RECOVERY_LEVEL);
   if (Value == NULL) {
@@ -1590,7 +1590,7 @@ IScsiCheckOpParams (
     Conn->MaxRecvDataSegmentLength = (UINT32) IScsiNetNtoi (Value);
   }
   //
-  // MaxBurstLength: result funtion is Mininum.
+  // MaxBurstLength: result function is Minimum.
   //
   Value = IScsiGetValueByKeyFromList (KeyValueList, ISCSI_KEY_MAX_BURST_LENGTH);
   if (Value == NULL) {
@@ -2249,7 +2249,7 @@ IScsiNewScsiCmdPdu (
 
   if (Session->ImmediateData && (Packet->OutTransferLength != 0)) {
     //
-    // Send immediate data in this SCSI Command PDU. The length of the immeidate
+    // Send immediate data in this SCSI Command PDU. The length of the immediate
     // data is the minimum of FirstBurstLength, the data length to be xfered, and
     // the MaxRecvdataSegmentLength on this connection.
     //
@@ -2494,7 +2494,7 @@ ON_EXIT:
   @param[in]  Lun             The LUN the data will be sent to.
   @param[in]  Tcb             The task control block.
 
-  @retval EFI_SUCCES           The data is sent out to the LUN.
+  @retval EFI_SUCCESS          The data is sent out to the LUN.
   @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.
   @retval Others               Other errors as indicated.
 
@@ -2547,9 +2547,9 @@ IScsiSendDataOutPduSequence (
   @param[in]        Tcb      The task control block.
   @param[in, out]   Packet   The EXT SCSI PASS THRU request packet.
 
-  @retval EFI_SUCCES           The check on the Data IN PDU is passed and some update
+  @retval EFI_SUCCESS          The check on the Data IN PDU is passed and some update
                                actions are taken.
-  @retval EFI_PROTOCOL_ERROR   Some kind of iSCSI protocol errror occurred.
+  @retval EFI_PROTOCOL_ERROR   Some kind of iSCSI protocol error occurred.
   @retval EFI_BAD_BUFFER_SIZEE The buffer was not the proper size for the request.
   @retval Others               Other errors as indicated.
 
@@ -2639,8 +2639,8 @@ IScsiOnDataInRcvd (
   @param[in]       Lun       The Lun.
   @param[in, out]  Packet    The EXT SCSI PASS THRU request packet.
 
-  @retval EFI_SUCCES         The R2T PDU is valid and the solicited data is sent out.
-  @retval EFI_PROTOCOL_ERROR Some kind of iSCSI protocol errror occurred.
+  @retval EFI_SUCCESS        The R2T PDU is valid and the solicited data is sent out.
+  @retval EFI_PROTOCOL_ERROR Some kind of iSCSI protocol error occurred.
   @retval Others             Other errors as indicated.
 
 **/
@@ -2707,8 +2707,8 @@ IScsiOnR2TRcvd (
   @param[in]       Tcb      The task control block.
   @param[in, out]  Packet   The EXT SCSI PASS THRU request packet.
 
-  @retval EFI_SUCCES         The Response PDU is processed.
-  @retval EFI_PROTOCOL_ERROR Some kind of iSCSI protocol errror occurred.
+  @retval EFI_SUCCESS        The Response PDU is processed.
+  @retval EFI_PROTOCOL_ERROR Some kind of iSCSI protocol error occurred.
   @retval EFI_BAD_BUFFER_SIZEE The buffer was not the proper size for the request.
   @retval Others             Other errors as indicated.
 
@@ -2815,9 +2815,9 @@ IScsiOnScsiRspRcvd (
   @param[in]  Pdu            The NOP In PDU received.
   @param[in]  Tcb            The task control block.
 
-  @retval EFI_SUCCES         The NOP In PDU is processed and the related sequence
+  @retval EFI_SUCCESS        The NOP In PDU is processed and the related sequence
                              numbers are updated.
-  @retval EFI_PROTOCOL_ERROR Some kind of iSCSI protocol errror occurred.
+  @retval EFI_PROTOCOL_ERROR Some kind of iSCSI protocol error occurred.
 
 **/
 EFI_STATUS
@@ -2864,7 +2864,7 @@ IScsiOnNopInRcvd (
   @param[in, out]  Packet    The request packet containing IO request, SCSI command
                              buffer and buffers to read/write.
 
-  @retval EFI_SUCCES           The SCSI command is executed and the result is updated to
+  @retval EFI_SUCCESS          The SCSI command is executed and the result is updated to
                                the Packet.
   @retval EFI_DEVICE_ERROR     Session state was not as required.
   @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.
-- 
2.21.0


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#52775): https://edk2.groups.io/g/devel/message/52775
Mute This Topic: https://groups.io/mt/69395926/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-





More information about the edk2-devel-archive mailing list