]> git.proxmox.com Git - mirror_edk2.git/blobdiff - NetworkPkg/Mtftp6Dxe/Mtftp6Driver.c
1. Fix a bug in PXE driver that the PXE boot do not restart if a new boot option...
[mirror_edk2.git] / NetworkPkg / Mtftp6Dxe / Mtftp6Driver.c
index 28aacf198a271609bca383df8466755970ed1bbc..432eea9cd4333f78b851e8c360fd39c75a2d5e7a 100644 (file)
@@ -2,7 +2,7 @@
   Driver Binding functions and Service Binding functions\r
   implementation for Mtftp6 Driver.\r
 \r
   Driver Binding functions and Service Binding functions\r
   implementation for Mtftp6 Driver.\r
 \r
-  Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>\r
 \r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
 \r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
@@ -33,7 +33,7 @@ EFI_SERVICE_BINDING_PROTOCOL  gMtftp6ServiceBindingTemplate = {
 \r
 \r
 /**\r
 \r
 \r
 /**\r
-  Destory the MTFTP6 service. The MTFTP6 service may be partly initialized,\r
+  Destroy the MTFTP6 service. The MTFTP6 service may be partly initialized,\r
   or partly destroyed. If a resource is destroyed, it is marked as such in\r
   case the destroy failed and is called again later.\r
 \r
   or partly destroyed. If a resource is destroyed, it is marked as such in\r
   case the destroy failed and is called again later.\r
 \r
@@ -46,7 +46,7 @@ Mtftp6DestroyService (
   )\r
 {\r
   //\r
   )\r
 {\r
   //\r
-  // Make sure all children instances have been already destoryed.\r
+  // Make sure all children instances have been already destroyed.\r
   //\r
   ASSERT (Service->ChildrenNum == 0);\r
 \r
   //\r
   ASSERT (Service->ChildrenNum == 0);\r
 \r
@@ -98,7 +98,7 @@ Mtftp6CreateService (
   Mtftp6Srv->Signature      = MTFTP6_SERVICE_SIGNATURE;\r
   Mtftp6Srv->Controller     = Controller;\r
   Mtftp6Srv->Image          = Image;\r
   Mtftp6Srv->Signature      = MTFTP6_SERVICE_SIGNATURE;\r
   Mtftp6Srv->Controller     = Controller;\r
   Mtftp6Srv->Image          = Image;\r
-  Mtftp6Srv->InDestory      = FALSE;\r
+  Mtftp6Srv->InDestroy      = FALSE;\r
   Mtftp6Srv->ChildrenNum    = 0;\r
 \r
   CopyMem (\r
   Mtftp6Srv->ChildrenNum    = 0;\r
 \r
   CopyMem (\r
@@ -219,7 +219,7 @@ Mtftp6CreateInstance (
   }\r
 \r
   Mtftp6Ins->Signature = MTFTP6_INSTANCE_SIGNATURE;\r
   }\r
 \r
   Mtftp6Ins->Signature = MTFTP6_INSTANCE_SIGNATURE;\r
-  Mtftp6Ins->InDestory = FALSE;\r
+  Mtftp6Ins->InDestroy = FALSE;\r
   Mtftp6Ins->Service   = Service;\r
 \r
   CopyMem (\r
   Mtftp6Ins->Service   = Service;\r
 \r
   CopyMem (\r
@@ -460,7 +460,7 @@ Mtftp6DriverBindingStop (
 \r
   Service = MTFTP6_SERVICE_FROM_THIS (ServiceBinding);\r
 \r
 \r
   Service = MTFTP6_SERVICE_FROM_THIS (ServiceBinding);\r
 \r
-  if (Service->InDestory) {\r
+  if (Service->InDestroy) {\r
     return EFI_SUCCESS;\r
   }\r
 \r
     return EFI_SUCCESS;\r
   }\r
 \r
@@ -468,9 +468,9 @@ Mtftp6DriverBindingStop (
 \r
   if (NumberOfChildren == 0) {\r
     //\r
 \r
   if (NumberOfChildren == 0) {\r
     //\r
-    // Destory the Mtftp6 service if there is no Mtftp6 child instance left.\r
+    // Destroy the Mtftp6 service if there is no Mtftp6 child instance left.\r
     //\r
     //\r
-    Service->InDestory = TRUE;\r
+    Service->InDestroy = TRUE;\r
 \r
     gBS->UninstallProtocolInterface (\r
            NicHandle,\r
 \r
     gBS->UninstallProtocolInterface (\r
            NicHandle,\r
@@ -482,7 +482,7 @@ Mtftp6DriverBindingStop (
 \r
   } else {\r
     //\r
 \r
   } else {\r
     //\r
-    // Destory the Mtftp6 child instance one by one.\r
+    // Destroy the Mtftp6 child instance one by one.\r
     //\r
     while (!IsListEmpty (&Service->Children)) {\r
       Instance = NET_LIST_HEAD (&Service->Children, MTFTP6_INSTANCE, Link);\r
     //\r
     while (!IsListEmpty (&Service->Children)) {\r
       Instance = NET_LIST_HEAD (&Service->Children, MTFTP6_INSTANCE, Link);\r
@@ -657,15 +657,15 @@ Mtftp6ServiceBindingDestroyChild (
   }\r
 \r
   //\r
   }\r
 \r
   //\r
-  // Check whether the instance already in destory state.\r
+  // Check whether the instance already in Destroy state.\r
   //\r
   //\r
-  if (Instance->InDestory) {\r
+  if (Instance->InDestroy) {\r
     return EFI_SUCCESS;\r
   }\r
 \r
   OldTpl = gBS->RaiseTPL (TPL_CALLBACK);\r
 \r
     return EFI_SUCCESS;\r
   }\r
 \r
   OldTpl = gBS->RaiseTPL (TPL_CALLBACK);\r
 \r
-  Instance->InDestory = TRUE;\r
+  Instance->InDestroy = TRUE;\r
 \r
   gBS->CloseProtocol (\r
          Service->DummyUdpIo->UdpHandle,\r
 \r
   gBS->CloseProtocol (\r
          Service->DummyUdpIo->UdpHandle,\r
@@ -684,7 +684,7 @@ Mtftp6ServiceBindingDestroyChild (
                   );\r
 \r
   if (EFI_ERROR (Status)) {\r
                   );\r
 \r
   if (EFI_ERROR (Status)) {\r
-    Instance->InDestory = FALSE;\r
+    Instance->InDestroy = FALSE;\r
     gBS->RestoreTPL (OldTpl);\r
     return Status;\r
   }\r
     gBS->RestoreTPL (OldTpl);\r
     return Status;\r
   }\r