[ofw] [PATCH 11/12] nd2: pass affinity information to CQ init

Hefty, Sean sean.hefty at intel.com
Tue Jul 27 00:55:31 PDT 2010


Carry processor affinity information through to Init call, so it's available
when supported by winverbs.

Signed-off-by: Sean Hefty <sean.hefty at intel.com>
---
 trunk/ulp/netdirect2/user/nd_adapter.cpp |    3 ++-
 trunk/ulp/netdirect2/user/nd_cq.cpp      |    2 +-
 trunk/ulp/netdirect2/user/nd_cq.h        |    7 ++++---
 3 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/trunk/ulp/netdirect2/user/nd_adapter.cpp b/trunk/ulp/netdirect2/user/nd_adapter.cpp
index 55fba91..a5977fa 100644
--- a/trunk/ulp/netdirect2/user/nd_adapter.cpp
+++ b/trunk/ulp/netdirect2/user/nd_adapter.cpp
@@ -171,7 +171,8 @@ STDMETHODIMP CNDAdapter::
 CreateCompletionQueue(REFIID iid, DWORD queueDepth, USHORT group, KAFFINITY affinity,
 					  VOID** ppCompletionQueue)
 {
-	return CNDCompletionQueue::CreateInstance(this, queueDepth, ppCompletionQueue);
+	return CNDCompletionQueue::CreateInstance(this, queueDepth, group,
+											  affinity, ppCompletionQueue);
 }
 
 STDMETHODIMP CNDAdapter::
diff --git a/trunk/ulp/netdirect2/user/nd_cq.cpp b/trunk/ulp/netdirect2/user/nd_cq.cpp
index be4b4bd..2d9d0d6 100644
--- a/trunk/ulp/netdirect2/user/nd_cq.cpp
+++ b/trunk/ulp/netdirect2/user/nd_cq.cpp
@@ -37,7 +37,7 @@ CNDCompletionQueue::CNDCompletionQueue(CNDAdapter *pAdapter)
 }
 
 STDMETHODIMP CNDCompletionQueue::
-Init(DWORD queueDepth)
+Init(DWORD queueDepth, USHORT group, KAFFINITY affinity)
 {
 	HRESULT hr;
 
diff --git a/trunk/ulp/netdirect2/user/nd_cq.h b/trunk/ulp/netdirect2/user/nd_cq.h
index fdadd98..8356854 100644
--- a/trunk/ulp/netdirect2/user/nd_cq.h
+++ b/trunk/ulp/netdirect2/user/nd_cq.h
@@ -59,7 +59,8 @@ public:
 	~CNDCompletionQueue();
 	void Delete() {delete this;}
 	static STDMETHODIMP
-	CreateInstance(CNDAdapter *pAdapter, DWORD queueDepth, VOID** ppCq)
+	CreateInstance(CNDAdapter *pAdapter, DWORD queueDepth, USHORT group,
+				   KAFFINITY affinity, VOID** ppCq)
 	{
 		HRESULT hr;
 		CNDCompletionQueue *cq;
@@ -70,7 +71,7 @@ public:
 			goto err1;
 		}
 
-		hr = cq->Init(queueDepth);
+		hr = cq->Init(queueDepth, group, affinity);
 		if (FAILED(hr)) {
 			goto err2;
 		}
@@ -89,7 +90,7 @@ public:
 
 protected:
 	CNDAdapter			*m_pAdapter;
-	STDMETHODIMP		Init(DWORD queueDepth);
+	STDMETHODIMP		Init(DWORD queueDepth, USHORT group, KAFFINITY affinity);
 	STDMETHODIMP_(HRESULT) ConvertStatus(WV_WC_STATUS Status);
 };
 




More information about the ofw mailing list