[igt-dev] [PATCH i-g-t] igt/kms_flip_tiling: Check GEM availability before use

Chris Wilson chris at chris-wilson.co.uk
Thu Jul 12 13:05:50 UTC 2018


Quoting Ville Syrjälä (2018-07-12 14:00:31)
> On Thu, Jul 12, 2018 at 11:12:45AM +0100, Chris Wilson wrote:
> > We use the GPU to convert between tiling formats, indirectly via the
> > call to igt_create_pattern_fb. So before we try and execute commands on
> > the GPU, we should check that the GPU is available.
> 
> Should this one be in the actualy spot in igt_fb.c where we do
> the gem stuff? I could imagine other drivers might want to add
> their own mechanisms there.

Maybe... There's a catch in that igt_require_gem() is quite heavy and
does things (reset the gpu, reset seqno) that you ordinarily don't want
to happen in the middle of the test (and can cause issues if caught
unaware, in particular if you happen to have a spinbatch in flight).

> Or we add some kind of igt_require_fb() to indicate igt_fb
> will be used?

Yup, something along those lines will be better.
-Chris


More information about the igt-dev mailing list