All of lore.kernel.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check
@ 2018-11-06 16:19 Ville Syrjala
  2018-11-06 16:19 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE Ville Syrjala
                   ` (5 more replies)
  0 siblings, 6 replies; 12+ messages in thread
From: Ville Syrjala @ 2018-11-06 16:19 UTC (permalink / raw)
  To: igt-dev

From: Ville Syrjälä <ville.syrjala@linux.intel.com>

Deal with frame counter wraparound correcrtly.

Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 lib/igt_debugfs.c | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/lib/igt_debugfs.c b/lib/igt_debugfs.c
index a3aca8466658..70874416d128 100644
--- a/lib/igt_debugfs.c
+++ b/lib/igt_debugfs.c
@@ -975,6 +975,16 @@ void igt_pipe_crc_get_single(igt_pipe_crc_t *pipe_crc, igt_crc_t *crc)
 	crc_sanity_checks(crc);
 }
 
+static bool vbl_after_eq(uint32_t a, uint32_t b)
+{
+	return (int32_t)(a - b) >= 0;
+}
+
+static bool vbl_before_eq(uint32_t a, uint32_t b)
+{
+	return vbl_after_eq(b, a);
+}
+
 /**
  * igt_pipe_crc_get_current:
  * @drm_fd: Pointer to drm fd for vblank counter
@@ -999,7 +1009,7 @@ igt_pipe_crc_get_current(int drm_fd, igt_pipe_crc_t *pipe_crc, igt_crc_t *crc)
 			igt_pipe_crc_get_single(pipe_crc, crc);
 			return;
 		}
-	} while (crc->frame <= vblank);
+	} while (vbl_before_eq(crc->frame, vblank));
 
 	crc_sanity_checks(crc);
 }
-- 
2.18.1

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE
  2018-11-06 16:19 [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Ville Syrjala
@ 2018-11-06 16:19 ` Ville Syrjala
  2018-11-06 16:38   ` Chris Wilson
  2018-11-06 16:19 ` [igt-dev] [PATCH i-g-t 3/3] tests/kms_flip: " Ville Syrjala
                   ` (4 subsequent siblings)
  5 siblings, 1 reply; 12+ messages in thread
From: Ville Syrjala @ 2018-11-06 16:19 UTC (permalink / raw)
  To: igt-dev; +Cc: Daniel Vetter

From: Ville Syrjälä <ville.syrjala@linux.intel.com>

Asking for the initial vblank count by specifying and absolute vblank count of 0
doesn't make much sense. Switch to a relative query instead.

It doesn't look like we care about lining up on the first vblank boundary so
we can just drop the NEXTONMISS flag. Only the relative timestamps of the
events will matter.

v2: Drop the NEXTONMISS (Daniel)

Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 tests/kms_setmode.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/kms_setmode.c b/tests/kms_setmode.c
index 681496044f5d..acd606cd5b5e 100644
--- a/tests/kms_setmode.c
+++ b/tests/kms_setmode.c
@@ -434,7 +434,7 @@ static void check_timings(int crtc_idx, const drmModeModeInfo *kmode)
 
 	memset(&wait, 0, sizeof(wait));
 	wait.request.type = kmstest_get_vbl_flag(crtc_idx);
-	wait.request.type |= DRM_VBLANK_ABSOLUTE | DRM_VBLANK_NEXTONMISS;
+	wait.request.type |= DRM_VBLANK_RELATIVE;
 	do_or_die(drmWaitVBlank(drm_fd, &wait));
 
 	last_seq = wait.reply.sequence;
-- 
2.18.1

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [igt-dev] [PATCH i-g-t 3/3] tests/kms_flip: Request the initial vbl count with RELATIVE instead of ABSOLUTE
  2018-11-06 16:19 [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Ville Syrjala
  2018-11-06 16:19 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE Ville Syrjala
@ 2018-11-06 16:19 ` Ville Syrjala
  2018-11-06 16:58 ` [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Daniel Vetter
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 12+ messages in thread
From: Ville Syrjala @ 2018-11-06 16:19 UTC (permalink / raw)
  To: igt-dev; +Cc: Daniel Vetter

From: Ville Syrjälä <ville.syrjala@linux.intel.com>

Asking for the initial vblank count by specifying and absolute vblank count of 0
doesn't make much sense. Switch to a relative query instead.

It doesn't look like we care about lining up on the first vblank boundary so
we can just drop the NEXTONMISS flag. Only the relative timestamps of the
events will matter.

v2: Drop the NEXTONMISS (Daniel)

Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 tests/kms_flip.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/kms_flip.c b/tests/kms_flip.c
index f28272dd1e3f..10a72bf0d1c3 100644
--- a/tests/kms_flip.c
+++ b/tests/kms_flip.c
@@ -1125,7 +1125,7 @@ static void calibrate_ts(struct test_output *o, int crtc_idx)
 
 	memset(&wait, 0, sizeof(wait));
 	wait.request.type = kmstest_get_vbl_flag(crtc_idx);
-	wait.request.type |= DRM_VBLANK_ABSOLUTE | DRM_VBLANK_NEXTONMISS;
+	wait.request.type |= DRM_VBLANK_RELATIVE;
 	do_or_die(drmWaitVBlank(drm_fd, &wait));
 
 	last_seq = wait.reply.sequence;
-- 
2.18.1

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE
  2018-11-06 16:19 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE Ville Syrjala
@ 2018-11-06 16:38   ` Chris Wilson
  2018-11-06 16:57     ` Daniel Vetter
  2018-11-06 18:40     ` Ville Syrjälä
  0 siblings, 2 replies; 12+ messages in thread
