[ofw] RE: [PATCH] ipoib
Leonid Keller
leonid at mellanox.co.il
Thu Apr 10 00:47:54 PDT 2008
As far as i remember, according to IB spec, only status and vendor error
fields are valid in an erroneous CQE.
So the customer can't count on the valid WR type field.
And this was the behavior of the low level driver in the first place.
I've changed it to return in WC all the information, found in CQE.
WQE is always accesible, because work_id is kept separately by the
driver and isn't influenced by failed CQE.
________________________________
From: ofw-bounces at lists.openfabrics.org
[mailto:ofw-bounces at lists.openfabrics.org] On Behalf Of Fab Tillier
Sent: Wednesday, April 09, 2008 7:54 PM
To: Reuven Amitai; ofw at lists.openfabrics.org
Subject: [ofw] RE: [PATCH] ipoib
Does this change imply that the HCA driver doesn't return the WR
type on an error completion? Does it really not have that information
(i.e. is the WQE no longer accessible)?
-Fab
From: ofw-bounces at lists.openfabrics.org
[mailto:ofw-bounces at lists.openfabrics.org] On Behalf Of Reuven Amitai
Sent: Wednesday, April 09, 2008 6:25 AM
To: ofw at lists.openfabrics.org
Subject: [ofw] [PATCH] ipoib
Hi,
the following patch fixes wrong status field.
Thanks, Reuven.
Index: ulp/ipoib/kernel/ipoib_port.c
===================================================================
--- ulp/ipoib/kernel/ipoib_port.c (revision 1047)
+++ ulp/ipoib/kernel/ipoib_port.c (working copy)
@@ -1854,7 +1854,7 @@
for( p_wc = p_done_wc_list; p_wc; p_wc = p_wc->p_next )
{
- CL_ASSERT( p_wc->wc_type == IB_WC_RECV );
+ CL_ASSERT( p_wc->status != IB_WCS_SUCCESS ||
p_wc->wc_type == IB_WC_RECV );
p_desc = (ipoib_recv_desc_t*)(uintn_t)p_wc->wr_id;
recv_cnt++;
@@ -3935,7 +3935,7 @@
while( p_wc )
{
cl_perf_start( SendComp );
- CL_ASSERT( p_wc->wc_type == IB_WC_SEND );
+ CL_ASSERT( p_wc->status != IB_WCS_SUCCESS ||
p_wc->wc_type == IB_WC_SEND );
p_packet = (NDIS_PACKET*)(uintn_t)p_wc->wr_id;
CL_ASSERT( p_packet );
CL_ASSERT( IPOIB_PORT_FROM_PACKET( p_packet )
== p_port );
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openfabrics.org/pipermail/ofw/attachments/20080410/742dffbe/attachment.html>
More information about the ofw
mailing list