[ofw] [PATCH] DAPL v2.0: common: posting events on full queue returns wrong error code
Davis, Arlin R
arlin.r.davis at intel.com
Wed Nov 2 14:34:32 PDT 2011
return DAT_QUEUE_FULL instead of DAT_INSUFFICIENT_RESOURCES
Signed-off-by: Arlin Davis <arlin.r.davis at intel.com>
---
dapl/common/dapl_evd_util.c | 17 ++++++++---------
1 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/dapl/common/dapl_evd_util.c b/dapl/common/dapl_evd_util.c
index 9171415..41423b2 100644
--- a/dapl/common/dapl_evd_util.c
+++ b/dapl/common/dapl_evd_util.c
@@ -712,7 +712,7 @@ dapls_evd_post_cr_arrival_event(IN DAPL_EVD * evd_ptr,
err:
dapl_os_unlock(&evd_ptr->header.lock);
dapls_evd_post_overflow_event(evd_ptr);
- return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES, DAT_RESOURCE_MEMORY);
+ return DAT_ERROR(DAT_QUEUE_FULL, 0);
}
DAT_RETURN
@@ -741,7 +741,7 @@ dapls_evd_post_connection_event(IN DAPL_EVD * evd_ptr,
err:
dapl_os_unlock(&evd_ptr->header.lock);
dapls_evd_post_overflow_event(evd_ptr);
- return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES, DAT_RESOURCE_MEMORY);
+ return DAT_ERROR(DAT_QUEUE_FULL, 0);
}
DAT_RETURN
@@ -770,7 +770,7 @@ dapls_evd_post_async_error_event(IN DAPL_EVD * evd_ptr,
err:
dapl_os_unlock(&evd_ptr->header.lock);
dapls_evd_post_overflow_event(evd_ptr);
- return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES, DAT_RESOURCE_MEMORY);
+ return DAT_ERROR(DAT_QUEUE_FULL, 0);
}
DAT_RETURN
@@ -794,7 +794,7 @@ dapls_evd_post_software_event(IN DAPL_EVD * evd_ptr,
err:
dapl_os_unlock(&evd_ptr->header.lock);
dapls_evd_post_overflow_event(evd_ptr);
- return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES, DAT_RESOURCE_MEMORY);
+ return DAT_ERROR(DAT_QUEUE_FULL, 0);
}
/*
@@ -835,7 +835,7 @@ dapls_evd_post_generic_event(IN DAPL_EVD * evd_ptr,
err:
dapl_os_unlock(&evd_ptr->header.lock);
dapls_evd_post_overflow_event(evd_ptr);
- return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES, DAT_RESOURCE_MEMORY);
+ return DAT_ERROR(DAT_QUEUE_FULL, 0);
}
#ifdef DAT_EXTENSIONS
@@ -876,8 +876,7 @@ dapls_evd_post_event_ext(IN DAPL_EVD * evd_ptr,
if (event_ptr == NULL) {
dapl_os_unlock(&evd_ptr->header.lock);
- return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES,
- DAT_RESOURCE_MEMORY);
+ return DAT_ERROR(DAT_QUEUE_FULL,0);
}
/* copy event and extended data */
@@ -926,7 +925,7 @@ dapls_evd_do_post_cr_event_ext(IN DAPL_EVD * evd_ptr,
err:
dapl_os_unlock(&evd_ptr->header.lock);
dapls_evd_post_overflow_event(evd_ptr);
- return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES, DAT_RESOURCE_MEMORY);
+ return DAT_ERROR(DAT_QUEUE_FULL, 0);
}
DAT_RETURN
@@ -1059,7 +1058,7 @@ dapls_evd_post_connection_event_ext(IN DAPL_EVD * evd_ptr,
err:
dapl_os_unlock(&evd_ptr->header.lock);
dapls_evd_post_overflow_event(evd_ptr);
- return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES, DAT_RESOURCE_MEMORY);
+ return DAT_ERROR(DAT_QUEUE_FULL, 0);
}
#endif
--
1.7.3
More information about the ofw
mailing list