diff options
author | Sorin Vinturis <svinturis@cloudbasesolutions.com> | 2015-03-26 19:59:36 +0000 |
---|---|---|
committer | Ben Pfaff <blp@nicira.com> | 2015-03-26 14:18:44 -0700 |
commit | 48b3e646d13f96d7d4d256966ae56910a557ed19 (patch) | |
tree | 0e7f5db3069327b2b77724045ec9957cb880aa65 /datapath-windows | |
parent | 5bf619159c26044b5643a50ec83aaa7de5b52aef (diff) | |
download | openvswitch-48b3e646d13f96d7d4d256966ae56910a557ed19.tar.gz |
datapath-windows: Added specific pool tag for buffermgmt code
All MDL memory allocations within buffermgmt code have 'BSVO' pool
tag.
Signed-off-by: Sorin Vinturis <svinturis@cloudbasesolutions.com>
Reported-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Reported-at: https://github.com/openvswitch/ovs-issues/issues/56
Acked-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Acked-by: Eitan Eliahu <eliahue@vmware.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'datapath-windows')
-rw-r--r-- | datapath-windows/ovsext/BufferMgmt.c | 6 | ||||
-rw-r--r-- | datapath-windows/ovsext/Util.h | 1 |
2 files changed, 4 insertions, 3 deletions
diff --git a/datapath-windows/ovsext/BufferMgmt.c b/datapath-windows/ovsext/BufferMgmt.c index e0377c13a..572b2988a 100644 --- a/datapath-windows/ovsext/BufferMgmt.c +++ b/datapath-windows/ovsext/BufferMgmt.c @@ -433,14 +433,14 @@ OvsAllocateMDLAndData(NDIS_HANDLE ndisHandle, PMDL mdl; PVOID data; - data = OvsAllocateMemory(dataSize); + data = OvsAllocateMemoryWithTag(dataSize, OVS_MDL_POOL_TAG); if (data == NULL) { return NULL; } mdl = NdisAllocateMdl(ndisHandle, data, dataSize); if (mdl == NULL) { - OvsFreeMemory(data); + OvsFreeMemoryWithTag(data, OVS_MDL_POOL_TAG); } return mdl; @@ -454,7 +454,7 @@ OvsFreeMDLAndData(PMDL mdl) data = MmGetMdlVirtualAddress(mdl); NdisFreeMdl(mdl); - OvsFreeMemory(data); + OvsFreeMemoryWithTag(data, OVS_MDL_POOL_TAG); } diff --git a/datapath-windows/ovsext/Util.h b/datapath-windows/ovsext/Util.h index 0f326545b..6a9c16994 100644 --- a/datapath-windows/ovsext/Util.h +++ b/datapath-windows/ovsext/Util.h @@ -23,6 +23,7 @@ #define OVS_NBL_ONLY_POOL_TAG 'OSVO' #define OVS_NET_BUFFER_POOL_TAG 'NSVO' #define OVS_OTHER_POOL_TAG 'MSVO' +#define OVS_MDL_POOL_TAG 'BSVO' #define OVS_DATAPATH_POOL_TAG 'DSVO' VOID *OvsAllocateMemory(size_t size); |