[ofw] [Patch][IPoIB_NDIS6_CM] Spacing and tabulation, no functionality changes

Alex Naslednikov xalex at mellanox.co.il
Tue Sep 21 08:26:18 PDT 2010


Index: B:/users/xalex/WoF-trunk/ulp/ipoib_NDIS6_CM/kernel/ipoib_driver.cpp
===================================================================
--- B:/users/xalex/WoF-trunk/ulp/ipoib_NDIS6_CM/kernel/ipoib_driver.cpp     (revision 2941)
+++ B:/users/xalex/WoF-trunk/ulp/ipoib_NDIS6_CM/kernel/ipoib_driver.cpp  (working copy)
@@ -6,18 +6,18 @@
  * This software is available to you under the OpenIB.org BSD license
  * below:
  *
- *     Redistribution and use in source and binary forms, with or
- *     without modification, are permitted provided that the following
- *     conditions are met:
+ *             Redistribution and use in source and binary forms, with or
+ *             without modification, are permitted provided that the following
+ *             conditions are met:
  *
- *      - Redistributions of source code must retain the above
- *        copyright notice, this list of conditions and the following
- *        disclaimer.
+ *                          - Redistributions of source code must retain the above
+ *                            copyright notice, this list of conditions and the following
+ *                            disclaimer.
  *
- *      - Redistributions in binary form must reproduce the above
- *        copyright notice, this list of conditions and the following
- *        disclaimer in the documentation and/or other materials
- *        provided with the distribution.
+ *                          - Redistributions in binary form must reproduce the above
+ *                            copyright notice, this list of conditions and the following
+ *                            disclaimer in the documentation and/or other materials
+ *                            provided with the distribution.
  *
  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
@@ -68,98 +68,98 @@

 static const NDIS_OID SUPPORTED_OIDS[] =
 {
-    OID_GEN_SUPPORTED_LIST,
-    OID_GEN_HARDWARE_STATUS,
-    OID_GEN_MEDIA_SUPPORTED,
-    OID_GEN_MEDIA_IN_USE,
-    OID_GEN_MAXIMUM_LOOKAHEAD,
-    OID_GEN_MAXIMUM_FRAME_SIZE,
-    OID_GEN_TRANSMIT_BUFFER_SPACE,
-    OID_GEN_RECEIVE_BUFFER_SPACE,
-    OID_GEN_TRANSMIT_BLOCK_SIZE,
-    OID_GEN_RECEIVE_BLOCK_SIZE,
-    OID_GEN_VENDOR_ID,
-    OID_GEN_VENDOR_DESCRIPTION,
-    OID_GEN_VENDOR_DRIVER_VERSION,
-    OID_GEN_CURRENT_PACKET_FILTER,
-    OID_GEN_CURRENT_LOOKAHEAD,
-    OID_GEN_DRIVER_VERSION,
-    OID_GEN_MAXIMUM_TOTAL_SIZE,
-    OID_GEN_MAC_OPTIONS,
-    OID_GEN_MAXIMUM_SEND_PACKETS,
-    OID_GEN_XMIT_OK,
-    OID_GEN_RCV_OK,
-    OID_GEN_XMIT_ERROR,
-    OID_GEN_RCV_ERROR,
-    OID_GEN_RCV_NO_BUFFER,
-    //OID_GEN_RCV_CRC_ERROR,
-    //OID_GEN_TRANSMIT_QUEUE_LENGTH,
-    OID_802_3_PERMANENT_ADDRESS,
-    OID_802_3_CURRENT_ADDRESS,
-    OID_802_3_MULTICAST_LIST,
-    OID_802_3_MAXIMUM_LIST_SIZE,
-    OID_802_3_RCV_ERROR_ALIGNMENT,
-    OID_802_3_XMIT_ONE_COLLISION,
-    OID_802_3_XMIT_MORE_COLLISIONS,
-    //OID_802_3_XMIT_DEFERRED,
-    //OID_802_3_XMIT_MAX_COLLISIONS,
-    //OID_802_3_RCV_OVERRUN,
-    //OID_802_3_XMIT_UNDERRUN,
-    //OID_802_3_XMIT_HEARTBEAT_FAILURE,
-    //OID_802_3_XMIT_TIMES_CRS_LOST,
-    //OID_802_3_XMIT_LATE_COLLISIONS,
+             OID_GEN_SUPPORTED_LIST,
+             OID_GEN_HARDWARE_STATUS,
+             OID_GEN_MEDIA_SUPPORTED,
+             OID_GEN_MEDIA_IN_USE,
+             OID_GEN_MAXIMUM_LOOKAHEAD,
+             OID_GEN_MAXIMUM_FRAME_SIZE,
+             OID_GEN_TRANSMIT_BUFFER_SPACE,
+             OID_GEN_RECEIVE_BUFFER_SPACE,
+             OID_GEN_TRANSMIT_BLOCK_SIZE,
+             OID_GEN_RECEIVE_BLOCK_SIZE,
+             OID_GEN_VENDOR_ID,
+             OID_GEN_VENDOR_DESCRIPTION,
+             OID_GEN_VENDOR_DRIVER_VERSION,
+             OID_GEN_CURRENT_PACKET_FILTER,
+             OID_GEN_CURRENT_LOOKAHEAD,
+             OID_GEN_DRIVER_VERSION,
+             OID_GEN_MAXIMUM_TOTAL_SIZE,
+             OID_GEN_MAC_OPTIONS,
+             OID_GEN_MAXIMUM_SEND_PACKETS,
+             OID_GEN_XMIT_OK,
+             OID_GEN_RCV_OK,
+             OID_GEN_XMIT_ERROR,
+             OID_GEN_RCV_ERROR,
+             OID_GEN_RCV_NO_BUFFER,
+             //OID_GEN_RCV_CRC_ERROR,
+             //OID_GEN_TRANSMIT_QUEUE_LENGTH,
+             OID_802_3_PERMANENT_ADDRESS,
+             OID_802_3_CURRENT_ADDRESS,
+             OID_802_3_MULTICAST_LIST,
+             OID_802_3_MAXIMUM_LIST_SIZE,
+             OID_802_3_RCV_ERROR_ALIGNMENT,
+             OID_802_3_XMIT_ONE_COLLISION,
+             OID_802_3_XMIT_MORE_COLLISIONS,
+             //OID_802_3_XMIT_DEFERRED,
+             //OID_802_3_XMIT_MAX_COLLISIONS,
+             //OID_802_3_RCV_OVERRUN,
+             //OID_802_3_XMIT_UNDERRUN,
+             //OID_802_3_XMIT_HEARTBEAT_FAILURE,
+             //OID_802_3_XMIT_TIMES_CRS_LOST,
+             //OID_802_3_XMIT_LATE_COLLISIONS,

 #if !BUILD_W2K
-    OID_GEN_PHYSICAL_MEDIUM,
+             OID_GEN_PHYSICAL_MEDIUM,
 #endif

-    OID_TCP_TASK_OFFLOAD,
-
+             OID_TCP_TASK_OFFLOAD,
+
 /* powermanagement */

-    OID_PNP_CAPABILITIES,
-    OID_PNP_SET_POWER,
-    OID_PNP_QUERY_POWER,
-    OID_PNP_ADD_WAKE_UP_PATTERN,
-    OID_PNP_REMOVE_WAKE_UP_PATTERN,
-    OID_PNP_ENABLE_WAKE_UP,
+             OID_PNP_CAPABILITIES,
+             OID_PNP_SET_POWER,
+             OID_PNP_QUERY_POWER,
+             OID_PNP_ADD_WAKE_UP_PATTERN,
+             OID_PNP_REMOVE_WAKE_UP_PATTERN,
+             OID_PNP_ENABLE_WAKE_UP,

 #if 0
 /* custom oid WMI support */
-    OID_CUSTOM_PERF_COUNTERS,
-    OID_CUSTOM_STRING,
+             OID_CUSTOM_PERF_COUNTERS,
+             OID_CUSTOM_STRING,
 #endif

-    OID_GEN_RECEIVE_SCALE_CAPABILITIES,
-    OID_GEN_RECEIVE_SCALE_PARAMETERS,
+             OID_GEN_RECEIVE_SCALE_CAPABILITIES,
+             OID_GEN_RECEIVE_SCALE_PARAMETERS,


 //
 // new and required for NDIS 6 miniports
 //
-    OID_GEN_LINK_PARAMETERS,
-    OID_GEN_INTERRUPT_MODERATION,
-    OID_GEN_STATISTICS,
+             OID_GEN_LINK_PARAMETERS,
+             OID_GEN_INTERRUPT_MODERATION,
+             OID_GEN_STATISTICS,

 /* Offload */
-    OID_TCP_OFFLOAD_CURRENT_CONFIG,
-    OID_TCP_OFFLOAD_PARAMETERS,
-    OID_TCP_OFFLOAD_HARDWARE_CAPABILITIES,
-    OID_OFFLOAD_ENCAPSULATION,
-
+             OID_TCP_OFFLOAD_CURRENT_CONFIG,
+             OID_TCP_OFFLOAD_PARAMETERS,
+             OID_TCP_OFFLOAD_HARDWARE_CAPABILITIES,
+             OID_OFFLOAD_ENCAPSULATION,
+
 #if 0

 /* Header - Data seperation */
-    OID_GEN_HD_SPLIT_PARAMETERS,
-    OID_GEN_HD_SPLIT_CURRENT_CONFIG,
+             OID_GEN_HD_SPLIT_PARAMETERS,
+             OID_GEN_HD_SPLIT_CURRENT_CONFIG,

 /* VLAN */
-    OID_ADD_VALN_ID,
-    OID_DELETE_VLAN_ID,
+             OID_ADD_VALN_ID,
+             OID_DELETE_VLAN_ID,


 /* Set MAC */
-    OID_SET_MAC_ADDRESS
+             OID_SET_MAC_ADDRESS
 #endif

 };
@@ -185,9 +185,9 @@
 ULONG                                                g_ipoib_send_SW           = 0;
 ULONG                                                g_ipoib_send_SG            = 0;
 ULONG                                                g_ipoib_send_SW_in_loop = 0;
-ULONG                                               g_ipoib_send_SG_pending = 0;
-ULONG                                               g_ipoib_send_SG_real = 0;
-ULONG                                               g_ipoib_send_SG_failed = 0;
+ULONG                                              g_ipoib_send_SG_pending = 0;
+ULONG                                              g_ipoib_send_SG_real = 0;
+ULONG                                              g_ipoib_send_SG_failed = 0;
 ULONG                                                g_ipoib_send_reset = 0;

 ULONG                                                g_NBL = 0;
