libibmad: update to commit 1f5fdf3dfc69733a427520198bcbdd03645bb326
authorshefty <shefty@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Mon, 2 Mar 2009 23:30:06 +0000 (23:30 +0000)
committershefty <shefty@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Mon, 2 Mar 2009 23:30:06 +0000 (23:30 +0000)
Needed update to exported function list.

Signed-off-by: Sean Hefty <sean.hefty@intel.com>
git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@1997 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/libibmad/include/infiniband/mad.h
ulp/libibmad/include/infiniband/mad_osd.h
ulp/libibmad/src/Sources
ulp/libibmad/src/dump.c
ulp/libibmad/src/fields.c
ulp/libibmad/src/gs.c
ulp/libibmad/src/ibmad_exports.src
ulp/libibmad/src/libibmad.map

index 3095f34..5f9dea3 100644 (file)
@@ -127,12 +127,23 @@ enum SMI_ATTR_ID {
 enum SA_ATTR_ID {
        IB_SA_ATTR_NOTICE = 0x02,
        IB_SA_ATTR_INFORMINFO = 0x03,
+       IB_SA_ATTR_NODERECORD = 0x11,
        IB_SA_ATTR_PORTINFORECORD = 0x12,
+       IB_SA_ATTR_SL2VLTABLERECORD = 0x13,
+       IB_SA_ATTR_SWITCHINFORECORD = 0x14,
+       IB_SA_ATTR_LFTRECORD = 0x15,
+       IB_SA_ATTR_RFTRECORD = 0x16,
+       IB_SA_ATTR_MFTRECORD = 0x17,
+       IB_SA_ATTR_SMINFORECORD = 0x18,
        IB_SA_ATTR_LINKRECORD = 0x20,
+       IB_SA_ATTR_GUIDINFORECORD = 0x30,
        IB_SA_ATTR_SERVICERECORD = 0x31,
+       IB_SA_ATTR_PKEYTABLERECORD = 0x33,
        IB_SA_ATTR_PATHRECORD = 0x35,
+       IB_SA_ATTR_VLARBTABLERECORD = 0x36,
        IB_SA_ATTR_MCRECORD = 0x38,
        IB_SA_ATTR_MULTIPATH = 0x3a,
+       IB_SA_ATTR_INFORMINFORECORD = 0xf3,
 
        IB_SA_ATTR_LAST
 };
@@ -142,7 +153,8 @@ enum GSI_ATTR_ID {
        IB_GSI_PORT_SAMPLES_RESULT = 0x11,
        IB_GSI_PORT_COUNTERS = 0x12,
        IB_GSI_PORT_COUNTERS_EXT = 0x1D,
-
+       IB_GSI_PORT_XMIT_DATA_SL = 0x36,
+       IB_GSI_PORT_RCV_DATA_SL  = 0x37,
        IB_GSI_ATTR_LAST
 };
 
@@ -551,6 +563,44 @@ enum MAD_FIELDS {
        IB_CPI_TRAP_QP_F,
        IB_CPI_TRAP_QKEY_F,
 
+       IB_PC_XMT_DATA_SL_FIRST_F,
+       IB_PC_XMT_DATA_SL0_F = IB_PC_XMT_DATA_SL_FIRST_F,
+       IB_PC_XMT_DATA_SL1_F,
+       IB_PC_XMT_DATA_SL2_F,
+       IB_PC_XMT_DATA_SL3_F,
+       IB_PC_XMT_DATA_SL4_F,
+       IB_PC_XMT_DATA_SL5_F,
+       IB_PC_XMT_DATA_SL6_F,
+       IB_PC_XMT_DATA_SL7_F,
+       IB_PC_XMT_DATA_SL8_F,
+       IB_PC_XMT_DATA_SL9_F,
+       IB_PC_XMT_DATA_SL10_F,
+       IB_PC_XMT_DATA_SL11_F,
+       IB_PC_XMT_DATA_SL12_F,
+       IB_PC_XMT_DATA_SL13_F,
+       IB_PC_XMT_DATA_SL14_F,
+       IB_PC_XMT_DATA_SL15_F,
+       IB_PC_XMT_DATA_SL_LAST_F,
+
+       IB_PC_RCV_DATA_SL_FIRST_F,
+       IB_PC_RCV_DATA_SL0_F = IB_PC_RCV_DATA_SL_FIRST_F,
+       IB_PC_RCV_DATA_SL1_F,
+       IB_PC_RCV_DATA_SL2_F,
+       IB_PC_RCV_DATA_SL3_F,
+       IB_PC_RCV_DATA_SL4_F,
+       IB_PC_RCV_DATA_SL5_F,
+       IB_PC_RCV_DATA_SL6_F,
+       IB_PC_RCV_DATA_SL7_F,
+       IB_PC_RCV_DATA_SL8_F,
+       IB_PC_RCV_DATA_SL9_F,
+       IB_PC_RCV_DATA_SL10_F,
+       IB_PC_RCV_DATA_SL11_F,
+       IB_PC_RCV_DATA_SL12_F,
+       IB_PC_RCV_DATA_SL13_F,
+       IB_PC_RCV_DATA_SL14_F,
+       IB_PC_RCV_DATA_SL15_F,
+       IB_PC_RCV_DATA_SL_LAST_F,
+
        IB_FIELD_LAST_          /* must be last */
 };
 
@@ -737,7 +787,7 @@ MAD_EXPORT uint8_t *smp_query(void *buf, ib_portid_t * id, unsigned attrid,
                              unsigned mod, unsigned timeout);
 MAD_EXPORT uint8_t *smp_set(void *buf, ib_portid_t * id, unsigned attrid,
                            unsigned mod, unsigned timeout);
-uint8_t *smp_query_via(void *buf, ib_portid_t * id, unsigned attrid,
+MAD_EXPORT uint8_t *smp_query_via(void *buf, ib_portid_t * id, unsigned attrid,
                       unsigned mod, unsigned timeout, const void *srcport);
 uint8_t *smp_set_via(void *buf, ib_portid_t * id, unsigned attrid, unsigned mod,
                     unsigned timeout, const void *srcport);
@@ -770,43 +820,13 @@ int ib_resolve_self_via(ib_portid_t * portid, int *portnum, ibmad_gid_t * gid,
                        const void *srcport);
 
 /* gs.c */
-MAD_EXPORT uint8_t *perf_classportinfo_query(void *rcvbuf, ib_portid_t * dest,
-                                            int port, unsigned timeout);
-MAD_EXPORT uint8_t *port_performance_query(void *rcvbuf, ib_portid_t * dest,
-                                          int port, unsigned timeout);
-MAD_EXPORT uint8_t *port_performance_reset(void *rcvbuf, ib_portid_t * dest,
-                                          int port, unsigned mask,
-                                          unsigned timeout);
-MAD_EXPORT uint8_t *port_performance_ext_query(void *rcvbuf, ib_portid_t * dest,
-                                              int port, unsigned timeout);
-MAD_EXPORT uint8_t *port_performance_ext_reset(void *rcvbuf, ib_portid_t * dest,
-                                              int port, unsigned mask,
-                                              unsigned timeout);
-MAD_EXPORT uint8_t *port_samples_control_query(void *rcvbuf, ib_portid_t * dest,
-                                              int port, unsigned timeout);
-MAD_EXPORT uint8_t *port_samples_result_query(void *rcvbuf, ib_portid_t * dest,
-                                             int port, unsigned timeout);
-
-uint8_t *perf_classportinfo_query_via(void *rcvbuf, ib_portid_t * dest,
-                                     int port, unsigned timeout,
-                                     const void *srcport);
-uint8_t *port_performance_query_via(void *rcvbuf, ib_portid_t * dest, int port,
-                                   unsigned timeout, const void *srcport);
-uint8_t *port_performance_reset_via(void *rcvbuf, ib_portid_t * dest, int port,
-                                   unsigned mask, unsigned timeout,
-                                   const void *srcport);
-uint8_t *port_performance_ext_query_via(void *rcvbuf, ib_portid_t * dest,
-                                       int port, unsigned timeout,
-                                       const void *srcport);
-uint8_t *port_performance_ext_reset_via(void *rcvbuf, ib_portid_t * dest,
-                                       int port, unsigned mask,
-                                       unsigned timeout, const void *srcport);
-uint8_t *port_samples_control_query_via(void *rcvbuf, ib_portid_t * dest,
-                                       int port, unsigned timeout,
-                                       const void *srcport);
-uint8_t *port_samples_result_query_via(void *rcvbuf, ib_portid_t * dest,
-                                      int port, unsigned timeout,
-                                      const void *srcport);
+MAD_EXPORT uint8_t *pma_query_via(void *rcvbuf, ib_portid_t * dest, int port,
+                             unsigned timeout, unsigned id,
+                             const void *srcport);
+
+MAD_EXPORT uint8_t *performance_reset_via(void *rcvbuf, ib_portid_t * dest,
+                                     int port, unsigned mask, unsigned timeout,
+                                     unsigned id, const void *srcport);
 /* dump.c */
 MAD_EXPORT ib_mad_dump_fn
     mad_dump_int, mad_dump_uint, mad_dump_hex, mad_dump_rhex,
@@ -819,7 +839,8 @@ MAD_EXPORT ib_mad_dump_fn
     mad_dump_mtu, mad_dump_vlcap, mad_dump_opervls,
     mad_dump_node_type, mad_dump_sltovl, mad_dump_vlarbitration,
     mad_dump_nodedesc, mad_dump_nodeinfo, mad_dump_portinfo,
-    mad_dump_switchinfo, mad_dump_perfcounters, mad_dump_perfcounters_ext;
+    mad_dump_switchinfo, mad_dump_perfcounters, mad_dump_perfcounters_ext,
+    mad_dump_perfcounters_xmt_sl, mad_dump_perfcounters_rcv_sl;
 
 extern int ibdebug;
 
@@ -864,7 +885,7 @@ static inline uint64_t htonll(uint64_t x)
        exit(-1); \
 } while(0)
 
-void xdump(FILE * file, char *msg, void *p, int size);
+MAD_EXPORT void xdump(FILE * file, char *msg, void *p, int size);
 
 END_C_DECLS
 #endif                         /* _MAD_H_ */
index 1308f88..dde6e3a 100644 (file)
@@ -48,6 +48,8 @@ typedef unsigned __int64      uint64_t;
 \r
 #define MAD_EXPORT     __declspec(dllexport)\r
 \r
+#define __attribute__(X)\r
+\r
 #if !defined( __cplusplus )\r
 #define inline __inline\r
 #endif\r
index 11df62f..e487615 100644 (file)
@@ -27,7 +27,11 @@ SOURCES = \
        smp.c \\r
        vendor.c\r
        \r
-INCLUDES = ..\include\infiniband;..\..\libibmad\include;..\..\libibverbs\include;..\..\libibumad\include;..\..\..\inc;..\..\..\inc\user;\r
+INCLUDES =     ..\include\infiniband;\\r
+                       ..\..\libibmad\include;\\r
+                       ..\..\libibverbs\include;\\r
+                       ..\..\libibumad\include;\\r
+                       ..\..\..\inc;..\..\..\inc\user;\r
 \r
 USER_C_FLAGS = $(USER_C_FLAGS) -DEXPORT_IBMAD_SYMBOLS\r
 \r
index 3b49158..e75e178 100644 (file)
@@ -699,6 +699,16 @@ void mad_dump_perfcounters_ext(char *buf, int bufsz, void *val, int valsz)
        _dump_fields(buf, bufsz, val, IB_PC_EXT_FIRST_F, IB_PC_EXT_LAST_F);
 }
 
