[OPENSM] version 3.3.2 work-in-progress
authorstansmith <stansmith@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Sat, 24 Oct 2009 00:58:23 +0000 (00:58 +0000)
committerstansmith <stansmith@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Sat, 24 Oct 2009 00:58:23 +0000 (00:58 +0000)
git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@2499 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/opensm/user/ibtrapgen/Makefile
ulp/opensm/user/ibtrapgen/SOURCES
ulp/opensm/user/ibtrapgen/ibtrapgen.c

index 9c985f5..a0c0627 100644 (file)
@@ -1,7 +1,7 @@
 #\r
 # DO NOT EDIT THIS FILE!!!  Edit .\sources. if you want to add a new source\r
 # file to this component.  This file merely indirects to the real make file\r
-# that is shared by all the driver components of the Windows NT DDK\r
+# that is shared by all the driver components of the OpenIB Windows project.\r
 #\r
 \r
-!INCLUDE $(NTMAKEENV)\makefile.def\r
+!INCLUDE ..\..\..\..\inc\openib.def\r
index c58e0c7..850a113 100644 (file)
@@ -16,6 +16,11 @@ TARGETPATH=$(OSM_TARGET)\bin\user\obj$(BUILD_ALT_DIR)
 TARGETPATH=$(WINIBHOME)\bin\user\obj$(BUILD_ALT_DIR)\r
 !endif\r
 \r
+# include only one vendor definition\r
+\r
+!include ..\opensm\vendor-ibal.inc\r
+#!include ..\opensm\vendor-umad.inc\r
+\r
 TARGETTYPE=PROGRAM\r
 UMTYPE=console\r
 USE_MSVCRT=1\r
@@ -24,41 +29,44 @@ OVR_DIR=..\addon
 \r
 SOURCES=\\r
        main.c \\r
-       ibtrapgen.c\r
-\r
+       ibtrapgen.c \\r
+       osm_files.c\r
 \r
 \r
 OSM_HOME=..\r
 \r
 TARGETLIBS=\\r
+       $(SDK_LIB_PATH)\kernel32.lib \\r
+       $(SDK_LIB_PATH)\ws2_32.lib \\r
 !if $(FREEBUILD)\r
-                       $(LIBPATH)\*\ibal.lib \\r
-                       $(LIBPATH)\*\complib.lib \\r
-                       $(TARGETPATH)\*\osmv_ibal.lib \\r
-                       $(TARGETPATH)\*\opensm_ibal.lib\r
+       $(VENDOR_LIBS) \\r
+       $(LIBPATH)\*\ibal.lib \\r
+       $(LIBPATH)\*\complib.lib\r
 !else\r
-                       $(LIBPATH)\*\ibald.lib \\r
-                       $(LIBPATH)\*\complibd.lib \\r
-                       $(TARGETPATH)\*\osmv_ibald.lib \\r
-                       $(TARGETPATH)\*\opensm_ibald.lib\r
+       $(VENDOR_LIBSD) \\r
+       $(LIBPATH)\*\ibald.lib \\r
+       $(LIBPATH)\*\complibd.lib\r
 !endif\r
 \r
-#DO NOT TOUCH the order of search path , until ib_types.h merging process will be done\r
 INCLUDES= \\r
-       $(OSM_HOME)\include; \\r
-       $(OSM_HOME); \\r
        $(WINIBHOME)\inc; \\r
-       $(WINIBHOME)\inc\user;\r
+       $(WINIBHOME)\inc\user; \\r
+       $(WINIBHOME)\inc\user\linux; \\r
+       $(OSM_HOME); \\r
+       $(OSM_HOME)\include; \\r
 \r
 # Could be any special flag needed for this project \r
 USER_C_FLAGS=$(USER_C_FLAGS) /MD\r
+\r
 #Add preproccessor definitions\r
-C_DEFINES=$(C_DEFINES) -DWIN32 -D__WIN__ -D__i386__ -Dinline=__inline -DMT_LITTLE_ENDIAN -DOSM_VENDOR_INTF_AL\r
+C_DEFINES=$(C_DEFINES) -D__WIN__ -D$(VENDOR_IF) -DHAVE_CONFIG_H\r
+\r
 !if !$(FREEBUILD)\r
 #C_DEFINES=$(C_DEFINES) -D_DEBUG -DDEBUG -DDBG\r
 C_DEFINES=$(C_DEFINES) \r
 !endif\r
 \r
 LINKER_FLAGS= $(LINKER_FLAGS)\r
+\r
 MSC_WARNING_LEVEL= /W3\r
 \r
index bd37882..e124474 100644 (file)
@@ -141,8 +141,7 @@ ibtrapgen_init( IN ibtrapgen_t * const p_ibtrapgen,
 
   /* all mads (actually wrappers) are taken and returned to a pool */
   osm_mad_pool_construct( &p_ibtrapgen->mad_pool );
-  status = osm_mad_pool_init(
-    &p_ibtrapgen->mad_pool, p_ibtrapgen->p_log );
+  status = osm_mad_pool_init( &p_ibtrapgen->mad_pool );
   if( status != IB_SUCCESS )
     goto Exit;
 
@@ -169,12 +168,12 @@ __ibtrapgen_rcv_callback(
 {
   ibtrapgen_t* p_ibtrapgen = (ibtrapgen_t*)bind_context;
 
-  OSM_LOG_ENTER( p_ibtrapgen->p_log, __ibtrapgen_rcv_callback );
+  OSM_LOG_ENTER( p_ibtrapgen->p_log );
 
   CL_ASSERT( p_madw );
 
-  osm_log( p_ibtrapgen->p_log, OSM_LOG_VERBOSE,
-           "__ibtrapgen_rcv_callback: Got callback\n",
+  OSM_LOG( p_ibtrapgen->p_log, OSM_LOG_VERBOSE,
+           "Got callback trans_id %64I\n",
            cl_ntoh64(p_madw->p_mad->trans_id) );
 
   OSM_LOG_EXIT( p_ibtrapgen->p_log );
@@ -196,7 +195,7 @@ __ibtrapgen_send_err_cb(
 {
   ibtrapgen_t* p_ibtrapgen = (ibtrapgen_t*)bind_context;
 
-  OSM_LOG_ENTER( p_ibtrapgen->p_log, __ibtrapgen_send_err_callback );
+  OSM_LOG_ENTER( p_ibtrapgen->p_log );
 
   osm_log( p_ibtrapgen->p_log, OSM_LOG_ERROR,
            "__ibtrapgen_send_err_cb: ERR 0011: "
@@ -223,7 +222,7 @@ ibtrapgen_bind( IN ibtrapgen_t * p_ibtrapgen )
   osm_bind_info_t bind_info;
   uint8_t i;
 
-  OSM_LOG_ENTER( p_ibtrapgen->p_log, ibtrapgen_bind );
+  OSM_LOG_ENTER( p_ibtrapgen->p_log );
 
   /*
    * Call the transport layer for a list of local port
@@ -347,7 +346,7 @@ ibtrapgen_run( IN ibtrapgen_t * const p_ibtrapgen )
   osm_log_t *p_log =      p_ibtrapgen->p_log;
   uint16_t                i;
 
-  OSM_LOG_ENTER( p_log, ibtrapgen_run );
+  OSM_LOG_ENTER( p_log );
 
   osm_log( p_log, OSM_LOG_INFO,
            "ibtrapgen_run: "