[openib-general] Re: static rate encoding change support

Jack Morgenstein jackm at mellanox.co.il
Mon Apr 3 01:34:25 PDT 2006


On Sunday 02 April 2006 20:43, Roland Dreier wrote:
>  > @@ -435,10 +443,16 @@ int mthca_query_qp(struct ib_qp *ibqp, s
>  >  		goto out;
>  >  	}
>  >
>  > +	if (qp->transport == RC || qp->transport == UC)
>  > +		for (i = 1; i < dev->limits.num_ports; ++i)
>  > +			if ((err = mthca_update_rate(dev,i)))
>  > +				goto out;
>
> I haven't read through all of this very carefully yet, but I'm
> wondering about this.  Why is it necessary to update the rates of all
> the ports on every query QP call?
>
> Any all of this seems like a whole lot of complexity for not much
> value.  If we really care about returning static rate from query QP,
> why not just store away the original state rate passed in through
> modify QP?
>
In memfree, static rate changes are tracked (the original patch) while in 
Tavor, they are not.  Easiest thing to do is to track static rate changes for 
Tavor and memfree both (modification of the original large patch).  Then, you 
can get rid of the port static rate update in query-qp.
I've indicated the required changes below in a new patch.	

(That was one of the reasons I wanted to merge the two patches -- sorry for 
not indicating this).

The merged mthca patch, which tracks static rate changes in Tavor as well,
includes the static-rate changes for Query-QP, and gets rid of the update_rate 
in query-qp,  is below.

- Jack

-----
   Push translation of static rate to HCA format into low-level drivers,
    where it belongs.  For static rate encoding, use encoding of rate
    field from IB standard PathRecord, with addition of value 0, for
    backwards compatibility with current usage.  The changes are:
    
     - Add enum ib_rate to midlayer includes.
     - Get rid of static rate translation in IPoIB; just use static rate
       directly from Path and MulticastGroup records.
     - Update mthca driver to translate absolute static rate into the
       format used by hardware.





More information about the general mailing list