From: Chris Wilson @ 2018-11-06 16:38 UTC (permalink / raw)
  To: Ville Syrjala, igt-dev; +Cc: Daniel Vetter

Quoting Ville Syrjala (2018-11-06 16:19:42)
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> 
> Asking for the initial vblank count by specifying and absolute vblank count of 0
> doesn't make much sense. Switch to a relative query instead.
> 
> It doesn't look like we care about lining up on the first vblank boundary so
> we can just drop the NEXTONMISS flag. Only the relative timestamps of the
> events will matter.

I had to do a double take as quite often we care about submitting the
workload before the next vblank, but no you are quite correct in this
case so long as the next request is submitted within the next frame it
should be fine and not miss a response.

To catch the error during setup, we could do something like

	for (n = 0; n < CALIBRATE_TS_STEPS; n++) {
		drmVBlank check;

		++wait.request.sequence;
		do_or_die(drmWaitVBlank(drm_fd, &wait));

		/* Double check that haven't already missed the vblank */
		memset(&check, 0, sizeof(check));
		check.request.type = kmstest_get_vblank_flag(crtc_idx);
		check.request.type |= DRM_VBLANK_RELATIVE;
		do_or_die(drmWaitVBlank(drm_fd, &check));

		igt_assert(!vblank_after(check.reply.sequence, wait.request.sequence));
	}

> 
> v2: Drop the NEXTONMISS (Daniel)
> 
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>

For both, but do consider the value of checking our setup.
-Chris
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE
  2018-11-06 16:38   ` Chris Wilson
@ 2018-11-06 16:57     ` Daniel Vetter
  2018-11-06 17:02       ` Ville Syrjälä
  2018-11-06 18:40     ` Ville Syrjälä
  1 sibling, 1 reply; 12+ messages in thread
From: Daniel Vetter @ 2018-11-06 16:57 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev, Daniel Vetter

On Tue, Nov 06, 2018 at 04:38:48PM +0000, Chris Wilson wrote:
> Quoting Ville Syrjala (2018-11-06 16:19:42)
> > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > 
> > Asking for the initial vblank count by specifying and absolute vblank count of 0
> > doesn't make much sense. Switch to a relative query instead.
> > 
> > It doesn't look like we care about lining up on the first vblank boundary so
> > we can just drop the NEXTONMISS flag. Only the relative timestamps of the
> > events will matter.
> 
> I had to do a double take as quite often we care about submitting the
> workload before the next vblank, but no you are quite correct in this
> case so long as the next request is submitted within the next frame it
> should be fine and not miss a response.
> 
> To catch the error during setup, we could do something like
> 
> 	for (n = 0; n < CALIBRATE_TS_STEPS; n++) {
> 		drmVBlank check;
> 
> 		++wait.request.sequence;
> 		do_or_die(drmWaitVBlank(drm_fd, &wait));
> 
> 		/* Double check that haven't already missed the vblank */
> 		memset(&check, 0, sizeof(check));
> 		check.request.type = kmstest_get_vblank_flag(crtc_idx);
> 		check.request.type |= DRM_VBLANK_RELATIVE;
> 		do_or_die(drmWaitVBlank(drm_fd, &check));
> 
> 		igt_assert(!vblank_after(check.reply.sequence, wait.request.sequence));
> 	}
> 
> > 
> > v2: Drop the NEXTONMISS (Daniel)

