1 diff -ruN acpica-unix-20180810/source/include/platform/acaros.h acpica-unix-20180810.aros/source/include/platform/acaros.h
2 --- acpica-unix-20180810/source/include/platform/acaros.h 1970-01-01 01:00:00.000000000 +0100
3 +++ acpica-unix-20180810.aros/source/include/platform/acaros.h 2018-09-19 00:27:31.596804800 +0100
5 +/******************************************************************************
7 + * Name: acaros.h - OS specific defines, etc. for AROS
9 + *****************************************************************************/
14 +#if defined(__i386__) || defined(__x86_64__)
15 +#define ACPI_DIV_64_BY_32(n_hi, n_lo, d32, q32, r32) \
22 + : "=r" (q32), "=r" (r32) \
23 + : "r" (n_hi), "r" (n_lo), "r" (d32) \
26 +#define ACPI_SHIFT_RIGHT_64(n_hi, n_lo) \
30 + : "=r" (n_hi), "=r" (n_lo) \
31 + : "0" (n_hi), "1" (n_lo) \
35 +/* Common (in-kernel/user-space) ACPICA configuration */
37 +#ifndef ACPI_USE_SYSTEM_CLIBRARY
38 +#define ACPI_USE_SYSTEM_CLIBRARY
40 +#define ACPI_USE_STANDARD_HEADERS
41 +#define ACPI_MUTEX_TYPE ACPI_BINARY_SEMAPHORE
42 +#define ACPI_USE_LOCAL_CACHE
44 +/* Use native AROS version of AcpiOsAllocateZeroed */
45 +#define USE_NATIVE_ALLOCATE_ZEROED
48 + * Calling conventions:
50 + * ACPI_SYSTEM_XFACE - Interfaces to host OS (handlers, threads)
51 + * ACPI_EXTERNAL_XFACE - External ACPI interfaces
52 + * ACPI_INTERNAL_XFACE - Internal ACPI interfaces
53 + * ACPI_INTERNAL_VAR_XFACE - Internal variable-parameter list interfaces
55 +#define ACPI_SYSTEM_XFACE
56 +#define ACPI_EXTERNAL_XFACE
57 +#define ACPI_INTERNAL_XFACE
58 +#define ACPI_INTERNAL_VAR_XFACE
61 +#include <proto/exec.h>
63 +/* Host-dependent types and defines for AROS ACPICA */
65 +#if defined(__x86_64__)
66 +#define ACPI_MACHINE_WIDTH 64
67 +#elif defined(__i386__)
68 +#define ACPI_MACHINE_WIDTH 32
70 +#error Unsupported hardware architecture!
77 +#define ACPI_FLUSH_CPU_CACHE() CacheClearU()
78 +#define ACPI_ACQUIRE_GLOBAL_LOCK(facs,acq) \
79 + { ACPI_TABLE_FACS *_facs = facs; \
80 + BOOLEAN ok = FALSE; \
81 + Disable(); if (_facs->GlobalLock == 0) { _facs->GlobalLock=1; ok = TRUE; } Enable(); \
83 +#define ACPI_RELEASE_GLOBAL_LOCK(facs,pend) \
84 + { ACPI_TABLE_FACS *_facs = facs; \
85 + BOOLEAN ok = FALSE; \
86 + Disable(); if (_facs->GlobalLock == 1) { _facs->GlobalLock=0; ok = TRUE; } Enable(); \
89 +#include <libraries/acpica.h>
91 +#endif /* __ACAROS_H__ */
92 diff -ruN acpica-unix-20180810/source/include/platform/acenv.h acpica-unix-20180810.aros/source/include/platform/acenv.h
93 --- acpica-unix-20180810/source/include/platform/acenv.h 2018-08-10 16:49:24.000000000 +0100
94 +++ acpica-unix-20180810.aros/source/include/platform/acenv.h 2018-09-18 22:37:03.805227836 +0100
96 #elif defined(__QNX__)
99 +#elif defined(__AROS__)
103 * EFI applications can be built with -nostdlib, in this case, it must be
104 * included after including all other host environmental definitions, in