- fix the release build for Colin.
authorGed Murphy <gedmurphy@reactos.org>
Mon, 21 May 2007 23:12:16 +0000 (23:12 +0000)
committerGed Murphy <gedmurphy@reactos.org>
Mon, 21 May 2007 23:12:16 +0000 (23:12 +0000)
- clean up formatting of a file I was playing with.

svn path=/trunk/; revision=26861

reactos/boot/freeldr/freeldr/arch/i386/hwacpi.c
reactos/boot/freeldr/freeldr/include/debug.h

index 5140326..36e7b77 100644 (file)
@@ -19,8 +19,6 @@
  */
 
 #include <freeldr.h>
-
-#define NDEBUG
 #include <debug.h>
 
 BOOLEAN AcpiPresent = FALSE;
@@ -28,49 +26,49 @@ BOOLEAN AcpiPresent = FALSE;
 static BOOLEAN
 FindAcpiBios(VOID)
 {
-  PUCHAR Ptr;
+    PUCHAR Ptr;
 
-  /* Find the 'Root System Descriptor Table Pointer' */
-  Ptr = (PUCHAR)0xE0000;
-  while ((ULONG)Ptr < 0x100000)
+    /* Find the 'Root System Descriptor Table Pointer' */
+    Ptr = (PUCHAR)0xE0000;
+    while ((ULONG)Ptr < 0x100000)
     {
-      if (!memcmp(Ptr, "RSD PTR ", 8))
-       {
-         DbgPrint((DPRINT_HWDETECT, "ACPI supported\n"));
+        if (!memcmp(Ptr, "RSD PTR ", 8))
+        {
+            DbgPrint((DPRINT_HWDETECT, "ACPI supported\n"));
 
-         return TRUE;
-       }
+            return TRUE;
+        }
 
-      Ptr = (PUCHAR)((ULONG)Ptr + 0x10);
+        Ptr = (PUCHAR)((ULONG)Ptr + 0x10);
     }
 
-  DbgPrint((DPRINT_HWDETECT, "ACPI not supported\n"));
+    DbgPrint((DPRINT_HWDETECT, "ACPI not supported\n"));
 
-  return FALSE;
+    return FALSE;
 }
 
 
 VOID
 DetectAcpiBios(FRLDRHKEY SystemKey, ULONG *BusNumber)
 {
-  WCHAR Buffer[80];
-  FRLDRHKEY BiosKey;
-  LONG Error;
+    WCHAR Buffer[80];
+    FRLDRHKEY BiosKey;
+    LONG Error;
 
-  if (FindAcpiBios())
+    if (FindAcpiBios())
     {
-      AcpiPresent = TRUE;
-      /* Create new bus key */
-      swprintf(Buffer,
-             L"MultifunctionAdapter\\%u", *BusNumber);
-      Error = RegCreateKey(SystemKey,
-                          Buffer,
-                          &BiosKey);
-      if (Error != ERROR_SUCCESS)
-       {
-         DbgPrint((DPRINT_HWDETECT, "RegCreateKey() failed (Error %u)\n", (int)Error));
-         return;
-       }
+        AcpiPresent = TRUE;
+        /* Create new bus key */
+        swprintf(Buffer,
+                 L"MultifunctionAdapter\\%u", *BusNumber);
+        Error = RegCreateKey(SystemKey,
+                             Buffer,
+                             &BiosKey);
+        if (Error != ERROR_SUCCESS)
+        {
+            DbgPrint((DPRINT_HWDETECT, "RegCreateKey() failed (Error %u)\n", (int)Error));
+            return;
+        }
 
 #if 0
       /* Set 'Component Information' */
@@ -80,20 +78,20 @@ DetectAcpiBios(FRLDRHKEY SystemKey, ULONG *BusNumber)
                               0xFFFFFFFF);
 #endif
 
-      /* Increment bus number */
-      (*BusNumber)++;
-
-      /* Set 'Identifier' value */
-      Error = RegSetValue(BiosKey,
-                         L"Identifier",
-                         REG_SZ,
-                         (PCHAR)L"ACPI BIOS",
-                         10 * sizeof(WCHAR));
-      if (Error != ERROR_SUCCESS)
-       {
-         DbgPrint((DPRINT_HWDETECT, "RegSetValue() failed (Error %u)\n", (int)Error));
-         return;
-       }
+        /* Increment bus number */
+        (*BusNumber)++;
+
+        /* Set 'Identifier' value */
+        Error = RegSetValue(BiosKey,
+                            L"Identifier",
+                            REG_SZ,
+                            (PCHAR)L"ACPI BIOS",
+                            10 * sizeof(WCHAR));
+        if (Error != ERROR_SUCCESS)
+        {
+            DbgPrint((DPRINT_HWDETECT, "RegSetValue() failed (Error %u)\n", (int)Error));
+            return;
+        }
 
     }
 }
index e43b9f7..a1b19be 100644 (file)
 #define DPRINT_HWDETECT                0x00000400  // OR this with DebugPrintMask to enable hardware detection messages
 #define DPRINT_WINDOWS         0x00000800  // OR this with DebugPrintMask to enable messages from Windows loader
 
+VOID   DebugPrint(ULONG Mask, char *format, ...);
+
 #ifdef DBG
 
        VOID    DebugInit(VOID);
-       VOID    DebugPrint(ULONG Mask, char *format, ...);
        VOID    DebugPrint1(char *format, ...);
        VOID    DebugDumpBuffer(ULONG Mask, PVOID Buffer, ULONG Length);
 
        #define DbgPrint(_x_)                                   DebugPrint _x_ ;
-       #define DPRINT1                                         DebugPrint1
+       #define DPRINT1                                                 DebugPrint1
        #define BugCheck(_x_)                                   { DebugPrint(DPRINT_WARNING, "Fatal Error: %s:%d(%s)\n", __FILE__, __LINE__, __FUNCTION__); DebugPrint _x_ ; for (;;); }
        #define DbgDumpBuffer(_x_, _y_, _z_)    DebugDumpBuffer(_x_, _y_, _z_)
 
@@ -77,7 +78,7 @@ void  MEMORY_WRITE_BREAKPOINT4(unsigned long addr);
 #else
 
        #define DebugInit()
-       #define DbgPrint(_x_) { if (0) DebugPrint _x_; }
+    #define DbgPrint(_x_) { if (0) DebugPrint _x_; }
        #define DPRINT1(_x_) { if (0) printf _x_; }
        #define BugCheck(_x_)
        #define DbgDumpBuffer(_x_, _y_, _z_)