1.Define SPIN_LOCK as "volatile UINTN" to prevent mutli-processor access harzard.
authorqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 29 Mar 2007 07:45:24 +0000 (07:45 +0000)
committerqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 29 Mar 2007 07:45:24 +0000 (07:45 +0000)
2.Sync MTFTP4 Protocol GUID with spec.
3.Sync the definition the EFI_IP4_VARIABLE_DATA and EFI_TCP4_VARIABLE_DATA with spec

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2514 6f19259b-4bc3-4df7-8a09-765794883524

MdePkg/Include/Library/BaseLib.h
MdePkg/Include/Protocol/IP4.h
MdePkg/Include/Protocol/Mtftp4.h
MdePkg/Include/Protocol/Tcp4.h
MdePkg/Library/BaseLib/Synchronization.c

index f98b250402ce5124f5c360bf4f26942db7578df3..fb3ca341312650007d29ead837c633e8e9b91499 100644 (file)
@@ -25,7 +25,7 @@
 //
 // SPIN_LOCK
 //
-typedef UINTN                       SPIN_LOCK;
+typedef volatile UINTN              SPIN_LOCK;
 
 #if   defined (MDE_CPU_IA32)
 //
index 0decc176d4877c7070dd8b2d0d10ca8a851f863a..5a6ab5976bd34eb349327127007f7579aa41566c 100644 (file)
@@ -28,6 +28,7 @@
 typedef struct _EFI_IP4_PROTOCOL EFI_IP4_PROTOCOL;\r
   \r
 typedef struct {\r
+  EFI_HANDLE              InstanceHandle;\r
   EFI_IPv4_ADDRESS        Ip4Address;\r
   EFI_IPv4_ADDRESS        SubnetMask;\r
 } EFI_IP4_ADDRESS_PAIR; \r
index 9c0e0734b78286b10c18a1cd7cab2a612a97161a..18ae20bc4b9a795139d6ca5651eb51924bdd4a28 100644 (file)
@@ -24,7 +24,7 @@
 \r
 #define EFI_MTFTP4_PROTOCOL_GUID \\r
   { \\r
-    0x3ad9df29, 0x4501, 0x478d, {0xb1, 0xf8, 0x7f, 0x7f, 0xe7, 0x0e, 0x50, 0xf3 } \\r
+    0x78247c57, 0x63db, 0x4708, {0x99, 0xc2, 0xa8, 0xb4, 0xa9, 0xa6, 0x1f, 0x6b } \\r
   }\r
 \r
 typedef struct _EFI_MTFTP4_PROTOCOL EFI_MTFTP4_PROTOCOL;\r
index 11354b577ee9b3d904fb83637420af7d7fe7a285..8c22ef20962a05b879f5e31e8713f938b6bee0b8 100644 (file)
@@ -33,6 +33,7 @@
 typedef struct _EFI_TCP4_PROTOCOL EFI_TCP4_PROTOCOL;\r
 \r
 typedef struct {\r
+  EFI_HANDLE        InstanceHandle;\r
   EFI_IPv4_ADDRESS        LocalAddress;\r
   UINT16                  LocalPort;\r
   EFI_IPv4_ADDRESS        RemoteAddress;\r
@@ -41,7 +42,7 @@ typedef struct {
 \r
 typedef struct {\r
   EFI_HANDLE              DriverHandle;\r
-  UINT                  ServiceCount;\r
+  UINT32                  ServiceCount;\r
   EFI_TCP4_SERVICE_POINT  Services[1];\r
 } EFI_TCP4_VARIABLE_DATA;\r
 \r
index e08aa62cf98da10cf02d22d6a54a89d79b771fcd..225453149d30a476187250b076f0b53ffc19c520 100644 (file)
@@ -16,8 +16,8 @@
 \r
 #include "BaseLibInternals.h"\r
 \r
-#define SPIN_LOCK_RELEASED          ((SPIN_LOCK)1)\r
-#define SPIN_LOCK_ACQUIRED          ((SPIN_LOCK)2)\r
+#define SPIN_LOCK_RELEASED          ((UINTN) 1)\r
+#define SPIN_LOCK_ACQUIRED          ((UINTN) 2)\r
 \r
 /**\r
   Retrieves the architecture specific spin lock alignment requirements for\r
@@ -151,7 +151,7 @@ AcquireSpinLockOrFail (
   IN OUT  SPIN_LOCK                 *SpinLock\r
   )\r
 {\r
-  volatile SPIN_LOCK    LockValue;\r
+  SPIN_LOCK    LockValue;\r
 \r
   ASSERT (SpinLock != NULL);\r
 \r
@@ -187,7 +187,7 @@ ReleaseSpinLock (
   IN OUT  SPIN_LOCK                 *SpinLock\r
   )\r
 {\r
-  volatile SPIN_LOCK    LockValue;\r
+  SPIN_LOCK    LockValue;\r
 \r
   ASSERT (SpinLock != NULL);\r
 \r