[openib-general] Re: [PATCH] (repost) no qp lock on poll, separate sq/rq locks

Michael S. Tsirkin mst at mellanox.co.il
Fri Feb 25 05:02:21 PST 2005


Quoting r. Michael S. Tsirkin <mst at mellanox.co.il>:
> Subject: Re: [PATCH] (repost) no qp lock on poll, separate sq/rq locks
> 
> Quoting r. Roland Dreier <roland at topspin.com>:
> > Subject: Re: [openib-general] [PATCH] (repost) no qp lock on poll, separate sq/rq locks
> > 
> > Ugh, I think I missed something when I thought about this the first
> > time around.  It seems the test for WQ overflow assumes that all WQs
> > have a power-of-2 size, which we currently don't enforce for Tavor
> > mode.  It seems there are two possible solutions:
> > 
> >   Round up WQ sizes for Tavor as well.  I don't like this because it
> >   could potentially use a lot of extra memory.
> > 
> >   Or, add one more counter back into the WQ struct so we can keep
> >   track of both the next index to use as well as the total number of
> >   WQEs posted in Tavor mode (we still only need one counter in
> >   mem-free mode).
> > 
> > I implemented the second option.  Does this patch look reasonable?
> > 
> >  - R.
> > 
> 
> True, I forgot that qp size may not be a power of 2 for tavor.
> Good catch.
> 
> But, it seems to me your patch does not handle unsignaled WQEs, since
> tail is incremented by 1 on each completion.
> I propose reverting, and applying the following simple patch.
> 

I forgot the SOB for that patch. Here it is:

Signed-off-by: Michael S. Tsirkin <mst at mellanox.co.il>

-- 
MST - Michael S. Tsirkin



More information about the general mailing list