summaryrefslogtreecommitdiff
path: root/network/wlan/WDI/COMMON/pool.h
diff options
context:
space:
mode:
authorAdam Shapiro <[email protected]>2016-02-04 13:02:45 -0800
committerAdam Shapiro <[email protected]>2016-02-04 13:02:45 -0800
commit3c8ac8624f815e66b370ef412bbf13cbd2c732e2 (patch)
tree9e1e9654be00272763677a6fe6891f7cb5fb4995 /network/wlan/WDI/COMMON/pool.h
parent921231effe018f3939f5b67fc7e44560aa6f3998 (diff)
WDI Sample
Adding WDI sample from partner enablement-China
Diffstat (limited to 'network/wlan/WDI/COMMON/pool.h')
-rw-r--r--network/wlan/WDI/COMMON/pool.h64
1 files changed, 64 insertions, 0 deletions
diff --git a/network/wlan/WDI/COMMON/pool.h b/network/wlan/WDI/COMMON/pool.h
new file mode 100644
index 00000000..9c61df6d
--- /dev/null
+++ b/network/wlan/WDI/COMMON/pool.h
@@ -0,0 +1,64 @@
+//---------------------------------------------------------------------------
+//
+// Copyright (c) 2014 Realtek Semiconductor, Inc. All rights reserved.
+//
+//---------------------------------------------------------------------------
+// Description:
+//
+//
+
+#ifndef __INC_POOL_H
+#define __INC_POOL_H
+
+
+//-----------------------------------------------------------------------------
+// Data
+//-----------------------------------------------------------------------------
+typedef struct _POOL
+{
+ const char *sig;
+ const char *name;
+ const u1Byte *start;
+ const u1Byte *end;
+ u4Byte entrySize;
+ RT_LIST_ENTRY freeList;
+ u4Byte freeCount;
+ u4Byte cap;
+ u4Byte lowMark;
+
+ u8Byte dbgComp;
+ u4Byte dbgLevel;
+}POOL;
+
+//-----------------------------------------------------------------------------
+// Function
+//-----------------------------------------------------------------------------
+
+VOID
+Pool_Init(
+ IN POOL *pool,
+ IN char *name,
+ IN u4Byte buflen,
+ IN VOID *buf,
+ IN u4Byte entrySize,
+ IN u8Byte dbgComp,
+ IN u4Byte dbgLevel
+ );
+
+VOID *
+Pool_Acquire(
+ IN POOL *pool
+ );
+
+VOID
+Pool_Release(
+ IN POOL *pool,
+ IN VOID *entry
+ );
+
+VOID
+Pool_Dump(
+ IN const POOL *pool
+ );
+
+#endif // #ifndef __INC_POOL_H \ No newline at end of file