Return-Path: Received: from mail-pl1-x62c.google.com (mail-pl1-x62c.google.com [IPv6:2607:f8b0:4864:20::62c]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3B78B11AA73 for ; Sat, 9 Jul 2022 16:22:42 +0000 (UTC) Received: by mail-pl1-x62c.google.com with SMTP id b2so1192075plx.7 for ; Sat, 09 Jul 2022 09:22:42 -0700 (PDT) From: Rob Clark To: igt-dev@lists.freedesktop.org Date: Sat, 9 Jul 2022 09:23:05 -0700 Message-Id: <20220709162305.1958838-1-robdclark@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [igt-dev] [PATCH igt] tests/kms_bw: Skip unsupported modes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rob Clark Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" List-ID: From: Rob Clark Signed-off-by: Rob Clark --- tests/kms_bw.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/kms_bw.c b/tests/kms_bw.c index a4553cde..7bb1332e 100644 --- a/tests/kms_bw.c +++ b/tests/kms_bw.c @@ -146,6 +146,7 @@ static void run_test_linear_tiling(data_t *data, int pipe, const drmModeModeInfo igt_crc_t zero, captured[IGT_MAX_PIPES]; int i = 0, num_pipes = 0; enum pipe p; + int ret; /* Cannot use igt_display_get_n_pipes() due to fused pipes on i915 where they do * not give the numver of valid crtcs and always return IGT_MAX_PIPES */ @@ -175,6 +176,12 @@ static void run_test_linear_tiling(data_t *data, int pipe, const drmModeModeInfo igt_plane_set_fb(data->primary[i], &buffer[i]); } + ret = igt_display_try_commit_atomic(display, + DRM_MODE_ATOMIC_ALLOW_MODESET | + DRM_MODE_ATOMIC_TEST_ONLY, + NULL); + igt_skip_on_f(ret != 0, "Unsupported mode\n"); + igt_display_commit_atomic(display, DRM_MODE_ATOMIC_ALLOW_MODESET, NULL); for (i = 0; i <= pipe; i++) { -- 2.36.1