I have no recollection of this, but comparing with
drm_wait_vblank_is_query() in the kernel this checks out. Also

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>

on both.
-Daniel

> > 
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
> 
> For both, but do consider the value of checking our setup.
> -Chris

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check
  2018-11-06 16:19 [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Ville Syrjala
  2018-11-06 16:19 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE Ville Syrjala
  2018-11-06 16:19 ` [igt-dev] [PATCH i-g-t 3/3] tests/kms_flip: " Ville Syrjala
@ 2018-11-06 16:58 ` Daniel Vetter
  2018-11-06 17:11 ` Chris Wilson
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 12+ messages in thread
From: Daniel Vetter @ 2018-11-06 16:58 UTC (permalink / raw)
  To: Ville Syrjala; +Cc: igt-dev

On Tue, Nov 06, 2018 at 06:19:41PM +0200, Ville Syrjala wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> 
> Deal with frame counter wraparound correcrtly.
> 
> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>

> ---
>  lib/igt_debugfs.c | 12 +++++++++++-
>  1 file changed, 11 insertions(+), 1 deletion(-)
> 
> diff --git a/lib/igt_debugfs.c b/lib/igt_debugfs.c
> index a3aca8466658..70874416d128 100644
> --- a/lib/igt_debugfs.c
> +++ b/lib/igt_debugfs.c
> @@ -975,6 +975,16 @@ void igt_pipe_crc_get_single(igt_pipe_crc_t *pipe_crc, igt_crc_t *crc)
>  	crc_sanity_checks(crc);
>  }
>  
> +static bool vbl_after_eq(uint32_t a, uint32_t b)
> +{
> +	return (int32_t)(a - b) >= 0;
> +}
> +
> +static bool vbl_before_eq(uint32_t a, uint32_t b)
> +{
> +	return vbl_after_eq(b, a);
> +}
> +
>  /**
>   * igt_pipe_crc_get_current:
>   * @drm_fd: Pointer to drm fd for vblank counter
> @@ -999,7 +1009,7 @@ igt_pipe_crc_get_current(int drm_fd, igt_pipe_crc_t *pipe_crc, igt_crc_t *crc)
>  			igt_pipe_crc_get_single(pipe_crc, crc);
>  			return;
>  		}
> -	} while (crc->frame <= vblank);
> +	} while (vbl_before_eq(crc->frame, vblank));
>  
>  	crc_sanity_checks(crc);
>  }
> -- 
> 2.18.1
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE
  2018-11-06 16:57     ` Daniel Vetter
@ 2018-11-06 17:02       ` Ville Syrjälä
  0 siblings, 0 replies; 12+ messages in thread
From: Ville Syrjälä @ 2018-11-06 17:02 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: igt-dev

On Tue, Nov 06, 2018 at 05:57:06PM +0100, Daniel Vetter wrote:
> On Tue, Nov 06, 2018 at 04:38:48PM +0000, Chris Wilson wrote:
> > Quoting Ville Syrjala (2018-11-06 16:19:42)
> > > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > > 
> > > Asking for the initial vblank count by specifying and absolute vblank count of 0
> > > doesn't make much sense. Switch to a relative query instead.
> > > 
> > > It doesn't look like we care about lining up on the first vblank boundary so
> > > we can just drop the NEXTONMISS flag. Only the relative timestamps of the
> > > events will matter.
> > 
> > I had to do a double take as quite often we care about submitting the
> > workload before the next vblank, but no you are quite correct in this
> > case so long as the next request is submitted within the next frame it
> > should be fine and not miss a response.
> > 
> > To catch the error during setup, we could do something like
> > 
> > 	for (n = 0; n < CALIBRATE_TS_STEPS; n++) {
> > 		drmVBlank check;
> > 
> > 		++wait.request.sequence;
> > 		do_or_die(drmWaitVBlank(drm_fd, &wait));
> > 
> > 		/* Double check that haven't already missed the vblank */
> > 		memset(&check, 0, sizeof(check));
> > 		check.request.type = kmstest_get_vblank_flag(crtc_idx);
> > 		check.request.type |= DRM_VBLANK_RELATIVE;
> > 		do_or_die(drmWaitVBlank(drm_fd, &check));
> > 
> > 		igt_assert(!vblank_after(check.reply.sequence, wait.request.sequence));
> > 	}
> > 
> > > 
> > > v2: Drop the NEXTONMISS (Daniel)
> 
> I have no recollection of this, but comparing with
> drm_wait_vblank_is_query() in the kernel this checks out. Also

It's an oldie :) Spotted while trawling patchwork for ancient treasures.

> 
> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> 
> on both.
> -Daniel
> 
> > > 
> > > Cc: Daniel Vetter <daniel@ffwll.ch>
> > > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
> > 
> > For both, but do consider the value of checking our setup.
> > -Chris
> 
> -- 
> Daniel Vetter
> Software Engineer, Intel Corporation
> http://blog.ffwll.ch

-- 
Ville Syrjälä
Intel
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check
  2018-11-06 16:19 [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Ville Syrjala
                   ` (2 preceding siblings ...)
  2018-11-06 16:58 ` [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Daniel Vetter
@ 2018-11-06 17:11 ` Chris Wilson
  2018-11-07 19:19 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/3] " Patchwork
  2018-11-08  7:20 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
  5 siblings, 0 replies; 12+ messages in thread
