From: shefty Date: Thu, 24 Apr 2008 22:05:09 +0000 (+0000) Subject: winverbs: fix API issues X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=34a40fa0cd246cb0a4b7a0abf5acf210a9a160fc;p=~shefty%2Frdma-win.git winverbs: fix API issues The FwVersion should be UINT64, not a 64-byte array. The Lookup() method needs the remote address as input. Signed-off-by: Sean Hefty git-svn-id: svn://openib.tc.cornell.edu/gen1@1070 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86 --- diff --git a/branches/winverbs/core/winverbs/user/wv_device.cpp b/branches/winverbs/core/winverbs/user/wv_device.cpp index 7eb7fdea..6c04b326 100644 --- a/branches/winverbs/core/winverbs/user/wv_device.cpp +++ b/branches/winverbs/core/winverbs/user/wv_device.cpp @@ -203,7 +203,7 @@ Query(WV_DEVICE_ATTRIBUTES* pAttributes) return HRESULT_FROM_WIN32(GetLastError()); } - RtlCopyMemory(pAttributes->FwVersion, attr.FwVersion, 64); + pAttributes->FwVersion = attr.FwVersion; pAttributes->NodeGuid = attr.NodeGuid; pAttributes->SystemImageGuid = attr.SystemImageGuid; pAttributes->VendorId = attr.VendorId; diff --git a/branches/winverbs/core/winverbs/user/wv_ep.cpp b/branches/winverbs/core/winverbs/user/wv_ep.cpp index a9a1fa36..08aa587a 100644 --- a/branches/winverbs/core/winverbs/user/wv_ep.cpp +++ b/branches/winverbs/core/winverbs/user/wv_ep.cpp @@ -243,8 +243,10 @@ Reject(const VOID* pPrivateData, SIZE_T PrivateDataLength) } STDMETHODIMP CWVDatagramEndpoint:: -Lookup(const VOID* pPrivateData, SIZE_T PrivateDataLength, OVERLAPPED* pOverlapped) +Lookup(const struct sockaddr* pAddress, const VOID* pPrivateData, + SIZE_T PrivateDataLength, OVERLAPPED* pOverlapped) { + UNREFERENCED_PARAMETER(pAddress); UNREFERENCED_PARAMETER(pPrivateData); UNREFERENCED_PARAMETER(PrivateDataLength); UNREFERENCED_PARAMETER(pOverlapped); diff --git a/branches/winverbs/core/winverbs/user/wv_ep.h b/branches/winverbs/core/winverbs/user/wv_ep.h index 2ffd0e34..070fb034 100644 --- a/branches/winverbs/core/winverbs/user/wv_ep.h +++ b/branches/winverbs/core/winverbs/user/wv_ep.h @@ -110,8 +110,8 @@ public: STDMETHODIMP Reject(const VOID* pPrivateData, SIZE_T PrivateDataLength); // IWVDatagramEndpoint methods - STDMETHODIMP Lookup(const VOID* pPrivateData, SIZE_T PrivateDataLength, - OVERLAPPED* pOverlapped); + STDMETHODIMP Lookup(const struct sockaddr* pAddress, const VOID* pPrivateData, + SIZE_T PrivateDataLength, OVERLAPPED* pOverlapped); STDMETHODIMP Accept(WV_DATAGRAM_PARAM* pParam, OVERLAPPED* pOverlapped); STDMETHODIMP JoinMulticast(const struct sockaddr* pAddress, OVERLAPPED* pOverlapped); diff --git a/branches/winverbs/inc/user/rdma/winverbs.h b/branches/winverbs/inc/user/rdma/winverbs.h index 43dde397..87f5b938 100644 --- a/branches/winverbs/inc/user/rdma/winverbs.h +++ b/branches/winverbs/inc/user/rdma/winverbs.h @@ -71,7 +71,7 @@ typedef enum _WV_ATOMIC_CAPABILITIES typedef struct _WV_DEVICE_ATTRIBUTES { - UINT8 FwVersion[64]; + UINT64 FwVersion; UINT64 NodeGuid; UINT64 SystemImageGuid; UINT32 VendorId; @@ -1173,6 +1173,7 @@ DECLARE_INTERFACE_(IWVDatagramEndpoint, IWVEndpoint) // IWVDatagramEndpoint methods STDMETHOD(Lookup)( THIS_ + __in const struct sockaddr* pAddress, __in_bcount_opt(PrivateDataLength) const VOID* pPrivateData, __in SIZE_T PrivateDataLength, __in OVERLAPPED* pOverlapped