[PATCH v8 RFC 1/3] sparc: Break up monolithic iommu table/lock into finer graularity pools and lock

Sowmini Varadhan sowmini.varadhan at oracle.com
Sat Apr 4 05:28:52 AEDT 2015



Just want to confirm:

> > + again:
> > +	if (pass == 0 && handle && *handle &&
> > +	    (*handle >= pool->start) && (*handle < pool->end))
> > +		start = *handle;
> > +	else
> > +		start = pool->hint;
> 
> Now this means "handle" might be < pool->hint, in that case you also
> need a lazy flush. Or rather only if the resulting alloc is. My
         :

> > +		} else {
> > +			/* give up */
> > +			n = DMA_ERROR_CODE;
> > +			goto bail;
> > +		}
> > +	}
> 
> Here, make this something like:
> 
> 	} else if (end < pool->hint)
> 		need_flush = true;

you mean 

 	} else if (start < pool->hint)

right?  (so I'm not missing some corner-case that you are thinking
about here)

--Sowmini
 


More information about the Linuxppc-dev mailing list