From: Chris Wilson @ 2018-11-06 17:11 UTC (permalink / raw)
  To: Ville Syrjala, igt-dev

Quoting Ville Syrjala (2018-11-06 16:19:41)
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> 
> Deal with frame counter wraparound correcrtly.
> 
> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
>  lib/igt_debugfs.c | 12 +++++++++++-
>  1 file changed, 11 insertions(+), 1 deletion(-)
> 
> diff --git a/lib/igt_debugfs.c b/lib/igt_debugfs.c
> index a3aca8466658..70874416d128 100644
> --- a/lib/igt_debugfs.c
> +++ b/lib/igt_debugfs.c
> @@ -975,6 +975,16 @@ void igt_pipe_crc_get_single(igt_pipe_crc_t *pipe_crc, igt_crc_t *crc)
>         crc_sanity_checks(crc);
>  }
>  
> +static bool vbl_after_eq(uint32_t a, uint32_t b)
> +{
> +       return (int32_t)(a - b) >= 0;
> +}
> +
> +static bool vbl_before_eq(uint32_t a, uint32_t b)
> +{
> +       return vbl_after_eq(b, a);
> +}

These seem like widely useful functions.

igt_vblank_passed() ?

For now,
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
-Chris
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE
  2018-11-06 16:38   ` Chris Wilson
  2018-11-06 16:57     ` Daniel Vetter
@ 2018-11-06 18:40     ` Ville Syrjälä
  2018-11-06 19:27       ` Chris Wilson
  1 sibling, 1 reply; 12+ messages in thread
From: Ville Syrjälä @ 2018-11-06 18:40 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev, Daniel Vetter

