summaryrefslogtreecommitdiffstats
path: root/src/plugins/rdma/format.c
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2019-03-28 23:34:56 +0100
committerFlorin Coras <florin.coras@gmail.com>2019-03-29 00:23:57 +0000
commit96d4e533638f585feb606e04b837396be5c503ed (patch)
tree482e4d10c12c0bc22e4badc71e35c965e395d796 /src/plugins/rdma/format.c
parenta03d18238350f9941357caca28957395ad737810 (diff)
rdma: add option to specify inteface name
Change-Id: Ic6244511b88bdd42756f74e3163a70b8014e8547 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/plugins/rdma/format.c')
-rw-r--r--src/plugins/rdma/format.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/plugins/rdma/format.c b/src/plugins/rdma/format.c
index 7ef65d43957..fbd40676639 100644
--- a/src/plugins/rdma/format.c
+++ b/src/plugins/rdma/format.c
@@ -29,6 +29,9 @@ format_rdma_device_name (u8 * s, va_list * args)
rdma_main_t *rm = &rdma_main;
rdma_device_t *rd = vec_elt_at_index (rm->devices, i);
+ if (rd->name)
+ return format (s, "%s", rd->name);
+
s = format (s, "rdma-%u", rd->dev_instance);
return s;
}