public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Martin Peres <martin.peres@linux.intel.com>
To: Simon Ser <simon.ser@intel.com>, igt-dev@lists.freedesktop.org
Cc: martin.peres@intel.com
Subject: Re: [igt-dev] [PATCH i-g-t] tests/kms_flip: improve logging when timing out
Date: Mon, 17 Jun 2019 10:26:37 +0300	[thread overview]
Message-ID: <dd601731-fc61-c201-7801-bfcd1de37d99@linux.intel.com> (raw)
In-Reply-To: <20190614105745.29648-1-simon.ser@intel.com>

On 14/06/2019 13:57, Simon Ser wrote:
> Signed-off-by: Simon Ser <simon.ser@intel.com>
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105363
> ---
>  tests/kms_flip.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/kms_flip.c b/tests/kms_flip.c
> index 2a158d97bbec..3015836c0186 100755
> --- a/tests/kms_flip.c
> +++ b/tests/kms_flip.c
> @@ -686,14 +686,16 @@ static unsigned int run_test_step(struct test_output *o)
>  	    !(o->pending_events & EVENT_VBLANK) && o->flip_state.count > 0) {
>  		struct vblank_reply reply;
>  		unsigned int exp_seq;
> -		unsigned long start;
> +		unsigned long start, end;
> 
>  		exp_seq = o->flip_state.current_seq;
>  		start = gettime_us();
>  		do_or_die(__wait_for_vblank(TEST_VBLANK_ABSOLUTE |
>  					    TEST_VBLANK_BLOCK, o->pipe, exp_seq,
>  					    0, &reply));
> -		igt_assert(gettime_us() - start < 500);
> +		end = gettime_us();
> +		igt_assert_f(end - start < 500, "Wait vblank timed out: %luus",
> +			     end - start);

The message is not super clear. How about:

"Vblank wait took longer than expected: %luus vs %luus\n"

>  		igt_assert_eq(reply.sequence, exp_seq);
>  		igt_assert(timercmp(&reply.ts, &o->flip_state.last_ts, ==));
>  	}
> --
> 2.22.0
> 
> _______________________________________________
> igt-dev mailing list
> igt-dev@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/igt-dev
> 
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

      parent reply	other threads:[~2019-06-17  7:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-14 10:57 [igt-dev] [PATCH i-g-t] tests/kms_flip: improve logging when timing out Simon Ser
2019-06-14 23:08 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2019-06-15 17:32 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2019-06-17  7:26 ` Martin Peres [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=dd601731-fc61-c201-7801-bfcd1de37d99@linux.intel.com \
    --to=martin.peres@linux.intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=martin.peres@intel.com \
    --cc=simon.ser@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox