]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Updated protocol function header per UEFI Spec.
authorjgong5 <jgong5@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 13 Nov 2008 06:26:27 +0000 (06:26 +0000)
committerjgong5 <jgong5@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 13 Nov 2008 06:26:27 +0000 (06:26 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6485 6f19259b-4bc3-4df7-8a09-765794883524

MdePkg/Include/Protocol/Udp4.h

index b7409f220c3172e09810d82c1cb4695faee19a01..6ba49a7d275ac850e787f7070c0b6c5840663f19 100644 (file)
@@ -125,6 +125,11 @@ typedef struct {
 /**\r
   Reads the current operational settings.\r
 \r
+  The GetModeData() function copies the current operational settings of this EFI\r
+  UDPv4 Protocol instance into user-supplied buffers. This function is used\r
+  optionally to retrieve the operational mode data of underlying networks or\r
+  drivers.\r
+\r
   @param  This           Pointer to the EFI_UDP4_PROTOCOL instance.\r
   @param  Udp4ConfigData Pointer to the buffer to receive the current configuration data.\r
   @param  Ip4ModeData    Pointer to the EFI IPv4 Protocol mode data structure.\r
@@ -151,6 +156,17 @@ EFI_STATUS
 /**\r
   Initializes, changes, or resets the operational parameters for this instance of the EFI UDPv4\r
   Protocol.\r
+  \r
+  The Configure() function is used to do the following:\r
+  * Initialize and start this instance of the EFI UDPv4 Protocol.\r
+  * Change the filtering rules and operational parameters.\r
+  * Reset this instance of the EFI UDPv4 Protocol.\r
+  Until these parameters are initialized, no network traffic can be sent or\r
+  received by this instance. This instance can be also reset by calling Configure()\r
+  with UdpConfigData set to NULL. Once reset, the receiving queue and transmitting\r
+  queue are flushed and no traffic is allowed through this instance.\r
+  With different parameters in UdpConfigData, Configure() can be used to bind\r
+  this instance to specified port.\r
 \r
   @param  This           Pointer to the EFI_UDP4_PROTOCOL instance.\r
   @param  Udp4ConfigData Pointer to the buffer to receive the current configuration data.\r
@@ -179,6 +195,10 @@ EFI_STATUS
 \r
 /**\r
   Joins and leaves multicast groups.\r
+  \r
+  The Groups() function is used to enable and disable the multicast group\r
+  filtering. If the JoinFlag is FALSE and the MulticastAddress is NULL, then all\r
+  currently joined groups are left.\r
 \r
   @param  This             Pointer to the EFI_UDP4_PROTOCOL instance.\r
   @param  JoinFlag         Set to TRUE to join a multicast group. Set to FALSE to leave one\r
@@ -212,6 +232,24 @@ EFI_STATUS
 \r
 /**\r
   Adds and deletes routing table entries.\r
+  \r
+  The Routes() function adds a route to or deletes a route from the routing table.\r
+  Routes are determined by comparing the SubnetAddress with the destination IP\r
+  address and arithmetically AND-ing it with the SubnetMask. The gateway address\r
+  must be on the same subnet as the configured station address.\r
+  The default route is added with SubnetAddress and SubnetMask both set to 0.0.0.0.\r
+  The default route matches all destination IP addresses that do not match any\r
+  other routes.\r
+  A zero GatewayAddress is a nonroute. Packets are sent to the destination IP\r
+  address if it can be found in the Address Resolution Protocol (ARP) cache or\r
+  on the local subnet. One automatic nonroute entry will be inserted into the\r
+  routing table for outgoing packets that are addressed to a local subnet\r
+  (gateway address of 0.0.0.0).\r
+  Each instance of the EFI UDPv4 Protocol has its own independent routing table.\r
+  Instances of the EFI UDPv4 Protocol that use the default IP address will also\r
+  have copies of the routing table provided by the EFI_IP4_CONFIG_PROTOCOL. These\r
+  copies will be updated automatically whenever the IP driver reconfigures its\r
+  instances; as a result, the previous modification to these copies will be lost.\r
 \r
   @param  This           Pointer to the EFI_UDP4_PROTOCOL instance.\r
   @param  DeleteRoute    Set to TRUE to delete this route from the routing table.\r
@@ -242,6 +280,15 @@ EFI_STATUS
 \r
 /**\r
   Polls for incoming data packets and processes outgoing data packets.\r
+  \r
+  The Poll() function can be used by network drivers and applications to increase\r
+  the rate that data packets are moved between the communications device and the\r
+  transmit and receive queues.\r
+  In some systems, the periodic timer event in the managed network driver may not\r
+  poll the underlying communications device fast enough to transmit and/or receive\r
+  all data packets without missing incoming packets or dropping outgoing packets.\r
+  Drivers and applications that are experiencing packet loss should try calling\r
+  the Poll() function more often.\r
 \r
   @param  This Pointer to the EFI_UDP4_PROTOCOL instance.\r
 \r
@@ -259,6 +306,15 @@ EFI_STATUS
 \r
 /**\r
   Places an asynchronous receive request into the receiving queue.\r
+  \r
+  The Receive() function places a completion token into the receive packet queue.\r
+  This function is always asynchronous.\r
+  The caller must fill in the Token.Event field in the completion token, and this\r
+  field cannot be NULL. When the receive operation completes, the EFI UDPv4 Protocol\r
+  driver updates the Token.Status and Token.Packet.RxData fields and the Token.Event\r
+  is signaled. Providing a proper notification function and context for the event\r
+  will enable the user to receive the notification and receiving status. That\r
+  notification function is guaranteed to not be re-entered.\r
 \r
   @param  This  Pointer to the EFI_UDP4_PROTOCOL instance.\r
   @param  Token Pointer to a token that is associated with the receive data\r
@@ -286,6 +342,13 @@ EFI_STATUS
 \r
 /**\r
   Queues outgoing data packets into the transmit queue.\r
+  \r
+  The Transmit() function places a sending request to this instance of the EFI\r
+  UDPv4 Protocol, alongside the transmit data that was filled by the user. Whenever\r
+  the packet in the token is sent out or some errors occur, the Token.Event will\r
+  be signaled and Token.Status is updated. Providing a proper notification function\r
+  and context for the event will enable the user to receive the notification and\r
+  transmitting status.\r
 \r
   @param  This  Pointer to the EFI_UDP4_PROTOCOL instance.\r
   @param  Token Pointer to the completion token that will be placed into the\r
@@ -316,6 +379,13 @@ EFI_STATUS
 \r
 /**\r
   Aborts an asynchronous transmit or receive request.\r
+  \r
+  The Cancel() function is used to abort a pending transmit or receive request.\r
+  If the token is in the transmit or receive request queues, after calling this\r
+  function, Token.Status will be set to EFI_ABORTED and then Token.Event will be\r
+  signaled. If the token is not in one of the queues, which usually means that\r
+  the asynchronous operation has completed, this function will not signal the\r
+  token and EFI_NOT_FOUND is returned.\r
 \r
   @param  This  Pointer to the EFI_UDP4_PROTOCOL instance.\r
   @param  Token Pointer to a token that has been issued by\r