On Tue, Nov 06, 2018 at 04:38:48PM +0000, Chris Wilson wrote:
> Quoting Ville Syrjala (2018-11-06 16:19:42)
> > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > 
> > Asking for the initial vblank count by specifying and absolute vblank count of 0
> > doesn't make much sense. Switch to a relative query instead.
> > 
> > It doesn't look like we care about lining up on the first vblank boundary so
> > we can just drop the NEXTONMISS flag. Only the relative timestamps of the
> > events will matter.
> 
> I had to do a double take as quite often we care about submitting the
> workload before the next vblank, but no you are quite correct in this
> case so long as the next request is submitted within the next frame it
> should be fine and not miss a response.
> 
> To catch the error during setup, we could do something like
> 
> 	for (n = 0; n < CALIBRATE_TS_STEPS; n++) {
> 		drmVBlank check;
> 
> 		++wait.request.sequence;
> 		do_or_die(drmWaitVBlank(drm_fd, &wait));
> 
> 		/* Double check that haven't already missed the vblank */
> 		memset(&check, 0, sizeof(check));
> 		check.request.type = kmstest_get_vblank_flag(crtc_idx);
> 		check.request.type |= DRM_VBLANK_RELATIVE;
> 		do_or_die(drmWaitVBlank(drm_fd, &check));
> 
> 		igt_assert(!vblank_after(check.reply.sequence, wait.request.sequence));
> 	}

Isn't the 'igt_assert_eq(ev.sequence, last_seq + 1);' sufficient
to catch that?

> 
> > 
> > v2: Drop the NEXTONMISS (Daniel)
> > 
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
> 
> For both, but do consider the value of checking our setup.
> -Chris

-- 
Ville Syrjälä
Intel
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE
  2018-11-06 18:40     ` Ville Syrjälä
@ 2018-11-06 19:27       ` Chris Wilson
  0 siblings, 0 replies; 12+ messages in thread
From: Chris Wilson @ 2018-11-06 19:27 UTC (permalink / raw)
  To: Ville Syrjälä; +Cc: igt-dev, Daniel Vetter

Quoting Ville Syrjälä (2018-11-06 18:40:03)
> On Tue, Nov 06, 2018 at 04:38:48PM +0000, Chris Wilson wrote:
> > Quoting Ville Syrjala (2018-11-06 16:19:42)
> > > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > > 
> > > Asking for the initial vblank count by specifying and absolute vblank count of 0
> > > doesn't make much sense. Switch to a relative query instead.
> > > 
> > > It doesn't look like we care about lining up on the first vblank boundary so
> > > we can just drop the NEXTONMISS flag. Only the relative timestamps of the
> > > events will matter.
> > 
> > I had to do a double take as quite often we care about submitting the
> > workload before the next vblank, but no you are quite correct in this
> > case so long as the next request is submitted within the next frame it
> > should be fine and not miss a response.
> > 
> > To catch the error during setup, we could do something like
> > 
> >       for (n = 0; n < CALIBRATE_TS_STEPS; n++) {
> >               drmVBlank check;
> > 
> >               ++wait.request.sequence;
> >               do_or_die(drmWaitVBlank(drm_fd, &wait));
> > 
> >               /* Double check that haven't already missed the vblank */
> >               memset(&check, 0, sizeof(check));
> >               check.request.type = kmstest_get_vblank_flag(crtc_idx);
> >               check.request.type |= DRM_VBLANK_RELATIVE;
> >               do_or_die(drmWaitVBlank(drm_fd, &check));
> > 
> >               igt_assert(!vblank_after(check.reply.sequence, wait.request.sequence));
> >       }
> 
> Isn't the 'igt_assert_eq(ev.sequence, last_seq + 1);' sufficient
> to catch that?

