kernel/acpica: Separate kernel and userland code in headers better.
authorSascha Wildner <saw@online.de>
Thu, 18 Dec 2014 23:21:49 +0000 (00:21 +0100)
committerSascha Wildner <saw@online.de>
Thu, 18 Dec 2014 23:23:48 +0000 (00:23 +0100)
Clean up a bit, use standard types, etc.

sys/contrib/dev/acpica/source/include/platform/acdragonfly.h
sys/platform/pc32/include/acpica_machdep.h
sys/platform/pc64/include/acpica_machdep.h

index cc3903b..08c48a5 100644 (file)
 
 #include <platform/acgcc.h>    /* DragonFly uses GCC */
 #include <sys/types.h>
-#include <machine/acpica_machdep.h>
 
-#define ACPI_UINTPTR_T         uintptr_t
+#ifdef __LP64__
+#define        ACPI_MACHINE_WIDTH      64
+#else
+#define        ACPI_MACHINE_WIDTH      32
+#define        ACPI_USE_NATIVE_DIVIDE
+#endif
+
+#define        ACPI_UINTPTR_T                  uintptr_t
+#define        COMPILER_DEPENDENT_INT64        int64_t
+#define        COMPILER_DEPENDENT_UINT64       uint64_t
+
 #define ACPI_USE_DO_WHILE_0
 #define ACPI_USE_SYSTEM_CLIBRARY
 
 #include "opt_acpi.h"
 #include <sys/ctype.h>
 #include <sys/systm.h>
+#include <machine/acpica_machdep.h>
 #include <stdarg.h>
 
+#ifdef ACPI_DEBUG
+#define ACPI_DEBUG_OUTPUT      /* enable debug output */
 #ifdef DEBUGGER_THREADING
 #undef DEBUGGER_THREADING
 #endif /* DEBUGGER_THREADING */
-
-#define DEBUGGER_THREADING 0    /* integrated with DDB */
-
-#ifdef ACPI_DEBUG
-#define ACPI_DEBUG_OUTPUT      /* enable debug output */
+#define        DEBUGGER_THREADING DEBUGGER_SINGLE_THREADED /* integrated with DDB */
 #if 0                          /* XXX */
 #include "opt_ddb.h"
 #ifdef DDB
index e5953dc..8753b6c 100644 (file)
@@ -69,9 +69,4 @@ extern int    acpi_release_global_lock(uint32_t *lock);
 
 #endif /* _KERNEL */
 
-#define ACPI_MACHINE_WIDTH             32
-#define COMPILER_DEPENDENT_INT64       long long
-#define COMPILER_DEPENDENT_UINT64      unsigned long long
-#define ACPI_USE_NATIVE_DIVIDE
-
 #endif /* _MACHINE_ACPICA_MACHDEP_H__ */
index 3ade026..47883e2 100644 (file)
@@ -24,7 +24,6 @@
  * SUCH DAMAGE.
  *
  * $FreeBSD: src/sys/amd64/include/acpica_machdep.h,v 1.6 2004/10/11 05:39:15 njl Exp $
- * $DragonFly: src/sys/platform/pc64/include/acpica_machdep.h,v 1.1 2007/08/21 19:45:45 corecode Exp $
  */
 
 /******************************************************************************
@@ -70,8 +69,4 @@ extern int    acpi_release_global_lock(uint32_t *lock);
 
 #endif /* _KERNEL */
 
-#define ACPI_MACHINE_WIDTH             64
-#define COMPILER_DEPENDENT_INT64       long
-#define COMPILER_DEPENDENT_UINT64      unsigned long
-
 #endif /* _MACHINE_ACPICA_MACHDEP_H__ */