All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Sharma, Swati2" <swati2.sharma@intel.com>
To: Naladala Ramanaidu <ramanaidu.naladala@intel.com>,
	<igt-dev@lists.freedesktop.org>
Subject: Re: [PATCH i-g-t v1] tests/kms_vblank: Skip timing check in simulation to avoid false negatives
Date: Mon, 21 Jul 2025 23:36:35 +0530	[thread overview]
Message-ID: <3d075fd4-48fc-41b5-8b2b-806940d7c1d1@intel.com> (raw)
In-Reply-To: <20250711180740.145938-1-ramanaidu.naladala@intel.com>

Hi Ramanaidu,

Patch LGTM.
Reviewed-by: Swati Sharma <swati2.sharma@intel.com>

On 11-07-2025 11:37 pm, Naladala Ramanaidu wrote:
> Simulation environments often do not reflect real hardware timing
> accurately, which can result in false negatives during vblank
> sequence testing. To prevent such issues, this patch conditionally
> skips the timing  validation when the test run in simulation.
>
> Signed-off-by: Naladala Ramanaidu <ramanaidu.naladala@intel.com>
> ---
>   tests/kms_vblank.c | 13 +++++++++++--
>   1 file changed, 11 insertions(+), 2 deletions(-)
>
> diff --git a/tests/kms_vblank.c b/tests/kms_vblank.c
> index b8044ad42..75cf9448f 100644
> --- a/tests/kms_vblank.c
> +++ b/tests/kms_vblank.c
> @@ -460,8 +460,17 @@ static void vblank_ts_cont(data_t *data, int fd, int nchildren)
>   
>   	igt_assert_f(seq2 - seq1 >= 0, "elapsed %f(%d vblanks) unexpected vblank seq %u, should be > %u\n", time_elapsed,
>   			estimated_vblanks, seq2, seq1);
> -	igt_assert_f(seq2 - seq1 <= estimated_vblanks + VBLANK_ERR, "elapsed %f(%d vblanks) unexpected vblank seq %u, should be <= %u\n", time_elapsed,
> -			estimated_vblanks, seq2, seq1 + estimated_vblanks);
> +	/*
> +	 * Timing behavior in simulation environments often differs from real hardware,
> +	 * which can lead to false negatives during testing. To mitigate this, disable
> +	 * timestamp and sequence validations when the INTEL_SIMULATION environment
> +	 * variable is active.
> +	 */
> +	if (!igt_run_in_simulation())
> +		igt_assert_f(seq2 - seq1 <= estimated_vblanks + VBLANK_ERR,
> +			     "elapsed %f(%d vblanks) unexpected vblank seq %u, should be <= %u\n",
> +			     time_elapsed, estimated_vblanks,
> +			     seq2, seq1 + estimated_vblanks);
>   }
>   
>   static void run_subtests(data_t *data)


      parent reply	other threads:[~2025-07-21 18:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-11 18:07 [PATCH i-g-t v1] tests/kms_vblank: Skip timing check in simulation to avoid false negatives Naladala Ramanaidu
2025-07-11 20:01 ` ✓ Xe.CI.BAT: success for " Patchwork
2025-07-11 20:03 ` ✓ i915.CI.BAT: " Patchwork
2025-07-12  4:40 ` ✓ i915.CI.Full: " Patchwork
2025-07-12  5:35 ` ✓ Xe.CI.Full: " Patchwork
2025-07-21 18:06 ` Sharma, Swati2 [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=3d075fd4-48fc-41b5-8b2b-806940d7c1d1@intel.com \
    --to=swati2.sharma@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=ramanaidu.naladala@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 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.