Sure, but does that tell us if our construction was bad or the kernel
reported the wrong event? My idea behind the assert was to ensure we
didn't feed garbage in.
-Chris
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/3] lib/debugfs: Fix wraparound handling for crc frame counter check
  2018-11-06 16:19 [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Ville Syrjala
                   ` (3 preceding siblings ...)
  2018-11-06 17:11 ` Chris Wilson
@ 2018-11-07 19:19 ` Patchwork
  2018-11-08  7:20 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
  5 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2018-11-07 19:19 UTC (permalink / raw)
  To: Ville Syrjälä; +Cc: igt-dev

== Series Details ==

Series: series starting with [i-g-t,1/3] lib/debugfs: Fix wraparound handling for crc frame counter check
URL   : https://patchwork.freedesktop.org/series/52103/
State : success

== Summary ==

= CI Bug Log - changes from IGT_4712 -> IGTPW_2042 =

== Summary - WARNING ==

  Minor unknown changes coming with IGTPW_2042 need to be verified
  manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in IGTPW_2042, please notify your bug team to allow them
  to document this new failure mode, which will reduce false positives in CI.

  External URL: https://patchwork.freedesktop.org/api/1.0/series/52103/revisions/1/mbox/

== Possible new issues ==

  Here are the unknown changes that may have been introduced in IGTPW_2042:

  === IGT changes ===

    ==== Warnings ====

    igt@drv_selftest@live_hangcheck:
      fi-icl-u:           SKIP -> PASS

    
== Known issues ==

  Here are the changes found in IGTPW_2042 that come from known issues:

  === IGT changes ===

    ==== Issues hit ====

    igt@gem_ctx_create@basic-files:
      fi-bsw-kefka:       PASS -> FAIL (fdo#108656)

    igt@gem_exec_suspend@basic-s4-devices:
      fi-blb-e6850:       PASS -> INCOMPLETE (fdo#107718)

    igt@kms_flip@basic-flip-vs-modeset:
      fi-hsw-4770r:       PASS -> DMESG-WARN (fdo#105602) +1

    igt@kms_pipe_crc_basic@read-crc-pipe-a-frame-sequence:
      fi-byt-clapper:     PASS -> FAIL (fdo#107362, fdo#103191)

    
    ==== Possible fixes ====

    igt@drv_selftest@live_execlists:
      fi-icl-u:           INCOMPLETE (fdo#108315) -> PASS

    igt@gem_ctx_create@basic-files:
      fi-icl-u2:          DMESG-WARN (fdo#107724) -> PASS

    igt@kms_chamelium@common-hpd-after-suspend:
      fi-skl-6700k2:      FAIL (fdo#103841) -> PASS

    igt@kms_pipe_crc_basic@read-crc-pipe-b:
      fi-byt-clapper:     FAIL (fdo#107362) -> PASS

    
    ==== Warnings ====

    igt@drv_selftest@live_contexts:
      fi-icl-u:           INCOMPLETE (fdo#108315) -> DMESG-FAIL (fdo#108569)

    
  fdo#103191 https://bugs.freedesktop.org/show_bug.cgi?id=103191
  fdo#103841 https://bugs.freedesktop.org/show_bug.cgi?id=103841
  fdo#105602 https://bugs.freedesktop.org/show_bug.cgi?id=105602
  fdo#107362 https://bugs.freedesktop.org/show_bug.cgi?id=107362
  fdo#107718 https://bugs.freedesktop.org/show_bug.cgi?id=107718
  fdo#107724 https://bugs.freedesktop.org/show_bug.cgi?id=107724
  fdo#108315 https://bugs.freedesktop.org/show_bug.cgi?id=108315
  fdo#108569 https://bugs.freedesktop.org/show_bug.cgi?id=108569
  fdo#108656 https://bugs.freedesktop.org/show_bug.cgi?id=108656


== Participating hosts (52 -> 47) ==

  Additional (1): fi-cnl-u 
  Missing    (6): fi-kbl-soraka fi-ilk-m540 fi-hsw-4200u fi-byt-squawks fi-bsw-cyan fi-ctg-p8600 


== Build changes ==

    * IGT: IGT_4712 -> IGTPW_2042

  CI_DRM_5097: c20dfc4f015dfd41246beb7d72338aa50543a5ef @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_2042: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2042/
  IGT_4712: a3ede1b535ac8137f6949c468edd7054453d5dae @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2042/issues.html
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [igt-dev] ✓ Fi.CI.IGT: success for series starting with [i-g-t,1/3] lib/debugfs: Fix wraparound handling for crc frame counter check
  2018-11-06 16:19 [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Ville Syrjala
                   ` (4 preceding siblings ...)
  2018-11-07 19:19 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/3] " Patchwork
