[igt-dev] [PATCH i-g-t 1/6] tests/kms_vblank: Make sure that we have a mode set
Arkadiusz Hiler
arkadiusz.hiler at intel.com
Mon Apr 6 12:38:13 UTC 2020
On Mon, Apr 06, 2020 at 12:11:35PM +0300, Imre Deak wrote:
> On Fri, Apr 03, 2020 at 04:03:01PM +0300, Arkadiusz Hiler wrote:
> > Subtest 'invalid' was depending on a "leftover" mode set by something
> > external (usually fbcon) in order to work.
> >
> > Let's make the test more robust by setting the mode explicitly.
> >
> > Cc: Imre Deak <imre.deak at intel.com>
> > Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler at intel.com>
> > ---
> > tests/kms_vblank.c | 14 ++++++++++++++
> > 1 file changed, 14 insertions(+)
> >
> > diff --git a/tests/kms_vblank.c b/tests/kms_vblank.c
> > index a895ab80..edf8581e 100644
> > --- a/tests/kms_vblank.c
> > +++ b/tests/kms_vblank.c
> > @@ -472,9 +472,22 @@ static void invalid_subtest(data_t *data, int fd)
> > {
> > union drm_wait_vblank vbl;
> > unsigned long valid_flags;
> > + enum pipe pipe;
> > + igt_output_t* output;
> > + bool found = false;
> >
> > igt_display_require_output_on_pipe(&data->display, 0);
>
> Is the above needed still?
nope, removed
> > + /* we need to have a mode set, otherwise we will get EINVAL no matter what */
> > + for_each_pipe_with_single_output(&data->display, pipe, output) {
> > + data->pipe = pipe;
> > + found = true;
> > + break;
> > + }
>
> So far pipe A was assumed. I guess it's better to make it more flexible,
> but then you have to add kmstest_get_vbl_flag() to the request flags
> too.
Yeah, I have blanked on that. I have added "base_flags" that will have
this + DRM_VBLANK_RELATIVE set and use this as the initial value.
You can already see it on Trybot as I am experimenting with a fix for 0
outputs becoming a fail instead of a skip:
https://patchwork.freedesktop.org/patch/360280/?series=75545&rev=1
--
Cheers,
Arek
More information about the igt-dev
mailing list