@@ -196,33 +196,33 @@

 typedef struct _IPOIB_REG_ENTRY
 {
-              NDIS_STRING RegName;                // variable name text
-              BOOLEAN     bRequired;              // 1 -> required, 0 -> optional
-              UINT        FieldOffset;            // offset in parent struct
-              UINT        FieldSize;              // size (in bytes) of the field
-              UINT        Default;                // default value to use
-              UINT        Min;                    // minimum value allowed
-              UINT        Max;                    // maximum value allowed
+             NDIS_STRING RegName;                                                              // variable name text
+             BOOLEAN            bRequired;                                                         // 1 -> required, 0 -> optional
+             UINT                      FieldOffset;                                        // offset in parent struct
+             UINT                      FieldSize;                                                             // size (in bytes) of the field
+             UINT                      Default;                                                                // default value to use
+             UINT                      Min;                                                                       // minimum value allowed
+             UINT                      Max;                                                                      // maximum value allowed
 } IPOIB_REG_ENTRY, *PIPOIB_REG_ENTRY;

 IPOIB_REG_ENTRY HCARegTable[] = {
-              // reg value name             If Required  Offset in parentr struct             Field size                  Default         Min     Max
-              {NDIS_STRING_CONST("GUIDMask"),         0, IPOIB_OFFSET(guid_mask),             IPOIB_SIZE(guid_mask),          0,          0,    MAX_GUID_MAX},
+             // reg value name                                              If Required  Offset in parentr struct                                       Field size                                                                              Default                                 Min        Max
+             {NDIS_STRING_CONST("GUIDMask"),                   0, IPOIB_OFFSET(guid_mask),                                    IPOIB_SIZE(guid_mask),                                               0,                                            0,              MAX_GUID_MAX},
                /* GUIDMask should be the first element */
-              {NDIS_STRING_CONST("RqDepth"),          1, IPOIB_OFFSET(rq_depth),              IPOIB_SIZE(rq_depth),           512,        128,    1024},
-              {NDIS_STRING_CONST("RqLowWatermark"),   0, IPOIB_OFFSET(rq_low_watermark),      IPOIB_SIZE(rq_low_watermark),   4,          2,      8},
-              {NDIS_STRING_CONST("SqDepth"),          1, IPOIB_OFFSET(sq_depth),              IPOIB_SIZE(sq_depth),           512,        128,    1024},
-              {NDIS_STRING_CONST("SendChksum"),       1, IPOIB_OFFSET(send_chksum_offload),   IPOIB_SIZE(send_chksum_offload),CSUM_ENABLED,CSUM_DISABLED,CSUM_BYPASS},
-              {NDIS_STRING_CONST("RecvChksum"),       1, IPOIB_OFFSET(recv_chksum_offload),   IPOIB_SIZE(recv_chksum_offload),CSUM_ENABLED,CSUM_DISABLED,CSUM_BYPASS},
-              {NDIS_STRING_CONST("SaTimeout"),        1, IPOIB_OFFSET(sa_timeout),            IPOIB_SIZE(sa_timeout),         1000,       250,    UINT_MAX},
-              {NDIS_STRING_CONST("SaRetries"),        1, IPOIB_OFFSET(sa_retry_cnt),          IPOIB_SIZE(sa_retry_cnt),       10,         1,      UINT_MAX},
-              {NDIS_STRING_CONST("RecvRatio"),        1, IPOIB_OFFSET(recv_pool_ratio),       IPOIB_SIZE(recv_pool_ratio),    1,          1,      10},
-              {NDIS_STRING_CONST("PayloadMtu"),       1, IPOIB_OFFSET(payload_mtu),           IPOIB_SIZE(payload_mtu),        2044,       512,   MAX_UD_PAYLOAD_MTU},
-              {NDIS_STRING_CONST("lso"),              0, IPOIB_OFFSET(lso),                   IPOIB_SIZE(lso),                0,          0,      1},
-              {NDIS_STRING_CONST("MCLeaveRescan"),    1, IPOIB_OFFSET(mc_leave_rescan),       IPOIB_SIZE(mc_leave_rescan),    260,        1,    3600},
-              {NDIS_STRING_CONST("BCJoinRetry"),     1, IPOIB_OFFSET(bc_join_retry),                              IPOIB_SIZE(bc_join_retry),      50,         0,    1000},
-              {NDIS_STRING_CONST("CmEnabled"),        0, IPOIB_OFFSET(cm_enabled),            IPOIB_SIZE(cm_enabled),         FALSE,     FALSE, TRUE},
-              {NDIS_STRING_CONST("CmPayloadMtu"),     1, IPOIB_OFFSET(cm_payload_mtu),        IPOIB_SIZE(cm_payload_mtu),     MAX_CM_PAYLOAD_MTU, 512, MAX_CM_PAYLOAD_MTU}
+             {NDIS_STRING_CONST("RqDepth"),                                       1, IPOIB_OFFSET(rq_depth),                                                      IPOIB_SIZE(rq_depth),                                  512,                        128,        1024},
+             {NDIS_STRING_CONST("RqLowWatermark"),    0, IPOIB_OFFSET(rq_low_watermark),                  IPOIB_SIZE(rq_low_watermark),              4,                                            2,                            8},
+             {NDIS_STRING_CONST("SqDepth"),                                       1, IPOIB_OFFSET(sq_depth),                                                      IPOIB_SIZE(sq_depth),                                 512,                        128,        1024},
+             {NDIS_STRING_CONST("SendChksum"),                              1, IPOIB_OFFSET(send_chksum_offload),                IPOIB_SIZE(send_chksum_offload),CSUM_ENABLED,CSUM_DISABLED,CSUM_BYPASS},
+             {NDIS_STRING_CONST("RecvChksum"),                               1, IPOIB_OFFSET(recv_chksum_offload),                IPOIB_SIZE(recv_chksum_offload),CSUM_ENABLED,CSUM_DISABLED,CSUM_BYPASS},
+             {NDIS_STRING_CONST("SaTimeout"),                   1, IPOIB_OFFSET(sa_timeout),                                  IPOIB_SIZE(sa_timeout),                              1000,                     250,        UINT_MAX},
+             {NDIS_STRING_CONST("SaRetries"),                      1, IPOIB_OFFSET(sa_retry_cnt),                                                IPOIB_SIZE(sa_retry_cnt),                           10,                          1,                            UINT_MAX},
+             {NDIS_STRING_CONST("RecvRatio"),                     1, IPOIB_OFFSET(recv_pool_ratio),                         IPOIB_SIZE(recv_pool_ratio),     1,                                            1,                            10},
+             {NDIS_STRING_CONST("PayloadMtu"),                                1, IPOIB_OFFSET(payload_mtu),                                               IPOIB_SIZE(payload_mtu),                          2044,                     512,   MAX_UD_PAYLOAD_MTU},
+             {NDIS_STRING_CONST("lso"),                                                   0, IPOIB_OFFSET(lso),                                                                    IPOIB_SIZE(lso),                                                               0,                                            0,                            1},
+             {NDIS_STRING_CONST("MCLeaveRescan"),        1, IPOIB_OFFSET(mc_leave_rescan),                      IPOIB_SIZE(mc_leave_rescan), 260,                        1,              3600},
+             {NDIS_STRING_CONST("BCJoinRetry"),                 1, IPOIB_OFFSET(bc_join_retry),                                              IPOIB_SIZE(bc_join_retry),                         50,                          0,              1000},
+             {NDIS_STRING_CONST("CmEnabled"),                  0, IPOIB_OFFSET(cm_enabled),                                                IPOIB_SIZE(cm_enabled),                            FALSE,      FALSE, TRUE},
+             {NDIS_STRING_CONST("CmPayloadMtu"),          1, IPOIB_OFFSET(cm_payload_mtu),                      IPOIB_SIZE(cm_payload_mtu),                 MAX_CM_PAYLOAD_MTU, 512, MAX_CM_PAYLOAD_MTU}
 };

 #define IPOIB_NUM_REG_PARAMS (sizeof (HCARegTable) / sizeof(IPOIB_REG_ENTRY))
@@ -235,7 +235,7 @@
                ULONG eventLogMsgId)

 {
-#define cMaxStrLen  40
+#define cMaxStrLen    40
 #define cArrLen  3

                PWCHAR logMsgArray[cArrLen];
@@ -279,8 +279,8 @@
 NDIS_STATUS
 ipoib_initialize_ex(
                IN                                                           NDIS_HANDLE                                   h_adapter,
-    IN                                                      NDIS_HANDLE                   config_context,
-    IN PNDIS_MINIPORT_INIT_PARAMETERS       MiniportInitParameters);
+             IN                                                           NDIS_HANDLE                   config_context,
+             IN PNDIS_MINIPORT_INIT_PARAMETERS            MiniportInitParameters);

 BOOLEAN
 ipoib_check_for_hang(
@@ -288,34 +288,34 @@

 void
 ipoib_halt_ex(
-              IN NDIS_HANDLE  adapter_context,
-              IN                                           NDIS_HALT_ACTION            HaltAction);
+             IN NDIS_HANDLE             adapter_context,
+             IN                                                           NDIS_HALT_ACTION                                      HaltAction);

 NDIS_STATUS
 ipoib_query_info(
-    IN      NDIS_HANDLE         adapter_context,
-    IN  OUT PNDIS_OID_REQUEST   pNdisRequest);
+             IN                           NDIS_HANDLE                   adapter_context,
+             IN           OUT PNDIS_OID_REQUEST          pNdisRequest);



 NDIS_STATUS
 ipoib_reset(
-    IN  NDIS_HANDLE     adapter_context,
-    OUT PBOOLEAN        p_addr_reset);
+             IN           NDIS_HANDLE   adapter_context,
+             OUT PBOOLEAN                               p_addr_reset);

 NDIS_STATUS
 ipoib_set_info(
-    IN      NDIS_HANDLE         adapter_context,
-    IN  OUT PNDIS_OID_REQUEST   pNdisRequest);
+             IN                           NDIS_HANDLE                   adapter_context,
+             IN           OUT PNDIS_OID_REQUEST          pNdisRequest);


 //NDIS60
 void
 ipoib_send_net_buffer_list(
-    IN  NDIS_HANDLE         adapter_context,
-    IN  PNET_BUFFER_LIST    net_buffer_list,
-    IN  NDIS_PORT_NUMBER    port_num,
-    IN  ULONG               send_flags);
+             IN           NDIS_HANDLE                   adapter_context,
+             IN           PNET_BUFFER_LIST        net_buffer_list,
+             IN           NDIS_PORT_NUMBER   port_num,
+             IN           ULONG                                                 send_flags);

 void
 ipoib_pnp_notify(
@@ -324,7 +324,7 @@

 VOID
 ipoib_shutdown_ex(
-              IN NDIS_HANDLE  adapter_context,
+             IN NDIS_HANDLE             adapter_context,
                IN NDIS_SHUTDOWN_ACTION  shutdown_action);


@@ -369,28 +369,28 @@

 static NDIS_STATUS
 ipoib_set_options(
-    IN NDIS_HANDLE  NdisMiniportDriverHandle,
-    IN NDIS_HANDLE  MiniportDriverContext);
+             IN NDIS_HANDLE             NdisMiniportDriverHandle,
+             IN NDIS_HANDLE             MiniportDriverContext);

 static NDIS_STATUS
 ipoib_oid_handler(
-    IN  NDIS_HANDLE         adapter_context,
-    IN  PNDIS_OID_REQUEST   pNdisRequest);
+             IN           NDIS_HANDLE                   adapter_context,
+             IN           PNDIS_OID_REQUEST    pNdisRequest);

 static void
 ipoib_cancel_oid_request(
-    IN  NDIS_HANDLE            adapter_context,
-    IN  PVOID                  requestId);
-
+             IN           NDIS_HANDLE                      adapter_context,
+             IN           PVOID                                                      requestId);
+
 static NDIS_STATUS
 ipoib_pause(
-    IN  NDIS_HANDLE                         adapter_context,
-    IN  PNDIS_MINIPORT_PAUSE_PARAMETERS     pause_parameters);
+             IN           NDIS_HANDLE                                                                                   adapter_context,
+             IN           PNDIS_MINIPORT_PAUSE_PARAMETERS             pause_parameters);

 static NDIS_STATUS
 ipoib_restart(
-    IN  NDIS_HANDLE                         adapter_context,
-    IN  PNDIS_MINIPORT_RESTART_PARAMETERS   restart_parameters);
+             IN           NDIS_HANDLE                                                                                   adapter_context,
+             IN           PNDIS_MINIPORT_RESTART_PARAMETERS         restart_parameters);



@@ -439,16 +439,16 @@
                ipoib_st_init();
                g_stat.drv.obj = p_drv_obj;

-    NdisZeroMemory(&characteristics, sizeof(characteristics));
+             NdisZeroMemory(&characteristics, sizeof(characteristics));

-    characteristics.Header.Type = NDIS_OBJECT_TYPE_MINIPORT_DRIVER_CHARACTERISTICS;
-    characteristics.Header.Size = NDIS_SIZEOF_MINIPORT_DRIVER_CHARACTERISTICS_REVISION_2;
-    characteristics.Header.Revision = NDIS_MINIPORT_DRIVER_CHARACTERISTICS_REVISION_2;
+             characteristics.Header.Type = NDIS_OBJECT_TYPE_MINIPORT_DRIVER_CHARACTERISTICS;
+             characteristics.Header.Size = NDIS_SIZEOF_MINIPORT_DRIVER_CHARACTERISTICS_REVISION_2;
+             characteristics.Header.Revision = NDIS_MINIPORT_DRIVER_CHARACTERISTICS_REVISION_2;

                characteristics.MajorNdisVersion                             = MAJOR_NDIS_VERSION;
                characteristics.MinorNdisVersion                             = MINOR_NDIS_VERSION;
-    characteristics.MajorDriverVersion                    = MAJOR_DRIVER_VERSION;
-    characteristics.MinorDriverVersion                    = MINOR_DRIVER_VERSION;
+             characteristics.MajorDriverVersion                          = MAJOR_DRIVER_VERSION;
+             characteristics.MinorDriverVersion                          = MINOR_DRIVER_VERSION;

                characteristics.CheckForHangHandlerEx                                = ipoib_check_for_hang;
                characteristics.HaltHandlerEx                                                     = ipoib_halt_ex;
@@ -460,9 +460,9 @@
                characteristics.ReturnNetBufferListsHandler       = ipoib_return_net_buffer_list;
                characteristics.SendNetBufferListsHandler          = ipoib_send_net_buffer_list;

-              characteristics.SetOptionsHandler                                           = ipoib_set_options;
+             characteristics.SetOptionsHandler                                           = ipoib_set_options;
                characteristics.PauseHandler                                                      = ipoib_pause;
