ibal/cm: allow RDMA writes for QP attributes by default
authorshefty <shefty@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Fri, 7 Aug 2009 18:48:52 +0000 (18:48 +0000)
committershefty <shefty@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Fri, 7 Aug 2009 18:48:52 +0000 (18:48 +0000)
Enable remote RDMA writes as the default QP attributes for INIT
transitions.  Previously, RDMA writes were only enabled if the CM
messages carried a responder resources > 0.  However, responder
resources indicates whether RDMA reads/atomics should be enabled,
not RDMA writes.

Without this patch, users of winverbs that connect in-band that
want to perform RDMA writes without performing RDMA reads will
see QP errors when performing writes.

Signed-off-by: Sean Hefty <sean.hefty@intel.com>
git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@2334 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

core/al/kernel/al_cm_cep.c

index be0a004..f1ee549 100644 (file)
@@ -6198,12 +6198,10 @@ al_cep_get_init_attr(
                        p_cep->av[p_cep->idx_primary].attr.port_num;\r
                p_init->state.init.pkey_index =\r
                        p_cep->av[p_cep->idx_primary].pkey_index;\r
-               p_init->state.init.access_ctrl = IB_AC_LOCAL_WRITE;\r
+               p_init->state.init.access_ctrl = IB_AC_LOCAL_WRITE | IB_AC_RDMA_WRITE;\r
                if ( p_cep->resp_res )\r
                {\r
-                       p_init->state.init.access_ctrl |= IB_AC_RDMA_READ |\r
-                                                                                         IB_AC_RDMA_WRITE |\r
-                                                                                         IB_AC_ATOMIC;\r
+                       p_init->state.init.access_ctrl |= IB_AC_RDMA_READ | IB_AC_ATOMIC;\r
                }\r
                status = IB_SUCCESS;\r
                break;\r