i915_gem_init_aliasing_ppgtt() loop after 55a254ac63a3ac1867d1501030e7fba69c7d4aeb

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

 



On Thu, Apr 05, 2012 at 03:04:39PM +0300, Konstantin Belousov wrote:
> On Thu, Apr 05, 2012 at 01:55:12PM +0200, Daniel Vetter wrote:
> > On Thu, Apr 5, 2012 at 13:04, Konstantin Belousov <kostikbel at gmail.com> wrote:
> > > it seems that the loop in i915_gem_init_aliasing_ppgtt() over pd_entries
> > > that calculates pt_addr does nothing after the commit 55a254ac in the
> > > !dmar case. Would it be better to move needs_dmar check over the whole
> > > loop ?
> > 
> > For the !dmar case we still need need to compute the physical address
> > with page_to_phys, so I think the loop is needed.
> 
> Does linux' page_to_phys() has side effects ? I just fail to see where the
> pt_addr is used after the calculation.

Oops.

The code indeed recomputes the pt_addr at the new location. Patch to reap
this dead code (and maybe also restructure it to move the if (dmar) check
out) highly welcome.

Yours, Daniel
-- 
Daniel Vetter
Mail: daniel at ffwll.ch
Mobile: +41 (0)79 365 57 48


[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux