23 31, 61, 127, 257, 521, 1031, 2053,
24 4099, 8191, 16381, 32749, 65537, 131071, 261983,
34#define WSH_SEARCH_TABLE_FROM_HANDLE(h, t) \
35 (&t->SearchTables[(((ULONG_PTR)h >> 2) & t->Mask)])
37#define WSH_HASH_FROM_HANDLE(h, hs) \
38 (hs->Handles[((ULONG_PTR)h % hs->Size)])
40#define AcquireWriteLock(t) \
41 EnterCriticalSection(&t->Lock);
43#define ReleaseWriteLock(t) \
44 LeaveCriticalSection(&t->Lock);
65 OldCount) == OldCount))
150 if (OldCount == &
Table->Count1)
167 if (
Table->SpinCount)
170 SpinCount =
Table->SpinCount;
171 while (*OldCount > 0)
174 if (--SpinCount <= 0)
break;
233 SearchTables[
i].Lock,
261 if (
Table->SearchTables[
i].HashTable)
294 SearchTable = &
Table->SearchTables[
i];
409 else if ((*HashHandle)->Handle ==
Handle->Handle)
412 OldHandle = *HashHandle;
446 Handles[HandleCount]));
#define InterlockedIncrement
#define InterlockedDecrement
struct HashTable * NewHashTable(void)
#define ERROR_INVALID_PARAMETER
#define HeapFree(x, y, z)
BOOL WINAPI WahEnumerateHandleContexts(IN PWAH_HANDLE_TABLE Table, IN PWAH_HANDLE_ENUMERATE_PROC Callback, IN PVOID Context)
VOID WINAPI DoWaitForReaders(IN PWAH_SEARCH_TABLE Table, IN PVLONG Counter)
static __inline VOID ReleaseReadLock(IN PWAH_SEARCH_TABLE Table, IN PVLONG Count)
#define WSH_HASH_FROM_HANDLE(h, hs)
CRITICAL_SECTION WshHandleTableLock
static __inline VOID TryWaitForReaders(IN PWAH_SEARCH_TABLE Table)
static __inline VOID AcquireReadLock(IN PWAH_SEARCH_TABLE Table, IN PVLONG *Count)
DWORD WINAPI WahCreateHandleContextTable(OUT PWAH_HANDLE_TABLE *Table)
DWORD WINAPI WahRemoveHandleContext(IN PWAH_HANDLE_TABLE Table, IN PWAH_HANDLE Handle)
PWAH_HANDLE WINAPI WahInsertHandleContext(IN PWAH_HANDLE_TABLE Table, IN PWAH_HANDLE Handle)
#define WSH_SEARCH_TABLE_FROM_HANDLE(h, t)
DWORD WINAPI WahDestroyHandleContextTable(IN PWAH_HANDLE_TABLE Table)
PWAH_HANDLE WINAPI WahReferenceContextByHandle(IN PWAH_HANDLE_TABLE Table, IN HANDLE Handle)
#define ReleaseWriteLock(t)
#define AcquireWriteLock(t)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
#define InterlockedCompareExchangePointer
#define InterlockedCompareExchange
_In_ NDIS_ERROR_CODE ErrorCode
WSH_SEARCH_TABLE SearchTables[1]
volatile PWAH_HASH_TABLE HashTable
volatile PLONG CurrentCount
static LARGE_INTEGER Counter
DWORD WINAPI WaitForSingleObject(IN HANDLE hHandle, IN DWORD dwMilliseconds)
VOID WINAPI DECLSPEC_HOTPATCH Sleep(IN DWORD dwMilliseconds)
BOOL WINAPI InitializeCriticalSectionAndSpinCount(OUT LPCRITICAL_SECTION lpCriticalSection, IN DWORD dwSpinCount)
BOOL WINAPI DECLSPEC_HOTPATCH PulseEvent(IN HANDLE hEvent)
#define FIELD_OFFSET(t, f)
#define RtlZeroMemory(Destination, Length)
_In_ WDFINTERRUPT _In_ PFN_WDF_INTERRUPT_SYNCHRONIZE Callback
BOOL WINAPI SwitchToThread(void)
void WINAPI DeleteCriticalSection(PCRITICAL_SECTION)
#define WSA_NOT_ENOUGH_MEMORY
BOOL(WINAPI * PWAH_HANDLE_ENUMERATE_PROC)(IN PVOID Context, IN PWAH_HANDLE Handle)
_Out_ PHANDLE EventHandle