[openib-general] [PATCHv2] kDAPL: remove DAT_RETURN

Tom Duffy tduffy at sun.com
Thu May 12 08:01:10 PDT 2005


This is the same patch I sent out yesterday to remove DAT_RETURN, just
rebased against v2313.

Signed-off-by: Tom Duffy <tduffy at sun.com>

diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat/api.c linux-kernel2/dat/api.c
--- linux-kernel/dat/api.c	2005-05-12 07:46:08.886002000 -0700
+++ linux-kernel2/dat/api.c	2005-05-12 07:47:31.724000000 -0700
@@ -44,7 +44,7 @@
  * Function: dat_strerror_major
  ***********************************************************************/
 
-static DAT_RETURN dat_strerror_major(DAT_RETURN value, const char **message)
+static u32 dat_strerror_major(u32 value, const char **message)
 {
 	switch (DAT_GET_TYPE(value)) {
 	case DAT_SUCCESS:
@@ -163,7 +163,7 @@ static DAT_RETURN dat_strerror_major(DAT
 /***********************************************************************
  * Function: dat_strerror_minor
  ***********************************************************************/
-static DAT_RETURN dat_strerror_minor(DAT_RETURN value, const char **message)
+static u32 dat_strerror_minor(u32 value, const char **message)
 {
 	switch (DAT_GET_SUBTYPE(value)) {
 
@@ -575,16 +575,13 @@ static DAT_RETURN dat_strerror_minor(DAT
  * Function: dat_ia_openv
  ***********************************************************************/
 
-DAT_RETURN dat_ia_openv(const DAT_NAME_PTR name,
-                        DAT_COUNT async_event_qlen,
-                        DAT_EVD_HANDLE *async_event_handle,
-                        DAT_IA_HANDLE *ia_handle,
-                        u32 dat_major, u32 dat_minor,
-                        boolean_t thread_safety)
+u32 dat_ia_openv(const DAT_NAME_PTR name, DAT_COUNT async_event_qlen,
+		 DAT_EVD_HANDLE *async_event_handle, DAT_IA_HANDLE *ia_handle,
+		 u32 dat_major, u32 dat_minor, boolean_t thread_safety)
 {
 	DAT_IA_OPEN_FUNC ia_open_func;
 	struct dat_provider_info info;
-        DAT_RETURN status;
+        u32 status;
 	size_t len;
 
 	dat_dbg_print(DAT_DBG_CLASS_CONSUMER_API,
@@ -628,11 +625,11 @@ EXPORT_SYMBOL(dat_ia_openv);
  * Function: dat_ia_close
  ***********************************************************************/
 
-DAT_RETURN dat_ia_close(DAT_IA_HANDLE ia_handle, DAT_CLOSE_FLAGS flags)
+u32 dat_ia_close(DAT_IA_HANDLE ia_handle, DAT_CLOSE_FLAGS flags)
 {
 	struct dat_provider *provider;
 	struct dat_provider_attr provider_attr;
-        DAT_RETURN status;
+        u32 status;
 	const char *ia_name;
 
 	dat_dbg_print(DAT_DBG_CLASS_CONSUMER_API, 
@@ -682,8 +679,8 @@ EXPORT_SYMBOL(dat_ia_close);
  * Function: dat_strerror
  ***********************************************************************/
 
-DAT_RETURN dat_strerror(DAT_RETURN value, const char **major_message, 
-                        const char **minor_message)
+u32 dat_strerror(u32 value, const char **major_message,
+		 const char **minor_message)
 {
 
         dat_dbg_print(DAT_DBG_CLASS_CONSUMER_API,
@@ -692,9 +689,9 @@ DAT_RETURN dat_strerror(DAT_RETURN value
 
 	/*
 	 * The DAT specification contains a note to implementers
-	 * suggesting that the consumer's DAT_RETURN value be used
+	 * suggesting that the consumer's return value be used
 	 * as an index into a table of text strings. However,
-	 * the DAT_RETURN values are not consecutive. Therefore this
+	 * the return values are not consecutive. Therefore this
 	 * implementation does not follow the suggested implementation.
 	 */
 
@@ -715,8 +712,8 @@ EXPORT_SYMBOL(dat_strerror);
  * Function: dat_registry_add_provider
  ***********************************************************************/
 
-DAT_RETURN dat_registry_add_provider(const struct dat_provider *provider,
-                                     const struct dat_provider_info *provider_info)
+u32 dat_registry_add_provider(const struct dat_provider *provider,
+			      const struct dat_provider_info *provider_info)
 {
 	dat_dbg_print(DAT_DBG_CLASS_PROVIDER_API, 
                       "%s(ia:%s, ver:%x.%x, thrd_safe:%x)\n",
@@ -740,8 +737,8 @@ EXPORT_SYMBOL(dat_registry_remove_provid
  * Function: dat_registry_remove_provider
  ***********************************************************************/
 
-DAT_RETURN dat_registry_remove_provider(const struct dat_provider *provider,
-                                        const struct dat_provider_info *provider_info)
+u32 dat_registry_remove_provider(const struct dat_provider *provider,
+				 const struct dat_provider_info *provider_info)
 {
 	dat_dbg_print(DAT_DBG_CLASS_PROVIDER_API,
 		      "%s(ia:%s)\n",
@@ -759,13 +756,12 @@ EXPORT_SYMBOL(dat_registry_add_provider)
  *  Function: dat_registry_list_providers
  ***********************************************************************/
 
-DAT_RETURN dat_registry_list_providers(DAT_COUNT max_to_return,
-                                       DAT_COUNT *entries_returned,
-                                       struct dat_provider_info *(dat_provider_list[]))
+u32 dat_registry_list_providers(DAT_COUNT max_to_return,
+				DAT_COUNT *entries_returned,
+				struct dat_provider_info *(dat_provider_list[]))
 {
-	DAT_RETURN status;
+	u32 status = DAT_SUCCESS;
 
-	status = DAT_SUCCESS;
 	dat_dbg_print(DAT_DBG_CLASS_CONSUMER_API, 
                       "%s(max_to_return:%i, entries_rtrn:%p, prvdr_list:%p)\n",
                       __func__, max_to_return, entries_returned, 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat/consumer.c linux-kernel2/dat/consumer.c
--- linux-kernel/dat/consumer.c	2005-05-10 10:19:45.654000000 -0700
+++ linux-kernel2/dat/consumer.c	2005-05-11 11:22:58.743960000 -0700
@@ -47,7 +47,7 @@
  * Function: dat_strerror_major
  ***********************************************************************/
 
-static DAT_RETURN dat_strerror_major(DAT_RETURN value, const char **message)
+static u32 dat_strerror_major(u32 value, const char **message)
 {
 	switch (DAT_GET_TYPE(value)) {
 	case DAT_SUCCESS:
@@ -166,7 +166,7 @@ static DAT_RETURN dat_strerror_major(DAT
 /***********************************************************************
  * Function: dat_strerror_minor
  ***********************************************************************/
-static DAT_RETURN dat_strerror_minor(DAT_RETURN value, const char **message)
+static u32 dat_strerror_minor(u32 value, const char **message)
 {
 	switch (DAT_GET_SUBTYPE(value)) {
 
@@ -574,7 +574,7 @@ static DAT_RETURN dat_strerror_minor(DAT
  *                                                                   *
  *********************************************************************/
 
-DAT_RETURN
+u32
 dat_ia_openv(const DAT_NAME_PTR name,
 	     DAT_COUNT async_event_qlen,
 	     DAT_EVD_HANDLE * async_event_handle,
@@ -584,7 +584,7 @@ dat_ia_openv(const DAT_NAME_PTR name,
 {
 	DAT_IA_OPEN_FUNC ia_open_func;
 	DAT_PROVIDER_INFO info;
-        DAT_RETURN status;
+        u32 status;
 	size_t len;
 
 	dat_dbg_print(DAT_DBG_CLASS_CONSUMER_API,
@@ -627,11 +627,11 @@ dat_ia_openv(const DAT_NAME_PTR name,
 
 EXPORT_SYMBOL(dat_ia_openv);
 
-DAT_RETURN dat_ia_close(DAT_IA_HANDLE ia_handle, DAT_CLOSE_FLAGS flags)
+u32 dat_ia_close(DAT_IA_HANDLE ia_handle, DAT_CLOSE_FLAGS flags)
 {
 	struct dat_provider *provider;
 	struct dat_provider_attr provider_attr;
-        DAT_RETURN status;
+        u32 status;
 	const char *ia_name;
 
 	dat_dbg_print(DAT_DBG_CLASS_CONSUMER_API, 
@@ -681,9 +681,8 @@ DAT_RETURN dat_ia_close(DAT_IA_HANDLE ia
 
 EXPORT_SYMBOL(dat_ia_close);
 
-DAT_RETURN
-dat_strerror(DAT_RETURN value,
-	     const char **major_message, const char **minor_message)
+u32
+dat_strerror(u32 value, const char **major_message, const char **minor_message)
 {
 
         dat_dbg_print(DAT_DBG_CLASS_CONSUMER_API,
@@ -692,9 +691,9 @@ dat_strerror(DAT_RETURN value,
 
 	/*
 	 * The DAT specification contains a note to implementers
-	 * suggesting that the consumer's DAT_RETURN value be used
+	 * suggesting that the consumer's return value be used
 	 * as an index into a table of text strings. However,
-	 * the DAT_RETURN values are not consecutive. Therefore this
+	 * the return values are not consecutive. Therefore this
 	 * implementation does not follow the suggested implementation.
 	 */
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat/dat.h linux-kernel2/dat/dat.h
--- linux-kernel/dat/dat.h	2005-05-10 10:32:56.912966000 -0700
+++ linux-kernel2/dat/dat.h	2005-05-11 13:07:34.341014000 -0700
@@ -47,25 +47,23 @@ typedef u64 DAT_PADDR;
 /*
  * All return codes are actually a 3-way tuple:
  *
- * type: DAT_RETURN_CLASS DAT_RETURN_TYPE DAT_RETURN_SUBTYPE
+ * type: dat_return_class dat_return_type dat_return_subtype
  * bits: 31-30            29-16           15-0
  *
  *    3                   2                   1
  *  1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0
  * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
- * | C | DAT_RETURN_TYPE           | DAT_RETURN_SUBTYPE            |
+ * | C | dat_return_type           | dat_return_subtype            |
  * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  */
 
-typedef u32 DAT_RETURN;
-
-typedef enum dat_return_class {
+enum dat_return_class {
 	DAT_CLASS_ERROR = 0x80000000,
 	DAT_CLASS_WARNING = 0x40000000,
 	DAT_CLASS_SUCCESS = 0x00000000
-} DAT_RETURN_CLASS;
+};
 
-typedef enum dat_return_type {
+enum dat_return_type {
 	/* The operation was successful.                              */
 	DAT_SUCCESS = 0x000000,
 
@@ -144,9 +142,9 @@ typedef enum dat_return_type {
 
 	/* Provider does not support the operation yet.               */
 	DAT_NOT_IMPLEMENTED = 0x3FFF0000
-} DAT_STATUS_TYPE;
+};
 
-typedef enum dat_return_subtype {
+enum dat_return_subtype {
 	/* First element is no subtype */
 	DAT_NO_SUBTYPE,
 	/* ABORT sub types                                            */
@@ -321,7 +319,7 @@ typedef enum dat_return_subtype {
 	DAT_MAJOR_NOT_FOUND,
 	DAT_MINOR_NOT_FOUND,
 	DAT_THREAD_SAFETY_NOT_FOUND
-} DAT_RETURN_SUBTYPE;
+};
 
 /*
  * Error bits
@@ -336,8 +334,8 @@ typedef enum dat_return_subtype {
 #define DAT_IS_ERROR(status)  ((u32)(status) & DAT_CLASS_ERROR)
 #define DAT_IS_WARNING(status)  ((u32)(status) & DAT_CLASS_WARNING)
 
-#define DAT_ERROR(Type, SubType) ((DAT_RETURN)(DAT_CLASS_ERROR | Type | SubType))
-#define DAT_WARNING(Type, SubType) ((DAT_RETURN)(DAT_CLASS_WARNING | Type | SubType))
+#define DAT_ERROR(type, sub_type) ((u32)(DAT_CLASS_ERROR | type | sub_type))
+#define DAT_WARNING(type, sub_type) ((u32)(DAT_CLASS_WARNING | type | sub_type))
 
 #define DAT_GET_TYPE(status)    ((u32)(status) & DAT_TYPE_MASK)
 #define DAT_GET_SUBTYPE(status) ((u32)(status) & DAT_SUBTYPE_MASK)
@@ -1107,178 +1105,178 @@ struct dat_provider_attr {
  *
  ****************************************************************/
 
-typedef DAT_RETURN (*DAT_IA_OPEN_FUNC) (
+typedef u32 (*DAT_IA_OPEN_FUNC) (
         const DAT_NAME_PTR, DAT_COUNT, DAT_EVD_HANDLE *, DAT_IA_HANDLE *);
 
-typedef DAT_RETURN (*DAT_IA_OPENV_FUNC) (
+typedef u32 (*DAT_IA_OPENV_FUNC) (
         const DAT_NAME_PTR, DAT_COUNT, DAT_EVD_HANDLE *, DAT_IA_HANDLE *,
         u32, u32, boolean_t);
 
-typedef DAT_RETURN (*DAT_IA_CLOSE_FUNC) (DAT_IA_HANDLE, DAT_CLOSE_FLAGS);
+typedef u32 (*DAT_IA_CLOSE_FUNC) (DAT_IA_HANDLE, DAT_CLOSE_FLAGS);
 
-typedef DAT_RETURN (*DAT_IA_QUERY_FUNC) (DAT_IA_HANDLE, DAT_EVD_HANDLE *,
+typedef u32 (*DAT_IA_QUERY_FUNC) (DAT_IA_HANDLE, DAT_EVD_HANDLE *,
 					 struct dat_ia_attr *,
 					 struct dat_provider_attr *);
 
-typedef DAT_RETURN (*DAT_SET_CONSUMER_CONTEXT_FUNC) (DAT_HANDLE, DAT_CONTEXT);
+typedef u32 (*DAT_SET_CONSUMER_CONTEXT_FUNC) (DAT_HANDLE, DAT_CONTEXT);
 
-typedef DAT_RETURN (*DAT_GET_CONSUMER_CONTEXT_FUNC) (DAT_HANDLE, DAT_CONTEXT *);
+typedef u32 (*DAT_GET_CONSUMER_CONTEXT_FUNC) (DAT_HANDLE, DAT_CONTEXT *);
 
-typedef DAT_RETURN (*DAT_GET_HANDLE_TYPE_FUNC) (DAT_HANDLE, DAT_HANDLE_TYPE *);
+typedef u32 (*DAT_GET_HANDLE_TYPE_FUNC) (DAT_HANDLE, DAT_HANDLE_TYPE *);
 
-typedef DAT_RETURN (*DAT_CR_QUERY_FUNC) (DAT_CR_HANDLE, struct dat_cr_param *);
+typedef u32 (*DAT_CR_QUERY_FUNC) (DAT_CR_HANDLE, struct dat_cr_param *);
 
-typedef DAT_RETURN (*DAT_CR_ACCEPT_FUNC) (
+typedef u32 (*DAT_CR_ACCEPT_FUNC) (
         DAT_CR_HANDLE, DAT_EP_HANDLE, DAT_COUNT, const DAT_PVOID);
 
-typedef DAT_RETURN (*DAT_CR_REJECT_FUNC) (DAT_CR_HANDLE);
+typedef u32 (*DAT_CR_REJECT_FUNC) (DAT_CR_HANDLE);
 
-typedef DAT_RETURN (*DAT_CR_HANDOFF_FUNC) (DAT_CR_HANDLE, DAT_CONN_QUAL);
+typedef u32 (*DAT_CR_HANDOFF_FUNC) (DAT_CR_HANDLE, DAT_CONN_QUAL);
 
-typedef DAT_RETURN (*DAT_EVD_RESIZE_FUNC) (DAT_EVD_HANDLE, DAT_COUNT);
+typedef u32 (*DAT_EVD_RESIZE_FUNC) (DAT_EVD_HANDLE, DAT_COUNT);
 
-typedef DAT_RETURN (*DAT_EVD_POST_SE_FUNC) (DAT_EVD_HANDLE,
+typedef u32 (*DAT_EVD_POST_SE_FUNC) (DAT_EVD_HANDLE,
 					    const struct dat_event *);
 
-typedef DAT_RETURN (*DAT_EVD_DEQUEUE_FUNC) (DAT_EVD_HANDLE, struct dat_event *);
+typedef u32 (*DAT_EVD_DEQUEUE_FUNC) (DAT_EVD_HANDLE, struct dat_event *);
 
-typedef DAT_RETURN (*DAT_EVD_FREE_FUNC) (DAT_EVD_HANDLE);
+typedef u32 (*DAT_EVD_FREE_FUNC) (DAT_EVD_HANDLE);
 
-typedef DAT_RETURN (*DAT_EVD_QUERY_FUNC) (DAT_EVD_HANDLE,
+typedef u32 (*DAT_EVD_QUERY_FUNC) (DAT_EVD_HANDLE,
 					  struct dat_evd_param *);
 
-typedef DAT_RETURN (*DAT_EP_CREATE_FUNC) (
+typedef u32 (*DAT_EP_CREATE_FUNC) (
         DAT_IA_HANDLE, DAT_PZ_HANDLE, DAT_EVD_HANDLE, DAT_EVD_HANDLE, 
         DAT_EVD_HANDLE, const struct dat_ep_attr *, DAT_EP_HANDLE *);
 
-typedef DAT_RETURN (*DAT_EP_CREATE_WITH_SRQ_FUNC) (
+typedef u32 (*DAT_EP_CREATE_WITH_SRQ_FUNC) (
         DAT_IA_HANDLE, DAT_PZ_HANDLE, DAT_EVD_HANDLE, DAT_EVD_HANDLE,
         DAT_EVD_HANDLE, DAT_SRQ_HANDLE, const struct dat_ep_attr *, DAT_EP_HANDLE *);
 
-typedef DAT_RETURN (*DAT_EP_QUERY_FUNC) (DAT_EP_HANDLE, struct dat_ep_param *);
+typedef u32 (*DAT_EP_QUERY_FUNC) (DAT_EP_HANDLE, struct dat_ep_param *);
 
-typedef DAT_RETURN (*DAT_EP_MODIFY_FUNC) (
+typedef u32 (*DAT_EP_MODIFY_FUNC) (
         DAT_EP_HANDLE, DAT_EP_PARAM_MASK, const struct dat_ep_param *);
 
-typedef DAT_RETURN (*DAT_EP_CONNECT_FUNC) (
+typedef u32 (*DAT_EP_CONNECT_FUNC) (
         DAT_EP_HANDLE, DAT_IA_ADDRESS_PTR, DAT_CONN_QUAL, DAT_TIMEOUT, DAT_COUNT,
         const DAT_PVOID, DAT_QOS, DAT_CONNECT_FLAGS);
 
-typedef DAT_RETURN (*DAT_EP_DUP_CONNECT_FUNC) (
+typedef u32 (*DAT_EP_DUP_CONNECT_FUNC) (
         DAT_EP_HANDLE, DAT_EP_HANDLE, DAT_TIMEOUT, DAT_COUNT, const DAT_PVOID, 
         DAT_QOS);
 
-typedef DAT_RETURN (*DAT_EP_DISCONNECT_FUNC) (DAT_EP_HANDLE, DAT_CLOSE_FLAGS);
+typedef u32 (*DAT_EP_DISCONNECT_FUNC) (DAT_EP_HANDLE, DAT_CLOSE_FLAGS);
 
-typedef DAT_RETURN (*DAT_EP_POST_SEND_FUNC) (
+typedef u32 (*DAT_EP_POST_SEND_FUNC) (
         DAT_EP_HANDLE, DAT_COUNT, struct dat_lmr_triplet *, DAT_DTO_COOKIE, 
         DAT_COMPLETION_FLAGS);
 
-typedef DAT_RETURN (*DAT_EP_POST_RECV_FUNC) (
+typedef u32 (*DAT_EP_POST_RECV_FUNC) (
         DAT_EP_HANDLE, DAT_COUNT, struct dat_lmr_triplet *, DAT_DTO_COOKIE,
         DAT_COMPLETION_FLAGS);
 
-typedef DAT_RETURN (*DAT_EP_POST_RDMA_READ_FUNC) (
+typedef u32 (*DAT_EP_POST_RDMA_READ_FUNC) (
         DAT_EP_HANDLE, DAT_COUNT, struct dat_lmr_triplet *, DAT_DTO_COOKIE,
         const struct dat_rmr_triplet *, DAT_COMPLETION_FLAGS);
 
-typedef DAT_RETURN (*DAT_EP_POST_RDMA_WRITE_FUNC) (
+typedef u32 (*DAT_EP_POST_RDMA_WRITE_FUNC) (
         DAT_EP_HANDLE, DAT_COUNT, struct dat_lmr_triplet *, DAT_DTO_COOKIE,
         const struct dat_rmr_triplet *, DAT_COMPLETION_FLAGS);
 
-typedef DAT_RETURN (*DAT_EP_GET_STATUS_FUNC) (
+typedef u32 (*DAT_EP_GET_STATUS_FUNC) (
         DAT_EP_HANDLE, DAT_EP_STATE *, boolean_t *, boolean_t *);
 
-typedef DAT_RETURN (*DAT_EP_FREE_FUNC) (DAT_EP_HANDLE);
+typedef u32 (*DAT_EP_FREE_FUNC) (DAT_EP_HANDLE);
 
-typedef DAT_RETURN (*DAT_EP_RESET_FUNC) (DAT_EP_HANDLE);
+typedef u32 (*DAT_EP_RESET_FUNC) (DAT_EP_HANDLE);
 
-typedef DAT_RETURN (*DAT_EP_RECV_QUERY_FUNC) (
+typedef u32 (*DAT_EP_RECV_QUERY_FUNC) (
         DAT_EP_HANDLE, DAT_COUNT *, DAT_COUNT *);
 
-typedef DAT_RETURN (*DAT_EP_SET_WATERMARK_FUNC) (
+typedef u32 (*DAT_EP_SET_WATERMARK_FUNC) (
         DAT_EP_HANDLE, DAT_COUNT, DAT_COUNT);
 
-typedef DAT_RETURN (*DAT_LMR_FREE_FUNC) (DAT_LMR_HANDLE);
+typedef u32 (*DAT_LMR_FREE_FUNC) (DAT_LMR_HANDLE);
 
-typedef DAT_RETURN (*DAT_LMR_QUERY_FUNC) (DAT_LMR_HANDLE,
+typedef u32 (*DAT_LMR_QUERY_FUNC) (DAT_LMR_HANDLE,
 					  struct dat_lmr_param *);
 
-typedef DAT_RETURN (*DAT_LMR_SYNC_RDMA_READ_FUNC) (
+typedef u32 (*DAT_LMR_SYNC_RDMA_READ_FUNC) (
         DAT_IA_HANDLE, const struct dat_lmr_triplet *, DAT_VLEN);
 
-typedef DAT_RETURN (*DAT_LMR_SYNC_RDMA_WRITE_FUNC) (
+typedef u32 (*DAT_LMR_SYNC_RDMA_WRITE_FUNC) (
         DAT_IA_HANDLE, const struct dat_lmr_triplet *, DAT_VLEN);
 
-typedef DAT_RETURN (*DAT_RMR_CREATE_FUNC) (DAT_PZ_HANDLE, DAT_RMR_HANDLE *);
+typedef u32 (*DAT_RMR_CREATE_FUNC) (DAT_PZ_HANDLE, DAT_RMR_HANDLE *);
 
-typedef DAT_RETURN (*DAT_RMR_QUERY_FUNC) (DAT_RMR_HANDLE, struct dat_rmr_param *);
+typedef u32 (*DAT_RMR_QUERY_FUNC) (DAT_RMR_HANDLE, struct dat_rmr_param *);
 
-typedef DAT_RETURN (*DAT_RMR_BIND_FUNC) (
+typedef u32 (*DAT_RMR_BIND_FUNC) (
         DAT_RMR_HANDLE, const struct dat_lmr_triplet *, DAT_MEM_PRIV_FLAGS,
         DAT_EP_HANDLE, DAT_RMR_COOKIE, DAT_COMPLETION_FLAGS, DAT_RMR_CONTEXT *);
 
-typedef DAT_RETURN (*DAT_RMR_FREE_FUNC) (DAT_RMR_HANDLE);
+typedef u32 (*DAT_RMR_FREE_FUNC) (DAT_RMR_HANDLE);
 
-typedef DAT_RETURN (*DAT_PSP_CREATE_FUNC) (
+typedef u32 (*DAT_PSP_CREATE_FUNC) (
         DAT_IA_HANDLE, DAT_CONN_QUAL, DAT_EVD_HANDLE, DAT_PSP_FLAGS, 
         DAT_PSP_HANDLE *);
 
-typedef DAT_RETURN (*DAT_PSP_CREATE_ANY_FUNC) (
+typedef u32 (*DAT_PSP_CREATE_ANY_FUNC) (
         DAT_IA_HANDLE, DAT_CONN_QUAL *, DAT_EVD_HANDLE, DAT_PSP_FLAGS,
         DAT_PSP_HANDLE *);
 
-typedef DAT_RETURN (*DAT_PSP_QUERY_FUNC) (DAT_PSP_HANDLE,
+typedef u32 (*DAT_PSP_QUERY_FUNC) (DAT_PSP_HANDLE,
 					  struct dat_psp_param *);
 
-typedef DAT_RETURN (*DAT_PSP_FREE_FUNC) (DAT_PSP_HANDLE);
+typedef u32 (*DAT_PSP_FREE_FUNC) (DAT_PSP_HANDLE);
 
-typedef DAT_RETURN (*DAT_RSP_CREATE_FUNC) (
+typedef u32 (*DAT_RSP_CREATE_FUNC) (
         DAT_IA_HANDLE, DAT_CONN_QUAL, DAT_EP_HANDLE, DAT_EVD_HANDLE, 
         DAT_RSP_HANDLE *);
 
-typedef DAT_RETURN (*DAT_RSP_QUERY_FUNC) (DAT_RSP_HANDLE,
+typedef u32 (*DAT_RSP_QUERY_FUNC) (DAT_RSP_HANDLE,
 					  struct dat_rsp_param *);
 
-typedef DAT_RETURN (*DAT_RSP_FREE_FUNC) (DAT_RSP_HANDLE);
+typedef u32 (*DAT_RSP_FREE_FUNC) (DAT_RSP_HANDLE);
 
-typedef DAT_RETURN (*DAT_PZ_CREATE_FUNC) (DAT_IA_HANDLE, DAT_PZ_HANDLE *);
+typedef u32 (*DAT_PZ_CREATE_FUNC) (DAT_IA_HANDLE, DAT_PZ_HANDLE *);
 
-typedef DAT_RETURN (*DAT_PZ_QUERY_FUNC) (DAT_PZ_HANDLE, struct dat_pz_param *);
+typedef u32 (*DAT_PZ_QUERY_FUNC) (DAT_PZ_HANDLE, struct dat_pz_param *);
 
-typedef DAT_RETURN (*DAT_PZ_FREE_FUNC) (DAT_PZ_HANDLE);
+typedef u32 (*DAT_PZ_FREE_FUNC) (DAT_PZ_HANDLE);
 
-typedef DAT_RETURN (*DAT_SRQ_CREATE_FUNC) (
+typedef u32 (*DAT_SRQ_CREATE_FUNC) (
         DAT_IA_HANDLE, DAT_PZ_HANDLE, struct dat_srq_attr *, DAT_SRQ_HANDLE *);
 
-typedef DAT_RETURN (*DAT_SRQ_SET_LW_FUNC) (DAT_SRQ_HANDLE, DAT_COUNT);
+typedef u32 (*DAT_SRQ_SET_LW_FUNC) (DAT_SRQ_HANDLE, DAT_COUNT);
 
-typedef DAT_RETURN (*DAT_SRQ_FREE_FUNC) (DAT_SRQ_HANDLE);
+typedef u32 (*DAT_SRQ_FREE_FUNC) (DAT_SRQ_HANDLE);
 
-typedef DAT_RETURN (*DAT_SRQ_QUERY_FUNC) (DAT_SRQ_HANDLE,
+typedef u32 (*DAT_SRQ_QUERY_FUNC) (DAT_SRQ_HANDLE,
 					  struct dat_srq_param *);
 
-typedef DAT_RETURN (*DAT_SRQ_RESIZE_FUNC) (DAT_SRQ_HANDLE, DAT_COUNT);
+typedef u32 (*DAT_SRQ_RESIZE_FUNC) (DAT_SRQ_HANDLE, DAT_COUNT);
 
-typedef DAT_RETURN (*DAT_SRQ_POST_RECV_FUNC) (
+typedef u32 (*DAT_SRQ_POST_RECV_FUNC) (
         DAT_SRQ_HANDLE, DAT_COUNT, struct dat_lmr_triplet *, DAT_DTO_COOKIE);
 
-typedef DAT_RETURN (*DAT_LMR_KCREATE_FUNC) (
+typedef u32 (*DAT_LMR_KCREATE_FUNC) (
         DAT_IA_HANDLE, DAT_MEM_TYPE, DAT_REGION_DESCRIPTION, DAT_VLEN,
         DAT_PZ_HANDLE, DAT_MEM_PRIV_FLAGS, DAT_MEM_OPTIMIZE_FLAGS,
         DAT_LMR_HANDLE *, DAT_LMR_CONTEXT *, DAT_RMR_CONTEXT *, DAT_VLEN *,
         DAT_VADDR *);
 
-typedef DAT_RETURN (*DAT_IA_MEMTYPE_HINT_FUNC) (
+typedef u32 (*DAT_IA_MEMTYPE_HINT_FUNC) (
         DAT_IA_HANDLE, DAT_MEM_TYPE, DAT_VLEN, DAT_MEM_OPTIMIZE_FLAGS,
         DAT_VLEN *, DAT_VADDR *);
 
-typedef DAT_RETURN (*DAT_EVD_KCREATE_FUNC) (
+typedef u32 (*DAT_EVD_KCREATE_FUNC) (
         DAT_IA_HANDLE, DAT_COUNT, DAT_UPCALL_POLICY,
 	const struct dat_upcall_object *,
         DAT_EVD_FLAGS, DAT_EVD_HANDLE *);
 
-typedef DAT_RETURN (*DAT_EVD_MODIFY_UPCALL_FUNC) (
+typedef u32 (*DAT_EVD_MODIFY_UPCALL_FUNC) (
         DAT_EVD_HANDLE, DAT_UPCALL_POLICY, const struct dat_upcall_object *);
 
 struct dat_provider {
@@ -1372,16 +1370,16 @@ struct dat_provider {
  * DAT registry functions for providers
  */
 
-extern DAT_RETURN dat_registry_add_provider(
+extern u32 dat_registry_add_provider(
         const struct dat_provider *, const struct dat_provider_info *);
 
-extern DAT_RETURN dat_registry_remove_provider(
+extern u32 dat_registry_remove_provider(
         const struct dat_provider *, const struct dat_provider_info *);
 
 /*
  * DAT registry functions for consumers
  */
-extern DAT_RETURN dat_ia_openv(const DAT_NAME_PTR, DAT_COUNT, 
+extern u32 dat_ia_openv(const DAT_NAME_PTR, DAT_COUNT, 
                                DAT_EVD_HANDLE *, DAT_IA_HANDLE *, 
                                u32, u32, boolean_t);
 
@@ -1390,11 +1388,11 @@ extern DAT_RETURN dat_ia_openv(const DAT
                 DAT_VERSION_MAJOR, DAT_VERSION_MINOR, \
                 DAT_THREADSAFE)
 
-extern DAT_RETURN dat_ia_close(DAT_IA_HANDLE, DAT_CLOSE_FLAGS);
+extern u32 dat_ia_close(DAT_IA_HANDLE, DAT_CLOSE_FLAGS);
 
-extern DAT_RETURN dat_strerror(DAT_RETURN, const char **, const char **);
+extern u32 dat_strerror(u32, const char **, const char **);
 
-extern DAT_RETURN dat_registry_list_providers(
+extern u32 dat_registry_list_providers(
         DAT_COUNT, DAT_COUNT *, struct dat_provider_info *dat_provider_list[]);
 
 /*
@@ -1405,27 +1403,27 @@ extern DAT_RETURN dat_registry_list_prov
 #define DAT_CALL_PROVIDER_FUNC(func, handle, ...) \
         DAT_HANDLE_TO_PROVIDER(handle)->func(handle, ##__VA_ARGS__)
 
-static inline DAT_RETURN dat_set_consumer_context(DAT_HANDLE handle, 
+static inline u32 dat_set_consumer_context(DAT_HANDLE handle, 
                                                   DAT_CONTEXT context) 
 {
         return DAT_CALL_PROVIDER_FUNC(
                 set_consumer_context_func, handle, context);
 }
 
-static inline DAT_RETURN dat_get_consumer_context(DAT_HANDLE handle, 
+static inline u32 dat_get_consumer_context(DAT_HANDLE handle, 
                                                   DAT_CONTEXT *context)
 {
         return DAT_CALL_PROVIDER_FUNC(
                 get_consumer_context_func, handle, context);
 }
 
-static inline DAT_RETURN dat_get_handle_type(DAT_HANDLE handle, 
+static inline u32 dat_get_handle_type(DAT_HANDLE handle, 
                                              DAT_HANDLE_TYPE *type)
 {
         return DAT_CALL_PROVIDER_FUNC(get_handle_type_func, handle, type);
 }
 
-static inline DAT_RETURN dat_ia_memtype_hint(DAT_IA_HANDLE ia, 
+static inline u32 dat_ia_memtype_hint(DAT_IA_HANDLE ia, 
                                              DAT_MEM_TYPE mem_type, 
                                              DAT_VLEN length,
                                              DAT_MEM_OPTIMIZE_FLAGS mem_optimize, 
@@ -1437,7 +1435,7 @@ static inline DAT_RETURN dat_ia_memtype_
                 preferred_length, preferred_alignment);
 }
 
-static inline DAT_RETURN dat_ia_query(DAT_IA_HANDLE ia, 
+static inline u32 dat_ia_query(DAT_IA_HANDLE ia, 
                                       DAT_EVD_HANDLE * async_evd,
                                       struct dat_ia_attr *ia_attr,
                                       struct dat_provider_attr *provider_attr)
@@ -1446,7 +1444,7 @@ static inline DAT_RETURN dat_ia_query(DA
                 ia_query_func, ia, async_evd, ia_attr, provider_attr);
 }
 
-static inline DAT_RETURN dat_cr_accept(DAT_CR_HANDLE cr, 
+static inline u32 dat_cr_accept(DAT_CR_HANDLE cr, 
                                        DAT_EP_HANDLE ep, 
                                        DAT_COUNT private_data_size,
                                        const DAT_PVOID private_data)
@@ -1455,35 +1453,35 @@ static inline DAT_RETURN dat_cr_accept(D
                 cr_accept_func, cr, ep, private_data_size, private_data);
 }
 
-static inline DAT_RETURN dat_cr_handoff(DAT_CR_HANDLE cr, 
+static inline u32 dat_cr_handoff(DAT_CR_HANDLE cr, 
                                         DAT_CONN_QUAL handoff)
 {
 	return DAT_CALL_PROVIDER_FUNC(cr_handoff_func, cr, handoff);
 }
 
-static inline DAT_RETURN dat_cr_query(DAT_CR_HANDLE cr, 
+static inline u32 dat_cr_query(DAT_CR_HANDLE cr, 
                                       struct dat_cr_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(cr_query_func, cr, param);
 }
 
-static inline DAT_RETURN dat_cr_reject(DAT_CR_HANDLE cr) 
+static inline u32 dat_cr_reject(DAT_CR_HANDLE cr) 
 {
         return DAT_CALL_PROVIDER_FUNC(cr_reject_func, cr);
 }
 
-static inline DAT_RETURN dat_evd_dequeue(DAT_EVD_HANDLE evd, 
+static inline u32 dat_evd_dequeue(DAT_EVD_HANDLE evd, 
                                          struct dat_event *event)
 {
         return DAT_CALL_PROVIDER_FUNC(evd_dequeue_func, evd, event);
 }
 
-static inline DAT_RETURN dat_evd_free(DAT_EVD_HANDLE evd)
+static inline u32 dat_evd_free(DAT_EVD_HANDLE evd)
 {
         return DAT_CALL_PROVIDER_FUNC(evd_free_func, evd);
 }
 
-static inline DAT_RETURN dat_evd_kcreate(DAT_IA_HANDLE ia, 
+static inline u32 dat_evd_kcreate(DAT_IA_HANDLE ia, 
                                          DAT_COUNT qlen, 
                                          DAT_UPCALL_POLICY policy, 
                                          const struct dat_upcall_object *upcall, 
@@ -1494,7 +1492,7 @@ static inline DAT_RETURN dat_evd_kcreate
                 evd_kcreate_func, ia, qlen, policy, upcall, flags, evd);
 }
 
-static inline DAT_RETURN dat_evd_modify_upcall(DAT_EVD_HANDLE evd, 
+static inline u32 dat_evd_modify_upcall(DAT_EVD_HANDLE evd, 
                                                DAT_UPCALL_POLICY policy,
                                                const struct dat_upcall_object *upcall)
 {
@@ -1502,24 +1500,24 @@ static inline DAT_RETURN dat_evd_modify_
                 evd_modify_upcall_func, evd, policy, upcall);
 }
 
-static inline DAT_RETURN dat_evd_post_se(DAT_EVD_HANDLE evd, 
+static inline u32 dat_evd_post_se(DAT_EVD_HANDLE evd, 
                                          const struct dat_event *event)
 {
         return DAT_CALL_PROVIDER_FUNC(evd_post_se_func, evd, event);
 }
 
-static inline DAT_RETURN dat_evd_query(DAT_EVD_HANDLE evd, 
+static inline u32 dat_evd_query(DAT_EVD_HANDLE evd, 
                                        struct dat_evd_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(evd_query_func, evd, param);
 }
 
-static inline DAT_RETURN dat_evd_resize(DAT_EVD_HANDLE evd, DAT_COUNT qlen)
+static inline u32 dat_evd_resize(DAT_EVD_HANDLE evd, DAT_COUNT qlen)
 {
         return DAT_CALL_PROVIDER_FUNC(evd_resize_func, evd, qlen);
 }
 
-static inline DAT_RETURN dat_ep_connect(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_connect(DAT_EP_HANDLE ep, 
                                         DAT_IA_ADDRESS_PTR ia_addr,
                                         DAT_CONN_QUAL conn_qual, 
                                         DAT_TIMEOUT timeout, 
@@ -1533,7 +1531,7 @@ static inline DAT_RETURN dat_ep_connect(
                 private_data_size, private_data, qos, flags);
 }
 
-static inline DAT_RETURN dat_ep_create(DAT_IA_HANDLE ia, 
+static inline u32 dat_ep_create(DAT_IA_HANDLE ia, 
                                        DAT_PZ_HANDLE pz, 
                                        DAT_EVD_HANDLE in_evd,
                                        DAT_EVD_HANDLE out_evd, 
@@ -1546,7 +1544,7 @@ static inline DAT_RETURN dat_ep_create(D
 }
 
 
-static inline DAT_RETURN dat_ep_create_with_srq(DAT_IA_HANDLE ia, 
+static inline u32 dat_ep_create_with_srq(DAT_IA_HANDLE ia, 
                                                 DAT_PZ_HANDLE pz,
                                                 DAT_EVD_HANDLE in_evd, 
                                                 DAT_EVD_HANDLE out_evd,
@@ -1559,13 +1557,13 @@ static inline DAT_RETURN dat_ep_create_w
                                       out_evd, connect_evd, srq, attr, ep);
 }
 
-static inline DAT_RETURN dat_ep_disconnect(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_disconnect(DAT_EP_HANDLE ep, 
                                            DAT_CLOSE_FLAGS flags)
 {
         return DAT_CALL_PROVIDER_FUNC(ep_disconnect_func, ep, flags);
 }
 
-static inline DAT_RETURN dat_ep_dup_connect(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_dup_connect(DAT_EP_HANDLE ep, 
                                             DAT_EP_HANDLE dup_ep, 
                                             DAT_TIMEOUT timeout,
                                             DAT_COUNT private_data_size,
@@ -1576,12 +1574,12 @@ static inline DAT_RETURN dat_ep_dup_conn
                                       private_data_size, private_data, qos);
 }
 
-static inline DAT_RETURN dat_ep_free(DAT_EP_HANDLE ep)
+static inline u32 dat_ep_free(DAT_EP_HANDLE ep)
 {
         return DAT_CALL_PROVIDER_FUNC(ep_free_func, ep);
 }
 
-static inline DAT_RETURN dat_ep_get_status(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_get_status(DAT_EP_HANDLE ep, 
                                            DAT_EP_STATE * state,
                                            boolean_t *recv_idle, 
                                            boolean_t *req_idle)
@@ -1590,14 +1588,14 @@ static inline DAT_RETURN dat_ep_get_stat
                 ep_get_status_func, ep, state, recv_idle, req_idle);
 }
 
-static inline DAT_RETURN dat_ep_modify(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_modify(DAT_EP_HANDLE ep, 
                                        DAT_EP_PARAM_MASK mask,
                                        const struct dat_ep_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(ep_modify_func, ep, mask, param);
 }
 
-static inline DAT_RETURN dat_ep_post_rdma_read(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_post_rdma_read(DAT_EP_HANDLE ep, 
                                                DAT_COUNT size,
                                                struct dat_lmr_triplet *local_iov, 
                                                DAT_DTO_COOKIE cookie,
@@ -1608,7 +1606,7 @@ static inline DAT_RETURN dat_ep_post_rdm
                                       local_iov, cookie, remote_iov, flags);
 }
 
-static inline DAT_RETURN dat_ep_post_rdma_write(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_post_rdma_write(DAT_EP_HANDLE ep, 
                                                 DAT_COUNT size,
                                                 struct dat_lmr_triplet *local_iov, 
                                                 DAT_DTO_COOKIE cookie,
@@ -1619,7 +1617,7 @@ static inline DAT_RETURN dat_ep_post_rdm
                                       local_iov, cookie, remote_iov, flags);
 }
 
-static inline DAT_RETURN dat_ep_post_recv(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_post_recv(DAT_EP_HANDLE ep, 
                                           DAT_COUNT size,
                                           struct dat_lmr_triplet *local_iov,
                                           DAT_DTO_COOKIE cookie, 
@@ -1629,7 +1627,7 @@ static inline DAT_RETURN dat_ep_post_rec
                 ep_post_recv_func, ep, size, local_iov, cookie, flags);
 }
 
-static inline DAT_RETURN dat_ep_post_send(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_post_send(DAT_EP_HANDLE ep, 
                                           DAT_COUNT size, 
                                           struct dat_lmr_triplet *local_iov,
                                           DAT_DTO_COOKIE cookie, 
@@ -1639,12 +1637,12 @@ static inline DAT_RETURN dat_ep_post_sen
                 ep_post_send_func, ep, size, local_iov, cookie, flags);
 }
 
-static inline DAT_RETURN dat_ep_query(DAT_EP_HANDLE ep, struct dat_ep_param *param)
+static inline u32 dat_ep_query(DAT_EP_HANDLE ep, struct dat_ep_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(ep_query_func, ep, param);
 }
 
-static inline DAT_RETURN dat_ep_recv_query(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_recv_query(DAT_EP_HANDLE ep, 
                                            DAT_COUNT * bufs_alloc, 
                                            DAT_COUNT * bufs_avail)
 {
@@ -1652,12 +1650,12 @@ static inline DAT_RETURN dat_ep_recv_que
                 ep_recv_query_func, ep, bufs_alloc, bufs_avail);
 }
 
-static inline DAT_RETURN dat_ep_reset(DAT_EP_HANDLE ep)
+static inline u32 dat_ep_reset(DAT_EP_HANDLE ep)
 {
         return DAT_CALL_PROVIDER_FUNC(ep_reset_func, ep);
 }
 
-static inline DAT_RETURN dat_ep_set_watermark(DAT_EP_HANDLE ep, 
+static inline u32 dat_ep_set_watermark(DAT_EP_HANDLE ep, 
                                               DAT_COUNT soft_high_watermark, 
                                               DAT_COUNT hard_high_watermark)
 {
@@ -1665,18 +1663,18 @@ static inline DAT_RETURN dat_ep_set_wate
                                       soft_high_watermark, hard_high_watermark);
 }
 
-static inline DAT_RETURN dat_lmr_query(DAT_LMR_HANDLE lmr,
+static inline u32 dat_lmr_query(DAT_LMR_HANDLE lmr,
 				       struct dat_lmr_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(lmr_query_func, lmr, param);
 }
 
-static inline DAT_RETURN dat_lmr_free(DAT_LMR_HANDLE lmr) 
+static inline u32 dat_lmr_free(DAT_LMR_HANDLE lmr) 
 {
         return DAT_CALL_PROVIDER_FUNC(lmr_free_func, lmr);
 }
 
-static inline DAT_RETURN dat_lmr_sync_rdma_read(DAT_IA_HANDLE ia, 
+static inline u32 dat_lmr_sync_rdma_read(DAT_IA_HANDLE ia, 
                                                 const struct dat_lmr_triplet *iovs,
                                                 DAT_VLEN num_iovs)
 {
@@ -1684,7 +1682,7 @@ static inline DAT_RETURN dat_lmr_sync_rd
                 lmr_sync_rdma_read_func, ia, iovs, num_iovs);
 }
 
-static inline DAT_RETURN dat_lmr_sync_rdma_write(DAT_IA_HANDLE ia,
+static inline u32 dat_lmr_sync_rdma_write(DAT_IA_HANDLE ia,
                                                  const struct dat_lmr_triplet *iovs, 
                                                  DAT_VLEN num_iovs)
 {
@@ -1692,17 +1690,17 @@ static inline DAT_RETURN dat_lmr_sync_rd
                 lmr_sync_rdma_write_func, ia, iovs, num_iovs);
 }
 
-static inline DAT_RETURN dat_rmr_create(DAT_PZ_HANDLE pz, DAT_RMR_HANDLE * rmr)
+static inline u32 dat_rmr_create(DAT_PZ_HANDLE pz, DAT_RMR_HANDLE * rmr)
 {
         return DAT_CALL_PROVIDER_FUNC(rmr_create_func, pz, rmr);
 }
 
-static inline DAT_RETURN dat_rmr_query(DAT_RMR_HANDLE rmr, struct dat_rmr_param *param)
+static inline u32 dat_rmr_query(DAT_RMR_HANDLE rmr, struct dat_rmr_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(rmr_query_func, rmr, param);
 }
 
-static inline DAT_RETURN dat_rmr_bind(DAT_RMR_HANDLE rmr, 
+static inline u32 dat_rmr_bind(DAT_RMR_HANDLE rmr, 
                                       const struct dat_lmr_triplet *iov,
                                       DAT_MEM_PRIV_FLAGS mem_flags, 
                                       DAT_EP_HANDLE ep,
@@ -1714,12 +1712,12 @@ static inline DAT_RETURN dat_rmr_bind(DA
                                       cookie, comp_flags, context);
 }
 
-static inline DAT_RETURN dat_rmr_free(DAT_RMR_HANDLE rmr)
+static inline u32 dat_rmr_free(DAT_RMR_HANDLE rmr)
 {
         return DAT_CALL_PROVIDER_FUNC(rmr_free_func, rmr);
 }
 
-static inline DAT_RETURN dat_psp_create(DAT_IA_HANDLE ia, 
+static inline u32 dat_psp_create(DAT_IA_HANDLE ia, 
                                         DAT_CONN_QUAL conn_qual, 
                                         DAT_EVD_HANDLE evd,
                                         DAT_PSP_FLAGS flags, 
@@ -1729,7 +1727,7 @@ static inline DAT_RETURN dat_psp_create(
                 psp_create_func, ia, conn_qual, evd, flags, psp);
 }
 
-static inline DAT_RETURN dat_psp_create_any(DAT_IA_HANDLE ia, 
+static inline u32 dat_psp_create_any(DAT_IA_HANDLE ia, 
                                             DAT_CONN_QUAL * conn_qual,
                                             DAT_EVD_HANDLE evd, 
                                             DAT_PSP_FLAGS flags,
@@ -1739,18 +1737,18 @@ static inline DAT_RETURN dat_psp_create_
                 psp_create_any_func, ia, conn_qual, evd, flags, psp);
 }
 
-static inline DAT_RETURN dat_psp_query(DAT_PSP_HANDLE psp,
+static inline u32 dat_psp_query(DAT_PSP_HANDLE psp,
 				       struct dat_psp_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(psp_query_func, psp, param);
 }
 
-static inline DAT_RETURN dat_psp_free(DAT_PSP_HANDLE psp)
+static inline u32 dat_psp_free(DAT_PSP_HANDLE psp)
 {
         return DAT_CALL_PROVIDER_FUNC(psp_free_func, psp);
 }
 
-static inline DAT_RETURN dat_rsp_create(DAT_IA_HANDLE ia, 
+static inline u32 dat_rsp_create(DAT_IA_HANDLE ia, 
                                         DAT_CONN_QUAL conn_qual, 
                                         DAT_EP_HANDLE ep,
                                         DAT_EVD_HANDLE evd, 
@@ -1760,34 +1758,34 @@ static inline DAT_RETURN dat_rsp_create(
                 rsp_create_func, ia, conn_qual, ep, evd, rsp);
 }
 
-static inline DAT_RETURN dat_rsp_query(DAT_RSP_HANDLE rsp,
+static inline u32 dat_rsp_query(DAT_RSP_HANDLE rsp,
 				       struct dat_rsp_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(rsp_query_func, rsp, param);
 }
 
-static inline DAT_RETURN dat_rsp_free(DAT_RSP_HANDLE rsp)
+static inline u32 dat_rsp_free(DAT_RSP_HANDLE rsp)
 {
         return DAT_CALL_PROVIDER_FUNC(rsp_free_func, rsp);
 }
 
-static inline DAT_RETURN dat_pz_create(DAT_IA_HANDLE ia, DAT_PZ_HANDLE * pz)
+static inline u32 dat_pz_create(DAT_IA_HANDLE ia, DAT_PZ_HANDLE * pz)
 {
         return DAT_CALL_PROVIDER_FUNC(pz_create_func, ia, pz);
 }
 
-static inline DAT_RETURN dat_pz_query(DAT_PZ_HANDLE pz,
+static inline u32 dat_pz_query(DAT_PZ_HANDLE pz,
 				      struct dat_pz_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(pz_query_func, pz, param);
 }
 
-static inline DAT_RETURN dat_pz_free(DAT_PZ_HANDLE pz)
+static inline u32 dat_pz_free(DAT_PZ_HANDLE pz)
 {
         return DAT_CALL_PROVIDER_FUNC(pz_free_func, pz);
 }
 
-static inline DAT_RETURN dat_srq_create(DAT_IA_HANDLE ia, 
+static inline u32 dat_srq_create(DAT_IA_HANDLE ia, 
                                         DAT_PZ_HANDLE pz, 
                                         struct dat_srq_attr *attr,
                                         DAT_SRQ_HANDLE * srq)
@@ -1795,12 +1793,12 @@ static inline DAT_RETURN dat_srq_create(
         return DAT_CALL_PROVIDER_FUNC(srq_create_func, ia, pz, attr, srq);
 }
 
-static inline DAT_RETURN dat_srq_free(DAT_SRQ_HANDLE srq)
+static inline u32 dat_srq_free(DAT_SRQ_HANDLE srq)
 {
         return DAT_CALL_PROVIDER_FUNC(srq_free_func, srq);
 }
 
-static inline DAT_RETURN dat_srq_post_recv(DAT_SRQ_HANDLE srq, 
+static inline u32 dat_srq_post_recv(DAT_SRQ_HANDLE srq, 
                                            DAT_COUNT num_iovs,
                                            struct dat_lmr_triplet *iovs, 
                                            DAT_DTO_COOKIE cookie)
@@ -1809,25 +1807,25 @@ static inline DAT_RETURN dat_srq_post_re
                 srq_post_recv_func, srq, num_iovs, iovs, cookie);
 }
 
-static inline DAT_RETURN dat_srq_query(DAT_SRQ_HANDLE srq,
+static inline u32 dat_srq_query(DAT_SRQ_HANDLE srq,
 				       struct dat_srq_param *param)
 {
         return DAT_CALL_PROVIDER_FUNC(srq_query_func, srq, param);
 }
 
-static inline DAT_RETURN dat_srq_resize(DAT_SRQ_HANDLE srq, 
+static inline u32 dat_srq_resize(DAT_SRQ_HANDLE srq, 
                                         DAT_COUNT max_recv_dtos)
 {
         return DAT_CALL_PROVIDER_FUNC(srq_resize_func, srq, max_recv_dtos);
 }
 
-static inline DAT_RETURN dat_srq_set_lw(DAT_SRQ_HANDLE srq, 
+static inline u32 dat_srq_set_lw(DAT_SRQ_HANDLE srq, 
                                         DAT_COUNT low_watermark)
 {
         return DAT_CALL_PROVIDER_FUNC(srq_set_lw_func, srq, low_watermark);
 }
 
-static inline DAT_RETURN dat_lmr_kcreate(DAT_IA_HANDLE ia, 
+static inline u32 dat_lmr_kcreate(DAT_IA_HANDLE ia, 
                                          DAT_MEM_TYPE type,
                                          DAT_REGION_DESCRIPTION region, 
                                          DAT_VLEN len,
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat/dictionary.c linux-kernel2/dat/dictionary.c
--- linux-kernel/dat/dictionary.c	2005-05-12 07:46:08.833024000 -0700
+++ linux-kernel2/dat/dictionary.c	2005-05-12 07:51:24.928004000 -0700
@@ -39,9 +39,8 @@
  *                                                                   *
  *********************************************************************/
 
-static DAT_RETURN 
-dat_dictionary_key_dup(const struct dat_provider_info *old_key,
-		       struct dat_provider_info *new_key);
+static u32 dat_dictionary_key_dup(const struct dat_provider_info *old_key,
+				  struct dat_provider_info *new_key);
 
 static boolean_t
 dat_dictionary_key_is_equal(const struct dat_provider_info *key_a,
@@ -78,8 +77,8 @@ void dat_dictionary_destroy(struct dat_d
  * Function: dat_dictionary_size
  ***********************************************************************/
 
-DAT_RETURN dat_dictionary_size(const struct dat_dictionary *dictionary,
-			       DAT_COUNT *size)
+u32 dat_dictionary_size(const struct dat_dictionary *dictionary,
+			DAT_COUNT *size)
 {
 	BUG_ON(NULL == dictionary);
 	BUG_ON(NULL == size);
@@ -93,15 +92,13 @@ DAT_RETURN dat_dictionary_size(const str
  * Function: dat_dictionary_entry_create
  ***********************************************************************/
 
-DAT_RETURN dat_dictionary_entry_create(struct dat_dictionary_entry **p_entry)
+u32 dat_dictionary_entry_create(struct dat_dictionary_entry **p_entry)
 {
 	struct dat_dictionary_entry *entry;
-	DAT_RETURN status;
+	u32 status = DAT_SUCCESS;
 
 	BUG_ON(NULL == p_entry);
 
-	status = DAT_SUCCESS;
-
 	entry = kmalloc(sizeof(*entry), GFP_ATOMIC);
 	if (NULL == entry) {
 		status =
@@ -128,12 +125,11 @@ void dat_dictionary_entry_destroy(const 
  * Function: dat_dictionary_insert
  ***********************************************************************/
 
-DAT_RETURN dat_dictionary_insert(struct dat_dictionary *dictionary,
-				 const struct dat_provider_info *key,
-				 struct dat_dictionary_entry *entry,
-				 void *data)
+u32 dat_dictionary_insert(struct dat_dictionary *dictionary,
+			  const struct dat_provider_info *key,
+			  struct dat_dictionary_entry *entry, void *data)
 {
-	DAT_RETURN status;
+	u32 status;
 
 	BUG_ON(NULL == dictionary);
 	BUG_ON(NULL == entry);
@@ -163,13 +159,12 @@ DAT_RETURN dat_dictionary_insert(struct 
  * Function: dat_dictionary_search
  ***********************************************************************/
 
-DAT_RETURN dat_dictionary_search(struct dat_dictionary *dictionary,
-				 const struct dat_provider_info *key,
-				 void **p_data)
+u32 dat_dictionary_search(struct dat_dictionary *dictionary,
+			  const struct dat_provider_info *key, void **p_data)
 {
 	struct list_head *cur_list;
 	struct dat_dictionary_entry *cur_entry;
-	DAT_RETURN status;
+	u32 status;
 
 	BUG_ON(NULL == dictionary);
 	BUG_ON(NULL == key);
@@ -196,14 +191,13 @@ DAT_RETURN dat_dictionary_search(struct 
  * Function: dat_dictionary_enumerate
  ***********************************************************************/
 
-DAT_RETURN dat_dictionary_enumerate(struct dat_dictionary *dictionary,
-				    void *array[],
-				    DAT_COUNT array_size)
+u32 dat_dictionary_enumerate(struct dat_dictionary *dictionary, void *array[],
+			     DAT_COUNT array_size)
 {
 	struct list_head *cur_list;
 	struct dat_dictionary_entry *cur_entry;
 	DAT_COUNT i;
-	DAT_RETURN status;
+	u32 status;
 
 	BUG_ON(NULL == dictionary);
 	BUG_ON(NULL == array);
@@ -230,14 +224,13 @@ DAT_RETURN dat_dictionary_enumerate(stru
  * Function: dat_dictionary_remove
  ***********************************************************************/
 
-DAT_RETURN dat_dictionary_remove(struct dat_dictionary *dictionary,
-				 const struct dat_provider_info *key,
-				 struct dat_dictionary_entry **p_entry,
-				 void **p_data)
+u32 dat_dictionary_remove(struct dat_dictionary *dictionary,
+			  const struct dat_provider_info *key,
+			  struct dat_dictionary_entry **p_entry, void **p_data)
 {
 	struct list_head *cur_list, *next_list;
 	struct dat_dictionary_entry *cur_entry;
-	DAT_RETURN status;
+	u32 status;
 
 	BUG_ON(NULL == dictionary);
 	BUG_ON(NULL == key);
@@ -277,8 +270,8 @@ DAT_RETURN dat_dictionary_remove(struct 
  * Function: dat_dictionary_key_create
  ***********************************************************************/
 
-DAT_RETURN dat_dictionary_key_dup(const struct dat_provider_info *old_key,
-				  struct dat_provider_info *new_key)
+u32 dat_dictionary_key_dup(const struct dat_provider_info *old_key,
+			   struct dat_provider_info *new_key)
 {
 	BUG_ON(NULL == old_key);
 	BUG_ON(NULL == new_key);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat/dictionary.h linux-kernel2/dat/dictionary.h
--- linux-kernel/dat/dictionary.h	2005-05-12 07:46:08.907009000 -0700
+++ linux-kernel2/dat/dictionary.h	2005-05-12 07:53:32.355003000 -0700
@@ -69,31 +69,30 @@ struct dat_dictionary {
 
 extern void dat_dictionary_destroy(struct dat_dictionary *dictionary);
 
-extern DAT_RETURN dat_dictionary_size(
-	const struct dat_dictionary *dictionary, DAT_COUNT *size);
+extern u32 dat_dictionary_size(const struct dat_dictionary *dictionary,
+			       DAT_COUNT *size);
 
-extern DAT_RETURN dat_dictionary_entry_create(
-	struct dat_dictionary_entry **p_entry);
+extern u32 dat_dictionary_entry_create(struct dat_dictionary_entry **p_entry);
 
 extern void dat_dictionary_entry_destroy(
 	const struct dat_dictionary_entry *entry);
 
-extern DAT_RETURN dat_dictionary_insert(struct dat_dictionary *dictionary,
-                                        const struct dat_provider_info *key, 
-                                        struct dat_dictionary_entry *entry,
-                                        void *data);
-
-extern DAT_RETURN dat_dictionary_search(struct dat_dictionary *dictionary,
-					const struct dat_provider_info *key,
-					void **p_data);
-
-extern DAT_RETURN dat_dictionary_enumerate(struct dat_dictionary *dictionary,
-					   void *array[], 
-					   const DAT_COUNT array_size);
-
-extern DAT_RETURN dat_dictionary_remove(struct dat_dictionary *dictionary,
-					const struct dat_provider_info *key,
-					struct dat_dictionary_entry **p_entry,
-					void **p_data);
+extern u32 dat_dictionary_insert(struct dat_dictionary *dictionary,
+				 const struct dat_provider_info *key,
+				 struct dat_dictionary_entry *entry,
+				 void *data);
+
+extern u32 dat_dictionary_search(struct dat_dictionary *dictionary,
+				 const struct dat_provider_info *key,
+				 void **p_data);
+
+extern u32 dat_dictionary_enumerate(struct dat_dictionary *dictionary,
+				    void *array[],
+				    const DAT_COUNT array_size);
+
+extern u32 dat_dictionary_remove(struct dat_dictionary *dictionary,
+				 const struct dat_provider_info *key,
+				 struct dat_dictionary_entry **p_entry,
+				 void **p_data);
 
 #endif /* DICTIONARY_H */
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat/dr.c linux-kernel2/dat/dr.c
--- linux-kernel/dat/dr.c	2005-05-12 07:46:08.786003000 -0700
+++ linux-kernel2/dat/dr.c	2005-05-12 07:49:02.844000000 -0700
@@ -76,12 +76,12 @@ void dat_dr_fini(void)
  * Function: dat_dr_insert
  ************************************************************************/
 
-DAT_RETURN dat_dr_insert(const struct dat_provider_info *info, 
-                         const DAT_IA_OPEN_FUNC ia_open_func)
+u32 dat_dr_insert(const struct dat_provider_info *info,
+		  const DAT_IA_OPEN_FUNC ia_open_func)
 {
 	struct dat_dr_entry *data;
 	struct dat_dictionary_entry *dict_entry;
-	DAT_RETURN status;
+	u32 status;
 
 	data = kmalloc(sizeof(*data), GFP_ATOMIC);
 	if (NULL == data) {
@@ -122,11 +122,11 @@ DAT_RETURN dat_dr_insert(const struct da
  * Function: dat_dr_remove
  ************************************************************************/
 
-DAT_RETURN dat_dr_remove(const struct dat_provider_info *info)
+u32 dat_dr_remove(const struct dat_provider_info *info)
 {
 	struct dat_dr_entry *data;
 	struct dat_dictionary_entry *dict_entry;
-	DAT_RETURN status;
+	u32 status;
 
 	dict_entry = NULL;
 	spin_lock(&g_dr_lock);
@@ -161,11 +161,11 @@ DAT_RETURN dat_dr_remove(const struct da
  * Function: dat_dr_provider_open
  ************************************************************************/
 
-DAT_RETURN dat_dr_provider_open(const struct dat_provider_info *info,
+u32 dat_dr_provider_open(const struct dat_provider_info *info,
 		                DAT_IA_OPEN_FUNC *p_ia_open_func)
 {
 	struct dat_dr_entry *data;
-	DAT_RETURN status;
+	u32 status;
 
 	spin_lock(&g_dr_lock);
 
@@ -185,10 +185,10 @@ DAT_RETURN dat_dr_provider_open(const st
  * Function: dat_dr_provider_close
  ************************************************************************/
 
-DAT_RETURN dat_dr_provider_close(const struct dat_provider_info *info)
+u32 dat_dr_provider_close(const struct dat_provider_info *info)
 {
 	struct dat_dr_entry *data;
-	DAT_RETURN status;
+	u32 status;
 
 	spin_lock(&g_dr_lock);
 
@@ -206,7 +206,7 @@ DAT_RETURN dat_dr_provider_close(const s
  * Function: dat_dr_size
  ************************************************************************/
 
-DAT_RETURN dat_dr_size(DAT_COUNT *size)
+u32 dat_dr_size(DAT_COUNT *size)
 {
 	return dat_dictionary_size(&g_dr_dictionary, size);
 }
@@ -215,17 +215,16 @@ DAT_RETURN dat_dr_size(DAT_COUNT *size)
  * Function: dat_dr_list
  ***********************************************************************/
 
-DAT_RETURN dat_dr_list(DAT_COUNT max_to_return,
-                       DAT_COUNT *entries_returned,
-                       struct dat_provider_info *(dat_provider_list[]))
+u32 dat_dr_list(DAT_COUNT max_to_return,
+		DAT_COUNT *entries_returned,
+		struct dat_provider_info *(dat_provider_list[]))
 {
 	struct dat_dr_entry **array;
 	DAT_COUNT array_size;
 	DAT_COUNT i;
-	DAT_RETURN status;
+	u32 status = DAT_SUCCESS;
 
 	array = NULL;
-	status = DAT_SUCCESS;
 
 	/* The dictionary size may increase between the call to      */
 	/* dat_dictionary_size() and dat_dictionary_enumerate().     */
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat/dr.h linux-kernel2/dat/dr.h
--- linux-kernel/dat/dr.h	2005-05-12 07:46:08.935003000 -0700
+++ linux-kernel2/dat/dr.h	2005-05-12 07:54:14.114000000 -0700
@@ -44,20 +44,20 @@
 
 extern void dat_dr_fini(void);
 
-extern DAT_RETURN dat_dr_insert(const struct dat_provider_info *info, 
-                                const DAT_IA_OPEN_FUNC ia_open_func);
+extern u32 dat_dr_insert(const struct dat_provider_info *info,
+			 const DAT_IA_OPEN_FUNC ia_open_func);
 
-extern DAT_RETURN dat_dr_remove(const struct dat_provider_info *info);
+extern u32 dat_dr_remove(const struct dat_provider_info *info);
 
-extern DAT_RETURN dat_dr_provider_open(const struct dat_provider_info *info, 
-                                       DAT_IA_OPEN_FUNC *p_ia_open_func);
+extern u32 dat_dr_provider_open(const struct dat_provider_info *info,
+				DAT_IA_OPEN_FUNC *p_ia_open_func);
 
-extern DAT_RETURN dat_dr_provider_close(const struct dat_provider_info *info);
+extern u32 dat_dr_provider_close(const struct dat_provider_info *info);
 
-extern DAT_RETURN dat_dr_size(DAT_COUNT *size);
+extern u32 dat_dr_size(DAT_COUNT *size);
 
-extern DAT_RETURN dat_dr_list(DAT_COUNT max_to_return, 
-                              DAT_COUNT *entries_returned,
-                              struct dat_provider_info *(dat_provider_list[]));
+extern u32 dat_dr_list(DAT_COUNT max_to_return,
+		       DAT_COUNT *entries_returned,
+		       struct dat_provider_info *(dat_provider_list[]));
 
 #endif /* DR_H */
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_adapter_util.h linux-kernel2/dat-provider/dapl_adapter_util.h
--- linux-kernel/dat-provider/dapl_adapter_util.h	2005-05-11 10:09:59.053024000 -0700
+++ linux-kernel2/dat-provider/dapl_adapter_util.h	2005-05-11 11:37:05.389975000 -0700
@@ -49,112 +49,93 @@ typedef enum async_handler_type {
  */
 #define IB_CM_REJ_REASON_CONSUMER_REJ            0x001C
 
-DAT_RETURN dapl_ib_enum_hcas(const char *vendor,
-			     DAPL_HCA_NAME ** hca_names,
-			     DAT_COUNT * total_hca_count);
+u32 dapl_ib_enum_hcas(const char *vendor,
+		      DAPL_HCA_NAME **hca_names,
+		      DAT_COUNT *total_hca_count);
 
-DAT_RETURN dapl_ib_get_instance_data(DAPL_HCA_NAME hca_name, char *instance);
+u32 dapl_ib_get_instance_data(DAPL_HCA_NAME hca_name, char *instance);
 
-DAT_RETURN dapl_ib_open_hca(char *namestr, DAPL_HCA * hca_ptr);
+u32 dapl_ib_open_hca(char *namestr, DAPL_HCA *hca_ptr);
 
-DAT_RETURN dapl_ib_close_hca(DAPL_HCA * hca_ptr);
+u32 dapl_ib_close_hca(DAPL_HCA *hca_ptr);
 
-DAT_RETURN dapl_ib_qp_alloc(DAPL_IA * ia_ptr,
-			    DAPL_EP * ep_ptr, DAPL_EP * ep_ctx_ptr);
+u32 dapl_ib_qp_alloc(DAPL_IA *ia_ptr, DAPL_EP *ep_ptr, DAPL_EP *ep_ctx_ptr);
 
-DAT_RETURN dapl_ib_qp_free(DAPL_IA * ia_ptr, DAPL_EP * ep_ptr);
+u32 dapl_ib_qp_free(DAPL_IA *ia_ptr, DAPL_EP *ep_ptr);
 
-DAT_RETURN dapl_ib_qp_modify(DAPL_IA * ia_ptr,
-			     DAPL_EP * ep_ptr, struct dat_ep_attr *ep_attr);
+u32 dapl_ib_qp_modify(DAPL_IA *ia_ptr, DAPL_EP *ep_ptr,
+		      struct dat_ep_attr *ep_attr);
 
-DAT_RETURN dapl_ib_connect(DAT_EP_HANDLE ep_handle,
-			   DAT_IA_ADDRESS_PTR remote_ia_address,
-			   DAT_CONN_QUAL remote_conn_qual,
-			   DAT_COUNT private_data_size, DAT_PVOID private_data);
+u32 dapl_ib_connect(DAT_EP_HANDLE ep_handle,
+		    DAT_IA_ADDRESS_PTR remote_ia_address,
+		    DAT_CONN_QUAL remote_conn_qual,
+		    DAT_COUNT private_data_size, DAT_PVOID private_data);
 
-DAT_RETURN dapl_ib_disconnect(DAPL_EP * ep_ptr, DAT_CLOSE_FLAGS close_flags);
+u32 dapl_ib_disconnect(DAPL_EP *ep_ptr, DAT_CLOSE_FLAGS close_flags);
 
-DAT_RETURN dapl_ib_setup_conn_listener(DAPL_IA * ia_ptr,
-				       u64 ServiceID, DAPL_SP * sp_ptr);
+u32 dapl_ib_setup_conn_listener(DAPL_IA *ia_ptr, u64 ServiceID,
+				DAPL_SP *sp_ptr);
 
-DAT_RETURN dapl_ib_remove_conn_listener(DAPL_IA * ia_ptr, DAPL_SP * sp_ptr);
+u32 dapl_ib_remove_conn_listener(DAPL_IA *ia_ptr, DAPL_SP *sp_ptr);
 
-DAT_RETURN dapl_ib_accept_connection(DAT_CR_HANDLE cr_handle,
-				     DAT_EP_HANDLE ep_handle,
-				     DAT_COUNT private_data_size,
-				     const DAT_PVOID private_data);
+u32 dapl_ib_accept_connection(DAT_CR_HANDLE cr_handle,
+			      DAT_EP_HANDLE ep_handle,
+			      DAT_COUNT private_data_size,
+			      const DAT_PVOID private_data);
 
-DAT_RETURN dapl_ib_reject_connection(ib_cm_handle_t cm_handle,
-				     int reject_reason);
+u32 dapl_ib_reject_connection(ib_cm_handle_t cm_handle, int reject_reason);
 
-DAT_RETURN dapl_ib_setup_async_callback(DAPL_IA * ia_ptr,
-					DAPL_ASYNC_HANDLER_TYPE handler_type,
-					ib_async_handler_t callback,
-					void *context);
+u32 dapl_ib_setup_async_callback(DAPL_IA *ia_ptr,
+				 DAPL_ASYNC_HANDLER_TYPE handler_type,
+				 ib_async_handler_t callback, void *context);
 
-DAT_RETURN dapl_ib_cq_alloc(DAPL_IA * ia_ptr,
-			    DAPL_EVD * evd_ptr,
-			    DAT_COUNT * cqlen, ib_comp_handle_t callback);
+u32 dapl_ib_cq_alloc(DAPL_IA *ia_ptr, DAPL_EVD *evd_ptr, DAT_COUNT *cqlen,
+		     ib_comp_handle_t callback);
 
-DAT_RETURN dapl_ib_cq_free(DAPL_IA * ia_ptr, DAPL_EVD * evd_ptr);
+u32 dapl_ib_cq_free(DAPL_IA *ia_ptr, DAPL_EVD *evd_ptr);
 
-DAT_RETURN dapl_set_cq_notify(DAPL_IA * ia_ptr, DAPL_EVD * evd_ptr);
+u32 dapl_set_cq_notify(DAPL_IA *ia_ptr, DAPL_EVD *evd_ptr);
 
-DAT_RETURN dapl_ib_cq_resize(DAPL_IA * ia_ptr,
-			     DAPL_EVD * evd_ptr, DAT_COUNT * cqlen);
+u32 dapl_ib_cq_resize(DAPL_IA *ia_ptr, DAPL_EVD *evd_ptr, DAT_COUNT *cqlen);
 
-DAT_RETURN dapl_ib_pd_alloc(DAPL_IA * ia_ptr, DAPL_PZ * pz);
+u32 dapl_ib_pd_alloc(DAPL_IA *ia_ptr, DAPL_PZ *pz);
 
-DAT_RETURN dapl_ib_pd_free(DAPL_PZ * pz);
+u32 dapl_ib_pd_free(DAPL_PZ *pz);
 
-DAT_RETURN dapl_ib_mr_register(DAPL_IA * ia_ptr,
-			       DAPL_LMR * lmr,
-			       DAT_PVOID virt_addr,
-			       DAT_VLEN length, DAT_MEM_PRIV_FLAGS privileges);
+u32 dapl_ib_mr_register(DAPL_IA *ia_ptr, DAPL_LMR *lmr, DAT_PVOID virt_addr,
+			DAT_VLEN length, DAT_MEM_PRIV_FLAGS privileges);
 
-DAT_RETURN dapl_ib_mr_register_physical(DAPL_IA * ia_ptr,
-					DAPL_LMR * lmr,
-					DAT_PVOID phys_addr,
-					DAT_VLEN length,
-					DAT_MEM_PRIV_FLAGS privileges);
+u32 dapl_ib_mr_register_physical(DAPL_IA *ia_ptr, DAPL_LMR *lmr,
+				 DAT_PVOID phys_addr, DAT_VLEN length,
+				 DAT_MEM_PRIV_FLAGS privileges);
 
-DAT_RETURN dapl_ib_mr_deregister(DAPL_LMR * lmr);
+u32 dapl_ib_mr_deregister(DAPL_LMR *lmr);
 
-DAT_RETURN dapl_ib_mr_register_shared(DAPL_IA * ia_ptr,
-				      DAPL_LMR * lmr,
-				      DAT_MEM_PRIV_FLAGS privileges);
+u32 dapl_ib_mr_register_shared(DAPL_IA *ia_ptr, DAPL_LMR *lmr,
+			       DAT_MEM_PRIV_FLAGS privileges);
 
-DAT_RETURN dapl_ib_mw_alloc(DAPL_RMR * rmr);
+u32 dapl_ib_mw_alloc(DAPL_RMR *rmr);
 
-DAT_RETURN dapl_ib_mw_free(DAPL_RMR * rmr);
+u32 dapl_ib_mw_free(DAPL_RMR *rmr);
 
-DAT_RETURN dapl_ib_mw_bind(DAPL_RMR * rmr,
-			   DAPL_LMR * lmr,
-			   DAPL_EP * ep,
-			   DAPL_COOKIE * cookie,
-			   DAT_VADDR virtual_address,
-			   DAT_VLEN length,
-			   DAT_MEM_PRIV_FLAGS mem_priv,
-			   boolean_t is_signaled);
+u32 dapl_ib_mw_bind(DAPL_RMR *rmr, DAPL_LMR *lmr, DAPL_EP *ep,
+		    DAPL_COOKIE *cookie, DAT_VADDR virtual_address,
+		    DAT_VLEN length, DAT_MEM_PRIV_FLAGS mem_priv,
+		    boolean_t is_signaled);
 
-DAT_RETURN dapl_ib_mw_unbind(DAPL_RMR * rmr,
-			     DAPL_EP * ep,
-			     DAPL_COOKIE * cookie, boolean_t is_signaled);
+u32 dapl_ib_mw_unbind(DAPL_RMR *rmr, DAPL_EP *ep, DAPL_COOKIE *cookie,
+		      boolean_t is_signaled);
 
-DAT_RETURN dapl_ib_query_hca(DAPL_HCA * hca_ptr,
-			     struct dat_ia_attr *ia_attr,
-			     struct dat_ep_attr *ep_attr,
-			     struct sockaddr_in6 *ip_addr);
+u32 dapl_ib_query_hca(DAPL_HCA *hca_ptr, struct dat_ia_attr *ia_attr,
+		      struct dat_ep_attr *ep_attr,
+		      struct sockaddr_in6 *ip_addr);
 
-DAT_RETURN dapl_ib_completion_poll(DAPL_HCA * hca_ptr,
-				   DAPL_EVD * evd_ptr,
-				   ib_work_completion_t * cqe_ptr);
+u32 dapl_ib_completion_poll(DAPL_HCA *hca_ptr, DAPL_EVD *evd_ptr,
+			    ib_work_completion_t *cqe_ptr);
 
-DAT_RETURN dapl_ib_completion_notify(DAPL_EVD * evd_ptr,
-				     ib_notification_type_t type);
+u32 dapl_ib_completion_notify(DAPL_EVD *evd_ptr, ib_notification_type_t type);
 
-DAT_DTO_COMPLETION_STATUS dapl_ib_get_dto_status(ib_work_completion_t *
-						 cqe_ptr);
+DAT_DTO_COMPLETION_STATUS dapl_ib_get_dto_status(ib_work_completion_t *cqe_ptr);
 
 void dapl_ib_reinit_ep(DAPL_EP * ep_ptr);
 
@@ -162,17 +143,16 @@ void dapl_ib_disconnect_clean(DAPL_EP * 
 			      boolean_t passive,
 			      const ib_cm_events_t ib_cm_event);
 
-DAT_RETURN dapl_ib_get_async_event(ib_error_record_t * cause_ptr,
-				   DAT_EVENT_NUMBER * async_event);
+u32 dapl_ib_get_async_event(ib_error_record_t *cause_ptr,
+			    DAT_EVENT_NUMBER *async_event);
 
 DAT_EVENT_NUMBER dapl_ib_get_dat_event(const ib_cm_events_t ib_cm_event,
 				       boolean_t active);
 
 ib_cm_events_t dapl_ib_get_cm_event(DAT_EVENT_NUMBER dat_event_num);
 
-DAT_RETURN dapl_ib_cm_remote_addr(DAT_HANDLE dat_handle,
-				  struct sockaddr_in6 *remote_ia_address);
-
+u32 dapl_ib_cm_remote_addr(DAT_HANDLE dat_handle,
+			   struct sockaddr_in6 *remote_ia_address);
 
 /*
  * Values for provider struct dat_named_attr
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cno_util.c linux-kernel2/dat-provider/dapl_cno_util.c
--- linux-kernel/dat-provider/dapl_cno_util.c	2005-05-11 08:28:12.472019000 -0700
+++ linux-kernel2/dat-provider/dapl_cno_util.c	2005-05-11 11:37:30.214963000 -0700
@@ -111,11 +111,9 @@ dapl_cno_trigger (
     DAPL_CNO		*cno_ptr,
     DAPL_EVD		*evd_ptr)
 {
-        DAT_RETURN		dat_status;
+        u32 dat_status = DAT_SUCCESS;
         struct dat_event event;
         
-        dat_status = DAT_SUCCESS;
-        
         dapl_os_assert (cno_ptr->header.magic == DAPL_MAGIC_CNO);
         /* The spec allows NULL EVDs. kDAPL doesn't have CNOs, they
          * are strictly used behind the scenes
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cno_util.c.mine linux-kernel2/dat-provider/dapl_cno_util.c.mine
--- linux-kernel/dat-provider/dapl_cno_util.c.mine	2005-05-10 11:53:42.390979000 -0700
+++ linux-kernel2/dat-provider/dapl_cno_util.c.mine	1969-12-31 16:00:00.000000000 -0800
@@ -1,139 +0,0 @@
-/*
- * Copyright (c) 2002-2005, Network Appliance, Inc. All rights reserved.
- *
- * This Software is licensed under one of the following licenses:
- *
- * 1) under the terms of the "Common Public License 1.0" a copy of which is
- *    available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/cpl.php.
- *
- * 2) under the terms of the "The BSD License" a copy of which is
- *    available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/bsd-license.php.
- *
- * 3) under the terms of the "GNU General Public License (GPL) Version 2" a
- *    copy of which is available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/gpl-license.php.
- *
- * Licensee has the right to choose one of the above licenses.
- *
- * Redistributions of source code must retain the above copyright
- * notice and one of the license notices.
- *
- * Redistributions in binary form must reproduce both the above copyright
- * notice, one of the license notices in the documentation
- * and/or other materials provided with the distribution.
- */
-
-/*
- * Manage CNO Info structure
- *
- * $Id: dapl_cno_util.c 2293 2005-05-10 15:18:25Z jlentini $
- */
-
-#include "dapl_ia_util.h"
-#include "dapl_cno_util.h"
-#include "dapl_adapter_util.h"
-
-
-
-/*
- * alloc and initialize an EVD struct
- */
-DAPL_CNO *
-dapl_cno_alloc(DAPL_IA *ia_ptr, const struct dat_upcall_object *upcall)
-{
-    DAPL_CNO *cno_ptr;
-
-    cno_ptr = (DAPL_CNO *) kmalloc(sizeof (DAPL_CNO), GFP_ATOMIC);
-    if (!cno_ptr)
-    {
-	return NULL;
-    }
-
-    /* zero the structure */
-    memset (cno_ptr, 0, sizeof (DAPL_CNO));
-
-    /*
-     * Initialize the header.
-     */
-    cno_ptr->header.provider            = ia_ptr->header.provider;
-    cno_ptr->header.magic               = DAPL_MAGIC_CNO;
-    cno_ptr->header.owner_ia            = ia_ptr;
-    cno_ptr->header.user_context.as_64  = 0;
-    cno_ptr->header.user_context.as_ptr = NULL;
-    dapl_llist_init_entry (&cno_ptr->header.ia_list_entry);
-    spin_lock_init (&cno_ptr->header.lock);
-
-    /*
-     * Initialize the body
-     */
-    cno_ptr->cno_upcall = *upcall;
-
-    return cno_ptr;
-}
-
-/*
- * Free the passed in CNO structure.
- */
-void
-dapl_cno_dealloc (
-    DAPL_CNO *cno_ptr)
-{
-    dapl_os_assert (cno_ptr->header.magic == DAPL_MAGIC_CNO);
-    /*
-     * deinitialize the header
-     */
-    cno_ptr->header.magic = DAPL_MAGIC_INVALID; /* reset magic to prevent reuse */
-
-    kfree (cno_ptr);
-}
-
-
-/*
- * dapl_cno_trigger
- *
- * DAPL Internal routine to trigger the specified CNO.
- * Called by the callback of some EVD associated with the CNO.
- *
- * Input:
- *	cno_ptr
- *	evd_ptr		EVD triggering
- *
- * Output:
- *	None
- *
- * Returns:
- *	None
- */
-void
-dapl_cno_trigger (
-    DAPL_CNO		*cno_ptr,
-    DAPL_EVD		*evd_ptr)
-{
-    DAT_RETURN		dat_status;
-    struct dat_event event;
-
-    dat_status = DAT_SUCCESS;
-
-    dapl_os_assert (cno_ptr->header.magic == DAPL_MAGIC_CNO);
-    /* The spec allows NULL EVDs. kDAPL doesn't have CNOs, they
-     * are strictly used behind the scenes
-     */
-    dapl_os_assert (evd_ptr == NULL || evd_ptr->header.magic == DAPL_MAGIC_EVD);
-
-    spin_lock (&cno_ptr->header.lock);
-
-	spin_unlock (&cno_ptr->header.lock);
-	dat_status = dapl_evd_dequeue ((DAT_EVD_HANDLE)evd_ptr, &event);
-	while (dat_status == DAT_SUCCESS ) {
-	    if (cno_ptr->cno_upcall.upcall_func != (DAT_UPCALL_FUNC) NULL) {
-		cno_ptr->cno_upcall.upcall_func (
-					cno_ptr->cno_upcall.instance_data,
-					&event,
-					FALSE);
-	    }
-	    dat_status = dapl_evd_dequeue ( (DAT_EVD_HANDLE)evd_ptr, &event);
-	}
-    return;
-}
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cno_util.c.r2295 linux-kernel2/dat-provider/dapl_cno_util.c.r2295
--- linux-kernel/dat-provider/dapl_cno_util.c.r2295	2005-05-10 11:53:42.382980000 -0700
+++ linux-kernel2/dat-provider/dapl_cno_util.c.r2295	1969-12-31 16:00:00.000000000 -0800
@@ -1,139 +0,0 @@
-/*
- * Copyright (c) 2002-2005, Network Appliance, Inc. All rights reserved.
- *
- * This Software is licensed under one of the following licenses:
- *
- * 1) under the terms of the "Common Public License 1.0" a copy of which is
- *    available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/cpl.php.
- *
- * 2) under the terms of the "The BSD License" a copy of which is
- *    available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/bsd-license.php.
- *
- * 3) under the terms of the "GNU General Public License (GPL) Version 2" a
- *    copy of which is available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/gpl-license.php.
- *
- * Licensee has the right to choose one of the above licenses.
- *
- * Redistributions of source code must retain the above copyright
- * notice and one of the license notices.
- *
- * Redistributions in binary form must reproduce both the above copyright
- * notice, one of the license notices in the documentation
- * and/or other materials provided with the distribution.
- */
-
-/*
- * Manage CNO Info structure
- *
- * $Id: dapl_cno_util.c 2296 2005-05-10 19:00:01Z jlentini $
- */
-
-#include "dapl_ia_util.h"
-#include "dapl_cno_util.h"
-#include "dapl_adapter_util.h"
-
-
-
-/*
- * alloc and initialize an EVD struct
- */
-DAPL_CNO *
-dapl_cno_alloc(DAPL_IA *ia_ptr, const struct dat_upcall_object *upcall)
-{
-    DAPL_CNO *cno_ptr;
-
-    cno_ptr = (DAPL_CNO *) kmalloc(sizeof (DAPL_CNO), GFP_ATOMIC);
-    if (!cno_ptr)
-    {
-	return NULL;
-    }
-
-    /* zero the structure */
-    memset (cno_ptr, 0, sizeof (DAPL_CNO));
-
-    /*
-     * Initialize the header.
-     */
-    cno_ptr->header.provider            = ia_ptr->header.provider;
-    cno_ptr->header.magic               = DAPL_MAGIC_CNO;
-    cno_ptr->header.owner_ia            = ia_ptr;
-    cno_ptr->header.user_context.as_64  = 0;
-    cno_ptr->header.user_context.as_ptr = NULL;
-    dapl_llist_init_entry (&cno_ptr->header.ia_list_entry);
-    spin_lock_init (&cno_ptr->header.lock);
-
-    /*
-     * Initialize the body
-     */
-    cno_ptr->cno_upcall = *upcall;
-
-    return cno_ptr;
-}
-
-/*
- * Free the passed in CNO structure.
- */
-void
-dapl_cno_dealloc (
-    DAPL_CNO *cno_ptr)
-{
-    dapl_os_assert (cno_ptr->header.magic == DAPL_MAGIC_CNO);
-    /*
-     * deinitialize the header
-     */
-    cno_ptr->header.magic = DAPL_MAGIC_INVALID; /* reset magic to prevent reuse */
-
-    kfree (cno_ptr);
-}
-
-
-/*
- * dapl_cno_trigger
- *
- * DAPL Internal routine to trigger the specified CNO.
- * Called by the callback of some EVD associated with the CNO.
- *
- * Input:
- *	cno_ptr
- *	evd_ptr		EVD triggering
- *
- * Output:
- *	None
- *
- * Returns:
- *	None
- */
-void
-dapl_cno_trigger (
-    DAPL_CNO		*cno_ptr,
-    DAPL_EVD		*evd_ptr)
-{
-    DAT_RETURN		dat_status;
-    struct dat_event event;
-
-    dat_status = DAT_SUCCESS;
-
-    dapl_os_assert (cno_ptr->header.magic == DAPL_MAGIC_CNO);
-    /* The spec allows NULL EVDs. kDAPL doesn't have CNOs, they
-     * are strictly used behind the scenes
-     */
-    dapl_os_assert (evd_ptr == NULL || evd_ptr->header.magic == DAPL_MAGIC_EVD);
-
-    spin_lock (&cno_ptr->header.lock);
-
-	spin_unlock (&cno_ptr->header.lock);
-	dat_status = dapl_evd_dequeue ((DAT_EVD_HANDLE)evd_ptr, &event);
-	while (dat_status == DAT_SUCCESS ) {
-	    if (cno_ptr->cno_upcall.upcall_func != (DAT_UPCALL_FUNC) NULL) {
-		cno_ptr->cno_upcall.upcall_func (
-					cno_ptr->cno_upcall.instance_data,
-					&event,
-					DAT_FALSE);
-	    }
-	    dat_status = dapl_evd_dequeue ( (DAT_EVD_HANDLE)evd_ptr, &event);
-	}
-    return;
-}
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cno_util.c.r2296 linux-kernel2/dat-provider/dapl_cno_util.c.r2296
--- linux-kernel/dat-provider/dapl_cno_util.c.r2296	2005-05-10 11:53:42.385969000 -0700
+++ linux-kernel2/dat-provider/dapl_cno_util.c.r2296	1969-12-31 16:00:00.000000000 -0800
@@ -1,136 +0,0 @@
-/*
- * Copyright (c) 2002-2005, Network Appliance, Inc. All rights reserved.
- *
- * This Software is licensed under one of the following licenses:
- *
- * 1) under the terms of the "Common Public License 1.0" a copy of which is
- *    available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/cpl.php.
- *
- * 2) under the terms of the "The BSD License" a copy of which is
- *    available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/bsd-license.php.
- *
- * 3) under the terms of the "GNU General Public License (GPL) Version 2" a
- *    copy of which is available from the Open Source Initiative, see
- *    http://www.opensource.org/licenses/gpl-license.php.
- *
- * Licensee has the right to choose one of the above licenses.
- *
- * Redistributions of source code must retain the above copyright
- * notice and one of the license notices.
- *
- * Redistributions in binary form must reproduce both the above copyright
- * notice, one of the license notices in the documentation
- * and/or other materials provided with the distribution.
- */
-
-/*
- * Manage CNO Info structure
- *
- * $Id: dapl_cno_util.c 2296 2005-05-10 19:00:01Z jlentini $
- */
-
-#include "dapl_ia_util.h"
-#include "dapl_cno_util.h"
-#include "dapl_adapter_util.h"
-
-
-
-/*
- * alloc and initialize an EVD struct
- */
-DAPL_CNO *
-dapl_cno_alloc(DAPL_IA *ia_ptr, const struct dat_upcall_object *upcall)
-{
-    DAPL_CNO *cno_ptr;
-
-    cno_ptr = (DAPL_CNO *) kmalloc(sizeof (DAPL_CNO), GFP_ATOMIC);
-    if (!cno_ptr)
-    {
-	return NULL;
-    }
-
-    /* zero the structure */
-    memset (cno_ptr, 0, sizeof (DAPL_CNO));
-
-    /*
-     * Initialize the header.
-     */
-    cno_ptr->header.provider            = ia_ptr->header.provider;
-    cno_ptr->header.magic               = DAPL_MAGIC_CNO;
-    cno_ptr->header.owner_ia            = ia_ptr;
-    cno_ptr->header.user_context.as_64  = 0;
-    cno_ptr->header.user_context.as_ptr = NULL;
-    dapl_llist_init_entry (&cno_ptr->header.ia_list_entry);
-    spin_lock_init (&cno_ptr->header.lock);
-
-    /*
-     * Initialize the body
-     */
-    cno_ptr->cno_upcall = *upcall;
-
-    return cno_ptr;
-}
-
-/*
- * Free the passed in CNO structure.
- */
-void
-dapl_cno_dealloc (
-    DAPL_CNO *cno_ptr)
-{
-    dapl_os_assert (cno_ptr->header.magic == DAPL_MAGIC_CNO);
-    /*
-     * deinitialize the header
-     */
-    cno_ptr->header.magic = DAPL_MAGIC_INVALID; /* reset magic to prevent reuse */
-
-    kfree (cno_ptr);
-}
-
-
-/*
- * dapl_cno_trigger
- *
- * DAPL Internal routine to trigger the specified CNO.
- * Called by the callback of some EVD associated with the CNO.
- *
- * Input:
- *	cno_ptr
- *	evd_ptr		EVD triggering
- *
- * Output:
- *	None
- *
- * Returns:
- *	None
- */
-void
-dapl_cno_trigger (
-    DAPL_CNO		*cno_ptr,
-    DAPL_EVD		*evd_ptr)
-{
-        DAT_RETURN		dat_status;
-        struct dat_event event;
-        
-        dat_status = DAT_SUCCESS;
-        
-        dapl_os_assert (cno_ptr->header.magic == DAPL_MAGIC_CNO);
-        /* The spec allows NULL EVDs. kDAPL doesn't have CNOs, they
-         * are strictly used behind the scenes
-         */
-        dapl_os_assert (evd_ptr == NULL || 
-                        evd_ptr->header.magic == DAPL_MAGIC_EVD);
-        
-        dat_status = dapl_evd_dequeue ((DAT_EVD_HANDLE)evd_ptr, &event);
-        while (dat_status == DAT_SUCCESS ) {
-                if (cno_ptr->cno_upcall.upcall_func != (DAT_UPCALL_FUNC) NULL) {
-                        cno_ptr->cno_upcall.upcall_func (
-                                cno_ptr->cno_upcall.instance_data,
-                                &event,
-                                DAT_FALSE);
-                }
-                dat_status = dapl_evd_dequeue((DAT_EVD_HANDLE)evd_ptr, &event);
-        }
-}
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cookie.c linux-kernel2/dat-provider/dapl_cookie.c
--- linux-kernel/dat-provider/dapl_cookie.c	2005-04-27 11:38:34.700014000 -0700
+++ linux-kernel2/dat-provider/dapl_cookie.c	2005-05-11 11:41:23.413960000 -0700
@@ -84,9 +84,9 @@
  *                                                                   *
  *********************************************************************/
 
-DAT_RETURN dapl_cb_get(DAPL_COOKIE_BUFFER * buffer, DAPL_COOKIE ** cookie_ptr);
+u32 dapl_cb_get(DAPL_COOKIE_BUFFER *buffer, DAPL_COOKIE **cookie_ptr);
 
-DAT_RETURN dapl_cb_put(DAPL_COOKIE_BUFFER * buffer, DAPL_COOKIE * cookie);
+u32 dapl_cb_put(DAPL_COOKIE_BUFFER *buffer, DAPL_COOKIE *cookie);
 
 /*********************************************************************
  *                                                                   *
@@ -113,8 +113,7 @@ DAT_RETURN dapl_cb_put(DAPL_COOKIE_BUFFE
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN
-dapl_cb_create(DAPL_COOKIE_BUFFER * buffer, DAPL_EP * ep, DAT_COUNT size)
+u32 dapl_cb_create(DAPL_COOKIE_BUFFER *buffer, DAPL_EP *ep, DAT_COUNT size)
 {
 	DAT_COUNT i;
 
@@ -179,9 +178,9 @@ void dapl_cb_free(DAPL_COOKIE_BUFFER * b
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_cb_get(DAPL_COOKIE_BUFFER * buffer, DAPL_COOKIE ** cookie_ptr)
+u32 dapl_cb_get(DAPL_COOKIE_BUFFER *buffer, DAPL_COOKIE **cookie_ptr)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	DAT_COUNT new_head;
 
 	dapl_os_assert(NULL != cookie_ptr);
@@ -218,7 +217,7 @@ DAT_RETURN dapl_cb_get(DAPL_COOKIE_BUFFE
  *	DAT_INSUFFICIENT_EMPTY
  *
  */
-DAT_RETURN dapl_cb_put(DAPL_COOKIE_BUFFER * buffer, DAPL_COOKIE * cookie)
+u32 dapl_cb_put(DAPL_COOKIE_BUFFER *buffer, DAPL_COOKIE *cookie)
 {
 	atomic_set(&buffer->tail, cookie->index);
 
@@ -243,13 +242,11 @@ DAT_RETURN dapl_cb_put(DAPL_COOKIE_BUFFE
  *	DAT_INSUFFICIENT_EMPTY
  *
  */
-DAT_RETURN
-dapl_rmr_cookie_alloc(DAPL_COOKIE_BUFFER * buffer,
-		      DAPL_RMR * rmr,
-		      DAT_RMR_COOKIE user_cookie, DAPL_COOKIE ** cookie_ptr)
+u32 dapl_rmr_cookie_alloc(DAPL_COOKIE_BUFFER *buffer, DAPL_RMR *rmr,
+			  DAT_RMR_COOKIE user_cookie, DAPL_COOKIE **cookie_ptr)
 {
 	DAPL_COOKIE *cookie;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	if (DAT_SUCCESS != dapl_cb_get(buffer, &cookie)) {
 		*cookie_ptr = NULL;
@@ -287,10 +284,8 @@ dapl_rmr_cookie_alloc(DAPL_COOKIE_BUFFER
  *	DAT_INSUFFICIENT_EMPTY
  *
  */
-DAT_RETURN
-dapl_dto_cookie_alloc(DAPL_COOKIE_BUFFER * buffer,
-		      DAPL_DTO_TYPE type,
-		      DAT_DTO_COOKIE user_cookie, DAPL_COOKIE ** cookie_ptr)
+u32 dapl_dto_cookie_alloc(DAPL_COOKIE_BUFFER *buffer, DAPL_DTO_TYPE type,
+			  DAT_DTO_COOKIE user_cookie, DAPL_COOKIE **cookie_ptr)
 {
 	DAPL_COOKIE *cookie;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cookie.h linux-kernel2/dat-provider/dapl_cookie.h
--- linux-kernel/dat-provider/dapl_cookie.h	2005-04-20 12:42:06.513011000 -0700
+++ linux-kernel2/dat-provider/dapl_cookie.h	2005-05-11 11:42:25.658973000 -0700
@@ -36,20 +36,18 @@
 
 #include "dapl.h"
 
-extern DAT_RETURN
-dapl_cb_create(DAPL_COOKIE_BUFFER * buffer, DAPL_EP * ep, DAT_COUNT size);
+extern u32 dapl_cb_create(DAPL_COOKIE_BUFFER *buffer, DAPL_EP *ep,
+			  DAT_COUNT size);
 
-extern void dapl_cb_free(DAPL_COOKIE_BUFFER * buffer);
+extern void dapl_cb_free(DAPL_COOKIE_BUFFER *buffer);
 
-extern DAT_RETURN
-dapl_rmr_cookie_alloc(DAPL_COOKIE_BUFFER * buffer,
-		      DAPL_RMR * rmr,
-		      DAT_RMR_COOKIE user_cookie, DAPL_COOKIE ** cookie_ptr);
-
-extern DAT_RETURN
-dapl_dto_cookie_alloc(DAPL_COOKIE_BUFFER * buffer,
-		      DAPL_DTO_TYPE type,
-		      DAT_DTO_COOKIE user_cookie, DAPL_COOKIE ** cookie_ptr);
+extern u32 dapl_rmr_cookie_alloc(DAPL_COOKIE_BUFFER *buffer, DAPL_RMR *rmr,
+				 DAT_RMR_COOKIE user_cookie,
+				 DAPL_COOKIE **cookie_ptr);
+
+extern u32 dapl_dto_cookie_alloc(DAPL_COOKIE_BUFFER *buffer,
+				 DAPL_DTO_TYPE type, DAT_DTO_COOKIE user_cookie,
+				 DAPL_COOKIE **cookie_ptr);
 
 extern void
 dapl_cookie_dealloc(DAPL_COOKIE_BUFFER * buffer, DAPL_COOKIE * cookie);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cr_accept.c linux-kernel2/dat-provider/dapl_cr_accept.c
--- linux-kernel/dat-provider/dapl_cr_accept.c	2005-05-02 08:48:17.581023000 -0700
+++ linux-kernel2/dat-provider/dapl_cr_accept.c	2005-05-11 11:42:47.385963000 -0700
@@ -39,13 +39,11 @@
  * Establish a connection between active side (remote endpoint)
  * and passive side (local endpoint).
  */
-DAT_RETURN
-dapl_cr_accept(DAT_CR_HANDLE cr_handle,
-	       DAT_EP_HANDLE ep_handle,
-	       DAT_COUNT private_data_size, const DAT_PVOID private_data)
+u32 dapl_cr_accept(DAT_CR_HANDLE cr_handle, DAT_EP_HANDLE ep_handle,
+		   DAT_COUNT private_data_size, const DAT_PVOID private_data)
 {
 	DAPL_EP *ep_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	DAPL_CR *cr_ptr;
 	DAT_EP_STATE entry_ep_state;
 	DAT_EP_HANDLE entry_ep_handle;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cr_callback.c linux-kernel2/dat-provider/dapl_cr_callback.c
--- linux-kernel/dat-provider/dapl_cr_callback.c	2005-05-11 08:28:11.511012000 -0700
+++ linux-kernel2/dat-provider/dapl_cr_callback.c	2005-05-11 11:43:26.176964000 -0700
@@ -45,9 +45,8 @@
 /*
  * Prototypes
  */
-DAT_RETURN dapl_connection_request(ib_cm_handle_t ib_cm_handle,
-				   DAPL_SP * sp_ptr,
-				   const void *prd_ptr, DAPL_EVD * evd_ptr);
+u32 dapl_connection_request(ib_cm_handle_t ib_cm_handle, DAPL_SP *sp_ptr,
+			    const void *prd_ptr, DAPL_EVD *evd_ptr);
 
 DAPL_EP *dapl_get_sp_ep(ib_cm_handle_t ib_cm_handle,
 			DAPL_SP * sp_ptr, DAT_EVENT_NUMBER dat_event_num);
@@ -65,7 +64,7 @@ void dapl_cr_callback(ib_cm_handle_t ib_
 	DAPL_EVD *evd_ptr;
 	DAPL_SP *sp_ptr;
 	DAT_EVENT_NUMBER dat_event_num;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_CM | DAPL_DBG_TYPE_CALLBACK,
 		     "--> dapl_cr_callback! context: %p event: %x cm_handle %p\n",
@@ -266,12 +265,10 @@ void dapl_cr_callback(ib_cm_handle_t ib_
  * Create a CR record and link it on to the SP so we can update it
  * and free it later. Create an EP if specified by the PSP flags.
  */
-DAT_RETURN
-dapl_connection_request(ib_cm_handle_t ib_cm_handle,
-			DAPL_SP * sp_ptr,
-			const void *prd_ptr, DAPL_EVD * evd_ptr)
+u32 dapl_connection_request(ib_cm_handle_t ib_cm_handle, DAPL_SP *sp_ptr,
+			    const void *prd_ptr, DAPL_EVD *evd_ptr)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	DAPL_CR *cr_ptr;
 	DAPL_EP *ep_ptr;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cr_handoff.c linux-kernel2/dat-provider/dapl_cr_handoff.c
--- linux-kernel/dat-provider/dapl_cr_handoff.c	2005-04-20 12:42:07.958024000 -0700
+++ linux-kernel2/dat-provider/dapl_cr_handoff.c	2005-05-11 11:16:06.189964000 -0700
@@ -37,7 +37,7 @@
  * Hand the connection request to another Sevice pont specified by the
  * Connectin Qualifier.
  */
-DAT_RETURN dapl_cr_handoff(DAT_CR_HANDLE cr_handle, DAT_CONN_QUAL cr_handoff)
+u32 dapl_cr_handoff(DAT_CR_HANDLE cr_handle, DAT_CONN_QUAL cr_handoff)
 {				/* handoff */
 	return DAT_ERROR(DAT_NOT_IMPLEMENTED, 0);
 }
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cr_query.c linux-kernel2/dat-provider/dapl_cr_query.c
--- linux-kernel/dat-provider/dapl_cr_query.c	2005-05-10 08:13:29.281019000 -0700
+++ linux-kernel2/dat-provider/dapl_cr_query.c	2005-05-11 11:16:06.193960000 -0700
@@ -34,10 +34,10 @@
 #include "dapl.h"
 #include "dapl_adapter_util.h"
 
-DAT_RETURN dapl_cr_query(DAT_CR_HANDLE cr_handle, struct dat_cr_param *cr_param)
+u32 dapl_cr_query(DAT_CR_HANDLE cr_handle, struct dat_cr_param *cr_param)
 {
 	DAPL_CR *cr_ptr;
-	DAT_RETURN status;
+	u32 status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_cr_query (%p, %x, %p)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_cr_reject.c linux-kernel2/dat-provider/dapl_cr_reject.c
--- linux-kernel/dat-provider/dapl_cr_reject.c	2005-04-20 12:42:07.641003000 -0700
+++ linux-kernel2/dat-provider/dapl_cr_reject.c	2005-05-11 11:16:06.196963000 -0700
@@ -40,14 +40,14 @@
  * Reject a connection request from the active remote side requesting
  * an Endpoint.
  */
-DAT_RETURN dapl_cr_reject(DAT_CR_HANDLE cr_handle)
+u32 dapl_cr_reject(DAT_CR_HANDLE cr_handle)
 {
 	DAPL_CR *cr_ptr;
 	DAPL_EP *ep_ptr;
 	DAT_EP_STATE entry_ep_state;
 	DAT_EP_HANDLE entry_ep_handle;
 	DAPL_SP *sp_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_cr_reject (%p)\n", cr_handle);
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_connect.c linux-kernel2/dat-provider/dapl_ep_connect.c
--- linux-kernel/dat-provider/dapl_ep_connect.c	2005-05-10 08:13:28.285058000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_connect.c	2005-05-11 11:58:33.206963000 -0700
@@ -42,18 +42,15 @@
  * and a remote Endpoint. This operation is used by the active/client
  * side of a connection
  */
-DAT_RETURN
-dapl_ep_connect(DAT_EP_HANDLE ep_handle,
-		DAT_IA_ADDRESS_PTR remote_ia_address,
-		DAT_CONN_QUAL remote_conn_qual,
-		DAT_TIMEOUT timeout,
-		DAT_COUNT private_data_size,
-		const DAT_PVOID private_data,
-		DAT_QOS qos, DAT_CONNECT_FLAGS connect_flags)
+u32 dapl_ep_connect(DAT_EP_HANDLE ep_handle,
+		    DAT_IA_ADDRESS_PTR remote_ia_address,
+		    DAT_CONN_QUAL remote_conn_qual, DAT_TIMEOUT timeout,
+		    DAT_COUNT private_data_size, const DAT_PVOID private_data,
+		    DAT_QOS qos, DAT_CONNECT_FLAGS connect_flags)
 {
 	DAPL_EP *ep_ptr;
 	DAPL_EP alloc_ep;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API | DAPL_DBG_TYPE_CM,
 		     "dapl_ep_connect (%p, {%u.%u.%u.%u}, %X, %d, %d, %p, %x, %x)\n",
@@ -66,7 +63,6 @@ dapl_ep_connect(DAT_EP_HANDLE ep_handle,
 		     timeout,
 		     private_data_size, private_data, qos, connect_flags);
 
-	dat_status = DAT_SUCCESS;
 	ep_ptr = (DAPL_EP *) ep_handle;
 
 	/*
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_create.c linux-kernel2/dat-provider/dapl_ep_create.c
--- linux-kernel/dat-provider/dapl_ep_create.c	2005-05-10 08:13:28.361017000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_create.c	2005-05-11 11:59:08.236964000 -0700
@@ -63,18 +63,16 @@
  *	DAT_INVALID_ATTRIBUTE
  *	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_ep_create(DAT_IA_HANDLE ia_handle,
-	       DAT_PZ_HANDLE pz_handle,
-	       DAT_EVD_HANDLE recv_evd_handle,
-	       DAT_EVD_HANDLE request_evd_handle,
-	       DAT_EVD_HANDLE connect_evd_handle,
-	       const struct dat_ep_attr *ep_attr, DAT_EP_HANDLE * ep_handle)
+u32 dapl_ep_create(DAT_IA_HANDLE ia_handle, DAT_PZ_HANDLE pz_handle,
+		   DAT_EVD_HANDLE recv_evd_handle,
+		   DAT_EVD_HANDLE request_evd_handle,
+		   DAT_EVD_HANDLE connect_evd_handle,
+		   const struct dat_ep_attr *ep_attr, DAT_EP_HANDLE *ep_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_EP *ep_ptr;
 	struct dat_ep_attr ep_attr_limit;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ep_create (%p, %p, %p, %p, %p, %p, %p)\n",
@@ -85,7 +83,6 @@ dapl_ep_create(DAT_IA_HANDLE ia_handle,
 		     connect_evd_handle, ep_attr, ep_handle);
 
 	ia_ptr = (DAPL_IA *) ia_handle;
-	dat_status = DAT_SUCCESS;
 
 	/*
 	 * Verify parameters
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_create_with_srq.c linux-kernel2/dat-provider/dapl_ep_create_with_srq.c
--- linux-kernel/dat-provider/dapl_ep_create_with_srq.c	2005-05-10 08:13:29.078008000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_create_with_srq.c	2005-05-11 12:00:02.787969000 -0700
@@ -69,22 +69,19 @@
  *	DAT_INVALID_ATTRIBUTE
  *	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_ep_create_with_srq(DAT_IA_HANDLE ia_handle,
-			DAT_PZ_HANDLE pz_handle,
-			DAT_EVD_HANDLE recv_evd_handle,
-			DAT_EVD_HANDLE request_evd_handle,
-			DAT_EVD_HANDLE connect_evd_handle,
-			DAT_SRQ_HANDLE srq_handle,
-			const struct dat_ep_attr *ep_attr,
-			DAT_EP_HANDLE * ep_handle)
+u32 dapl_ep_create_with_srq(DAT_IA_HANDLE ia_handle, DAT_PZ_HANDLE pz_handle,
+			    DAT_EVD_HANDLE recv_evd_handle,
+			    DAT_EVD_HANDLE request_evd_handle,
+			    DAT_EVD_HANDLE connect_evd_handle,
+			    DAT_SRQ_HANDLE srq_handle,
+			    const struct dat_ep_attr *ep_attr,
+			    DAT_EP_HANDLE *ep_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_EP *ep_ptr;
 	struct dat_ep_attr ep_attr_limit;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
-	dat_status = DAT_SUCCESS;
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ep_create_with_srq (%p, %p, %p, %p, %p, %p, %p %p)\n",
 		     ia_handle,
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_disconnect.c linux-kernel2/dat-provider/dapl_ep_disconnect.c
--- linux-kernel/dat-provider/dapl_ep_disconnect.c	2005-05-02 08:48:17.787970000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_disconnect.c	2005-05-11 12:00:23.524963000 -0700
@@ -63,14 +63,14 @@
  *	DAT_INSUFFICIENT_RESOURCES
  *	DAT_INVALID_PARAMETER
  */
-DAT_RETURN
-dapl_ep_disconnect(DAT_EP_HANDLE ep_handle, DAT_CLOSE_FLAGS disconnect_flags)
+u32 dapl_ep_disconnect(DAT_EP_HANDLE ep_handle,
+		       DAT_CLOSE_FLAGS disconnect_flags)
 {
 	DAPL_EP *ep_ptr;
 	DAPL_EVD *evd_ptr;
 	DAPL_CR *cr_ptr;
 	ib_cm_events_t ib_cm_event;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API | DAPL_DBG_TYPE_CM,
 		     "dapl_ep_disconnect (%p, %x)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_dup_connect.c linux-kernel2/dat-provider/dapl_ep_dup_connect.c
--- linux-kernel/dat-provider/dapl_ep_dup_connect.c	2005-04-20 12:42:08.547017000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_dup_connect.c	2005-05-11 12:00:47.734963000 -0700
@@ -69,15 +69,12 @@
  *	DAT_INVALID_STATE
  *	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_ep_dup_connect(DAT_EP_HANDLE ep_handle,
-		    DAT_EP_HANDLE ep_dup_handle,
-		    DAT_TIMEOUT timeout,
-		    DAT_COUNT private_data_size,
-		    const DAT_PVOID private_data, DAT_QOS qos)
+u32 dapl_ep_dup_connect(DAT_EP_HANDLE ep_handle, DAT_EP_HANDLE ep_dup_handle,
+			DAT_TIMEOUT timeout, DAT_COUNT private_data_size,
+			const DAT_PVOID private_data, DAT_QOS qos)
 {
 	DAPL_EP *ep_dup_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	DAT_IA_ADDRESS_PTR remote_ia_address_ptr;
 	DAT_CONN_QUAL remote_conn_qual;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_free.c linux-kernel2/dat-provider/dapl_ep_free.c
--- linux-kernel/dat-provider/dapl_ep_free.c	2005-05-10 08:13:28.517011000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_free.c	2005-05-11 11:16:06.224962000 -0700
@@ -61,13 +61,13 @@
  *	DAT_INVALID_PARAMETER
  *	DAT_INVALID_STATE
  */
-DAT_RETURN dapl_ep_free(DAT_EP_HANDLE ep_handle)
+u32 dapl_ep_free(DAT_EP_HANDLE ep_handle)
 {
 	DAPL_EP *ep_ptr;
 	DAPL_IA *ia_ptr;
 	struct dat_ep_param *param;
 	ib_qp_state_t save_qp_state;
-	DAT_RETURN dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_ep_free (%p)\n", ep_handle);
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_get_status.c linux-kernel2/dat-provider/dapl_ep_get_status.c
--- linux-kernel/dat-provider/dapl_ep_get_status.c	2005-05-11 08:28:11.861017000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_get_status.c	2005-05-11 12:02:16.057971000 -0700
@@ -59,20 +59,17 @@
  *	DAT_SUCCESS
  *	DAT_INVALID_PARAMETER
  */
-DAT_RETURN
-dapl_ep_get_status(DAT_EP_HANDLE ep_handle,
-		   DAT_EP_STATE * ep_state,
-		   boolean_t *in_dto_idle, boolean_t *out_dto_idle)
+u32 dapl_ep_get_status(DAT_EP_HANDLE ep_handle, DAT_EP_STATE *ep_state,
+		       boolean_t *in_dto_idle, boolean_t *out_dto_idle)
 {
 	DAPL_EP *ep_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ep_get_status (%p, %p, %p, %p)\n",
 		     ep_handle, ep_state, in_dto_idle, out_dto_idle);
 
 	ep_ptr = (DAPL_EP *) ep_handle;
-	dat_status = DAT_SUCCESS;
 
 	/*
 	 * Verify parameter & state
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_modify.c linux-kernel2/dat-provider/dapl_ep_modify.c
--- linux-kernel/dat-provider/dapl_ep_modify.c	2005-05-11 08:28:12.424000000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_modify.c	2005-05-11 12:04:01.023960000 -0700
@@ -52,7 +52,7 @@
  *
  */
 
-static inline DAT_RETURN
+static inline u32
 dapl_ep_modify_validate_parameters(DAT_EP_HANDLE ep_handle,
 				   DAT_EP_PARAM_MASK mask,
 				   const struct dat_ep_param *ep_param,
@@ -65,11 +65,10 @@ dapl_ep_modify_validate_parameters(DAT_E
 	struct dat_ep_attr ep_attr;
 	struct dat_ep_attr ep_attr_limit;
 	struct dat_ep_attr ep_attr_request;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	*ia_ptr = NULL;
 	*ep_ptr = NULL;
-	dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(ep_handle, DAPL_MAGIC_EP)) {
 		dat_status =
@@ -309,8 +308,8 @@ dapl_ep_modify_validate_parameters(DAT_E
  *	DAT_INVALID_ATTRIBUTE
  *	DAT_INVALID_STATE
  */
-DAT_RETURN dapl_ep_modify(DAT_EP_HANDLE ep_handle, DAT_EP_PARAM_MASK mask,
-                          const struct dat_ep_param *ep_param)
+u32 dapl_ep_modify(DAT_EP_HANDLE ep_handle, DAT_EP_PARAM_MASK mask,
+		   const struct dat_ep_param *ep_param)
 {
 	DAPL_IA *ia;
 	DAPL_EP *ep1, *ep2;
@@ -319,7 +318,7 @@ DAT_RETURN dapl_ep_modify(DAT_EP_HANDLE 
 	DAPL_EP alloc_ep;	/* Holder for resources.  */
 	DAPL_PZ *tmp_pz;
 	DAPL_EVD *tmp_evd;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	/* Flag indicating we've allocated a new one of these.  */
 	boolean_t qp_allocated = FALSE;
@@ -585,7 +584,7 @@ DAT_RETURN dapl_ep_modify(DAT_EP_HANDLE 
 
       bail:
 	if (qp_allocated) {
-		DAT_RETURN local_dat_status;
+		u32 local_dat_status;
 		if (dat_status != DAT_SUCCESS || !qp_used) {
 			local_dat_status = dapl_ib_qp_free(ia, &alloc_ep);
 		} else {
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_post_rdma_read.c linux-kernel2/dat-provider/dapl_ep_post_rdma_read.c
--- linux-kernel/dat-provider/dapl_ep_post_rdma_read.c	2005-05-10 08:13:29.096006000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_post_rdma_read.c	2005-05-11 12:04:41.106971000 -0700
@@ -66,16 +66,14 @@
  * 	DAT_PROTECTION_VIOLATION
  * 	DAT_PRIVILEGES_VIOLATION
  */
-DAT_RETURN
-dapl_ep_post_rdma_read(DAT_EP_HANDLE ep_handle,
-		       DAT_COUNT num_segments,
-		       struct dat_lmr_triplet *local_iov,
-		       DAT_DTO_COOKIE user_cookie,
-		       const struct dat_rmr_triplet *remote_iov,
-		       DAT_COMPLETION_FLAGS completion_flags)
+u32 dapl_ep_post_rdma_read(DAT_EP_HANDLE ep_handle, DAT_COUNT num_segments,
+			   struct dat_lmr_triplet *local_iov,
+			   DAT_DTO_COOKIE user_cookie,
+			   const struct dat_rmr_triplet *remote_iov,
+			   DAT_COMPLETION_FLAGS completion_flags)
 {
 
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ep_post_rdma_read (%p, %d, %p, %p, %p, %x)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_post_rdma_write.c linux-kernel2/dat-provider/dapl_ep_post_rdma_write.c
--- linux-kernel/dat-provider/dapl_ep_post_rdma_write.c	2005-05-10 08:13:28.342024000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_post_rdma_write.c	2005-05-11 12:05:08.228968000 -0700
@@ -66,15 +66,13 @@
  *	DAT_PROTECTION_VIOLATION
  *	DAT_PRIVILEGES_VIOLATION
  */
-DAT_RETURN
-dapl_ep_post_rdma_write(DAT_EP_HANDLE ep_handle,
-			DAT_COUNT num_segments,
-			struct dat_lmr_triplet *local_iov,
-			DAT_DTO_COOKIE user_cookie,
-			const struct dat_rmr_triplet *remote_iov,
-			DAT_COMPLETION_FLAGS completion_flags)
+u32 dapl_ep_post_rdma_write(DAT_EP_HANDLE ep_handle, DAT_COUNT num_segments,
+			    struct dat_lmr_triplet *local_iov,
+			    DAT_DTO_COOKIE user_cookie,
+			    const struct dat_rmr_triplet *remote_iov,
+			    DAT_COMPLETION_FLAGS completion_flags)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ep_post_rdma_write (%p, %d, %p, %P, %p, %x)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_post_recv.c linux-kernel2/dat-provider/dapl_ep_post_recv.c
--- linux-kernel/dat-provider/dapl_ep_post_recv.c	2005-05-10 08:13:29.263024000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_post_recv.c	2005-05-11 12:05:45.066971000 -0700
@@ -66,16 +66,14 @@
  * 	DAT_PROTECTION_VIOLATION
  * 	DAT_PROVILEGES_VIOLATION
  */
-DAT_RETURN
-dapl_ep_post_recv(DAT_EP_HANDLE ep_handle,
-		  DAT_COUNT num_segments,
-		  struct dat_lmr_triplet *local_iov,
-		  DAT_DTO_COOKIE user_cookie,
-		  DAT_COMPLETION_FLAGS completion_flags)
+u32 dapl_ep_post_recv(DAT_EP_HANDLE ep_handle, DAT_COUNT num_segments,
+		      struct dat_lmr_triplet *local_iov,
+		      DAT_DTO_COOKIE user_cookie,
+		      DAT_COMPLETION_FLAGS completion_flags)
 {
 	DAPL_EP *ep_ptr;
 	DAPL_COOKIE *cookie;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ep_post_recv (%p, %d, %p, %P, %x)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_post_send.c linux-kernel2/dat-provider/dapl_ep_post_send.c
--- linux-kernel/dat-provider/dapl_ep_post_send.c	2005-05-10 08:13:28.702022000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_post_send.c	2005-05-11 12:06:13.573960000 -0700
@@ -63,15 +63,13 @@
  *	DAT_PROTECTION_VIOLATION
  *	DAT_PRIVILEGES_VIOLATION
  */
-DAT_RETURN
-dapl_ep_post_send(DAT_EP_HANDLE ep_handle,
-		  DAT_COUNT num_segments,
-		  struct dat_lmr_triplet *local_iov,
-		  DAT_DTO_COOKIE user_cookie,
-		  DAT_COMPLETION_FLAGS completion_flags)
+u32 dapl_ep_post_send(DAT_EP_HANDLE ep_handle, DAT_COUNT num_segments,
+		      struct dat_lmr_triplet *local_iov,
+		      DAT_DTO_COOKIE user_cookie,
+		      DAT_COMPLETION_FLAGS completion_flags)
 {
 	struct dat_rmr_triplet remote_iov = { 0, 0, 0, 0 };
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ep_post_send (%p, %d, %p, %P, %x)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_query.c linux-kernel2/dat-provider/dapl_ep_query.c
--- linux-kernel/dat-provider/dapl_ep_query.c	2005-05-10 08:13:28.778009000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_query.c	2005-05-11 12:06:40.494963000 -0700
@@ -57,17 +57,15 @@
  *	DAT_SUCCESS
  *	DAT_INVALID_PARAMETER
  */
-DAT_RETURN
-dapl_ep_query(DAT_EP_HANDLE ep_handle, struct dat_ep_param *ep_param)
+u32 dapl_ep_query(DAT_EP_HANDLE ep_handle, struct dat_ep_param *ep_param)
 {
 	DAPL_EP *ep_ptr;
-	DAT_RETURN status;
+	u32 status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ep_query (%p, %p)\n",
 		     ep_handle, ep_param);
 
-	status = DAT_SUCCESS;
 	ep_ptr = (DAPL_EP *) ep_handle;
 
 	/*
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_recv_query.c linux-kernel2/dat-provider/dapl_ep_recv_query.c
--- linux-kernel/dat-provider/dapl_ep_recv_query.c	2005-05-04 08:19:32.717975000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_recv_query.c	2005-05-11 12:07:41.941768000 -0700
@@ -54,14 +54,11 @@
  *	DAT_INVALID_HANDLE
  *	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_ep_recv_query(DAT_EP_HANDLE ep_handle,
-		   DAT_COUNT * nbufs_allocate, DAT_COUNT * bufs_alloc_span)
+u32 dapl_ep_recv_query(DAT_EP_HANDLE ep_handle,
+		       DAT_COUNT *nbufs_allocate, DAT_COUNT *bufs_alloc_span)
 {
 	DAPL_EP *ep_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_ep_recv_query (%p, %p, %p)\n",
 		     ep_handle, nbufs_allocate, bufs_alloc_span);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_reset.c linux-kernel2/dat-provider/dapl_ep_reset.c
--- linux-kernel/dat-provider/dapl_ep_reset.c	2005-04-20 12:42:07.660015000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_reset.c	2005-05-11 12:08:05.331962000 -0700
@@ -61,12 +61,10 @@
  *	DAT_INVALID_PARAMETER
  *	DAT_INVALID_STATE
  */
-DAT_RETURN dapl_ep_reset(DAT_EP_HANDLE ep_handle)
+u32 dapl_ep_reset(DAT_EP_HANDLE ep_handle)
 {
 	DAPL_EP *ep_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	ep_ptr = (DAPL_EP *) ep_handle;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_set_watermark.c linux-kernel2/dat-provider/dapl_ep_set_watermark.c
--- linux-kernel/dat-provider/dapl_ep_set_watermark.c	2005-04-20 12:42:08.865015000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_set_watermark.c	2005-05-11 12:08:28.540010000 -0700
@@ -59,15 +59,12 @@
  *	DAT_INVALID_HANDLE
  *	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_ep_set_watermark(DAT_EP_HANDLE ep_handle,
-		      DAT_COUNT soft_high_watermark,
-		      DAT_COUNT hard_high_watermark)
+u32 dapl_ep_set_watermark(DAT_EP_HANDLE ep_handle,
+			  DAT_COUNT soft_high_watermark,
+			  DAT_COUNT hard_high_watermark)
 {
 	DAPL_EP *ep_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_ep_set_watermark (%p, %d, %d)\n",
 		     ep_handle, soft_high_watermark, hard_high_watermark);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_util.c linux-kernel2/dat-provider/dapl_ep_util.c
--- linux-kernel/dat-provider/dapl_ep_util.c	2005-05-11 08:28:12.629009000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_util.c	2005-05-11 12:09:16.971011000 -0700
@@ -257,7 +257,7 @@ void dapl_ep_default_attrs(DAPL_EP * ep_
 	return;
 }
 
-DAT_RETURN dapl_ep_check_recv_completion_flags(DAT_COMPLETION_FLAGS flags)
+u32 dapl_ep_check_recv_completion_flags(DAT_COMPLETION_FLAGS flags)
 {
 
 	/*
@@ -276,23 +276,21 @@ DAT_RETURN dapl_ep_check_recv_completion
 	return DAT_SUCCESS;
 }
 
-DAT_RETURN dapl_ep_check_request_completion_flags(DAT_COMPLETION_FLAGS flags)
+u32 dapl_ep_check_request_completion_flags(DAT_COMPLETION_FLAGS flags)
 {
 	return DAT_SUCCESS;
 }
 
-DAT_RETURN
-dapl_ep_post_send_req(DAT_EP_HANDLE ep_handle,
-		      DAT_COUNT num_segments,
-		      struct dat_lmr_triplet *local_iov,
-		      DAT_DTO_COOKIE user_cookie,
-		      const struct dat_rmr_triplet *remote_iov,
-		      DAT_COMPLETION_FLAGS completion_flags,
-		      DAPL_DTO_TYPE dto_type, int op_type)
+u32 dapl_ep_post_send_req(DAT_EP_HANDLE ep_handle, DAT_COUNT num_segments,
+			  struct dat_lmr_triplet *local_iov,
+			  DAT_DTO_COOKIE user_cookie,
+			  const struct dat_rmr_triplet *remote_iov,
+			  DAT_COMPLETION_FLAGS completion_flags,
+			  DAPL_DTO_TYPE dto_type, int op_type)
 {
 	DAPL_EP *ep_ptr;
 	DAPL_COOKIE *cookie;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	if (DAPL_BAD_HANDLE(ep_handle, DAPL_MAGIC_EP)) {
 		dat_status =
@@ -373,9 +371,9 @@ void dapl_ep_timeout(uintptr_t arg)
  * Return the INVALID_STATE connection subtype associated with an
  * INVALID_STATE on an EP. Strictly for error reporting.
  */
-DAT_RETURN_SUBTYPE dapl_ep_state_subtype(DAPL_EP * ep_ptr)
+enum dat_return_subtype dapl_ep_state_subtype(DAPL_EP * ep_ptr)
 {
-	DAT_RETURN_SUBTYPE dat_status;
+	enum dat_return_subtype dat_status;
 
 	switch (ep_ptr->param.ep_state) {
 	case DAT_EP_STATE_UNCONNECTED:
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ep_util.h linux-kernel2/dat-provider/dapl_ep_util.h
--- linux-kernel/dat-provider/dapl_ep_util.h	2005-05-10 08:13:29.059014000 -0700
+++ linux-kernel2/dat-provider/dapl_ep_util.h	2005-05-11 12:09:54.401014000 -0700
@@ -46,23 +46,20 @@ extern DAPL_EP *dapl_ep_alloc(DAPL_IA * 
 
 extern void dapl_ep_dealloc(DAPL_EP * ep_ptr);
 
-extern DAT_RETURN
-dapl_ep_check_recv_completion_flags(DAT_COMPLETION_FLAGS flags);
+extern u32 dapl_ep_check_recv_completion_flags(DAT_COMPLETION_FLAGS flags);
 
-extern DAT_RETURN
-dapl_ep_check_request_completion_flags(DAT_COMPLETION_FLAGS flags);
+extern u32 dapl_ep_check_request_completion_flags(DAT_COMPLETION_FLAGS flags);
 
-extern DAT_RETURN
-dapl_ep_post_send_req(DAT_EP_HANDLE ep_handle,
-		      DAT_COUNT num_segments,
-		      struct dat_lmr_triplet *local_iov,
-		      DAT_DTO_COOKIE user_cookie,
-		      const struct dat_rmr_triplet *remote_iov,
-		      DAT_COMPLETION_FLAGS completion_flags,
-		      DAPL_DTO_TYPE dto_type, int op_type);
+extern u32 dapl_ep_post_send_req(DAT_EP_HANDLE ep_handle,
+				 DAT_COUNT num_segments,
+				 struct dat_lmr_triplet *local_iov,
+				 DAT_DTO_COOKIE user_cookie,
+				 const struct dat_rmr_triplet *remote_iov,
+				 DAT_COMPLETION_FLAGS completion_flags,
+				 DAPL_DTO_TYPE dto_type, int op_type);
 
 void dapl_ep_timeout(uintptr_t arg);
 
-DAT_RETURN_SUBTYPE dapl_ep_state_subtype(DAPL_EP * ep_ptr);
+enum dat_return_subtype dapl_ep_state_subtype(DAPL_EP * ep_ptr);
 
 #endif				/*  DAPL_EP_UTIL_H */
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_connection_callb.c linux-kernel2/dat-provider/dapl_evd_connection_callb.c
--- linux-kernel/dat-provider/dapl_evd_connection_callb.c	2005-05-11 08:28:11.694002000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_connection_callb.c	2005-05-11 11:16:06.285963000 -0700
@@ -69,7 +69,7 @@ dapl_evd_connection_callback(ib_cm_handl
 	DAPL_EP *ep_ptr;
 	DAPL_EVD *evd_ptr;
 	DAT_EVENT_NUMBER dat_event_num;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	int private_data_size;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_CM | DAPL_DBG_TYPE_CALLBACK,
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_cq_async_error_callb.c linux-kernel2/dat-provider/dapl_evd_cq_async_error_callb.c
--- linux-kernel/dat-provider/dapl_evd_cq_async_error_callb.c	2005-04-20 12:42:06.412004000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_cq_async_error_callb.c	2005-05-11 11:16:06.290966000 -0700
@@ -58,7 +58,7 @@ dapl_evd_cq_async_error_callback(ib_erro
 {
 	DAPL_EVD *async_evd;
 	DAPL_EVD *evd;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_CALLBACK | DAPL_DBG_TYPE_EXCEPTION,
 		     "dapl_evd_cq_async_error_callback (%p, %p)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_dequeue.c linux-kernel2/dat-provider/dapl_evd_dequeue.c
--- linux-kernel/dat-provider/dapl_evd_dequeue.c	2005-05-10 08:13:28.796004000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_dequeue.c	2005-05-11 12:11:09.256002000 -0700
@@ -62,17 +62,16 @@
  * 	DAT_QUEUE_EMPTY
  */
 
-DAT_RETURN dapl_evd_dequeue(DAT_EVD_HANDLE evd_handle, struct dat_event *event)
+u32 dapl_evd_dequeue(DAT_EVD_HANDLE evd_handle, struct dat_event *event)
 {
 	DAPL_EVD *evd_ptr;
 	struct dat_event *local_event;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_evd_dequeue (%p, %p)\n", evd_handle, event);
 
 	evd_ptr = (DAPL_EVD *) evd_handle;
-	dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(evd_handle, DAPL_MAGIC_EVD)) {
 		dat_status = DAT_ERROR(DAT_INVALID_HANDLE, 0);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_dto_callb.c linux-kernel2/dat-provider/dapl_evd_dto_callb.c
--- linux-kernel/dat-provider/dapl_evd_dto_callb.c	2005-05-09 11:07:01.636005000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_dto_callb.c	2005-05-11 11:16:06.298964000 -0700
@@ -71,7 +71,7 @@
 void dapl_evd_dto_callback(ib_cq_handle_t cq_handle, void *user_context)
 {
 	DAPL_EVD *evd_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	DAPL_EVD_STATE state;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_CALLBACK,
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_free.c linux-kernel2/dat-provider/dapl_evd_free.c
--- linux-kernel/dat-provider/dapl_evd_free.c	2005-05-04 13:38:41.149012000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_free.c	2005-05-11 12:12:01.796013000 -0700
@@ -39,15 +39,14 @@
 /*
  * Destroy a specific instance of the Event Dispatcher
  */
-DAT_RETURN dapl_evd_free(DAT_EVD_HANDLE evd_handle)
+u32 dapl_evd_free(DAT_EVD_HANDLE evd_handle)
 {
 	DAPL_EVD *evd_ptr;
 	DAPL_CNO *cno_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_evd_free (%p)\n", evd_handle);
 
-	dat_status = DAT_SUCCESS;
 	evd_ptr = (DAPL_EVD *) evd_handle;
 
 	if (DAPL_BAD_HANDLE(evd_handle, DAPL_MAGIC_EVD)) {
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_kcreate.c linux-kernel2/dat-provider/dapl_evd_kcreate.c
--- linux-kernel/dat-provider/dapl_evd_kcreate.c	2005-05-10 08:13:28.913024000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_kcreate.c	2005-05-11 12:12:41.439041000 -0700
@@ -48,16 +48,15 @@
  * even if it is not required. However, it will not be armed.
  */
 
-DAT_RETURN dapl_evd_kcreate(DAT_IA_HANDLE ia_handle, DAT_COUNT evd_min_qlen, 
-			    DAT_UPCALL_POLICY upcall_policy, /* ignore */
-			    const struct dat_upcall_object *upcall,
-			    DAT_EVD_FLAGS evd_flags,
-			    DAT_EVD_HANDLE * evd_handle)
+u32 dapl_evd_kcreate(DAT_IA_HANDLE ia_handle, DAT_COUNT evd_min_qlen,
+		     DAT_UPCALL_POLICY upcall_policy, /* ignore */
+		     const struct dat_upcall_object *upcall,
+		     DAT_EVD_FLAGS evd_flags, DAT_EVD_HANDLE *evd_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_EVD *evd_ptr;
 	DAPL_CNO *cno_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	DAT_EVD_HANDLE evdhandle = (DAT_EVD_HANDLE) NULL;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
@@ -69,7 +68,6 @@ DAT_RETURN dapl_evd_kcreate(DAT_IA_HANDL
 	cno_ptr = NULL;
 	evd_ptr = NULL;
 	*evd_handle = NULL;
-	dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(ia_handle, DAPL_MAGIC_IA)) {
 		dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_kquery.c linux-kernel2/dat-provider/dapl_evd_kquery.c
--- linux-kernel/dat-provider/dapl_evd_kquery.c	2005-05-10 08:13:28.949014000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_kquery.c	2005-05-11 12:13:16.420015000 -0700
@@ -38,13 +38,10 @@
 
 #include "dapl.h"
 
-DAT_RETURN dapl_evd_kquery(DAT_EVD_HANDLE evd_handle,
-			   struct dat_evd_param *evd_param)
+u32 dapl_evd_kquery(DAT_EVD_HANDLE evd_handle, struct dat_evd_param *evd_param)
 {
 	DAPL_EVD *evd_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	if (NULL == evd_param) {
 		dat_status = DAT_ERROR(DAT_INVALID_PARAMETER, DAT_INVALID_ARG3);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_modify_upcall.c linux-kernel2/dat-provider/dapl_evd_modify_upcall.c
--- linux-kernel/dat-provider/dapl_evd_modify_upcall.c	2005-05-10 08:13:28.739072000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_modify_upcall.c	2005-05-11 12:13:46.318006000 -0700
@@ -43,19 +43,17 @@
  * Modify the upcall instance on an EVD
  */
 
-DAT_RETURN dapl_evd_modify_upcall(DAT_EVD_HANDLE evd_handle,
-				  DAT_UPCALL_POLICY upcall_policy, /* ignore */
-				  const struct dat_upcall_object *upcall)
+u32 dapl_evd_modify_upcall(DAT_EVD_HANDLE evd_handle,
+			   DAT_UPCALL_POLICY upcall_policy, /* ignore */
+			   const struct dat_upcall_object *upcall)
 {
 	DAPL_EVD *evd_ptr;
 	DAPL_CNO *cno_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_modify_upcall (%p)\n",
 		     evd_handle);
 
-	dat_status = DAT_SUCCESS;
-
 	evd_ptr = (DAPL_EVD *) evd_handle;
 	cno_ptr = evd_ptr->cno_ptr;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_post_se.c linux-kernel2/dat-provider/dapl_evd_post_se.c
--- linux-kernel/dat-provider/dapl_evd_post_se.c	2005-05-10 08:13:28.553029000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_post_se.c	2005-05-11 12:14:04.553039000 -0700
@@ -59,14 +59,12 @@
  * 	DAT_INVALID_PARAMETER
  */
 
-DAT_RETURN dapl_evd_post_se(DAT_EVD_HANDLE evd_handle,
-			    const struct dat_event *event)
+u32 dapl_evd_post_se(DAT_EVD_HANDLE evd_handle, const struct dat_event *event)
 {
 	DAPL_EVD *evd_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	evd_ptr = (DAPL_EVD *) evd_handle;
-	dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(evd_handle, DAPL_MAGIC_EVD)) {
 		dat_status = DAT_ERROR(DAT_INVALID_HANDLE, 0);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_qp_async_error_callb.c linux-kernel2/dat-provider/dapl_evd_qp_async_error_callb.c
--- linux-kernel/dat-provider/dapl_evd_qp_async_error_callb.c	2005-05-04 08:19:32.774965000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_qp_async_error_callb.c	2005-05-11 11:16:06.330963000 -0700
@@ -60,7 +60,7 @@ dapl_evd_qp_async_error_callback(ib_erro
 	DAPL_EP *ep_ptr;
 	DAPL_EVD *async_evd;
 	DAT_EVENT_NUMBER async_event;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	ep_ptr = (DAPL_EP *) context;
 	async_evd = (DAPL_EVD *) ep_ptr->header.owner_ia->async_error_evd;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_resize.c linux-kernel2/dat-provider/dapl_evd_resize.c
--- linux-kernel/dat-provider/dapl_evd_resize.c	2005-05-09 11:07:01.737008000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_resize.c	2005-05-11 11:16:06.333962000 -0700
@@ -63,12 +63,12 @@
  * 	DAT_INVALID_STATE
  */
 
-DAT_RETURN dapl_evd_resize(DAT_EVD_HANDLE evd_handle, DAT_COUNT evd_qlen)
+u32 dapl_evd_resize(DAT_EVD_HANDLE evd_handle, DAT_COUNT evd_qlen)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_EVD *evd_ptr;
 	DAT_COUNT pend_cnt;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_evd_resize (%p, %d)\n",
 		     evd_handle, evd_qlen);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_un_async_error_callb.c linux-kernel2/dat-provider/dapl_evd_un_async_error_callb.c
--- linux-kernel/dat-provider/dapl_evd_un_async_error_callb.c	2005-04-20 12:42:07.893006000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_un_async_error_callb.c	2005-05-11 11:16:06.338964000 -0700
@@ -59,7 +59,7 @@ dapl_evd_un_async_error_callback(ib_erro
 {
 	DAPL_EVD *async_evd;
 	DAT_EVENT_NUMBER async_event;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_CALLBACK | DAPL_DBG_TYPE_EXCEPTION,
 		     "dapl_evd_un_async_error_callback (%p, %p)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_util.c linux-kernel2/dat-provider/dapl_evd_util.c
--- linux-kernel/dat-provider/dapl_evd_util.c	2005-05-11 08:28:12.854000000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_util.c	2005-05-11 12:18:40.507003000 -0700
@@ -41,7 +41,7 @@
 
 static __inline__ void dapl_evd_eh_print_cqe(ib_work_completion_t * cqe);
 
-DAT_RETURN dapl_evd_event_alloc(DAPL_EVD * evd_ptr, DAT_COUNT qlen);
+u32 dapl_evd_event_alloc(DAPL_EVD *evd_ptr, DAT_COUNT qlen);
 
 /*
  * actually create the evd.  this is called after all parameter checking
@@ -49,17 +49,14 @@ DAT_RETURN dapl_evd_event_alloc(DAPL_EVD
  * to create the default async evd.
  */
 
-DAT_RETURN
-dapl_evd_internal_create(DAPL_IA * ia_ptr,
-			 DAPL_CNO *cno_ptr,
-			 DAT_COUNT min_qlen,
-			 DAT_EVD_FLAGS evd_flags, DAPL_EVD ** evd_ptr_ptr)
+u32 dapl_evd_internal_create(DAPL_IA *ia_ptr, DAPL_CNO *cno_ptr,
+			     DAT_COUNT min_qlen, DAT_EVD_FLAGS evd_flags,
+			     DAPL_EVD **evd_ptr_ptr)
 {
 	DAPL_EVD *evd_ptr;
 	DAT_COUNT cq_len;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
-	dat_status = DAT_SUCCESS;
 	*evd_ptr_ptr = NULL;
 	cq_len = min_qlen;
 
@@ -174,13 +171,11 @@ DAPL_EVD *dapl_evd_alloc(DAPL_IA * ia_pt
 /*
  * alloc events into an EVD.
  */
-DAT_RETURN dapl_evd_event_alloc(DAPL_EVD * evd_ptr, DAT_COUNT qlen)
+u32 dapl_evd_event_alloc(DAPL_EVD *evd_ptr, DAT_COUNT qlen)
 {
 	struct dat_event *event_ptr;
 	DAT_COUNT i;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	/* Allocate EVENTs */
 	event_ptr =
@@ -218,13 +213,13 @@ DAT_RETURN dapl_evd_event_alloc(DAPL_EVD
 /*
  * realloc events into an EVD.
  */
-DAT_RETURN dapl_evd_event_realloc(DAPL_EVD * evd_ptr, DAT_COUNT qlen)
+u32 dapl_evd_event_realloc(DAPL_EVD *evd_ptr, DAT_COUNT qlen)
 {
     struct dat_event *events;
     DAT_COUNT	old_qlen;
     DAT_COUNT   i;
     intptr_t	diff;
-    DAT_RETURN	dat_status;
+	u32 dat_status;
 
     /* Allocate EVENTs */
     events = (struct dat_event *)dapl_os_realloc(evd_ptr->events,
@@ -274,13 +269,11 @@ bail:
  * will clean up all of the internal data structures and report the
  * error.
  */
-DAT_RETURN dapl_evd_dealloc(DAPL_EVD * evd_ptr)
+u32 dapl_evd_dealloc(DAPL_EVD *evd_ptr)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	DAPL_IA *ia_ptr;
 
-	dat_status = DAT_SUCCESS;
-
 	dapl_os_assert(evd_ptr->header.magic == DAPL_MAGIC_EVD);
 	dapl_os_assert(atomic_read(&evd_ptr->evd_ref_count) == 0);
 
@@ -419,9 +412,10 @@ static struct dat_event *dapl_evd_get_ev
  * entry to this function.
  */
 
-static void dapl_evd_post_event(DAPL_EVD * evd_ptr, const struct dat_event * event_ptr)
+static void dapl_evd_post_event(DAPL_EVD *evd_ptr,
+				const struct dat_event *event_ptr)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	DAPL_CNO * cno_to_trigger = NULL;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_EVD,
@@ -511,12 +505,12 @@ static struct dat_event *dapl_evd_get_an
 	return event_ptr;
 }
 
-DAT_RETURN
-dapl_evd_post_cr_arrival_event(DAPL_EVD * evd_ptr,
-			       DAT_EVENT_NUMBER event_number,
-			       DAT_SP_HANDLE sp_handle,
-			       DAT_IA_ADDRESS_PTR ia_address_ptr,
-			       DAT_CONN_QUAL conn_qual, DAT_CR_HANDLE cr_handle)
+u32 dapl_evd_post_cr_arrival_event(DAPL_EVD *evd_ptr,
+				   DAT_EVENT_NUMBER event_number,
+				   DAT_SP_HANDLE sp_handle,
+				   DAT_IA_ADDRESS_PTR ia_address_ptr,
+				   DAT_CONN_QUAL conn_qual,
+				   DAT_CR_HANDLE cr_handle)
 {
 	struct dat_event *event_ptr;
 	event_ptr = dapl_evd_get_and_init_event(evd_ptr, event_number);
@@ -542,12 +536,11 @@ dapl_evd_post_cr_arrival_event(DAPL_EVD 
 	return DAT_SUCCESS;
 }
 
-DAT_RETURN
-dapl_evd_post_connection_event(DAPL_EVD * evd_ptr,
-			       DAT_EVENT_NUMBER event_number,
-			       DAT_EP_HANDLE ep_handle,
-			       DAT_COUNT private_data_size,
-			       DAT_PVOID private_data)
+u32 dapl_evd_post_connection_event(DAPL_EVD *evd_ptr,
+				   DAT_EVENT_NUMBER event_number,
+				   DAT_EP_HANDLE ep_handle,
+				   DAT_COUNT private_data_size,
+				   DAT_PVOID private_data)
 {
 	struct dat_event *event_ptr;
 	event_ptr = dapl_evd_get_and_init_event(evd_ptr, event_number);
@@ -572,10 +565,9 @@ dapl_evd_post_connection_event(DAPL_EVD 
 	return DAT_SUCCESS;
 }
 
-DAT_RETURN
-dapl_evd_post_async_error_event(DAPL_EVD * evd_ptr,
-				DAT_EVENT_NUMBER event_number,
-				DAT_IA_HANDLE ia_handle)
+u32 dapl_evd_post_async_error_event(DAPL_EVD *evd_ptr,
+				    DAT_EVENT_NUMBER event_number,
+				    DAT_IA_HANDLE ia_handle)
 {
 	struct dat_event *event_ptr;
 	event_ptr = dapl_evd_get_and_init_event(evd_ptr, event_number);
@@ -598,9 +590,9 @@ dapl_evd_post_async_error_event(DAPL_EVD
 	return DAT_SUCCESS;
 }
 
-DAT_RETURN
-dapl_evd_post_software_event(DAPL_EVD * evd_ptr,
-			     DAT_EVENT_NUMBER event_number, DAT_PVOID pointer)
+u32 dapl_evd_post_software_event(DAPL_EVD *evd_ptr,
+				 DAT_EVENT_NUMBER event_number,
+				 DAT_PVOID pointer)
 {
 	struct dat_event *event_ptr;
 	event_ptr = dapl_evd_get_and_init_event(evd_ptr, event_number);
@@ -775,10 +767,9 @@ dapl_evd_cqe_to_event(DAPL_EVD * evd_ptr
  * 	Status of operation
  *
  */
-DAT_RETURN dapl_evd_cq_poll_to_event(DAPL_EVD * evd_ptr,
-				     struct dat_event *event)
+u32 dapl_evd_cq_poll_to_event(DAPL_EVD *evd_ptr, struct dat_event *event)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	ib_work_completion_t cur_cqe;
 
 	dat_status = dapl_ib_completion_poll(evd_ptr->header.owner_ia->hca_ptr,
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_evd_util.h linux-kernel2/dat-provider/dapl_evd_util.h
--- linux-kernel/dat-provider/dapl_evd_util.h	2005-05-10 08:13:29.134055000 -0700
+++ linux-kernel2/dat-provider/dapl_evd_util.h	2005-05-11 12:21:06.564007000 -0700
@@ -40,17 +40,16 @@
 
 #include "dapl.h"
 
-DAT_RETURN
-dapl_evd_internal_create(DAPL_IA * ia_ptr, DAPL_CNO * cno_ptr,
-			 DAT_COUNT min_qlen,
-			 DAT_EVD_FLAGS evd_flags, DAPL_EVD ** evd_ptr_ptr);
+u32 dapl_evd_internal_create(DAPL_IA *ia_ptr, DAPL_CNO *cno_ptr,
+			     DAT_COUNT min_qlen, DAT_EVD_FLAGS evd_flags,
+			     DAPL_EVD **evd_ptr_ptr);
 
 DAPL_EVD *dapl_evd_alloc(DAPL_IA * ia_ptr, DAPL_CNO * cno_ptr,
 			 DAT_EVD_FLAGS evd_flags, DAT_COUNT qlen);
 
-DAT_RETURN dapl_evd_dealloc(DAPL_EVD * evd_ptr);
+u32 dapl_evd_dealloc(DAPL_EVD *evd_ptr);
 
-DAT_RETURN dapl_evd_event_realloc(DAPL_EVD * evd_ptr, DAT_COUNT qlen);
+u32 dapl_evd_event_realloc(DAPL_EVD *evd_ptr, DAT_COUNT qlen);
 
 /*
  * Each of these functions will retrieve a free event from
@@ -63,30 +62,26 @@ DAT_RETURN dapl_evd_event_realloc(DAPL_E
  * DAT_SUCCESS otherwise.
  */
 
-DAT_RETURN
-dapl_evd_post_cr_arrival_event(DAPL_EVD * evd_ptr,
-			       DAT_EVENT_NUMBER event_number,
-			       DAT_SP_HANDLE sp_handle,
-			       DAT_IA_ADDRESS_PTR ia_address_ptr,
-			       DAT_CONN_QUAL conn_qual,
-			       DAT_CR_HANDLE cr_handle);
-
-DAT_RETURN
-dapl_evd_post_connection_event(DAPL_EVD * evd_ptr,
-			       DAT_EVENT_NUMBER event_number,
-			       DAT_EP_HANDLE ep_handle,
-			       DAT_COUNT private_data_size,
-			       DAT_PVOID private_data);
-
-DAT_RETURN
-dapl_evd_post_async_error_event(DAPL_EVD * evd_ptr,
-				DAT_EVENT_NUMBER event_number,
-				DAT_IA_HANDLE ia_handle);
-
-DAT_RETURN
-dapl_evd_post_software_event(DAPL_EVD * evd_ptr,
-			     DAT_EVENT_NUMBER event_number, DAT_PVOID pointer);
-
+u32 dapl_evd_post_cr_arrival_event(DAPL_EVD *evd_ptr,
+				   DAT_EVENT_NUMBER event_number,
+				   DAT_SP_HANDLE sp_handle,
+				   DAT_IA_ADDRESS_PTR ia_address_ptr,
+				   DAT_CONN_QUAL conn_qual,
+				   DAT_CR_HANDLE cr_handle);
+
+u32 dapl_evd_post_connection_event(DAPL_EVD *evd_ptr,
+				   DAT_EVENT_NUMBER event_number,
+				   DAT_EP_HANDLE ep_handle,
+				   DAT_COUNT private_data_size,
+				   DAT_PVOID private_data);
+
+u32 dapl_evd_post_async_error_event(DAPL_EVD *evd_ptr,
+				    DAT_EVENT_NUMBER event_number,
+				    DAT_IA_HANDLE ia_handle);
+
+u32 dapl_evd_post_software_event(DAPL_EVD *evd_ptr,
+				 DAT_EVENT_NUMBER event_number,
+				 DAT_PVOID pointer); 
 
 /*************************************
  * dapl internal callbacks functions *
@@ -111,7 +106,7 @@ extern void dapl_evd_cq_async_error_call
 extern void dapl_evd_qp_async_error_callback(ib_error_record_t * cause_ptr,
 					     void *context);
 
-extern DAT_RETURN dapl_evd_cq_poll_to_event(DAPL_EVD * evd_ptr,
-					    struct dat_event *event);
+extern u32 dapl_evd_cq_poll_to_event(DAPL_EVD *evd_ptr,
+				     struct dat_event *event);
 
 #endif
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_get_consumer_context.c linux-kernel2/dat-provider/dapl_get_consumer_context.c
--- linux-kernel/dat-provider/dapl_get_consumer_context.c	2005-04-20 12:42:06.961003000 -0700
+++ linux-kernel2/dat-provider/dapl_get_consumer_context.c	2005-05-11 12:21:23.159014000 -0700
@@ -55,14 +55,11 @@
  * 	DAT_SUCCESS
  * 	DAT_INVALID_PARAMETER
  */
-DAT_RETURN
-dapl_get_consumer_context(DAT_HANDLE dat_handle, DAT_CONTEXT * context)
+u32 dapl_get_consumer_context(DAT_HANDLE dat_handle, DAT_CONTEXT *context)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	DAPL_HEADER *header;
 
-	dat_status = DAT_SUCCESS;
-
 	header = (DAPL_HEADER *) dat_handle;
 	if (((header) == NULL) ||
 	    ((unsigned long)(header) & 3) ||
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_get_handle_type.c linux-kernel2/dat-provider/dapl_get_handle_type.c
--- linux-kernel/dat-provider/dapl_get_handle_type.c	2005-04-20 12:42:08.013010000 -0700
+++ linux-kernel2/dat-provider/dapl_get_handle_type.c	2005-05-11 12:21:50.885012000 -0700
@@ -56,14 +56,11 @@
  * 	DAT_INVALID_PARAMETER
  */
 
-DAT_RETURN
-dapl_get_handle_type(DAT_HANDLE dat_handle, DAT_HANDLE_TYPE * handle_type)
+u32 dapl_get_handle_type(DAT_HANDLE dat_handle, DAT_HANDLE_TYPE *handle_type)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	DAPL_HEADER *header;
 
-	dat_status = DAT_SUCCESS;
-
 	header = (DAPL_HEADER *) dat_handle;
 	if (((header) == NULL) ||
 	    ((unsigned long)(header) & 3) ||
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl.h linux-kernel2/dat-provider/dapl.h
--- linux-kernel/dat-provider/dapl.h	2005-05-11 11:08:04.453960000 -0700
+++ linux-kernel2/dat-provider/dapl.h	2005-05-11 13:23:31.584000000 -0700
@@ -138,8 +138,6 @@ typedef enum dapl_qp_state {
 #define DEBUG_IS_BAD_HANDLE(h, magicNum) (0)
 #endif
 
-#define DAT_ERROR(Type, SubType) ((DAT_RETURN)(DAT_CLASS_ERROR | Type | SubType))
-
 /*********************************************************************
  *                                                                   *
  * Typedefs                                                          *
@@ -477,275 +475,245 @@ typedef char DAPL_HCA_NAME[DAPL_HCA_NAME
  * DAT API functions
  */
 
-extern DAT_RETURN dapl_ia_open(const DAT_NAME_PTR, DAT_COUNT, DAT_EVD_HANDLE *, 
-                               DAT_IA_HANDLE *);
+extern u32 dapl_ia_open(const DAT_NAME_PTR, DAT_COUNT, DAT_EVD_HANDLE *,
+			DAT_IA_HANDLE *);
 
-extern DAT_RETURN dapl_ia_close(DAT_IA_HANDLE, DAT_CLOSE_FLAGS);
+extern u32 dapl_ia_close(DAT_IA_HANDLE, DAT_CLOSE_FLAGS);
 
-extern DAT_RETURN dapl_ia_query(DAT_IA_HANDLE,
-				DAT_EVD_HANDLE *,
-				struct dat_ia_attr *,
-				struct dat_provider_attr *);
+extern u32 dapl_ia_query(DAT_IA_HANDLE, DAT_EVD_HANDLE *, struct dat_ia_attr *,
+			 struct dat_provider_attr *);
 
 /* helper functions */
 
-extern DAT_RETURN dapl_set_consumer_context(DAT_HANDLE,		/* dat handle */
-					    DAT_CONTEXT);	/* context */
+extern u32 dapl_set_consumer_context(DAT_HANDLE handle, DAT_CONTEXT context);
 
-extern DAT_RETURN dapl_get_consumer_context(DAT_HANDLE,		/* dat handle */
-					    DAT_CONTEXT *);	/* context */
+extern u32 dapl_get_consumer_context(DAT_HANDLE handle, DAT_CONTEXT *context);
 
-extern DAT_RETURN dapl_get_handle_type(DAT_HANDLE, DAT_HANDLE_TYPE *);
+extern u32 dapl_get_handle_type(DAT_HANDLE handle, DAT_HANDLE_TYPE *context);
 
 /* CR Functions */
 
-extern DAT_RETURN dapl_cr_query(DAT_CR_HANDLE, struct dat_cr_param *);	
+extern u32 dapl_cr_query(DAT_CR_HANDLE, struct dat_cr_param *);	
 
-extern DAT_RETURN dapl_cr_accept(DAT_CR_HANDLE,	/* cr_handle */
-				 DAT_EP_HANDLE,	/* ep_handle */
-				 DAT_COUNT,	/* private_data_size */
-				 const DAT_PVOID);	/* private_data */
+extern u32 dapl_cr_accept(DAT_CR_HANDLE cr_handle, DAT_EP_HANDLE ep_handle,
+			  DAT_COUNT private_data_size,
+			  const DAT_PVOID private_data);
 
-extern DAT_RETURN dapl_cr_reject(DAT_CR_HANDLE);
+extern u32 dapl_cr_reject(DAT_CR_HANDLE cr_handle);
 
-extern DAT_RETURN dapl_cr_handoff(DAT_CR_HANDLE,	/* cr_handle */
-				  DAT_CONN_QUAL);	/* handoff */
+extern u32 dapl_cr_handoff(DAT_CR_HANDLE cr_handle, DAT_CONN_QUAL handoff);
 
 /* EVD Functions */
-extern DAT_RETURN dapl_ia_memtype_hint(DAT_IA_HANDLE,	/* ia_handle */
-				       DAT_MEM_TYPE,	/* mem_type */
-				       DAT_VLEN,	/* length */
-				       DAT_MEM_OPT,	/* mem_optimization */
-				       DAT_VLEN *,	/* suggested_length */
-				       DAT_VADDR *);	/* suggested_alignment */
+extern u32 dapl_ia_memtype_hint(DAT_IA_HANDLE ia_handle, DAT_MEM_TYPE mem_type,
+				DAT_VLEN length, DAT_MEM_OPT mem_optimization,
+				DAT_VLEN *suggested_length,
+				DAT_VADDR *suggested_alignment);
 
-extern DAT_RETURN dapl_evd_kcreate(DAT_IA_HANDLE,	/* ia_handle */
-				   DAT_COUNT,	/* evd_min_qlen */
-				   DAT_UPCALL_POLICY,	/* upcall_policy */
-				   const struct dat_upcall_object *,/* upcall */
-				   DAT_EVD_FLAGS,	/* evd_flags */
-				   DAT_EVD_HANDLE *);	/* evd_handle */
+extern u32 dapl_evd_kcreate(DAT_IA_HANDLE ia_handle, DAT_COUNT evd_min_qlen,
+			    DAT_UPCALL_POLICY upcall_policy,
+			    const struct dat_upcall_object * upcall,
+			    DAT_EVD_FLAGS evd_flags,
+			    DAT_EVD_HANDLE * evd_handle);
 
-extern DAT_RETURN dapl_evd_kquery(DAT_EVD_HANDLE,	/* evd_handle */
-				  struct dat_evd_param *);	/* evd_args */
+extern u32 dapl_evd_kquery(DAT_EVD_HANDLE evd_handle,
+			   struct dat_evd_param *evd_args);
 
-extern DAT_RETURN dapl_evd_modify_upcall(DAT_EVD_HANDLE,	/* evd_handle */
-					 DAT_UPCALL_POLICY,	/* upcall_policy */
-					 const struct dat_upcall_object *);	/* upcall */
+extern u32 dapl_evd_modify_upcall(DAT_EVD_HANDLE evd_handle,
+				  DAT_UPCALL_POLICY upcall_policy,
+				  const struct dat_upcall_object * upcall);
 
-extern DAT_RETURN dapl_evd_enable(DAT_EVD_HANDLE);	/* evd_handle */
+extern u32 dapl_evd_enable(DAT_EVD_HANDLE evd_handle);
 
-extern DAT_RETURN dapl_evd_disable(DAT_EVD_HANDLE);	/* evd_handle */
+extern u32 dapl_evd_disable(DAT_EVD_HANDLE evd_handle);
 
-extern DAT_RETURN dapl_evd_resize(DAT_EVD_HANDLE,	/* evd_handle */
-				  DAT_COUNT);	/* evd_qlen */
+extern u32 dapl_evd_resize(DAT_EVD_HANDLE evd_handle, DAT_COUNT evd_qlen);
 
-extern DAT_RETURN dapl_evd_post_se(DAT_EVD_HANDLE,	/* evd_handle */
-				   const struct dat_event *);	/* event */
+extern u32 dapl_evd_post_se(DAT_EVD_HANDLE evd_handle,
+			    const struct dat_event *event);
 
-extern DAT_RETURN dapl_evd_dequeue(DAT_EVD_HANDLE,	/* evd_handle */
-				   struct dat_event *);	/* event */
+extern u32 dapl_evd_dequeue(DAT_EVD_HANDLE evd_handle, struct dat_event *event);
 
-extern DAT_RETURN dapl_evd_free(DAT_EVD_HANDLE);
+extern u32 dapl_evd_free(DAT_EVD_HANDLE evd_handle);
 
-extern DAT_RETURN dapl_evd_set_unwaitable(DAT_EVD_HANDLE evd_handle);
+extern u32 dapl_evd_set_unwaitable(DAT_EVD_HANDLE evd_handle);
 
-extern DAT_RETURN dapl_evd_clear_unwaitable(DAT_EVD_HANDLE evd_handle);
+extern u32 dapl_evd_clear_unwaitable(DAT_EVD_HANDLE evd_handle);
 
 /* EP functions */
 
-extern DAT_RETURN dapl_ep_create(DAT_IA_HANDLE,	/* ia_handle */
-				 DAT_PZ_HANDLE,	/* pz_handle */
-				 DAT_EVD_HANDLE,	/* in_dto_completion_evd_handle */
-				 DAT_EVD_HANDLE,	/* out_dto_completion_evd_handle */
-				 DAT_EVD_HANDLE,	/* connect_evd_handle */
-				 const struct dat_ep_attr *,	/* ep_parameters */
-				 DAT_EP_HANDLE *);	/* ep_handle */
-
-extern DAT_RETURN dapl_ep_query(DAT_EP_HANDLE, struct dat_ep_param *);
-
-extern DAT_RETURN dapl_ep_modify(DAT_EP_HANDLE,	/* ep_handle */
-				 DAT_EP_PARAM_MASK,	/* ep_args_mask */
-				 const struct dat_ep_param *);	/* ep_args */
-
-extern DAT_RETURN dapl_ep_connect(DAT_EP_HANDLE,	/* ep_handle */
-				  DAT_IA_ADDRESS_PTR,	/* remote_ia_address */
-				  DAT_CONN_QUAL,	/* remote_conn_qual */
-				  DAT_TIMEOUT,	/* timeout */
-				  DAT_COUNT,	/* private_data_size */
-				  const DAT_PVOID,	/* private_data  */
-				  DAT_QOS,	/* quality_of_service */
-				  DAT_CONNECT_FLAGS);	/* connect_flags */
-
-extern DAT_RETURN dapl_ep_dup_connect(DAT_EP_HANDLE,	/* ep_handle */
-				      DAT_EP_HANDLE,	/* ep_dup_handle */
-				      DAT_TIMEOUT,	/* timeout */
-				      DAT_COUNT,	/* private_data_size */
-				      const DAT_PVOID,	/* private_data */
-				      DAT_QOS);	/* quality_of_service */
-
-extern DAT_RETURN dapl_ep_disconnect(DAT_EP_HANDLE,	/* ep_handle */
-				     DAT_CLOSE_FLAGS);	/* close_flags */
-
-extern DAT_RETURN dapl_ep_post_send(DAT_EP_HANDLE,	/* ep_handle */
-				    DAT_COUNT,	/* num_segments */
-				    struct dat_lmr_triplet *,	/* local_iov */
-				    DAT_DTO_COOKIE,	/* user_cookie */
-				    DAT_COMPLETION_FLAGS);	/* completion_flags */
-
-extern DAT_RETURN dapl_ep_post_recv(DAT_EP_HANDLE,	/* ep_handle */
-				    DAT_COUNT,	/* num_segments */
-				    struct dat_lmr_triplet *,	/* local_iov */
-				    DAT_DTO_COOKIE,	/* user_cookie */
-				    DAT_COMPLETION_FLAGS);	/* completion_flags */
-
-extern DAT_RETURN dapl_ep_post_rdma_read(DAT_EP_HANDLE,	/* ep_handle */
-					 DAT_COUNT,	/* num_segments */
-					 struct dat_lmr_triplet *,	/* local_iov */
-					 DAT_DTO_COOKIE,	/* user_cookie */
-					 const struct dat_rmr_triplet *,	/* remote_iov */
-					 DAT_COMPLETION_FLAGS);	/* completion_flags */
-
-extern DAT_RETURN dapl_ep_post_rdma_write(DAT_EP_HANDLE,	/* ep_handle */
-					  DAT_COUNT,	/* num_segments */
-					  struct dat_lmr_triplet *,	/* local_iov */
-					  DAT_DTO_COOKIE,	/* user_cookie */
-					  const struct dat_rmr_triplet *,	/* remote_iov */
-					  DAT_COMPLETION_FLAGS);	/* completion_flags */
-
-extern DAT_RETURN dapl_ep_get_status(DAT_EP_HANDLE,	/* ep_handle */
-				     DAT_EP_STATE *,	/* ep_state */
-				     boolean_t *,	/* in_dto_idle */
-				     boolean_t *);	/* out_dto_idle */
-
-extern DAT_RETURN dapl_ep_free(DAT_EP_HANDLE);	/* ep_handle */
-
-extern DAT_RETURN dapl_ep_reset(DAT_EP_HANDLE);	/* ep_handle */
-
-extern DAT_RETURN dapl_ep_create_with_srq(DAT_IA_HANDLE,	/* ia_handle            */
-					  DAT_PZ_HANDLE,	/* pz_handle            */
-					  DAT_EVD_HANDLE,	/* recv_evd_handle      */
-					  DAT_EVD_HANDLE,	/* request_evd_handle   */
-					  DAT_EVD_HANDLE,	/* connect_evd_handle   */
-					  DAT_SRQ_HANDLE,	/* srq_handle           */
-					  const struct dat_ep_attr *,	/* ep_attributes        */
-					  DAT_EP_HANDLE *);	/* ep_handle            */
-
-extern DAT_RETURN dapl_ep_recv_query(DAT_EP_HANDLE,	/* ep_handle            */
-				     DAT_COUNT *,	/* nbufs_allocated      */
-				     DAT_COUNT *);	/* bufs_alloc_span      */
-
-extern DAT_RETURN dapl_ep_set_watermark(DAT_EP_HANDLE,	/* ep_handle            */
-					DAT_COUNT,	/* soft_high_watermark  */
-					DAT_COUNT);	/* hard_high_watermark  */
+extern u32 dapl_ep_create(DAT_IA_HANDLE ia_handle, DAT_PZ_HANDLE pz_handle,
+			  DAT_EVD_HANDLE in_dto_completion_evd_handle,
+			  DAT_EVD_HANDLE out_dto_completion_evd_handle,
+			  DAT_EVD_HANDLE connect_evd_handle,
+			  const struct dat_ep_attr *ep_parameters,
+			  DAT_EP_HANDLE *ep_handle);
+
+extern u32 dapl_ep_query(DAT_EP_HANDLE, struct dat_ep_param *);
+
+extern u32 dapl_ep_modify(DAT_EP_HANDLE ep_handle,
+			  DAT_EP_PARAM_MASK ep_args_mask,
+			  const struct dat_ep_param *ep_args);
+
+extern u32 dapl_ep_connect(DAT_EP_HANDLE ep_handle,
+			   DAT_IA_ADDRESS_PTR remote_ia_address,
+			   DAT_CONN_QUAL remote_conn_qual,
+			   DAT_TIMEOUT timeout,
+			   DAT_COUNT private_data_size,
+			   const DAT_PVOID private_data,
+			   DAT_QOS quality_of_service,
+			   DAT_CONNECT_FLAGS connect_flags);
+
+extern u32 dapl_ep_dup_connect(DAT_EP_HANDLE ep_handle,
+			       DAT_EP_HANDLE ep_dup_handle, DAT_TIMEOUT timeout,
+			       DAT_COUNT private_data_size,
+			       const DAT_PVOID private_data,
+			       DAT_QOS quality_of_service);
+
+extern u32 dapl_ep_disconnect(DAT_EP_HANDLE ep_handle,
+			      DAT_CLOSE_FLAGS close_flags);
+
+extern u32 dapl_ep_post_send(DAT_EP_HANDLE ep_handle, DAT_COUNT num_segments,
+			     struct dat_lmr_triplet *local_iov,
+			     DAT_DTO_COOKIE user_cookie,
+			     DAT_COMPLETION_FLAGS completion_flags);
+
+extern u32 dapl_ep_post_recv(DAT_EP_HANDLE ep_handle, DAT_COUNT num_segments,
+			     struct dat_lmr_triplet *local_iov,
+			     DAT_DTO_COOKIE user_cookie,
+			     DAT_COMPLETION_FLAGS completion_flags);
+
+extern u32 dapl_ep_post_rdma_read(DAT_EP_HANDLE ep_handle,
+				  DAT_COUNT num_segments,
+				  struct dat_lmr_triplet *local_iov,
+				  DAT_DTO_COOKIE user_cookie,
+				  const struct dat_rmr_triplet *remote_iov,
+				  DAT_COMPLETION_FLAGS completion_flags);
+
+extern u32 dapl_ep_post_rdma_write(DAT_EP_HANDLE ep_handle,
+				   DAT_COUNT num_segments,
+				   struct dat_lmr_triplet *local_iov,
+				   DAT_DTO_COOKIE user_cookie,
+				   const struct dat_rmr_triplet *remote_iov,
+				   DAT_COMPLETION_FLAGS completion_flags);
+
+extern u32 dapl_ep_get_status(DAT_EP_HANDLE ep_handle, DAT_EP_STATE *ep_state,
+			      boolean_t *in_dto_idle, boolean_t *out_dto_idle);
+
+extern u32 dapl_ep_free(DAT_EP_HANDLE ep_handle);
+
+extern u32 dapl_ep_reset(DAT_EP_HANDLE ep_handle);
+
+extern u32 dapl_ep_create_with_srq(DAT_IA_HANDLE ia_handle,
+				   DAT_PZ_HANDLE pz_handle,
+				   DAT_EVD_HANDLE recv_evd_handle,
+				   DAT_EVD_HANDLE request_evd_handle,
+				   DAT_EVD_HANDLE connect_evd_handle,
+				   DAT_SRQ_HANDLE srq_handle,
+				   const struct dat_ep_attr *ep_attributes,
+				   DAT_EP_HANDLE *ep_handle);
+
+extern u32 dapl_ep_recv_query(DAT_EP_HANDLE ep_handle,
+			      DAT_COUNT *nbufs_allocated,
+			      DAT_COUNT *bufs_alloc_span);
+
+extern u32 dapl_ep_set_watermark(DAT_EP_HANDLE ep_handle,
+				 DAT_COUNT soft_high_watermark,
+				 DAT_COUNT hard_high_watermark);
 
 /* LMR functions */
 
-extern DAT_RETURN dapl_lmr_kcreate(DAT_IA_HANDLE,	/* ia_handle */
-				   DAT_MEM_TYPE,	/* mem_type */
-				   DAT_REGION_DESCRIPTION,	/* region_description */
-				   DAT_VLEN,	/* length */
-				   DAT_PZ_HANDLE,	/* pz_handle */
-				   DAT_MEM_PRIV_FLAGS,	/* privileges */
-				   DAT_MEM_OPT,	/* optimization */
-				   DAT_LMR_HANDLE *,	/* lmr_handle */
-				   DAT_LMR_CONTEXT *,	/* lmr_context */
-				   DAT_RMR_CONTEXT *,	/* rmr_context          */
-				   DAT_VLEN *,	/* registered_length */
-				   DAT_VADDR *);	/* registered_address */
-
-extern DAT_RETURN dapl_lmr_query(DAT_LMR_HANDLE, struct dat_lmr_param *);
-
-extern DAT_RETURN dapl_lmr_free(DAT_LMR_HANDLE);
-
-extern DAT_RETURN dapl_lmr_sync_rdma_read(DAT_IA_HANDLE,	/* ia_handle            */
-					  const struct dat_lmr_triplet *,	/* local_segments      */
-					  DAT_VLEN);	/* num_segments         */
-
-extern DAT_RETURN dapl_lmr_sync_rdma_write(DAT_IA_HANDLE,	/* ia_handle            */
-					   const struct dat_lmr_triplet *,	/* local_segments      */
-					   DAT_VLEN);	/* num_segments         */
+extern u32 dapl_lmr_kcreate(DAT_IA_HANDLE ia_handle, DAT_MEM_TYPE mem_type,
+			    DAT_REGION_DESCRIPTION region_description,
+			    DAT_VLEN length, DAT_PZ_HANDLE pz_handle,
+			    DAT_MEM_PRIV_FLAGS privileges,
+			    DAT_MEM_OPT optimization,
+			    DAT_LMR_HANDLE *lmr_handle,
+			    DAT_LMR_CONTEXT *lmr_context,
+			    DAT_RMR_CONTEXT *rmr_context,
+			    DAT_VLEN *registered_length,
+			    DAT_VADDR *registered_address);
+
+extern u32 dapl_lmr_query(DAT_LMR_HANDLE, struct dat_lmr_param *);
+
+extern u32 dapl_lmr_free(DAT_LMR_HANDLE);
+
+extern u32 dapl_lmr_sync_rdma_read(DAT_IA_HANDLE ia_handle,
+				   const struct dat_lmr_triplet *local_segments,
+				   DAT_VLEN num_segments);
+
+extern u32 dapl_lmr_sync_rdma_write(DAT_IA_HANDLE ia_handle,
+				    const struct dat_lmr_triplet *local_segments,
+				    DAT_VLEN num_segments);
 
 /* RMR Functions */
 
-extern DAT_RETURN dapl_rmr_create(DAT_PZ_HANDLE,	/* pz_handle */
-				  DAT_RMR_HANDLE *);	/* rmr_handle */
+extern u32 dapl_rmr_create(DAT_PZ_HANDLE pz_handle, DAT_RMR_HANDLE *rmr_handle);
 
-extern DAT_RETURN dapl_rmr_query(DAT_RMR_HANDLE,	/* rmr_handle */
-				 struct dat_rmr_param *);	/* rmr_args */
+extern u32 dapl_rmr_query(DAT_RMR_HANDLE rmr_handle,
+			  struct dat_rmr_param *rmr_args);
 
-extern DAT_RETURN dapl_rmr_bind(DAT_RMR_HANDLE,	/* rmr_handle */
-				const struct dat_lmr_triplet *,	/* lmr_triplet */
-				DAT_MEM_PRIV_FLAGS,	/* mem_priv */
-				DAT_EP_HANDLE,	/* ep_handle */
-				DAT_RMR_COOKIE,	/* user_cookie */
-				DAT_COMPLETION_FLAGS,	/* completion_flags */
-				DAT_RMR_CONTEXT *);	/* context */
+extern u32 dapl_rmr_bind(DAT_RMR_HANDLE rmr_handle,
+			 const struct dat_lmr_triplet *lmr_triplet,
+			 DAT_MEM_PRIV_FLAGS mem_priv, DAT_EP_HANDLE ep_handle,
+			 DAT_RMR_COOKIE user_cookie,
+			 DAT_COMPLETION_FLAGS completion_flags,
+			 DAT_RMR_CONTEXT *context);
 
-extern DAT_RETURN dapl_rmr_free(DAT_RMR_HANDLE);
+extern u32 dapl_rmr_free(DAT_RMR_HANDLE);
 
 /* PSP Functions */
 
-extern DAT_RETURN dapl_psp_create(DAT_IA_HANDLE,	/* ia_handle */
-				  DAT_CONN_QUAL,	/* conn_qual */
-				  DAT_EVD_HANDLE,	/* evd_handle */
-				  DAT_PSP_FLAGS,	/* psp_flags */
-				  DAT_PSP_HANDLE *);	/* psp_handle */
-
-extern DAT_RETURN dapl_psp_create_any(DAT_IA_HANDLE,	/* ia_handle */
-				      DAT_CONN_QUAL *,	/* conn_qual */
-				      DAT_EVD_HANDLE,	/* evd_handle */
-				      DAT_PSP_FLAGS,	/* psp_flags */
-				      DAT_PSP_HANDLE *);	/* psp_handle */
+extern u32 dapl_psp_create(DAT_IA_HANDLE ia_handle, DAT_CONN_QUAL conn_qual,
+			   DAT_EVD_HANDLE evd_handle, DAT_PSP_FLAGS psp_flags,
+			   DAT_PSP_HANDLE *psp_handle);
+
+extern u32 dapl_psp_create_any(DAT_IA_HANDLE ia_handle,
+			       DAT_CONN_QUAL *conn_qual,
+			       DAT_EVD_HANDLE evd_handle,
+			       DAT_PSP_FLAGS psp_flags,
+			       DAT_PSP_HANDLE *psp_handle);
 
-extern DAT_RETURN dapl_psp_query(DAT_PSP_HANDLE, struct dat_psp_param *);
+extern u32 dapl_psp_query(DAT_PSP_HANDLE, struct dat_psp_param *);
 
-extern DAT_RETURN dapl_psp_free(DAT_PSP_HANDLE);	/* psp_handle */
+extern u32 dapl_psp_free(DAT_PSP_HANDLE psp_handle);
 
 /* RSP Functions */
 
-extern DAT_RETURN dapl_rsp_create(DAT_IA_HANDLE,	/* ia_handle */
-				  DAT_CONN_QUAL,	/* conn_qual */
-				  DAT_EP_HANDLE,	/* ep_handle */
-				  DAT_EVD_HANDLE,	/* evd_handle */
-				  DAT_RSP_HANDLE *);	/* rsp_handle */
+extern u32 dapl_rsp_create(DAT_IA_HANDLE ia_handle, DAT_CONN_QUAL conn_qual,
+			   DAT_EP_HANDLE ep_handle, DAT_EVD_HANDLE evd_handle,
+			   DAT_RSP_HANDLE *rsp_handle);
 
-extern DAT_RETURN dapl_rsp_query(DAT_RSP_HANDLE, struct dat_rsp_param *);
+extern u32 dapl_rsp_query(DAT_RSP_HANDLE, struct dat_rsp_param *);
 
-extern DAT_RETURN dapl_rsp_free(DAT_RSP_HANDLE);	/* rsp_handle */
+extern u32 dapl_rsp_free(DAT_RSP_HANDLE rsp_handle);
 
 /* PZ Functions */
 
-extern DAT_RETURN dapl_pz_create(DAT_IA_HANDLE,	/* ia_handle */
-				 DAT_PZ_HANDLE *);	/* pz_handle */
+extern u32 dapl_pz_create(DAT_IA_HANDLE ia_handle, DAT_PZ_HANDLE *pz_handle);
 
-extern DAT_RETURN dapl_pz_query(DAT_PZ_HANDLE,	/* pz_handle */
-				struct dat_pz_param *);	/* pz_args */
+extern u32 dapl_pz_query(DAT_PZ_HANDLE pz_handle, struct dat_pz_param *pz_args);
 
-extern DAT_RETURN dapl_pz_free(DAT_PZ_HANDLE);	/* pz_handle */
+extern u32 dapl_pz_free(DAT_PZ_HANDLE pz_handle);
 
 /* SRQ functions */
 
-extern DAT_RETURN dapl_srq_create(DAT_IA_HANDLE,	/* ia_handle            */
-				  DAT_PZ_HANDLE,	/* pz_handle            */
-				  struct dat_srq_attr *,	/* srq_attr             */
-				  DAT_SRQ_HANDLE *);	/* srq_handle           */
-
-extern DAT_RETURN dapl_srq_free(DAT_SRQ_HANDLE);	/* srq_handle           */
-
-extern DAT_RETURN dapl_srq_post_recv(DAT_SRQ_HANDLE,	/* srq_handle           */
-				     DAT_COUNT,	/* num_segments         */
-				     struct dat_lmr_triplet *,	/* local_iov            */
-				     DAT_DTO_COOKIE);	/* user_cookie          */
+extern u32 dapl_srq_create(DAT_IA_HANDLE ia_handle, DAT_PZ_HANDLE pz_handle,
+			   struct dat_srq_attr *srq_attr,
+			   DAT_SRQ_HANDLE *srq_handle);
+
+extern u32 dapl_srq_free(DAT_SRQ_HANDLE srq_handle);
+
+extern u32 dapl_srq_post_recv(DAT_SRQ_HANDLE srq_handle, DAT_COUNT num_segments,
+			      struct dat_lmr_triplet *local_iov,
+			      DAT_DTO_COOKIE user_cookie);
 
-extern DAT_RETURN dapl_srq_query(DAT_SRQ_HANDLE,	/* srq_handle           */
-				 struct dat_srq_param *);	/* srq_param            */
+extern u32 dapl_srq_query(DAT_SRQ_HANDLE srq_handle,
+			  struct dat_srq_param *srq_param);
 
-extern DAT_RETURN dapl_srq_resize(DAT_SRQ_HANDLE,	/* srq_handle           */
-				  DAT_COUNT);	/* srq_max_recv_dto     */
+extern u32 dapl_srq_resize(DAT_SRQ_HANDLE srq_handle,
+			   DAT_COUNT srq_max_recv_dto);
 
-extern DAT_RETURN dapl_srq_set_lw(DAT_SRQ_HANDLE,	/* srq_handle           */
-				  DAT_COUNT);	/* low_watermark        */
+extern u32 dapl_srq_set_lw(DAT_SRQ_HANDLE srq_handle, DAT_COUNT low_watermark);
 
 /*
  * DAPL internal utility function prototpyes
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_hash.c linux-kernel2/dat-provider/dapl_hash.c
--- linux-kernel/dat-provider/dapl_hash.c	2005-05-11 08:28:12.964000000 -0700
+++ linux-kernel2/dat-provider/dapl_hash.c	2005-05-11 13:24:53.952031000 -0700
@@ -320,15 +320,14 @@ dapl_hash_delete_element(DAPL_HASH_ELEM 
 /*
  * Create a new hash table with at least 'table_size' hash buckets.
  */
-DAT_RETURN dapl_hash_create(DAT_COUNT table_size, DAPL_HASH_TABLE ** pp_table)
+u32 dapl_hash_create(DAT_COUNT table_size, DAPL_HASH_TABLE **pp_table)
 {
 	DAPL_HASH_TABLE *p_table;
 	DAT_COUNT table_length = table_size * sizeof(DAPL_HASH_ELEM);
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	DAT_COUNT i;
 
 	dapl_os_assert(pp_table);
-	dat_status = DAT_SUCCESS;
 
 	/* Allocate hash table */
 	p_table = kmalloc(sizeof(DAPL_HASH_TABLE), GFP_ATOMIC);
@@ -365,7 +364,7 @@ DAT_RETURN dapl_hash_create(DAT_COUNT ta
 /*
  * Destroy a hash table
  */
-DAT_RETURN dapl_hash_free(DAPL_HASH_TABLE * p_table)
+u32 dapl_hash_free(DAPL_HASH_TABLE *p_table)
 {
 	dapl_os_assert(p_table && p_table->table);
 
@@ -380,7 +379,7 @@ DAT_RETURN dapl_hash_free(DAPL_HASH_TABL
  * Returns the number of elements stored in the table
  */
 
-DAT_RETURN dapl_hash_size(DAPL_HASH_TABLE * p_table, DAT_COUNT * p_size)
+u32 dapl_hash_size(DAPL_HASH_TABLE *p_table, DAT_COUNT *p_size)
 {
 	dapl_os_assert(p_table && p_size);
 
@@ -394,14 +393,12 @@ DAT_RETURN dapl_hash_size(DAPL_HASH_TABL
  * Duplicates are not expected, and return in error, having done nothing.
  */
 
-DAT_RETURN
-dapl_hash_insert(DAPL_HASH_TABLE * p_table,
-		 DAPL_HASH_KEY key, DAPL_HASH_DATA data)
+u32 dapl_hash_insert(DAPL_HASH_TABLE *p_table, DAPL_HASH_KEY key,
+		     DAPL_HASH_DATA data)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_os_assert(p_table);
-	dat_status = DAT_SUCCESS;
 
 	spin_lock(&p_table->lock);
 	if (!dapl_hash_add(p_table, key, data, FALSE, NULL)) {
@@ -419,11 +416,10 @@ dapl_hash_insert(DAPL_HASH_TABLE * p_tab
  * data is returned in the DAPL_HASH_DATA 
  * pointer if that pointer is not NULL.
  */
-DAT_RETURN
-dapl_hash_search(DAPL_HASH_TABLE * p_table,
-		 DAPL_HASH_KEY key, DAPL_HASH_DATA * p_data)
+u32 dapl_hash_search(DAPL_HASH_TABLE *p_table, DAPL_HASH_KEY key,
+		     DAPL_HASH_DATA *p_data)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	void *olddatum;
 	DAPL_HASH_ELEM *found;
 
@@ -444,11 +440,10 @@ dapl_hash_search(DAPL_HASH_TABLE * p_tab
 	return dat_status;
 }
 
-DAT_RETURN
-dapl_hash_remove(DAPL_HASH_TABLE * p_table,
-		 DAPL_HASH_KEY key, DAPL_HASH_DATA * p_data)
+u32 dapl_hash_remove(DAPL_HASH_TABLE *p_table, DAPL_HASH_KEY key,
+		     DAPL_HASH_DATA *p_data)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	DAPL_HASH_KEY hashValue, save_key = key;
 
 	dapl_os_assert(p_table);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_hash.h linux-kernel2/dat-provider/dapl_hash.h
--- linux-kernel/dat-provider/dapl_hash.h	2005-04-20 12:42:08.701003000 -0700
+++ linux-kernel2/dat-provider/dapl_hash.h	2005-05-11 13:25:44.049020000 -0700
@@ -67,23 +67,19 @@
  *                                                                   *
  *********************************************************************/
 
-extern DAT_RETURN
-dapl_hash_create(DAT_COUNT capacity, DAPL_HASH_TABLE ** pp_table);
+extern u32 dapl_hash_create(DAT_COUNT capacity, DAPL_HASH_TABLE **pp_table);
 
-extern DAT_RETURN dapl_hash_free(DAPL_HASH_TABLE * p_table);
+extern u32 dapl_hash_free(DAPL_HASH_TABLE *p_table);
 
-extern DAT_RETURN dapl_hash_size(DAPL_HASH_TABLE * p_table, DAT_COUNT * p_size);
+extern u32 dapl_hash_size(DAPL_HASH_TABLE *p_table, DAT_COUNT *p_size);
 
-extern DAT_RETURN
-dapl_hash_insert(DAPL_HASH_TABLE * p_table,
-		 DAPL_HASH_KEY key, DAPL_HASH_DATA data);
+extern u32 dapl_hash_insert(DAPL_HASH_TABLE *p_table, DAPL_HASH_KEY key,
+			    DAPL_HASH_DATA data);
 
-extern DAT_RETURN
-dapl_hash_search(DAPL_HASH_TABLE * p_table,
-		 DAPL_HASH_KEY key, DAPL_HASH_DATA * p_data);
+extern u32 dapl_hash_search(DAPL_HASH_TABLE *p_table, DAPL_HASH_KEY key,
+			    DAPL_HASH_DATA *p_data);
 
-extern DAT_RETURN
-dapl_hash_remove(DAPL_HASH_TABLE * p_table,
-		 DAPL_HASH_KEY key, DAPL_HASH_DATA * p_data);
+extern u32 dapl_hash_remove(DAPL_HASH_TABLE *p_table, DAPL_HASH_KEY key,
+			    DAPL_HASH_DATA *p_data);
 
 #endif				/* DAPL_HASH_H */
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ia_close.c linux-kernel2/dat-provider/dapl_ia_close.c
--- linux-kernel/dat-provider/dapl_ia_close.c	2005-04-20 12:42:07.789026000 -0700
+++ linux-kernel2/dat-provider/dapl_ia_close.c	2005-05-11 11:16:06.367966000 -0700
@@ -57,10 +57,10 @@
  * 	DAT_INSUFFICIENT_RESOURCES
  * 	DAT_INVALID_PARAMETER
  */
-DAT_RETURN dapl_ia_close(DAT_IA_HANDLE ia_handle, DAT_CLOSE_FLAGS ia_flags)
+u32 dapl_ia_close(DAT_IA_HANDLE ia_handle, DAT_CLOSE_FLAGS ia_flags)
 {
 	DAPL_IA *ia_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_ia_close (%p, %d)\n", ia_handle, ia_flags);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ia_memtype_hint.c linux-kernel2/dat-provider/dapl_ia_memtype_hint.c
--- linux-kernel/dat-provider/dapl_ia_memtype_hint.c	2005-04-20 12:42:06.476020000 -0700
+++ linux-kernel2/dat-provider/dapl_ia_memtype_hint.c	2005-05-11 13:26:28.672013000 -0700
@@ -63,22 +63,18 @@
  * 	DAT_INVALID_HANDLE
  * 	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_ia_memtype_hint(DAT_IA_HANDLE ia_handle,
-		     DAT_MEM_TYPE mem_type,
-		     DAT_VLEN length,
-		     DAT_MEM_OPT mem_optimization,
-		     DAT_VLEN * suggested_length,
-		     DAT_VADDR * suggested_alignment)
+u32 dapl_ia_memtype_hint(DAT_IA_HANDLE ia_handle, DAT_MEM_TYPE mem_type,
+			 DAT_VLEN length, DAT_MEM_OPT mem_optimization,
+			 DAT_VLEN *suggested_length,
+			 DAT_VADDR *suggested_alignment)
 {
 	DAPL_IA *ia_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_ia_memtype_hint (%p)\n",
 		     ia_handle);
 
 	ia_ptr = (DAPL_IA *) ia_handle;
-	dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(ia_ptr, DAPL_MAGIC_IA)) {
 		dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ia_open.c linux-kernel2/dat-provider/dapl_ia_open.c
--- linux-kernel/dat-provider/dapl_ia_open.c	2005-05-11 11:08:04.435965000 -0700
+++ linux-kernel2/dat-provider/dapl_ia_open.c	2005-05-11 13:26:48.054000000 -0700
@@ -51,19 +51,16 @@
  * That function maps the DAT_NAME parameter of dat_ia_open to a DAT_PROVIDER,
  * and calls this function.
  */
-DAT_RETURN
-dapl_ia_open(const DAT_NAME_PTR name,
-	     DAT_COUNT async_evd_qlen,
-	     DAT_EVD_HANDLE * async_evd_handle_ptr,
-	     DAT_IA_HANDLE * ia_handle_ptr)
+u32 dapl_ia_open(const DAT_NAME_PTR name, DAT_COUNT async_evd_qlen,
+		 DAT_EVD_HANDLE *async_evd_handle_ptr,
+		 DAT_IA_HANDLE *ia_handle_ptr)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	struct dat_provider *provider;
 	DAPL_HCA *hca_ptr;
 	DAPL_IA *ia_ptr;
 	DAPL_EVD *evd_ptr;
 
-	dat_status = DAT_SUCCESS;
 	hca_ptr = NULL;
 	ia_ptr = NULL;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ia_query.c linux-kernel2/dat-provider/dapl_ia_query.c
--- linux-kernel/dat-provider/dapl_ia_query.c	2005-05-11 08:28:11.913022000 -0700
+++ linux-kernel2/dat-provider/dapl_ia_query.c	2005-05-11 13:27:31.889018000 -0700
@@ -59,14 +59,12 @@
  * 	DAT_SUCCESS
  * 	DAT_INVALID_PARAMETER
  */
-DAT_RETURN
-dapl_ia_query(DAT_IA_HANDLE ia_handle,
-	      DAT_EVD_HANDLE * async_evd_handle,
-	      struct dat_ia_attr *ia_attr,
-	      struct dat_provider_attr *provider_attr)
+u32 dapl_ia_query(DAT_IA_HANDLE ia_handle, DAT_EVD_HANDLE *async_evd_handle,
+		  struct dat_ia_attr *ia_attr,
+		  struct dat_provider_attr *provider_attr)
 {
 	DAPL_IA *ia_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	struct evd_merge_type {
 		boolean_t array[6][6];
 	} *evd_merge;
@@ -82,7 +80,6 @@ dapl_ia_query(DAT_IA_HANDLE ia_handle,
                      provider_attr);
 
 	ia_ptr = (DAPL_IA *) ia_handle;
-	dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(ia_ptr, DAPL_MAGIC_IA)) {
 		dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ia_util.c linux-kernel2/dat-provider/dapl_ia_util.c
--- linux-kernel/dat-provider/dapl_ia_util.c	2005-05-11 11:08:04.416964000 -0700
+++ linux-kernel2/dat-provider/dapl_ia_util.c	2005-05-11 13:28:41.996001000 -0700
@@ -107,9 +107,9 @@ DAPL_IA *dapl_ia_alloc(struct dat_provid
  * Performs an abrupt close of the IA
  */
 
-DAT_RETURN dapl_ia_abrupt_close(DAPL_IA * ia_ptr)
+u32 dapl_ia_abrupt_close(DAPL_IA *ia_ptr)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	DAPL_EP *ep_ptr, *next_ep_ptr;
 	DAPL_LMR *lmr_ptr, *next_lmr_ptr;
 	DAPL_RMR *rmr_ptr, *next_rmr_ptr;
@@ -119,8 +119,6 @@ DAT_RETURN dapl_ia_abrupt_close(DAPL_IA 
 	DAPL_CR *cr_ptr, *next_cr_ptr;
 	DAPL_HCA *hca_ptr;
 
-	dat_status = DAT_SUCCESS;
-
 	/*
 	 * clear all the data structures associated with the IA.
 	 * this must be done in order (rmr,rsp) before (ep lmr psp) before
@@ -351,16 +349,14 @@ DAT_RETURN dapl_ia_abrupt_close(DAPL_IA 
  *
  */
 
-DAT_RETURN dapl_ia_graceful_close(DAPL_IA * ia_ptr)
+u32 dapl_ia_graceful_close(DAPL_IA *ia_ptr)
 {
-	DAT_RETURN dat_status;
-	DAT_RETURN cur_dat_status;
+	u32 dat_status = DAT_SUCCESS;
+	u32 cur_dat_status;
 	DAPL_EVD *evd_ptr;
 	DAPL_LLIST_ENTRY *entry;
 	DAPL_HCA *hca_ptr;
 
-	dat_status = DAT_SUCCESS;
-
 	if (!dapl_llist_is_empty(&ia_ptr->rmr_list_head) ||
 	    !dapl_llist_is_empty(&ia_ptr->rsp_list_head) ||
 	    !dapl_llist_is_empty(&ia_ptr->ep_list_head) ||
@@ -710,9 +706,9 @@ void dapl_ia_link_rsp(DAPL_IA * ia_ptr, 
 	spin_unlock(&ia_ptr->header.lock);
 }
 
-DAT_RETURN dapl_ia_setup_callbacks(DAPL_IA * ia_ptr, DAPL_EVD * async_evd_ptr)
+u32 dapl_ia_setup_callbacks(DAPL_IA * ia_ptr, DAPL_EVD * async_evd_ptr)
 {
-	DAT_RETURN dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	/* unaffiliated handler */
 	dat_status =
@@ -733,9 +729,9 @@ DAT_RETURN dapl_ia_setup_callbacks(DAPL_
 	return dat_status;
 }
 
-DAT_RETURN dapl_ia_teardown_callbacks(DAPL_IA * ia_ptr)
+u32 dapl_ia_teardown_callbacks(DAPL_IA * ia_ptr)
 {
-	DAT_RETURN dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	/* unaffiliated handler */
 	dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ia_util.h linux-kernel2/dat-provider/dapl_ia_util.h
--- linux-kernel/dat-provider/dapl_ia_util.h	2005-05-11 08:28:12.246007000 -0700
+++ linux-kernel2/dat-provider/dapl_ia_util.h	2005-05-11 13:29:00.006004000 -0700
@@ -41,9 +41,9 @@
 
 DAPL_IA *dapl_ia_alloc(struct dat_provider *provider, DAPL_HCA * hca_ptr);
 
-DAT_RETURN dapl_ia_abrupt_close(DAPL_IA * ia_ptr);
+u32 dapl_ia_abrupt_close(DAPL_IA *ia_ptr);
 
-DAT_RETURN dapl_ia_graceful_close(DAPL_IA * ia_ptr);
+u32 dapl_ia_graceful_close(DAPL_IA *ia_ptr);
 
 void dapl_ia_free(DAPL_IA * ia_ptr);
 
@@ -80,8 +80,8 @@ void dapl_ia_link_rsp(DAPL_IA * ia_ptr, 
 DAPL_SP *dapl_ia_sp_search(DAPL_IA * ia_ptr,
 			   DAT_CONN_QUAL conn_qual, boolean_t is_psp);
 
-DAT_RETURN dapl_ia_setup_callbacks(DAPL_IA * ia_ptr, DAPL_EVD * async_evd_ptr);
+u32 dapl_ia_setup_callbacks(DAPL_IA *ia_ptr, DAPL_EVD *async_evd_ptr);
 
-DAT_RETURN dapl_ia_teardown_callbacks(DAPL_IA * ia_ptr);
+u32 dapl_ia_teardown_callbacks(DAPL_IA *ia_ptr);
 
 #endif
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_lmr_free.c linux-kernel2/dat-provider/dapl_lmr_free.c
--- linux-kernel/dat-provider/dapl_lmr_free.c	2005-04-27 11:38:35.485003000 -0700
+++ linux-kernel2/dat-provider/dapl_lmr_free.c	2005-05-11 11:16:06.394963000 -0700
@@ -57,10 +57,10 @@
  * 	DAT_INVALID_STATE 
  */
 
-DAT_RETURN dapl_lmr_free(DAT_LMR_HANDLE lmr_handle)
+u32 dapl_lmr_free(DAT_LMR_HANDLE lmr_handle)
 {
 	DAPL_LMR *lmr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_lmr_free (%p)\n", lmr_handle);
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_lmr_kcreate.c linux-kernel2/dat-provider/dapl_lmr_kcreate.c
--- linux-kernel/dat-provider/dapl_lmr_kcreate.c	2005-05-06 16:16:19.180012000 -0700
+++ linux-kernel2/dat-provider/dapl_lmr_kcreate.c	2005-05-11 13:37:00.876008000 -0700
@@ -37,71 +37,20 @@
 #include "dapl_lmr_util.h"
 #include "dapl_adapter_util.h"
 
-/*********************************************************************
- *                                                                   *
- * Function Prototypes                                               *
- *                                                                   *
- *********************************************************************/
-
-static __inline__ DAT_RETURN
-dapl_lmr_create_virtual(DAPL_IA * ia,
-			DAT_PVOID virt_addr,
-			DAT_VLEN length,
-			DAPL_PZ * pz,
-			DAT_MEM_PRIV_FLAGS privileges,
-			DAT_LMR_HANDLE * lmr_handle,
-			DAT_LMR_CONTEXT * lmr_context,
-			DAT_RMR_CONTEXT * rmr_context,
-			DAT_VLEN * registered_length,
-			DAT_VADDR * registered_address);
-
-static __inline__ DAT_RETURN
-dapl_lmr_create_physical(DAPL_IA * ia,
-			 DAT_REGION_DESCRIPTION phys_addr,
-			 DAT_VLEN length,
-			 DAPL_PZ * pz,
-			 DAT_MEM_PRIV_FLAGS privileges,
-			 DAT_LMR_HANDLE * lmr_handle,
-			 DAT_LMR_CONTEXT * lmr_context,
-			 DAT_RMR_CONTEXT * rmr_context,
-			 DAT_VLEN * registered_length,
-			 DAT_VADDR * registered_address);
-
-static __inline__ DAT_RETURN
-dapl_lmr_create_lmr(DAPL_IA * ia,
-		    DAPL_LMR * original_lmr,
-		    DAPL_PZ * pz,
-		    DAT_MEM_PRIV_FLAGS privileges,
-		    DAT_LMR_HANDLE * lmr_handle,
-		    DAT_LMR_CONTEXT * lmr_context,
-		    DAT_RMR_CONTEXT * rmr_context,
-		    DAT_VLEN * registered_length,
-		    DAT_VADDR * registered_address);
-
-/*********************************************************************
- *                                                                   *
- * Function Definitions                                              *
- *                                                                   *
- *********************************************************************/
-
-DAT_RETURN
-dapl_lmr_create_virtual(DAPL_IA * ia,
-			DAT_PVOID virt_addr,
-			DAT_VLEN length,
-			DAPL_PZ * pz,
-			DAT_MEM_PRIV_FLAGS privileges,
-			DAT_LMR_HANDLE * lmr_handle,
-			DAT_LMR_CONTEXT * lmr_context,
-			DAT_RMR_CONTEXT * rmr_context,
-			DAT_VLEN * registered_length,
-			DAT_VADDR * registered_address)
+static inline u32 dapl_lmr_create_virtual(DAPL_IA *ia, DAT_PVOID virt_addr,
+					  DAT_VLEN length, DAPL_PZ *pz,
+					  DAT_MEM_PRIV_FLAGS privileges,
+					  DAT_LMR_HANDLE *lmr_handle,
+					  DAT_LMR_CONTEXT *lmr_context,
+					  DAT_RMR_CONTEXT *rmr_context,
+					  DAT_VLEN *registered_length,
+					  DAT_VADDR *registered_address)
 {
 	DAPL_LMR *lmr;
 	DAT_REGION_DESCRIPTION reg_desc;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	reg_desc.for_va = virt_addr;
-	dat_status = DAT_SUCCESS;
 
 	lmr = dapl_lmr_alloc(ia,
 			     DAT_MEM_TYPE_VIRTUAL,
@@ -170,25 +119,21 @@ dapl_lmr_create_virtual(DAPL_IA * ia,
 
 }
 
-DAT_RETURN
-dapl_lmr_create_physical(DAPL_IA * ia,
-			 DAT_REGION_DESCRIPTION phys_addr,
-			 DAT_VLEN page_count,
-			 DAPL_PZ * pz,
-			 DAT_MEM_PRIV_FLAGS privileges,
-			 DAT_LMR_HANDLE * lmr_handle,
-			 DAT_LMR_CONTEXT * lmr_context,
-			 DAT_RMR_CONTEXT * rmr_context,
-			 DAT_VLEN * registered_length,
-			 DAT_VADDR * registered_address)
+static inline u32 dapl_lmr_create_physical(DAPL_IA *ia,
+					   DAT_REGION_DESCRIPTION phys_addr,
+					   DAT_VLEN page_count, DAPL_PZ *pz,
+					   DAT_MEM_PRIV_FLAGS privileges,
+					   DAT_LMR_HANDLE *lmr_handle,
+					   DAT_LMR_CONTEXT *lmr_context,
+					   DAT_RMR_CONTEXT *rmr_context,
+					   DAT_VLEN *registered_length,
+					   DAT_VADDR *registered_address)
 {
 	DAPL_LMR *lmr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	u64 *array;
 	array = (u64 *) phys_addr.for_array;
 
-	dat_status = DAT_SUCCESS;
-
 	lmr = dapl_lmr_alloc(ia,
 			     DAT_MEM_TYPE_PHYSICAL,
 			     phys_addr,
@@ -258,20 +203,18 @@ dapl_lmr_create_physical(DAPL_IA * ia,
 	return dat_status;
 }
 
-DAT_RETURN
-dapl_lmr_create_lmr(DAPL_IA * ia,
-		    DAPL_LMR * original_lmr,
-		    DAPL_PZ * pz,
-		    DAT_MEM_PRIV_FLAGS privileges,
-		    DAT_LMR_HANDLE * lmr_handle,
-		    DAT_LMR_CONTEXT * lmr_context,
-		    DAT_RMR_CONTEXT * rmr_context,
-		    DAT_VLEN * registered_length,
-		    DAT_VADDR * registered_address)
+static inline u32 dapl_lmr_create_lmr(DAPL_IA *ia, DAPL_LMR *original_lmr,
+				      DAPL_PZ *pz,
+				      DAT_MEM_PRIV_FLAGS privileges,
+				      DAT_LMR_HANDLE *lmr_handle,
+				      DAT_LMR_CONTEXT *lmr_context,
+				      DAT_RMR_CONTEXT *rmr_context,
+				      DAT_VLEN *registered_length,
+				      DAT_VADDR *registered_address)
 {
 	DAPL_LMR *lmr;
 	DAT_REGION_DESCRIPTION reg_desc;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dat_status = dapl_hash_search(ia->hca_ptr->lmr_hash_table,
 				      original_lmr->param.lmr_context,
@@ -378,22 +321,15 @@ dapl_lmr_create_lmr(DAPL_IA * ia,
  * 	DAT_MODEL_NOT_SUPPORTED
  *
  */
-DAT_RETURN
-dapl_lmr_kcreate(DAT_IA_HANDLE ia_handle,
-		 DAT_MEM_TYPE mem_type,
-		 DAT_REGION_DESCRIPTION region_description,
-		 DAT_VLEN length,
-		 DAT_PZ_HANDLE pz_handle,
-		 DAT_MEM_PRIV_FLAGS privileges,
-		 DAT_MEM_OPT optimization,
-		 DAT_LMR_HANDLE * lmr_handle,
-		 DAT_LMR_CONTEXT * lmr_context,
-		 DAT_RMR_CONTEXT * rmr_context,
-		 DAT_VLEN * registered_length, DAT_VADDR * registered_address)
+u32 dapl_lmr_kcreate(DAT_IA_HANDLE ia_handle, DAT_MEM_TYPE mem_type,
+		     DAT_REGION_DESCRIPTION region_description, DAT_VLEN length,
+		     DAT_PZ_HANDLE pz_handle, DAT_MEM_PRIV_FLAGS privileges,
+		     DAT_MEM_OPT optimization, DAT_LMR_HANDLE *lmr_handle,
+		     DAT_LMR_CONTEXT *lmr_context, DAT_RMR_CONTEXT *rmr_context,		     DAT_VLEN *registered_length, DAT_VADDR *registered_address)
 {
 	DAPL_IA *ia;
 	DAPL_PZ *pz;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_lmr_kcreate(ia:%p, mem_type:%x, ...)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_lmr_query.c linux-kernel2/dat-provider/dapl_lmr_query.c
--- linux-kernel/dat-provider/dapl_lmr_query.c	2005-05-10 08:13:28.665004000 -0700
+++ linux-kernel2/dat-provider/dapl_lmr_query.c	2005-05-11 13:37:47.609016000 -0700
@@ -36,11 +36,10 @@
 
 #include "dapl.h"
 
-DAT_RETURN dapl_lmr_query(DAT_LMR_HANDLE lmr_handle,
-			  struct dat_lmr_param *lmr_param)
+u32 dapl_lmr_query(DAT_LMR_HANDLE lmr_handle, struct dat_lmr_param *lmr_param)
 {
 	DAPL_LMR *lmr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_lmr_query (%p, %p)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_lmr_sync_rdma_read.c linux-kernel2/dat-provider/dapl_lmr_sync_rdma_read.c
--- linux-kernel/dat-provider/dapl_lmr_sync_rdma_read.c	2005-05-10 08:13:28.304000000 -0700
+++ linux-kernel2/dat-provider/dapl_lmr_sync_rdma_read.c	2005-05-11 13:38:06.653039000 -0700
@@ -56,15 +56,12 @@
  * 	DAT_INVALID_HANDLE
  * 	DAT_INVALID_PARAMETER
  */
-DAT_RETURN
-dapl_lmr_sync_rdma_read(DAT_IA_HANDLE ia_handle,
-			const struct dat_lmr_triplet *local_segments,
-			DAT_VLEN num_segments)
+u32 dapl_lmr_sync_rdma_read(DAT_IA_HANDLE ia_handle,
+			    const struct dat_lmr_triplet *local_segments,
+			    DAT_VLEN num_segments)
 {
 	DAPL_IA *ia_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dat_lmr_sync_rdma_read (%p, %p, %ld)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_lmr_sync_rdma_write.c linux-kernel2/dat-provider/dapl_lmr_sync_rdma_write.c
--- linux-kernel/dat-provider/dapl_lmr_sync_rdma_write.c	2005-05-10 08:13:29.023025000 -0700
+++ linux-kernel2/dat-provider/dapl_lmr_sync_rdma_write.c	2005-05-11 13:38:29.184000000 -0700
@@ -41,15 +41,12 @@
  * Ensure a region of memory is consistent by locally flushing
  * non-coherent cache
  */
-DAT_RETURN
-dapl_lmr_sync_rdma_write(DAT_IA_HANDLE ia_handle,
-			 const struct dat_lmr_triplet *local_segments,
-			 DAT_VLEN num_segments)
+u32 dapl_lmr_sync_rdma_write(DAT_IA_HANDLE ia_handle,
+			     const struct dat_lmr_triplet *local_segments,
+			     DAT_VLEN num_segments)
 {
 	DAPL_IA *ia_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dat_lmr_sync_rdma_write (%p, %p, %ld)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_module.c linux-kernel2/dat-provider/dapl_module.c
--- linux-kernel/dat-provider/dapl_module.c	2005-05-11 11:08:04.396968000 -0700
+++ linux-kernel2/dat-provider/dapl_module.c	2005-05-11 11:16:06.423960000 -0700
@@ -58,7 +58,7 @@ static void dapl_unregister_providers(vo
  */
 static int __init dapl_init(void)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_UTIL, "DAPL: Started (dapl_init)\n");
 
@@ -96,7 +96,7 @@ module_init(dapl_init);
  */
 static void __exit dapl_fini(void)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_UTIL, "DAPL: Stopped (dapl_fini)\n");
 
@@ -121,7 +121,7 @@ void DAT_PROVIDER_INIT_FUNC_NAME(const s
 {
 	struct dat_provider *provider;
 	DAPL_HCA *hca_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	provider = NULL;
 	hca_ptr = NULL;
@@ -194,7 +194,7 @@ void DAT_PROVIDER_INIT_FUNC_NAME(const s
 void DAT_PROVIDER_FINI_FUNC_NAME(const struct dat_provider_info *provider_info)
 {
 	struct dat_provider *provider;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dat_status =
 	    dapl_provider_list_search(provider_info->ia_name, &provider);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_openib_cm.c linux-kernel2/dat-provider/dapl_openib_cm.c
--- linux-kernel/dat-provider/dapl_openib_cm.c	2005-05-11 10:09:59.074056000 -0700
+++ linux-kernel2/dat-provider/dapl_openib_cm.c	2005-05-11 13:40:22.442023000 -0700
@@ -397,10 +397,10 @@ error:
  *         DAT_INVALID_PARAMETER
  * 
  */
-DAT_RETURN dapl_ib_connect(DAT_EP_HANDLE ep_handle,
-			   DAT_IA_ADDRESS_PTR remote_ia_address,
-			   DAT_CONN_QUAL remote_conn_qual,
-			   DAT_COUNT private_data_size, DAT_PVOID private_data)
+u32 dapl_ib_connect(DAT_EP_HANDLE ep_handle,
+		    DAT_IA_ADDRESS_PTR remote_ia_address,
+		    DAT_CONN_QUAL remote_conn_qual,
+		    DAT_COUNT private_data_size, DAT_PVOID private_data)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_EP *ep_ptr;
@@ -489,7 +489,7 @@ DAT_RETURN dapl_ib_connect(DAT_EP_HANDLE
  *        DAT_INVALID_PARAMETER
  *
  */
-DAT_RETURN dapl_ib_disconnect(DAPL_EP * ep_ptr, DAT_CLOSE_FLAGS close_flags)
+u32 dapl_ib_disconnect(DAPL_EP *ep_ptr, DAT_CLOSE_FLAGS close_flags)
 {
 	struct dapl_cm_id *conn = ep_ptr->cm_handle;
 	int status;
@@ -622,9 +622,7 @@ void dapl_ib_reinit_ep(DAPL_EP * ep_ptr)
  *        DAT_INVALID_PARAMETER
  *
  */
-DAT_RETURN
-dapl_ib_setup_conn_listener(DAPL_IA * ia_ptr,
-			    u64 ServiceID, DAPL_SP * sp_ptr)
+u32 dapl_ib_setup_conn_listener(DAPL_IA *ia_ptr, u64 ServiceID, DAPL_SP *sp_ptr)
 {
 	int status;
 
@@ -667,7 +665,7 @@ dapl_ib_setup_conn_listener(DAPL_IA * ia
  *      DAT_INVALID_PARAMETER
  *
  */
-DAT_RETURN dapl_ib_remove_conn_listener(DAPL_IA * ia_ptr, DAPL_SP * sp_ptr)
+u32 dapl_ib_remove_conn_listener(DAPL_IA *ia_ptr, DAPL_SP *sp_ptr)
 {
 	//*** This will hang if called from CM thread context...
 	//*** Move back to using WQ...
@@ -695,8 +693,7 @@ DAT_RETURN dapl_ib_remove_conn_listener(
  *        DAT_INVALID_PARAMETER
  *
  */
-DAT_RETURN
-dapl_ib_reject_connection(struct dapl_cm_id *cm_handle, int reject_reason)
+u32 dapl_ib_reject_connection(struct dapl_cm_id *cm_handle, int reject_reason)
 {
 	int status;
 
@@ -738,15 +735,14 @@ dapl_ib_reject_connection(struct dapl_cm
  *        DAT_INVALID_PARAMETER
  *
  */
-DAT_RETURN dapl_ib_accept_connection(DAT_CR_HANDLE cr_handle,
-				     DAT_EP_HANDLE ep_handle,
-				     DAT_COUNT private_data_size,
-				     const DAT_PVOID prd_ptr)
+u32 dapl_ib_accept_connection(DAT_CR_HANDLE cr_handle, DAT_EP_HANDLE ep_handle,
+			      DAT_COUNT private_data_size,
+			      const DAT_PVOID prd_ptr)
 {
 	DAPL_CR *cr_ptr;
 	DAPL_EP *ep_ptr;
 	DAPL_IA *ia_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	int status;
 	struct ib_cm_rep_param passive_params;
 	struct dapl_cm_id *conn;
@@ -842,8 +838,8 @@ static int ib_cm_get_remote_gid(struct d
  *	DAT_INVALID_PARAMETER
  *
  */
-DAT_RETURN dapl_ib_cm_remote_addr(DAT_HANDLE dat_handle,
-				  struct sockaddr_in6 *remote_ia_address)
+u32 dapl_ib_cm_remote_addr(DAT_HANDLE dat_handle,
+			   struct sockaddr_in6 *remote_ia_address)
 {
 	DAPL_IA *ia_ptr;
 	int rc;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_openib_dto.h linux-kernel2/dat-provider/dapl_openib_dto.h
--- linux-kernel/dat-provider/dapl_openib_dto.h	2005-05-10 08:13:28.379014000 -0700
+++ linux-kernel2/dat-provider/dapl_openib_dto.h	2005-05-11 13:41:39.620043000 -0700
@@ -50,10 +50,9 @@
  *
  * Provider specific Post RECV function
  */
-static __inline__ DAT_RETURN
-dapl_ib_post_recv(DAPL_EP * ep_ptr,
-		  DAPL_COOKIE * cookie,
-		  DAT_COUNT num_segments, struct dat_lmr_triplet *local_iov)
+static __inline__ u32 dapl_ib_post_recv(DAPL_EP *ep_ptr, DAPL_COOKIE *cookie,
+					DAT_COUNT num_segments,
+					struct dat_lmr_triplet *local_iov)
 {
 	struct ib_recv_wr rr_desc = { NULL };
 	struct ib_recv_wr *rr_desc_fail;
@@ -100,14 +99,12 @@ dapl_ib_post_recv(DAPL_EP * ep_ptr,
  *
  * Provider specific Post SEND function
  */
-static __inline__ DAT_RETURN
-dapl_ib_post_send(DAPL_EP * ep_ptr,
-		  int op_type,
-		  DAPL_COOKIE * cookie,
-		  DAT_COUNT num_segments,
-		  struct dat_lmr_triplet *local_iov,
-		  const struct dat_rmr_triplet *remote_iov,
-		  DAT_COMPLETION_FLAGS completion_flags)
+static __inline__ u32 dapl_ib_post_send(DAPL_EP *ep_ptr, int op_type,
+					DAPL_COOKIE *cookie,
+					DAT_COUNT num_segments,
+					struct dat_lmr_triplet *local_iov,
+					const struct dat_rmr_triplet *remote_iov,
+					DAT_COMPLETION_FLAGS completion_flags)
 {
 	struct ib_send_wr send_desc = { NULL };
 	struct ib_send_wr *send_desc_fail;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_openib_qp.c linux-kernel2/dat-provider/dapl_openib_qp.c
--- linux-kernel/dat-provider/dapl_openib_qp.c	2005-05-10 08:13:28.894000000 -0700
+++ linux-kernel2/dat-provider/dapl_openib_qp.c	2005-05-11 13:42:06.454000000 -0700
@@ -67,8 +67,7 @@ ib_cq_handle_t dapl_get_dto_cq(DAPL_IA *
  *	  DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN
-dapl_ib_qp_alloc(DAPL_IA * ia_ptr, DAPL_EP * ep_ptr, DAPL_EP * ep_ctx_ptr)
+u32 dapl_ib_qp_alloc(DAPL_IA *ia_ptr, DAPL_EP *ep_ptr, DAPL_EP *ep_ctx_ptr)
 {
 	struct dat_ep_attr *attr;
 	int ib_status;
@@ -151,7 +150,7 @@ dapl_ib_qp_alloc(DAPL_IA * ia_ptr, DAPL_
  *	   Status of destroy operation.
  *
  */
-DAT_RETURN dapl_ib_qp_free(DAPL_IA * ia_ptr, DAPL_EP * ep_ptr)
+u32 dapl_ib_qp_free(DAPL_IA *ia_ptr, DAPL_EP *ep_ptr)
 {
 	int ib_status;
 
@@ -231,9 +230,8 @@ ib_cq_handle_t dapl_get_dto_cq(DAPL_IA *
  *	  DAT_INVALID_PARAMETER
  *
  */
-DAT_RETURN
-dapl_ib_qp_modify(DAPL_IA * ia_ptr, DAPL_EP * ep_ptr,
-		  struct dat_ep_attr *ep_attr)
+u32 dapl_ib_qp_modify(DAPL_IA *ia_ptr, DAPL_EP *ep_ptr,
+		      struct dat_ep_attr *ep_attr)
 {
 	struct ib_qp_attr qp_attr;
 	struct ib_qp *qp_handle;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_openib_util.c linux-kernel2/dat-provider/dapl_openib_util.c
--- linux-kernel/dat-provider/dapl_openib_util.c	2005-05-11 10:09:59.144000000 -0700
+++ linux-kernel2/dat-provider/dapl_openib_util.c	2005-05-11 13:48:41.352007000 -0700
@@ -47,9 +47,8 @@
 #include "dapl_vendor.h"
 #include "dapl_openib_cm.h"
 
-DAT_RETURN
-dapl_ib_get_hca_ids(ib_hca_handle_t hca,
-		    u8 port, union ib_gid * gid, u16 * lid);
+u32 dapl_ib_get_hca_ids(ib_hca_handle_t hca, u8 port, union ib_gid *gid,
+			u16 *lid);
 
 /*
  * Map all IB DTO completion codes to their DAT equivalent.
@@ -162,9 +161,9 @@ dapl_ib_convert_mem_privileges(DAT_MEM_P
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_ib_open_hca(char *name, DAPL_HCA * hca_ptr)
+u32 dapl_ib_open_hca(char *name, DAPL_HCA * hca_ptr)
 {
-	DAT_RETURN dat_ret;
+	u32 dat_ret;
 
 	memset(&hca_ptr->ib_trans.gid.global, 0, sizeof(union ib_gid));
 	hca_ptr->ib_trans.lid = 0;
@@ -199,7 +198,7 @@ DAT_RETURN dapl_ib_open_hca(char *name, 
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_ib_close_hca(DAPL_HCA * hca_ptr)
+u32 dapl_ib_close_hca(DAPL_HCA *hca_ptr)
 {
 	return DAT_SUCCESS;
 }
@@ -222,10 +221,8 @@ DAT_RETURN dapl_ib_close_hca(DAPL_HCA * 
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN
-dapl_ib_cq_alloc(DAPL_IA * ia_ptr,
-		 DAPL_EVD * evd_ptr,
-		 DAT_COUNT * cqlen, ib_comp_handle_t callback)
+u32 dapl_ib_cq_alloc(DAPL_IA *ia_ptr, DAPL_EVD *evd_ptr, DAT_COUNT *cqlen,
+		     ib_comp_handle_t callback)
 {
 	int ib_status;
 
@@ -258,7 +255,7 @@ dapl_ib_cq_alloc(DAPL_IA * ia_ptr,
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_ib_cq_free(DAPL_IA * ia_ptr, DAPL_EVD * evd_ptr)
+u32 dapl_ib_cq_free(DAPL_IA *ia_ptr, DAPL_EVD *evd_ptr)
 {
 	int ib_status;
 
@@ -266,8 +263,7 @@ DAT_RETURN dapl_ib_cq_free(DAPL_IA * ia_
 	return dapl_ib_status_convert(ib_status);
 }
 
-DAT_RETURN
-dapl_ib_cq_resize(DAPL_IA * ia_ptr, DAPL_EVD * evd_ptr, DAT_COUNT * cqlen)
+u32 dapl_ib_cq_resize(DAPL_IA *ia_ptr, DAPL_EVD *evd_ptr, DAT_COUNT *cqlen)
 {
 	int ib_status;
 
@@ -299,7 +295,7 @@ dapl_ib_cq_resize(DAPL_IA * ia_ptr, DAPL
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_set_cq_notify(DAPL_IA * ia_ptr, DAPL_EVD * evd_ptr)
+u32 dapl_set_cq_notify(DAPL_IA *ia_ptr, DAPL_EVD *evd_ptr)
 {
 	int ib_status;
 
@@ -324,7 +320,7 @@ DAT_RETURN dapl_set_cq_notify(DAPL_IA * 
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_ib_pd_alloc(DAPL_IA * ia, DAPL_PZ * pz)
+u32 dapl_ib_pd_alloc(DAPL_IA *ia, DAPL_PZ *pz)
 {
 	struct ib_pd *pd;
 	int ib_status;
@@ -359,7 +355,7 @@ DAT_RETURN dapl_ib_pd_alloc(DAPL_IA * ia
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_ib_pd_free(DAPL_PZ * pz)
+u32 dapl_ib_pd_free(DAPL_PZ *pz)
 {
 	int ib_status;
 
@@ -394,21 +390,16 @@ DAT_RETURN dapl_ib_pd_free(DAPL_PZ * pz)
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN
-dapl_ib_mr_register(DAPL_IA * ia,
-		    DAPL_LMR * lmr,
-		    DAT_PVOID virt_addr,
-		    DAT_VLEN length, DAT_MEM_PRIV_FLAGS privileges)
+u32 dapl_ib_mr_register(DAPL_IA *ia, DAPL_LMR *lmr, DAT_PVOID virt_addr,
+			DAT_VLEN length, DAT_MEM_PRIV_FLAGS privileges)
 {
 	/* ITBD virtual memory registration ??? */
 	return (DAT_SUCCESS);
 }
 
-DAT_RETURN dapl_ib_mr_register_physical(DAPL_IA * ia_ptr,
-					DAPL_LMR * lmr,
-					DAT_PVOID phys_addr,
-					DAT_VLEN length,
-					DAT_MEM_PRIV_FLAGS privileges)
+u32 dapl_ib_mr_register_physical(DAPL_IA *ia_ptr, DAPL_LMR *lmr,
+				 DAT_PVOID phys_addr, DAT_VLEN length,
+				 DAT_MEM_PRIV_FLAGS privileges)
 {
 	int ib_status;
 	int i;
@@ -481,7 +472,7 @@ DAT_RETURN dapl_ib_mr_register_physical(
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_ib_mr_deregister(DAPL_LMR * lmr)
+u32 dapl_ib_mr_deregister(DAPL_LMR *lmr)
 {
 	int ib_status;
 
@@ -515,7 +506,7 @@ DAT_RETURN dapl_ib_mr_deregister(DAPL_LM
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_ib_mw_alloc(DAPL_RMR * rmr)
+u32 dapl_ib_mw_alloc(DAPL_RMR *rmr)
 {
 	int ib_status;
 	struct ib_mw *mw;
@@ -552,7 +543,7 @@ DAT_RETURN dapl_ib_mw_alloc(DAPL_RMR * r
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_ib_mw_free(DAPL_RMR * rmr)
+u32 dapl_ib_mw_free(DAPL_RMR *rmr)
 {
 	int ib_status;
 
@@ -585,14 +576,10 @@ DAT_RETURN dapl_ib_mw_free(DAPL_RMR * rm
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN
-dapl_ib_mw_bind(DAPL_RMR * rmr,
-		DAPL_LMR * lmr,
-		DAPL_EP * ep,
-		DAPL_COOKIE * cookie,
-		DAT_VADDR virtual_address,
-		DAT_VLEN length,
-		DAT_MEM_PRIV_FLAGS mem_priv, boolean_t is_signaled)
+u32 dapl_ib_mw_bind(DAPL_RMR *rmr, DAPL_LMR *lmr, DAPL_EP *ep,
+		    DAPL_COOKIE *cookie, DAT_VADDR virtual_address,
+		    DAT_VLEN length, DAT_MEM_PRIV_FLAGS mem_priv,
+		    boolean_t is_signaled)
 {
 	int ib_status;
 	struct ib_mw_bind mw_bind_prop;
@@ -640,9 +627,8 @@ dapl_ib_mw_bind(DAPL_RMR * rmr,
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN
-dapl_ib_mw_unbind(DAPL_RMR * rmr,
-		  DAPL_EP * ep, DAPL_COOKIE * cookie, boolean_t is_signaled)
+u32 dapl_ib_mw_unbind(DAPL_RMR *rmr, DAPL_EP *ep, DAPL_COOKIE *cookie,
+		      boolean_t is_signaled)
 {
 	int ib_status;
 	struct ib_mw_bind mw_bind_prop;
@@ -688,10 +674,9 @@ dapl_ib_mw_unbind(DAPL_RMR * rmr,
  *	DAT_INVALID_PARAMETER
  *
  */
-DAT_RETURN
-dapl_ib_setup_async_callback(DAPL_IA * ia_ptr,
-			     DAPL_ASYNC_HANDLER_TYPE handler_type,
-			     ib_async_handler_t callback, void *context)
+u32 dapl_ib_setup_async_callback(DAPL_IA *ia_ptr,
+				 DAPL_ASYNC_HANDLER_TYPE handler_type,
+				 ib_async_handler_t callback, void *context)
 {
 	int ib_status = 0;
 
@@ -714,10 +699,8 @@ dapl_ib_setup_async_callback(DAPL_IA * i
  * 	DAT_SUCCESS
  *	DAT_INVALID_PARAMETER
  */
-DAT_RETURN dapl_ib_query_hca(DAPL_HCA * hca_ptr,
-			     struct dat_ia_attr *ia_attr,
-			     struct dat_ep_attr *ep_attr,
-			     struct sockaddr_in6 *ip_addr)
+u32 dapl_ib_query_hca(DAPL_HCA *hca_ptr, struct dat_ia_attr *ia_attr,
+		      struct dat_ep_attr *ep_attr, struct sockaddr_in6 *ip_addr)
 {
 	int ib_status;
 	struct ib_device_attr device_attr;
@@ -795,9 +778,8 @@ DAT_RETURN dapl_ib_query_hca(DAPL_HCA * 
 	return DAT_SUCCESS;
 }
 
-DAT_RETURN
-dapl_ib_completion_poll(DAPL_HCA * hca_ptr,
-			DAPL_EVD * evd_ptr, ib_work_completion_t * cqe_ptr)
+u32 dapl_ib_completion_poll(DAPL_HCA *hca_ptr, DAPL_EVD *evd_ptr,
+			    ib_work_completion_t *cqe_ptr)
 {
 	int ib_status;
 
@@ -805,12 +787,11 @@ dapl_ib_completion_poll(DAPL_HCA * hca_p
 	if (ib_status == 1)
 		return DAT_SUCCESS;
 	if (ib_status == 0)
-		return DAT_ERRORP(DAT_QUEUE_EMPTY, DAT_NO_SUBTYPE);
+		return DAT_ERROR(DAT_QUEUE_EMPTY, DAT_NO_SUBTYPE);
 	return dapl_ib_status_convert(ib_status);
 }
 
-DAT_RETURN
-dapl_ib_completion_notify(DAPL_EVD * evd_ptr, ib_notification_type_t type)
+u32 dapl_ib_completion_notify(DAPL_EVD *evd_ptr, ib_notification_type_t type)
 {
 	int ib_status;
 
@@ -877,14 +858,12 @@ DAT_DTO_COMPLETION_STATUS dapl_ib_get_dt
  *	DAT_NOT_IMPLEMENTED	Caller is not interested this event
  */
 
-DAT_RETURN
-dapl_ib_get_async_event(ib_error_record_t * cause_ptr,
-			DAT_EVENT_NUMBER * async_event)
+u32 dapl_ib_get_async_event(ib_error_record_t *cause_ptr,
+			    DAT_EVENT_NUMBER *async_event)
 {
 	ib_async_event_type event_id;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
-	dat_status = DAT_SUCCESS;
 	event_id = cause_ptr->event;
 
 	switch (event_id) {
@@ -921,8 +900,8 @@ dapl_ib_get_async_event(ib_error_record_
 	return dat_status;
 }
 
-DAT_RETURN
-dapl_ib_get_hca_ids(ib_hca_handle_t hca, u8 port, union ib_gid * gid, u16 * lid)
+u32 dapl_ib_get_hca_ids(ib_hca_handle_t hca, u8 port, union ib_gid *gid,
+			u16 *lid)
 {
 	int status;
 	struct ib_port_attr port_attr;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_openib_util.h linux-kernel2/dat-provider/dapl_openib_util.h
--- linux-kernel/dat-provider/dapl_openib_util.h	2005-05-11 10:09:59.163023000 -0700
+++ linux-kernel2/dat-provider/dapl_openib_util.h	2005-05-11 13:48:41.355003000 -0700
@@ -47,12 +47,7 @@
 void dapl_add_one(struct ib_device *device);
 void dapl_remove_one(struct ib_device *device);
 
-static __inline__ DAT_RETURN dapl_ib_status_convert(int32_t ib_status);
-
-/* A version of DAT_ERROR is redefined here as the order of include
- * files makes it unavailable at this point
- */
-#define DAT_ERRORP(Type, SubType) ((DAT_RETURN)(DAT_CLASS_ERROR | Type | SubType))
+static __inline__ u32 dapl_ib_status_convert(int32_t ib_status);
 
 /*
  * Typedefs to map OpenIB types to more generic 'ib' types
@@ -126,28 +121,28 @@ typedef struct ib_hca_transport {
  * Do not return invalid Handles, the user is not able
  * to deal with them.
  */
-static __inline__ DAT_RETURN dapl_ib_status_convert(int32_t ib_status)
+static __inline__ u32 dapl_ib_status_convert(int32_t ib_status)
 {
 	switch (ib_status) {
 	case 0:
 		return DAT_SUCCESS;
 	case -EAGAIN:
-		return DAT_ERRORP(DAT_QUEUE_EMPTY, DAT_NO_SUBTYPE);
+		return DAT_ERROR(DAT_QUEUE_EMPTY, DAT_NO_SUBTYPE);
 	case -EBUSY:
-		return DAT_ERRORP(DAT_INTERNAL_ERROR, DAT_NO_SUBTYPE);
+		return DAT_ERROR(DAT_INTERNAL_ERROR, DAT_NO_SUBTYPE);
 	case -ENOMEM:
-		return DAT_ERRORP(DAT_INSUFFICIENT_RESOURCES, DAT_NO_SUBTYPE);
+		return DAT_ERROR(DAT_INSUFFICIENT_RESOURCES, DAT_NO_SUBTYPE);
 	case -EINVAL:
-		return DAT_ERRORP(DAT_INVALID_HANDLE, DAT_NO_SUBTYPE);
+		return DAT_ERROR(DAT_INVALID_HANDLE, DAT_NO_SUBTYPE);
 		/*
 		 * Udapl only, not sure what will be the return value from the IB
 		 * case ??????:
-		 *      return DAT_ERRORP(DAT_TIMEOUT_EXPIRED, DAT_NO_SUBTYPE);
+		 *      return DAT_ERROR(DAT_TIMEOUT_EXPIRED, DAT_NO_SUBTYPE);
 		 */
 	case -EINTR:
-		return DAT_ERRORP(DAT_INTERRUPTED_CALL, DAT_NO_SUBTYPE);
+		return DAT_ERROR(DAT_INTERRUPTED_CALL, DAT_NO_SUBTYPE);
 	default:
-		return DAT_ERRORP(DAT_INTERNAL_ERROR, DAT_NO_SUBTYPE);
+		return DAT_ERROR(DAT_INTERNAL_ERROR, DAT_NO_SUBTYPE);
 	}
 }
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_provider.c linux-kernel2/dat-provider/dapl_provider.c
--- linux-kernel/dat-provider/dapl_provider.c	2005-05-11 08:28:12.130010000 -0700
+++ linux-kernel2/dat-provider/dapl_provider.c	2005-05-11 13:50:39.276005000 -0700
@@ -37,7 +37,7 @@
 
 #include "dapl_provider.h"
 
-extern DAT_RETURN dapl_not_implemented(void);
+extern u32 dapl_not_implemented(void);
 
 /*********************************************************************
  *                                                                   *
@@ -144,11 +144,9 @@ dapl_provider_list_key_cmp(const char *n
  *                                                                   *
  *********************************************************************/
 
-DAT_RETURN dapl_provider_list_create(void)
+u32 dapl_provider_list_create(void)
 {
-	DAT_RETURN status;
-
-	status = DAT_SUCCESS;
+	u32 status = DAT_SUCCESS;
 
 	/* create the head node */
 	g_dapl_provider_list.head =
@@ -192,7 +190,7 @@ DAT_RETURN dapl_provider_list_create(voi
 	return status;
 }
 
-DAT_RETURN dapl_provider_list_destroy(void)
+u32 dapl_provider_list_destroy(void)
 {
 	DAPL_PROVIDER_LIST_NODE *cur_node;
 
@@ -211,15 +209,12 @@ DAT_COUNT dapl_provider_list_size(void)
 	return g_dapl_provider_list.size;
 }
 
-DAT_RETURN dapl_provider_list_insert(const char *name,
-				     struct dat_provider **p_data)
+u32 dapl_provider_list_insert(const char *name, struct dat_provider **p_data)
 {
 	DAPL_PROVIDER_LIST_NODE *cur_node, *prev_node, *next_node;
-	DAT_RETURN status;
+	u32 status = DAT_SUCCESS;
 	unsigned int len;
 
-	status = DAT_SUCCESS;
-
 	cur_node = kmalloc(sizeof(DAPL_PROVIDER_LIST_NODE), GFP_ATOMIC);
 
 	if (NULL == cur_node) {
@@ -266,13 +261,10 @@ DAT_RETURN dapl_provider_list_insert(con
 	return status;
 }
 
-DAT_RETURN dapl_provider_list_search(const char *name,
-				     struct dat_provider **p_data)
+u32 dapl_provider_list_search(const char *name, struct dat_provider **p_data)
 {
 	DAPL_PROVIDER_LIST_NODE *cur_node;
-	DAT_RETURN status;
-
-	status = DAT_ERROR(DAT_PROVIDER_NOT_FOUND, DAT_NAME_NOT_REGISTERED);
+	u32 status = DAT_ERROR(DAT_PROVIDER_NOT_FOUND, DAT_NAME_NOT_REGISTERED);
 
 	for (cur_node = g_dapl_provider_list.head->next;
 	     g_dapl_provider_list.tail != cur_node; cur_node = cur_node->next) {
@@ -290,12 +282,10 @@ DAT_RETURN dapl_provider_list_search(con
 	return status;
 }
 
-DAT_RETURN dapl_provider_list_remove(const char *name)
+u32 dapl_provider_list_remove(const char *name)
 {
 	DAPL_PROVIDER_LIST_NODE *cur_node, *prev_node, *next_node;
-	DAT_RETURN status;
-
-	status = DAT_ERROR(DAT_PROVIDER_NOT_FOUND, DAT_NAME_NOT_REGISTERED);
+	u32 status = DAT_ERROR(DAT_PROVIDER_NOT_FOUND, DAT_NAME_NOT_REGISTERED);
 
 	for (cur_node = g_dapl_provider_list.head->next;
 	     g_dapl_provider_list.tail != cur_node; cur_node = cur_node->next) {
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_provider.h linux-kernel2/dat-provider/dapl_provider.h
--- linux-kernel/dat-provider/dapl_provider.h	2005-05-09 11:07:01.934000000 -0700
+++ linux-kernel2/dat-provider/dapl_provider.h	2005-05-11 13:51:03.534001000 -0700
@@ -74,18 +74,18 @@ extern struct dat_provider g_dapl_provid
  *                                                                   *
  *********************************************************************/
 
-extern DAT_RETURN dapl_provider_list_create(void);
+extern u32 dapl_provider_list_create(void);
 
-extern DAT_RETURN dapl_provider_list_destroy(void);
+extern u32 dapl_provider_list_destroy(void);
 
 extern DAT_COUNT dapl_provider_list_size(void);
 
-extern DAT_RETURN
-dapl_provider_list_insert(const char *name, struct dat_provider **p_data);
+extern u32 dapl_provider_list_insert(const char *name,
+				     struct dat_provider **p_data);
 
-extern DAT_RETURN
-dapl_provider_list_search(const char *name, struct dat_provider **p_data);
+extern u32 dapl_provider_list_search(const char *name,
+				     struct dat_provider **p_data);
 
-extern DAT_RETURN dapl_provider_list_remove(const char *name);
+extern u32 dapl_provider_list_remove(const char *name);
 
 #endif				/* DAPL_PROVIDER_H */
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_psp_create_any.c linux-kernel2/dat-provider/dapl_psp_create_any.c
--- linux-kernel/dat-provider/dapl_psp_create_any.c	2005-05-11 08:28:11.754000000 -0700
+++ linux-kernel2/dat-provider/dapl_psp_create_any.c	2005-05-11 13:51:42.543040000 -0700
@@ -70,22 +70,19 @@
  * 	DAT_CONN_QUAL_IN_USE
  * 	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_psp_create_any(DAT_IA_HANDLE ia_handle,
-		    DAT_CONN_QUAL * conn_qual,
-		    DAT_EVD_HANDLE evd_handle,
-		    DAT_PSP_FLAGS psp_flags, DAT_PSP_HANDLE * psp_handle)
+u32 dapl_psp_create_any(DAT_IA_HANDLE ia_handle, DAT_CONN_QUAL *conn_qual,
+			DAT_EVD_HANDLE evd_handle, DAT_PSP_FLAGS psp_flags,
+			DAT_PSP_HANDLE *psp_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_SP *sp_ptr;
 	DAPL_EVD *evd_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	static DAT_CONN_QUAL hint_conn_qual = 1000;	/* seed value */
 	DAT_CONN_QUAL lcl_conn_qual;
 	DAT_CONN_QUAL limit_conn_qual;
 
 	ia_ptr = (DAPL_IA *) ia_handle;
-	dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(ia_ptr, DAPL_MAGIC_IA)) {
 		dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_psp_create.c linux-kernel2/dat-provider/dapl_psp_create.c
--- linux-kernel/dat-provider/dapl_psp_create.c	2005-05-11 08:28:11.632017000 -0700
+++ linux-kernel2/dat-provider/dapl_psp_create.c	2005-05-11 13:52:10.176006000 -0700
@@ -67,20 +67,17 @@
  * 	DAT_CONN_QUAL_IN_USE
  * 	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_psp_create(DAT_IA_HANDLE ia_handle,
-		DAT_CONN_QUAL conn_qual,
-		DAT_EVD_HANDLE evd_handle,
-		DAT_PSP_FLAGS psp_flags, DAT_PSP_HANDLE * psp_handle)
+u32 dapl_psp_create(DAT_IA_HANDLE ia_handle, DAT_CONN_QUAL conn_qual,
+		    DAT_EVD_HANDLE evd_handle, DAT_PSP_FLAGS psp_flags,
+		    DAT_PSP_HANDLE *psp_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_SP *sp_ptr;
 	DAPL_EVD *evd_ptr;
 	boolean_t sp_found;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	ia_ptr = (DAPL_IA *) ia_handle;
-	dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(ia_ptr, DAPL_MAGIC_IA)) {
 		dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_psp_free.c linux-kernel2/dat-provider/dapl_psp_free.c
--- linux-kernel/dat-provider/dapl_psp_free.c	2005-05-11 08:28:11.814001000 -0700
+++ linux-kernel2/dat-provider/dapl_psp_free.c	2005-05-11 13:52:46.992015000 -0700
@@ -58,15 +58,14 @@
  * 	DAT_SUCCESS
  * 	DAT_INVALID_PARAMETER
  */
-DAT_RETURN dapl_psp_free(DAT_PSP_HANDLE psp_handle)
+u32 dapl_psp_free(DAT_PSP_HANDLE psp_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_SP *sp_ptr;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	DAPL_SP_STATE save_state;
 
 	sp_ptr = (DAPL_SP *) psp_handle;
-	dat_status = DAT_SUCCESS;
 	/*
 	 * Verify handle
 	 */
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_psp_query.c linux-kernel2/dat-provider/dapl_psp_query.c
--- linux-kernel/dat-provider/dapl_psp_query.c	2005-05-11 08:28:13.131019000 -0700
+++ linux-kernel2/dat-provider/dapl_psp_query.c	2005-05-11 13:53:16.824005000 -0700
@@ -38,11 +38,10 @@
 
 #include "dapl.h"
 
-DAT_RETURN dapl_psp_query(DAT_PSP_HANDLE psp_handle,
-			  struct dat_psp_param *psp_param)
+u32 dapl_psp_query(DAT_PSP_HANDLE psp_handle, struct dat_psp_param *psp_param)
 {
 	DAPL_SP *sp_ptr;
-	DAT_RETURN status;
+	u32 status;
 
 	if (DAPL_BAD_HANDLE(psp_handle, DAPL_MAGIC_PSP) ||
 	    ((DAPL_SP *) psp_handle)->listening != TRUE) {
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_pz_create.c linux-kernel2/dat-provider/dapl_pz_create.c
--- linux-kernel/dat-provider/dapl_pz_create.c	2005-04-20 12:42:07.269030000 -0700
+++ linux-kernel2/dat-provider/dapl_pz_create.c	2005-05-11 13:53:40.203026000 -0700
@@ -55,16 +55,15 @@
  *      DAT_INVALID_PARAMETER
  *      DAT_INVLAID_HANDLE
  */
-DAT_RETURN dapl_pz_create(DAT_IA_HANDLE ia_handle, DAT_PZ_HANDLE * pz_handle)
+u32 dapl_pz_create(DAT_IA_HANDLE ia_handle, DAT_PZ_HANDLE *pz_handle)
 {
 	DAPL_IA *ia;
 	DAPL_PZ *pz;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_pz_create (%p, %p)\n", ia_handle, pz_handle);
 
-	dat_status = DAT_SUCCESS;
 	if (DAPL_BAD_HANDLE(ia_handle, DAPL_MAGIC_IA)) {
 		dat_status =
 		    DAT_ERROR(DAT_INVALID_HANDLE, DAT_INVALID_HANDLE_IA);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_pz_free.c linux-kernel2/dat-provider/dapl_pz_free.c
--- linux-kernel/dat-provider/dapl_pz_free.c	2005-04-27 11:38:35.840017000 -0700
+++ linux-kernel2/dat-provider/dapl_pz_free.c	2005-05-11 13:53:55.799011000 -0700
@@ -54,14 +54,13 @@
  * 	DAT_INVALID_STATE
  * 	DAT_INVALID_HANDLE
  */
-DAT_RETURN dapl_pz_free(DAT_PZ_HANDLE pz_handle)
+u32 dapl_pz_free(DAT_PZ_HANDLE pz_handle)
 {
 	DAPL_PZ *pz;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_pz_free (%p)\n", pz_handle);
 
-	dat_status = DAT_SUCCESS;
 	if (DAPL_BAD_HANDLE(pz_handle, DAPL_MAGIC_PZ)) {
 		dat_status =
 		    DAT_ERROR(DAT_INVALID_HANDLE, DAT_INVALID_HANDLE_PZ);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_pz_query.c linux-kernel2/dat-provider/dapl_pz_query.c
--- linux-kernel/dat-provider/dapl_pz_query.c	2005-05-10 08:13:28.647010000 -0700
+++ linux-kernel2/dat-provider/dapl_pz_query.c	2005-05-11 11:16:06.498965000 -0700
@@ -36,10 +36,10 @@
 
 #include "dapl.h"
 
-DAT_RETURN dapl_pz_query(DAT_PZ_HANDLE pz_handle, struct dat_pz_param *pz_param)
+u32 dapl_pz_query(DAT_PZ_HANDLE pz_handle, struct dat_pz_param *pz_param)
 {
 	DAPL_PZ *pz;
-	DAT_RETURN status;
+	u32 status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_pz_query (%p, %x, %p)\n", 
 		     pz_handle, pz_param);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ring_buffer_util.c linux-kernel2/dat-provider/dapl_ring_buffer_util.c
--- linux-kernel/dat-provider/dapl_ring_buffer_util.c	2005-04-27 11:38:34.816004000 -0700
+++ linux-kernel2/dat-provider/dapl_ring_buffer_util.c	2005-05-11 13:54:51.243023000 -0700
@@ -56,7 +56,7 @@
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_rbuf_alloc(DAPL_RING_BUFFER * rbuf, DAT_COUNT size)
+u32 dapl_rbuf_alloc(DAPL_RING_BUFFER *rbuf, DAT_COUNT size)
 {
 	unsigned int rsize;	/* real size */
 
@@ -104,13 +104,11 @@ DAT_RETURN dapl_rbuf_alloc(DAPL_RING_BUF
  *	DAT_INSUFFICIENT_RESOURCES
  *
  */
-DAT_RETURN dapl_rbuf_realloc(DAPL_RING_BUFFER * rbuf, DAT_COUNT size)
+u32 dapl_rbuf_realloc(DAPL_RING_BUFFER *rbuf, DAT_COUNT size)
 {
     DAPL_RING_BUFFER	new_rbuf;
     void 		*entry;
-    DAT_RETURN		dat_status;
-
-    dat_status = DAT_SUCCESS;
+    u32 dat_status = DAT_SUCCESS;
 
     /* decreasing the size or retaining the old size is not allowed */
     if (size <= rbuf->lim + 1)
@@ -191,7 +189,7 @@ void dapl_rbuf_destroy(DAPL_RING_BUFFER 
  *	DAT_INSUFFICIENT_RESOURCES         (queue full)
  *
  */
-DAT_RETURN dapl_rbuf_add(DAPL_RING_BUFFER * rbuf, void *entry)
+u32 dapl_rbuf_add(DAPL_RING_BUFFER *rbuf, void *entry)
 {
 	int pos;
 	int val;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_ring_buffer_util.h linux-kernel2/dat-provider/dapl_ring_buffer_util.h
--- linux-kernel/dat-provider/dapl_ring_buffer_util.h	2005-04-27 11:38:34.911019000 -0700
+++ linux-kernel2/dat-provider/dapl_ring_buffer_util.h	2005-05-11 13:55:12.302088000 -0700
@@ -42,13 +42,13 @@
 /*
  * Prototypes
  */
-DAT_RETURN dapl_rbuf_alloc(DAPL_RING_BUFFER * rbuf, DAT_COUNT size);
+u32 dapl_rbuf_alloc(DAPL_RING_BUFFER *rbuf, DAT_COUNT size);
 
-DAT_RETURN dapl_rbuf_realloc(DAPL_RING_BUFFER * rbuf, DAT_COUNT size);
+u32 dapl_rbuf_realloc(DAPL_RING_BUFFER *rbuf, DAT_COUNT size);
 
 void dapl_rbuf_destroy(DAPL_RING_BUFFER * rbuf);
 
-DAT_RETURN dapl_rbuf_add(DAPL_RING_BUFFER * rbuf, void *entry);
+u32 dapl_rbuf_add(DAPL_RING_BUFFER *rbuf, void *entry);
 
 void *dapl_rbuf_remove(DAPL_RING_BUFFER * rbuf);
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_rmr_bind.c linux-kernel2/dat-provider/dapl_rmr_bind.c
--- linux-kernel/dat-provider/dapl_rmr_bind.c	2005-05-11 10:09:59.093023000 -0700
+++ linux-kernel2/dat-provider/dapl_rmr_bind.c	2005-05-11 13:56:47.864000000 -0700
@@ -46,18 +46,17 @@
  *                                                                   *
  *********************************************************************/
 
-static inline DAT_RETURN 
-dapl_rmr_bind_fuse(DAPL_RMR * rmr,
-                   const struct dat_lmr_triplet *lmr_triplet,
-                   DAT_MEM_PRIV_FLAGS mem_priv,
-                   DAPL_EP * ep_ptr,
-                   DAT_RMR_COOKIE user_cookie,
-                   DAT_COMPLETION_FLAGS completion_flags,
-                   DAT_RMR_CONTEXT * rmr_context)
+static inline u32 dapl_rmr_bind_fuse(DAPL_RMR *rmr,
+				     const struct dat_lmr_triplet *lmr_triplet,
+				     DAT_MEM_PRIV_FLAGS mem_priv,
+				     DAPL_EP *ep_ptr,
+				     DAT_RMR_COOKIE user_cookie,
+				     DAT_COMPLETION_FLAGS completion_flags,
+				     DAT_RMR_CONTEXT *rmr_context)
 {
 	DAPL_LMR *lmr;
 	DAPL_COOKIE *cookie;
-	DAT_RETURN status;
+	u32 status;
 	boolean_t is_signaled;
 
 	status = dapl_hash_search(rmr->header.owner_ia->hca_ptr->lmr_hash_table,
@@ -157,17 +156,14 @@ dapl_rmr_bind_fuse(DAPL_RMR * rmr,
 	return status;
 }
 
-static inline DAT_RETURN 
-dapl_rmr_bind_unfuse(DAPL_RMR * rmr,
-                     DAPL_EP * ep_ptr,
-                     DAT_RMR_COOKIE user_cookie,
-                     DAT_COMPLETION_FLAGS completion_flags)
+static inline u32 dapl_rmr_bind_unfuse(DAPL_RMR *rmr, DAPL_EP *ep_ptr,
+				       DAT_RMR_COOKIE user_cookie,
+				       DAT_COMPLETION_FLAGS completion_flags)
 {
 	DAPL_COOKIE *cookie;
-	DAT_RETURN status;
+	u32 status = DAT_SUCCESS;
 	boolean_t is_signaled;
 
-	status = DAT_SUCCESS;
 	/*
 	 * if the ep in unconnected return an error. IB requires that the
 	 * QP be connected to change a memory window binding since:
@@ -253,13 +249,12 @@ dapl_rmr_bind_unfuse(DAPL_RMR * rmr,
  * Input:
  * Output:
  */
-DAT_RETURN dapl_rmr_bind(DAT_RMR_HANDLE rmr_handle,
-                         const struct dat_lmr_triplet *lmr_triplet,
-                         DAT_MEM_PRIV_FLAGS mem_priv,
-                         DAT_EP_HANDLE ep_handle,
-                         DAT_RMR_COOKIE user_cookie,
-                         DAT_COMPLETION_FLAGS completion_flags,
-                         DAT_RMR_CONTEXT * rmr_context)
+u32 dapl_rmr_bind(DAT_RMR_HANDLE rmr_handle,
+		  const struct dat_lmr_triplet *lmr_triplet,
+		  DAT_MEM_PRIV_FLAGS mem_priv, DAT_EP_HANDLE ep_handle,
+		  DAT_RMR_COOKIE user_cookie,
+		  DAT_COMPLETION_FLAGS completion_flags,
+		  DAT_RMR_CONTEXT *rmr_context)
 {
 	DAPL_RMR *rmr;
 	DAPL_EP *ep_ptr;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_rmr_create.c linux-kernel2/dat-provider/dapl_rmr_create.c
--- linux-kernel/dat-provider/dapl_rmr_create.c	2005-04-27 11:38:34.778010000 -0700
+++ linux-kernel2/dat-provider/dapl_rmr_create.c	2005-05-11 13:57:10.428101000 -0700
@@ -53,13 +53,11 @@
  * 	DAT_INSUFFICIENT_RESOURCES
  * 	DAT_INVALID_PARAMETER
  */
-DAT_RETURN dapl_rmr_create(DAT_PZ_HANDLE pz_handle, DAT_RMR_HANDLE * rmr_handle)
+u32 dapl_rmr_create(DAT_PZ_HANDLE pz_handle, DAT_RMR_HANDLE *rmr_handle)
 {
 	DAPL_PZ *pz;
 	DAPL_RMR *rmr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(pz_handle, DAPL_MAGIC_PZ)) {
 		dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_rmr_free.c linux-kernel2/dat-provider/dapl_rmr_free.c
--- linux-kernel/dat-provider/dapl_rmr_free.c	2005-04-27 11:38:35.027007000 -0700
+++ linux-kernel2/dat-provider/dapl_rmr_free.c	2005-05-11 13:57:34.719027000 -0700
@@ -53,12 +53,10 @@
  * 	DAT_SUCCESS
  * 	DAT_INVALID_PARAMETER
  */
-DAT_RETURN dapl_rmr_free(DAT_RMR_HANDLE rmr_handle)
+u32 dapl_rmr_free(DAT_RMR_HANDLE rmr_handle)
 {
 	DAPL_RMR *rmr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(rmr_handle, DAPL_MAGIC_RMR)) {
 		dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_rmr_query.c linux-kernel2/dat-provider/dapl_rmr_query.c
--- linux-kernel/dat-provider/dapl_rmr_query.c	2005-05-10 08:13:28.721018000 -0700
+++ linux-kernel2/dat-provider/dapl_rmr_query.c	2005-05-11 13:57:51.347004000 -0700
@@ -38,13 +38,10 @@
 
 #include "dapl.h"
 
-DAT_RETURN dapl_rmr_query(DAT_RMR_HANDLE rmr_handle,
-			  struct dat_rmr_param *rmr_param)
+u32 dapl_rmr_query(DAT_RMR_HANDLE rmr_handle, struct dat_rmr_param *rmr_param)
 {
 	DAPL_RMR *rmr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	if (DAPL_BAD_HANDLE(rmr_handle, DAPL_MAGIC_RMR)) {
 		dat_status =
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_rsp_create.c linux-kernel2/dat-provider/dapl_rsp_create.c
--- linux-kernel/dat-provider/dapl_rsp_create.c	2005-05-11 08:28:12.578010000 -0700
+++ linux-kernel2/dat-provider/dapl_rsp_create.c	2005-05-11 13:58:29.482113000 -0700
@@ -68,20 +68,17 @@
  *	DAT_INVALID_STATE
  *	DAT_CONN_QUAL_IN_USE
  */
-DAT_RETURN
-dapl_rsp_create(DAT_IA_HANDLE ia_handle,
-		DAT_CONN_QUAL conn_qual,
-		DAT_EP_HANDLE ep_handle,
-		DAT_EVD_HANDLE evd_handle, DAT_RSP_HANDLE * rsp_handle)
+u32 dapl_rsp_create(DAT_IA_HANDLE ia_handle, DAT_CONN_QUAL conn_qual,
+		    DAT_EP_HANDLE ep_handle, DAT_EVD_HANDLE evd_handle,
+		    DAT_RSP_HANDLE *rsp_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_SP *sp_ptr;
 	DAPL_EVD *evd_ptr;
 	DAPL_EP *ep_ptr;
 	boolean_t sp_found;
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 
-	dat_status = DAT_SUCCESS;
 	ia_ptr = (DAPL_IA *) ia_handle;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_CM,
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_rsp_free.c linux-kernel2/dat-provider/dapl_rsp_free.c
--- linux-kernel/dat-provider/dapl_rsp_free.c	2005-05-11 08:28:12.737008000 -0700
+++ linux-kernel2/dat-provider/dapl_rsp_free.c	2005-05-11 13:58:44.765006000 -0700
@@ -58,14 +58,12 @@
  *	DAT_SUCCESS
  *	DAT_INVALID_HANDLE
  */
-DAT_RETURN dapl_rsp_free(DAT_RSP_HANDLE rsp_handle)
+u32 dapl_rsp_free(DAT_RSP_HANDLE rsp_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_SP *sp_ptr;
 	DAPL_EP *ep_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	sp_ptr = (DAPL_SP *) rsp_handle;
 	/*
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_rsp_query.c linux-kernel2/dat-provider/dapl_rsp_query.c
--- linux-kernel/dat-provider/dapl_rsp_query.c	2005-05-10 08:13:29.299014000 -0700
+++ linux-kernel2/dat-provider/dapl_rsp_query.c	2005-05-11 13:58:53.725005000 -0700
@@ -38,11 +38,10 @@
 
 #include "dapl.h"
 
-DAT_RETURN dapl_rsp_query(DAT_RSP_HANDLE rsp_handle,
-			  struct dat_rsp_param *rsp_param)
+u32 dapl_rsp_query(DAT_RSP_HANDLE rsp_handle, struct dat_rsp_param *rsp_param)
 {
 	DAPL_SP *sp_ptr;
-	DAT_RETURN status;
+	u32 status;
 
 	if (DAPL_BAD_HANDLE(rsp_handle, DAPL_MAGIC_RSP)) {
 		status = DAT_ERROR(DAT_INVALID_HANDLE, DAT_INVALID_HANDLE_RSP);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_set_consumer_context.c linux-kernel2/dat-provider/dapl_set_consumer_context.c
--- linux-kernel/dat-provider/dapl_set_consumer_context.c	2005-04-20 12:42:07.233010000 -0700
+++ linux-kernel2/dat-provider/dapl_set_consumer_context.c	2005-05-11 13:59:07.265009000 -0700
@@ -56,13 +56,11 @@
  * 	DAT_SUCCESS
  * 	DAT_INVALID_HANDLE
  */
-DAT_RETURN dapl_set_consumer_context(DAT_HANDLE dat_handle, DAT_CONTEXT context)
+u32 dapl_set_consumer_context(DAT_HANDLE dat_handle, DAT_CONTEXT context)
 {
-	DAT_RETURN dat_status;
+	u32 dat_status = DAT_SUCCESS;
 	DAPL_HEADER *header;
 
-	dat_status = DAT_SUCCESS;
-
 	header = (DAPL_HEADER *) dat_handle;
 	if (((header) == NULL) ||
 	    ((unsigned long)(header) & 3) ||
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_srq_create.c linux-kernel2/dat-provider/dapl_srq_create.c
--- linux-kernel/dat-provider/dapl_srq_create.c	2005-05-10 08:13:28.397009000 -0700
+++ linux-kernel2/dat-provider/dapl_srq_create.c	2005-05-11 13:59:33.909018000 -0700
@@ -65,16 +65,12 @@
  *	?DAT_INVALID_ATTRIBUTE??
  *	DAT_MODEL_NOT_SUPPORTED
  */
-DAT_RETURN
-dapl_srq_create(DAT_IA_HANDLE ia_handle,
-		DAT_PZ_HANDLE pz_handle,
-		struct dat_srq_attr *srq_attr, DAT_SRQ_HANDLE * srq_handle)
+u32 dapl_srq_create(DAT_IA_HANDLE ia_handle, DAT_PZ_HANDLE pz_handle,
+		    struct dat_srq_attr *srq_attr, DAT_SRQ_HANDLE *srq_handle)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_SRQ *srq_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_srq_create (%p, %p, %p, %p)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_srq_free.c linux-kernel2/dat-provider/dapl_srq_free.c
--- linux-kernel/dat-provider/dapl_srq_free.c	2005-05-10 08:13:29.041072000 -0700
+++ linux-kernel2/dat-provider/dapl_srq_free.c	2005-05-11 13:59:46.496011000 -0700
@@ -59,14 +59,12 @@
  *	DAT_INVALID_PARAMETER
  *	DAT_INVALID_STATE
  */
-DAT_RETURN dapl_srq_free(DAT_SRQ_HANDLE srq_handle)
+u32 dapl_srq_free(DAT_SRQ_HANDLE srq_handle)
 {
 	DAPL_SRQ *srq_ptr;
 	DAPL_IA *ia_ptr;
 	struct dat_srq_param *param;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_srq_free (%p)\n", srq_handle);
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_srq_post_recv.c linux-kernel2/dat-provider/dapl_srq_post_recv.c
--- linux-kernel/dat-provider/dapl_srq_post_recv.c	2005-05-10 08:13:28.985006000 -0700
+++ linux-kernel2/dat-provider/dapl_srq_post_recv.c	2005-05-11 14:00:05.629017000 -0700
@@ -67,15 +67,13 @@
  * 	DAT_PROTECTION_VIOLATION
  * 	DAT_PROVILEGES_VIOLATION
  */
-DAT_RETURN
-dapl_srq_post_recv(DAT_SRQ_HANDLE srq_handle,
-		   DAT_COUNT num_segments,
-		   struct dat_lmr_triplet *local_iov,
-		   DAT_DTO_COOKIE user_cookie)
+u32 dapl_srq_post_recv(DAT_SRQ_HANDLE srq_handle, DAT_COUNT num_segments,
+		       struct dat_lmr_triplet *local_iov,
+		       DAT_DTO_COOKIE user_cookie)
 {
 	DAPL_SRQ *srq_ptr;
 	DAPL_COOKIE *cookie;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_srq_post_recv (%p, %d, %p, %P)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_srq_query.c linux-kernel2/dat-provider/dapl_srq_query.c
--- linux-kernel/dat-provider/dapl_srq_query.c	2005-05-10 08:13:28.434065000 -0700
+++ linux-kernel2/dat-provider/dapl_srq_query.c	2005-05-11 14:00:20.113028000 -0700
@@ -39,13 +39,10 @@
 
 #include "dapl.h"
 
-DAT_RETURN dapl_srq_query(DAT_SRQ_HANDLE srq_handle,
-			  struct dat_srq_param *srq_param)
+u32 dapl_srq_query(DAT_SRQ_HANDLE srq_handle, struct dat_srq_param *srq_param)
 {
 	DAPL_SRQ *srq_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API,
 		     "dapl_srq_query (%p, %x, %p)\n",
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_srq_resize.c linux-kernel2/dat-provider/dapl_srq_resize.c
--- linux-kernel/dat-provider/dapl_srq_resize.c	2005-04-20 12:42:06.684011000 -0700
+++ linux-kernel2/dat-provider/dapl_srq_resize.c	2005-05-11 14:00:32.574007000 -0700
@@ -63,14 +63,11 @@
  * 	DAT_INVALID_STATE
  */
 
-DAT_RETURN
-dapl_srq_resize(DAT_SRQ_HANDLE srq_handle, DAT_COUNT srq_max_recv_dto)
+u32 dapl_srq_resize(DAT_SRQ_HANDLE srq_handle, DAT_COUNT srq_max_recv_dto)
 {
 	DAPL_IA *ia_ptr;
 	DAPL_SRQ *srq_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_srq_resize (%p, %d)\n",
 		     srq_handle, srq_max_recv_dto);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_srq_set_lw.c linux-kernel2/dat-provider/dapl_srq_set_lw.c
--- linux-kernel/dat-provider/dapl_srq_set_lw.c	2005-04-20 12:42:07.855013000 -0700
+++ linux-kernel2/dat-provider/dapl_srq_set_lw.c	2005-05-11 14:00:43.964001000 -0700
@@ -63,12 +63,10 @@
  * 	DAT_MODEL_NOT_SUPPORTED
  */
 
-DAT_RETURN dapl_srq_set_lw(DAT_SRQ_HANDLE srq_handle, DAT_COUNT low_watermark)
+u32 dapl_srq_set_lw(DAT_SRQ_HANDLE srq_handle, DAT_COUNT low_watermark)
 {
 	DAPL_SRQ *srq_ptr;
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	dapl_dbg_log(DAPL_DBG_TYPE_API, "dapl_srq_set_lw (%p, %d)\n",
 		     srq_handle, low_watermark);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_timer_util.c linux-kernel2/dat-provider/dapl_timer_util.c
--- linux-kernel/dat-provider/dapl_timer_util.c	2005-05-11 08:28:12.521015000 -0700
+++ linux-kernel2/dat-provider/dapl_timer_util.c	2005-05-11 14:01:14.200017000 -0700
@@ -91,9 +91,8 @@ void dapl_timer_init(void)
  *	no return value
  *
  */
-DAT_RETURN
-dapl_timer_set(DAPL_OS_TIMER * timer,
-	       void (*func) (uintptr_t), void *data, DAPL_OS_TIMEVAL expires)
+u32 dapl_timer_set(DAPL_OS_TIMER *timer, void (*func) (uintptr_t),
+		   void *data, DAPL_OS_TIMEVAL expires)
 {
 	DAPL_OS_TIMER *list_ptr;
 	DAPL_OS_TIMEVAL cur_time;
@@ -240,7 +239,7 @@ void dapl_timer_thread(void *arg)
 {
 	DAPL_OS_TIMER *list_ptr;
 	DAPL_OS_TIMEVAL cur_time;
-	DAT_RETURN dat_status;
+	u32 dat_status;
 	DAPL_TIMER_HEAD *timer_head;
 
 	timer_head = arg;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_timer_util.h linux-kernel2/dat-provider/dapl_timer_util.h
--- linux-kernel/dat-provider/dapl_timer_util.h	2005-04-20 12:42:07.873010000 -0700
+++ linux-kernel2/dat-provider/dapl_timer_util.h	2005-05-11 14:01:34.201022000 -0700
@@ -37,8 +37,7 @@
 
 void dapl_timer_init(void);
 
-DAT_RETURN dapl_timer_set(DAPL_OS_TIMER * timer,
-			  void (*func) (uintptr_t),
-			  void *data, DAPL_OS_TIMEVAL expires);
+u32 dapl_timer_set(DAPL_OS_TIMER *timer, void (*func) (uintptr_t),
+		   void *data, DAPL_OS_TIMEVAL expires);
 
 void dapl_timer_cancel(DAPL_OS_TIMER * timer);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_util.c linux-kernel2/dat-provider/dapl_util.c
--- linux-kernel/dat-provider/dapl_util.c	2005-05-06 16:22:03.058010000 -0700
+++ linux-kernel2/dat-provider/dapl_util.c	2005-05-11 14:02:26.035004000 -0700
@@ -55,7 +55,7 @@
  *	DAT_SUCCESS
  */
 
-DAT_RETURN dapl_os_get_time(DAPL_OS_TIMEVAL * loc)
+u32 dapl_os_get_time(DAPL_OS_TIMEVAL *loc)
 {
 	struct timeval tv;
 
@@ -81,7 +81,7 @@ DAT_RETURN dapl_os_get_time(DAPL_OS_TIME
  *	DAT_SUCCESS
  *	DAT_INTERNAL_ERROR
  */
-DAT_RETURN dapl_os_wait_object_init(DAPL_OS_WAIT_OBJECT * wait_obj)
+u32 dapl_os_wait_object_init(DAPL_OS_WAIT_OBJECT *wait_obj)
 {
 	init_waitqueue_head(&wait_obj->wait_queue);
 
@@ -101,13 +101,10 @@ DAT_RETURN dapl_os_wait_object_init(DAPL
  *	DAT_TIMEOUT -- the specified time limit was reached.
  */
 
-DAT_RETURN
-dapl_os_wait_object_wait(DAPL_OS_WAIT_OBJECT * wait_obj,
-			 DAT_TIMEOUT timeout_val)
+u32 dapl_os_wait_object_wait(DAPL_OS_WAIT_OBJECT *wait_obj,
+			     DAT_TIMEOUT timeout_val)
 {
-	DAT_RETURN dat_status;
-
-	dat_status = DAT_SUCCESS;
+	u32 dat_status = DAT_SUCCESS;
 
 	if (DAT_TIMEOUT_INFINITE == timeout_val) {
 		interruptible_sleep_on(&wait_obj->wait_queue);
@@ -137,7 +134,7 @@ dapl_os_wait_object_wait(DAPL_OS_WAIT_OB
  *	DAT_SUCCESS
  *	DAT_INTERNAL_ERROR
  */
-DAT_RETURN dapl_os_wait_object_wakeup(DAPL_OS_WAIT_OBJECT * wait_obj)
+u32 dapl_os_wait_object_wakeup(DAPL_OS_WAIT_OBJECT *wait_obj)
 {
 	wake_up_interruptible(&wait_obj->wait_queue);
 
@@ -156,7 +153,7 @@ DAT_RETURN dapl_os_wait_object_wakeup(DA
  *	DAT_SUCCESS
  *	DAT_INTERNAL_ERROR
  */
-DAT_RETURN dapl_os_wait_object_destroy(DAPL_OS_WAIT_OBJECT * wait_obj)
+u32 dapl_os_wait_object_destroy(DAPL_OS_WAIT_OBJECT *wait_obj)
 {
 
 	return DAT_SUCCESS;
@@ -188,9 +185,8 @@ void dapl_thread_init(struct thread_draf
  * Returns:
  *	DAT_SUCCESS
  */
-DAT_RETURN
-dapl_os_thread_create(void (*func) (void *),
-		      void *data, DAPL_OS_THREAD * thread_id)
+u32 dapl_os_thread_create(void (*func) (void *), void *data,
+			  DAPL_OS_THREAD * thread_id)
 {
 	struct thread_draft *thread_draft;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/dat-provider/dapl_util.h linux-kernel2/dat-provider/dapl_util.h
--- linux-kernel/dat-provider/dapl_util.h	2005-05-06 16:22:03.118012000 -0700
+++ linux-kernel2/dat-provider/dapl_util.h	2005-05-11 14:03:17.730035000 -0700
@@ -125,9 +125,8 @@ dapl_os_atomic_assign(atomic_t * v, DAT_
  */
 typedef int DAPL_OS_THREAD;
 
-DAT_RETURN
-dapl_os_thread_create(void (*func) (void *),
-		      void *data, DAPL_OS_THREAD * thread_id);
+u32 dapl_os_thread_create(void (*func) (void *), void *data,
+			  DAPL_OS_THREAD *thread_id);
 
 /*
  * Wait Objects
@@ -144,15 +143,14 @@ typedef struct _dapl_os_wait_object_ {
 } DAPL_OS_WAIT_OBJECT;
 
 /* function prototypes */
-DAT_RETURN dapl_os_wait_object_init(DAPL_OS_WAIT_OBJECT * wait_obj);
+u32 dapl_os_wait_object_init(DAPL_OS_WAIT_OBJECT *wait_obj);
 
-DAT_RETURN
-dapl_os_wait_object_wait(DAPL_OS_WAIT_OBJECT * wait_obj,
-			 DAT_TIMEOUT timeout_val);
+u32 dapl_os_wait_object_wait(DAPL_OS_WAIT_OBJECT *wait_obj,
+			     DAT_TIMEOUT timeout_val);
 
-DAT_RETURN dapl_os_wait_object_wakeup(DAPL_OS_WAIT_OBJECT * wait_obj);
+u32 dapl_os_wait_object_wakeup(DAPL_OS_WAIT_OBJECT *wait_obj);
 
-DAT_RETURN dapl_os_wait_object_destroy(DAPL_OS_WAIT_OBJECT * wait_obj);
+u32 dapl_os_wait_object_destroy(DAPL_OS_WAIT_OBJECT *wait_obj);
 
 /*
  * Memory Functions
@@ -193,7 +191,7 @@ typedef struct dapl_timer_entry DAPL_OS_
 typedef unsigned long long int DAPL_OS_TICKS;
 
 /* timer function prototype */
-DAT_RETURN dapl_os_get_time(DAPL_OS_TIMEVAL *);
+u32 dapl_os_get_time(DAPL_OS_TIMEVAL *);
 
 /*
  * *printf format helpers. We use the C string constant concatenation
@@ -224,12 +222,11 @@ static __inline__ long dapl_os_strtol(co
 /*
  * OS inter module functions to obtain and release verbs list
  */
-DAT_RETURN dapl_os_get_verbs_vector(void **verbs_list,
-				    char *list_name, char *driver_name);
+u32 dapl_os_get_verbs_vector(void **verbs_list, char *list_name,
+			     char *driver_name);
 
-DAT_RETURN
-dapl_os_release_verbs_vector(void **verbs_list,
-			     char *list_name, char *driver_name);
+u32 dapl_os_release_verbs_vector(void **verbs_list, char *list_name,
+				 char *driver_name);
 
 /*
  * helper routines
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/include/dapl_proto.h linux-kernel2/test/dapltest/include/dapl_proto.h
--- linux-kernel/test/dapltest/include/dapl_proto.h	2005-05-11 08:52:07.424000000 -0700
+++ linux-kernel2/test/dapltest/include/dapl_proto.h	2005-05-11 11:16:06.658962000 -0700
@@ -523,7 +523,7 @@ boolean_t            DT_check_params (Pe
 void        	DT_Test_Error (void);
 
 /* dapl_util.c */
-const char      *DT_RetToString (DAT_RETURN ret_value);
+const char      *DT_RetToString (u32 ret_value);
 
 const char      *DT_TransferTypeToString (DT_Transfer_Type type);
 
@@ -640,7 +640,7 @@ void	    DT_mem_test (Params_t *params_p
 /* dapl_fft_queryinfo.c */
 int	    DT_queryinfo_basic (Params_t *params_ptr, FFT_Cmd_t *cmd,
 				FFT_query_enum object_to_query,
-				DAT_RETURN result_wanted);
+				u32 result_wanted);
 int	    DT_queryinfo_case0 (Params_t *params_ptr, FFT_Cmd_t *cmd);
 int	    DT_queryinfo_case1 (Params_t *params_ptr, FFT_Cmd_t *cmd);
 int	    DT_queryinfo_case2 (Params_t *params_ptr, FFT_Cmd_t *cmd);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/include/dapl_tdep.h linux-kernel2/test/dapltest/include/dapl_tdep.h
--- linux-kernel/test/dapltest/include/dapl_tdep.h	2005-05-10 08:13:26.796006000 -0700
+++ linux-kernel2/test/dapltest/include/dapl_tdep.h	2005-05-11 11:16:06.664963000 -0700
@@ -44,21 +44,21 @@ DT_Tdep_End ( void ) ;
 int
 DT_Tdep_Execute_Test ( Params_t *params_ptr ) ;
 
-DAT_RETURN
+u32
 DT_Tdep_evd_create (DAT_IA_HANDLE	ia_handle,
 		    DAT_COUNT		evd_min_qlen,
 		    DAT_CNO_HANDLE	cno_handle,
 		    DAT_EVD_FLAGS	evd_flags,
 		    DAT_EVD_HANDLE 	*evd_handle_ptr);
 
-DAT_RETURN
+u32
 DT_Tdep_evd_free (DAT_EVD_HANDLE 	evd_handle);
 
-DAT_RETURN
+u32
 DT_Tdep_evd_wait (DAT_EVD_HANDLE 	evd_handle,
 		  DAT_TIMEOUT   	timeout,
 		  struct dat_event    	*event);
-DAT_RETURN
+u32
 DT_Tdep_evd_dequeue (DAT_EVD_HANDLE	evd_handle,
 		     struct dat_event	*event);
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/kdapl/kdapl_tdep_evd.c linux-kernel2/test/dapltest/kdapl/kdapl_tdep_evd.c
--- linux-kernel/test/dapltest/kdapl/kdapl_tdep_evd.c	2005-05-10 10:19:18.034000000 -0700
+++ linux-kernel2/test/dapltest/kdapl/kdapl_tdep_evd.c	2005-05-11 11:16:06.670966000 -0700
@@ -94,7 +94,7 @@ KDT_Evd_Destroy(void)
     DT_Mdep_LockDestroy (&DT_Evd_Lock);
 }
 
-DAT_RETURN
+u32
 DT_Tdep_evd_create (DAT_IA_HANDLE		ia_handle,
 		    DAT_COUNT			evd_min_qlen,
 		    DAT_CNO_HANDLE		cno_handle,
@@ -102,7 +102,7 @@ DT_Tdep_evd_create (DAT_IA_HANDLE		ia_ha
 		    DAT_EVD_HANDLE		*evd_handle_ptr)
 
 {
-    DAT_RETURN 		dat_status;
+    u32 		dat_status;
     struct dat_upcall_object upcall;
     Tdep_Evd		*evd_ptr;
 
@@ -154,11 +154,11 @@ error:
     }
     return (dat_status);
 }
-DAT_RETURN
+u32
 DT_Tdep_evd_dequeue (DAT_EVD_HANDLE evd_handle,
 		     struct dat_event *dat_event)
 {
-    DAT_RETURN dat_status;
+    u32 dat_status;
     Tdep_Evd   *evd_ptr;    
     Tdep_Event *event;
 
@@ -212,12 +212,12 @@ DT_Tdep_evd_dequeue (DAT_EVD_HANDLE evd_
     return dat_status;
 }
 
-DAT_RETURN
+u32
 DT_Tdep_evd_wait (DAT_EVD_HANDLE evd_handle,
 		  DAT_TIMEOUT   timeout,
 		  struct dat_event      *dat_event)
 {
-    DAT_RETURN  dat_status;
+    u32  dat_status;
     Tdep_Evd	*evd_ptr;
     Tdep_Event	*event;
     int rc;
@@ -290,7 +290,7 @@ DT_Tdep_evd_wait (DAT_EVD_HANDLE evd_han
     return dat_status;
 }
 
-DAT_RETURN
+u32
 DT_Tdep_evd_free (DAT_EVD_HANDLE evd_handle)
 {
     Tdep_Evd	*next;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_bpool.c linux-kernel2/test/dapltest/test/dapl_bpool.c
--- linux-kernel/test/dapltest/test/dapl_bpool.c	2005-05-11 09:01:40.530003000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_bpool.c	2005-05-11 11:16:06.675963000 -0700
@@ -101,7 +101,7 @@ DT_BpoolAlloc (
     Bpool                   *bpool_ptr = NULL;
     DAT_COUNT               alloc_size, bpool_size;
     DAT_REGION_DESCRIPTION  region;
-    DAT_RETURN              ret = DAT_SUCCESS;
+    u32              ret = DAT_SUCCESS;
     DAT_VLEN                bp_len;
     DAT_MEM_TYPE            DT_mem_type;
     u64            buf_region[10];
@@ -328,7 +328,7 @@ DT_Bpool_Destroy (Per_Test_Data_t * pt_p
 	    {
 		struct dat_lmr_triplet iov;
 		DAT_RMR_COOKIE  cookie;
-		DAT_RETURN	ret;
+		u32	ret;
 
 		iov.virtual_address = bpool_ptr->reg_addr;
 		iov.segment_length  = 0; /* un-bind */
@@ -359,7 +359,7 @@ DT_Bpool_Destroy (Per_Test_Data_t * pt_p
 
 	    if (bpool_ptr->lmr_handle)
 	    {
-		DAT_RETURN ret = dat_lmr_free (bpool_ptr->lmr_handle);
+		u32 ret = dat_lmr_free (bpool_ptr->lmr_handle);
 		if (ret != DAT_SUCCESS)
 		{
 		    DT_Tdep_PT_Printf (phead,
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_client.c linux-kernel2/test/dapltest/test/dapl_client.c
--- linux-kernel/test/dapltest/test/dapl_client.c	2005-05-11 08:59:09.049005000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_client.c	2005-05-11 11:16:06.680966000 -0700
@@ -63,7 +63,7 @@ DT_cs_Client (Params_t * params_ptr,
     struct dat_dto_completion_event_data dto_stat;
     DAT_EVENT_NUMBER    event_num;
     unsigned char *     buffp;
-    DAT_RETURN          ret;
+    u32          ret;
     DT_Tdep_Print_Head	*phead;
     int status = 0;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_cnxn.c linux-kernel2/test/dapltest/test/dapl_cnxn.c
--- linux-kernel/test/dapltest/test/dapl_cnxn.c	2005-05-10 10:19:18.044000000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_cnxn.c	2005-05-11 11:16:06.687963000 -0700
@@ -34,7 +34,7 @@ get_ep_connection_state (DT_Tdep_Print_H
     DAT_EP_STATE    ep_state;
     boolean_t     in_dto_idle;
     boolean_t     out_dto_idle;
-    DAT_RETURN      ret;
+    u32      ret;
     char           *recv_status = "Idle";
     char           *req_status = "Idle";
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_connmgt.c linux-kernel2/test/dapltest/test/dapl_fft_connmgt.c
--- linux-kernel/test/dapltest/test/dapl_fft_connmgt.c	2005-04-06 22:02:35.416990000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_connmgt.c	2005-05-11 11:16:06.693960000 -0700
@@ -31,7 +31,7 @@ int DT_connmgt_case0 (Params_t *params_p
 {
     FFT_Connection_t conn;
     int res = 1;
-    DAT_RETURN rc = 0;
+    u32 rc = 0;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
 
@@ -54,7 +54,7 @@ int DT_connmgt_case1 (Params_t *params_p
 {
     FFT_Connection_t conn;
     int res = 1;
-    DAT_RETURN rc;
+    u32 rc;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_dataxfer.c linux-kernel2/test/dapltest/test/dapl_fft_dataxfer.c
--- linux-kernel/test/dapltest/test/dapl_fft_dataxfer.c	2005-04-06 22:02:35.866991000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_dataxfer.c	2005-05-11 11:16:06.696963000 -0700
@@ -31,7 +31,7 @@
 int DT_dataxfer_generic ( DT_Tdep_Print_Head * phead, FFT_Cmd_t *cmd, int test_case)
 {
     FFT_Connection_t conn;
-    DAT_RETURN rc=0;
+    u32 rc=0;
     int res=1;
     DT_fft_init_server (phead, cmd, &conn);
     DT_assert (phead, NULL != conn.ia_handle);
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_dataxfer_client.c linux-kernel2/test/dapltest/test/dapl_fft_dataxfer_client.c
--- linux-kernel/test/dapltest/test/dapl_fft_dataxfer_client.c	2005-05-11 08:59:09.052008000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_dataxfer_client.c	2005-05-11 11:16:06.700967000 -0700
@@ -37,7 +37,7 @@ int DT_dataxfer_client_generic (DT_Tdep_
 {
     int res=1;
     FFT_Connection_t conn;
-    DAT_RETURN rc=0;
+    u32 rc=0;
 
     DT_fft_init_client (phead, cmd, &conn);
     DT_assert_dat (phead, conn.ia_handle != NULL)
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_endpoint.c linux-kernel2/test/dapltest/test/dapl_fft_endpoint.c
--- linux-kernel/test/dapltest/test/dapl_fft_endpoint.c	2005-05-11 08:59:09.055001000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_endpoint.c	2005-05-11 11:16:06.705962000 -0700
@@ -43,7 +43,7 @@ int DT_endpoint_generic (Params_t *param
     DAT_EVD_HANDLE conn_evd_handle;
     DAT_EVD_HANDLE send_evd_handle;
     DAT_EVD_HANDLE recv_evd_handle;
-    DAT_RETURN rc, wanted;
+    u32 rc, wanted;
     int res;
     DT_Tdep_Print_Head *phead;
 
@@ -171,7 +171,7 @@ int DT_endpoint_case2 (Params_t *params_
     struct dat_event event;
     Bpool *bpool;
     int res;
-    DAT_RETURN rc;
+    u32 rc;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
     DT_Tdep_PT_Printf (phead, "\
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_hwconn.c linux-kernel2/test/dapltest/test/dapl_fft_hwconn.c
--- linux-kernel/test/dapltest/test/dapl_fft_hwconn.c	2005-05-05 13:35:54.484001000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_hwconn.c	2005-05-11 11:16:06.710964000 -0700
@@ -33,7 +33,7 @@ int DT_hwconn_case0 ( Params_t *params_p
     char* dev_name;
     DAT_IA_HANDLE  nic_handle;
     DAT_EVD_HANDLE evd_handle;
-    DAT_RETURN rc;
+    u32 rc;
     int res = 1;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
@@ -59,7 +59,7 @@ cleanup:
 int DT_hwconn_case1 ( Params_t *params_ptr, FFT_Cmd_t *cmd)
 {
     DAT_IA_HANDLE  nic_handle;
-    DAT_RETURN rc;
+    u32 rc;
     DAT_EVD_HANDLE evd_handle;
     char dev_name[100];
     int i;
@@ -121,7 +121,7 @@ int DT_hwconn_case1 ( Params_t *params_p
 int DT_hwconn_case2 (Params_t *params_ptr, FFT_Cmd_t *cmd)
 {
     DAT_IA_HANDLE  nic_handle;
-    DAT_RETURN rc;
+    u32 rc;
     int res=1;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
@@ -140,7 +140,7 @@ cleanup:
 int DT_hwconn_case3 (Params_t *params_ptr, FFT_Cmd_t *cmd)
 {
     FFT_Connection_t conn;
-    DAT_RETURN rc;
+    u32 rc;
     int res;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_mem.c linux-kernel2/test/dapltest/test/dapl_fft_mem.c
--- linux-kernel/test/dapltest/test/dapl_fft_mem.c	2005-05-02 12:52:13.731015000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_mem.c	2005-05-11 11:16:06.715962000 -0700
@@ -33,7 +33,7 @@
 /*--------------------------------------------------------*/
 int DT_mem_generic (Params_t *params_ptr, FFT_Cmd_t *cmd, int flag)
 {
-    DAT_RETURN rc, expect;
+    u32 rc, expect;
     FFT_Connection_t conn;
     DAT_REGION_DESCRIPTION region;
     DAT_VLEN reg_size;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_pz.c linux-kernel2/test/dapltest/test/dapl_fft_pz.c
--- linux-kernel/test/dapltest/test/dapl_fft_pz.c	2005-05-11 08:59:09.058004000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_pz.c	2005-05-11 11:16:06.722964000 -0700
@@ -38,7 +38,7 @@ int DT_pz_case0 ( Params_t *params_ptr, 
     DAT_IA_HANDLE  ia_handle;
     DAT_PZ_HANDLE pz_handle;
     DAT_EVD_HANDLE evd_handle;
-    DAT_RETURN rc;
+    u32 rc;
     int res;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead; 
@@ -79,7 +79,7 @@ int DT_pz_case1 (Params_t *params_ptr, F
     DAT_PZ_HANDLE pz_handle;
     DAT_EP_HANDLE ep_handle;
     DAT_EVD_HANDLE conn_evd, send_evd, recv_evd, cr_evd;
-    DAT_RETURN rc;
+    u32 rc;
     int res;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead; 
@@ -163,7 +163,7 @@ int DT_pz_case2 (Params_t *params_ptr, F
     DAT_IA_HANDLE  ia_handle;
     DAT_PZ_HANDLE pz_handle;
     Bpool *bpool;
-    DAT_RETURN rc;
+    u32 rc;
     int res;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead; 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_queryinfo.c linux-kernel2/test/dapltest/test/dapl_fft_queryinfo.c
--- linux-kernel/test/dapltest/test/dapl_fft_queryinfo.c	2005-05-10 08:16:11.583008000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_queryinfo.c	2005-05-11 11:16:06.726963000 -0700
@@ -41,7 +41,7 @@ static DAT_OS_WAIT_PROXY_AGENT NULLPROXY
 int DT_queryinfo_basic (Params_t *params_ptr,
 			FFT_Cmd_t *cmd,
 			FFT_query_enum object_to_query,
-			DAT_RETURN  result_wanted)
+			u32  result_wanted)
 {
     char *dev_name;
     DAT_IA_HANDLE ia_handle;
@@ -77,7 +77,7 @@ int DT_queryinfo_basic (Params_t *params
     unsigned char *alloc_ptr;
     DT_Tdep_Print_Head *phead;
 
-    DAT_RETURN rc;
+    u32 rc;
     int res = 1;
     buffer_size = BUFFSIZE * sizeof (unsigned char);
     phead = params_ptr->phead;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_fft_util.c linux-kernel2/test/dapltest/test/dapl_fft_util.c
--- linux-kernel/test/dapltest/test/dapl_fft_util.c	2005-05-11 08:59:09.062007000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_fft_util.c	2005-05-11 11:16:06.731964000 -0700
@@ -72,7 +72,7 @@ int DT_ep_create (Params_t *params_ptr,
 		  DAT_EVD_HANDLE *recv_evd, 
 		  DAT_EP_HANDLE *ep_handle)
 {
-    DAT_RETURN status;
+    u32 status;
     DT_Tdep_Print_Head *phead;
     *conn_evd = NULL;
     *send_evd = NULL;
@@ -146,7 +146,7 @@ void DT_fft_init_conn_struct (FFT_Connec
 void DT_fft_init_client (Params_t *params_ptr, FFT_Cmd_t *cmd, FFT_Connection_t *conn)
 {
     int res;
-    DAT_RETURN rc=0;
+    u32 rc=0;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
 
@@ -194,7 +194,7 @@ cleanup:
 int DT_fft_destroy_conn_struct (Params_t *params_ptr, 
 				FFT_Connection_t *conn)
 {
-    DAT_RETURN rc = DAT_SUCCESS;
+    u32 rc = DAT_SUCCESS;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
     
@@ -264,7 +264,7 @@ int DT_fft_destroy_conn_struct (Params_t
 void DT_fft_init_server (Params_t *params_ptr, FFT_Cmd_t *cmd, FFT_Connection_t *conn)
 {
     int res;
-    DAT_RETURN rc=0;
+    u32 rc=0;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
 
@@ -308,7 +308,7 @@ cleanup:
 void DT_fft_listen (Params_t *params_ptr, FFT_Connection_t *conn)
 {
     int res;
-    DAT_RETURN rc=0;
+    u32 rc=0;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
 
@@ -341,7 +341,7 @@ int DT_fft_connect (Params_t *params_ptr
 {
     int wait_count;
     int res;
-    DAT_RETURN rc=0;
+    u32 rc=0;
     DT_Tdep_Print_Head *phead;
     phead = params_ptr->phead;
 
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_limit.c linux-kernel2/test/dapltest/test/dapl_limit.c
--- linux-kernel/test/dapltest/test/dapl_limit.c	2005-05-11 09:04:51.554002000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_limit.c	2005-05-11 11:16:06.742963000 -0700
@@ -105,7 +105,7 @@ limit_test ( DT_Tdep_Print_Head *phead,
     DAT_OS_WAIT_PROXY_AGENT DAT_OS_WAIT_PROXY_AGENT_NULL = {NULL, NULL};
 #endif
 
-    DAT_RETURN	ret;
+    u32	ret;
 #   define DFLT_QLEN	  10	/* a small event queue size	*/
 #   define START_COUNT	1024	/* initial # handles		*/
 #   define DFLT_BUFFSZ	4096	/* default size for buffer	*/
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_performance_client.c linux-kernel2/test/dapltest/test/dapl_performance_client.c
--- linux-kernel/test/dapltest/test/dapl_performance_client.c	2005-05-11 09:04:51.559004000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_performance_client.c	2005-05-11 11:16:06.745962000 -0700
@@ -91,7 +91,7 @@ DT_Performance_Test_Client_Connect (
     DT_Tdep_Print_Head		*phead,
     Performance_Test_t 		*test_ptr)
 {
-    DAT_RETURN          	ret;
+    u32          	ret;
     DAT_EVENT_NUMBER            event_num;
     unsigned int		retry_cnt = 0;
 
@@ -256,7 +256,7 @@ DT_Performance_Test_Client_Phase2 (
     struct dat_rmr_triplet     	rmr_triplet;
     DAT_DTO_COOKIE 		cookie;
     struct dat_event       		event;
-    DAT_RETURN      		ret;
+    u32      		ret;
     Performance_Ep_Context_t 	*ep_context;
     Performance_Test_Op_t   	*op;
     DT_Mdep_TimeStamp 		pre_ts;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_performance_server.c linux-kernel2/test/dapltest/test/dapl_performance_server.c
--- linux-kernel/test/dapltest/test/dapl_performance_server.c	2005-05-11 09:04:51.566003000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_performance_server.c	2005-05-12 07:55:42.534000000 -0700
@@ -99,7 +99,7 @@ DT_Performance_Test_Server_Connect (
     DT_Tdep_Print_Head		*phead,
     Performance_Test_t 		*test_ptr)
 {
-    DAT_RETURN 			ret;
+    u32 			ret;
     boolean_t 		status;
     DAT_RSP_HANDLE              rsp_handle;
     DAT_PSP_HANDLE              psp_handle;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_performance_util.c linux-kernel2/test/dapltest/test/dapl_performance_util.c
--- linux-kernel/test/dapltest/test/dapl_performance_util.c	2005-05-11 09:04:51.571006000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_performance_util.c	2005-05-11 11:16:06.756962000 -0700
@@ -41,7 +41,7 @@ DT_Performance_Test_Create (
 {
     Performance_Test_t 		*test_ptr;
     DAT_COUNT			pipeline_len;
-    DAT_RETURN 			ret;
+    u32 			ret;
     DT_Tdep_Print_Head		*phead;
 
     phead = pt_ptr->Params.phead;
@@ -268,7 +268,7 @@ DT_Performance_Test_Destroy (
     Performance_Test_t 		*test_ptr,
     boolean_t 		is_server)
 {
-    DAT_RETURN 			ret;
+    u32 			ret;
     DAT_EP_HANDLE               ep_handle;
     DT_Tdep_Print_Head		*phead;
     int 			status = 0;
@@ -427,7 +427,7 @@ DT_performance_post_rdma_op (
     DT_Mdep_TimeStamp 		pre_ts;
     DT_Mdep_TimeStamp 		post_ts;
     DAT_DTO_COOKIE 		cookie;
-    DAT_RETURN      		ret;
+    u32      		ret;
     Performance_Test_Op_t   	*op = &ep_context->op;
     struct dat_lmr_triplet    	*iov = DT_Bpool_GetIOV(op->bp, 0);
     struct dat_rmr_triplet     	rmr_triplet;
@@ -525,7 +525,7 @@ DT_performance_wait (
 {
     DAT_COUNT			i;
     DAT_COUNT			queue_size;
-    DAT_RETURN      		ret;
+    u32      		ret;
     struct dat_event       		event;
     unsigned long 		pre_ctxt_num;
     unsigned long 		post_ctxt_num;
@@ -614,7 +614,7 @@ DT_performance_poll (
     DAT_EVD_HANDLE 			evd_handle,
     Performance_Stats_t 		*stats)
 {
-    DAT_RETURN      		ret;
+    u32      		ret;
     struct dat_event       		event;
     unsigned long 		pre_ctxt_num;
     unsigned long 		post_ctxt_num;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_server.c linux-kernel2/test/dapltest/test/dapl_server.c
--- linux-kernel/test/dapltest/test/dapl_server.c	2005-05-11 08:59:09.094002000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_server.c	2005-05-11 11:16:06.763960000 -0700
@@ -52,7 +52,7 @@ DT_cs_Server (Params_t * params_ptr)
 
     DAT_DTO_COOKIE	dto_cookie;
     struct dat_dto_completion_event_data dto_stat;
-    DAT_RETURN          ret;
+    u32          ret;
     DT_Tdep_Print_Head *phead;
 
     phead = params_ptr->phead;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_test_util.c linux-kernel2/test/dapltest/test/dapl_test_util.c
--- linux-kernel/test/dapltest/test/dapl_test_util.c	2005-05-11 09:04:51.577002000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_test_util.c	2005-05-11 11:16:06.768963000 -0700
@@ -38,7 +38,7 @@ DT_query (   Per_Test_Data_t *pt_ptr,
     unsigned char   *module = "DT_query";
     DAT_EVD_HANDLE  async_evd_hdl;  /* not used */
     struct dat_ep_param ep_params;
-    DAT_RETURN      ret;
+    u32      ret;
     DT_Tdep_Print_Head *phead;
 
     phead = pt_ptr->Params.phead;
@@ -169,7 +169,7 @@ DT_post_recv_buffer (DT_Tdep_Print_Head 
     struct dat_lmr_triplet *iov = DT_Bpool_GetIOV(bp, index);
     DAT_LMR_CONTEXT lmr_c = DT_Bpool_GetLMR (bp, index);
     DAT_DTO_COOKIE  cookie;
-    DAT_RETURN      ret;
+    u32      ret;
 
     /*
      * Prep the inputs
@@ -214,7 +214,7 @@ DT_post_send_buffer (DT_Tdep_Print_Head 
     struct dat_lmr_triplet *iov = DT_Bpool_GetIOV(bp, index);
     DAT_LMR_CONTEXT lmr_c = DT_Bpool_GetLMR (bp, index);
     DAT_DTO_COOKIE  cookie;
-    DAT_RETURN      ret;
+    u32      ret;
 
     /*
      * Prep the inputs
@@ -258,7 +258,7 @@ DT_cr_event_wait ( DT_Tdep_Print_Head *p
 
     for (;;)
     {
-	DAT_RETURN      ret;
+	u32      ret;
 	struct dat_event       event;
 
 	ret = DT_Tdep_evd_wait (evd_handle, DAT_TIMEOUT_INFINITE, &event);
@@ -313,7 +313,7 @@ DT_conn_event_wait (DT_Tdep_Print_Head *
 {
     for (;;)
     {
-	DAT_RETURN      ret;
+	u32      ret;
 	struct dat_event       event;
 
 	ret = DT_Tdep_evd_wait (evd_handle, DAT_TIMEOUT_INFINITE, &event);
@@ -366,7 +366,7 @@ DT_disco_event_wait ( DT_Tdep_Print_Head
 {
     for (;;)
     {
-	DAT_RETURN      ret;
+	u32      ret;
 	struct dat_event       event;
 
 	ret = DT_Tdep_evd_wait (evd_handle, DAT_TIMEOUT_INFINITE, &event);
@@ -437,7 +437,7 @@ DT_dto_event_poll (DT_Tdep_Print_Head *p
 {
     for (;;)
     {
-	DAT_RETURN      ret;
+	u32      ret;
 	struct dat_event       event;
 
 	ret = DT_Tdep_evd_dequeue ( evd_handle,
@@ -489,7 +489,7 @@ DT_dto_event_wait (DT_Tdep_Print_Head *p
 {
     for (;;)
     {
-	DAT_RETURN      ret;
+	u32      ret;
 	struct dat_event       event;
 
 	ret = DT_Tdep_evd_wait (evd_handle, DAT_TIMEOUT_INFINITE, &event);
@@ -533,7 +533,7 @@ DT_rmr_event_wait (DT_Tdep_Print_Head *p
 {
     for (;;)
     {
-	DAT_RETURN      ret;
+	u32      ret;
 	struct dat_event       event;
 
 	ret = DT_Tdep_evd_wait (evd_handle, DAT_TIMEOUT_INFINITE, &event);
@@ -664,7 +664,7 @@ DT_cr_check (  DT_Tdep_Print_Head *phead
 		DAT_CR_HANDLE   *cr_handlep,
 		char            *message)
 {
-    DAT_RETURN ret;
+    u32 ret;
 
     if (cr_handlep)
     {
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_transaction_test.c linux-kernel2/test/dapltest/test/dapl_transaction_test.c
--- linux-kernel/test/dapltest/test/dapl_transaction_test.c	2005-05-11 09:04:51.593002000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_transaction_test.c	2005-05-11 11:16:06.783962000 -0700
@@ -229,7 +229,7 @@ void 
 DT_Transaction_Main (void *param)
 {
     Transaction_Test_t  *test_ptr = (Transaction_Test_t *) param;
-    DAT_RETURN          ret;
+    u32          ret;
     u32          i, j;
     boolean_t 	success = FALSE;
     Per_Test_Data_t     *pt_ptr;
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_transaction_util.c linux-kernel2/test/dapltest/test/dapl_transaction_util.c
--- linux-kernel/test/dapltest/test/dapl_transaction_util.c	2005-05-11 09:04:51.599004000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_transaction_util.c	2005-05-11 11:16:06.789964000 -0700
@@ -43,7 +43,7 @@ DT_handle_post_recv_buf (DT_Tdep_Print_H
 	Transaction_Test_Op_t   *op   = &ep_context[i].op[op_indx];
 	struct dat_lmr_triplet  *iov = DT_Bpool_GetIOV(op->bp, 0);
 	DAT_DTO_COOKIE          cookie;
-	DAT_RETURN              ret;
+	u32              ret;
 
 	/* Prep the inputs */
 	for (j = 0;  j < op->num_segs;  j++)
@@ -105,7 +105,7 @@ DT_handle_send_op (DT_Tdep_Print_Head *p
 	Transaction_Test_Op_t   *op   = &ep_context[i].op[op_indx];
 	struct dat_lmr_triplet  *iov = DT_Bpool_GetIOV(op->bp, 0);
 	DAT_DTO_COOKIE          cookie;
-	DAT_RETURN              ret;
+	u32              ret;
 
 	/* Prep the inputs */
 	for (j = 0;  j < op->num_segs;  j++)
@@ -470,7 +470,7 @@ DT_handle_rdma_op (DT_Tdep_Print_Head *p
 		  boolean_t poll)
 {
     unsigned int    i, j;
-    DAT_RETURN      ret;
+    u32      ret;
     unsigned char   *completion_reaped;
 
     completion_reaped = DT_Mdep_Malloc (num_eps * sizeof (unsigned char));
diff -Nurp -X /home/tduffy/dontdiff linux-kernel/test/dapltest/test/dapl_util.c linux-kernel2/test/dapltest/test/dapl_util.c
--- linux-kernel/test/dapltest/test/dapl_util.c	2005-05-05 09:42:06.416005000 -0700
+++ linux-kernel2/test/dapltest/test/dapl_util.c	2005-05-11 11:16:06.794962000 -0700
@@ -28,11 +28,11 @@
 #include "dapl_proto.h"
 
 /*
- * Map DAT_RETURN values to readable strings,
+ * Map u32 values to readable strings,
  * but don't assume the values are zero-based or contiguous.
  */
 const char *
-DT_RetToString (DAT_RETURN ret_value)
+DT_RetToString (u32 ret_value)
 {
     const char *major_msg, *minor_msg;
     int sz;
@@ -61,7 +61,7 @@ DT_AsyncErr2Str (DAT_EVENT_NUMBER error_
     static struct
     {
 	const char  *name;
-	DAT_RETURN  value;
+	u32  value;
     } dat_errors[] =
     {
 #   define DATxx(x) { # x, x }
@@ -106,7 +106,7 @@ DT_EventToSTr (DAT_EVENT_NUMBER event_co
     static struct
     {
 	const char  *name;
-	DAT_RETURN  value;
+	u32  value;
     }
     dat_events[] =
     {
@@ -154,7 +154,7 @@ DT_State2Str (DAT_EP_STATE state_code)
     static struct
     {
 	const char  *name;
-	DAT_RETURN  value;
+	u32  value;
     }
     dat_state[] =
     {




More information about the general mailing list