DIRS=\\r
- complib \\r
+ complib \\r
al \\r
bus \\r
- iou\r
+ iou \\r
+ winverbs\r
--- /dev/null
+DIRS=\\r
+ user\r
--- /dev/null
+TARGETNAME=winverbs\r
+TARGETPATH=..\..\..\bin\kernel\obj$(BUILD_ALT_DIR)\r
+TARGETTYPE=DRIVER_LIBRARY\r
+\r
+!if $(FREEBUILD)\r
+ENABLE_EVENT_TRACING=1\r
+!else\r
+#ENABLE_EVENT_TRACING=1\r
+!endif\r
+\r
+DLLDEF=wv_exports.def\r
+\r
+SOURCES= winverbs.rc \\r
+ wv_provider.c\r
+\r
+INCLUDES=..;..\..\..\inc;..\..\..\inc\kernel;\r
+\r
+C_DEFINES=$(C_DEFINES) -DDRIVER -DDEPRECATE_DDK_FUNCTIONS \\r
+ -DEXPORT_WV_SYMBOLS\r
+\r
+!if !defined(DDK_TARGET_OS) || "$(DDK_TARGET_OS)"=="Win2K"\r
+#\r
+# The driver is built in the Win2K build environment\r
+# - use the library version of safe strings \r
+#\r
+TARGETLIBS= $(TARGETLIBS) $(DDK_LIB_PATH)\ntstrsafe.lib\r
+!endif\r
+\r
+!IFDEF ENABLE_EVENT_TRACING\r
+\r
+C_DEFINES = $(C_DEFINES) -DEVENT_TRACING\r
+\r
+RUN_WPP = $(SOURCES) -km -ext: .cpp .h\r
+!ENDIF\r
+\r
+MSC_WARNING_LEVEL= /W4\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+\r
+#include <oib_ver.h>\r
+\r
+#define VER_FILETYPE VFT_DRV\r
+#define VER_FILESUBTYPE VFT2_UNKNOWN\r
+\r
+#ifdef _DEBUG_\r
+#define VER_FILEDESCRIPTION_STR "Kernel WinVerbs (Debug)"\r
+#else\r
+#define VER_FILEDESCRIPTION_STR "Kernel WinVerbs"\r
+#endif\r
+\r
+#define VER_INTERNALNAME_STR "winverbs.sys"\r
+#define VER_ORIGINALFILENAME_STR "winverbs.sys"\r
+\r
+#include <common.ver>\r
--- /dev/null
+LIBRARY winverbs.sys\r
+\r
+EXPORTS\r
+; DllInitialize and DllUnload must be exported for the OS reference counting to\r
+; work, and must be private for the compiler to accept them.\r
+DllInitialize private\r
+DllUnload private\r
--- /dev/null
+!if $(FREEBUILD)\r
+TARGETNAME=winverbs\r
+!else\r
+TARGETNAME=winverbsd\r
+!endif\r
+\r
+TARGETPATH=..\..\..\bin\user\obj$(BUILD_ALT_DIR)\r
+TARGETTYPE=DYNLINK\r
+DLLENTRY=DllMain\r
+\r
+DLLDEF=$O\wv_exports.def\r
+USE_NTDLL=1\r
+\r
+SOURCES=\\r
+ winverbs.rc \\r
+ wv_main.cpp \\r
+ wv_cq.cpp \\r
+ wv_device.cpp \\r
+ wv_ep.cpp \\r
+ wv_listen.cpp \\r
+ wv_pd.cpp \\r
+ wv_provider.cpp \\r
+ wv_qp.cpp \\r
+ wv_srq.cpp\r
+\r
+INCLUDES=..\..\..\inc;..\..\..\inc\user;\r
+\r
+USER_C_FLAGS=$(USER_C_FLAGS) -DEXPORT_WV_SYMBOLS\r
+\r
+TARGETLIBS= \\r
+ $(SDK_LIB_PATH)\kernel32.lib \\r
+ $(SDK_LIB_PATH)\uuid.lib\r
+\r
+MSC_WARNING_LEVEL= /W4\r
--- /dev/null
+#\r
+# DO NOT EDIT THIS FILE!!! Edit .\sources. if you want to add a new source\r
+# file to this component. This file merely indirects to the real make file\r
+# that is shared by all the driver components of the OpenIB Windows project.\r
+#\r
+\r
+!INCLUDE ..\..\..\inc\openib.def\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+\r
+#include <oib_ver.h>\r
+\r
+#define VER_FILETYPE VFT_DLL\r
+#define VER_FILESUBTYPE VFT2_UNKNOWN\r
+\r
+#ifdef _DEBUG_\r
+#define VER_FILEDESCRIPTION_STR "WinVerbs (Debug)"\r
+#define VER_INTERNALNAME_STR "winverbsd.dll"\r
+#define VER_ORIGINALFILENAME_STR "winverbsd.dll"\r
+#else\r
+#define VER_FILEDESCRIPTION_STR "WinVerbs"\r
+#define VER_INTERNALNAME_STR "winverbs.dll"\r
+#define VER_ORIGINALFILENAME_STR "winverbs.dll"\r
+#endif\r
+\r
+#include <common.ver>\r
--- /dev/null
+#include "wv_provider.h"\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_BASE_H_\r
+#define _WV_BASE_H_\r
+\r
+#include "windows.h"\r
+//#include "iba\ib_types.h"\r
+\r
+__inline void* __cdecl operator new(size_t size)\r
+{\r
+ return HeapAlloc(GetProcessHeap(), 0, size);\r
+}\r
+\r
+__inline void __cdecl operator delete(void *pObj)\r
+{\r
+ HeapFree(GetProcessHeap(), 0, pObj);\r
+}\r
+\r
+//HRESULT ConvertIbalStatus(ib_api_status_t status);\r
+\r
+#endif // _WV_BASE_H_
\ No newline at end of file
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include "wv_base.h"\r
+#include "wv_cq.h"\r
+\r
+STDMETHODIMP CWVCompletionQueue::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVCompletionQueue::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVCompletionQueue::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVCompletionQueue::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVCompletionQueue::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVCompletionQueue::\r
+Resize(SIZE_T* pEntries)\r
+{\r
+ UNREFERENCED_PARAMETER(pEntries);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVCompletionQueue::\r
+Peek(SIZE_T* pCompletedEntries)\r
+{\r
+ UNREFERENCED_PARAMETER(pCompletedEntries);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVCompletionQueue::\r
+Notify(WV_CQ_NOTIFY_TYPE Type, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(Type);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVCompletionQueue::\r
+BatchNotify(SIZE_T CompletedEntries, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(CompletedEntries);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(SIZE_T) CWVCompletionQueue::\r
+Poll(WV_COMPLETION* pCompletions[], SIZE_T Entries)\r
+{\r
+ UNREFERENCED_PARAMETER(pCompletions);\r
+ UNREFERENCED_PARAMETER(Entries);\r
+\r
+ return 0;\r
+}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_CQ_H_\r
+#define _WV_CQ_H_\r
+\r
+#include "rdma\winverbs.h"\r
+\r
+class CWVCompletionQueue : IWVCompletionQueue\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVCompletionQueue methods\r
+ STDMETHODIMP Resize(SIZE_T* pEntries);\r
+ STDMETHODIMP Peek(SIZE_T* pCompletedEntries);\r
+ STDMETHODIMP Notify(WV_CQ_NOTIFY_TYPE Type, OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP BatchNotify(SIZE_T CompletedEntries, OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP_(SIZE_T) Poll(WV_COMPLETION* pCompletions[], SIZE_T Entries);\r
+};\r
+\r
+#endif //_WV_CQ_H_
\ No newline at end of file
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include "wv_base.h"\r
+#include "wv_device.h"\r
+\r
+STDMETHODIMP CIWVDevice::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CIWVDevice::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CIWVDevice::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+//static void\r
+//SetDeviceCap(DWORD *pFlags, ib_ca_attr_t *pCaAttr)\r
+//{\r
+// *pFlags = 0;\r
+//\r
+// *pFlags |= pCaAttr->bad_pkey_ctr_support ? WV_DEVICE_BAD_PKEY_COUNTER : 0;\r
+// *pFlags |= pCaAttr->bad_qkey_ctr_support ? WV_DEVICE_BAD_QKEY_COUNTER : 0;\r
+// *pFlags |= pCaAttr->apm_support ? WV_DEVICE_PATH_MIGRATION : 0;\r
+// *pFlags |= pCaAttr->av_port_check ? WV_DEVICE_AH_PORT_CHECKING : 0;\r
+// *pFlags |= pCaAttr->change_primary_port ? WV_DEVICE_CHANGE_PHYSICAL_PORT : 0;\r
+// *pFlags |= pCaAttr->modify_wr_depth ? WV_DEVICE_RESIZE_MAX_WR : 0;\r
+// *pFlags |= pCaAttr->modify_srq_depth ? WV_DEVICE_SRQ_RESIZE : 0;\r
+// *pFlags |= pCaAttr->current_qp_state_support ? WV_DEVICE_QP_STATE_MODIFIER : 0;\r
+// *pFlags |= pCaAttr->shutdown_port_capability ? WV_DEVICE_SHUTDOWN_PORT : 0;\r
+// *pFlags |= pCaAttr->init_type_support ? WV_DEVICE_INIT_TYPE : 0;\r
+// *pFlags |= pCaAttr->port_active_event_support ? WV_DEVICE_PORT_ACTIVE_EVENT : 0;\r
+// *pFlags |= pCaAttr->system_image_guid_support ? WV_DEVICE_SYSTEM_IMAGE_GUID : 0;\r
+// //WV_DEVICE_RC_RNR_NAK_GENERATION - not set\r
+// //WV_DEVICE_BATCH_NOTIFY_CQ - not set\r
+//}\r
+\r
+//static void\r
+//SetDevicePages(DWORD *pFlags, ib_ca_attr_t *pCaAttr)\r
+//{\r
+// unsigned int i;\r
+// UINT32 size;\r
+//\r
+// *pFlags = 0;\r
+//\r
+// for (i = 0; i < pCaAttr->num_page_sizes; i++)\r
+// {\r
+// size = pCaAttr->p_page_size[i];\r
+// *pFlags |= (size & (size - 1)) ? 0 : size;\r
+// }\r
+//}\r
+\r
+//static void\r
+//ConvertDeviceAttr(WV_DEVICE_ATTRIBUTES* pAttributes, ib_ca_attr_t *pCaAttr)\r
+//{\r
+// *((UINT64*)pAttributes->FwVersion) = pCaAttr->fw_ver; //TODO: check this: 64 byte array?\r
+// pAttributes->NodeGuid = pCaAttr->ca_guid;\r
+// pAttributes->SystemImageGuid = pCaAttr->system_image_guid;\r
+// pAttributes->VendorId = pCaAttr->vend_id;\r
+// pAttributes->VendorPartId = pCaAttr->dev_id;\r
+// pAttributes->HwVersion = pCaAttr->revision;\r
+//\r
+// SetDeviceCap(&pAttributes->CapabilityFlags, pCaAttr);\r
+// pAttributes->AtomicCapability = (WV_ATOMIC_CAPABILITIES) pCaAttr->atomicity;\r
+// SetDevicePages(&pAttributes->PageSizeCapabilityFlags, pCaAttr);\r
+//\r
+// pAttributes->MaxMrSize = pCaAttr->init_region_size;\r
+// pAttributes->MaxQp = pCaAttr->max_qps;\r
+// pAttributes->MaxQpWr = pCaAttr->max_wrs;\r
+// pAttributes->MaxSge = pCaAttr->max_sges;\r
+// pAttributes->MaxCq = pCaAttr->max_cqs;\r
+// pAttributes->MaxCqEntries = pCaAttr->max_cqes;\r
+// pAttributes->MaxMr = pCaAttr->init_regions;\r
+// pAttributes->MaxPd = pCaAttr->max_pds;\r
+// pAttributes->MaxQpResponderResources = pCaAttr->max_qp_resp_res;\r
+// pAttributes->MaxResponderResources = pCaAttr->max_resp_res;\r
+// pAttributes->MaxQpInitiatorDepth = pCaAttr->max_qp_init_depth;\r
+// pAttributes->MaxMw = pCaAttr->init_windows;\r
+// pAttributes->MaxMulticast = pCaAttr->max_mcast_grps;\r
+// pAttributes->MaxQpAttach = pCaAttr->max_qps_per_mcast_grp;\r
+// pAttributes->MaxMulticastQp = pCaAttr->max_mcast_qps;\r
+// pAttributes->MaxAh = pCaAttr->max_addr_handles;\r
+// pAttributes->MaxFmr = pCaAttr->max_fmr;\r
+// pAttributes->MaxMapPerFmr = pCaAttr->max_map_per_fmr;\r
+// pAttributes->MaxSrq = pCaAttr->max_srq;\r
+// pAttributes->MaxSrqWr = pCaAttr->max_srq_wrs;\r
+// pAttributes->MaxSrqSge = pCaAttr->max_srq_sges;\r
+// pAttributes->MaxPkeys = pCaAttr->max_partitions;\r
+// pAttributes->LocalAckDelay = pCaAttr->local_ack_delay;\r
+// pAttributes->PhysPortCount = pCaAttr->num_ports;\r
+//}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+Query(WV_DEVICE_ATTRIBUTES* pAttributes)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+QueryPort(UINT8 PortNumber, WV_PORT_ATTRIBUTES* pAttributes)\r
+{\r
+ UNREFERENCED_PARAMETER(PortNumber);\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+QueryGid(UINT8 PortNumber, DWORD Index, WV_GID* pGid)\r
+{\r
+ UNREFERENCED_PARAMETER(PortNumber);\r
+ UNREFERENCED_PARAMETER(Index);\r
+ UNREFERENCED_PARAMETER(pGid);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+QueryPkey(UINT8 PortNumber, DWORD Index, UINT16* pPkey)\r
+{\r
+ UNREFERENCED_PARAMETER(PortNumber);\r
+ UNREFERENCED_PARAMETER(Index);\r
+ UNREFERENCED_PARAMETER(pPkey);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+CreateCompletionQueue(SIZE_T *pEntries, IWVCompletionQueue** ppCq)\r
+{\r
+ UNREFERENCED_PARAMETER(pEntries);\r
+ UNREFERENCED_PARAMETER(ppCq);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+AllocateProtectionDomain(IWVProtectionDomain** ppPd)\r
+{\r
+ UNREFERENCED_PARAMETER(ppPd);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CIWVDevice::\r
+Notify(OVERLAPPED* pOverlapped, WV_EVENT* pEvent)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pEvent);\r
+\r
+ return E_NOTIMPL;\r
+}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_DEVICE_H_\r
+#define _WV_DEVICE_H_\r
+\r
+#include "rdma\winverbs.h"\r
+\r
+class CIWVDevice : IWVDevice\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVDevice methods\r
+ STDMETHODIMP Query(WV_DEVICE_ATTRIBUTES* pAttributes);\r
+ STDMETHODIMP QueryPort(UINT8 PortNumber, WV_PORT_ATTRIBUTES* pAttributes);\r
+ STDMETHODIMP QueryGid(UINT8 PortNumber, DWORD Index, WV_GID* pGid);\r
+ STDMETHODIMP QueryPkey(UINT8 PortNumber, DWORD Index, UINT16* pPkey);\r
+ STDMETHODIMP CreateCompletionQueue(SIZE_T *pEntries, IWVCompletionQueue** ppCq);\r
+ STDMETHODIMP AllocateProtectionDomain(IWVProtectionDomain** ppPd);\r
+ STDMETHODIMP Notify(OVERLAPPED* pOverlapped, WV_EVENT* pEvent);\r
+};\r
+\r
+#endif // __WV_DEVICE_H_\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include "wv_base.h"\r
+#include "wv_ep.h"\r
+\r
+STDMETHODIMP CWVEndpoint::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVEndpoint::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVEndpoint::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVEndpoint::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVEndpoint::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVEndpoint::\r
+BindAddress(const struct sockaddr* pAddress)\r
+{\r
+ UNREFERENCED_PARAMETER(pAddress);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVEndpoint::\r
+Reject(const VOID* pPrivateData, SIZE_T PrivateDataLength)\r
+{\r
+ UNREFERENCED_PARAMETER(pPrivateData);\r
+ UNREFERENCED_PARAMETER(PrivateDataLength);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVConnectEndpoint::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVConnectEndpoint::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+BindAddress(const struct sockaddr* pAddress)\r
+{\r
+ UNREFERENCED_PARAMETER(pAddress);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+Reject(const VOID* pPrivateData, SIZE_T PrivateDataLength)\r
+{\r
+ UNREFERENCED_PARAMETER(pPrivateData);\r
+ UNREFERENCED_PARAMETER(PrivateDataLength);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+Connect(IWVConnectQueuePair* pQp, WV_CONNECT_PARAM* pParam, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pQp);\r
+ UNREFERENCED_PARAMETER(pParam);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+Accept(IWVConnectQueuePair* pQp, WV_CONNECT_PARAM* pParam, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pQp);\r
+ UNREFERENCED_PARAMETER(pParam);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+Disconnect(OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+NotifyDisconnect(OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectEndpoint::\r
+Query(WV_CONNECT_ATTRIBUTES* pAttributes)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVDatagramEndpoint::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVDatagramEndpoint::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+BindAddress(const struct sockaddr* pAddress)\r
+{\r
+ UNREFERENCED_PARAMETER(pAddress);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+Reject(const VOID* pPrivateData, SIZE_T PrivateDataLength)\r
+{\r
+ UNREFERENCED_PARAMETER(pPrivateData);\r
+ UNREFERENCED_PARAMETER(PrivateDataLength);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+Lookup(const VOID* pPrivateData, SIZE_T PrivateDataLength, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pPrivateData);\r
+ UNREFERENCED_PARAMETER(PrivateDataLength);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+Accept(WV_DATAGRAM_PARAM* pParam, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pParam);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+JoinMulticast(const struct sockaddr* pAddress, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pAddress);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+LeaveMulticast(const struct sockaddr* pAddress, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pAddress);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramEndpoint::\r
+Query(WV_DATAGRAM_ATTRIBUTES* pAttributes)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+\r
+ return E_NOTIMPL;\r
+}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_EP_H_\r
+#define _WV_EP_H_\r
+\r
+#include "rdma\winverbs.h"\r
+\r
+class CWVEndpoint : IWVEndpoint\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVEndpoint methods\r
+ STDMETHODIMP BindAddress(const struct sockaddr* pAddress);\r
+ STDMETHODIMP Reject(const VOID* pPrivateData, SIZE_T PrivateDataLength);\r
+};\r
+\r
+class CWVConnectEndpoint : IWVConnectEndpoint\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVEndpoint methods\r
+ STDMETHODIMP BindAddress(const struct sockaddr* pAddress);\r
+ STDMETHODIMP Reject(const VOID* pPrivateData, SIZE_T PrivateDataLength);\r
+\r
+ // IWVConnectEndpoint methods\r
+ STDMETHODIMP Connect(IWVConnectQueuePair* pQp, WV_CONNECT_PARAM* pParam,\r
+ OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP Accept(IWVConnectQueuePair* pQp, WV_CONNECT_PARAM* pParam,\r
+ OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP Disconnect(OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP NotifyDisconnect(OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP Query(WV_CONNECT_ATTRIBUTES* pAttributes);\r
+};\r
+\r
+class CWVDatagramEndpoint : IWVDatagramEndpoint\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVEndpoint methods\r
+ STDMETHODIMP BindAddress(const struct sockaddr* pAddress);\r
+ STDMETHODIMP Reject(const VOID* pPrivateData, SIZE_T PrivateDataLength);\r
+\r
+ // IWVDatagramEndpoint methods\r
+ STDMETHODIMP Lookup(const VOID* pPrivateData, SIZE_T PrivateDataLength,\r
+ OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP Accept(WV_DATAGRAM_PARAM* pParam, OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP JoinMulticast(const struct sockaddr* pAddress,\r
+ OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP LeaveMulticast(const struct sockaddr* pAddress,\r
+ OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP Query(WV_DATAGRAM_ATTRIBUTES* pAttributes);\r
+};\r
+\r
+#endif // _WV_EP_H_\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+LIBRARY WINVERBS.DLL\r
+\r
+EXPORTS\r
+ DllCanUnloadNow PRIVATE\r
+ DllGetClassObject PRIVATE\r
--- /dev/null
+#if DBG\r
+LIBRARY winverbsd.dll\r
+#else\r
+LIBRARY winverbs.dll\r
+#endif\r
+\r
+#ifndef _WIN64\r
+EXPORTS\r
+\r
+#endif\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include "wv_base.h"\r
+#include "wv_listen.h"\r
+\r
+STDMETHODIMP CWVListen::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVListen::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVListen::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVListen::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVListen::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVListen::\r
+GetRequest(IWVEndpoint* pEndpoint, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pEndpoint);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_LISTEN_H_\r
+#define _WV_LISTEN_H_\r
+\r
+#include "rdma\winverbs.h"\r
+\r
+class CWVListen : IWVListen\r
+{\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVListen methods\r
+ STDMETHODIMP GetRequest(IWVEndpoint* pEndpoint, OVERLAPPED* pOverlapped);\r
+};\r
+\r
+#endif // _WV_LISTEN_H_
\ No newline at end of file
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include <initguid.h>\r
+\r
+#include "wv_base.h"\r
+#include "wv_provider.h"\r
+\r
+static volatile LONG nRef;\r
+\r
+BOOLEAN WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)\r
+{\r
+ UNREFERENCED_PARAMETER(hInstance);\r
+ UNREFERENCED_PARAMETER(dwReason);\r
+ UNREFERENCED_PARAMETER(lpReserved);\r
+\r
+ return TRUE;\r
+}\r
+\r
+STDAPI DllCanUnloadNow(void)\r
+{\r
+ return nRef ? S_FALSE : S_OK;\r
+}\r
+\r
+STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppvObj)\r
+{\r
+ HRESULT ret;\r
+ CWVProvider *wv;\r
+\r
+ UNREFERENCED_PARAMETER(rclsid);\r
+\r
+ if (riid != IID_IWVProvider)\r
+ {\r
+ *ppvObj = NULL;\r
+ return E_NOINTERFACE;\r
+ }\r
+\r
+ wv = new CWVProvider;\r
+ ret = wv->QueryInterface(riid, ppvObj);\r
+ if (ret == NOERROR)\r
+ InterlockedIncrement(&nRef);\r
+ return ret;\r
+}\r
+\r
+//HRESULT ConvertIbalStatus(ib_api_status_t status)\r
+//{\r
+// switch (status)\r
+// {\r
+// case IB_SUCCESS: return WV_SUCCESS;\r
+// case IB_INSUFFICIENT_RESOURCES: return WV_INSUFFICIENT_RESOURCES;\r
+// case IB_INSUFFICIENT_MEMORY: return WV_NO_MEMORY;\r
+// case IB_INVALID_PARAMETER: return WV_INVALID_PARAMETER;\r
+// case IB_INVALID_SETTING: return WV_INVALID_PARAMETER;\r
+// case IB_NOT_FOUND: return WV_INVALID_ADDRESS;\r
+// case IB_TIMEOUT: return WV_TIMEOUT;\r
+// case IB_CANCELED: return WV_CANCELLED;\r
+// case IB_INTERRUPTED: return WV_CANCELLED;\r
+// case IB_INVALID_PERMISSION: return WV_ACCESS_VIOLATION;\r
+// case IB_UNSUPPORTED: return WV_NOT_SUPPORTED;\r
+// case IB_OVERFLOW: return WV_BUFFER_OVERFLOW;\r
+// case IB_MAX_MCAST_QPS_REACHED: return WV_INSUFFICIENT_RESOURCES;\r
+// case IB_INVALID_QP_STATE: return WV_INVALID_PARAMETER;\r
+// case IB_INVALID_APM_STATE: return WV_INVALID_PARAMETER;\r
+// case IB_INVALID_PORT_STATE: return WV_INVALID_PARAMETER;\r
+// case IB_INVALID_STATE: return WV_INVALID_PARAMETER;\r
+// case IB_RESOURCE_BUSY: return WV_DEVICE_BUSY;\r
+// case IB_INVALID_PKEY: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_LKEY: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_RKEY: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_MAX_WRS: return WV_INSUFFICIENT_RESOURCES;\r
+// case IB_INVALID_MAX_SGE: return WV_INSUFFICIENT_RESOURCES;\r
+// case IB_INVALID_CQ_SIZE: return WV_INSUFFICIENT_RESOURCES;\r
+// case IB_INVALID_SRQ_SIZE: return WV_INSUFFICIENT_RESOURCES;\r
+// case IB_INVALID_SERVICE_TYPE: return WV_NOT_SUPPORTED;\r
+// case IB_INVALID_GID: return WV_INVALID_ADDRESS;\r
+// case IB_INVALID_LID: return WV_INVALID_ADDRESS;\r
+// case IB_INVALID_GUID: return WV_INVALID_ADDRESS;\r
+// case IB_INVALID_CA_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_AV_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_CQ_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_QP_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_SRQ_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_PD_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_MR_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_FMR_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_MW_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_MCAST_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_CALLBACK: return WV_INVALID_PARAMETER;\r
+// case IB_INVALID_AL_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_INVALID_HANDLE: return WV_INVALID_HANDLE;\r
+// case IB_ERROR: return WV_UNKNOWN_ERROR;\r
+// case IB_REMOTE_ERROR: return WV_REMOTE_OP_ERROR;\r
+// case IB_VERBS_PROCESSING_DONE: return WV_SUCCESS;\r
+// case IB_INVALID_WR_TYPE: return WV_INVALID_PARAMETER;\r
+// case IB_QP_IN_TIMEWAIT: return WV_INVALID_PARAMETER;\r
+// case IB_EE_IN_TIMEWAIT: return WV_INVALID_PARAMETER;\r
+// case IB_INVALID_PORT: return WV_INVALID_ADDRESS;\r
+// case IB_NOT_DONE: return WV_PENDING;\r
+// case IB_INVALID_INDEX: return WV_INVALID_PARAMETER;\r
+// case IB_NO_MATCH: return WV_INVALID_PARAMETER;\r
+// case IB_PENDING: return WV_PENDING;\r
+// default: return WV_UNKNOWN_ERROR;\r
+// }\r
+//}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include "wv_base.h"\r
+#include "wv_pd.h"\r
+\r
+STDMETHODIMP CWVProtectionDomain::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVProtectionDomain::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVProtectionDomain::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVProtectionDomain::\r
+CreateSharedReceiveQueue(SIZE_T MaxWr, SIZE_T MaxSge,\r
+ SIZE_T SrqLimit, IWVSharedReceiveQueue** ppSrq)\r
+{\r
+ UNREFERENCED_PARAMETER(MaxWr);\r
+ UNREFERENCED_PARAMETER(MaxSge);\r
+ UNREFERENCED_PARAMETER(SrqLimit);\r
+ UNREFERENCED_PARAMETER(ppSrq);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProtectionDomain::\r
+CreateQueuePair(WV_QP_CREATE* pAttributes, IWVQueuePair** ppQp)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+ UNREFERENCED_PARAMETER(ppQp);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProtectionDomain::\r
+RegisterMemory(const VOID* pBuffer, SIZE_T BufferLength, DWORD AccessFlags,\r
+ OVERLAPPED* pOverlapped, UINT32* pLkey, UINT32* pRkey)\r
+{\r
+ UNREFERENCED_PARAMETER(pBuffer);\r
+ UNREFERENCED_PARAMETER(BufferLength);\r
+ UNREFERENCED_PARAMETER(AccessFlags);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pLkey);\r
+ UNREFERENCED_PARAMETER(pRkey);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProtectionDomain::\r
+DeregisterMemory(UINT32 Lkey, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(Lkey);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProtectionDomain::\r
+AllocateMemoryWindow(IWVMemoryWindow** ppMw)\r
+{\r
+ UNREFERENCED_PARAMETER(ppMw);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProtectionDomain::\r
+CreateAddressHandle(WV_ADDRESS_VECTOR* pAddress, IWVAddressHandle** ppAh)\r
+{\r
+ UNREFERENCED_PARAMETER(pAddress);\r
+ UNREFERENCED_PARAMETER(ppAh);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+\r
+STDMETHODIMP CWVMemoryWindow::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVMemoryWindow::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVMemoryWindow::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+\r
+STDMETHODIMP CWVAddressHandle::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVAddressHandle::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVAddressHandle::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_PD_H_\r
+#define _WV_PD_H_\r
+\r
+#include "rdma\winverbs.h"\r
+\r
+class CWVProtectionDomain : IWVProtectionDomain\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVProtectionDomain methods\r
+ STDMETHODIMP CreateSharedReceiveQueue(SIZE_T MaxWr, SIZE_T MaxSge,\r
+ SIZE_T SrqLimit, IWVSharedReceiveQueue** ppSrq);\r
+ STDMETHODIMP CreateQueuePair(WV_QP_CREATE* pAttributes, IWVQueuePair** ppQp);\r
+ STDMETHODIMP RegisterMemory(const VOID* pBuffer, SIZE_T BufferLength,\r
+ DWORD AccessFlags, OVERLAPPED* pOverlapped,\r
+ UINT32* pLkey, UINT32* pRkey);\r
+ STDMETHODIMP DeregisterMemory(UINT32 Lkey, OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP AllocateMemoryWindow(IWVMemoryWindow** ppMw);\r
+ STDMETHODIMP CreateAddressHandle(WV_ADDRESS_VECTOR* pAddress,\r
+ IWVAddressHandle** ppAh);\r
+};\r
+\r
+class CWVMemoryWindow : IWVMemoryWindow\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+};\r
+\r
+\r
+class CWVAddressHandle : IWVAddressHandle\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+};\r
+\r
+#endif // _WV_PD_H_
\ No newline at end of file
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include "wv_base.h"\r
+#include "wv_provider.h"\r
+\r
+STDMETHODIMP CWVProvider::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ if (riid != IID_IUnknown && riid != IID_IWVProvider)\r
+ {\r
+ *ppvObj = NULL;\r
+ return E_NOINTERFACE;\r
+ }\r
+\r
+ *ppvObj = this;\r
+ InterlockedIncrement(&m_nRef);\r
+ return NOERROR;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVProvider::\r
+AddRef(void)\r
+{\r
+ return InterlockedIncrement(&m_nRef);\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVProvider::\r
+Release(void)\r
+{\r
+ ULONG ref;\r
+\r
+ ref = (ULONG) InterlockedDecrement(&m_nRef);\r
+ if (ref == 0)\r
+ delete this;\r
+ return ref;\r
+}\r
+\r
+STDMETHODIMP CWVProvider::\r
+QueryDeviceList(UINT64* pGuidList, SIZE_T* pBufferSize)\r
+{\r
+ UNREFERENCED_PARAMETER(pGuidList);\r
+ UNREFERENCED_PARAMETER(pBufferSize);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProvider::\r
+QueryDevice(UINT64 Guid, WV_DEVICE_ATTRIBUTES* pAttributes)\r
+{\r
+ UNREFERENCED_PARAMETER(Guid);\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProvider::\r
+QueryAddressList(WV_ADDRESS_LIST* pAddressList, SIZE_T* pBufferSize)\r
+{\r
+ UNREFERENCED_PARAMETER(pAddressList);\r
+ UNREFERENCED_PARAMETER(pBufferSize);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProvider::\r
+OpenDevice(UINT64 Guid, IWVDevice** ppDevice)\r
+{\r
+ UNREFERENCED_PARAMETER(Guid);\r
+ UNREFERENCED_PARAMETER(ppDevice);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProvider::\r
+CreateConnectEndpoint(IWVConnectEndpoint** ppConnectEndpoint)\r
+{\r
+ UNREFERENCED_PARAMETER(ppConnectEndpoint);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProvider::\r
+CreateDatagramEndpoint(IWVDatagramEndpoint** ppDatagramEndpoint)\r
+{\r
+ UNREFERENCED_PARAMETER(ppDatagramEndpoint);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVProvider::\r
+CreateListen(const struct sockaddr* pAddress, SIZE_T Backlog, IWVListen** ppListen)\r
+{\r
+ UNREFERENCED_PARAMETER(pAddress);\r
+ UNREFERENCED_PARAMETER(Backlog);\r
+ UNREFERENCED_PARAMETER(ppListen);\r
+\r
+ return E_NOTIMPL;\r
+}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_PROVIDER_H_\r
+#define _WV_PROVIDER_H_\r
+\r
+#include "rdma\winverbs.h"\r
+\r
+class CWVProvider : IWVProvider\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVProvider methods\r
+ STDMETHODIMP QueryDeviceList(UINT64* pGuidList, SIZE_T* pBufferSize);\r
+ STDMETHODIMP QueryDevice(UINT64 Guid, WV_DEVICE_ATTRIBUTES* pAttributes);\r
+ STDMETHODIMP QueryAddressList(WV_ADDRESS_LIST* pAddressList,\r
+ SIZE_T* pBufferSize);\r
+\r
+ STDMETHODIMP OpenDevice(UINT64 Guid, IWVDevice** ppDevice);\r
+\r
+ STDMETHODIMP CreateConnectEndpoint(IWVConnectEndpoint** ppConnectEndpoint);\r
+ STDMETHODIMP CreateDatagramEndpoint(IWVDatagramEndpoint** ppDatagramEndpoint);\r
+ STDMETHODIMP CreateListen(const struct sockaddr* pAddress,\r
+ SIZE_T backlog, IWVListen** ppListen);\r
+\r
+private:\r
+ volatile LONG m_nRef;\r
+};\r
+\r
+#endif // _WV_PROVIDER_H_
\ No newline at end of file
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include "wv_base.h"\r
+#include "wv_qp.h"\r
+\r
+STDMETHODIMP CWVQueuePair::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVQueuePair::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVQueuePair::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVQueuePair::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVQueuePair::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVQueuePair::\r
+Query(WV_QP_ATTRIBUTES* pAttributes)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVQueuePair::\r
+Modify(WV_QP_ATTRIBUTES* pAttributes, DWORD Options, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+ UNREFERENCED_PARAMETER(Options);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVQueuePair::\r
+PostReceive(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSgl);\r
+ UNREFERENCED_PARAMETER(nSge);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVConnectQueuePair::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVConnectQueuePair::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+Query(WV_QP_ATTRIBUTES* pAttributes)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+Modify(WV_QP_ATTRIBUTES* pAttributes, DWORD Options, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+ UNREFERENCED_PARAMETER(Options);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+PostReceive(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSgl);\r
+ UNREFERENCED_PARAMETER(nSge);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+Send(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge,\r
+ DWORD Flags, UINT32 ImmediateData)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSgl);\r
+ UNREFERENCED_PARAMETER(nSge);\r
+ UNREFERENCED_PARAMETER(Flags);\r
+ UNREFERENCED_PARAMETER(ImmediateData);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+Read(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge,\r
+ DWORD Flags, UINT64 Address, UINT32 Rkey)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSgl);\r
+ UNREFERENCED_PARAMETER(nSge);\r
+ UNREFERENCED_PARAMETER(Flags);\r
+ UNREFERENCED_PARAMETER(Address);\r
+ UNREFERENCED_PARAMETER(Rkey);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+Write(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge,\r
+ DWORD Flags, UINT32 ImmediateData, UINT64 Address, UINT32 Rkey)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSgl);\r
+ UNREFERENCED_PARAMETER(nSge);\r
+ UNREFERENCED_PARAMETER(Flags);\r
+ UNREFERENCED_PARAMETER(ImmediateData);\r
+ UNREFERENCED_PARAMETER(Address);\r
+ UNREFERENCED_PARAMETER(Rkey);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+CompareExchange(UINT64 WrId, const WV_SGE* pSge, DWORD Flags,\r
+ UINT64 Compare, UINT64 Exchange, UINT64 Address, UINT32 Rkey)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSge);\r
+ UNREFERENCED_PARAMETER(Flags);\r
+ UNREFERENCED_PARAMETER(Compare);\r
+ UNREFERENCED_PARAMETER(Exchange);\r
+ UNREFERENCED_PARAMETER(Address);\r
+ UNREFERENCED_PARAMETER(Rkey);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+FetchAdd(UINT64 WrId, const WV_SGE* pSge, DWORD Flags,\r
+ UINT64 Value, UINT64 Address, UINT32 Rkey)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSge);\r
+ UNREFERENCED_PARAMETER(Flags);\r
+ UNREFERENCED_PARAMETER(Value);\r
+ UNREFERENCED_PARAMETER(Address);\r
+ UNREFERENCED_PARAMETER(Rkey);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVConnectQueuePair::\r
+BindMemoryWindow(IWVMemoryWindow* pMw, UINT64 WrId,\r
+ UINT32 Lkey, DWORD AccessFlags, DWORD SendFlags,\r
+ const VOID* pBuffer, SIZE_T BufferLength, UINT32 *pRkey)\r
+{\r
+ UNREFERENCED_PARAMETER(pMw);\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(Lkey);\r
+ UNREFERENCED_PARAMETER(AccessFlags);\r
+ UNREFERENCED_PARAMETER(SendFlags);\r
+ UNREFERENCED_PARAMETER(pBuffer);\r
+ UNREFERENCED_PARAMETER(BufferLength);\r
+ UNREFERENCED_PARAMETER(pRkey);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVDatagramQueuePair::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVDatagramQueuePair::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+Query(WV_QP_ATTRIBUTES* pAttributes)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+Modify(WV_QP_ATTRIBUTES* pAttributes, DWORD Options, OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pAttributes);\r
+ UNREFERENCED_PARAMETER(Options);\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+PostReceive(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSgl);\r
+ UNREFERENCED_PARAMETER(nSge);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+Send(UINT64 WrId, IWVAddressHandle* pAddressHandle,\r
+ WV_SGE* pSge, DWORD Flags, UINT32 DestinationQpn,\r
+ UINT32 DestinationQkey, UINT16 PkeyIndex)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pAddressHandle);\r
+ UNREFERENCED_PARAMETER(pSge);\r
+ UNREFERENCED_PARAMETER(Flags);\r
+ UNREFERENCED_PARAMETER(DestinationQpn);\r
+ UNREFERENCED_PARAMETER(DestinationQkey);\r
+ UNREFERENCED_PARAMETER(PkeyIndex);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+SendMessage(WV_SEND_DATAGRAM* pSend)\r
+{\r
+ UNREFERENCED_PARAMETER(pSend);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+AttachMulticast(WV_GID *pGid, UINT16 Lid)\r
+{\r
+ UNREFERENCED_PARAMETER(pGid);\r
+ UNREFERENCED_PARAMETER(Lid);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVDatagramQueuePair::\r
+DetachMulticast(WV_GID *pGid, UINT16 Lid)\r
+{\r
+ UNREFERENCED_PARAMETER(pGid);\r
+ UNREFERENCED_PARAMETER(Lid);\r
+\r
+ return E_NOTIMPL;\r
+}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_QP_H_\r
+#define _WV_QP_H_\r
+\r
+#include "rdma\winverbs.h"\r
+\r
+class CWVQueuePair : IWVQueuePair\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVQueuePair methods\r
+ STDMETHODIMP Query(WV_QP_ATTRIBUTES* pAttributes);\r
+ STDMETHODIMP Modify(WV_QP_ATTRIBUTES* pAttributes, DWORD Options,\r
+ OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP PostReceive(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge);\r
+};\r
+\r
+class CWVConnectQueuePair : IWVConnectQueuePair\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVQueuePair methods\r
+ STDMETHODIMP Query(WV_QP_ATTRIBUTES* pAttributes);\r
+ STDMETHODIMP Modify(WV_QP_ATTRIBUTES* pAttributes, DWORD Options,\r
+ OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP PostReceive(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge);\r
+\r
+ // IWVConnectQueuePair methods\r
+ STDMETHODIMP Send(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge,\r
+ DWORD Flags, UINT32 ImmediateData);\r
+ STDMETHODIMP Read(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge,\r
+ DWORD Flags, UINT64 Address, UINT32 Rkey);\r
+ STDMETHODIMP Write(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge,\r
+ DWORD Flags, UINT32 ImmediateData, UINT64 Address, UINT32 Rkey);\r
+ STDMETHODIMP CompareExchange(UINT64 WrId, const WV_SGE* pSge, DWORD Flags,\r
+ UINT64 Compare, UINT64 Exchange, UINT64 Address, UINT32 Rkey);\r
+ STDMETHODIMP FetchAdd(UINT64 WrId, const WV_SGE* pSge, DWORD Flags,\r
+ UINT64 Value, UINT64 Address, UINT32 Rkey);\r
+ STDMETHODIMP BindMemoryWindow(IWVMemoryWindow* pMw, UINT64 WrId,\r
+ UINT32 Lkey, DWORD AccessFlags, DWORD SendFlags,\r
+ const VOID* pBuffer, SIZE_T BufferLength, UINT32 *pRkey);\r
+};\r
+\r
+class CWVDatagramQueuePair : IWVDatagramQueuePair\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVQueuePair methods\r
+ STDMETHODIMP Query(WV_QP_ATTRIBUTES* pAttributes);\r
+ STDMETHODIMP Modify(WV_QP_ATTRIBUTES* pAttributes, DWORD Options,\r
+ OVERLAPPED* pOverlapped);\r
+ STDMETHODIMP PostReceive(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge);\r
+\r
+ // IWVDatagramQueuePair Methods\r
+ STDMETHODIMP Send(UINT64 WrId, IWVAddressHandle* pAddressHandle,\r
+ WV_SGE* pSge, DWORD Flags, UINT32 DestinationQpn,\r
+ UINT32 DestinationQkey, UINT16 PkeyIndex);\r
+ STDMETHODIMP SendMessage(WV_SEND_DATAGRAM* pSend);\r
+ STDMETHODIMP AttachMulticast(WV_GID *pGid, UINT16 Lid);\r
+ STDMETHODIMP DetachMulticast(WV_GID *pGid, UINT16 Lid);\r
+};\r
+\r
+#endif // _WV_QP_H_
\ No newline at end of file
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#include "wv_base.h"\r
+#include "wv_srq.h"\r
+\r
+STDMETHODIMP CWVSharedReceiveQueue::\r
+QueryInterface(REFIID riid, LPVOID FAR* ppvObj)\r
+{\r
+ UNREFERENCED_PARAMETER(riid);\r
+ UNREFERENCED_PARAMETER(ppvObj);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVSharedReceiveQueue::\r
+AddRef(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP_(ULONG) CWVSharedReceiveQueue::\r
+Release(void)\r
+{\r
+ return 0;\r
+}\r
+\r
+STDMETHODIMP CWVSharedReceiveQueue::\r
+CancelOverlappedRequests(void)\r
+{\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVSharedReceiveQueue::\r
+GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+ UNREFERENCED_PARAMETER(pNumberOfBytesTransferred);\r
+ UNREFERENCED_PARAMETER(bWait);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVSharedReceiveQueue::\r
+Query(SIZE_T* pMaxWr, SIZE_T* pMaxSge, SIZE_T* pSrqLimit)\r
+{\r
+ UNREFERENCED_PARAMETER(pMaxWr);\r
+ UNREFERENCED_PARAMETER(pMaxSge);\r
+ UNREFERENCED_PARAMETER(pSrqLimit);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVSharedReceiveQueue::\r
+Modify(SIZE_T MaxWr, SIZE_T SrqLimit)\r
+{\r
+ UNREFERENCED_PARAMETER(MaxWr);\r
+ UNREFERENCED_PARAMETER(SrqLimit);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVSharedReceiveQueue::\r
+PostReceive(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge)\r
+{\r
+ UNREFERENCED_PARAMETER(WrId);\r
+ UNREFERENCED_PARAMETER(pSgl);\r
+ UNREFERENCED_PARAMETER(nSge);\r
+\r
+ return E_NOTIMPL;\r
+}\r
+\r
+STDMETHODIMP CWVSharedReceiveQueue::\r
+Notify(OVERLAPPED* pOverlapped)\r
+{\r
+ UNREFERENCED_PARAMETER(pOverlapped);\r
+\r
+ return E_NOTIMPL;\r
+}\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WV_SRQ_H_\r
+#define _WV_SRQ_H_\r
+\r
+#include "rdma\winverbs.h"\r
+\r
+class CWVSharedReceiveQueue : IWVSharedReceiveQueue\r
+{\r
+public:\r
+ // IUnknown methods\r
+ STDMETHODIMP QueryInterface(REFIID riid, LPVOID FAR* ppvObj);\r
+ STDMETHODIMP_(ULONG) AddRef();\r
+ STDMETHODIMP_(ULONG) Release();\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHODIMP CancelOverlappedRequests();\r
+ STDMETHODIMP GetOverlappedResult(OVERLAPPED *pOverlapped,\r
+ SIZE_T *pNumberOfBytesTransferred, BOOL bWait);\r
+\r
+ // IWVSharedReceiveQueue methods\r
+ STDMETHODIMP Query(SIZE_T* pMaxWr, SIZE_T* pMaxSge, SIZE_T* pSrqLimit);\r
+ STDMETHODIMP Modify(SIZE_T MaxWr, SIZE_T SrqLimit);\r
+ STDMETHODIMP PostReceive(UINT64 WrId, const WV_SGE* pSgl, SIZE_T nSge);\r
+ STDMETHODIMP Notify(OVERLAPPED* pOverlapped);\r
+};\r
+\r
+#endif // _WV_SRQ_H_
\ No newline at end of file
--- /dev/null
+/*\r
+ * Copyright (c) 1996-2008 Intel Corporation. All rights reserved.\r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WINVERBS_H_\r
+#define _WINVERBS_H_\r
+\r
+#include <winsock2.h>\r
+#include <unknwn.h>\r
+#include "wvstatus.h"\r
+\r
+typedef union _WV_GID // Network byte order\r
+{\r
+ UINT8 Raw[16];\r
+\r
+} WV_GID;\r
+\r
+// Device/port capability flags\r
+#define WV_DEVICE_RESIZE_MAX_WR 0x00000001\r
+#define WV_DEVICE_BAD_PKEY_COUNTER 0x00000002\r
+#define WV_DEVICE_BAD_QKEY_COUNTER 0x00000004\r
+// reserved 0x00000008\r
+#define WV_DEVICE_PATH_MIGRATION 0x00000010\r
+#define WV_DEVICE_CHANGE_PHYSICAL_PORT 0x00000020\r
+#define WV_DEVICE_AH_PORT_CHECKING 0x00000040\r
+#define WV_DEVICE_QP_STATE_MODIFIER 0x00000080\r
+#define WV_DEVICE_SHUTDOWN_PORT 0x00000100\r
+#define WV_DEVICE_INIT_TYPE 0x00000200\r
+#define WV_DEVICE_PORT_ACTIVE_EVENT 0x00000400\r
+#define WV_DEVICE_SYSTEM_IMAGE_GUID 0x00000800\r
+#define WV_DEVICE_RC_RNR_NAK_GENERATION 0x00001000\r
+#define WV_DEVICE_SRQ_RESIZE 0x00002000\r
+#define WV_DEVICE_BATCH_NOTIFY_CQ 0x00004000\r
+\r
+typedef enum _WV_ATOMIC_CAPABILITIES\r
+{\r
+ WvAtomicNone,\r
+ WvAtomicHca,\r
+ WvAtomicNode\r
+\r
+} WV_ATOMIC_CAPABILITIES;\r
+\r
+typedef struct _WV_DEVICE_ATTRIBUTES\r
+{\r
+ UINT8 FwVersion[64];\r
+ UINT64 NodeGuid;\r
+ UINT64 SystemImageGuid;\r
+ UINT32 VendorId;\r
+ UINT32 VendorPartId;\r
+ UINT32 HwVersion;\r
+ DWORD CapabilityFlags;\r
+ WV_ATOMIC_CAPABILITIES AtomicCapability;\r
+ DWORD PageSizeCapabilityFlags;\r
+ SIZE_T MaxMrSize;\r
+ SIZE_T MaxQp;\r
+ SIZE_T MaxQpWr;\r
+ SIZE_T MaxSge;\r
+ SIZE_T MaxCq;\r
+ SIZE_T MaxCqEntries;\r
+ SIZE_T MaxMr;\r
+ SIZE_T MaxPd;\r
+ SIZE_T MaxQpResponderResources;\r
+ SIZE_T MaxResponderResources;\r
+ SIZE_T MaxQpInitiatorDepth;\r
+ SIZE_T MaxMw;\r
+ SIZE_T MaxMulticast;\r
+ SIZE_T MaxQpAttach;\r
+ SIZE_T MaxMulticastQp;\r
+ SIZE_T MaxAh;\r
+ SIZE_T MaxFmr;\r
+ SIZE_T MaxMapPerFmr;\r
+ SIZE_T MaxSrq;\r
+ SIZE_T MaxSrqWr;\r
+ SIZE_T MaxSrqSge;\r
+ SIZE_T MaxPkeys;\r
+ UINT8 LocalAckDelay;\r
+ UINT8 PhysPortCount;\r
+\r
+} WV_DEVICE_ATTRIBUTES;\r
+\r
+typedef enum _WV_PORT_STATE\r
+{\r
+ WvPortNop,\r
+ WvPortDown,\r
+ WvPortInit,\r
+ WvPortArmed,\r
+ WvPortActive,\r
+ WvPortActiveDefer\r
+\r
+} WV_PORT_STATE;\r
+\r
+typedef struct _WV_PORT_ATTRIBUTES\r
+{\r
+ DWORD PortCabilityFlags;\r
+ WV_PORT_STATE State;\r
+ UINT32 MaxMtu;\r
+ UINT32 ActiveMtu;\r
+ UINT32 GidTableLength;\r
+ UINT32 MaxMessageSize;\r
+ UINT32 BadPkeyCounter;\r
+ UINT32 QkeyViolationCounter;\r
+ UINT16 PkeyTableLength;\r
+ UINT16 Lid;\r
+ UINT16 SmLid;\r
+ UINT8 Lmc;\r
+ UINT8 MaxVls;\r
+ UINT8 SmSl;\r
+ UINT8 SubneTimeout;\r
+ UINT8 InitTypeReply;\r
+ UINT8 ActiveWidth;\r
+ UINT8 ActiveSpeed;\r
+ UINT8 PhysicalState;\r
+\r
+} WV_PORT_ATTRIBUTES;\r
+\r
+typedef struct _WV_ADDRESS\r
+{\r
+ SOCKET_ADDRESS Address;\r
+ UINT64 DeviceGuid;\r
+ UINT16 Pkey;\r
+ UINT8 PortNumber;\r
+\r
+} WV_ADDRESS;\r
+\r
+typedef struct _WV_ADDRESS_LIST\r
+{\r
+ SIZE_T Count;\r
+ WV_ADDRESS Address[1];\r
+\r
+} WV_ADDRESS_LIST;\r
+\r
+typedef enum _WV_EVENT_TYPE\r
+{\r
+ WvEventDeviceError,\r
+ WvEventPortActive,\r
+ WvEventPortDown\r
+\r
+} WV_EVENT_TYPE;\r
+\r
+typedef struct _WV_EVENT\r
+{\r
+ HRESULT Status;\r
+ WV_EVENT_TYPE Type;\r
+ UINT8 PortNumber;\r
+\r
+} WV_EVENT;\r
+\r
+typedef enum _WV_CQ_NOTIFY_TYPE\r
+{\r
+ WvCqSolicited = 1,\r
+ WvCqNextCompletion\r
+\r
+} WV_CQ_NOTIFY_TYPE;\r
+\r
+typedef enum _WV_OPCODE\r
+{\r
+ WvSend,\r
+ WvRdmaWrite,\r
+ WvRecv,\r
+ WvRdmaRead,\r
+ WvBindWindow,\r
+ WvFetchAdd,\r
+ WvCompareExchange,\r
+ WvRecvRdmaWrite\r
+\r
+} WV_OPCODE;\r
+\r
+// Completion flags\r
+#define WV_WC_IMMEDIATE 0x00000001\r
+// reserved 0x00000002\r
+#define WV_WC_GRH_VALID 0x00000004\r
+\r
+typedef struct _WV_COMPLETION\r
+{\r
+ VOID* QpContext;\r
+ UINT64 WrId;\r
+ WV_OPCODE Opcode;\r
+ UINT32 Length;\r
+ UINT64 VendorCode;\r
+ HRESULT Status;\r
+\r
+ // Receive completion data\r
+ DWORD Flags;\r
+ UINT32 ImmediateData; // Network byte order\r
+ UINT32 SourceQpn; // Network byte order\r
+ UINT16 PkeyIndex;\r
+ UINT16 SLid; // Network byte order\r
+ UINT8 SL;\r
+ UINT8 DLidPathBits;\r
+\r
+} WV_COMPLETION;\r
+\r
+// Access flags\r
+#define WV_ACCESS_REMOTE_READ 0x00000001\r
+#define WV_ACCESS_REMOTE_WRITE 0x0000000A\r
+#define WV_ACCESS_REMOTE_ATOMIC 0x00000004\r
+#define WV_ACCESS_LOCAL_WRITE 0x00000008\r
+#define WV_ACCESS_MW_BIND 0x00000010\r
+\r
+// Send queue operation flags\r
+#define WV_SEND_IMMEDIATE 0X00000001\r
+#define WV_SEND_FENCE 0X00000002\r
+#define WV_SEND_SIGNALED 0X00000004\r
+#define WV_SEND_SOLICITED 0X00000008\r
+#define WV_SEND_INLINE 0X00000010\r
+\r
+typedef struct _WV_SGE\r
+{\r
+ VOID* pAddress;\r
+ SIZE_T Length;\r
+ UINT32 Lkey;\r
+\r
+} WV_SGE;\r
+\r
+typedef struct _WV_SEND_DATAGRAM\r
+{\r
+ UINT64 WrId;\r
+ interface IWVAddressHandle* pAddressHandle;\r
+\r
+ WV_SGE* pSgl;\r
+ SIZE_T nSge;\r
+ DWORD Flags;\r
+ UINT32 ImmediateData; // Network byte order\r
+ UINT32 DestinationQpn; // Network byte order\r
+ UINT32 DestinationQkey; // Network byte order\r
+ UINT16 PkeyIndex;\r
+\r
+} WV_SEND_DATAGRAM;\r
+\r
+typedef struct _WV_GRH\r
+{\r
+ UINT32 VersionClassFlow;\r
+ UINT16 Reserved1;\r
+ UINT8 Reserved2;\r
+ UINT8 HopLimit;\r
+ WV_GID SGid;\r
+ WV_GID DGid;\r
+\r
+} WV_GRH;\r
+\r
+typedef struct _WV_ADDRESS_VECTOR\r
+{\r
+ WV_GRH Grh;\r
+ BOOL GrhValid;\r
+ UINT16 DLid; // Network byte order\r
+ UINT8 ServiceLevel;\r
+ UINT8 SourcePathBits;\r
+ UINT8 StaticRate;\r
+ UINT8 PortNumber;\r
+\r
+} WV_ADDRESS_VECTOR;\r
+\r
+typedef enum _WV_QP_TYPE\r
+{\r
+ WvQpTypeRc,\r
+ WvQpTypeUc,\r
+ WvQpTypeReserved,\r
+ WvQpTypeUd\r
+\r
+} WV_QP_TYPE;\r
+\r
+typedef enum _WV_QP_STATE\r
+{\r
+ WvQpStateReset = (1 << 0),\r
+ WvQpStateInit = (1 << 1),\r
+ WvQpStateRtr = (1 << 2),\r
+ WvQpStateRts = (1 << 3),\r
+ WvQpStateSqd = (1 << 4),\r
+ WvQpStateSqdDraining = WvQpStateSqd | (1 << 5),\r
+ WvQpStateSqdDrained = WvQpStateSqd | (1 << 6),\r
+ WvQpStateSqerr = (1 << 7),\r
+ WvQpStateError = (1 << 8),\r
+ WvQpStateTimeWait = 0xdead0000\r
+\r
+} WV_QP_STATE;\r
+\r
+typedef enum _WV_APM_STATE\r
+{\r
+ WvApmMigrated = 1,\r
+ WvApmRearm,\r
+ WvApmArmed\r
+\r
+} WV_APM_STATE;\r
+\r
+typedef struct _WV_QP_CREATE\r
+{\r
+ interface IWVCompletionQueue* pSendCq;\r
+ interface IWVCompletionQueue* pReceiveCq;\r
+ interface IWVSharedReceiveQueue* pSharedReceiveQueue;\r
+ VOID* Context;\r
+\r
+ SIZE_T SendDepth;\r
+ SIZE_T SendSge;\r
+ SIZE_T ReceiveDepth;\r
+ SIZE_T ReceiveSge;\r
+ SIZE_T MaxInlineSend;\r
+ SIZE_T InitiatorDepth;\r
+ SIZE_T ResponderResources;\r
+\r
+ WV_QP_TYPE QpType;\r
+ BOOL SignalSends;\r
+\r
+} WV_QP_CREATE;\r
+\r
+// QP attribute mask\r
+#define WV_QP_ATTR_STATE 0x00000001\r
+#define WV_QP_ATTR_CURRENT_STATE 0x00000002\r
+#define WV_QP_ATTR_ENABLE_SQD_ASYNC_NOTIFY 0x00000004\r
+#define WV_QP_ATTR_ACCESS_FLAGS 0x00000008\r
+#define WV_QP_ATTR_PKEY_INDEX 0x00000010\r
+#define WV_QP_ATTR_PORT 0x00000020\r
+#define WV_QP_ATTR_QKEY 0x00000040\r
+#define WV_QP_ATTR_AV 0x00000080\r
+#define WV_QP_ATTR_PATH_MTU 0x00000100\r
+#define WV_QP_ATTR_TIMEOUT 0x00000200\r
+#define WV_QP_ATTR_RETRY_COUNT 0x00000400\r
+#define WV_QP_ATTR_RNR_RETRY 0x00000800\r
+#define WV_QP_ATTR_RQ_PSN 0x00001000\r
+#define WV_QP_ATTR_INITIATOR_DEPTH 0x00002000\r
+#define WV_QP_ATTR_ALTERNATE_AV 0x00004000\r
+#define WV_QP_ATTR_MIN_RNR_TIMER 0x00008000\r
+#define WV_QP_ATTR_SQ_PSN 0x00010000\r
+#define WV_QP_ATTR_RESPONDER_RESOURCES 0x00020000\r
+#define WV_QP_ATTR_PATH_MIG_STATE 0x00040000\r
+#define WV_QP_ATTR_CAPABILITIES 0x00080000\r
+#define WV_QP_ATTR_DESTINATION_QPN 0x00100000\r
+\r
+typedef struct _WV_QP_ATTRIBUTES\r
+{\r
+ interface IWVProtectionDomain* pPd;\r
+ interface IWVCompletionQueue* pSendCq;\r
+ interface IWVCompletionQueue* pReceiveCq;\r
+ interface IWVSharedReceiveQueue* pSharedReceiveQueue;\r
+\r
+ SIZE_T SendDepth;\r
+ SIZE_T SendSge;\r
+ SIZE_T ReceiveDepth;\r
+ SIZE_T ReceiveSge;\r
+ SIZE_T MaxInlineSend;\r
+ SIZE_T InitiatorDepth;\r
+ SIZE_T ResponderResources;\r
+\r
+ WV_QP_TYPE QpType;\r
+ WV_QP_STATE CurrentQpState;\r
+ WV_QP_STATE QpState;\r
+ WV_APM_STATE ApmState;\r
+ UINT32 Qpn; // Network byte order\r
+ UINT32 DestinationQpn; // Network byte order\r
+ UINT32 Qkey; // Network byte order\r
+ UINT32 SendPsn; // Network byte order\r
+ UINT32 ReceivePsn; // Network byte order\r
+\r
+ WV_ADDRESS_VECTOR PrimaryAddressVector;\r
+ WV_ADDRESS_VECTOR AlternateAddressVector;\r
+ DWORD AccessFlags;\r
+ BOOL SignalSends;\r
+ UINT16 PkeyIndex;\r
+\r
+ UINT8 PathMtu;\r
+ UINT8 LocalAckTimeout;\r
+ UINT8 SequenceErrorRetryCount;\r
+ UINT8 RnrRetryCount;\r
+\r
+} WV_QP_ATTRIBUTES;\r
+\r
+#define WV_CM_UDP_QKEY 0x01234567\r
+\r
+#pragma warning(push)\r
+#pragma warning(disable: 4200) \r
+typedef struct _WV_CONNECT_PARAM\r
+{\r
+ SIZE_T DataLength;\r
+ SIZE_T ResponderResources;\r
+ SIZE_T InitiatorDepth;\r
+ UINT8 RetryCount; // Ignored when accepting\r
+ UINT8 RnrRetryCount;\r
+ UINT8 Reserved[2];\r
+ UINT8 Data[];\r
+\r
+} WV_CONNECT_PARAM;\r
+\r
+typedef struct _WV_DATAGRAM_PARAM\r
+{\r
+ SIZE_T DataLength;\r
+ WV_ADDRESS_VECTOR AddressVector;\r
+ UINT32 Qpn;\r
+ UINT32 Qkey;\r
+ UINT8 Data[];\r
+\r
+} WV_DATAGRAM_PARAM;\r
+#pragma warning(pop)\r
+\r
+typedef struct _WV_CONNECT_ATTRIBUTES\r
+{\r
+ WV_ADDRESS LocalAddress;\r
+ SOCKET_ADDRESS PeerAddress;\r
+ WV_CONNECT_PARAM Param;\r
+\r
+} WV_CONNECT_ATTRIBUTES;\r
+\r
+typedef struct _WV_DATAGRAM_ATTRIBUTES\r
+{\r
+ WV_ADDRESS LocalAddress;\r
+ SOCKET_ADDRESS PeerAddress; // Specify when querying\r
+ WV_DATAGRAM_PARAM Param;\r
+\r
+} WV_DATAGRAM_ATTRIBUTES;\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVOverlapped\r
+// {64687592-aa67-4b55-bc4b-e189bdd2fc4f}\r
+DEFINE_GUID(IID_IWVOverlapped, 0x64687592, 0xaa67, 0x4b55,\r
+ 0xbc, 0x4b, 0xe1, 0x89, 0xbd, 0xd2, 0xfc, 0x4f);\r
+\r
+DECLARE_INTERFACE_(IWVOverlapped, IUnknown)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVCompletionQueue\r
+// {a5f6a8de-18a6-4086-aa93-7b66607a290a}\r
+DEFINE_GUID(IID_IWVCompletionQueue, 0xa5f6a8de, 0x18a6, 0x4086,\r
+ 0xaa, 0x93, 0x7b, 0x66, 0x60, 0x7a, 0x29, 0x0a);\r
+\r
+DECLARE_INTERFACE_(IWVCompletionQueue, IWVOverlapped)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVCompletionQueue methods\r
+ STDMETHOD(Resize)(\r
+ THIS_\r
+ __inout SIZE_T* pEntries\r
+ ) PURE;\r
+\r
+ STDMETHOD(Peek)(\r
+ THIS_\r
+ __out SIZE_T* pCompletedEntries\r
+ ) PURE;\r
+\r
+ STDMETHOD(Notify)(\r
+ THIS_\r
+ __in WV_CQ_NOTIFY_TYPE Type,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(BatchNotify)(\r
+ THIS_\r
+ __in SIZE_T CompletedEntries,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD_(SIZE_T,Poll)(\r
+ THIS_\r
+ __inout_ecount(Entries) WV_COMPLETION* pCompletions[],\r
+ __in SIZE_T Entries\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVMemoryWindow\r
+// {e8ae206f-b31f-4709-8dc9-6e87625f93fc}\r
+DEFINE_GUID(IID_IWVMemoryWindow, 0xe8ae206f, 0xb31f, 0x4709,\r
+ 0x8d, 0xc9, 0x6e, 0x87, 0x62, 0x5f, 0x93, 0xfc);\r
+\r
+DECLARE_INTERFACE_(IWVMemoryWindow, IUnknown)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVAddressHandle\r
+// {95903fde-fdac-4007-92b7-e01286cd36e8}\r
+DEFINE_GUID(IID_IWVAddressHandle, 0x95903fde, 0xfdac, 0x4007,\r
+ 0x92, 0xb7, 0xe0, 0x12, 0x86, 0xcd, 0x36, 0xe8);\r
+\r
+DECLARE_INTERFACE_(IWVAddressHandle, IUnknown)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVSharedReceiveQueue\r
+// {b2bf30e4-8c2e-4659-ac7a-4c5e0d2c7114}\r
+DEFINE_GUID(IID_IWVSharedReceiveQueue, 0xb2bf30e4, 0x8c2e, 0x4659,\r
+ 0xac, 0x7a, 0x4c, 0x5e, 0x0d, 0x2c, 0x71, 0x14);\r
+\r
+DECLARE_INTERFACE_(IWVSharedReceiveQueue, IWVOverlapped)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVSharedReceiveQueue methods\r
+ STDMETHOD(Query)(\r
+ THIS_\r
+ __out SIZE_T* pMaxWr,\r
+ __out SIZE_T* pMaxSge,\r
+ __out SIZE_T* pSrqLimit\r
+ ) PURE;\r
+\r
+ STDMETHOD(Modify)(\r
+ THIS_\r
+ __in SIZE_T MaxWr,\r
+ __in SIZE_T SrqLimit\r
+ ) PURE;\r
+\r
+ STDMETHOD(PostReceive)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in_ecount(nSge) const WV_SGE* pSgl,\r
+ __in SIZE_T nSge\r
+ ) PURE;\r
+\r
+ /* Signaled on limit reached event */\r
+ STDMETHOD(Notify)(\r
+ THIS_\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVQueuePair\r
+// {a847c13c-e617-489c-b0ab-2da73eb0adfd}\r
+DEFINE_GUID(IID_IWVQueuePair, 0xa847c13c, 0xe617, 0x489c,\r
+ 0xb0, 0xab, 0x2d, 0xa7, 0x3e, 0xb0, 0xad, 0xfd);\r
+\r
+DECLARE_INTERFACE_(IWVQueuePair, IWVOverlapped)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVQueuePair methods\r
+ STDMETHOD(Query)(\r
+ THIS_\r
+ __out WV_QP_ATTRIBUTES* pAttributes\r
+ ) PURE;\r
+\r
+ STDMETHOD(Modify)(\r
+ THIS_\r
+ __in WV_QP_ATTRIBUTES* pAttributes,\r
+ __in DWORD Options,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(PostReceive)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in_ecount(nSge) const WV_SGE* pSgl,\r
+ __in SIZE_T nSge\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVConnectQueuePair\r
+// {A791309C-4244-4194-AD63-7D372CADE5E0}\r
+DEFINE_GUID(IID_IWVConnectQueuePair, 0xa791309c, 0x4244, 0x4194,\r
+ 0xad, 0x63, 0x7d, 0x37, 0x2c, 0xad, 0xe5, 0xe0);\r
+\r
+DECLARE_INTERFACE_(IWVConnectQueuePair, IWVQueuePair)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVQueuePair methods\r
+ STDMETHOD(Query)(\r
+ THIS_\r
+ __out WV_QP_ATTRIBUTES* pAttributes\r
+ ) PURE;\r
+\r
+ STDMETHOD(Modify)(\r
+ THIS_\r
+ __in WV_QP_ATTRIBUTES* pAttributes,\r
+ __in DWORD Options,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(PostReceive)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in_ecount(nSge) const WV_SGE* pSgl,\r
+ __in SIZE_T nSge\r
+ ) PURE;\r
+\r
+ // IWVConnectQueuePair methods\r
+ STDMETHOD(Send)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in_ecount(nSge) const WV_SGE* pSgl,\r
+ __in SIZE_T nSge,\r
+ __in DWORD Flags,\r
+ __in UINT32 ImmediateData\r
+ ) PURE;\r
+\r
+ STDMETHOD(Read)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in_ecount(nSge) const WV_SGE* pSgl,\r
+ __in SIZE_T nSge,\r
+ __in DWORD Flags,\r
+ __in UINT64 Address,\r
+ __in UINT32 Rkey\r
+ ) PURE;\r
+\r
+ STDMETHOD(Write)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in_ecount(nSge) const WV_SGE* pSgl,\r
+ __in SIZE_T nSge,\r
+ __in DWORD Flags,\r
+ __in UINT32 ImmediateData,\r
+ __in UINT64 Address,\r
+ __in UINT32 Rkey\r
+ ) PURE;\r
+\r
+ STDMETHOD(CompareExchange)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in const WV_SGE* pSge,\r
+ __in DWORD Flags,\r
+ __in UINT64 Compare,\r
+ __in UINT64 Exchange,\r
+ __in UINT64 Address,\r
+ __in UINT32 Rkey\r
+ ) PURE;\r
+\r
+ STDMETHOD(FetchAdd)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in const WV_SGE* pSge,\r
+ __in DWORD Flags,\r
+ __in UINT64 Value,\r
+ __in UINT64 Address,\r
+ __in UINT32 Rkey\r
+ ) PURE;\r
+\r
+ STDMETHOD(BindMemoryWindow)(\r
+ THIS_\r
+ __in IWVMemoryWindow* pMw,\r
+ __in UINT64 WrId,\r
+ __in UINT32 Lkey,\r
+ __in DWORD AccessFlags,\r
+ __in DWORD SendFlags,\r
+ __in_bcount(BufferLength) const VOID* pBuffer,\r
+ __in SIZE_T BufferLength,\r
+ __out UINT32 *pRkey\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVDatagramQueuePair\r
+// {3BA2F15E-D961-4df8-8FC2-6043A6D67826}\r
+DEFINE_GUID(IID_IWVDatagramQueuePair, 0x3ba2f15e, 0xd961, 0x4df8,\r
+ 0x8f, 0xc2, 0x60, 0x43, 0xa6, 0xd6, 0x78, 0x26);\r
+\r
+DECLARE_INTERFACE_(IWVDatagramQueuePair, IWVQueuePair)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVQueuePair methods\r
+ STDMETHOD(Query)(\r
+ THIS_\r
+ __out WV_QP_ATTRIBUTES* pAttributes\r
+ ) PURE;\r
+\r
+ STDMETHOD(Modify)(\r
+ THIS_\r
+ __in WV_QP_ATTRIBUTES* pAttributes,\r
+ __in DWORD Options,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(PostReceive)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in_ecount(nSge) const WV_SGE* pSgl,\r
+ __in SIZE_T nSge\r
+ ) PURE;\r
+\r
+ // IWVDatagramQueuePair Methods\r
+ STDMETHOD(Send)(\r
+ THIS_\r
+ __in UINT64 WrId,\r
+ __in IWVAddressHandle* pAddressHandle,\r
+ __in WV_SGE* pSge,\r
+ __in DWORD Flags,\r
+ __in UINT32 DestinationQpn,\r
+ __in UINT32 DestinationQkey,\r
+ __in UINT16 PkeyIndex\r
+ ) PURE;\r
+\r
+ STDMETHOD(SendMessage)(\r
+ THIS_\r
+ __in WV_SEND_DATAGRAM* pSend\r
+ ) PURE;\r
+\r
+ STDMETHOD(AttachMulticast)(\r
+ THIS_\r
+ __in WV_GID *pGid,\r
+ __in UINT16 Lid\r
+ ) PURE;\r
+\r
+ STDMETHOD(DetachMulticast)(\r
+ THIS_\r
+ __in WV_GID *pGid,\r
+ __in UINT16 Lid\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVProtectionDomain\r
+// {a5633a12-dffc-4060-927d-9a600d7efb63}\r
+DEFINE_GUID(IID_IWVProtectionDomain, 0xa5633a12, 0xdffc, 0x4060,\r
+ 0x92, 0x7d, 0x9a, 0x60, 0x0d, 0x7e, 0xfb, 0x63);\r
+\r
+DECLARE_INTERFACE_(IWVProtectionDomain, IUnknown)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVProtectionDomain methods\r
+ STDMETHOD(CreateSharedReceiveQueue)(\r
+ THIS_\r
+ __in SIZE_T MaxWr,\r
+ __in SIZE_T MaxSge,\r
+ __in SIZE_T SrqLimit,\r
+ __deref_out IWVSharedReceiveQueue** ppSrq\r
+ ) PURE;\r
+\r
+ STDMETHOD(CreateQueuePair)(\r
+ THIS_\r
+ __in WV_QP_CREATE* pAttributes,\r
+ __deref_out IWVQueuePair** ppQp\r
+ ) PURE;\r
+\r
+ STDMETHOD(RegisterMemory)(\r
+ THIS_\r
+ __in_bcount(BufferLength) const VOID* pBuffer,\r
+ __in SIZE_T BufferLength,\r
+ __in DWORD AccessFlags,\r
+ __in OVERLAPPED* pOverlapped,\r
+ __out UINT32* pLkey,\r
+ __out UINT32* pRkey\r
+ ) PURE;\r
+\r
+ STDMETHOD(DeregisterMemory)(\r
+ THIS_\r
+ __in UINT32 Lkey,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(AllocateMemoryWindow)(\r
+ THIS_\r
+ __deref_out IWVMemoryWindow** ppMw\r
+ ) PURE;\r
+\r
+ STDMETHOD(CreateAddressHandle)(\r
+ THIS_\r
+ __in WV_ADDRESS_VECTOR* pAddress,\r
+ __deref_out IWVAddressHandle** ppAh\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVEndpoint\r
+// {eb2fbd8e-b9b6-4b24-9a5e-94c26ae265f0}\r
+DEFINE_GUID(IID_IWVEndpoint, 0xeb2fbd8e, 0xb9b6, 0x4b24,\r
+ 0x9a, 0x5e, 0x94, 0xc2, 0x6a, 0xe2, 0x65, 0xf0);\r
+\r
+DECLARE_INTERFACE_(IWVEndpoint, IWVOverlapped)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVEndpoint methods\r
+ STDMETHOD(BindAddress)(\r
+ THIS_\r
+ __in const struct sockaddr* pAddress\r
+ ) PURE;\r
+\r
+ STDMETHOD(Reject)(\r
+ THIS_\r
+ __in_bcount_opt(PrivateDataLength) const VOID* pPrivateData,\r
+ __in SIZE_T PrivateDataLength\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVConnectEndpoint\r
+// {ac670274-1934-4759-a39c-eee01a8130b3}\r
+DEFINE_GUID(IID_IWVConnectEndpoint, 0xac670274, 0x1934, 0x4759,\r
+ 0xa3, 0x9c, 0xee, 0xe0, 0x1a, 0x81, 0x30, 0xb3);\r
+\r
+DECLARE_INTERFACE_(IWVConnectEndpoint, IWVEndpoint)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVEndpoint methods\r
+ __override STDMETHOD(BindAddress)(\r
+ THIS_\r
+ __in const struct sockaddr* pAddress\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(Reject)(\r
+ THIS_\r
+ __in_bcount_opt(PrivateDataLength) const VOID* pPrivateData,\r
+ __in SIZE_T PrivateDataLength\r
+ ) PURE;\r
+\r
+ // IWVConnectEndpoint methods\r
+ STDMETHOD(Connect)(\r
+ THIS_\r
+ __in IWVConnectQueuePair* pQp,\r
+ __in WV_CONNECT_PARAM* pParam,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(Accept)(\r
+ THIS_\r
+ __in IWVConnectQueuePair* pQp,\r
+ __in WV_CONNECT_PARAM* pParam,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(Disconnect)(\r
+ THIS_\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(NotifyDisconnect)(\r
+ THIS_\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(Query)(\r
+ THIS_\r
+ __out WV_CONNECT_ATTRIBUTES* pAttributes\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVDatagramEndpoint\r
+// {1d879de6-f2af-4a8a-8893-52e0ab868130}\r
+DEFINE_GUID(IID_IWVDatagramEndpoint, 0x1d879de6, 0xf2af, 0x4a8a,\r
+ 0x88, 0x93, 0x52, 0xe0, 0xab, 0x86, 0x81, 0x30);\r
+\r
+DECLARE_INTERFACE_(IWVDatagramEndpoint, IWVEndpoint)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVEndpoint methods\r
+ __override STDMETHOD(BindAddress)(\r
+ THIS_\r
+ __in const struct sockaddr* pAddress\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(Reject)(\r
+ THIS_\r
+ __in_bcount_opt(PrivateDataLength) const VOID* pPrivateData,\r
+ __in SIZE_T PrivateDataLength\r
+ ) PURE;\r
+\r
+ // IWVDatagramEndpoint methods\r
+ STDMETHOD(Lookup)(\r
+ THIS_\r
+ __in_bcount_opt(PrivateDataLength) const VOID* pPrivateData,\r
+ __in SIZE_T PrivateDataLength,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(Accept)(\r
+ THIS_\r
+ __in WV_DATAGRAM_PARAM* pParam,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(JoinMulticast)(\r
+ THIS_\r
+ __in const struct sockaddr* pAddress,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(LeaveMulticast)(\r
+ THIS_\r
+ __in const struct sockaddr* pAddress,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+\r
+ STDMETHOD(Query)(\r
+ THIS_\r
+ __inout WV_DATAGRAM_ATTRIBUTES* pAttributes\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVListen\r
+// {5b839fd4-7410-441f-a2d9-5d75b1d8599b}\r
+DEFINE_GUID(IID_IWVListen, 0x5b839fd4, 0x7410, 0x441f,\r
+ 0xa2, 0xd9, 0x5d, 0x75, 0xb1, 0xd8, 0x59, 0x9b);\r
+\r
+DECLARE_INTERFACE_(IWVListen, IWVOverlapped)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVListen methods\r
+ STDMETHOD(GetRequest)(\r
+ THIS_\r
+ __in IWVEndpoint* pEndpoint,\r
+ __in OVERLAPPED* pOverlapped\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVDevice\r
+// {244af78c-b1ac-40e4-9896-271d58d591b8}\r
+DEFINE_GUID(IID_IWVDevice, 0x244af78c, 0xb1ac, 0x40e4,\r
+ 0x98, 0x96, 0x27, 0x1d, 0x58, 0xd5, 0x91, 0xb8);\r
+\r
+DECLARE_INTERFACE_(IWVDevice, IWVOverlapped)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVOverlapped methods\r
+ __override STDMETHOD(CancelOverlappedRequests)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD(GetOverlappedResult)(\r
+ THIS_\r
+ __inout_opt OVERLAPPED *pOverlapped,\r
+ __out SIZE_T *pNumberOfBytesTransferred,\r
+ __in BOOL bWait\r
+ ) PURE;\r
+\r
+ // IWVDevice methods\r
+ STDMETHOD(Query)(\r
+ THIS_\r
+ __out WV_DEVICE_ATTRIBUTES* pAttributes\r
+ ) PURE;\r
+\r
+ STDMETHOD(QueryPort)(\r
+ THIS_\r
+ __in UINT8 PortNumber,\r
+ __out WV_PORT_ATTRIBUTES* pAttributes\r
+ ) PURE;\r
+\r
+ STDMETHOD(QueryGid)(\r
+ THIS_\r
+ __in UINT8 PortNumber,\r
+ __in DWORD Index,\r
+ __out WV_GID* pGid\r
+ ) PURE;\r
+\r
+ STDMETHOD(QueryPkey)(\r
+ THIS_\r
+ __in UINT8 PortNumber,\r
+ __in DWORD Index,\r
+ __out UINT16* pPkey\r
+ ) PURE;\r
+\r
+ STDMETHOD(CreateCompletionQueue)(\r
+ THIS_\r
+ __inout SIZE_T *pEntries,\r
+ __deref_out IWVCompletionQueue** ppCq\r
+ ) PURE;\r
+\r
+ STDMETHOD(AllocateProtectionDomain)(\r
+ THIS_\r
+ __deref_out IWVProtectionDomain** ppPd\r
+ ) PURE;\r
+\r
+ STDMETHOD(Notify)(\r
+ THIS_\r
+ __in OVERLAPPED* pOverlapped,\r
+ __out WV_EVENT* pEvent\r
+ ) PURE;\r
+};\r
+\r
+\r
+#undef INTERFACE\r
+#define INTERFACE IWVProvider\r
+// {6901010c-17af-4894-a1dc-794d3611f262}\r
+DEFINE_GUID(IID_IWVProvider, 0x6901010c, 0x17af, 0x4894,\r
+ 0xa1, 0xdc, 0x79, 0x4d, 0x36, 0x11, 0xf2, 0x62);\r
+\r
+DECLARE_INTERFACE_(IWVProvider, IUnknown)\r
+{\r
+ // IUnknown methods\r
+ __override STDMETHOD(QueryInterface)(\r
+ THIS_\r
+ REFIID riid,\r
+ LPVOID FAR* ppvObj\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,AddRef)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ __override STDMETHOD_(ULONG,Release)(\r
+ THIS\r
+ ) PURE;\r
+\r
+ // IWVProvider methods\r
+ STDMETHOD(QueryDeviceList)(\r
+ THIS_\r
+ __inout_bcount_part_opt(*pBufferSize, *pBufferSize) UINT64* pGuidList,\r
+ __inout SIZE_T* pBufferSize\r
+ ) PURE;\r
+\r
+ STDMETHOD(QueryDevice)(\r
+ THIS_\r
+ __in UINT64 Guid,\r
+ __out WV_DEVICE_ATTRIBUTES* pAttributes\r
+ ) PURE;\r
+\r
+ STDMETHOD(QueryAddressList)(\r
+ THIS_\r
+ __inout_bcount_part_opt(*pBufferSize, *pBufferSize) WV_ADDRESS_LIST* pAddressList,\r
+ __inout SIZE_T* pBufferSize\r
+ ) PURE;\r
+\r
+ STDMETHOD(OpenDevice)(\r
+ THIS_\r
+ __in UINT64 Guid,\r
+ __deref_out IWVDevice** ppDevice\r
+ ) PURE;\r
+\r
+ STDMETHOD(CreateConnectEndpoint)(\r
+ THIS_\r
+ __deref_out IWVConnectEndpoint** ppConnectEndpoint\r
+ ) PURE;\r
+\r
+ STDMETHOD(CreateDatagramEndpoint)(\r
+ THIS_\r
+ __deref_out IWVDatagramEndpoint** ppDatagramEndpoint\r
+ ) PURE;\r
+\r
+ STDMETHOD(CreateListen)(\r
+ THIS_\r
+ __in const struct sockaddr* pAddress,\r
+ __in SIZE_T Backlog,\r
+ __deref_out IWVListen** ppListen\r
+ ) PURE;\r
+};\r
+\r
+#endif // _WINVERBS_H_\r
--- /dev/null
+/*\r
+ * Copyright (c) 2008 Intel Corporation. All rights reserved. \r
+ *\r
+ * This software is available to you under the OpenIB.org BSD license\r
+ * below:\r
+ *\r
+ * Redistribution and use in source and binary forms, with or\r
+ * without modification, are permitted provided that the following\r
+ * conditions are met:\r
+ *\r
+ * - Redistributions of source code must retain the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer.\r
+ *\r
+ * - Redistributions in binary form must reproduce the above\r
+ * copyright notice, this list of conditions and the following\r
+ * disclaimer in the documentation and/or other materials\r
+ * provided with the distribution.\r
+ *\r
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\r
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\r
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\r
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r
+ * SOFTWARE.\r
+ */\r
+\r
+#pragma once\r
+\r
+#ifndef _WVSTATUS_H_\r
+#define _WVSTATUS_H_\r
+\r
+//\r
+// Values are 32 bit values laid out as follows:\r
+//\r
+// 3 3 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 1 1 1 1\r
+// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0\r
+// +---+-+-+-----------------------+-------------------------------+\r
+// |Sev|C|R| Facility | Code |\r
+// +---+-+-+-----------------------+-------------------------------+\r
+//\r
+// where\r
+//\r
+// Sev - is the severity code\r
+//\r
+// 00 - Success\r
+// 01 - Informational\r
+// 10 - Warning\r
+// 11 - Error\r
+//\r
+// C - is the Customer code flag\r
+//\r
+// R - is a reserved bit\r
+//\r
+// Facility - is the facility code\r
+//\r
+// Code - is the facility's status code\r
+//\r
+//\r
+// Define the facility codes\r
+//\r
+#define FACILITY_WINVERBS 0x38\r
+\r
+\r
+//\r
+// Define the severity codes\r
+//\r
+#define STATUS_SEVERITY_WARNING 0x2\r
+#define STATUS_SEVERITY_SUCCESS 0x0\r
+#define STATUS_SEVERITY_INFORMATIONAL 0x1\r
+#define STATUS_SEVERITY_ERROR 0x3\r
+\r
+\r
+//\r
+// Values map to NTSTATUS and NDSTATUS where possible\r
+//\r
+#define WV_SUCCESS ((HRESULT)0x00000000L)\r
+#define WV_TIMEOUT ((HRESULT)0x00000102L)\r
+#define WV_PENDING ((HRESULT)0x00000103L)\r
+#define WV_BUFFER_OVERFLOW ((HRESULT)0x80000005L)\r
+#define WV_DEVICE_BUSY ((HRESULT)0x80000011L)\r
+#define WV_NO_MORE_ENTRIES ((HRESULT)0x8000001AL)\r
+#define WV_UNSUCCESSFUL ((HRESULT)0xC0000001L)\r
+#define WV_ACCESS_VIOLATION ((HRESULT)0xC0000005L)\r
+#define WV_INVALID_HANDLE ((HRESULT)0xC0000008L)\r
+#define WV_INVALID_PARAMETER ((HRESULT)0xC000000DL)\r
+#define WV_NO_MEMORY ((HRESULT)0xC0000017L)\r
+#define WV_INVALID_PARAMETER_MIX ((HRESULT)0xC0000030L)\r
+#define WV_DATA_OVERRUN ((HRESULT)0xC000003CL)\r
+#define WV_INSUFFICIENT_RESOURCES ((HRESULT)0xC000009AL)\r
+#define WV_NOT_INITIALIZED ((HRESULT)0xC00000A3L)\r
+#define WV_NOT_SUPPORTED ((HRESULT)0xC00000BBL)\r
+#define WV_INTERNAL_ERROR ((HRESULT)0xC00000E5L)\r
+#define WV_INVALID_PARAMETER_1 ((HRESULT)0xC00000EFL)\r
+#define WV_INVALID_PARAMETER_2 ((HRESULT)0xC00000F0L)\r
+#define WV_INVALID_PARAMETER_3 ((HRESULT)0xC00000F1L)\r
+#define WV_INVALID_PARAMETER_4 ((HRESULT)0xC00000F2L)\r
+#define WV_INVALID_PARAMETER_5 ((HRESULT)0xC00000F3L)\r
+#define WV_INVALID_PARAMETER_6 ((HRESULT)0xC00000F4L)\r
+#define WV_INVALID_PARAMETER_7 ((HRESULT)0xC00000F5L)\r
+#define WV_INVALID_PARAMETER_8 ((HRESULT)0xC00000F6L)\r
+#define WV_INVALID_PARAMETER_9 ((HRESULT)0xC00000F7L)\r
+#define WV_INVALID_PARAMETER_10 ((HRESULT)0xC00000F8L)\r
+#define WV_CANCELLED ((HRESULT)0xC0000120L)\r
+#define WV_REMOTE_ERROR ((HRESULT)0xC000013DL)\r
+#define WV_INVALID_ADDRESS ((HRESULT)0xC0000141L)\r
+#define WV_ADDRESS_ALREADY_EXISTS ((HRESULT)0xC000020AL)\r
+#define WV_CONNECTION_REFUSED ((HRESULT)0xC0000236L)\r
+#define WV_CONNECTION_INVALID ((HRESULT)0xC000023AL)\r
+#define WV_CONNECTION_ACTIVE ((HRESULT)0xC000023BL)\r
+#define WV_HOST_UNREACHABLE ((HRESULT)0xC000023DL)\r
+#define WV_CONNECTION_ABORTED ((HRESULT)0xC0000241L)\r
+#define WV_DEVICE_REMOVED ((HRESULT)0xC00002B6L)\r
+#define WV_LOCAL_LENGTH ((HRESULT)0xC0380001L)\r
+#define WV_INVALIDATION_ERROR ((HRESULT)0xC0380002L)\r
+#define WV_LOCAL_OP_ERROR ((HRESULT)0xC0380003L)\r
+#define WV_LOCAL_PROTECTION_ERROR ((HRESULT)0xC0380004L)\r
+#define WV_WR_FLUSHED_ERROR ((HRESULT)0xC0380005L)\r
+#define WV_BIND_WINDOW_ERROR ((HRESULT)0xC0380006L)\r
+#define WV_REMOTE_ACCESS_ERROR ((HRESULT)0xC0380007L)\r
+#define WV_REMOTE_OP_ERROR ((HRESULT)0xC0380008L)\r
+#define WV_RNR_RETRY_ERROR ((HRESULT)0xC0380009L)\r
+#define WV_TIMEOUT_RETRY_ERROR ((HRESULT)0xC038000AL)\r
+#define WV_REMOTE_INVALID_REQUEST_ERROR ((HRESULT)0xC038000BL)\r
+#define WV_BAD_RESPONSE_ERROR ((HRESULT)0xC038000CL)\r
+#define WV_LOCAL_ACCESS_ERROR ((HRESULT)0xC038000DL)\r
+#define WV_UNKNOWN_ERROR ((HRESULT)0xC038000EL)\r
+\r
+#endif // _WVSTATUS_H_\r