]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/core: Add iterator over ib_devices
authorLeon Romanovsky <leonro@mellanox.com>
Mon, 19 Jun 2017 11:04:56 +0000 (14:04 +0300)
committerLeon Romanovsky <leon@kernel.org>
Thu, 10 Aug 2017 10:21:54 +0000 (13:21 +0300)
commit1c7abdc9f3131f1a65565e3d1aff0eadde9350c9
treecf311a3832440d76f745c72842ae03633d18552c
parentebbf88b6c796ffc2695ccaea32b6c9136baf8287
RDMA/core: Add iterator over ib_devices

The coming nldev needs to iterate over all IB devices in the system
and in order to not expose the ib_devices list outside the devices.c,
it is necessary to provide function iterator.

Current version is written explicitly for nldev callback to avoid
over-engineering at this stage, but it can be easily extended for
other types.

Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Reviewed-by: Steve Wise <swise@opengridcomputing.com>
drivers/infiniband/core/core_priv.h
drivers/infiniband/core/device.c