Skip to contentSkip to conversation

infiniband-diags: libibnetdisc add port interface

PATCH In review Ira Weiny 1 participant 1 message Jul 20, 2011 InfiniBand

lore
Share & tools
lore

Ira Weiny

author
#0 lore raw

PATCH 1/3 infiniband-diags: libibnetdisc add port interface

Add ability to find port's based on PortGUID and DRPath

---
 libibnetdisc/include/infiniband/ibnetdisc.h |   11 +++
 libibnetdisc/libibnetdisc.ver               |    2 +-
 libibnetdisc/src/ibnetdisc.c                |  112 ++++++++++++++++++++-------
 libibnetdisc/src/libibnetdisc.map           |    3 +
 4 files changed, 98 insertions(+), 30 deletions(-)
libibnetdisc/include/infiniband/ibnetdisc.h +11 -0
index 7b42026..300094e 100644
@@ -213,6 +213,17 @@ IBND_EXPORT void ibnd_iter_nodes_type(ibnd_fabric_t * fabric,
 				     int node_type, void *user_data);
 
 /** =========================================================================
+ * Port operations
+ */
+IBND_EXPORT ibnd_port_t *ibnd_find_port_guid(ibnd_fabric_t * fabric,
+					uint64_t guid);
+IBND_EXPORT ibnd_port_t *ibnd_find_port_dr(ibnd_fabric_t * fabric,
+					char *dr_str);
+typedef void (*ibnd_iter_port_func_t) (ibnd_port_t * port, void *user_data);
+IBND_EXPORT void ibnd_iter_ports(ibnd_fabric_t * fabric,
+				ibnd_iter_port_func_t func, void *user_data);
+
+/** =========================================================================
  * Chassis queries
  */
 IBND_EXPORT uint64_t ibnd_get_chassis_guid(ibnd_fabric_t * fabric,
libibnetdisc/libibnetdisc.ver +1 -1
index 27f922f..8ff2d35 100644
@@ -6,4 +6,4 @@
 # API_REV - advance on any added API
 # RUNNING_REV - advance any change to the vendor files
 # AGE - number of backward versions the API still supports
-LIBVERSION=5:1:0
+LIBVERSION=6:0:1
libibnetdisc/src/ibnetdisc.c +83 -29

123 lines not on this page · raw message

libibnetdisc/src/libibnetdisc.map +3 -0
index 8a56fbb..1c42e7b 100644
@@ -14,5 +14,8 @@ IBNETDISC_1.0 {
 		ibnd_get_chassis_slot_str;
 		ibnd_iter_nodes;
 		ibnd_iter_nodes_type;
+		ibnd_find_port_guid;
+		ibnd_find_port_dr;
+		ibnd_iter_ports;
 	local: *;
 };
Signature · 6 lines
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html