/** @file\r
The implementation of the Udp4 protocol.\r
\r
-Copyright (c) 2006 - 2010, Intel Corporation.<BR> \r
-All rights reserved. This program and the accompanying materials\r
+Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>\r
+This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
which accompanies this distribution. The full text of the license may be found at\r
http://opensource.org/licenses/bsd-license.php\r
\r
@param[in] Status The completion status of the output udp datagram.\r
@param[in] Context Pointer to the context data.\r
- @param[in] Sender Pointer to the Ip sender of the udp datagram.\r
+ @param[in] Sender Specify a pointer of EFI_IP4_PROTOCOL for sending.\r
@param[in] NotifyData Pointer to the notify data.\r
\r
**/\r
VOID\r
EFIAPI\r
Udp4DgramSent (\r
- IN EFI_STATUS Status,\r
- IN VOID *Context,\r
- IN VOID *Sender,\r
- IN VOID *NotifyData\r
+ IN EFI_STATUS Status,\r
+ IN VOID *Context,\r
+ IN IP_IO_IP_PROTOCOL Sender,\r
+ IN VOID *NotifyData\r
);\r
\r
/**\r
//\r
// TimeoutTick unit is microsecond, MNP_TIMEOUT_CHECK_INTERVAL unit is 100ns.\r
//\r
- if (Wrap->TimeoutTick <= (UDP4_TIMEOUT_INTERVAL / 10)) {\r
+ if (Wrap->TimeoutTick < (UDP4_TIMEOUT_INTERVAL / 10)) {\r
//\r
// Remove this RxData if it timeouts.\r
//\r
Instance->IcmpError = EFI_SUCCESS;\r
Instance->Configured = FALSE;\r
Instance->IsNoMapping = FALSE;\r
- Instance->Destroyed = FALSE;\r
+ Instance->InDestroy = FALSE;\r
}\r
\r
\r
\r
@param[in] Status The completion status of the output udp datagram.\r
@param[in] Context Pointer to the context data.\r
- @param[in] Sender Pointer to the Ip sender of the udp datagram.\r
+ @param[in] Sender Specify a pointer of EFI_IP4_PROTOCOL for sending.\r
@param[in] NotifyData Pointer to the notify data.\r
\r
**/\r
VOID\r
EFIAPI\r
Udp4DgramSent (\r
- IN EFI_STATUS Status,\r
- IN VOID *Context,\r
- IN VOID *Sender,\r
- IN VOID *NotifyData\r
+ IN EFI_STATUS Status,\r
+ IN VOID *Context,\r
+ IN IP_IO_IP_PROTOCOL Sender,\r
+ IN VOID *NotifyData\r
)\r
{\r
UDP4_INSTANCE_DATA *Instance;\r
// Get the datagram header from the packet buffer.\r
//\r
Udp4Header = (EFI_UDP_HEADER *) NetbufGetByte (Packet, 0, NULL);\r
+ ASSERT (Udp4Header != NULL);\r
\r
if (Udp4Header->Checksum != 0) {\r
//\r
UDP4_INSTANCE_DATA *Instance;\r
\r
Udp4Header = (EFI_UDP_HEADER *) NetbufGetByte (Packet, 0, NULL);\r
+ ASSERT (Udp4Header != NULL);\r
\r
CopyMem (&Udp4Session.SourceAddress, &NetSession->Source, sizeof (EFI_IPv4_ADDRESS));\r
CopyMem (&Udp4Session.DestinationAddress, &NetSession->Dest, sizeof (EFI_IPv4_ADDRESS));\r