kernel32/nls: Added LOCALE_SNAN entries.
[wine.git] / dlls / hal / hal.c
blobddd87102d78b0ddce584542acb6607f5e2d40315
1 /*
2 * hal.dll implementation
4 * Copyright (C) 2007 Chris Wulff
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 #include "config.h"
22 #include "wine/port.h"
24 #include <stdarg.h>
26 #include "ntstatus.h"
27 #define WIN32_NO_STATUS
28 #include "windef.h"
29 #include "winternl.h"
30 #include "excpt.h"
31 #include "ddk/ntddk.h"
32 #include "wine/debug.h"
34 WINE_DEFAULT_DEBUG_CHANNEL(ntoskrnl);
36 #ifdef __i386__
37 #define DEFINE_FASTCALL1_ENTRYPOINT( name ) \
38 __ASM_STDCALL_FUNC( name, 4, \
39 "popl %eax\n\t" \
40 "pushl %ecx\n\t" \
41 "pushl %eax\n\t" \
42 "jmp " __ASM_NAME("__regs_") #name __ASM_STDCALL(4))
43 #define DEFINE_FASTCALL2_ENTRYPOINT( name ) \
44 __ASM_STDCALL_FUNC( name, 8, \
45 "popl %eax\n\t" \
46 "pushl %edx\n\t" \
47 "pushl %ecx\n\t" \
48 "pushl %eax\n\t" \
49 "jmp " __ASM_NAME("__regs_") #name __ASM_STDCALL(8))
50 #endif
53 #ifdef DEFINE_FASTCALL1_ENTRYPOINT
54 DEFINE_FASTCALL1_ENTRYPOINT( ExAcquireFastMutex )
55 VOID WINAPI DECLSPEC_HIDDEN __regs_ExAcquireFastMutex(PFAST_MUTEX FastMutex)
56 #else
57 VOID WINAPI ExAcquireFastMutex(PFAST_MUTEX FastMutex)
58 #endif
60 FIXME("%p: stub\n", FastMutex);
63 #ifdef DEFINE_FASTCALL1_ENTRYPOINT
64 DEFINE_FASTCALL1_ENTRYPOINT( ExReleaseFastMutex )
65 VOID WINAPI DECLSPEC_HIDDEN __regs_ExReleaseFastMutex(PFAST_MUTEX FastMutex)
66 #else
67 VOID WINAPI ExReleaseFastMutex(PFAST_MUTEX FastMutex)
68 #endif
70 FIXME("%p: stub\n", FastMutex);
73 #ifdef DEFINE_FASTCALL1_ENTRYPOINT
74 DEFINE_FASTCALL1_ENTRYPOINT( ExTryToAcquireFastMutex )
75 BOOLEAN WINAPI DECLSPEC_HIDDEN __regs_ExTryToAcquireFastMutex(PFAST_MUTEX FastMutex)
76 #else
77 BOOLEAN WINAPI ExTryToAcquireFastMutex(PFAST_MUTEX FastMutex)
78 #endif
80 FIXME("(%p) stub\n", FastMutex);
81 return TRUE;
84 #ifdef DEFINE_FASTCALL1_ENTRYPOINT
85 DEFINE_FASTCALL1_ENTRYPOINT( KfAcquireSpinLock )
86 KIRQL WINAPI DECLSPEC_HIDDEN __regs_KfAcquireSpinLock(PKSPIN_LOCK SpinLock)
87 #else
88 KIRQL WINAPI KfAcquireSpinLock(PKSPIN_LOCK SpinLock)
89 #endif
91 FIXME( "(%p) stub!\n", SpinLock );
93 return 0;
97 #ifdef DEFINE_FASTCALL1_ENTRYPOINT
98 DEFINE_FASTCALL1_ENTRYPOINT( KfLowerIrql )
99 VOID WINAPI DECLSPEC_HIDDEN __regs_KfLowerIrql(KIRQL NewIrql)
100 #else
101 VOID WINAPI KfLowerIrql(KIRQL NewIrql)
102 #endif
104 FIXME( "(%u) stub!\n", NewIrql );
108 #ifdef DEFINE_FASTCALL1_ENTRYPOINT
109 DEFINE_FASTCALL1_ENTRYPOINT( KfRaiseIrql )
110 KIRQL WINAPI DECLSPEC_HIDDEN __regs_KfRaiseIrql(KIRQL NewIrql)
111 #else
112 KIRQL WINAPI KfRaiseIrql(KIRQL NewIrql)
113 #endif
115 FIXME( "(%u) stub!\n", NewIrql );
117 return 0;
121 #ifdef DEFINE_FASTCALL2_ENTRYPOINT
122 DEFINE_FASTCALL2_ENTRYPOINT( KfReleaseSpinLock )
123 VOID WINAPI DECLSPEC_HIDDEN __regs_KfReleaseSpinLock(PKSPIN_LOCK SpinLock, KIRQL NewIrql)
124 #else
125 VOID WINAPI KfReleaseSpinLock(PKSPIN_LOCK SpinLock, KIRQL NewIrql)
126 #endif
128 FIXME( "(%p %u) stub!\n", SpinLock, NewIrql );
131 ULONG WINAPI HalGetBusData(BUS_DATA_TYPE BusDataType, ULONG BusNumber, ULONG SlotNumber, PVOID Buffer, ULONG Length)
133 FIXME("(%u %u %u %p %u) stub!\n", BusDataType, BusNumber, SlotNumber, Buffer, Length);
134 /* Claim that there is no such bus */
135 return 0;
138 ULONG WINAPI HalGetBusDataByOffset(BUS_DATA_TYPE BusDataType, ULONG BusNumber, ULONG SlotNumber, PVOID Buffer, ULONG Offset, ULONG Length)
140 FIXME("(%u %u %u %p %u %u) stub!\n", BusDataType, BusNumber, SlotNumber, Buffer, Offset, Length);
141 /* Claim that there is no such bus */
142 return 0;
145 BOOLEAN WINAPI HalTranslateBusAddress(INTERFACE_TYPE InterfaceType, ULONG BusNumber, PHYSICAL_ADDRESS BusAddress,
146 PULONG AddressSpace, PPHYSICAL_ADDRESS TranslatedAddress)
148 FIXME("(%d %d %s %p %p) stub!\n", InterfaceType, BusNumber,
149 wine_dbgstr_longlong(BusAddress.QuadPart), AddressSpace, TranslatedAddress);
150 return FALSE;
153 KIRQL WINAPI KeGetCurrentIrql(VOID)
155 FIXME( " stub!\n");
156 return 0;
159 UCHAR WINAPI READ_PORT_UCHAR(UCHAR *port)
161 FIXME("(%p) stub!\n", port);
162 return 0;
165 ULONG WINAPI READ_PORT_ULONG(ULONG *port)
167 FIXME("(%p) stub!\n", port);
168 return 0;
171 void WINAPI WRITE_PORT_UCHAR(UCHAR *port, UCHAR value)
173 FIXME("(%p %d) stub!\n", port, value);
176 void WINAPI WRITE_PORT_ULONG(ULONG *port, ULONG value)
178 FIXME("(%p %d) stub!\n", port, value);