mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
[ACPICA] Fix MSVC x64 build
See CORE-16082
This commit is contained in:
parent
6997a7a36f
commit
ad60726288
3 changed files with 44 additions and 3 deletions
|
@ -149,7 +149,7 @@
|
|||
#endif
|
||||
|
||||
#ifdef __REACTOS__
|
||||
|
||||
#ifdef _M_IX86
|
||||
/* Flush CPU cache - used when going to sleep. Wbinvd or similar. */
|
||||
|
||||
#ifdef ACPI_APPLICATION
|
||||
|
@ -208,7 +208,7 @@
|
|||
__asm exit_rel: \
|
||||
__asm mov Pnd, al \
|
||||
}
|
||||
|
||||
#endif /* _M_IX86 */
|
||||
#endif /* __REACTOS__ */
|
||||
|
||||
/* warn C4100: unreferenced formal parameter */
|
||||
|
|
|
@ -83,6 +83,7 @@
|
|||
|
||||
/*! [Begin] no source code translation */
|
||||
|
||||
#ifndef __REACTOS__
|
||||
#define ACPI_FLUSH_CPU_CACHE()
|
||||
|
||||
/*
|
||||
|
@ -99,6 +100,46 @@
|
|||
|
||||
#endif
|
||||
|
||||
#else /* __REACTOS__ */
|
||||
|
||||
#ifdef ACPI_APPLICATION
|
||||
#define ACPI_FLUSH_CPU_CACHE()
|
||||
#else
|
||||
#define ACPI_FLUSH_CPU_CACHE() __wbinvd()
|
||||
#endif
|
||||
|
||||
#define ACPI_ACQUIRE_GLOBAL_LOCK(FacsPtr, Acq) \
|
||||
{ \
|
||||
BOOLEAN acquired = 0xFF; \
|
||||
\
|
||||
if ((FacsPtr) != 0) \
|
||||
{ \
|
||||
UINT32 compare, prev, newval; \
|
||||
UINT32* lock = &((FacsPtr)->GlobalLock); \
|
||||
do \
|
||||
{ \
|
||||
compare = *lock; \
|
||||
newval = (compare & ~1) | ((compare >> 1) & 1) | 2; \
|
||||
prev = InterlockedCompareExchange(lock, newval, compare); \
|
||||
} while (prev != compare); \
|
||||
acquired = ((newval & 0xFF) < 3) ? 0xFF : 0x00; \
|
||||
} \
|
||||
(Acq) = acquired; \
|
||||
}
|
||||
|
||||
#define ACPI_RELEASE_GLOBAL_LOCK(FacsPtr, Pnd) \
|
||||
{ \
|
||||
BOOLEAN pending = 0; \
|
||||
\
|
||||
if ((FacsPtr) != 0) \
|
||||
{ \
|
||||
pending = InterlockedAnd(&(FacsPtr)->GlobalLock, ~3) & 1; \
|
||||
} \
|
||||
(Pnd) = pending; \
|
||||
}
|
||||
|
||||
#endif /* __REACTOS__ */
|
||||
|
||||
/*! [End] no source code translation !*/
|
||||
|
||||
#endif /* __ACWIN_H__ */
|
||||
|
|
|
@ -434,7 +434,7 @@ AcpiNsBuildPrefixedPathname (
|
|||
char *FullPath = NULL;
|
||||
char *ExternalPath = NULL;
|
||||
char *PrefixPath = NULL;
|
||||
UINT32 PrefixPathLength = 0;
|
||||
SIZE_T PrefixPathLength = 0;
|
||||
|
||||
|
||||
/* If there is a prefix, get the pathname to it */
|
||||
|
|
Loading…
Reference in a new issue