INCLUDES=..;..\..\..\inc;..\..\..\inc\kernel;\r
\r
C_DEFINES=$(C_DEFINES) -DNDIS_MINIPORT_DRIVER -DNDIS_WDM=1 \\r
- -DDEPRECATE_DDK_FUNCTIONS -DNDIS51_MINIPORT -DNEED_CL_OBJ -DBINARY_COMPATIBLE=0\r
+ -DDEPRECATE_DDK_FUNCTIONS -DNDIS51_MINIPORT -DNEED_CL_OBJ -DBINARY_COMPATIBLE=0 -DPERF_TRACK_ON\r
\r
TARGETLIBS= \\r
$(TARGETPATH)\*\complib.lib \\r
/*\r
* Macros\r
*/\r
-\r
+typedef enum \r
+{\r
+ CSUM_DISABLED = 0, \r
+ CSUM_ENABLED, \r
+ CSUM_BYPASS\r
+} csum_flag_t;\r
\r
typedef struct _ipoib_params\r
{\r
int32_t rq_depth;\r
int32_t rq_low_watermark;\r
int32_t sq_depth;\r
- boolean_t send_chksum_offload;\r
- boolean_t recv_chksum_offload;\r
+ csum_flag_t send_chksum_offload;\r
+ csum_flag_t recv_chksum_offload;\r
uint32_t sa_timeout;\r
uint32_t sa_retry_cnt;\r
uint32_t recv_pool_ratio;\r
IN ipoib_port_t* const p_port,\r
IN ipoib_endpt_t* const p_endpt )\r
{\r
- cm_state_t cm_state;\r
IPOIB_ENTER( IPOIB_DBG_ENDPT );\r
\r
if( !p_port || !p_endpt )\r
return;\r
\r
- cm_state = endpt_cm_set_state( p_endpt, IPOIB_CM_DESTROY );\r
- p_endpt->cm_flag = 0;\r
-\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION, IPOIB_DBG_ENDPT,\r
- ("Destroy Connected Endpt State: %d\n", cm_state ) );\r
-\r
cl_event_init( &p_endpt->remove_event, FALSE );\r
NdisInterlockedInsertTailList( &p_port->endpt_mgr.remove_conns, \r
&p_endpt->list_item, &p_port->endpt_mgr.remove_lock );\r
cm_listen.ca_guid = p_port->p_adapter->guids.ca_guid;\r
cm_listen.port_guid = p_port->p_adapter->guids.port_guid.guid;\r
cm_listen.lid = IB_ALL_LIDS;\r
- cm_listen.pkey = IB_ALL_PKEYS; // TODO: set pkey\r
+ cm_listen.pkey = p_port->p_adapter->guids.port_guid.pkey;\r
\r
cm_listen.pfn_cm_req_cb = __conn_req_cb;\r
\r
p_endpt->conn.h_qp = NULL;\r
}\r
}\r
- //ipoib_port_resume( p_port );\r
-\r
+ cl_spinlock_acquire( &p_port->send_lock );\r
+ if( cl_qlist_count( &p_port->send_mgr.pending_list ) )\r
+ {\r
+ cl_spinlock_release( &p_port->send_lock );\r
+ ipoib_port_resume( p_port );\r
+ }\r
+ else\r
+ {\r
+ cl_spinlock_release( &p_port->send_lock );\r
+ }\r
IPOIB_EXIT( IPOIB_DBG_ENDPT );\r
\r
return;\r
ipoib_shutdown(\r
IN PVOID adapter_context );\r
\r
+void\r
+ipoib_cancel_xmit(\r
+ IN NDIS_HANDLE adapter_context,\r
+ IN PVOID cancel_id );\r
+\r
static void\r
ipoib_complete_query(\r
IN ipoib_adapter_t* const p_adapter,\r
\r
characteristics.ReturnPacketHandler = ipoib_return_packet;\r
characteristics.SendPacketsHandler = ipoib_send_packets;\r
-\r
+ characteristics.CancelSendPacketsHandler = ipoib_cancel_xmit;\r
#ifdef NDIS51_MINIPORT\r
characteristics.PnPEventNotifyHandler = ipoib_pnp_notify;\r
characteristics.AdapterShutdownHandler = ipoib_shutdown;\r
// Adjusting the low watermark parameter\r
p_adapter->params.rq_low_watermark =\r
p_adapter->params.rq_depth / p_adapter->params.rq_low_watermark;\r
-\r
+ \r
+ /* so far disable CM if LSO get active */\r
+ if( p_adapter->params.cm_enabled )\r
+ {\r
+ p_adapter->params.cm_enabled = !p_adapter->params.lso;\r
+ }\r
p_adapter->params.cm_payload_mtu =\r
min( MAX_CM_PAYLOAD_MTU, p_adapter->params.payload_mtu );\r
p_adapter->params.cm_xfer_block_size = \r
#if IPOIB_USE_DMA\r
status =\r
NdisMInitializeScatterGatherDma( h_adapter, TRUE,\r
- max( p_adapter->params.xfer_block_size, p_adapter->params.cm_xfer_block_size ) );\r
+ ( p_adapter->params.cm_enabled ? \r
+ p_adapter->params.cm_xfer_block_size: \r
+ p_adapter->params.xfer_block_size ) );\r
if( status != NDIS_STATUS_SUCCESS )\r
{\r
ipoib_destroy_adapter( p_adapter );\r
break;\r
\r
case OID_GEN_LINK_SPEED:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_LINK_SPEED\n", port_num) );\r
cl_obj_lock( &p_adapter->obj );\r
switch( p_adapter->state )\r
break;\r
\r
case OID_GEN_MEDIA_CONNECT_STATUS:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_MEDIA_CONNECT_STATUS\n", port_num) );\r
cl_obj_lock( &p_adapter->obj );\r
switch( p_adapter->state )\r
break;\r
\r
case IB_PNP_PORT_ACTIVE:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d returning NdisMediaStateConnected\n", port_num) );\r
info = NdisMediaStateConnected;\r
break;\r
\r
/* Required General Statistics */\r
case OID_GEN_XMIT_OK:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_XMIT_OK\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_send_stat( p_adapter, IP_STAT_SUCCESS, &oid_info );\r
break;\r
\r
case OID_GEN_RCV_OK:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_RCV_OK\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_SUCCESS, &oid_info );\r
break;\r
\r
case OID_GEN_XMIT_ERROR:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_XMIT_ERROR\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_send_stat( p_adapter, IP_STAT_ERROR, &oid_info );\r
break;\r
\r
case OID_GEN_RCV_ERROR:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_RCV_ERROR\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_ERROR, &oid_info );\r
break;\r
\r
case OID_GEN_RCV_NO_BUFFER:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_RCV_NO_BUFFER\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_DROPPED, &oid_info );\r
break;\r
\r
case OID_GEN_DIRECTED_BYTES_XMIT:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_DIRECTED_BYTES_XMIT\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_send_stat( p_adapter, IP_STAT_UCAST_BYTES, &oid_info );\r
break;\r
\r
case OID_GEN_DIRECTED_FRAMES_XMIT:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_DIRECTED_FRAMES_XMIT\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_send_stat( p_adapter, IP_STAT_UCAST_FRAMES, &oid_info );\r
break;\r
\r
case OID_GEN_MULTICAST_BYTES_XMIT:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_MULTICAST_BYTES_XMIT\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_send_stat( p_adapter, IP_STAT_MCAST_BYTES, &oid_info );\r
break;\r
\r
case OID_GEN_MULTICAST_FRAMES_XMIT:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_MULTICAST_FRAMES_XMIT\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_send_stat( p_adapter, IP_STAT_MCAST_FRAMES, &oid_info );\r
break;\r
\r
case OID_GEN_BROADCAST_BYTES_XMIT:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_BROADCAST_BYTES_XMIT\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_send_stat( p_adapter, IP_STAT_BCAST_BYTES, &oid_info );\r
break;\r
\r
case OID_GEN_BROADCAST_FRAMES_XMIT:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_BROADCAST_FRAMES_XMIT\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_send_stat( p_adapter, IP_STAT_BCAST_FRAMES, &oid_info );\r
break;\r
\r
case OID_GEN_DIRECTED_BYTES_RCV:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_DIRECTED_BYTES_RCV\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_UCAST_BYTES, &oid_info );\r
break;\r
\r
case OID_GEN_DIRECTED_FRAMES_RCV:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_DIRECTED_FRAMES_RCV\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_UCAST_FRAMES, &oid_info );\r
break;\r
\r
case OID_GEN_MULTICAST_BYTES_RCV:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_MULTICAST_BYTES_RCV\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_MCAST_BYTES, &oid_info );\r
break;\r
\r
case OID_GEN_MULTICAST_FRAMES_RCV:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_MULTICAST_FRAMES_RCV\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_MCAST_FRAMES, &oid_info );\r
break;\r
\r
case OID_GEN_BROADCAST_BYTES_RCV:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_BROADCAST_BYTES_RCV\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_BCAST_BYTES, &oid_info );\r
break;\r
\r
case OID_GEN_BROADCAST_FRAMES_RCV:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_GEN_BROADCAST_FRAMES_RCV\n", port_num) );\r
src_buf = NULL;\r
status = ipoib_get_recv_stat( p_adapter, IP_STAT_BCAST_FRAMES, &oid_info );\r
\r
/* Required Ethernet operational characteristics */\r
case OID_802_3_PERMANENT_ADDRESS:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_802_3_PERMANENT_ADDRESS\n", port_num) );\r
src_buf = &p_adapter->mac;\r
buf_len = sizeof(p_adapter->mac);\r
break;\r
\r
case OID_802_3_CURRENT_ADDRESS:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_802_3_CURRENT_ADDRESS\n", port_num) );\r
src_buf = &p_adapter->params.conf_mac;\r
buf_len = sizeof(p_adapter->params.conf_mac);\r
break;\r
\r
case OID_802_3_MULTICAST_LIST:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_802_3_MULTICAST_LIST\n", port_num) );\r
src_buf = p_adapter->mcast_array;\r
buf_len = p_adapter->mcast_array_size * sizeof(mac_addr_t);\r
break;\r
\r
case OID_802_3_MAXIMUM_LIST_SIZE:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_802_3_MAXIMUM_LIST_SIZE\n", port_num) );\r
info = MAX_MCAST;\r
break;\r
\r
case OID_802_3_MAC_OPTIONS:\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received query for OID_802_3_MAC_OPTIONS\n", port_num) );\r
info = 0;\r
break;\r
case OID_802_3_XMIT_LATE_COLLISIONS:\r
case OID_PNP_CAPABILITIES:\r
status = NDIS_STATUS_NOT_SUPPORTED;\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received an unsupported oid of 0x%.8X!\n", port_num, oid) );\r
break;\r
\r
#endif\r
default:\r
status = NDIS_STATUS_INVALID_OID;\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE,IPOIB_DBG_OID,\r
("Port %d received an invalid oid of 0x%.8X!\n", port_num, oid) );\r
break;\r
}\r
IPOIB_EXIT( IPOIB_DBG_OID );\r
}\r
\r
+void\r
+ipoib_cancel_xmit(\r
+ IN NDIS_HANDLE adapter_context,\r
+ IN PVOID cancel_id )\r
+{\r
+ ipoib_adapter_t* const p_adapter =\r
+ (ipoib_adapter_t* const )adapter_context;\r
+\r
+ if( p_adapter && p_adapter->p_port )\r
+ {\r
+ ipoib_port_cancel_xmit( p_adapter->p_port, cancel_id );\r
+ }\r
+}\r
\r
static void\r
__ipoib_ats_reg_cb(\r
static NDIS_PACKET*\r
__endpt_cm_get_ndis_pkt(\r
IN ipoib_port_t* const p_port,\r
- IN ipoib_recv_desc_t* const p_desc );\r
+ IN ipoib_cm_desc_t* const p_desc );\r
\r
-static inline ipoib_recv_desc_t*\r
+static inline ipoib_cm_desc_t*\r
__endpt_cm_buf_mgr_get_recv(\r
IN endpt_buf_mgr_t * const p_buf_mgr );\r
\r
p_port->p_adapter->p_ifc->leave_mcast( p_endpt->h_mcast, ipoib_leave_mcast_cb );\r
}\r
else if( p_port->p_adapter->params.cm_enabled )\r
- { \r
- if( endpt_cm_get_state( p_endpt ) == IPOIB_CM_CONNECTED )\r
+ {\r
+ cm_state_t cm_state;\r
+ cm_state = endpt_cm_set_state( p_endpt, IPOIB_CM_DESTROY );\r
+ p_endpt->cm_flag = 0;\r
+ IPOIB_PRINT( TRACE_LEVEL_INFORMATION, IPOIB_DBG_ENDPT,\r
+ ("Destroy Endpt CM state: %d\n", cm_state ) );\r
+ switch( cm_state )\r
{\r
- /* send DREQ */\r
- //endpt_cm_disconnect( p_port, p_endpt );\r
+ case IPOIB_CM_CONNECTED:\r
+ /* DREQ will be sent in context of destroy_qp */\r
+ case IPOIB_CM_CONNECT:\r
+ case IPOIB_CM_DREP_SENT:\r
+ case IPOIB_CM_STALE_CONN:\r
+ cl_obj_unlock( p_obj );\r
+ endpt_cm_destroy_conn( p_port, p_endpt );\r
+ cl_obj_lock( p_obj );\r
+ case IPOIB_CM_DISCONNECTED:\r
+ default:\r
+ CL_ASSERT( p_endpt->conn.h_qp == NULL );\r
+ break;\r
}\r
- endpt_cm_destroy_conn( p_port, p_endpt );\r
}\r
\r
cl_obj_unlock( p_obj );\r
p_port->cm_recv_mgr.rq_depth ,\r
0,\r
0,\r
- sizeof( ipoib_recv_desc_t ),\r
+ sizeof( ipoib_cm_desc_t ),\r
__cm_recv_desc_ctor,\r
__cm_recv_desc_dtor,\r
p_port );\r
p_item = cl_qlist_remove_head( &p_port->cm_buf_mgr.posted_list ) )\r
{\r
cl_qpool_put( &p_port->cm_buf_mgr.recv_pool, \r
- &( PARENT_STRUCT( p_item, ipoib_recv_desc_t, list_item ))->item );\r
+ &( PARENT_STRUCT( p_item, ipoib_cm_desc_t, list_item ))->item );\r
}\r
}\r
cl_qpool_destroy( &p_port->cm_buf_mgr.recv_pool );\r
IN void* context,\r
OUT cl_pool_item_t** const pp_pool_item )\r
{\r
- ipoib_recv_desc_t* p_desc;\r
+ ipoib_cm_desc_t* p_desc;\r
ipoib_port_t* p_port;\r
\r
//IPOIB_ENTER( IPOIB_DBG_ALLOC );\r
CL_ASSERT( p_object );\r
CL_ASSERT( context );\r
\r
- p_desc = (ipoib_recv_desc_t*)p_object;\r
+ p_desc = (ipoib_cm_desc_t*)p_object;\r
p_port = (ipoib_port_t*)context;\r
\r
/* Allocate the receive buffer. */\r
p_desc->buf_size = p_port->p_adapter->params.cm_xfer_block_size;\r
\r
- p_desc->p_buf = (recv_buf_t*)ExAllocatePoolWithTag( \r
+ p_desc->p_buf = (uint8_t *)ExAllocatePoolWithTag( \r
NonPagedPool, p_desc->buf_size, 'DOMC' );\r
\r
if( p_desc->p_buf == NULL )\r
IN const cl_pool_item_t* const p_pool_item,\r
IN void *context )\r
{\r
- ipoib_recv_desc_t *p_desc;\r
+ ipoib_cm_desc_t *p_desc;\r
\r
//IPOIB_ENTER( IPOIB_DBG_ALLOC );\r
\r
UNUSED_PARAM( context );\r
\r
- p_desc = PARENT_STRUCT( p_pool_item, ipoib_recv_desc_t, item );\r
+ p_desc = PARENT_STRUCT( p_pool_item, ipoib_cm_desc_t, item );\r
\r
if( p_desc->p_buf )\r
ExFreePoolWithTag( p_desc->p_buf, 'DOMC' );\r
static NDIS_PACKET*\r
__endpt_cm_get_ndis_pkt(\r
IN ipoib_port_t* const p_port,\r
- IN ipoib_recv_desc_t* const p_desc )\r
+ IN ipoib_cm_desc_t* const p_desc )\r
{\r
NDIS_STATUS status;\r
NDIS_PACKET *p_packet;\r
return p_packet;\r
}\r
\r
-static inline ipoib_recv_desc_t*\r
+static inline ipoib_cm_desc_t*\r
__endpt_cm_buf_mgr_get_recv(\r
IN endpt_buf_mgr_t * const p_buf_mgr )\r
{\r
- ipoib_recv_desc_t *p_desc;\r
-\r
- //IPOIB_ENTER( IPOIB_DBG_RECV );\r
-\r
- p_desc = (ipoib_recv_desc_t*)cl_qpool_get( &p_buf_mgr->recv_pool );\r
+ ipoib_cm_desc_t *p_desc;\r
\r
+ p_desc = (ipoib_cm_desc_t*)cl_qpool_get( &p_buf_mgr->recv_pool );\r
if( p_desc )\r
cl_qlist_insert_tail( &p_buf_mgr->posted_list, &p_desc->list_item );\r
\r
- //IPOIB_EXIT( IPOIB_DBG_RECV );\r
return p_desc;\r
}\r
\r
void\r
endpt_cm_buf_mgr_put_recv(\r
IN endpt_buf_mgr_t * const p_buf_mgr,\r
- IN ipoib_recv_desc_t* const p_desc )\r
+ IN ipoib_cm_desc_t* const p_desc )\r
{\r
\r
IPOIB_ENTER(IPOIB_DBG_RECV );\r
IN OUT uint32_t* p_bytes_recv )\r
{\r
cl_list_item_t *p_item;\r
- ipoib_recv_desc_t *p_desc;\r
+ ipoib_cm_desc_t *p_desc;\r
uint32_t i = 0;\r
NDIS_PACKET *p_packet;\r
\r
for( p_item; p_item != cl_qlist_end( p_done_list );\r
p_item = cl_qlist_remove_head( p_done_list ) )\r
{\r
- p_desc = (ipoib_recv_desc_t*)p_item;\r
+ p_desc = (ipoib_cm_desc_t*)p_item;\r
\r
p_packet = __endpt_cm_get_ndis_pkt( p_port, p_desc );\r
if( !p_packet )\r
ib_wc_t *p_free_wc;\r
ib_wc_t *p_done_wc;\r
ib_wc_t *p_wc;\r
- ipoib_recv_desc_t *p_desc;\r
+ ipoib_cm_desc_t *p_desc;\r
size_t i;\r
\r
IPOIB_ENTER( IPOIB_DBG_RECV );\r
cl_spinlock_acquire( &p_port->recv_lock );\r
for( p_wc = p_done_wc; p_wc; p_wc = p_wc->p_next )\r
{\r
- p_desc = (ipoib_recv_desc_t*)(uintn_t)p_wc->wr_id;\r
+ p_desc = (ipoib_cm_desc_t *)(uintn_t)p_wc->wr_id;\r
endpt_cm_buf_mgr_put_recv( &p_port->cm_buf_mgr, p_desc );\r
p_port->cm_recv_mgr.depth--;\r
}\r
OUT cl_qlist_t* const p_bad_list )\r
{\r
ib_api_status_t ib_status;\r
- ipoib_recv_desc_t *p_desc;\r
+ ipoib_cm_desc_t *p_desc;\r
ib_wc_t *p_wc;\r
ipoib_pkt_t *p_ipoib;\r
eth_pkt_t *p_eth;\r
\r
for( p_wc = p_done_wc_list, recv_cnt = 0; p_wc; p_wc = p_wc->p_next )\r
{\r
- p_desc = (ipoib_recv_desc_t*)(uintn_t)p_wc->wr_id;\r
+ p_desc = (ipoib_cm_desc_t *)(uintn_t)p_wc->wr_id;\r
recv_cnt++;\r
if( p_wc->status != IB_WCS_SUCCESS )\r
{\r
IN ipoib_port_t* const p_port )\r
{\r
ib_api_status_t ib_status = IB_SUCCESS;\r
- ipoib_recv_desc_t *p_head_desc = NULL;\r
- ipoib_recv_desc_t *p_tail_desc = NULL;\r
- ipoib_recv_desc_t *p_next_desc;\r
+ ipoib_cm_desc_t *p_head_desc = NULL;\r
+ ipoib_cm_desc_t *p_tail_desc = NULL;\r
+ ipoib_cm_desc_t *p_next_desc;\r
ib_recv_wr_t *p_failed_wc = NULL;\r
\r
IPOIB_ENTER( IPOIB_DBG_RECV );\r
/* put descriptors back to the pool */\r
while( p_failed_wc )\r
{\r
- p_head_desc = PARENT_STRUCT( p_failed_wc, ipoib_recv_desc_t, wr );\r
+ p_head_desc = PARENT_STRUCT( p_failed_wc, ipoib_cm_desc_t, wr );\r
p_failed_wc = p_failed_wc->p_next;\r
endpt_cm_buf_mgr_put_recv( &p_port->cm_buf_mgr, p_head_desc );\r
p_port->cm_recv_mgr.depth--;\r
IPOIB_CM_CONNECT,\r
IPOIB_CM_CONNECTED,\r
IPOIB_CM_LISTEN,\r
- IPOIB_CM_FAILED,\r
IPOIB_CM_DREP_SENT,\r
IPOIB_CM_DREQ_SENT,\r
IPOIB_CM_STALE_CONN,\r
// disable further CM initialization \r
p_port->p_adapter->params.cm_enabled = FALSE;\r
}\r
- \r
+ if (!p_port->p_ca_attrs->ipoib_csum )\r
+ {\r
+ //checksum is not supported by device\r
+ //user must specify BYPASS to explicitly cancel checksum calculation\r
+ IPOIB_PRINT( TRACE_LEVEL_ERROR, IPOIB_DBG_ERROR,\r
+ ("IPOIB CHKSUM IS NOT SUPPORTED BY HCA\n" ) );\r
+ if (p_port->p_adapter->params.send_chksum_offload == CSUM_ENABLED)\r
+ p_port->p_adapter->params.send_chksum_offload = CSUM_DISABLED;\r
+ if (p_port->p_adapter->params.recv_chksum_offload == CSUM_ENABLED)\r
+ p_port->p_adapter->params.recv_chksum_offload = CSUM_DISABLED;\r
+ }\r
/* Allocate the UD QP. */\r
cl_memclr( &qp_create, sizeof(qp_create) );\r
qp_create.qp_type = IB_QPT_UNRELIABLE_DGRM;\r
\r
/* Get the port and descriptor from the packet. */\r
p_port = IPOIB_PORT_FROM_PACKET( p_packet );\r
- \r
- cl_spinlock_acquire( &p_port->recv_lock );\r
+ p_desc = (ipoib_recv_desc_t *)IPOIB_RECV_FROM_PACKET( p_packet );\r
\r
- /* Get descriptor from the packet. */\r
- p_desc = IPOIB_RECV_FROM_PACKET( p_packet );\r
+ cl_spinlock_acquire( &p_port->recv_lock );\r
\r
+ /* Get descriptor from the packet. */\r
if( p_desc->type == PKT_TYPE_CM_UCAST )\r
{\r
NDIS_BUFFER *p_buf;\r
NdisDprFreePacketNonInterlocked( p_packet );\r
NdisFreeBuffer( p_buf );\r
\r
- endpt_cm_buf_mgr_put_recv( &p_port->cm_buf_mgr, p_desc );\r
+ endpt_cm_buf_mgr_put_recv( &p_port->cm_buf_mgr, (ipoib_cm_desc_t *)p_desc );\r
\r
status = endpt_cm_post_recv( p_port );\r
if( status != IB_SUCCESS )\r
while( shortage-- > 1 )\r
{\r
__buf_mgr_put_recv( p_port,\r
- IPOIB_RECV_FROM_PACKET( p_port->recv_mgr.recv_pkt_array[shortage] ),\r
+ (ipoib_recv_desc_t *)IPOIB_RECV_FROM_PACKET( p_port->recv_mgr.recv_pkt_array[shortage] ),\r
p_port->recv_mgr.recv_pkt_array[shortage] );\r
}\r
cl_spinlock_release( &p_port->recv_lock );\r
\r
if( *pp_src && *pp_dst )\r
{\r
- IPOIB_PRINT(TRACE_LEVEL_INFORMATION, IPOIB_DBG_RECV,\r
+ IPOIB_PRINT(TRACE_LEVEL_VERBOSE, IPOIB_DBG_RECV,\r
("Recv:\n"\r
"\tsrc MAC: %02X-%02X-%02X-%02X-%02X-%02X\n"\r
"\tdst MAC: %02X-%02X-%02X-%02X-%02X-%02X\n",\r
}\r
else\r
{\r
- IPOIB_PRINT(TRACE_LEVEL_INFORMATION, IPOIB_DBG_RECV,\r
+ IPOIB_PRINT(TRACE_LEVEL_VERBOSE, IPOIB_DBG_RECV,\r
("Flushed completion %s\n",\r
p_port->p_adapter->p_ifc->get_wc_status_str( p_wc->status )) );\r
ipoib_inc_recv_stat( p_port->p_adapter, IP_STAT_DROPPED, 0, 0 );\r
\r
}\r
/* Successful completion. Get the receive information. */\r
- p_desc->ndis_csum.Value = (ULONG) p_wc->csum_ok;\r
+ p_desc->ndis_csum.Value = ( ( p_wc->recv.ud.recv_opt & IB_RECV_OPT_CSUM_MASK) >> 8 );\r
cl_perf_start( GetRecvEndpts );\r
__recv_get_endpts( p_port, p_desc, p_wc, &p_src, &p_dst );\r
cl_perf_stop( &p_port->p_adapter->perf, GetRecvEndpts );\r
NDIS_STATUS status;\r
uint32_t pkt_filter;\r
ip_stat_sel_t type;\r
+ NDIS_TCP_IP_CHECKSUM_PACKET_INFO chksum;\r
PERF_DECLARE( GetNdisPkt );\r
\r
IPOIB_ENTER( IPOIB_DBG_RECV );\r
return IB_INSUFFICIENT_RESOURCES;\r
}\r
\r
- /* Get the checksums directly from packet information. */\r
- NDIS_PER_PACKET_INFO_FROM_PACKET( *pp_packet, TcpIpChecksumPacketInfo ) = \r
- (PVOID) (uintn_t) (p_desc->ndis_csum.Value);\r
+ chksum.Value = 0;\r
+ switch( p_port->p_adapter->params.recv_chksum_offload )\r
+ {\r
+ default:\r
+ CL_ASSERT( FALSE );\r
+ case CSUM_DISABLED:\r
+ NDIS_PER_PACKET_INFO_FROM_PACKET( *pp_packet, TcpIpChecksumPacketInfo ) =\r
+ (void*)(uintn_t)chksum.Value;\r
+ break;\r
+ case CSUM_ENABLED:\r
+ /* Get the checksums directly from packet information. */\r
+ /* In this case, no one of cheksum's cat get false value */\r
+ /* If hardware checksum failed or wasn't calculated, NDIS will recalculate it again */\r
+ NDIS_PER_PACKET_INFO_FROM_PACKET( *pp_packet, TcpIpChecksumPacketInfo ) = \r
+ (void*)(uintn_t)(p_desc->ndis_csum.Value);\r
+ break;\r
+ case CSUM_BYPASS:\r
+ /* Flag the checksums as having been calculated. */\r
+ chksum.Receive.NdisPacketTcpChecksumSucceeded = TRUE;\r
+ chksum.Receive.NdisPacketUdpChecksumSucceeded = TRUE;\r
+ chksum.Receive.NdisPacketIpChecksumSucceeded = TRUE;\r
+ NDIS_PER_PACKET_INFO_FROM_PACKET( *pp_packet, TcpIpChecksumPacketInfo ) =\r
+ (void*)(uintn_t)chksum.Value;\r
+ break;\r
+ }\r
ipoib_inc_recv_stat( p_port->p_adapter, type, p_desc->len, 1 );\r
\r
IPOIB_EXIT( IPOIB_DBG_RECV );\r
if( p_arp->op == ARP_OP_REQ )\r
{\r
IPOIB_PRINT_EXIT( TRACE_LEVEL_INFORMATION, IPOIB_DBG_INIT,\r
- (" ARP REQUEST SEND to ENDPT[%p] set LCM %#x\n",\r
+ (" ARP REQUEST SEND to ENDPT[%p] CM flag %#x\n",\r
p_desc->p_endpt, ipoib_addr_get_flags( &p_ib_arp->src_hw ) ));\r
}\r
else if( p_arp->op == ARP_OP_REP )\r
{\r
IPOIB_PRINT_EXIT( TRACE_LEVEL_INFORMATION, IPOIB_DBG_INIT,\r
- ("ARP REPLY SEND to ENDPT[%p] state %d CM: %#x LCM: %#x\n",\r
- p_desc->p_endpt, endpt_cm_get_state( p_desc->p_endpt ),\r
- p_desc->p_endpt->cm_flag, \r
- ipoib_addr_get_flags( &p_ib_arp->src_hw ) ) );\r
+ ("ARP REPLY to ENDPT[%p] state %d CM flag: %#x MAC %02x:%02x:%02x:%02x:%02x:%02x\n",\r
+ p_desc->p_endpt, endpt_cm_get_state( p_desc->p_endpt ), p_desc->p_endpt->cm_flag,\r
+ p_desc->p_endpt->mac.addr[0], p_desc->p_endpt->mac.addr[1],\r
+ p_desc->p_endpt->mac.addr[2], p_desc->p_endpt->mac.addr[3],\r
+ p_desc->p_endpt->mac.addr[4], p_desc->p_endpt->mac.addr[5] ) );\r
}\r
}\r
\r
return NDIS_STATUS_BUFFER_TOO_SHORT;\r
}\r
\r
- IPOIB_PRINT_EXIT( TRACE_LEVEL_INFORMATION, IPOIB_DBG_SEND,\r
+ IPOIB_PRINT_EXIT( TRACE_LEVEL_VERBOSE, IPOIB_DBG_SEND,\r
("Ethernet header:\n"\r
"\tsrc MAC: %02X-%02X-%02X-%02X-%02X-%02X\n"\r
"\tdst MAC: %02X-%02X-%02X-%02X-%02X-%02X\n"\r
p_desc->wr.p_next = NULL;\r
p_desc->wr.wr_id = (uintn_t)p_desc->p_pkt;\r
\r
- if(p_port->p_adapter->params.send_chksum_offload & \r
+ if(p_port->p_adapter->params.send_chksum_offload && \r
(pChecksumPktInfo->Transmit.NdisPacketChecksumV4 || pChecksumPktInfo->Transmit.NdisPacketChecksumV6))\r
{\r
// Set transimition checksum offloading \r
break;\r
}\r
}\r
-\r
/*\r
* Complete the send as if we sent it - WHQL tests don't like the\r
* sends to fail.\r
cl_perf_start( BuildSendDesc );\r
status = __build_send_desc( p_port, p_eth_hdr, p_buf, buf_len, &desc );\r
cl_perf_stop( &p_port->p_adapter->perf, BuildSendDesc );\r
- if( status == NDIS_STATUS_PENDING )\r
- {\r
- /* ARP REPLY packet queued */\r
- if( &desc.p_endpt )\r
- ipoib_endpt_deref( desc.p_endpt );\r
- break;\r
- }\r
if( status != NDIS_STATUS_SUCCESS )\r
{\r
+ if( status == NDIS_STATUS_PENDING )\r
+ {\r
+ /* ARP REPLY packet queued */\r
+ ipoib_endpt_deref( desc.p_endpt );\r
+ break;\r
+ }\r
cl_perf_start( ProcessFailedSends );\r
__process_failed_send( p_port, &desc, status );\r
cl_perf_stop( &p_port->p_adapter->perf, ProcessFailedSends );\r
p_endpt = PARENT_STRUCT( p_item, ipoib_endpt_t, list_item );\r
if( p_port->endpt_mgr.thread_is_done )\r
{\r
- endpt_cm_set_state( p_endpt, IPOIB_CM_FAILED );\r
+ endpt_cm_set_state( p_endpt, IPOIB_CM_DESTROY );\r
NdisInterlockedInsertTailList( &p_port->endpt_mgr.remove_conns, \r
&p_endpt->list_item, \r
&p_port->endpt_mgr.remove_lock );\r
}\r
if( ib_status != IB_SUCCESS && ib_status != IB_PENDING )\r
{\r
- endpt_cm_set_state( p_endpt, IPOIB_CM_FAILED );\r
+ endpt_cm_set_state( p_endpt, IPOIB_CM_DESTROY );\r
NdisInterlockedInsertTailList( &p_port->endpt_mgr.remove_conns, \r
&p_endpt->list_item, \r
&p_port->endpt_mgr.remove_lock );\r
\r
cl_obj_lock( &p_port->obj );\r
\r
- IPOIB_PRINT( TRACE_LEVEL_INFORMATION, IPOIB_DBG_ENDPT,\r
+ IPOIB_PRINT( TRACE_LEVEL_VERBOSE, IPOIB_DBG_ENDPT,\r
("Look for :\t MAC: %02X-%02X-%02X-%02X-%02X-%02X\n",\r
mac.addr[0], mac.addr[1], mac.addr[2],\r
mac.addr[3], mac.addr[4], mac.addr[5]) );\r
return status;\r
}\r
\r
- status = endpt_cm_buf_mgr_init( p_port );\r
- if( status != IB_SUCCESS )\r
+ if( p_port->p_adapter->params.cm_enabled )\r
{\r
- IPOIB_PRINT( TRACE_LEVEL_ERROR, IPOIB_DBG_ERROR,\r
- ("CM Init buf mgr failed status %#x\n", status ) );\r
+ status = endpt_cm_buf_mgr_init( p_port );\r
+ if( status != IB_SUCCESS )\r
+ {\r
+ IPOIB_PRINT( TRACE_LEVEL_ERROR, IPOIB_DBG_ERROR,\r
+ ("CM Init buf mgr failed status %#x\n", status ) );\r
\r
- endpt_cm_buf_mgr_destroy( p_port );\r
- ipoib_port_srq_destroy( p_port );\r
- p_port->p_adapter->params.cm_enabled = FALSE;\r
- return status;\r
+ endpt_cm_buf_mgr_destroy( p_port );\r
+ ipoib_port_srq_destroy( p_port );\r
+ p_port->p_adapter->params.cm_enabled = FALSE;\r
+ }\r
}\r
-\r
p_port->p_local_endpt = p_endpt;\r
\r
IPOIB_EXIT( IPOIB_DBG_INIT );\r
return;\r
}\r
\r
- while( p_port->recv_mgr.depth > 0 )\r
- {\r
- __recv_cb( p_port->ib_mgr.h_recv_cq, (void *)p_port );\r
- }\r
-\r
- qp_mod.req_state = IB_QPS_RESET;\r
- status = p_port->p_adapter->p_ifc->modify_qp( p_port->ib_mgr.h_qp, &qp_mod );\r
- if( status != IB_SUCCESS )\r
- {\r
- IPOIB_PRINT_EXIT( TRACE_LEVEL_ERROR, IPOIB_DBG_ERROR,\r
- ("ib_modify_qp to RESET state returned %s.\n",\r
- p_port->p_adapter->p_ifc->get_err_str( status )) );\r
- p_port->p_adapter->hung = TRUE;\r
- return;\r
- }\r
-\r
KeResetEvent(&p_port->leave_mcast_event);\r
\r
/* Reset all endpoints so we don't flush our ARP cache. */\r
return __recv_dhcp(\r
p_port, p_ipoib, p_eth, p_src,p_dst );\r
}\r
+\r
+void\r
+ipoib_port_cancel_xmit(\r
+ IN ipoib_port_t* const p_port,\r
+ IN PVOID cancel_id )\r
+{\r
+ cl_list_item_t *p_item;\r
+ NDIS_PACKET* p_packet;\r
+ PVOID packet_id;\r
+ cl_qlist_t cancel_list;\r
+\r
+ IPOIB_ENTER( IPOIB_DBG_SEND );\r
+\r
+ cl_qlist_init( &cancel_list );\r
+\r
+ cl_spinlock_acquire( &p_port->send_lock );\r
+\r
+ for( p_item = cl_qlist_head( &p_port->send_mgr.pending_list );\r
+ p_item != cl_qlist_end( &p_port->send_mgr.pending_list );\r
+ p_item = cl_qlist_next( p_item ) )\r
+ {\r
+ p_packet = IPOIB_PACKET_FROM_LIST_ITEM( p_item );\r
+ packet_id = NDIS_GET_PACKET_CANCEL_ID( p_packet );\r
+ if( packet_id == cancel_id )\r
+ {\r
+ cl_qlist_remove_item( &p_port->send_mgr.pending_list, p_item );\r
+ NDIS_SET_PACKET_STATUS( p_packet, NDIS_STATUS_REQUEST_ABORTED );\r
+ cl_qlist_insert_tail( &cancel_list, IPOIB_LIST_ITEM_FROM_PACKET( p_packet ) );\r
+ }\r
+ }\r
+ cl_spinlock_release( &p_port->send_lock );\r
+\r
+ if( cl_qlist_count( &cancel_list ) )\r
+ {\r
+ while( ( p_item = cl_qlist_remove_head( &cancel_list )) \r
+ != cl_qlist_end( &cancel_list ))\r
+ {\r
+ p_packet = IPOIB_PACKET_FROM_LIST_ITEM( p_item );\r
+ NdisMSendComplete( p_port->p_adapter->h_adapter, \r
+ p_packet, NDIS_STATUS_REQUEST_ABORTED );\r
+ }\r
+ }\r
+ IPOIB_EXIT( IPOIB_DBG_SEND );\r
+}\r
/*\r
* Define to place receive buffer inline in receive descriptor.\r
*/\r
-#define IPOIB_INLINE_RECV 0\r
+#define IPOIB_INLINE_RECV 1\r
\r
/* \r
* Invalid pkey index\r
#define IPOIB_ENDPT_FROM_PACKET( P ) \\r
(((ipoib_endpt_t**)P->MiniportReservedEx)[1])\r
#define IPOIB_RECV_FROM_PACKET( P ) \\r
- (((ipoib_recv_desc_t**)P->MiniportReservedEx)[1])\r
+ (((void **)P->MiniportReservedEx)[1])\r
#define IPOIB_SEND_FROM_PACKET( P ) \\r
(((send_buf_t**)P->MiniportReservedEx)[2])\r
#define IPOIB_PACKET_FROM_LIST_ITEM( I ) \\r
\r
} ipoib_pkt_type_t;\r
\r
+typedef struct _ipoib_cm_desc\r
+{\r
+ cl_pool_item_t item; /* Must be first. */\r
+ uint32_t len;\r
+ ipoib_pkt_type_t type;\r
+ ib_recv_wr_t wr;\r
+ ipoib_endpt_t* p_endpt;\r
+ ib_local_ds_t local_ds[2];\r
+ cl_list_item_t list_item;\r
+ uint8_t *p_buf;\r
+ uint8_t *p_phys_buf;\r
+ uint32_t buf_size;\r
+ NDIS_TCP_IP_CHECKSUM_PACKET_INFO ndis_csum;\r
+\r
+} ipoib_cm_desc_t;\r
\r
typedef struct _ipoib_recv_desc\r
{\r
cl_pool_item_t item; /* Must be first. */\r
- cl_list_item_t list_item;\r
uint32_t len;\r
ipoib_pkt_type_t type;\r
ib_recv_wr_t wr;\r
- ipoib_endpt_t* p_endpt;\r
ib_local_ds_t local_ds[2];\r
NDIS_TCP_IP_CHECKSUM_PACKET_INFO ndis_csum;\r
#if IPOIB_INLINE_RECV\r
recv_buf_t buf;\r
#else\r
recv_buf_t *p_buf;\r
- uint32_t buf_size;\r
#endif\r
\r
} ipoib_recv_desc_t;\r
void\r
endpt_cm_buf_mgr_put_recv(\r
IN endpt_buf_mgr_t * const p_buf_mgr,\r
- IN ipoib_recv_desc_t* const p_desc );\r
+ IN ipoib_cm_desc_t* const p_desc );\r
\r
void\r
endpt_cm_buf_mgr_put_recv_list(\r
IN ipoib_endpt_t* const p_src,\r
IN ipoib_endpt_t* const p_dst );\r
\r
+void\r
+ipoib_port_cancel_xmit(\r
+ IN ipoib_port_t* const p_port,\r
+ IN PVOID cancel_id );\r
+\r
#endif /* _IPOIB_PORT_H_ */\r
\r
HKR, Ndi\Params\SendChksum, ParamDesc, 0, "Send Checksum Offload"\r
HKR, Ndi\Params\SendChksum, Type, 0, "enum"\r
-HKR, Ndi\Params\SendChksum, Default, 0, "0"\r
+HKR, Ndi\Params\SendChksum, Default, 0, "1"\r
HKR, Ndi\Params\SendChksum, Optional, 0, "0"\r
HKR, Ndi\Params\SendChksum\enum, "0", 0, "Disabled"\r
-HKR, Ndi\Params\SendChksum\enum, "1", 0, "Enabled"\r
+HKR, Ndi\Params\SendChksum\enum, "1", 0, "Enabled (if supported by HW)"\r
+HKR, Ndi\Params\SendChksum\enum, "2", 0, "Bypass"\r
\r
HKR, Ndi\Params\RecvChksum, ParamDesc, 0, "Recv Checksum Offload"\r
HKR, Ndi\Params\RecvChksum, Type, 0, "enum"\r
-HKR, Ndi\Params\RecvChksum, Default, 0, "0"\r
+HKR, Ndi\Params\RecvChksum, Default, 0, "1"\r
HKR, Ndi\Params\RecvChksum, Optional, 0, "0"\r
HKR, Ndi\Params\RecvChksum\enum, "0", 0, "Disabled"\r
-HKR, Ndi\Params\RecvChksum\enum, "1", 0, "Enabled"\r
+HKR, Ndi\Params\RecvChksum\enum, "1", 0, "Enabled (if supported by HW)"\r
+HKR, Ndi\Params\RecvChksum\enum, "2", 0, "Bypass"\r
+\r
+HKR, Ndi\Params\lso, ParamDesc, 0, "Large Send Offload"\r
+HKR, Ndi\Params\lso, Type, 0, "enum"\r
+HKR, Ndi\Params\lso, Default, 0, "0"\r
+HKR, Ndi\Params\lso, Optional, 0, "0"\r
+HKR, Ndi\Params\lso\enum, "0", 0, "Disabled"\r
+HKR, Ndi\Params\lso\enum, "1", 0, "Enabled"\r
\r
HKR, Ndi\Params\SaTimeout, ParamDesc, 0, "SA Query Timeout (ms)"\r
HKR, Ndi\Params\SaTimeout, Type, 0, "dword"\r