]> git.openfabrics.org - ~shefty/libibverbs.git/commitdiff
List all devices in ibv_devinfo
authorDotan Barak <dotanb@mellanox.co.il>
Mon, 23 Jan 2006 05:07:09 +0000 (05:07 +0000)
committerRoland Dreier <rolandd@cisco.com>
Thu, 9 Nov 2006 19:35:58 +0000 (11:35 -0800)
Make ibv_devinfo list all IB devices by default, rather than the first
device only.

Signed-off-by: Dotan Barak <dotanb@mellanox.co.il>
Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
ChangeLog
examples/devinfo.c

index c5423f5298b9ce00db7f10ceff4b391f4a480c4e..25caafa40c43dd86bd91d5d61f5158cab091cd69 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2006-01-22  Dotan Barak  <dotanb@mellanox.co.il>
+
+       * examples/devinfo.c (main): Make ibv_devinfo list all IB devices
+       by default, rather than the first device only.
+
 2006-01-20  Roland Dreier  <rdreier@cisco.com>
 
        * examples/rc_pingpong.c, examples/uc_pingpong.c,
index 0e3e02022c23f26840c11effe2678cb825e0618b..1e75bf4c58e5ccdeb125aeee54886459435700b5 100644 (file)
@@ -396,7 +396,11 @@ int main(int argc, char *argv[])
                        fprintf(stderr, "No IB devices found\n");
                        return -1;
                }
-               ret |= print_hca_cap(*dev_list, ib_port);
+
+               while (*dev_list) {
+                       ret |= print_hca_cap(*dev_list, ib_port);
+                       ++dev_list;
+               }
        }
 
        if (ib_devname)