]> git.proxmox.com Git - mirror_edk2.git/commitdiff
synced function header
authorjgong5 <jgong5@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 18 Nov 2008 14:30:46 +0000 (14:30 +0000)
committerjgong5 <jgong5@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 18 Nov 2008 14:30:46 +0000 (14:30 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6615 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Driver.h
MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Impl.h
MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Io.h
MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Option.h

index b0052bef694cfb37024a15a43a7f8fb0bbff831a..66396707f970751e31a9fbb1fd56b9f9aa7cd24d 100644 (file)
@@ -27,16 +27,21 @@ extern EFI_COMPONENT_NAME_PROTOCOL  gDhcp4ComponentName;
 extern EFI_COMPONENT_NAME2_PROTOCOL gDhcp4ComponentName2;\r
 \r
 /**\r
-  Test to see if this driver supports ControllerHandle.\r
-\r
-  @param  This                   Protocol instance pointer.\r
-  @param  ControllerHandle       Handle of device to test.\r
-  @param  RemainingDevicePath    Optional parameter use to pick a specific child\r
-                                 device to start.\r
-\r
-  @retval EFI_SUCCES             This driver supports this device\r
-  @retval EFI_ALREADY_STARTED    This driver is already running on this device.\r
-  @retval other                  This driver does not support this device.\r
+  Test to see if this driver supports ControllerHandle. This service\r
+  is called by the EFI boot service ConnectController(). In\r
+  order to make drivers as small as possible, there are a few calling\r
+  restrictions for this service. ConnectController() must\r
+  follow these calling restrictions. If any other agent wishes to call\r
+  Supported() it must also follow these calling restrictions.\r
+\r
+  @param  This                Protocol instance pointer.\r
+  @param  ControllerHandle    Handle of device to test\r
+  @param  RemainingDevicePath Optional parameter use to pick a specific child\r
+                              device to start.\r
+\r
+  @retval EFI_SUCCESS         This driver supports this device\r
+  @retval EFI_ALREADY_STARTED This driver is already running on this device\r
+  @retval other               This driver does not support this device\r
 \r
 **/\r
 EFI_STATUS\r
@@ -48,16 +53,21 @@ Dhcp4DriverBindingSupported (
   );\r
 \r
 /**\r
-  Start this driver on ControllerHandle.\r
-\r
-  @param  This                   Protocol instance pointer.\r
-  @param  ControllerHandle       Handle of device to bind driver to\r
-  @param  RemainingDevicePath    Optional parameter use to pick a specific child\r
-                                 device to start.\r
-\r
-  @retval EFI_SUCCES             This driver is added to ControllerHandle\r
-  @retval EFI_ALREADY_STARTED    This driver is already running on ControllerHandle\r
-  @retval other                  This driver does not support this device\r
+  Start this driver on ControllerHandle. This service is called by the\r
+  EFI boot service ConnectController(). In order to make\r
+  drivers as small as possible, there are a few calling restrictions for\r
+  this service. ConnectController() must follow these\r
+  calling restrictions. If any other agent wishes to call Start() it\r
+  must also follow these calling restrictions.\r
+\r
+  @param  This                 Protocol instance pointer.\r
+  @param  ControllerHandle     Handle of device to bind driver to\r
+  @param  RemainingDevicePath  Optional parameter use to pick a specific child\r
+                               device to start.\r
+\r
+  @retval EFI_SUCCESS          This driver is added to ControllerHandle\r
+  @retval EFI_ALREADY_STARTED  This driver is already running on ControllerHandle\r
+  @retval other                This driver does not support this device\r
 \r
 **/\r
 EFI_STATUS\r
@@ -69,16 +79,21 @@ Dhcp4DriverBindingStart (
   );\r
 \r
 /**\r
-  Stop this driver on ControllerHandle.\r
-\r
-  @param  This                   Protocol instance pointer.\r
-  @param  ControllerHandle       Handle of device to stop driver on\r
-  @param  NumberOfChildren       Number of Handles in ChildHandleBuffer. If number\r
-                                 of  children is zero stop the entire bus driver.\r
-  @param  ChildHandleBuffer      List of Child Handles to Stop.\r
-\r
-  @retval EFI_SUCCES             This driver is removed ControllerHandle\r
-  @retval other                  This driver was not removed from this device\r
+  Stop this driver on ControllerHandle. This service is called by the\r
+  EFI boot service DisconnectController(). In order to\r
+  make drivers as small as possible, there are a few calling\r
+  restrictions for this service. DisconnectController()\r
+  must follow these calling restrictions. If any other agent wishes\r
+  to call Stop() it must also follow these calling restrictions.\r
+  \r
+  @param  This              Protocol instance pointer.\r
+  @param  ControllerHandle  Handle of device to stop driver on\r
+  @param  NumberOfChildren  Number of Handles in ChildHandleBuffer. If number of\r
+                            children is zero stop the entire bus driver.\r
+  @param  ChildHandleBuffer List of Child Handles to Stop.\r
+\r
+  @retval EFI_SUCCESS       This driver is removed ControllerHandle\r
+  @retval other             This driver was not removed from this device\r
 \r
 **/\r
 EFI_STATUS\r
@@ -93,17 +108,16 @@ Dhcp4DriverBindingStop (
 /**\r
   Creates a child handle with a set of I/O services.\r
 \r
-  @param  This                   Protocol instance pointer.\r
-  @param  ChildHandle            Pointer to the handle of the child to create. If\r
-                                 it is NULL, then a new handle is created. If it is\r
-                                 not NULL, then the I/O services are  added to the\r
-                                 existing child handle.\r
+  @param  This        Protocol instance pointer.\r
+  @param  ChildHandle Pointer to the handle of the child to create.  If it is NULL,\r
+                      then a new handle is created.  If it is not NULL, then the\r
+                      I/O services are added to the existing child handle.\r
 \r
-  @retval EFI_SUCCES             The child handle was created with the I/O\r
-                                 services.\r
-  @retval EFI_OUT_OF_RESOURCES   There are not enough resources availabe to create\r
-                                 the child.\r
-  @retval other                  The child handle was not created.\r
+  @retval EFI_SUCCES            The child handle was created with the I/O services\r
+  @retval EFI_INVALID_PARAMETER ChildHandle is NULL.\r
+  @retval EFI_OUT_OF_RESOURCES  There are not enough resources availabe to create\r
+                                the child\r
+  @retval other                 The child handle was not created\r
 \r
 **/\r
 EFI_STATUS\r
@@ -116,17 +130,16 @@ Dhcp4ServiceBindingCreateChild (
 /**\r
   Destroys a child handle with a set of I/O services.\r
 \r
-  @param  This                   Protocol instance pointer.\r
-  @param  ChildHandle            Handle of the child to destroy.\r
-\r
-  @retval EFI_SUCCES             The I/O services were removed from the child\r
-                                 handle.\r
-  @retval EFI_UNSUPPORTED        The child handle does not support the I/O services\r
-                                  that are being removed.\r
-  @retval EFI_INVALID_PARAMETER  Child handle is not a valid EFI Handle.\r
-  @retval EFI_ACCESS_DENIED      The child handle could not be destroyed because\r
-                                 its  I/O services are being used.\r
-  @retval other                  The child handle was not destroyed.\r
+  @param  This        Protocol instance pointer.\r
+  @param  ChildHandle Handle of the child to destroy\r
+\r
+  @retval EFI_SUCCES            The I/O services were removed from the child handle\r
+  @retval EFI_UNSUPPORTED       The child handle does not support the I/O services\r
+                                that are being removed.\r
+  @retval EFI_INVALID_PARAMETER Child handle is not a valid EFI Handle.\r
+  @retval EFI_ACCESS_DENIED     The child handle could not be destroyed because its\r
+                                I/O services are being used.\r
+  @retval other                 The child handle was not destroyed\r
 \r
 **/\r
 EFI_STATUS\r
index 16ea4936cf3447ea19cbeabf94d5c1926c8c217a..db75addae88202fe571d0c10deb6206c4e51a91e 100644 (file)
@@ -165,9 +165,17 @@ extern EFI_DHCP4_PROTOCOL mDhcp4ProtocolTemplate;
 **/\r
 VOID\r
 DhcpYieldControl (\r
-  IN DHCP_SERVICE         *DhcpSb\r
+  IN DHCP_SERVICE           *DhcpSb\r
   );\r
 \r
+/**\r
+  Complete a Dhcp4 transaction and signal the upper layer.\r
+  \r
+  @param Instance      Dhcp4 instance.\r
+  \r
+  @return None.\r
+\r
+**/\r
 VOID\r
 PxeDhcpDone (\r
   IN DHCP_PROTOCOL  *Instance\r
index 4dab42e9a7440b060d690ce7c10e1474688d2a5c..21bbf194bff216a0f9c047d3df4793b91d22d96e 100644 (file)
@@ -93,9 +93,9 @@ typedef enum {
 **/\r
 EFI_STATUS\r
 DhcpSetState (\r
-  IN DHCP_SERVICE           *DhcpSb,\r
-  IN INTN                   State,\r
-  IN BOOLEAN                CallUser\r
+  IN OUT DHCP_SERVICE           *DhcpSb,\r
+  IN     INTN                   State,\r
+  IN     BOOLEAN                CallUser\r
   );\r
 \r
 /**\r
@@ -114,6 +114,7 @@ DhcpSetState (
   @retval EFI_OUT_OF_RESOURCES  Failed to allocate resources for the packet\r
   @retval EFI_ACCESS_DENIED     Failed to transmit the packet through UDP\r
   @retval EFI_SUCCESS           The message is sent\r
+  @retval other                 Other error occurs\r
 \r
 **/\r
 EFI_STATUS\r
@@ -146,7 +147,7 @@ DhcpOnTimerTick (
   );\r
 \r
 /**\r
-  Handle the received DHCP packets. This function drivers the DHCP\r
+  Handle the received DHCP packets. This function drives the DHCP\r
   state machine.\r
 \r
   @param  UdpPacket             The UDP packets received.\r
@@ -172,6 +173,7 @@ DhcpInput (
   @param  DhcpSb                The DHCP service instance\r
 \r
   @retval EFI_SUCCESS           The request has been sent\r
+  @retval other                 Some error occurs when sending the request.\r
 \r
 **/\r
 EFI_STATUS\r
index fe62e55085f270fc219233b2fe08a67715df89e4..74d84b3f8148f2558b12c523170be8a1f6a503ea 100644 (file)
@@ -239,13 +239,13 @@ EFI_STATUS
   @param  Context                The opaque parameter for Check\r
 \r
   @retval EFI_SUCCESS            The DHCP packet's options are well formated\r
-  @retval Others                 The DHCP packet's options are not well formated\r
+  @retval EFI_INVALID_PARAMETER  The DHCP packet's options are not well formated\r
 \r
 **/\r
 EFI_STATUS\r
 DhcpIterateOptions (\r
   IN  EFI_DHCP4_PACKET      *Packet,\r
-  IN  DHCP_CHECK_OPTION     Check,          OPTIONAL\r
+  IN  DHCP_CHECK_OPTION     Check,        OPTIONAL\r
   IN  VOID                  *Context\r
   );\r
 \r
@@ -264,7 +264,7 @@ DhcpIterateOptions (
 EFI_STATUS\r
 DhcpValidateOptions (\r
   IN  EFI_DHCP4_PACKET      *Packet,\r
-  OUT DHCP_PARAMETER        **Para          OPTIONAL\r
+  OUT DHCP_PARAMETER        **Para       OPTIONAL\r
   );\r
 \r
 /**\r
@@ -277,7 +277,7 @@ DhcpValidateOptions (
   as a UINT8. It then iterates the DHCP packet to get data length of\r
   each option by calling DhcpIterOptions with DhcpGetOptionLen. Now, it\r
   knows the number of present options and their length. It allocates a\r
-  array of DHCP_OPTION and a continous buffer after the array to put\r
+  array of DHCP_OPTION and a continuous buffer after the array to put\r
   all the options' data. Each option's data is pointed to by the Data\r
   field in DHCP_OPTION structure. At last, it call DhcpIterateOptions\r
   with DhcpFillOption to fill each option's data to its position in the\r
@@ -315,10 +315,10 @@ DhcpParseOption (
 **/\r
 UINT8 *\r
 DhcpAppendOption (\r
-  IN UINT8                  *Buf,\r
-  IN UINT8                  Tag,\r
-  IN UINT16                 DataLen,\r
-  IN UINT8                  *Data\r
+  OUT UINT8                  *Buf,\r
+  IN  UINT8                  Tag,\r
+  IN  UINT16                 DataLen,\r
+  IN  UINT8                  *Data\r
   );\r
 \r
 /**\r
@@ -334,17 +334,18 @@ DhcpAppendOption (
                                  function.\r
 \r
   @retval EFI_OUT_OF_RESOURCES   Failed to allocate memory\r
+  @retval EFI_INVALID_PARAMETER  The options in SeekPacket are mal-formated\r
   @retval EFI_SUCCESS            The packet is build.\r
 \r
 **/\r
 EFI_STATUS\r
 DhcpBuild (\r
-  IN  EFI_DHCP4_PACKET         *SeedPacket,\r
-  IN  UINT32                   DeleteCount,\r
-  IN  UINT8                    *DeleteList OPTIONAL,\r
-  IN  UINT32                   AppendCount,\r
-  IN  EFI_DHCP4_PACKET_OPTION  *AppendList[] OPTIONAL,\r
-  OUT EFI_DHCP4_PACKET         **NewPacket\r
+  IN  EFI_DHCP4_PACKET        *SeedPacket,\r
+  IN  UINT32                  DeleteCount,\r
+  IN  UINT8                   *DeleteList     OPTIONAL,\r
+  IN  UINT32                  AppendCount,\r
+  IN  EFI_DHCP4_PACKET_OPTION *AppendList[]   OPTIONAL,\r
+  OUT EFI_DHCP4_PACKET        **NewPacket\r
   );\r
 \r
 #endif\r