diff options
author | wpaul <wpaul@FreeBSD.org> | 2005-02-16 18:18:30 +0000 |
---|---|---|
committer | wpaul <wpaul@FreeBSD.org> | 2005-02-16 18:18:30 +0000 |
commit | a372ba85cee8186936a67b01506b82c45df2adfe (patch) | |
tree | 7bd47a7b0e507dddb01a8e51c992241ccf0928f5 /sys/compat/ndis/subr_ntoskrnl.c | |
parent | 7662ea78966911e735feef0771a6c56dff7c55ef (diff) | |
download | FreeBSD-src-a372ba85cee8186936a67b01506b82c45df2adfe.zip FreeBSD-src-a372ba85cee8186936a67b01506b82c45df2adfe.tar.gz |
KeAcquireSpinLockRaiseToDpc() and KeReleaseSpinLock() are (at least
for now) exactly the same as KfAcquireSpinLock() and KfReleaseSpinLock().
I implemented the former as small routines in subr_ntoskrnl.c that just
turned around and invoked the latter. But I don't really need the wrapper
routines: I can just create an entries in the ntoskrnl func table that
map KeAcquireSpinLockRaiseToDpc() and KeReleaseSpinLock() to
KfAcquireSpinLock() and KfReleaseSpinLock() directly. This means
the stubs can go away.
Diffstat (limited to 'sys/compat/ndis/subr_ntoskrnl.c')
-rw-r--r-- | sys/compat/ndis/subr_ntoskrnl.c | 27 |
1 files changed, 3 insertions, 24 deletions
diff --git a/sys/compat/ndis/subr_ntoskrnl.c b/sys/compat/ndis/subr_ntoskrnl.c index 5558705..eb7f5ba 100644 --- a/sys/compat/ndis/subr_ntoskrnl.c +++ b/sys/compat/ndis/subr_ntoskrnl.c @@ -1498,27 +1498,6 @@ KefReleaseSpinLockFromDpcLevel(REGARGS1(kspin_lock *lock)) return; } -__stdcall uint8_t -KeAcquireSpinLockRaiseToDpc(lock) - kspin_lock *lock; -{ - uint8_t oldirql; - - oldirql = FASTCALL1(KfAcquireSpinLock, lock); - return(oldirql); -} - -#ifndef __i386__ -__stdcall void -KeReleaseSpinLock(lock, irql) - kspin_lock *lock; - uint8_t irql; -{ - FASTCALL2(KfReleaseSpinLock, lock, irql); - return; -} -#endif - __fastcall static uint32_t InterlockedIncrement(REGARGS1(volatile uint32_t *addend)) { @@ -2392,7 +2371,7 @@ image_patch_table ntoskrnl_functbl[] = { IMPORT_FUNC(strlen), IMPORT_FUNC(memcpy), IMPORT_FUNC_MAP(memmove, ntoskrnl_memset), - IMPORT_FUNC(ntoskrnl_memset), + IMPORT_FUNC_MAP(memset, ntoskrnl_memset), IMPORT_FUNC(IoAllocateDriverObjectExtension), IMPORT_FUNC(IoGetDriverObjectExtension), IMPORT_FUNC(IofCallDriver), @@ -2442,8 +2421,8 @@ image_patch_table ntoskrnl_functbl[] = { IMPORT_FUNC(ExInterlockedPushEntrySList), IMPORT_FUNC(KefAcquireSpinLockAtDpcLevel), IMPORT_FUNC(KefReleaseSpinLockFromDpcLevel), - IMPORT_FUNC(KeAcquireSpinLockRaiseToDpc), - IMPORT_FUNC(KeReleaseSpinLock), + IMPORT_FUNC_MAP(KeAcquireSpinLockRaiseToDpc, KfAcquireSpinLock), + IMPORT_FUNC_MAP(KeReleaseSpinLock, KfReleaseSpinLock), IMPORT_FUNC(InterlockedIncrement), IMPORT_FUNC(InterlockedDecrement), IMPORT_FUNC(ExInterlockedAddLargeStatistic), |