Re: [PATCH v2 2/5] drm/i915: Add a new "remapped" gtt_view

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

 



Quoting Ville Syrjälä (2018-09-14 13:58:15)
> On Thu, Sep 13, 2018 at 09:19:00PM +0100, Chris Wilson wrote:
> > Quoting Ville Syrjala (2018-09-13 21:01:37)
> > > diff --git a/drivers/gpu/drm/i915/selftests/i915_vma.c b/drivers/gpu/drm/i915/selftests/i915_vma.c
> > > index ffa74290e054..4fc49c27f13c 100644
> > > --- a/drivers/gpu/drm/i915/selftests/i915_vma.c
> > > +++ b/drivers/gpu/drm/i915/selftests/i915_vma.c
> > > @@ -395,8 +395,8 @@ assert_rotated(struct drm_i915_gem_object *obj,
> > >         return sg;
> > >  }
> > >  
> > > -static unsigned int rotated_size(const struct intel_rotation_plane_info *a,
> > > -                                const struct intel_rotation_plane_info *b)
> > > +static unsigned int rotated_size(const struct intel_remapped_plane_info *a,
> > > +                                const struct intel_remapped_plane_info *b)
> > >  {
> > >         return a->width * a->height + b->width * b->height;
> > >  }
> > > @@ -406,7 +406,7 @@ static int igt_vma_rotate(void *arg)
> > >         struct drm_i915_private *i915 = arg;
> > >         struct i915_address_space *vm = &i915->ggtt.vm;
> > >         struct drm_i915_gem_object *obj;
> > > -       const struct intel_rotation_plane_info planes[] = {
> > > +       const struct intel_remapped_plane_info planes[] = {
> > >                 { .width = 1, .height = 1, .stride = 1 },
> > >                 { .width = 2, .height = 2, .stride = 2 },
> > >                 { .width = 4, .height = 4, .stride = 4 },
> > 
> > Could we prove our remapping vma works by doing an i915_vma_pin_iomap()
> > and checking that a write into each page ends up in the correct address?
> 
> So write through a fence and check it lands in the right place?
> Seems doable. Though we'd have to allow a fence for these vmas,
> which I guess isn't really a problem.

We don't need the fence for a linear view. For the short term, I'd
PIN_MAPPABLE and bludgeon can-map (although that's all that would
required for us to get a fence...) so that i915_vma_pin_iomap works.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




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

  Powered by Linux