void
dapls_query_provider_specific_attr(
IN DAPL_IA *ia_ptr,
- IN DAT_PROVIDER_ATTR *provider_attr );
+ IN DAT_PROVIDER_ATTR *attr_ptr );
#ifdef CQ_WAIT_OBJECT
DAT_RETURN
if ( DAPL_DBG_DEST_STDOUT & g_dapl_dbg_dest )
{
va_start (args, fmt);
- fprintf(stdout, "%s:%d: ", _ptr_host_, getpid());
+ fprintf(stdout, "%s:%d: ", _ptr_host_, dapl_os_getpid());
dapl_os_vprintf (fmt, args);
va_end (args);
}
#include "dapl_sp_util.h"
#include "dapl_ep_util.h"
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-
STATIC _INLINE_ void dapli_evd_eh_print_cqe (
IN ib_work_completion_t *cqe);
dapl_llist_init_entry (&sp_ptr->header.ia_list_entry);
dapl_os_lock_init (&sp_ptr->header.lock);
-#if defined(_WIN32) || defined(_WIN64)
+#if defined(_VENDOR_IBAL_)
dapl_os_wait_object_init( &sp_ptr->wait_object );
#endif
/*
sp_ptr->header.magic == DAPL_MAGIC_RSP);
dapl_os_assert (dapl_llist_is_empty (&sp_ptr->cr_list_head));
-#if defined(_WIN32) || defined(_WIN64)
+#if defined(_VENDOR_IBAL_)
dapl_os_wait_object_destroy( &sp_ptr->wait_object );
#endif
dapl_os_lock (&sp_ptr->header.lock);
ib_cm_srvc_handle_t cm_srvc_handle; /* Used by Mellanox CM */
DAPL_LLIST_HEAD cr_list_head; /* CR pending queue */
DAT_COUNT cr_list_count; /* count of CRs on queue */
-#if _VENDOR_IBAL_
+#if defined(_VENDOR_IBAL_)
DAPL_OS_WAIT_OBJECT wait_object; /* cancel & destroy. */
#endif
};
#include <sys/time.h>
#include <syslog.h>
#include <netdb.h> /* for getaddrinfo */
+#include <byteswap.h>
+
+#include <sys/ioctl.h> /* for IOCTL's */
#include "dapl_debug.h"
/*
* Include files for setting up a network name
*/
+#include <sys/socket.h> /* for socket(2) */
+#include <net/if.h> /* for struct ifreq */
+#include <net/if_arp.h> /* for ARPHRD_ETHER */
#include <unistd.h>
#include <sys/types.h>
#include <sys/socket.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
#include <ctype.h>
+#include <sys/poll.h>
+#include <signal.h>
+#include <netinet/tcp.h>
+#include <sys/utsname.h>
+#include <fcntl.h>
+
#if !defined(REDHAT_EL5) && (defined(__ia64__))
#include <asm/atomic.h>
#endif
#define dapl_os_vprintf(fmt,args) vprintf(fmt,args)
#define dapl_os_syslog(fmt,args) vsyslog(LOG_USER|LOG_WARNING,fmt,args)
+#define dapl_os_getpid getpid
#endif /* _DAPL_OSD_H_ */
#include <string.h>
#include <winsock2.h>
#include <Ws2tcpip.h>
+#include <process.h>
#include <stdlib.h>
#pragma warning ( pop )
exit(1); \
}
+#define openlog(...)
+#define closelog(...)
+
/*
* Atomic operations
*/
*/
STATIC __inline void dapl_os_sleep_usec (int sleep_time)
{
- Sleep(sleep_time/1000);
+ Sleep(sleep_time/1000); // convert to milliseconds
}
STATIC __inline DAPL_OS_TICKS dapl_os_get_ticks (void);
return strtol(nptr, endptr, base);
}
+STATIC __inline int
+dapl_os_getpid(void)
+{
+ return (int)GetCurrentProcessId();
+}
/*
* Debug Helper Functions
#define dapl_os_vprintf(fmt,args) vprintf(fmt,args)
#define dapl_os_syslog(fmt,args) /* XXX Need log routine call */
-
#endif /* _DAPL_OSD_H_ */
/*
TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR)
TARGETTYPE=DYNLINK
DLLENTRY=_DllMainCRTStartup
+!if $(_NT_TOOLS_VERSION) == 0x700
DLLDEF=$O\udat_exports.def
-USE_CRTDLL=1
+!else
+DLLDEF=$(OBJ_PATH)\$O\udat_exports.def
+!endif
+USE_MSVCRT=1
SOURCES=udat.rc \
udat.c \
dat_pz_query
dat_registry_add_provider
dat_registry_remove_provider
+dat_registry_list_providers
dat_rmr_bind
dat_rmr_create
dat_rmr_free
dat_rsp_free
dat_rsp_query
dat_strerror
+dats_get_ia_handle
#ifdef DAT_EXTENSIONS
dat_extension_op
#endif
{
va_list args;
- va_start(args, fmt);
-
if ( DAT_OS_DBG_DEST_STDOUT & g_dbg_dest )
{
+ va_start(args, fmt);
vfprintf(stdout, fmt, args);
- }
-
- va_end(args);
-
fflush(stdout);
+ va_end(args);
+ }
+ /* no syslog() susport in Windows */
}
}
#error "UNDEFINED OS TYPE"
#endif /* WIN32/64 */
-#include <dat/udat.h>
-#include <dat/dat_registry.h>
+#include <dat2/udat.h>
+#include <dat2/dat_registry.h>
#include <windows.h>
#include <assert.h>