-              characteristics.RestartHandler                                                   = ipoib_restart;
+             characteristics.RestartHandler                                                   = ipoib_restart;
                characteristics.UnloadHandler                                                   = ipoib_unload;
                characteristics.CancelSendHandler                                          = ipoib_cancel_xmit;
                characteristics.ShutdownHandlerEx                                        = ipoib_shutdown_ex;
@@ -482,17 +482,17 @@

 static NDIS_STATUS
 ipoib_set_options(
-    IN NDIS_HANDLE  NdisMiniportDriverHandle,
-    IN NDIS_HANDLE  MiniportDriverContext
-    )
+             IN NDIS_HANDLE             NdisMiniportDriverHandle,
+             IN NDIS_HANDLE             MiniportDriverContext
+             )
 {
                IPOIB_ENTER( IPOIB_DBG_INIT );

-    UNREFERENCED_PARAMETER(NdisMiniportDriverHandle);
-    UNREFERENCED_PARAMETER(MiniportDriverContext);
+             UNREFERENCED_PARAMETER(NdisMiniportDriverHandle);
+             UNREFERENCED_PARAMETER(MiniportDriverContext);

                IPOIB_EXIT( IPOIB_DBG_INIT );
-    return NDIS_STATUS_SUCCESS;
+             return NDIS_STATUS_SUCCESS;
 }

 static NTSTATUS