+void mad_dump_perfcounters_xmt_sl(char *buf, int bufsz, void *val, int valsz)
+{
+       _dump_fields(buf, bufsz, val, IB_PC_XMT_DATA_SL_FIRST_F, IB_PC_XMT_DATA_SL_LAST_F);
+}
+
+void mad_dump_perfcounters_rcv_sl(char *buf, int bufsz, void *val, int valsz)
+{
+       _dump_fields(buf, bufsz, val, IB_PC_RCV_DATA_SL_FIRST_F, IB_PC_RCV_DATA_SL_LAST_F);
+}
+
 void xdump(FILE * file, char *msg, void *p, int size)
 {
 #define HEX(x)  ((x) < 10 ? '0' + (x) : 'a' + ((x) -10))
index 08d0ccb..7b69310 100644 (file)
@@ -95,7 +95,7 @@ static const ib_field_t ib_mad_f[] = {
        {BE_OFFS(272, 16), "DrSmpSLID", mad_dump_hex},
 
        /* word 10,11 (36-43 bytes) */
-       {0, 0},                 /* IB_SA_MKEY_F - reserved as invalid */
+       {288, 64, "SaSMkey", mad_dump_hex},
 
        /* word 12 (44-47 bytes) */
        {BE_OFFS(46 * 8, 16), "SaAttrOffs", mad_dump_uint},
@@ -123,8 +123,8 @@ static const ib_field_t ib_mad_f[] = {
         */
        {0, 64, "Mkey", mad_dump_hex},
        {64, 64, "GidPrefix", mad_dump_hex},
-       {BITSOFFS(128, 16), "Lid", mad_dump_hex},
-       {BITSOFFS(144, 16), "SMLid", mad_dump_hex},
+       {BITSOFFS(128, 16), "Lid", mad_dump_uint},
+       {BITSOFFS(144, 16), "SMLid", mad_dump_uint},
        {160, 32, "CapMask", mad_dump_portcapmask},
        {BITSOFFS(192, 16), "DiagCode", mad_dump_hex},
        {BITSOFFS(208, 16), "MkeyLeasePeriod", mad_dump_uint},
@@ -402,6 +402,42 @@ static const ib_field_t ib_mad_f[] = {
        {BITSOFFS(520, 24), "TrapQP", mad_dump_hex},
        {544, 32, "TrapQKey", mad_dump_hex},
 
+       {32,  32, "XmtDataSL0", mad_dump_uint},
+       {64,  32, "XmtDataSL1", mad_dump_uint},
+       {96,  32, "XmtDataSL2", mad_dump_uint},
+       {128, 32, "XmtDataSL3", mad_dump_uint},
+       {160, 32, "XmtDataSL4", mad_dump_uint},
+       {196, 32, "XmtDataSL5", mad_dump_uint},
+       {224, 32, "XmtDataSL6", mad_dump_uint},
+       {256, 32, "XmtDataSL7", mad_dump_uint},
+       {288, 32, "XmtDataSL8", mad_dump_uint},
+       {320, 32, "XmtDataSL9", mad_dump_uint},
+       {352, 32, "XmtDataSL10", mad_dump_uint},
+       {384, 32, "XmtDataSL11", mad_dump_uint},
+       {416, 32, "XmtDataSL12", mad_dump_uint},
+       {448, 32, "XmtDataSL13", mad_dump_uint},
+       {480, 32, "XmtDataSL14", mad_dump_uint},
+       {512, 32, "XmtDataSL15", mad_dump_uint},
+       {0, 0},                 /* IB_PC_XMT_DATA_SL_LAST_F */
+
+       {32,  32, "RcvDataSL0", mad_dump_uint},
+       {64,  32, "RcvDataSL1", mad_dump_uint},
+       {96,  32, "RcvDataSL2", mad_dump_uint},
+       {128, 32, "RcvDataSL3", mad_dump_uint},
+       {160, 32, "RcvDataSL4", mad_dump_uint},
+       {196, 32, "RcvDataSL5", mad_dump_uint},
+       {224, 32, "RcvDataSL6", mad_dump_uint},
+       {256, 32, "RcvDataSL7", mad_dump_uint},
+       {288, 32, "RcvDataSL8", mad_dump_uint},
+       {320, 32, "RcvDataSL9", mad_dump_uint},
+       {352, 32, "RcvDataSL10", mad_dump_uint},
+       {384, 32, "RcvDataSL11", mad_dump_uint},
+       {416, 32, "RcvDataSL12", mad_dump_uint},
+       {448, 32, "RcvDataSL13", mad_dump_uint},
+       {480, 32, "RcvDataSL14", mad_dump_uint},
+       {512, 32, "RcvDataSL15", mad_dump_uint},
+       {0, 0},                 /* IB_PC_RCV_DATA_SL_LAST_F */
+
        {0, 0}                  /* IB_FIELD_LAST_ */
 
 };
index d2c4574..5b7ed88 100644 (file)
@@ -45,9 +45,9 @@
 #undef DEBUG
 #define DEBUG  if (ibdebug)    IBWARN
 
-static uint8_t *pma_query_via(void *rcvbuf, ib_portid_t * dest, int port,
-                             unsigned timeout, unsigned id,
-                             const void *srcport)
+uint8_t *pma_query_via(void *rcvbuf, ib_portid_t * dest, int port,
+                     unsigned timeout, unsigned id,
+                     const void *srcport)
 {
        ib_rpc_t rpc = { 0 };
        int lid = dest->lid;
@@ -81,42 +81,9 @@ static uint8_t *pma_query_via(void *rcvbuf, ib_portid_t * dest, int port,
        }
 }
 
-uint8_t *pma_query(void *rcvbuf, ib_portid_t * dest, int port, unsigned timeout,
-                  unsigned id)
-{
-       return pma_query_via(rcvbuf, dest, port, timeout, id, NULL);
-}
-
-uint8_t *perf_classportinfo_query_via(void *rcvbuf, ib_portid_t * dest,
-                                     int port, unsigned timeout,
-                                     const void *srcport)
-{
-       return pma_query_via(rcvbuf, dest, port, timeout, CLASS_PORT_INFO,
-                            srcport);
-}
-
-uint8_t *perf_classportinfo_query(void *rcvbuf, ib_portid_t * dest, int port,
-                                 unsigned timeout)
-{
-       return pma_query(rcvbuf, dest, port, timeout, CLASS_PORT_INFO);
-}
-
-uint8_t *port_performance_query_via(void *rcvbuf, ib_portid_t * dest, int port,
-                                   unsigned timeout, const void *srcport)
-{
-       return pma_query_via(rcvbuf, dest, port, timeout,
-                            IB_GSI_PORT_COUNTERS, srcport);
-}
-
-uint8_t *port_performance_query(void *rcvbuf, ib_portid_t * dest, int port,
-                               unsigned timeout)
-{
-       return pma_query(rcvbuf, dest, port, timeout, IB_GSI_PORT_COUNTERS);
-}
-
-static uint8_t *performance_reset_via(void *rcvbuf, ib_portid_t * dest,
-                                     int port, unsigned mask, unsigned timeout,
-                                     unsigned id, const void *srcport)
+uint8_t *performance_reset_via(void *rcvbuf, ib_portid_t * dest,
+                             int port, unsigned mask, unsigned timeout,
+                             unsigned id, const void *srcport)
 {
        ib_rpc_t rpc = { 0 };
        int lid = dest->lid;
@@ -156,84 +123,3 @@ static uint8_t *performance_reset_via(void *rcvbuf, ib_portid_t * dest,
                return madrpc(&rpc, dest, rcvbuf, rcvbuf);
        }
 }
-
-static uint8_t *performance_reset(void *rcvbuf, ib_portid_t * dest, int port,
-                                 unsigned mask, unsigned timeout, unsigned id)
-{
-       return performance_reset_via(rcvbuf, dest, port, mask, timeout,
-                                    id, NULL);
-}
-
-uint8_t *port_performance_reset_via(void *rcvbuf, ib_portid_t * dest, int port,
-                                   unsigned mask, unsigned timeout,
-                                   const void *srcport)
-{
-       return performance_reset_via(rcvbuf, dest, port, mask, timeout,
-                                    IB_GSI_PORT_COUNTERS, srcport);
-}
-
-uint8_t *port_performance_reset(void *rcvbuf, ib_portid_t * dest, int port,
-                               unsigned mask, unsigned timeout)
-{
-       return performance_reset(rcvbuf, dest, port, mask, timeout,
-                                IB_GSI_PORT_COUNTERS);
-}
-
-uint8_t *port_performance_ext_query_via(void *rcvbuf, ib_portid_t * dest,
-                                       int port, unsigned timeout,
-                                       const void *srcport)
-{
-       return pma_query_via(rcvbuf, dest, port, timeout,
-                            IB_GSI_PORT_COUNTERS_EXT, srcport);
-}
-
-uint8_t *port_performance_ext_query(void *rcvbuf, ib_portid_t * dest, int port,
-                                   unsigned timeout)
-{
-       return pma_query(rcvbuf, dest, port, timeout, IB_GSI_PORT_COUNTERS_EXT);
-}
-
-uint8_t *port_performance_ext_reset_via(void *rcvbuf, ib_portid_t * dest,
-                                       int port, unsigned mask,
-                                       unsigned timeout, const void *srcport)
-{
-       return performance_reset_via(rcvbuf, dest, port, mask, timeout,
-                                    IB_GSI_PORT_COUNTERS_EXT, srcport);
-}
-
-uint8_t *port_performance_ext_reset(void *rcvbuf, ib_portid_t * dest, int port,
-                                   unsigned mask, unsigned timeout)
-{
-       return performance_reset(rcvbuf, dest, port, mask, timeout,
-                                IB_GSI_PORT_COUNTERS_EXT);
-}
-
-uint8_t *port_samples_control_query_via(void *rcvbuf, ib_portid_t * dest,
-                                       int port, unsigned timeout,
-                                       const void *srcport)
-{
-       return pma_query_via(rcvbuf, dest, port, timeout,
-                            IB_GSI_PORT_SAMPLES_CONTROL, srcport);
-}
-
-uint8_t *port_samples_control_query(void *rcvbuf, ib_portid_t * dest, int port,
-                                   unsigned timeout)
-{
-       return pma_query(rcvbuf, dest, port, timeout,
-                        IB_GSI_PORT_SAMPLES_CONTROL);
-}
-
-uint8_t *port_samples_result_query_via(void *rcvbuf, ib_portid_t * dest,
-                                      int port, unsigned timeout,
-                                      const void *srcport)
-{
-       return pma_query_via(rcvbuf, dest, port, timeout,
-                            IB_GSI_PORT_SAMPLES_RESULT, srcport);
-}
-
-uint8_t *port_samples_result_query(void *rcvbuf, ib_portid_t * dest, int port,
-                                  unsigned timeout)
-{
-       return pma_query(rcvbuf, dest, port, timeout,
-                        IB_GSI_PORT_SAMPLES_RESULT);
-}
index cdc0aa0..cbd8803 100644 (file)
@@ -34,20 +34,15 @@ EXPORTS
        madrpc_show_errors;\r
        smp_query;\r
        smp_set;\r
+       smp_query_via;\r
        ib_vendor_call;\r
        ib_path_query;\r
        ib_resolve_smlid;\r
        ib_resolve_portid_str;\r
        ib_resolve_self;\r
-       perf_classportinfo_query;\r
-       port_performance_query;\r
-       port_performance_reset;\r
-       port_performance_ext_query;\r
-       port_performance_ext_reset;\r
-       port_samples_control_query;\r
-       port_samples_result_query;\r
        portid2str;\r
        portid2portnum;\r
        str2drpath;\r
        drpath2str;\r
+       xdump\r
 #endif\r
index f944d86..8db9e65 100644 (file)
@@ -22,6 +22,8 @@ IBMAD_1.3 {
                mad_dump_opervls;
                mad_dump_perfcounters;
                mad_dump_perfcounters_ext;
+               mad_dump_perfcounters_xmt_sl;
+               mad_dump_perfcounters_rcv_sl;
                mad_dump_physportstate;
                mad_dump_portcapmask;
                mad_dump_portinfo;
@@ -40,13 +42,8 @@ IBMAD_1.3 {
                mad_set_field64;
                mad_get_array;
                mad_set_array;
-               perf_classportinfo_query;
-               port_performance_query;
-               port_performance_reset;
-               port_performance_ext_query;
-               port_performance_ext_reset;
-               port_samples_control_query;
-               port_samples_result_query;
+               pma_query_via;
+               performance_reset_via;
                mad_build_pkt;
                mad_decode_field;
                mad_encode;
@@ -97,11 +94,5 @@ IBMAD_1.3 {
                ib_resolve_portid_str_via;
                ib_resolve_self_via;
                perf_classportinfo_query_via;
-               port_performance_query_via;
-               port_performance_reset_via;
-               port_performance_ext_query_via;
-               port_performance_ext_reset_via;
-               port_samples_control_query_via;
-               port_samples_result_query_via;
        local: *;
 };