Move GUID comparison macro to wdm.h
authorAmine Khaldi <amine.khaldi@reactos.org>
Sat, 27 Feb 2010 15:09:59 +0000 (15:09 +0000)
committerAmine Khaldi <amine.khaldi@reactos.org>
Sat, 27 Feb 2010 15:09:59 +0000 (15:09 +0000)
svn path=/branches/header-work/; revision=45700

include/ddk/wdm.h
include/ddk/winddk.h

index 4517979..3db6a24 100644 (file)
@@ -71,6 +71,22 @@ extern "C" {
 #define ALIGN_UP_POINTER(p, t) \
     (ALIGN_DOWN_POINTER(((ULONG_PTR)(p) + sizeof(t) - 1), t))
 
 #define ALIGN_UP_POINTER(p, t) \
     (ALIGN_DOWN_POINTER(((ULONG_PTR)(p) + sizeof(t) - 1), t))
 
+/*
+ * GUID Comparison
+ */
+
+#ifndef __IID_ALIGNED__
+    #define __IID_ALIGNED__
+    #ifdef __cplusplus
+        inline int IsEqualGUIDAligned(REFGUID guid1, REFGUID guid2)
+        {
+            return ((*(PLONGLONG)(&guid1) == *(PLONGLONG)(&guid2)) && (*((PLONGLONG)(&guid1) + 1) == *((PLONGLONG)(&guid2) + 1)));
+        }
+    #else
+        #define IsEqualGUIDAligned(guid1, guid2) \
+            ((*(PLONGLONG)(guid1) == *(PLONGLONG)(guid2)) && (*((PLONGLONG)(guid1) + 1) == *((PLONGLONG)(guid2) + 1)))
+    #endif 
+#endif
 
 /* Simple types */
 typedef UCHAR KPROCESSOR_MODE;
 
 /* Simple types */
 typedef UCHAR KPROCESSOR_MODE;
index 094efc9..27bc4f1 100644 (file)
@@ -74,23 +74,6 @@ extern "C" {
 # define _DDK_DUMMYUNION_N_MEMBER(n, name) name
 #endif
 
 # define _DDK_DUMMYUNION_N_MEMBER(n, name) name
 #endif
 
-/*
- * GUID Comparison
- */
-
-#ifndef __IID_ALIGNED__
-    #define __IID_ALIGNED__
-    #ifdef __cplusplus
-        inline int IsEqualGUIDAligned(REFGUID guid1, REFGUID guid2)
-        {
-            return ((*(PLONGLONG)(&guid1) == *(PLONGLONG)(&guid2)) && (*((PLONGLONG)(&guid1) + 1) == *((PLONGLONG)(&guid2) + 1)));
-        }
-    #else
-        #define IsEqualGUIDAligned(guid1, guid2) \
-            ((*(PLONGLONG)(guid1) == *(PLONGLONG)(guid2)) && (*((PLONGLONG)(guid1) + 1) == *((PLONGLONG)(guid2) + 1)))
-    #endif 
-#endif
-
 /*
 ** Forward declarations
 */
 /*
 ** Forward declarations
 */