@@ -593,7 +593,7 @@
 {
                NDIS_STATUS                                                                                    status;
                NDIS_HANDLE                                                                                   h_config;
-    NDIS_CONFIGURATION_OBJECT                        config_obj;
+             NDIS_CONFIGURATION_OBJECT                              config_obj;
                NDIS_CONFIGURATION_PARAMETER    *p_param;
                UINT                                                                                                      value;
                PIPOIB_REG_ENTRY                                                       pRegEntry;
@@ -604,11 +604,11 @@

                IPOIB_ENTER( IPOIB_DBG_INIT );

-    config_obj.Header.Type = NDIS_OBJECT_TYPE_CONFIGURATION_OBJECT;
-    config_obj.Header.Revision = NDIS_CONFIGURATION_OBJECT_REVISION_1;
-    config_obj.Header.Size = sizeof(NDIS_CONFIGURATION_OBJECT);
-    config_obj.NdisHandle = p_adapter->h_adapter;
-    config_obj.Flags = 0;
+             config_obj.Header.Type = NDIS_OBJECT_TYPE_CONFIGURATION_OBJECT;
+             config_obj.Header.Revision = NDIS_CONFIGURATION_OBJECT_REVISION_1;
+             config_obj.Header.Size = sizeof(NDIS_CONFIGURATION_OBJECT);
+             config_obj.NdisHandle = p_adapter->h_adapter;
+             config_obj.Flags = 0;

                status = NdisOpenConfigurationEx( &config_obj, &h_config);
                if( status != NDIS_STATUS_SUCCESS )
@@ -833,7 +833,7 @@


 //! Initialization function called for each IOC discovered
-/*  The MiniportInitialize function is a required function that sets up a
+/*         The MiniportInitialize function is a required function that sets up a
 NIC (or virtual NIC) for network I/O operations, claims all hardware
 resources necessary to the NIC in the registry, and allocates resources
 the driver needs to carry out network I/O operations.
@@ -861,110 +861,110 @@
 NDIS_STATUS
 SetDeviceRegistrationAttributes(
                ipoib_adapter_t *p_adapter,
-    NDIS_HANDLE             h_adapter
-    )
+             NDIS_HANDLE   h_adapter
+             )
 {
-    NDIS_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES atr;
-    NTSTATUS Status;
+             NDIS_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES atr;
+             NTSTATUS Status;

-    NdisZeroMemory(&atr, sizeof(NDIS_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES));
+             NdisZeroMemory(&atr, sizeof(NDIS_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES));

-    //
-    // setting registration attributes
-    //
-    atr.Header.Type = NDIS_OBJECT_TYPE_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES;
-    atr.Header.Revision = NDIS_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES_REVISION_1;
-    atr.Header.Size = NDIS_SIZEOF_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES_REVISION_1;
+             //
+             // setting registration attributes
+             //
+             atr.Header.Type = NDIS_OBJECT_TYPE_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES;
+             atr.Header.Revision = NDIS_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES_REVISION_1;
+             atr.Header.Size = NDIS_SIZEOF_MINIPORT_ADD_DEVICE_REGISTRATION_ATTRIBUTES_REVISION_1;


-    atr.MiniportAddDeviceContext = (NDIS_HANDLE)p_adapter;
-    atr.Flags = 0;
+             atr.MiniportAddDeviceContext = (NDIS_HANDLE)p_adapter;
+             atr.Flags = 0;

-    Status = NdisMSetMiniportAttributes(h_adapter,
-                    (PNDIS_MINIPORT_ADAPTER_ATTRIBUTES)&atr);
+             Status = NdisMSetMiniportAttributes(h_adapter,
+                                                                             (PNDIS_MINIPORT_ADAPTER_ATTRIBUTES)&atr);

-    return Status;
+             return Status;
 }

 //NDIS 6.1
 #if 0
 NDIS_STATUS
 SetHardwareAssistAttributes(
-    ipoib_adapter_t *p_adapter,
-    NDIS_HANDLE             h_adapter
-    )
+             ipoib_adapter_t *p_adapter,
+             NDIS_HANDLE   h_adapter
+             )
 {
-    NDIS_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES atr;
-    NTSTATUS Status;
+             NDIS_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES atr;
+             NTSTATUS Status;

-    NdisZeroMemory(&atr, sizeof(NDIS_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES));
+             NdisZeroMemory(&atr, sizeof(NDIS_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES));

-    //
-    // setting registration attributes
-    //
-    atr.Header.Type = NDIS_OBJECT_TYPE_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES;
-    atr.Header.Revision = NDIS_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES_REVISION_1;
-    atr.Header.Size = NDIS_SIZEOF_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES_REVISION_1;
+             //
+             // setting registration attributes
+             //
+             atr.Header.Type = NDIS_OBJECT_TYPE_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES;
+             atr.Header.Revision = NDIS_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES_REVISION_1;
+             atr.Header.Size = NDIS_SIZEOF_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES_REVISION_1;

-    NDIS_HD_SPLIT_ATTRIBUTES nhsa;
-    NdisZeroMemory(&nhsa, sizeof(nhsa));
+             NDIS_HD_SPLIT_ATTRIBUTES nhsa;
+             NdisZeroMemory(&nhsa, sizeof(nhsa));

-    nhsa.Header.Type = NDIS_OBJECT_TYPE_HD_SPLIT_ATTRIBUTES;
-    nhsa.Header.Revision = NDIS_OFFLOAD_REVISION_1;
-    nhsa.Header.Size = NDIS_SIZEOF_HD_SPLIT_ATTRIBUTES_REVISION_1;
+             nhsa.Header.Type = NDIS_OBJECT_TYPE_HD_SPLIT_ATTRIBUTES;
+             nhsa.Header.Revision = NDIS_OFFLOAD_REVISION_1;
+             nhsa.Header.Size = NDIS_SIZEOF_HD_SPLIT_ATTRIBUTES_REVISION_1;

-    // BUGBUG: We are just cheating here ...
-    nhsa.HardwareCapabilities = NDIS_HD_SPLIT_CAPS_SUPPORTS_HEADER_DATA_SPLIT;
+             // BUGBUG: We are just cheating here ...
+             nhsa.HardwareCapabilities = NDIS_HD_SPLIT_CAPS_SUPPORTS_HEADER_DATA_SPLIT;
 #if 0
-    ... Only supported on B0
+             ... Only supported on B0

-                                 NDIS_HD_SPLIT_CAPS_SUPPORTS_IPV4_OPTIONS |
-                                 NDIS_HD_SPLIT_CAPS_SUPPORTS_IPV6_EXTENSION_HEADERS |
-                                 NDIS_HD_SPLIT_CAPS_SUPPORTS_TCP_OPTIONS;
+                                                                                                                             NDIS_HD_SPLIT_CAPS_SUPPORTS_IPV4_OPTIONS |
+                                                                                                                             NDIS_HD_SPLIT_CAPS_SUPPORTS_IPV6_EXTENSION_HEADERS |
+                                                                                                                             NDIS_HD_SPLIT_CAPS_SUPPORTS_TCP_OPTIONS;
 #endif

-    // The bellow should be left zero
-    if (pPort->Config.HeaderDataSplit) {
-        nhsa.CurrentCapabilities = NDIS_HD_SPLIT_CAPS_SUPPORTS_HEADER_DATA_SPLIT;
-    } else {
-        nhsa.CurrentCapabilities = 0;
-    }
+             // The bellow should be left zero
+             if (pPort->Config.HeaderDataSplit) {
+                             nhsa.CurrentCapabilities = NDIS_HD_SPLIT_CAPS_SUPPORTS_HEADER_DATA_SPLIT;
+             } else {
+                             nhsa.CurrentCapabilities = 0;
+             }

-    nhsa.HDSplitFlags = 0;
-    nhsa.BackfillSize = 0;
-    nhsa.MaxHeaderSize = 0;
+             nhsa.HDSplitFlags = 0;
+             nhsa.BackfillSize = 0;
+             nhsa.MaxHeaderSize = 0;

-    atr.HDSplitAttributes = &nhsa;
+             atr.HDSplitAttributes = &nhsa;

-    Status = NdisMSetMiniportAttributes(h_adapter,
-                    (PNDIS_MINIPORT_ADAPTER_ATTRIBUTES)&atr);
+             Status = NdisMSetMiniportAttributes(h_adapter,
+                                                                             (PNDIS_MINIPORT_ADAPTER_ATTRIBUTES)&atr);

-    if (nhsa.HDSplitFlags & NDIS_HD_SPLIT_ENABLE_HEADER_DATA_SPLIT) {
-        ASSERT(pPort->Config.HeaderDataSplit == TRUE);
-        pPort->Config.HeaderDataSplit = TRUE;
-    }
-    else {
-        ASSERT(pPort->Config.HeaderDataSplit == FALSE);
-        pPort->Config.HeaderDataSplit = FALSE;
-    }
+             if (nhsa.HDSplitFlags & NDIS_HD_SPLIT_ENABLE_HEADER_DATA_SPLIT) {
+                             ASSERT(pPort->Config.HeaderDataSplit == TRUE);
+                             pPort->Config.HeaderDataSplit = TRUE;
+             }
+             else {
+                             ASSERT(pPort->Config.HeaderDataSplit == FALSE);
+                             pPort->Config.HeaderDataSplit = FALSE;
+             }

-    return Status;
+             return Status;
 }
 #endif

 /*++
 Routine Description:
-    the routine sets attributes that are associated with a miniport adapter.
+             the routine sets attributes that are associated with a miniport adapter.

 Arguments:
-    pPort - Pointer to port object
+             pPort - Pointer to port object

 Return Value:
-    NDIS_STATUS
+             NDIS_STATUS

 Note:
-    Should be called in PASSIVE_LEVEL
-
+             Should be called in PASSIVE_LEVEL
+
 --*/
 NDIS_STATUS
 SetAdapterRegistrationAttributes(
@@ -986,7 +986,7 @@
                atr.MiniportAdapterContext = (NDIS_HANDLE)p_adapter;
                atr.AttributeFlags = NDIS_MINIPORT_ATTRIBUTES_BUS_MASTER;
                atr.CheckForHangTimeInSeconds = 10;
-              atr.InterfaceType = NdisInterfacePci ;   // ???? UH
+             atr.InterfaceType = NdisInterfacePci ;    // ???? UH
                //TODO NDIS60 PNP or PCI ?
                //RegistrationAttributes.InterfaceType = NdisInterfacePNPBus;

@@ -999,29 +999,29 @@

 /*++
 Routine Description:
-    the routine sets generic attributes that are associated with a miniport
-    adapter.
+             the routine sets generic attributes that are associated with a miniport
+             adapter.

 Arguments:
-    pPort - Pointer to port object
+             pPort - Pointer to port object

 Return Value:
-    NDIS_STATUS
+             NDIS_STATUS

 Note:
-    Should be called in PASSIVE_LEVEL
-
+             Should be called in PASSIVE_LEVEL
+
 --*/
 NDIS_STATUS
 SetGenericAttributes(
-    ipoib_adapter_t *p_adapter,
-    NDIS_HANDLE             h_adapter
-    )
+             ipoib_adapter_t *p_adapter,
+             NDIS_HANDLE   h_adapter
+             )
 {
-    NDIS_STATUS Status;
+             NDIS_STATUS Status;

-    NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES gat;
-    NdisZeroMemory(&gat, sizeof(NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES));
+             NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES gat;
+             NdisZeroMemory(&gat, sizeof(NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES));

                /* set up generic attributes */

@@ -1029,11 +1029,11 @@
                gat.Header.Revision = NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES_REVISION_1;
                gat.Header.Size = sizeof(NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES);

-              gat.MediaType =                              NdisMedium802_3;
-              gat.MaxXmitLinkSpeed =             IPOIB_MEDIA_MAX_SPEED;
-              gat.MaxRcvLinkSpeed =                IPOIB_MEDIA_MAX_SPEED;
+             gat.MediaType =                              NdisMedium802_3;
+             gat.MaxXmitLinkSpeed =             IPOIB_MEDIA_MAX_SPEED;
+             gat.MaxRcvLinkSpeed =                IPOIB_MEDIA_MAX_SPEED;
                gat.XmitLinkSpeed =                      NDIS_LINK_SPEED_UNKNOWN;
-              gat.RcvLinkSpeed =         NDIS_LINK_SPEED_UNKNOWN;
+             gat.RcvLinkSpeed =                         NDIS_LINK_SPEED_UNKNOWN;

                gat.MediaConnectState = MediaConnectStateConnected; //TODO NDIS60 Check the current state
                gat.MediaDuplexState = MediaDuplexStateFull;
@@ -1051,7 +1051,7 @@
                                                                                // DT: Enable for Header Data Split WHQL
                                                                                // |  NDIS_MAC_OPTION_8021Q_VLAN;

-              gat.SupportedPacketFilters =     NDIS_PACKET_TYPE_DIRECTED |
+             gat.SupportedPacketFilters =     NDIS_PACKET_TYPE_DIRECTED |
                                                                                                                                                NDIS_PACKET_TYPE_MULTICAST |
                                                                                                                                                //NDIS_PACKET_TYPE_ALL_MULTICAST |
                                                                                                                                                NDIS_PACKET_TYPE_BROADCAST;
@@ -1085,57 +1085,57 @@

                //TODO NDIS60 is it possible to reduce unsupported statistics
                gat.SupportedStatistics =
-                                      NDIS_STATISTICS_XMIT_OK_SUPPORTED |
-                                      NDIS_STATISTICS_RCV_OK_SUPPORTED |
-                                      NDIS_STATISTICS_XMIT_ERROR_SUPPORTED |
-                                      NDIS_STATISTICS_RCV_ERROR_SUPPORTED |
-                                      NDIS_STATISTICS_RCV_CRC_ERROR_SUPPORTED |
-                                      NDIS_STATISTICS_RCV_NO_BUFFER_SUPPORTED |
-                                      NDIS_STATISTICS_TRANSMIT_QUEUE_LENGTH_SUPPORTED;
+                                                                                                             NDIS_STATISTICS_XMIT_OK_SUPPORTED |
+                                                                                                             NDIS_STATISTICS_RCV_OK_SUPPORTED |
+                                                                                                             NDIS_STATISTICS_XMIT_ERROR_SUPPORTED |
+                                                                                                             NDIS_STATISTICS_RCV_ERROR_SUPPORTED |
+                                                                                                             NDIS_STATISTICS_RCV_CRC_ERROR_SUPPORTED |
+                                                                                                             NDIS_STATISTICS_RCV_NO_BUFFER_SUPPORTED |
+                                                                                                             NDIS_STATISTICS_TRANSMIT_QUEUE_LENGTH_SUPPORTED;

                //SupportedStatistics = NDIS_STATISTICS_XMIT_OK_SUPPORTED |
                                                                                                                // NDIS_STATISTICS_GEN_STATISTICS_SUPPORTED;


-    //
-    // Set power management capabilities
-    //
-    gat.PowerManagementCapabilities = NULL;
+             //
+             // Set power management capabilities
+             //
+             gat.PowerManagementCapabilities = NULL;
 #if 0
-    NDIS_PNP_CAPABILITIES PowerManagementCapabilities;
-    NdisZeroMemory(&PowerManagementCapabilities, sizeof(NDIS_PNP_CAPABILITIES));
-    if (MPIsPoMgmtSupported(pPort))
-    {
-        MPFillPoMgmtCaps(pPort, &PowerManagementCapabilities, &Status, &unUsed);
-        ASSERT(NT_SUCCESS(Status));
-        gat.PowerManagementCapabilities = &PowerManagementCapabilities;
-    }
-    else
-    {
-
-    }
+             NDIS_PNP_CAPABILITIES PowerManagementCapabilities;
+             NdisZeroMemory(&PowerManagementCapabilities, sizeof(NDIS_PNP_CAPABILITIES));
+             if (MPIsPoMgmtSupported(pPort))
+             {
+                             MPFillPoMgmtCaps(pPort, &PowerManagementCapabilities, &Status, &unUsed);
+                             ASSERT(NT_SUCCESS(Status));
+                             gat.PowerManagementCapabilities = &PowerManagementCapabilities;
+             }
+             else
+             {
+
+             }
 #endif

-    //
-    // Set RSS attributes
-    //
-    gat.RecvScaleCapabilities = NULL;
+             //
+             // Set RSS attributes
+             //
+             gat.RecvScaleCapabilities = NULL;
 #if 0
-    NDIS_RECEIVE_SCALE_CAPABILITIES RssCapabilities;
-    NdisZeroMemory(&RssCapabilities, sizeof(PNDIS_RECEIVE_SCALE_CAPABILITIES));
-    Status = MPFillRssCapabilities(pPort, &RssCapabilities, &unUsed);
-    if (NT_SUCCESS(Status))
-    {
-        gat.RecvScaleCapabilities = &RssCapabilities;
-    }
-    else
-    {
-        //
-        // do not fail the call because of failure to get PM caps
-        //
-        Status = NDIS_STATUS_SUCCESS;
-        gat.RecvScaleCapabilities = NULL;
-    }
+             NDIS_RECEIVE_SCALE_CAPABILITIES RssCapabilities;
+             NdisZeroMemory(&RssCapabilities, sizeof(PNDIS_RECEIVE_SCALE_CAPABILITIES));
+             Status = MPFillRssCapabilities(pPort, &RssCapabilities, &unUsed);
+             if (NT_SUCCESS(Status))
+             {
+                             gat.RecvScaleCapabilities = &RssCapabilities;
+             }
+             else
+             {
+                             //
+                             // do not fail the call because of failure to get PM caps
+                             //
+                             Status = NDIS_STATUS_SUCCESS;
+                             gat.RecvScaleCapabilities = NULL;
+             }
 #endif

                Status = NdisMSetMiniportAttributes(h_adapter,
@@ -1147,16 +1147,16 @@

 /*++
 Routine Description:
-    The routine sets an NDIS_OFFLOAD structure indicates the current offload
-    capabilities that are provided by the miniport adapter
-
+             The routine sets an NDIS_OFFLOAD structure indicates the current offload
+             capabilities that are provided by the miniport adapter
+
 Arguments:
-    pPort - a pointer to port object
-    offload - reference to NDIS_OFFLOAD object that should be filled
+             pPort - a pointer to port object
+             offload - reference to NDIS_OFFLOAD object that should be filled

 Return Value:
-    None.
-
+             None.
+
 --*/
 static
 void
@@ -1235,22 +1235,22 @@

 /*++
 Routine Description:
-    The routine sets an NDIS_OFFLOAD structure that indicates all the task
-    offload capabilites that are supported by the NIC. These capabilities include
-    capabilities that are currently disabled by standardized keywords in the registry.
-
+             The routine sets an NDIS_OFFLOAD structure that indicates all the task
+             offload capabilites that are supported by the NIC. These capabilities include
+             capabilities that are currently disabled by standardized keywords in the registry.
+
 Arguments:
-    offload - reference to NDIS_OFFLOAD object that should be filled
+             offload - reference to NDIS_OFFLOAD object that should be filled

 Return Value:
-    None.
-
+             None.
+
 --*/
 static
 void
 OffloadCapabilities(
                ipoib_adapter_t *p_adapter,
-              NDIS_OFFLOAD                *p_offload
+             NDIS_OFFLOAD                *p_offload
                )
 {
                ULONG ulEncapsulation = NDIS_ENCAPSULATION_IEEE_802_3 | NDIS_ENCAPSULATION_IEEE_802_3_P_AND_Q ;
@@ -1276,9 +1276,9 @@


                //
-              //  BUGBUG::
-              //  During a HW bug that didn't handle correctly packets with
-              //  IPv6 Extension Headers -> we set IpExtensionHeadersSupported to TRUE
+             //            BUGBUG::
+             //            During a HW bug that didn't handle correctly packets with
+             //            IPv6 Extension Headers -> we set IpExtensionHeadersSupported to TRUE
                //
                p_offload->Checksum.IPv6Transmit.Encapsulation = ulEncapsulation;
                p_offload->Checksum.IPv6Transmit.IpExtensionHeadersSupported =
@@ -1323,18 +1323,18 @@

 /*++
 Routine Description:
-    The routine sets offload attributes that are associated with a miniport
-    adapter.
+             The routine sets offload attributes that are associated with a miniport
+             adapter.

 Arguments:
-    pPort - Pointer to port object
+             pPort - Pointer to port object

 Return Value:
-    NDIS_STATUS
+             NDIS_STATUS

 Note:
-    Should be called in PASSIVE_LEVEL
-
+             Should be called in PASSIVE_LEVEL
+
 --*/
 NDIS_STATUS
 SetOffloadAttributes(
@@ -1346,7 +1346,7 @@
                NDIS_OFFLOAD offload,hwOffload;
                //ULONG ulEncapsulation = NDIS_ENCAPSULATION_IEEE_802_3 | NDIS_ENCAPSULATION_IEEE_802_3_P_AND_Q;

-              NDIS_MINIPORT_ADAPTER_OFFLOAD_ATTRIBUTES oat;
+             NDIS_MINIPORT_ADAPTER_OFFLOAD_ATTRIBUTES oat;
                NdisZeroMemory(&oat, sizeof(NDIS_MINIPORT_ADAPTER_OFFLOAD_ATTRIBUTES));

                oat.Header.Type = NDIS_OBJECT_TYPE_MINIPORT_ADAPTER_OFFLOAD_ATTRIBUTES;
@@ -1372,30 +1372,30 @@
 /*++

 Routine Description:
-    An NDIS 6.0 miniport driver must call NdisMSetMiniportAttributes
-    at least twice. The first call is to register itself with NDIS.
-    The second call is to register the miniport driver's general
-    attributes with NDIS.
+             An NDIS 6.0 miniport driver must call NdisMSetMiniportAttributes
+             at least twice. The first call is to register itself with NDIS.
+             The second call is to register the miniport driver's general
+             attributes with NDIS.

-    NdisMSetMiniportAttributes takes a parameter of type
-    NDIS_MINIPORT_ADAPTER_ATTRIBUTES, which is a union of several miniport
-    adapter attributes. Miniport drivers must first call
-    NdisMSetMiniportAttributes and pass in an
-    NDIS_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES structure
-    that contains the pointer to its own context area, attribute flags,
-    check-for-hang time, and interface type.
+             NdisMSetMiniportAttributes takes a parameter of type
+             NDIS_MINIPORT_ADAPTER_ATTRIBUTES, which is a union of several miniport
+             adapter attributes. Miniport drivers must first call
+             NdisMSetMiniportAttributes and pass in an
+             NDIS_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES structure
+             that contains the pointer to its own context area, attribute flags,
+             check-for-hang time, and interface type.

-    All NDIS 6.0 miniport drivers are deserialized by default.
+             All NDIS 6.0 miniport drivers are deserialized by default.

 Arguments:
-    pPort - Pointer to port object
+             pPort - Pointer to port object

 Return Value:
-    NDIS_STATUS
+             NDIS_STATUS

 Note:
-    Should be called in PASSIVE_LEVEL
-
+             Should be called in PASSIVE_LEVEL
+
 --*/
 NDIS_STATUS
 SetAttributes(
@@ -1433,8 +1433,8 @@
                                Status = SetHardwareAssistAttributes(pPort);
                                if (Status != NDIS_STATUS_SUCCESS)
                                {
-                                  //ETH_PRINT(TRACE_LEVEL_ERROR, ETH_INIT, "Set Hardware Assist Attributes failed Error=0x%x\n", Status);
-                                  return Status;
+                                             //ETH_PRINT(TRACE_LEVEL_ERROR, ETH_INIT, "Set Hardware Assist Attributes failed Error=0x%x\n", Status);
+                                             return Status;
                                }
                }
 #endif
@@ -1442,8 +1442,8 @@
                Status = SetGenericAttributes(p_adapter, h_adapter);
                if (Status != NDIS_STATUS_SUCCESS)
                {
-                  //ETH_PRINT(TRACE_LEVEL_ERROR, ETH_INIT, "Set generic attributes failed Error=0x%x\n", Status);
-                  return Status;
+                             //ETH_PRINT(TRACE_LEVEL_ERROR, ETH_INIT, "Set generic attributes failed Error=0x%x\n", Status);
+                             return Status;
                }

                return Status;
@@ -1452,20 +1452,20 @@
 BOOLEAN
 IsValidOffloadConfig(ipoib_adapter_t *p_adapter, PNDIS_OFFLOAD_PARAMETERS pOffloadParam)
 {
-    BOOLEAN bRet = TRUE;
+             BOOLEAN bRet = TRUE;

-    UCHAR CheckSumConfig[5]={0};
-    CheckSumConfig[0] = pOffloadParam->IPv4Checksum;
-    CheckSumConfig[1] = pOffloadParam->TCPIPv4Checksum;
-    CheckSumConfig[2] = pOffloadParam->UDPIPv4Checksum;
-    CheckSumConfig[3] = pOffloadParam->TCPIPv6Checksum;
-    CheckSumConfig[4] = pOffloadParam->UDPIPv6Checksum;
+             UCHAR CheckSumConfig[5]={0};
+             CheckSumConfig[0] = pOffloadParam->IPv4Checksum;
+             CheckSumConfig[1] = pOffloadParam->TCPIPv4Checksum;
+             CheckSumConfig[2] = pOffloadParam->UDPIPv4Checksum;
+             CheckSumConfig[3] = pOffloadParam->TCPIPv6Checksum;
+             CheckSumConfig[4] = pOffloadParam->UDPIPv6Checksum;

-    for(int i=0 ; i<5 ; i++)
-    {
-        if(CheckSumConfig[i] != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
-        {
-              switch (CheckSumConfig[i]) {
+             for(int i=0 ; i<5 ; i++)
+             {
+                             if(CheckSumConfig[i] != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
+                             {
+                                             switch (CheckSumConfig[i]) {
                                                                case NDIS_OFFLOAD_PARAMETERS_TX_RX_DISABLED:
                                                                                bRet = TRUE;
                                                                                break;
@@ -1482,28 +1482,28 @@
                                                                                break;
                                                                default:
                                                                                ASSERT (FALSE);
-              }
+                                             }

                                                if (!bRet)
                                                                return FALSE;


-            for(int j=0 ; j<5 ; j++)
-            {
-                if( (CheckSumConfig[j] != 0) && (CheckSumConfig[j] != CheckSumConfig[i])  )
-                {
-                   bRet = FALSE;
-                   goto Exit;
-                }
-            }
-        }
-    }
+                                             for(int j=0 ; j<5 ; j++)
+                                             {
+                                                             if( (CheckSumConfig[j] != 0) && (CheckSumConfig[j] != CheckSumConfig[i])  )
+                                                             {
+                                                                bRet = FALSE;
+                                                                goto Exit;
+                                                             }
+                                             }
+                             }
+             }


-    UCHAR OffloadConfig[3]={0};
-    OffloadConfig[0] = pOffloadParam->LsoV1;
-    OffloadConfig[1] = pOffloadParam->LsoV2IPv4;
-    OffloadConfig[2] = pOffloadParam->LsoV2IPv6;
+             UCHAR OffloadConfig[3]={0};
+             OffloadConfig[0] = pOffloadParam->LsoV1;
+             OffloadConfig[1] = pOffloadParam->LsoV2IPv4;
+             OffloadConfig[2] = pOffloadParam->LsoV2IPv6;

                if (!p_adapter->offload_cap.lso) {
                                if ((pOffloadParam->LsoV1 == NDIS_OFFLOAD_PARAMETERS_LSOV1_ENABLED) ||
@@ -1514,128 +1514,128 @@
                }

                pOffloadParam->LsoV1;
-    OffloadConfig[1] = pOffloadParam->LsoV2IPv4;
+             OffloadConfig[1] = pOffloadParam->LsoV2IPv4;

-    for(int i=0 ; i<3 ; i++)
-    {
-        if(OffloadConfig[i] != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
-        {
-            for(int j=0 ; j<3 ; j++)
-            {
-                if( (OffloadConfig[j] != 0) && (OffloadConfig[j] != OffloadConfig[i])  )
-                {
-                   bRet = FALSE;
-                   goto Exit;
-                }
-            }
-        }
-    }
+             for(int i=0 ; i<3 ; i++)
+             {
+                             if(OffloadConfig[i] != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
+                             {
+                                             for(int j=0 ; j<3 ; j++)
+                                             {
+                                                             if( (OffloadConfig[j] != 0) && (OffloadConfig[j] != OffloadConfig[i])  )
+                                                             {
+                                                                bRet = FALSE;
+                                                                goto Exit;
+                                                             }
+                                             }
+                             }
+             }

 Exit:
-    return bRet;
+             return bRet;
 }

 static
 NDIS_STATUS
 SetOffloadParameters(
-    ipoib_adapter_t * p_adapter,
-    void* const pBuf,
-    ULONG len
-    )
+             ipoib_adapter_t * p_adapter,
+             void* const pBuf,
+             ULONG len
+             )
 {
-    IPOIB_ENTER(IPOIB_DBG_OID);
+             IPOIB_ENTER(IPOIB_DBG_OID);

-    ASSERT(pBuf != NULL);
-
-    PNDIS_OFFLOAD_PARAMETERS pOffloadParam = NULL;
-    PNDIS_OBJECT_HEADER pOffloadHeader = NULL;
-    NDIS_STATUS Status = NDIS_STATUS_SUCCESS;
-    bool StatusIndicationFlag = FALSE;
+             ASSERT(pBuf != NULL);
+
+             PNDIS_OFFLOAD_PARAMETERS pOffloadParam = NULL;
+             PNDIS_OBJECT_HEADER pOffloadHeader = NULL;
+             NDIS_STATUS Status = NDIS_STATUS_SUCCESS;
+             bool StatusIndicationFlag = FALSE;

-    if (len != NDIS_SIZEOF_OFFLOAD_PARAMETERS_REVISION_2)
-    {
-        ASSERT(FALSE);
-        IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_OID,
+             if (len != NDIS_SIZEOF_OFFLOAD_PARAMETERS_REVISION_2)
+             {
+                             ASSERT(FALSE);
+                             IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_OID,
                                                ("Buffer is too small. offloading task requirs %d but the buffer "
                                                 "size is: %d \n", NDIS_SIZEOF_OFFLOAD_PARAMETERS_REVISION_2, len));
-        Status =  NDIS_STATUS_INVALID_LENGTH;
-        goto Exit;
-    }
+                             Status =  NDIS_STATUS_INVALID_LENGTH;
+                             goto Exit;
+             }

-    IPOIB_PRINT(TRACE_LEVEL_VERBOSE, IPOIB_DBG_OID,
+             IPOIB_PRINT(TRACE_LEVEL_VERBOSE, IPOIB_DBG_OID,
                                ("received set for OID_TCP_TASK_OFFLOAD\n"));

-    pOffloadParam = (PNDIS_OFFLOAD_PARAMETERS) pBuf;
-    pOffloadHeader = &(pOffloadParam->Header);
-
-    if((pOffloadHeader->Type != NDIS_OBJECT_TYPE_DEFAULT) ||
-       (pOffloadHeader->Revision != NDIS_OFFLOAD_PARAMETERS_REVISION_2) ||
-       (pOffloadHeader->Size != NDIS_SIZEOF_OFFLOAD_PARAMETERS_REVISION_2))
-    {
-        ASSERT(FALSE);
-        IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_OID,
+             pOffloadParam = (PNDIS_OFFLOAD_PARAMETERS) pBuf;
+             pOffloadHeader = &(pOffloadParam->Header);
+
+             if((pOffloadHeader->Type != NDIS_OBJECT_TYPE_DEFAULT) ||
+                (pOffloadHeader->Revision != NDIS_OFFLOAD_PARAMETERS_REVISION_2) ||
+                (pOffloadHeader->Size != NDIS_SIZEOF_OFFLOAD_PARAMETERS_REVISION_2))
+             {
+                             ASSERT(FALSE);
+                             IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_OID,
                                                ("Set offloading task Illegal header\n"));
-        Status = NDIS_STATUS_INVALID_DATA;
-        goto Exit;
-    }
+                             Status = NDIS_STATUS_INVALID_DATA;
+                             goto Exit;
+             }

-    if ((pOffloadParam->IPsecV1 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE) ||
-        (pOffloadParam->TcpConnectionIPv4 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE) ||
-        (pOffloadParam->TcpConnectionIPv6 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE) ||
-        (pOffloadParam->Flags != 0))
-    {
-        Status = NDIS_STATUS_NOT_SUPPORTED;
-        goto Exit;
-    }
+             if ((pOffloadParam->IPsecV1 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE) ||
+                             (pOffloadParam->TcpConnectionIPv4 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE) ||
+                             (pOffloadParam->TcpConnectionIPv6 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE) ||
+                             (pOffloadParam->Flags != 0))
+             {
+                             Status = NDIS_STATUS_NOT_SUPPORTED;
+                             goto Exit;
+             }

                //Eliminate currently unsupported statistic
                if ((pOffloadParam->TCPIPv6Checksum != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE) ||
                                (pOffloadParam->UDPIPv6Checksum != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE) ||
-                              (pOffloadParam->LsoV2IPv6                      != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE))
+                             (pOffloadParam->LsoV2IPv6                      != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE))
                {
                                Status = NDIS_STATUS_NOT_SUPPORTED;
-        goto Exit;
+                             goto Exit;
                }


-    BOOLEAN bRet = IsValidOffloadConfig(p_adapter, pOffloadParam);
-    if(bRet == FALSE)
-    {
-        //ASSERT(FALSE);
-        Status = NDIS_STATUS_NOT_SUPPORTED;
-        goto Exit;
-    }
+             BOOLEAN bRet = IsValidOffloadConfig(p_adapter, pOffloadParam);
+             if(bRet == FALSE)
+             {
+                             //ASSERT(FALSE);
+                             Status = NDIS_STATUS_NOT_SUPPORTED;
+                             goto Exit;
+             }

                // Set current offload configuration capabilites
                if ((pOffloadParam->IPv4Checksum == NDIS_OFFLOAD_PARAMETERS_TX_ENABLED_RX_DISABLED) ||
                                (pOffloadParam->TCPIPv4Checksum ==                NDIS_OFFLOAD_PARAMETERS_TX_ENABLED_RX_DISABLED) ||
-                              (pOffloadParam->UDPIPv4Checksum ==                 NDIS_OFFLOAD_PARAMETERS_TX_ENABLED_RX_DISABLED))
+                             (pOffloadParam->UDPIPv4Checksum ==                NDIS_OFFLOAD_PARAMETERS_TX_ENABLED_RX_DISABLED))
                {
                                p_adapter->params.send_chksum_offload = CSUM_ENABLED;
                                p_adapter->params.recv_chksum_offload = CSUM_DISABLED;
                                StatusIndicationFlag = TRUE;
                }

-              else if ((pOffloadParam->IPv4Checksum ==        NDIS_OFFLOAD_PARAMETERS_RX_ENABLED_TX_DISABLED) ||
-                              (pOffloadParam->TCPIPv4Checksum ==                 NDIS_OFFLOAD_PARAMETERS_RX_ENABLED_TX_DISABLED) ||
-                              (pOffloadParam->UDPIPv4Checksum ==                 NDIS_OFFLOAD_PARAMETERS_RX_ENABLED_TX_DISABLED))
+             else if ((pOffloadParam->IPv4Checksum ==        NDIS_OFFLOAD_PARAMETERS_RX_ENABLED_TX_DISABLED) ||
+                             (pOffloadParam->TCPIPv4Checksum ==                NDIS_OFFLOAD_PARAMETERS_RX_ENABLED_TX_DISABLED) ||
+                             (pOffloadParam->UDPIPv4Checksum ==                NDIS_OFFLOAD_PARAMETERS_RX_ENABLED_TX_DISABLED))
                {
                                p_adapter->params.recv_chksum_offload = CSUM_ENABLED;
                                p_adapter->params.send_chksum_offload = CSUM_DISABLED;
                                StatusIndicationFlag = TRUE;
                }

-              else if ((pOffloadParam->IPv4Checksum ==        NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED ) ||
-                              (pOffloadParam->TCPIPv4Checksum ==               NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED ) ||
-                              (pOffloadParam->UDPIPv4Checksum ==              NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED ))
+             else if ((pOffloadParam->IPv4Checksum ==        NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED ) ||
+                             (pOffloadParam->TCPIPv4Checksum ==               NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED ) ||
+                             (pOffloadParam->UDPIPv4Checksum ==              NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED ))
                {
                                p_adapter->params.send_chksum_offload = CSUM_ENABLED;
                                p_adapter->params.recv_chksum_offload = CSUM_ENABLED;
                                StatusIndicationFlag = TRUE;
                }
-              else if ((pOffloadParam->IPv4Checksum ==        NDIS_OFFLOAD_PARAMETERS_TX_RX_DISABLED ) ||
-                                              (pOffloadParam->TCPIPv4Checksum ==               NDIS_OFFLOAD_PARAMETERS_TX_RX_DISABLED ) ||
-                                              (pOffloadParam->UDPIPv4Checksum ==              NDIS_OFFLOAD_PARAMETERS_TX_RX_DISABLED ))
+             else if ((pOffloadParam->IPv4Checksum ==        NDIS_OFFLOAD_PARAMETERS_TX_RX_DISABLED ) ||
+                                             (pOffloadParam->TCPIPv4Checksum ==               NDIS_OFFLOAD_PARAMETERS_TX_RX_DISABLED ) ||
+                                             (pOffloadParam->UDPIPv4Checksum ==              NDIS_OFFLOAD_PARAMETERS_TX_RX_DISABLED ))
                {
                                p_adapter->params.send_chksum_offload = CSUM_DISABLED;
                                p_adapter->params.recv_chksum_offload = CSUM_DISABLED;
@@ -1644,127 +1644,127 @@



- #if 0
-    if(pOffloadParam->TCPIPv6Checksum != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
-    {
-        UpdateOffloadSeeting(pOffloadParam->TCPIPv6Checksum, pPort->Config.TCPUDPIPv4Chksum);
-        StatusIndicationFlag = TRUE;
-    }
-
-    if(pOffloadParam->UDPIPv6Checksum != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
-    {
-        UpdateOffloadSeeting(pOffloadParam->UDPIPv6Checksum, pPort->Config.TCPUDPIPv4Chksum);
-        StatusIndicationFlag = TRUE;
-    }
+ #if 0
+             if(pOffloadParam->TCPIPv6Checksum != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
+             {
+                             UpdateOffloadSeeting(pOffloadParam->TCPIPv6Checksum, pPort->Config.TCPUDPIPv4Chksum);
+                             StatusIndicationFlag = TRUE;
+             }
+
+             if(pOffloadParam->UDPIPv6Checksum != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
+             {
+                             UpdateOffloadSeeting(pOffloadParam->UDPIPv6Checksum, pPort->Config.TCPUDPIPv4Chksum);
+                             StatusIndicationFlag = TRUE;
+             }
 #endif

    // SetCheksumOffloadingModes(pPort->Config);
-
-    //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//
-
-    //////////////////////////// OFFLOAD OFFLOAD ////////////////////////////
-    if(pOffloadParam->LsoV1 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
-    {
-              p_adapter->params.lso = (pOffloadParam->LsoV1 == NDIS_OFFLOAD_PARAMETERS_LSOV1_ENABLED);
-        StatusIndicationFlag = TRUE;
-    }
-
-    if(pOffloadParam->LsoV2IPv4 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
-    {
-        p_adapter->params.lso = (pOffloadParam->LsoV1 == NDIS_OFFLOAD_PARAMETERS_LSOV2_ENABLED);
-        StatusIndicationFlag = TRUE;
-    }
-#if 0
-    if(pOffloadParam->LsoV2IPv6 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
-    {
-        if(pOffloadParam->LsoV2IPv6 == NDIS_OFFLOAD_PARAMETERS_LSOV2_ENABLED)
-        {
-            pPort->Config.LsoV2IPv6 = TRUE;
-        }
-        else
-        {
-            pPort->Config.LsoV2IPv6 = FALSE;
-        }
-
-        StatusIndicationFlag = TRUE;
-    }
+
+             //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//
+
+             //////////////////////////// OFFLOAD OFFLOAD ////////////////////////////
+             if(pOffloadParam->LsoV1 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
+             {
+                             p_adapter->params.lso = (pOffloadParam->LsoV1 == NDIS_OFFLOAD_PARAMETERS_LSOV1_ENABLED);
+                             StatusIndicationFlag = TRUE;
+             }
+
+             if(pOffloadParam->LsoV2IPv4 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
+             {
+                             p_adapter->params.lso = (pOffloadParam->LsoV1 == NDIS_OFFLOAD_PARAMETERS_LSOV2_ENABLED);
+                             StatusIndicationFlag = TRUE;
+             }
+#if 0
+             if(pOffloadParam->LsoV2IPv6 != NDIS_OFFLOAD_PARAMETERS_NO_CHANGE)
+             {
+                             if(pOffloadParam->LsoV2IPv6 == NDIS_OFFLOAD_PARAMETERS_LSOV2_ENABLED)
+                             {
+                                             pPort->Config.LsoV2IPv6 = TRUE;
+                             }
+                             else
+                             {
+                                             pPort->Config.LsoV2IPv6 = FALSE;
+                             }
+
+                             StatusIndicationFlag = TRUE;
+             }
 #endif


-    //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//
+             //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//


-    if(StatusIndicationFlag)
-    {
-        NDIS_OFFLOAD CurrentOffloadCapapilities;
-        NDIS_STATUS_INDICATION StatusIndication;
+             if(StatusIndicationFlag)
+             {
+                             NDIS_OFFLOAD CurrentOffloadCapapilities;
+                             NDIS_STATUS_INDICATION StatusIndication;

-        OffloadConfig(p_adapter, &CurrentOffloadCapapilities);
+                             OffloadConfig(p_adapter, &CurrentOffloadCapapilities);

-
-        IPOIB_INIT_NDIS_STATUS_INDICATION(&StatusIndication,
-                                       p_adapter->h_adapter,
-                                       NDIS_STATUS_TASK_OFFLOAD_CURRENT_CONFIG ,
-                                       (PVOID)&CurrentOffloadCapapilities,
-                                       sizeof(CurrentOffloadCapapilities));
-
-        NdisMIndicateStatusEx(p_adapter->h_adapter, &StatusIndication);
-    }
-
-Exit:
-    IPOIB_EXIT(IPOIB_DBG_OID);
-    return Status;
+
+                             IPOIB_INIT_NDIS_STATUS_INDICATION(&StatusIndication,
+                                                                                                                                                p_adapter->h_adapter,
+                                                                                                                                                NDIS_STATUS_TASK_OFFLOAD_CURRENT_CONFIG ,
+                                                                                                                                                (PVOID)&CurrentOffloadCapapilities,
+                                                                                                                                                sizeof(CurrentOffloadCapapilities));
+
+                             NdisMIndicateStatusEx(p_adapter->h_adapter, &StatusIndication);
+             }
+
+Exit:
+             IPOIB_EXIT(IPOIB_DBG_OID);
+             return Status;
 }

 /*++

 Routine Description:
-    The routine handles setting of OID_GEN_INTERRUPT_MODERATION.
+             The routine handles setting of OID_GEN_INTERRUPT_MODERATION.

 Arguments:
-    InformationBuffer - Pointer to the buffer that contains the data
-    InformationBufferLength - data length
-
+             InformationBuffer - Pointer to the buffer that contains the data
+             InformationBufferLength - data length
+
 Return Value:
-    NDIS_STAUS
-
+             NDIS_STAUS
+
 --*/
 static
 NDIS_STATUS
 SetInterruptModeration(
-    PVOID InformationBuffer,
-    ULONG InformationBufferLength )
+             PVOID InformationBuffer,
+             ULONG InformationBufferLength )
 {
-    IPOIB_ENTER(IPOIB_DBG_OID);
-
-    NDIS_STATUS Status = NDIS_STATUS_SUCCESS;
-
-    if (InformationBufferLength != sizeof(NDIS_INTERRUPT_MODERATION_PARAMETERS))
-    {
-        Status = NDIS_STATUS_INVALID_LENGTH;
-        goto Exit;
-    }
-
-    PNDIS_INTERRUPT_MODERATION_PARAMETERS pInteruptModerationParam =
-                    (PNDIS_INTERRUPT_MODERATION_PARAMETERS)InformationBuffer;
-
-    if ((pInteruptModerationParam->Header.Type != NDIS_OBJECT_TYPE_DEFAULT) ||
-        (pInteruptModerationParam->Header.Revision != NDIS_INTERRUPT_MODERATION_PARAMETERS_REVISION_1) ||
-        (pInteruptModerationParam->Header.Size != NDIS_SIZEOF_INTERRUPT_MODERATION_PARAMETERS_REVISION_1))
-    {
-        Status = NDIS_STATUS_INVALID_DATA;
-        goto Exit;
-    }
-    //
-    // BUGBUG: Need to handle disabling of interrupt moderation
-    //                          UH, 4-Jun-2008
-    //
-//    ASSERT(pInteruptModerationParam->Flags == NDIS_INTERRUPT_MODERATION_CHANGE_NEEDS_RESET);
-//    ASSERT(pInteruptModerationParam->InterruptModeration == NdisInterruptModerationEnabled);
+             IPOIB_ENTER(IPOIB_DBG_OID);
+
+             NDIS_STATUS Status = NDIS_STATUS_SUCCESS;
+
+             if (InformationBufferLength != sizeof(NDIS_INTERRUPT_MODERATION_PARAMETERS))
+             {
+                             Status = NDIS_STATUS_INVALID_LENGTH;
+                             goto Exit;
+             }
+
+             PNDIS_INTERRUPT_MODERATION_PARAMETERS pInteruptModerationParam =
+                                                                             (PNDIS_INTERRUPT_MODERATION_PARAMETERS)InformationBuffer;
+
+             if ((pInteruptModerationParam->Header.Type != NDIS_OBJECT_TYPE_DEFAULT) ||
+                             (pInteruptModerationParam->Header.Revision != NDIS_INTERRUPT_MODERATION_PARAMETERS_REVISION_1) ||
+                             (pInteruptModerationParam->Header.Size != NDIS_SIZEOF_INTERRUPT_MODERATION_PARAMETERS_REVISION_1))
+             {
+                             Status = NDIS_STATUS_INVALID_DATA;
+                             goto Exit;
+             }
+             //
+             // BUGBUG: Need to handle disabling of interrupt moderation
+             //                                                                                                            UH, 4-Jun-2008
+             //
+//           ASSERT(pInteruptModerationParam->Flags == NDIS_INTERRUPT_MODERATION_CHANGE_NEEDS_RESET);
+//           ASSERT(pInteruptModerationParam->InterruptModeration == NdisInterruptModerationEnabled);

 Exit:
-    IPOIB_EXIT(IPOIB_DBG_OID);
-    return Status;
+             IPOIB_EXIT(IPOIB_DBG_OID);
+             return Status;
 }


@@ -1825,17 +1825,17 @@
 /*++
 Routine Description:

-    MiniportInitialize handler
+             MiniportInitialize handler

 Arguments:

-    MiniportAdapterHandle   The handle NDIS uses to refer to us
-    MiniportDriverContext   Handle passed to NDIS when we registered the driver
-    MiniportInitParameters  Initialization parameters
-
+             MiniportAdapterHandle               The handle NDIS uses to refer to us
+             MiniportDriverContext  Handle passed to NDIS when we registered the driver
+             MiniportInitParameters                Initialization parameters
+
 Return Value:

-    NDIS_STATUS_SUCCESS unless something goes wrong
+             NDIS_STATUS_SUCCESS unless something goes wrong

 --*/

@@ -1878,7 +1878,7 @@
                                }
                                p_adapter->ipoib_state = IPOIB_INIT;

-                              status  = SetAttributes(p_adapter, h_adapter);
+                             status    = SetAttributes(p_adapter, h_adapter);
                                if (status != NDIS_STATUS_SUCCESS) {
                                                //ASSERT(FALSE);
                                                ipoib_destroy_adapter( p_adapter );
@@ -1934,14 +1934,14 @@

 //! Deallocates resources when the NIC is removed and halts the NIC..
 //TODO: Dispatch or Passive ?
-/*  IRQL = DISPATCH_LEVEL
+/*         IRQL = DISPATCH_LEVEL

 @param adapter_context The adapter context allocated at start
 */
 void
 ipoib_halt_ex(
                IN                                                           NDIS_HANDLE                                                                   adapter_context,
-              IN                                           NDIS_HALT_ACTION            HaltAction )
+             IN                                                           NDIS_HALT_ACTION                                      HaltAction )
 {
                ipoib_adapter_t               *p_adapter;

@@ -1974,7 +1974,7 @@


 //! Reports the state of the NIC, or monitors the responsiveness of an underlying device driver.
-/*  IRQL = DISPATCH_LEVEL
+/*         IRQL = DISPATCH_LEVEL

 @param adapter_context The adapter context allocated at start
 @return TRUE if the driver determines that its NIC is not operating
@@ -2051,7 +2051,7 @@
                ULONG RxChksumOffload = ((MP_GET_PORT_CONFIG(pPort, RxChksumOffload) == TRUE) ? NDIS_OFFLOAD_SET_ON : NDIS_OFFLOAD_SET_OFF);
                BOOLEAN fLargeSendOffload = MP_GET_PORT_CONFIG(pPort, LargeSendOffload);
                ULONG ulEncapsulation = NDIS_ENCAPSULATION_IEEE_802_3 | NDIS_ENCAPSULATION_IEEE_802_3_P_AND_Q;
-
+
                NdisZeroMemory(&*p_offload, sizeof(NDIS_OFFLOAD));
                *p_offload.Header.Type = NDIS_OBJECT_TYPE_OFFLOAD;
                *p_offload.Header.Revision = NDIS_OFFLOAD_REVISION_1; // BUGBUG: do we need to support revision 2? UH 17-May-2008
@@ -2086,17 +2086,17 @@

                if (fLargeSendOffload)
                {
-                  *p_offload.LsoV1.IPv4.Encapsulation = ulEncapsulation;
-                  *p_offload.LsoV1.IPv4.MaxOffLoadSize = LARGE_SEND_OFFLOAD_SIZE;
-                  *p_offload.LsoV1.IPv4.MinSegmentCount = 1;
-                  *p_offload.LsoV1.IPv4.TcpOptions = NDIS_OFFLOAD_SUPPORTED;
-                  *p_offload.LsoV1.IPv4.IpOptions = NDIS_OFFLOAD_SUPPORTED;
+                             *p_offload.LsoV1.IPv4.Encapsulation = ulEncapsulation;
+                             *p_offload.LsoV1.IPv4.MaxOffLoadSize = LARGE_SEND_OFFLOAD_SIZE;
+                             *p_offload.LsoV1.IPv4.MinSegmentCount = 1;
+                             *p_offload.LsoV1.IPv4.TcpOptions = NDIS_OFFLOAD_SUPPORTED;
+                             *p_offload.LsoV1.IPv4.IpOptions = NDIS_OFFLOAD_SUPPORTED;
                }
 }
 #endif

 //! Returns information about the capabilities and status of the driver and/or its NIC.
-/*  IRQL = DISPATCH_LEVEL
+/*         IRQL = DISPATCH_LEVEL

 @param adapter_context The adapter context allocated at start
 @param oid Object ID representing the query operation to be carried out
@@ -2111,8 +2111,8 @@

 NDIS_STATUS
 ipoib_query_info(
-    IN      NDIS_HANDLE         adapter_context,
-    IN  OUT PNDIS_OID_REQUEST   pNdisRequest )
+             IN                           NDIS_HANDLE                   adapter_context,
+             IN           OUT PNDIS_OID_REQUEST          pNdisRequest )

 {
                                ipoib_adapter_t                               *p_adapter;
@@ -2123,7 +2123,7 @@
                                ULONG                                                 buf_len;
                                pending_oid_t                  oid_info;
                                uint8_t                                                 port_num;
-                              NDIS_OFFLOAD        offload;
+                             NDIS_OFFLOAD                                offload;

                                NDIS_INTERRUPT_MODERATION_PARAMETERS InterruptModerationParam;

@@ -2366,7 +2366,7 @@
                                                IPOIB_PRINT( TRACE_LEVEL_INFORMATION,IPOIB_DBG_OID,
                                                                ("Port %d received query for OID_GEN_STATISTICS\n", port_num) );
                                                src_buf = NULL;
-                                              buf_len =  sizeof(NDIS_STATISTICS_INFO);
+                                             buf_len =           sizeof(NDIS_STATISTICS_INFO);
                                                if (oid_info.buf_len < buf_len)
                                                {
                                                   break;
@@ -2538,29 +2538,29 @@
                                                info = 0;
                                                break;
                                case OID_TCP_OFFLOAD_HARDWARE_CAPABILITIES:
-            buf_len = sizeof(NDIS_OFFLOAD);
-            if (buf_len < oid_info.buf_len)
-            {
-                *oid_info.p_bytes_needed = buf_len;
+                                             buf_len = sizeof(NDIS_OFFLOAD);
+                                             if (buf_len < oid_info.buf_len)
+                                             {
+                                                             *oid_info.p_bytes_needed = buf_len;
                                                                return NDIS_STATUS_BUFFER_TOO_SHORT;
-            }
+                                             }

-            OffloadCapabilities(p_adapter, &offload);
-            src_buf = &offload;
-            break;
+                                             OffloadCapabilities(p_adapter, &offload);
+                                             src_buf = &offload;
+                                             break;
                                case OID_GEN_INTERRUPT_MODERATION:
-            InterruptModerationParam.Header.Type = NDIS_OBJECT_TYPE_DEFAULT;
-            InterruptModerationParam.Header.Revision =
+                                             InterruptModerationParam.Header.Type = NDIS_OBJECT_TYPE_DEFAULT;
+                                             InterruptModerationParam.Header.Revision =
                                                                                                                NDIS_INTERRUPT_MODERATION_PARAMETERS_REVISION_1;
-            InterruptModerationParam.Header.Size =
+                                             InterruptModerationParam.Header.Size =
                                                                                                NDIS_SIZEOF_INTERRUPT_MODERATION_PARAMETERS_REVISION_1;
-            InterruptModerationParam.Flags =
+                                             InterruptModerationParam.Flags =
                                                                                                                                NDIS_INTERRUPT_MODERATION_CHANGE_NEEDS_RESET;
-            InterruptModerationParam.InterruptModeration =
+                                             InterruptModerationParam.InterruptModeration =
                                                                                                                                                                NdisInterruptModerationNotSupported;
-            buf_len = sizeof(NDIS_INTERRUPT_MODERATION_PARAMETERS);
-            src_buf = (PVOID) &InterruptModerationParam;
-            break;
+                                             buf_len = sizeof(NDIS_INTERRUPT_MODERATION_PARAMETERS);
+                                             src_buf = (PVOID) &InterruptModerationParam;
+                                             break;

                                /* Optional General */
                                case OID_GEN_SUPPORTED_GUIDS:
@@ -2613,7 +2613,7 @@
                                                                ("Port %d received query for OID_TCP_OFFLOAD_CURRENT_CONFIG\n",
                                                                                port_num) );
                                                                //ulBytesAvailable = ulInfoLen = sizeof(NDIS_OFFLOAD);
-                                                              if (oid_info.buf_len <  sizeof(NDIS_OFFLOAD))
+                                                             if (oid_info.buf_len <     sizeof(NDIS_OFFLOAD))
                                                                {

                                                                                *oid_info.p_bytes_needed = sizeof(NDIS_OFFLOAD) ;
@@ -2726,43 +2726,43 @@
 static
 NDIS_STATUS
 SetOffloadEncapsulation(
-    void* const pBuf,
-    ULONG len
-    )
+             void* const pBuf,
+             ULONG len
+             )
 {
-    ASSERT(pBuf != NULL);
-
-    PNDIS_OFFLOAD_ENCAPSULATION pOffload;
-    PNDIS_OBJECT_HEADER pOffloadHeader;
+             ASSERT(pBuf != NULL);
+
+             PNDIS_OFFLOAD_ENCAPSULATION pOffload;
+             PNDIS_OBJECT_HEADER pOffloadHeader;

-    if (len != sizeof(NDIS_OFFLOAD_ENCAPSULATION))
-    {
-        ASSERT(FALSE);
-        IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_OID, ("Buffer is too small. offloading task requirs %d but the buffer size is: %d \n", sizeof(NDIS_OFFLOAD_ENCAPSULATION), len));
-        return  NDIS_STATUS_INVALID_DATA;
-    }
+             if (len != sizeof(NDIS_OFFLOAD_ENCAPSULATION))
+             {
+                             ASSERT(FALSE);
+                             IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_OID, ("Buffer is too small. offloading task requirs %d but the buffer size is: %d \n", sizeof(NDIS_OFFLOAD_ENCAPSULATION), len));
+                             return   NDIS_STATUS_INVALID_DATA;
+             }

-    pOffload= (PNDIS_OFFLOAD_ENCAPSULATION) pBuf;
-    pOffloadHeader = &(pOffload->Header);
+             pOffload= (PNDIS_OFFLOAD_ENCAPSULATION) pBuf;
+             pOffloadHeader = &(pOffload->Header);

-    if((pOffloadHeader->Type != NDIS_OBJECT_TYPE_OFFLOAD_ENCAPSULATION) ||
-       (pOffloadHeader->Revision != NDIS_OFFLOAD_ENCAPSULATION_REVISION_1) ||
-       (pOffloadHeader->Size != NDIS_SIZEOF_OFFLOAD_ENCAPSULATION_REVISION_1))
-    {
-        ASSERT(FALSE);
-        IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_OID, ("Set offloading task Illegal header\n"));
-        return NDIS_STATUS_INVALID_DATA;
-    }
+             if((pOffloadHeader->Type != NDIS_OBJECT_TYPE_OFFLOAD_ENCAPSULATION) ||
+                (pOffloadHeader->Revision != NDIS_OFFLOAD_ENCAPSULATION_REVISION_1) ||
+                (pOffloadHeader->Size != NDIS_SIZEOF_OFFLOAD_ENCAPSULATION_REVISION_1))
+             {
+                             ASSERT(FALSE);
+                             IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_OID, ("Set offloading task Illegal header\n"));
+                             return NDIS_STATUS_INVALID_DATA;
+             }

-    //
-    // BUGBUG: Need to handle the offload parameter setting
-    //
-    return NDIS_STATUS_SUCCESS;
+             //
+             // BUGBUG: Need to handle the offload parameter setting
+             //
+             return NDIS_STATUS_SUCCESS;
 }


 //! Issues a hardware reset to the NIC and/or resets the driver's software state.
-/*  Tear down the connection and start over again.  This is only called when there is a problem.
+/*         Tear down the connection and start over again.                This is only called when there is a problem.
 For example, if a send, query info, or set info had a time out.  MiniportCheckForHang will
 be called first.
 IRQL = DISPATCH_LEVEL
@@ -2775,8 +2775,8 @@
 */
 NDIS_STATUS
 ipoib_reset(
-    IN  NDIS_HANDLE     adapter_context,
-    OUT PBOOLEAN        p_addr_reset)
+             IN           NDIS_HANDLE   adapter_context,
+             OUT PBOOLEAN                               p_addr_reset)
 {
                ipoib_adapter_t* p_adapter;

@@ -2808,7 +2808,7 @@


 //! Request changes in the state information that the miniport driver maintains
-/*  For example, this is used to set multicast addresses and the packet filter.
+/*         For example, this is used to set multicast addresses and the packet filter.
 IRQL = DISPATCH_LEVEL

 @param adapter_context The adapter context allocated at start
@@ -2823,8 +2823,8 @@
 */
 NDIS_STATUS
 ipoib_set_info(
-    IN      NDIS_HANDLE         adapter_context,
-    IN  OUT PNDIS_OID_REQUEST   pNdisRequest)
+             IN                           NDIS_HANDLE                   adapter_context,
+             IN           OUT PNDIS_OID_REQUEST          pNdisRequest)

 {
                ipoib_adapter_t*            p_adapter;
@@ -2840,11 +2840,11 @@
                CL_ASSERT( adapter_context );
                p_adapter = (ipoib_adapter_t*)adapter_context;

-              NDIS_OID    oid = pNdisRequest->DATA.SET_INFORMATION.Oid;
-              PVOID       info_buf = pNdisRequest->DATA.SET_INFORMATION.InformationBuffer;
-              UINT        info_buf_len = pNdisRequest->DATA.SET_INFORMATION.InformationBufferLength;
+             NDIS_OID            oid = pNdisRequest->DATA.SET_INFORMATION.Oid;
+             PVOID                   info_buf = pNdisRequest->DATA.SET_INFORMATION.InformationBuffer;
+             UINT                      info_buf_len = pNdisRequest->DATA.SET_INFORMATION.InformationBufferLength;
                PULONG                              p_bytes_read = (PULONG)&pNdisRequest->DATA.SET_INFORMATION.BytesRead;
-              PULONG                              p_bytes_needed = (PULONG)&pNdisRequest->DATA.SET_INFORMATION.BytesNeeded;
+             PULONG                              p_bytes_needed = (PULONG)&pNdisRequest->DATA.SET_INFORMATION.BytesNeeded;

                CL_ASSERT( p_bytes_read );
                CL_ASSERT( p_bytes_needed );
@@ -3089,10 +3089,10 @@

 static NDIS_STATUS
 ipoib_oid_handler(
-    IN      NDIS_HANDLE         adapter_context,
-    IN  OUT PNDIS_OID_REQUEST   pNdisRequest)
+             IN                           NDIS_HANDLE                   adapter_context,
+             IN           OUT PNDIS_OID_REQUEST          pNdisRequest)
 {
-    NDIS_REQUEST_TYPE       RequestType;
+             NDIS_REQUEST_TYPE                    RequestType;
                NDIS_STATUS    status = NDIS_STATUS_SUCCESS;

                IPOIB_ENTER( IPOIB_DBG_OID );
@@ -3101,28 +3101,28 @@

                switch(RequestType)
                {
-        case NdisRequestSetInformation:
-            status = ipoib_set_info(adapter_context, pNdisRequest);
-            break;
-
-        case NdisRequestQueryInformation:
-        case NdisRequestQueryStatistics:
-            status = ipoib_query_info(adapter_context, pNdisRequest);
+                             case NdisRequestSetInformation:
+                                             status = ipoib_set_info(adapter_context, pNdisRequest);
+                                             break;
+
+                             case NdisRequestQueryInformation:
+                             case NdisRequestQueryStatistics:
+                                             status = ipoib_query_info(adapter_context, pNdisRequest);

-            break;
+                                             break;

-        default:
-            status = NDIS_STATUS_NOT_SUPPORTED;
-            break;
+                             default:
+                                             status = NDIS_STATUS_NOT_SUPPORTED;
+                                             break;
                }
                IPOIB_EXIT( IPOIB_DBG_OID );
                return status;
 }

 /* Transfers some number of packets, specified as an array of packet pointers,
- *  over the network.
- *  For a deserialized driver, these packets are completed asynchronously
- *  using NdisMSendComplete.
+ *          over the network.
+ *          For a deserialized driver, these packets are completed asynchronously
+ *          using NdisMSendComplete.
  * IRQL <= DISPATCH_LEVEL

  @param adapter_context - Pointer to ipoib_adapter_t structure with per NIC state
@@ -3132,16 +3132,16 @@
 */
 void
 ipoib_send_net_buffer_list(
-    IN  NDIS_HANDLE         adapter_context,
-    IN  PNET_BUFFER_LIST    net_buffer_list,
-    IN  NDIS_PORT_NUMBER    port_num,
-    IN  ULONG               send_flags )
+             IN           NDIS_HANDLE                   adapter_context,
+             IN           PNET_BUFFER_LIST        net_buffer_list,
+             IN           NDIS_PORT_NUMBER   port_num,
+             IN           ULONG                                                 send_flags )
 {
                ipoib_adapter_t                               *p_adapter;
                ipoib_port_t                      *p_port;
                ULONG                                                 send_complete_flags;
-    PNET_BUFFER_LIST    curr_net_buffer_list;
-    PNET_BUFFER_LIST    next_net_buffer_list;
+             PNET_BUFFER_LIST        curr_net_buffer_list;
+             PNET_BUFFER_LIST        next_net_buffer_list;
                NDIS_STATUS    status = NDIS_STATUS_SUCCESS;

                UNREFERENCED_PARAMETER(port_num);
@@ -3191,9 +3191,9 @@
                                ipoib_cnt_inc( &p_adapter->n_send_NBL );

                                next_net_buffer_list = NET_BUFFER_LIST_NEXT_NBL(curr_net_buffer_list);
-        KeMemoryBarrierWithoutFence();
+                             KeMemoryBarrierWithoutFence();
                                // Important issue, break the connection between the different nbls
-        NET_BUFFER_LIST_NEXT_NBL(curr_net_buffer_list) = NULL;
+                             NET_BUFFER_LIST_NEXT_NBL(curr_net_buffer_list) = NULL;

                                cl_perf_start( PortSend );
                                IPOIB_PRINT( TRACE_LEVEL_VERBOSE, IPOIB_DBG_BUF,
@@ -3211,14 +3211,14 @@
                cl_perf_log( &p_adapter->perf, SendBundle, 1 );

 compl_status:
-    if (status != NDIS_STATUS_SUCCESS)
+             if (status != NDIS_STATUS_SUCCESS)
                {

                                IPOIB_PRINT( TRACE_LEVEL_ERROR, IPOIB_DBG_ERROR,
                                                                ("Got bad status, g_NBL=%d, g_NBL_completed=%d \n",
                                                                g_NBL, g_NBL_complete) );
                                send_complete_flags = 0;
-
+
                                for (curr_net_buffer_list = net_buffer_list;
                                                                 curr_net_buffer_list != NULL;
                                                                 curr_net_buffer_list = next_net_buffer_list)
@@ -3277,7 +3277,7 @@

 VOID
 ipoib_shutdown_ex(
-              IN NDIS_HANDLE  adapter_context,
+             IN NDIS_HANDLE             adapter_context,
                IN NDIS_SHUTDOWN_ACTION  shutdown_action)
 {
                IPOIB_ENTER( IPOIB_DBG_INIT ) ;
@@ -3562,16 +3562,16 @@
                                                // otherwise, it can lead to a memory violation (happened when AddressCount was > 1)
                                                if( p_net_addr_oid->AddressLength != NETWORK_ADDRESS_LENGTH_IP)
                                                {
-                                                              IPOIB_PRINT( TRACE_LEVEL_ERROR, IPOIB_DBG_ERROR,
+                                                             IPOIB_PRINT(TRACE_LEVEL_ERROR, IPOIB_DBG_ERROR,
                                                                                ("Port %d OID_GEN_NETWORK_LAYER_ADDRESSES - Address %d is wrong size of %d, "
                                                                                                "should be %d\n", port_num, i, p_net_addr_oid->AddressLength,
                                                                                                NETWORK_ADDRESS_LENGTH_IP));
                                                                ASSERT ( p_net_addr_oid->AddressLength == NETWORK_ADDRESS_LENGTH_IPX );
                                                                break;
                                                }
-
+
                                                ASSERT( p_net_addr_oid->AddressType == NDIS_PROTOCOL_ID_TCP_IP );
-
+
                                                p_ip_addr = (PNETWORK_ADDRESS_IP)p_net_addr_oid->Address;
                                                if( !cl_memcmp( &p_ip_addr->in_addr,
                                                                &p_addr_item->address.as_ulong, sizeof(ULONG) ) )
@@ -3737,7 +3737,7 @@
                if(p_adapter->guids.port_guid.pkey != IB_DEFAULT_PKEY)
                {
                                IPOIB_PRINT_EXIT( TRACE_LEVEL_ERROR,IPOIB_DBG_ERROR,
-                              ("ATS Service available for default pkey only\n"));
+                             ("ATS Service available for default pkey only\n"));
                                return;
                }
                port_num = p_adapter->guids.port_num;
@@ -3761,7 +3761,7 @@
                                ("Problem copying ATS name: exiting\n"));
                                return;
                }
-
+
                /* IP Address in question will be put in below */
                ib_service.port_guid                      = p_adapter->guids.port_guid.guid;
                ib_service.timeout_ms                 = p_adapter->params.sa_timeout;
@@ -3786,7 +3786,7 @@
                for( idx = 0; idx < cl_vector_get_size( &p_adapter->ip_vector); idx++ )
                {
                                p_addr_item = (net_address_item_t*)
-                                              cl_vector_get_ptr(  &p_adapter->ip_vector, idx );
+                                             cl_vector_get_ptr(          &p_adapter->ip_vector, idx );

                                if( p_addr_item->p_reg )
                                                continue;
@@ -3972,8 +3972,8 @@

 static NDIS_STATUS
 ipoib_pause(
-    IN  NDIS_HANDLE                         adapter_context,
-    IN  PNDIS_MINIPORT_PAUSE_PARAMETERS     pause_parameters)
+             IN           NDIS_HANDLE                                                                                   adapter_context,
+             IN           PNDIS_MINIPORT_PAUSE_PARAMETERS             pause_parameters)
 {
                ipoib_adapter_t                               *p_adapter;
                KLOCK_QUEUE_HANDLE              hdl;
@@ -4009,26 +4009,26 @@

 static NDIS_STATUS
 ipoib_restart(
-    IN  NDIS_HANDLE                         adapter_context,
-    IN  PNDIS_MINIPORT_RESTART_PARAMETERS   restart_parameters)
+             IN           NDIS_HANDLE                                                                                   adapter_context,
+             IN           PNDIS_MINIPORT_RESTART_PARAMETERS         restart_parameters)
 {
                ipoib_adapter_t                               *p_adapter;
                KLOCK_QUEUE_HANDLE              hdl;
-    PNDIS_RESTART_ATTRIBUTES     NdisRestartAttributes;
-    PNDIS_RESTART_GENERAL_ATTRIBUTES  NdisGeneralAttributes;
+             PNDIS_RESTART_ATTRIBUTES    NdisRestartAttributes;
+             PNDIS_RESTART_GENERAL_ATTRIBUTES  NdisGeneralAttributes;

                IPOIB_ENTER( IPOIB_DBG_INIT );
                p_adapter = (ipoib_adapter_t*)adapter_context;

                NdisRestartAttributes = restart_parameters->RestartAttributes;

-    if (NdisRestartAttributes != NULL)
-    {
-        CL_ASSERT(NdisRestartAttributes->Oid == OID_GEN_MINIPORT_RESTART_ATTRIBUTES);
-        NdisGeneralAttributes = (PNDIS_RESTART_GENERAL_ATTRIBUTES)NdisRestartAttributes->Data;
-        //
-        // Check to see if we need to change any attributes
-    }
+             if (NdisRestartAttributes != NULL)
+             {
+                             CL_ASSERT(NdisRestartAttributes->Oid == OID_GEN_MINIPORT_RESTART_ATTRIBUTES);
+                             NdisGeneralAttributes = (PNDIS_RESTART_GENERAL_ATTRIBUTES)NdisRestartAttributes->Data;
+                             //
+                             // Check to see if we need to change any attributes
+             }

                if ( (p_adapter->ipoib_state == IPOIB_PAUSED) || (p_adapter->ipoib_state == IPOIB_INIT) ) {
                                IPOIB_PRINT( TRACE_LEVEL_INFORMATION, IPOIB_DBG_RECV,
@@ -4046,37 +4046,37 @@


                IPOIB_EXIT( IPOIB_DBG_INIT );
-    return NDIS_STATUS_SUCCESS;
+             return NDIS_STATUS_SUCCESS;
 }

 /*++
 Routine Description:

-    This function aborts the request pending in the miniport.
+             This function aborts the request pending in the miniport.

 Arguments:

-    MiniportAdapterContext  Pointer to the adapter structure
-    RequestId               Specify the request to be cancelled.
-
+             MiniportAdapterContext             Pointer to the adapter structure
+             RequestId                                                           Specify the request to be cancelled.
+
 Return Value:
-
+
 --*/
 static void
 ipoib_cancel_oid_request(
-    IN  NDIS_HANDLE            adapter_context,
-    IN  PVOID                  requestId
-    )
+             IN           NDIS_HANDLE                      adapter_context,
+             IN           PVOID                                                      requestId
+             )
 {
-    PNDIS_OID_REQUEST    pending_request;
+             PNDIS_OID_REQUEST    pending_request;
                ipoib_adapter_t                               *p_adapter;

                IPOIB_ENTER( IPOIB_DBG_OID );
                p_adapter = (ipoib_adapter_t*)adapter_context;

-    cl_obj_lock( &p_adapter->obj );
-
-    if ( p_adapter->query_oid.p_pending_oid &&
+             cl_obj_lock( &p_adapter->obj );
+
+             if ( p_adapter->query_oid.p_pending_oid &&
                                p_adapter->query_oid.p_pending_oid->RequestId == requestId)
                {
                                pending_request = p_adapter->query_oid.p_pending_oid;
@@ -4097,11 +4097,11 @@
                                ("No Pending OID found\n") );
                                return;
                }
-    cl_obj_unlock( &p_adapter->obj );
+             cl_obj_unlock( &p_adapter->obj );

-    NdisMOidRequestComplete(p_adapter->h_adapter,
-                            pending_request,
-                            NDIS_STATUS_REQUEST_ABORTED);
+             NdisMOidRequestComplete(p_adapter->h_adapter,
+                                                                                                             pending_request,
+                                                                                                             NDIS_STATUS_REQUEST_ABORTED);

-    IPOIB_EXIT( IPOIB_DBG_OID );
+             IPOIB_EXIT( IPOIB_DBG_OID );
 }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openfabrics.org/pipermail/ofw/attachments/20100921/967c4362/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ipoib_driver_spacing_and_tabulations.patch
Type: application/octet-stream
Size: 73704 bytes
Desc: ipoib_driver_spacing_and_tabulations.patch
URL: <http://lists.openfabrics.org/pipermail/ofw/attachments/20100921/967c4362/attachment.obj>


More information about the ofw mailing list