]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Library/DxeNetLib/NetBuffer.c
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7125 6f19259b...
[mirror_edk2.git] / MdeModulePkg / Library / DxeNetLib / NetBuffer.c
index fcfb0936bc5c611f335c75f8be05f9f42374e83c..a92efb71c0408e7f884e55d9c2556d56b6abd7fb 100644 (file)
@@ -137,11 +137,11 @@ FreeNBuf:
 }\r
 \r
 /**\r
-  Free the vector. \r
+  Free the net vector. \r
    \r
-  Decrease the reference count of the vector by one. The real resource free \r
-  operation isn't performed until the reference count of the vector is decreased \r
-  to 0.\r
+  Decrease the reference count of the net vector by one. The real resource free \r
+  operation isn't performed until the reference count of the net vector is \r
+  decreased to 0. \r
 \r
   @param[in]  Vector                Pointer to the NET_VECTOR to be freed.\r
 \r
@@ -190,11 +190,11 @@ NetbufFreeVector (
 /**\r
   Free the net buffer and its associated NET_VECTOR.\r
  \r
-  Decrease the reference count of the net buffer by one. Free the associated\r
-  vector and itself if the reference count of the net buffer is decreased to 0.\r
-  The vector free operation just decrease the reference count of the vector by\r
-  one and do the real resource free operation when the reference count of the\r
-  vector is 0.\r
+  Decrease the reference count of the net buffer by one. Free the associated net\r
+  vector and itself if the reference count of the net buffer is decreased to 0. \r
+  The net vector free operation just decrease the reference count of the net \r
+  vector by one and do the real resource free operation when the reference count\r
+  of the net vector is 0. \r
  \r
   @param[in]  Nbuf                  Pointer to the NET_BUF to be freed.\r
 \r
@@ -323,7 +323,7 @@ NetbufDuplicate (
   Free a list of net buffers.\r
 \r
   @param[in, out]  Head              Pointer to the head of linked net buffers.\r
-NOT YET\r
+\r
 **/\r
 VOID\r
 EFIAPI\r
@@ -362,8 +362,8 @@ NetbufFreeList (
   @param[out]  Index     Index of the NET_BLOCK_OP that contains the byte at \r
                          Offset.\r
 \r
-  @return       Pointer to the nth byte of data in the net buffer, or NULL \r
-                indicating there is no such data in the net buffer.\r
+  @return       Pointer to the Offset'th byte of data in the net buffer, or NULL\r
+                if there is no such data in the net buffer.\r
 \r
 **/\r
 UINT8  *\r
@@ -486,13 +486,13 @@ NetbufSetBlockOp (
 \r
 \r
 /**\r
-  Helper function for NetbufClone. It is necessary because NetbufGetFragment\r
-  may allocate the first block to accomodate the HeadSpace and HeadLen. So, it\r
-  need to create a new NET_VECTOR. But, we want to avoid data copy by sharing\r
-  the old NET_VECTOR.\r
+  Helper function for NetbufGetFragment. NetbufGetFragment may allocate the \r
+  first block to reserve HeadSpace bytes header space. So it needs to create a \r
+  new net vector for the first block and can avoid copy for the remaining data \r
+  by sharing the old net vector. \r
 \r
   @param[in]  Arg                   Point to the old NET_VECTOR.\r
-NOT YET\r
+\r
 **/\r
 VOID\r
 NetbufGetFragmentFree (\r
@@ -520,8 +520,8 @@ NetbufGetFragmentFree (
   @param[in]  Len          Bytes of data to be included in the new net buffer. \r
   @param[in]  HeadSpace    Bytes of head space to reserve for protocol header. \r
 \r
-  @return                  Pointer to the cloned net buffer, or NULL indicating \r
-                           the allocation failed due to resource limit.\r
+  @return                  Pointer to the cloned net buffer, or NULL if the \r
+                           allocation failed due to resource limit.\r
 \r
 **/\r
 NET_BUF  *\r
@@ -631,7 +631,7 @@ NetbufGetFragment (
     Vector->Len   = HeadSpace;\r
 \r
     //\r
-    //Reserve the head space in the first block\r
+    // Reserve the head space in the first block\r
     //\r
     NetbufSetBlock (Child, FirstBulk, HeadSpace, 0);\r
     Child->BlockOp[0].Head += HeadSpace;\r
@@ -709,8 +709,8 @@ FreeChild:
                                     called.\r
 \r
   @return                  Pointer to the net buffer built from the data blocks, \r
-                           or NULL indicating the allocation failed due to\r
-                           resource limit.\r
+                           or NULL if the allocation failed due to resource\r
+                           limit.\r
 \r
 **/\r
 NET_BUF  *\r
@@ -1034,7 +1034,7 @@ NetbufReserve (
                               from head (TRUE) or tail (FALSE).\r
 \r
   @return                     Pointer to the first byte of the allocated buffer, \r
-                              or NULL indicating there is no sufficient space.\r
+                              or NULL if there is no sufficient space.\r
 \r
 **/\r
 UINT8*\r
@@ -1420,8 +1420,7 @@ NetbufQueAppend (
   @param[in, out]  NbufQue               Pointer to the net buffer queue.\r
 \r
   @return           Pointer to the net buffer removed from the specific queue, \r
-                    or NULL indicating there is no net buffer in the specific\r
-                    queue.\r
+                    or NULL if there is no net buffer in the specific queue.\r
 \r
 **/\r
 NET_BUF  *\r
@@ -1460,7 +1459,7 @@ NetbufQueRemove (
   @param[in]   Len             Length of the data to copy.\r
   @param[out]  Dest            The destination of the data to copy to.\r
 \r
-  @return       The length of the actual copied data, or 0 indicating the offset\r
+  @return       The length of the actual copied data, or 0 if the offset \r
                 specified exceeds the total size of net buffer queue.\r
 \r
 **/\r