[ewg] OFED-1.5.1 failure over iWarp
Steve Wise
swise at opengridcomputing.com
Wed Feb 3 07:20:05 PST 2010
> diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c
> index a2d5aad..76dce2b 100644
> --- a/drivers/infiniband/core/cma.c
> +++ b/drivers/infiniband/core/cma.c
> @@ -348,15 +348,28 @@ static int cma_acquire_dev(struct rdma_id_private *id_priv)
> union ib_gid gid;
> int ret = -ENODEV;
>
> - rdma_addr_get_sgid(dev_addr, &gid);
> - list_for_each_entry(cma_dev, &dev_list, list) {
> - ret = ib_find_cached_gid(cma_dev->device, &gid,
> - &id_priv->id.port_num, NULL);
> - if (!ret) {
> - cma_attach_to_dev(id_priv, cma_dev);
> - break;
> + if (dev_addr->dev_type != ARPHRD_INFINIBAND) {
> + rocee_addr_get_sgid(dev_addr, &gid);
> + list_for_each_entry(cma_dev, &dev_list, list) {
> + ret = ib_find_cached_gid(cma_dev->device, &gid,
> + &id_priv->id.port_num, NULL);
> + if (!ret)
> + break;
> + }
>
The above if statement is true for iwarp devices, so this patch is just
wrong. rocee__addr_get_sgid() should only be used for ROCEE
interfaces, correct?
> + } else {
> + memcpy(&gid, dev_addr->src_dev_addr +
> + rdma_addr_gid_offset(dev_addr), sizeof gid);
> + list_for_each_entry(cma_dev, &dev_list, list) {
> + ret = ib_find_cached_gid(cma_dev->device, &gid,
> + &id_priv->id.port_num, NULL);
> + if (!ret)
> + break;
> }
> }
> +
> + if (!ret)
> + cma_attach_to_dev(id_priv, cma_dev);
> +
> return ret;
> }
>
>
More information about the ewg
mailing list