summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorChiara Meiohas <cmeiohas@nvidia.com>2024-10-31 15:36:51 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-12-05 14:02:08 +0100
commit3a03f5f2e05cf30501c7b3258aba7e3158e5aa3b (patch)
tree144691fbc80d3b0dc227915930913ee89d6892ad /include
parent344f598db1fc607544beff6e503f1304f2fb64fa (diff)
downloadlinux-3a03f5f2e05cf30501c7b3258aba7e3158e5aa3b.tar.gz
linux-3a03f5f2e05cf30501c7b3258aba7e3158e5aa3b.tar.bz2
linux-3a03f5f2e05cf30501c7b3258aba7e3158e5aa3b.zip
RDMA/core: Implement RoCE GID port rescan and export delete function
[ Upstream commit af7a35bf6c36a77624d3abe46b3830b7c2a5f20c ] rdma_roce_rescan_port() scans all network devices in the system and adds the gids if relevant to the RoCE device port. When not in bonding mode it adds the GIDs of the netdevice in this port. When in bonding mode it adds the GIDs of both the port's netdevice and the bond master netdevice. Export roce_del_all_netdev_gids(), which removes all GIDs associated with a specific netdevice for a given port. Signed-off-by: Chiara Meiohas <cmeiohas@nvidia.com> Link: https://patch.msgid.link/674d498da4637a1503ff1367e28bd09ff942fd5e.1730381292.git.leon@kernel.org Signed-off-by: Leon Romanovsky <leon@kernel.org> Stable-dep-of: 0bd2c61df953 ("RDMA/mlx5: Ensure active slave attachment to the bond IB device") Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include')
-rw-r--r--include/rdma/ib_verbs.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h
index 9cb8b5fe7eee..67551133b522 100644
--- a/include/rdma/ib_verbs.h
+++ b/include/rdma/ib_verbs.h
@@ -4734,6 +4734,9 @@ ib_get_vector_affinity(struct ib_device *device, int comp_vector)
* @device: the rdma device
*/
void rdma_roce_rescan_device(struct ib_device *ibdev);
+void rdma_roce_rescan_port(struct ib_device *ib_dev, u32 port);
+void roce_del_all_netdev_gids(struct ib_device *ib_dev,
+ u32 port, struct net_device *ndev);
struct ib_ucontext *ib_uverbs_get_ucontext_file(struct ib_uverbs_file *ufile);