[ofw] RE: [patch] fix ipoib performance problem in rev 1430

Anatoly Greenblatt anatolyg at voltaire.com
Thu Aug 28 05:15:21 PDT 2008


Hi Fab,

You're right although some may say chksum on receive path is not needed
at all. Anyway, mthcd does not update csum_ok at all, therefore ndis
checksum flags have random value in each packet. Fix is attached.

Thanks,
Anatoly.

Index: hw/mthca/kernel/mthca_cq.c
===================================================================
--- hw/mthca/kernel/mthca_cq.c	(revision 1521)
+++ hw/mthca/kernel/mthca_cq.c	(working copy)
@@ -579,6 +579,7 @@
 		entry->recv.ud.path_bits =
(uint8_t)(cl_ntoh16(cqe->sl_g_mlpath) & 0x7f);
 		entry->recv.ud.recv_opt   |= cl_ntoh16(cqe->sl_g_mlpath)
& 0x80 ?
 					IB_RECV_OPT_GRH_VALID : 0;
+		entry->csum_ok = 0;
 	}
 	if (!is_send && cqe->rlid == 0){
 		HCA_PRINT(TRACE_LEVEL_INFORMATION,HCA_DBG_CQ,("found
rlid == 0 \n "));
Index: ulp/ipoib/kernel/ipoib_port.c
===================================================================
--- ulp/ipoib/kernel/ipoib_port.c	(revision 1521)
+++ ulp/ipoib/kernel/ipoib_port.c	(working copy)
@@ -3862,7 +3862,7 @@
 	p_desc->wr.p_next = NULL;
 	p_desc->wr.wr_id = (uintn_t)p_desc->p_pkt;
 
-	if(p_port->p_adapter->params.send_chksum_offload & 
+	if(p_port->p_adapter->params.send_chksum_offload && 
 		(pChecksumPktInfo->Transmit.NdisPacketChecksumV4 ||
pChecksumPktInfo->Transmit.NdisPacketChecksumV6))
 	{
 		// Set transimition checksum offloading
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix_ipoib_csum_offload_2.patch
Type: application/octet-stream
Size: 1118 bytes
Desc: fix_ipoib_csum_offload_2.patch
URL: <http://lists.openfabrics.org/pipermail/ofw/attachments/20080828/d8b3bc90/attachment.obj>


More information about the ofw mailing list