@ 2018-11-08  7:20 ` Patchwork
  5 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2018-11-08  7:20 UTC (permalink / raw)
  To: Ville Syrjälä; +Cc: igt-dev

== Series Details ==

Series: series starting with [i-g-t,1/3] lib/debugfs: Fix wraparound handling for crc frame counter check
URL   : https://patchwork.freedesktop.org/series/52103/
State : success

== Summary ==

= CI Bug Log - changes from IGT_4712_full -> IGTPW_2042_full =

== Summary - WARNING ==

  Minor unknown changes coming with IGTPW_2042_full need to be verified
  manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in IGTPW_2042_full, please notify your bug team to allow them
  to document this new failure mode, which will reduce false positives in CI.

  External URL: https://patchwork.freedesktop.org/api/1.0/series/52103/revisions/1/mbox/

== Possible new issues ==

  Here are the unknown changes that may have been introduced in IGTPW_2042_full:

  === IGT changes ===

    ==== Warnings ====

    igt@pm_rc6_residency@rc6-accuracy:
      shard-kbl:          PASS -> SKIP
      shard-snb:          PASS -> SKIP

    
== Known issues ==

  Here are the changes found in IGTPW_2042_full that come from known issues:

  === IGT changes ===

    ==== Issues hit ====

    igt@drv_suspend@shrink:
      shard-snb:          PASS -> INCOMPLETE (fdo#105411, fdo#106886)

    igt@gem_exec_reuse@baggage:
      shard-apl:          PASS -> DMESG-WARN (fdo#108690)

    igt@kms_available_modes_crc@available_mode_test_crc:
      shard-apl:          PASS -> FAIL (fdo#106641)

    igt@kms_ccs@pipe-b-crc-sprite-planes-basic:
      shard-glk:          PASS -> FAIL (fdo#108145)

    igt@kms_cursor_crc@cursor-256x256-dpms:
      shard-glk:          PASS -> FAIL (fdo#103232)

    igt@kms_cursor_crc@cursor-256x85-random:
      shard-apl:          PASS -> FAIL (fdo#103232) +4

    igt@kms_cursor_crc@cursor-64x64-random:
      shard-kbl:          PASS -> FAIL (fdo#103232)

    igt@kms_cursor_legacy@cursorb-vs-flipb-varying-size:
      shard-glk:          PASS -> DMESG-WARN (fdo#106538, fdo#105763)

    igt@kms_flip@2x-flip-vs-expired-vblank-interruptible:
      shard-glk:          PASS -> FAIL (fdo#105363)

    igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-indfb-draw-mmap-wc:
      shard-glk:          PASS -> FAIL (fdo#103167) +1

    igt@kms_frontbuffer_tracking@fbc-1p-primscrn-cur-indfb-draw-mmap-cpu:
      shard-apl:          PASS -> FAIL (fdo#103167) +1

    igt@kms_frontbuffer_tracking@fbc-1p-primscrn-shrfb-plflip-blt:
      shard-snb:          PASS -> INCOMPLETE (fdo#105411)

    igt@kms_frontbuffer_tracking@fbc-2p-rte:
      shard-glk:          PASS -> FAIL (fdo#103167, fdo#105682)

    igt@kms_plane@plane-position-covered-pipe-a-planes:
      shard-apl:          PASS -> FAIL (fdo#103166) +1

    igt@kms_plane_multiple@atomic-pipe-c-tiling-y:
      shard-glk:          PASS -> FAIL (fdo#103166)

    
    ==== Possible fixes ====

    igt@gem_exec_bad_domains@cpu-domain:
      shard-apl:          DMESG-WARN (fdo#103558, fdo#105602) -> PASS +5

    igt@gem_pwrite_pread@snooped-copy-correctness:
      shard-snb:          INCOMPLETE (fdo#105411) -> PASS

    igt@kms_cursor_crc@cursor-128x128-random:
      shard-apl:          FAIL (fdo#103232) -> PASS +2

    igt@kms_cursor_crc@cursor-64x64-dpms:
      shard-kbl:          FAIL (fdo#103232) -> PASS +2

    igt@kms_cursor_crc@cursor-64x64-random:
      shard-glk:          FAIL (fdo#103232) -> PASS +3

    igt@kms_cursor_legacy@2x-nonblocking-modeset-vs-cursor-atomic:
      shard-glk:          FAIL (fdo#105454, fdo#106509) -> PASS

    igt@kms_cursor_legacy@cursor-vs-flip-toggle:
      shard-hsw:          FAIL (fdo#103355) -> PASS

    igt@kms_cursor_legacy@cursora-vs-flipa-toggle:
      shard-glk:          DMESG-WARN (fdo#106538, fdo#105763) -> PASS

    igt@kms_frontbuffer_tracking@fbc-1p-primscrn-spr-indfb-draw-render:
      shard-apl:          FAIL (fdo#103167) -> PASS

    igt@kms_frontbuffer_tracking@fbc-2p-primscrn-spr-indfb-draw-pwrite:
      shard-glk:          FAIL (fdo#103167) -> PASS +2

    igt@kms_plane_alpha_blend@pipe-c-constant-alpha-max:
      shard-glk:          FAIL (fdo#108145) -> PASS

    igt@kms_plane_multiple@atomic-pipe-a-tiling-x:
      shard-apl:          FAIL (fdo#103166) -> PASS +4

    igt@kms_plane_multiple@atomic-pipe-b-tiling-x:
      shard-glk:          FAIL (fdo#103166) -> PASS +2

    igt@kms_plane_multiple@atomic-pipe-b-tiling-y:
      shard-kbl:          FAIL (fdo#103166) -> PASS

    igt@kms_setmode@basic-clone-single-crtc:
      shard-snb:          DMESG-WARN (fdo#107469) -> PASS +2

    
  fdo#103166 https://bugs.freedesktop.org/show_bug.cgi?id=103166
  fdo#103167 https://bugs.freedesktop.org/show_bug.cgi?id=103167
  fdo#103232 https://bugs.freedesktop.org/show_bug.cgi?id=103232
  fdo#103355 https://bugs.freedesktop.org/show_bug.cgi?id=103355
  fdo#103558 https://bugs.freedesktop.org/show_bug.cgi?id=103558
  fdo#105363 https://bugs.freedesktop.org/show_bug.cgi?id=105363
  fdo#105411 https://bugs.freedesktop.org/show_bug.cgi?id=105411
  fdo#105454 https://bugs.freedesktop.org/show_bug.cgi?id=105454
  fdo#105602 https://bugs.freedesktop.org/show_bug.cgi?id=105602
  fdo#105682 https://bugs.freedesktop.org/show_bug.cgi?id=105682
  fdo#105763 https://bugs.freedesktop.org/show_bug.cgi?id=105763
  fdo#106509 https://bugs.freedesktop.org/show_bug.cgi?id=106509
  fdo#106538 https://bugs.freedesktop.org/show_bug.cgi?id=106538
  fdo#106641 https://bugs.freedesktop.org/show_bug.cgi?id=106641
  fdo#106886 https://bugs.freedesktop.org/show_bug.cgi?id=106886
  fdo#107469 https://bugs.freedesktop.org/show_bug.cgi?id=107469
  fdo#108145 https://bugs.freedesktop.org/show_bug.cgi?id=108145
  fdo#108690 https://bugs.freedesktop.org/show_bug.cgi?id=108690


== Participating hosts (6 -> 5) ==

  Missing    (1): shard-skl 


== Build changes ==

    * IGT: IGT_4712 -> IGTPW_2042

  CI_DRM_5097: c20dfc4f015dfd41246beb7d72338aa50543a5ef @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_2042: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2042/
  IGT_4712: a3ede1b535ac8137f6949c468edd7054453d5dae @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2042/shards.html
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2018-11-08  7:20 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-06 16:19 [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Ville Syrjala
2018-11-06 16:19 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_setmode: Request the initial vbl count with RELATIVE instead of ABSOLUTE Ville Syrjala
2018-11-06 16:38   ` Chris Wilson
2018-11-06 16:57     ` Daniel Vetter
2018-11-06 17:02       ` Ville Syrjälä
2018-11-06 18:40     ` Ville Syrjälä
2018-11-06 19:27       ` Chris Wilson
2018-11-06 16:19 ` [igt-dev] [PATCH i-g-t 3/3] tests/kms_flip: " Ville Syrjala
2018-11-06 16:58 ` [igt-dev] [PATCH i-g-t 1/3] lib/debugfs: Fix wraparound handling for crc frame counter check Daniel Vetter
2018-11-06 17:11 ` Chris Wilson
2018-11-07 19:19 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/3] " Patchwork
2018-11-08  7:20 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.