From patchwork Wed Feb 1 13:18:07 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mika Kahola X-Patchwork-Id: 9549711 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0713260424 for ; Wed, 1 Feb 2017 13:17:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E9CD528448 for ; Wed, 1 Feb 2017 13:17:35 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id DEB8C28451; Wed, 1 Feb 2017 13:17:35 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7D95928448 for ; Wed, 1 Feb 2017 13:17:35 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3A4C46E7DB; Wed, 1 Feb 2017 13:17:34 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by gabe.freedesktop.org (Postfix) with ESMTPS id D9DCD6E7D5 for ; Wed, 1 Feb 2017 13:17:32 +0000 (UTC) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga105.jf.intel.com with ESMTP; 01 Feb 2017 05:17:32 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,320,1477983600"; d="scan'208";a="38245141" Received: from sorvi.fi.intel.com ([10.237.72.109]) by orsmga002.jf.intel.com with ESMTP; 01 Feb 2017 05:17:31 -0800 From: Mika Kahola To: intel-gfx@lists.freedesktop.org Date: Wed, 1 Feb 2017 15:18:07 +0200 Message-Id: <1485955089-30267-6-git-send-email-mika.kahola@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1485955089-30267-1-git-send-email-mika.kahola@intel.com> References: <1485955089-30267-1-git-send-email-mika.kahola@intel.com> Subject: [Intel-gfx] [PATCH i-g-t v3 5/7] tests/kms_rotation_crc: Add TEST_ONLY flag X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP Add TEST_ONLY flag to test atomic modesetting commits without actual real-life commit. Signed-off-by: Mika Kahola --- tests/kms_rotation_crc.c | 139 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 139 insertions(+) diff --git a/tests/kms_rotation_crc.c b/tests/kms_rotation_crc.c index 9bfcde3..2d2606d 100644 --- a/tests/kms_rotation_crc.c +++ b/tests/kms_rotation_crc.c @@ -522,46 +522,109 @@ igt_main igt_display_init(&data.display, data.gfx_fd); } igt_subtest_f("primary-rotation-180") { + data.display.force_test_atomic = false; + data.rotation = IGT_ROTATION_180; + test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); + } + + igt_subtest_f("primary-rotation-180-with-test") { + data.display.force_test_atomic = true; data.rotation = IGT_ROTATION_180; test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); } igt_subtest_f("sprite-rotation-180") { + data.display.force_test_atomic = false; + data.rotation = IGT_ROTATION_180; + test_plane_rotation(&data, DRM_PLANE_TYPE_OVERLAY); + } + + igt_subtest_f("sprite-rotation-180-with-test") { + data.display.force_test_atomic = true; data.rotation = IGT_ROTATION_180; test_plane_rotation(&data, DRM_PLANE_TYPE_OVERLAY); } igt_subtest_f("cursor-rotation-180") { + data.display.force_test_atomic = false; + data.rotation = IGT_ROTATION_180; + test_plane_rotation(&data, DRM_PLANE_TYPE_CURSOR); + } + + igt_subtest_f("cursor-rotation-180-with-test") { + data.display.force_test_atomic = true; data.rotation = IGT_ROTATION_180; test_plane_rotation(&data, DRM_PLANE_TYPE_CURSOR); } igt_subtest_f("primary-rotation-90") { igt_require(gen >= 9); + data.display.force_test_atomic = false; + data.rotation = IGT_ROTATION_90; + test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); + } + + igt_subtest_f("primary-rotation-90-with-test") { + igt_require(gen >= 9); + data.display.force_test_atomic = true; data.rotation = IGT_ROTATION_90; test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); } igt_subtest_f("primary-rotation-270") { igt_require(gen >= 9); + data.display.force_test_atomic = false; + data.rotation = IGT_ROTATION_270; + test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); + } + + igt_subtest_f("primary-rotation-270-with-test") { + igt_require(gen >= 9); + data.display.force_test_atomic = true; data.rotation = IGT_ROTATION_270; test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); } igt_subtest_f("sprite-rotation-90") { igt_require(gen >= 9); + data.display.force_test_atomic = false; + data.rotation = IGT_ROTATION_90; + test_plane_rotation(&data, DRM_PLANE_TYPE_OVERLAY); + } + + igt_subtest_f("sprite-rotation-90-with-test") { + igt_require(gen >= 9); + data.display.force_test_atomic = true; data.rotation = IGT_ROTATION_90; test_plane_rotation(&data, DRM_PLANE_TYPE_OVERLAY); } igt_subtest_f("sprite-rotation-270") { igt_require(gen >= 9); + data.display.force_test_atomic = false; + data.rotation = IGT_ROTATION_270; + test_plane_rotation(&data, DRM_PLANE_TYPE_OVERLAY); + } + + igt_subtest_f("sprite-rotation-270-with-test") { + igt_require(gen >= 9); + data.display.force_test_atomic = true; data.rotation = IGT_ROTATION_270; test_plane_rotation(&data, DRM_PLANE_TYPE_OVERLAY); } igt_subtest_f("sprite-rotation-90-pos-100-0") { igt_require(gen >= 9); + data.display.force_test_atomic = false; + data.rotation = IGT_ROTATION_90; + data.pos_x = 100, + data.pos_y = 0; + test_plane_rotation(&data, DRM_PLANE_TYPE_OVERLAY); + } + + igt_subtest_f("sprite-rotation-90-pos-100-0-with-test") { + igt_require(gen >= 9); + data.display.force_test_atomic = true; data.rotation = IGT_ROTATION_90; data.pos_x = 100, data.pos_y = 0; @@ -574,6 +637,17 @@ igt_main data.pos_y = 0; data.rotation = IGT_ROTATION_90; data.override_fmt = DRM_FORMAT_RGB565; + data.display.force_test_atomic = false; + test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); + } + + igt_subtest_f("bad-pixel-format-with-test") { + igt_require(gen >= 9); + data.pos_x = 0, + data.pos_y = 0; + data.rotation = IGT_ROTATION_90; + data.override_fmt = DRM_FORMAT_RGB565; + data.display.force_test_atomic = true; test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); } @@ -582,6 +656,16 @@ igt_main data.override_fmt = 0; data.rotation = IGT_ROTATION_90; data.override_tiling = LOCAL_DRM_FORMAT_MOD_NONE; + data.display.force_test_atomic = false; + test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); + } + + igt_subtest_f("bad-tiling-with-test") { + igt_require(gen >= 9); + data.override_fmt = 0; + data.rotation = IGT_ROTATION_90; + data.override_tiling = LOCAL_DRM_FORMAT_MOD_NONE; + data.display.force_test_atomic = true; test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); } @@ -590,6 +674,16 @@ igt_main data.override_tiling = 0; data.flip_stress = 60; data.rotation = IGT_ROTATION_90; + data.display.force_test_atomic = false; + test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); + } + + igt_subtest_f("primary-rotation-90-flip-stress-with-test") { + igt_require(gen >= 9); + data.override_tiling = 0; + data.flip_stress = 60; + data.rotation = IGT_ROTATION_90; + data.display.force_test_atomic = true; test_plane_rotation(&data, DRM_PLANE_TYPE_PRIMARY); } @@ -600,6 +694,28 @@ igt_main igt_require(gen >= 9); data.rotation = IGT_ROTATION_90; + data.display.force_test_atomic = false; + + for_each_pipe_with_valid_output(&data.display, pipe, output) { + igt_output_set_pipe(output, pipe); + + test_plane_rotation_ytiled_obj(&data, output, DRM_PLANE_TYPE_PRIMARY); + + valid_tests++; + break; + } + + igt_require_f(valid_tests, "no valid crtc/connector combinations found\n"); + } + + igt_subtest_f("primary-rotation-90-Y-tiled-with-test") { + enum pipe pipe; + igt_output_t *output; + int valid_tests = 0; + + igt_require(gen >= 9); + data.rotation = IGT_ROTATION_90; + data.display.force_test_atomic = true; for_each_pipe_with_valid_output(&data.display, pipe, output) { igt_output_set_pipe(output, pipe); @@ -620,6 +736,29 @@ igt_main igt_require(gen >= 9); + data.display.force_test_atomic = false; + + for_each_pipe_with_valid_output(&data.display, pipe, output) { + igt_output_set_pipe(output, pipe); + + test_plane_rotation_exhaust_fences(&data, output, DRM_PLANE_TYPE_PRIMARY); + + valid_tests++; + break; + } + + igt_require_f(valid_tests, "no valid crtc/connector combinations found\n"); + } + + igt_subtest_f("exhaust-fences-with-test") { + enum pipe pipe; + igt_output_t *output; + int valid_tests = 0; + + igt_require(gen >= 9); + + data.display.force_test_atomic = true; + for_each_pipe_with_valid_output(&data.display, pipe, output) { igt_output_set_pipe(output, pipe);