[Intel-gfx] [PATCH i-g-t] tests/kms_frontbuffer_tracking: Correctly handle debugfs errors

Chris Wilson chris at chris-wilson.co.uk
Fri Dec 15 12:59:55 UTC 2017


Quoting Joonas Lahtinen (2017-12-04 10:45:13)
> On Tue, 2017-11-28 at 17:29 +0000, Chris Wilson wrote:
> > Quoting Michal Wajdeczko (2017-11-28 17:01:15)
> > > In commit 3f6ae7b19 ("igt/kms_frontbuffer_tracking: Keep the debugfs
> > > dir around") we introduced custom variant of __igt_debugfs_read function
> > > that fires assert when debugfs returns an error. Replace that assert
> > > with proper error handling to allow use of errors like -ENODEV.
> > 
> > Like ENODEV or just ENODEV?
> > 
> > Oh, it appears I goofed in c5da0662d1c0 and didn't change the open error
> > from a bool to an int error code. You could also take the opportunity to
> > then return -errno.
> > 
> > And here we can debate whether you want to use
> > 
> > if (len < 0) {
> >       igt_assert_eq(len, -ENODEV);
> >       len = 0;
> > }
> 
> Let's be explicit at this time, can you resend (with the R-b and this
> change), Michal. I'll then merge this and the kernel patch.

And v2 was applied.
-Chris


More information about the Intel-gfx mailing list