Return-Path: Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by gabe.freedesktop.org (Postfix) with ESMTPS id 994A589C53 for ; Tue, 7 Sep 2021 07:55:04 +0000 (UTC) From: Bhanuprakash Modem Date: Tue, 7 Sep 2021 13:25:14 +0530 Message-Id: <20210907075514.492714-1-bhanuprakash.modem@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [igt-dev] [PATCH i-g-t] tests/kms_cursor_crc: Handle invalid cursor sizes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" To: igt-dev@lists.freedesktop.org Cc: Bhanuprakash Modem , Juha-Pekka Heikkila , Mika Kahola List-ID: As there are many possibilities to fail the commit, instead of considering all the failures we must take -EINVAL only into account. Cc: Juha-Pekka Heikkila Cc: Mika Kahola Signed-off-by: Bhanuprakash Modem --- tests/kms_cursor_crc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/kms_cursor_crc.c b/tests/kms_cursor_crc.c index f478ae08d..d53f5d249 100644 --- a/tests/kms_cursor_crc.c +++ b/tests/kms_cursor_crc.c @@ -651,7 +651,10 @@ static void require_cursor_size(data_t *data, int w, int h) igt_remove_fb(data->drm_fd, &primary_fb); igt_output_set_pipe(output, PIPE_NONE); - igt_skip_on_f(ret, "Cursor size %dx%d not supported by driver\n", w, h); + if (ret < 0) { + igt_assert_eq(errno, EINVAL); + igt_skip("Cursor size %dx%d not supported by driver\n", w, h); + } } static void run_test(data_t *data, void (*testfunc)(data_t *), int cursor_w, int cursor_h) -- 2.32.0