[ofw] [PATCH 1/13] DAPL v2.0: common: CR EVD overflow causes segfault.

Davis, Arlin R arlin.r.davis at intel.com
Fri Jan 13 15:54:42 PST 2012


Clean up Bugzilla bugs. Patch set resulting from negative testing of connection
protocol and DAT interfaces for all OpenFabrics DAPL providers (cma, scm, ucm). 

The CR is freed up incorrectly before unlinking with SP.

Signed-off-by: Arlin Davis <arlin.r.davis at intel.com>
---
 dapl/common/dapl_cr_callback.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dapl/common/dapl_cr_callback.c b/dapl/common/dapl_cr_callback.c
index 3997b38..c58444b 100644
--- a/dapl/common/dapl_cr_callback.c
+++ b/dapl/common/dapl_cr_callback.c
@@ -414,7 +414,6 @@ dapli_connection_request(IN dp_ib_cm_handle_t ib_cm_handle,
 						     (DAT_CR_HANDLE) cr_ptr);
 
 	if (dat_status != DAT_SUCCESS) {
-		dapls_cr_free(cr_ptr);
 		(void)dapls_ib_reject_connection(ib_cm_handle,
 						 DAT_CONNECTION_EVENT_BROKEN,
 						 0, NULL);
@@ -423,6 +422,7 @@ dapli_connection_request(IN dp_ib_cm_handle_t ib_cm_handle,
 		dapl_os_lock(&sp_ptr->header.lock);
 		dapl_sp_remove_cr(sp_ptr, cr_ptr);
 		dapl_os_unlock(&sp_ptr->header.lock);
+		dapls_cr_free(cr_ptr);
 		return DAT_INSUFFICIENT_RESOURCES;
 	}
 
-- 
1.7.3





More information about the ofw mailing list