Re: [igt-dev] [PATCH i-g-t 2/2] tests: Skip testdisplay when KMS is disabled

Souza, Jose
2018-10-15T21:52:27Z

On Sat, 2018-10-13 at 11:25 +0100, Chris Wilson wrote:
> Quoting José Roberto de Souza (2018-10-12 22:28:27)
> > This test should be skiped when KMS is disabled.
> >
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
> > ---
> > tests/testdisplay.c | 5 +----
> > 1 file changed, 1 insertion(+), 4 deletions(-)
>
> Testdisplay is really an oddball that doesn't belong amid the igt
> suite
> of tests/
>
> > diff --git a/tests/testdisplay.c b/tests/testdisplay.c
> > index b13c3d70..9972fb3c 100644
> > --- a/tests/testdisplay.c
> > +++ b/tests/testdisplay.c
> > @@ -457,10 +457,7 @@ int update_display(bool probe)
> > int c;
> >
> > resources = drmModeGetResources(drm_fd);
> > - if (!resources) {
> > - igt_warn("drmModeGetResources failed: %s\n",
> > strerror(errno));
> > - return 0;
> > - }
> > + igt_require(resources);
>
> Hmm, looks like there's a drmSetClientCap() that would fail earlier.
> I
> think ideally we would pass resources into the function.
>
> For now, this is a simple improvement
> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
>
> Fwiw,
> https://patchwork.freedesktop.org/patch/254962/
> https://patchwork.freedesktop.org/patch/254961/
> are the remaining issues for BAT + no display.

Thanks. Could someone merge this 2?
I'm waiting the GitLab migration to ask commit rights.

> -Chris