> Use netevent notification for sensing that a change has happened in the IP
> stack,
> then scan the rdma-cm IDs list to see if there is an ID that is "misaligned"
> in that respect with the IP stack, and disconnect it, in case this is what
> the
> user asked to when setting an ha mode for the ID.
this seems like a strange "HA" feature -- to disconnect connections that
otherwise would continue operating. What is the use case/use scenario?
> + list_for_each_entry(cma_dev, &dev_list, list)
> + list_for_each_entry(id_priv, &cma_dev->id_list, list) {
> + dev_addr = &id_priv->id.route.addr.dev_addr;
> + if (!memcmp(dev_addr->src_netdev_name, ndev->name,
> IFNAMSIZ) &&
> + memcmp(dev_addr->src_dev_addr, ndev->dev_addr,
> ndev->addr_len))
> + if (id_priv->ha_mode ==
> RDMA_ALIGN_WITH_NETDEVICE)
> +
> schedule_work(&id_priv->ha_work);
> + }
This looks horribly racy/incorrect against RDMA device removal, CMA ID
destruction and netdev renaming.
- R.
_______________________________________________
general mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general
To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general