Re: [Intel-gfx] [PATCH] drm/i915: Mark the final obj->pages sg entry as last

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jun 09, 2015 at 10:53:23AM +0100, Chris Wilson wrote:
> > >  		if (!i || page_to_pfn(page) != last_pfn + 1) {
> > >  			if (i)
> > > -				sg = sg_next(sg);
> > > +				sg = sg_next(end = sg);
> > 
> > But this looks incorrect to me, sg points now to the last element for
> > which we set the page below and end points to one before the last. Or
> > I'm (still) missing something..
> 
> Nah, this was a change I made to try and reduce te patch size.
> Originally I did sg_set_page(); end = sg; but then thought I could avoid
> resetting end to the same sg in a few cases.

And without the complication of swiotlb_nr_tlb(), then sg after the loop
is pointing to the last set page anyway. The current code is correct,
sorry for the noise.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]