Chris Wulff : hal: Added stubs for KfAquireSpinLock, KfReleaseSpinLock, KfLowerIrql, KfRaiseIrql.
Alexandre Julliard
julliard at winehq.org
Wed Oct 31 08:35:34 CDT 2007
Module: wine
Branch: master
Commit: d230fd611946b6c1c735a6751cd75b27ba768d19
URL: http://source.winehq.org/git/wine.git/?a=commit;h=d230fd611946b6c1c735a6751cd75b27ba768d19
Author: Chris Wulff <crwulff at rochester.rr.com>
Date: Tue Oct 30 20:02:00 2007 -0400
hal: Added stubs for KfAquireSpinLock, KfReleaseSpinLock, KfLowerIrql, KfRaiseIrql.
---
dlls/hal/Makefile.in | 3 +
dlls/hal/hal.c | 101 ++++++++++++++++++++++++++++++++++++++++++++++++++
dlls/hal/hal.spec | 8 ++--
3 files changed, 108 insertions(+), 4 deletions(-)
diff --git a/dlls/hal/Makefile.in b/dlls/hal/Makefile.in
index b382cff..4f3cf1c 100644
--- a/dlls/hal/Makefile.in
+++ b/dlls/hal/Makefile.in
@@ -5,6 +5,9 @@ VPATH = @srcdir@
MODULE = hal.dll
IMPORTS = kernel32 ntdll
+C_SRCS = \
+ hal.c
+
@MAKE_DLL_RULES@
@DEPENDENCIES@ # everything below this line is overwritten by make depend
diff --git a/dlls/hal/hal.c b/dlls/hal/hal.c
new file mode 100644
index 0000000..10c695b
--- /dev/null
+++ b/dlls/hal/hal.c
@@ -0,0 +1,101 @@
+/*
+ * hal.dll implementation
+ *
+ * Copyright (C) 2007 Chris Wulff
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#include "config.h"
+#include "wine/port.h"
+
+#include <stdarg.h>
+
+#define NONAMELESSUNION
+#define NONAMELESSSTRUCT
+
+#include "ntstatus.h"
+#define WIN32_NO_STATUS
+#include "windef.h"
+#include "winternl.h"
+#include "excpt.h"
+#include "ddk/wdm.h"
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(ntoskrnl);
+
+#ifdef __i386__
+#define DEFINE_FASTCALL1_ENTRYPOINT( name ) \
+ __ASM_GLOBAL_FUNC( name, \
+ "popl %eax\n\t" \
+ "pushl %ecx\n\t" \
+ "pushl %eax\n\t" \
+ "jmp " __ASM_NAME("__regs_") #name )
+#define DEFINE_FASTCALL2_ENTRYPOINT( name ) \
+ __ASM_GLOBAL_FUNC( name, \
+ "popl %eax\n\t" \
+ "pushl %edx\n\t" \
+ "pushl %ecx\n\t" \
+ "pushl %eax\n\t" \
+ "jmp " __ASM_NAME("__regs_") #name )
+#endif
+
+
+#ifdef DEFINE_FASTCALL1_ENTRYPOINT
+DEFINE_FASTCALL1_ENTRYPOINT( KfAcquireSpinLock )
+KIRQL WINAPI __regs_KfAcquireSpinLock(PKSPIN_LOCK SpinLock)
+#else
+KIRQL WINAPI KfAcquireSpinLock(PKSPIN_LOCK SpinLock)
+#endif
+{
+ FIXME( "(%p) stub!\n", SpinLock );
+
+ return (KIRQL)0;
+}
+
+
+#ifdef DEFINE_FASTCALL1_ENTRYPOINT
+DEFINE_FASTCALL1_ENTRYPOINT( KfLowerIrql )
+VOID WINAPI __regs_KfLowerIrql(KIRQL NewIrql)
+#else
+VOID WINAPI KfLowerIrql(KIRQL NewIrql)
+#endif
+{
+ FIXME( "(%u) stub!\n", NewIrql );
+}
+
+
+#ifdef DEFINE_FASTCALL1_ENTRYPOINT
+DEFINE_FASTCALL1_ENTRYPOINT( KfRaiseIrql )
+KIRQL WINAPI __regs_KfRaiseIrql(KIRQL NewIrql)
+#else
+KIRQL WINAPI KfRaiseIrql(KIRQL NewIrql)
+#endif
+{
+ FIXME( "(%u) stub!\n", NewIrql );
+
+ return (KIRQL)0;
+}
+
+
+#ifdef DEFINE_FASTCALL2_ENTRYPOINT
+DEFINE_FASTCALL2_ENTRYPOINT( KfReleaseSpinLock )
+VOID WINAPI __regs_KfReleaseSpinLock(PKSPIN_LOCK SpinLock, KIRQL NewIrql)
+#else
+VOID WINAPI KfReleaseSpinLock(PKSPIN_LOCK SpinLock, KIRQL NewIrql)
+#endif
+{
+ FIXME( "(%p %u) stub!\n", SpinLock, NewIrql );
+}
diff --git a/dlls/hal/hal.spec b/dlls/hal/hal.spec
index 5c5fc5f..298dc8e 100644
--- a/dlls/hal/hal.spec
+++ b/dlls/hal/hal.spec
@@ -13,10 +13,10 @@
@ stub KeReleaseQueuedSpinLock
@ stub KeTryToAcquireQueuedSpinLock
@ stub KeTryToAcquireQueuedSpinLockRaiseToSynch
-@ stub KfAcquireSpinLock
-@ stub KfLowerIrql
-@ stub KfRaiseIrql
-@ stub KfReleaseSpinLock
+@ stdcall -norelay KfAcquireSpinLock(ptr)
+@ stdcall -norelay KfLowerIrql(long)
+@ stdcall -norelay KfRaiseIrql()
+@ stdcall -norelay KfReleaseSpinLock(ptr long)
@ stub HalAcquireDisplayOwnership
@ stub HalAdjustResourceList
@ stub HalAllProcessorsStarted
More information about the wine-cvs
mailing list