From patchwork Thu Mar 23 12:48:25 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mika Kahola X-Patchwork-Id: 9640991 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 68716601E9 for ; Thu, 23 Mar 2017 12:47:31 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5D742279E0 for ; Thu, 23 Mar 2017 12:47:31 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 525B128304; Thu, 23 Mar 2017 12:47:31 +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.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID 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 03432279E0 for ; Thu, 23 Mar 2017 12:47:31 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 31C0E6EA22; Thu, 23 Mar 2017 12:47:29 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by gabe.freedesktop.org (Postfix) with ESMTPS id DED136EA01 for ; Thu, 23 Mar 2017 12:47:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=intel.com; i=@intel.com; q=dns/txt; s=intel; t=1490273240; x=1521809240; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=M3hMxmwbZ8DzH5LOiRtgdKWNx7JFN3nlOxiAL9SgQjs=; b=Cif78dP3cii5OLkkHcDNlFYG9Mk+jdne7KW94cWIQa/mWLK7pGevJUhR QixFfmH7abe+Zv/ZtWNN7wln8LiZYg==; Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 23 Mar 2017 05:47:20 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.36,209,1486454400"; d="scan'208";a="239514284" Received: from sorvi.fi.intel.com ([10.237.72.182]) by fmsmga004.fm.intel.com with ESMTP; 23 Mar 2017 05:47:19 -0700 From: Mika Kahola To: intel-gfx@lists.freedesktop.org Date: Thu, 23 Mar 2017 14:48:25 +0200 Message-Id: <1490273311-9794-3-git-send-email-mika.kahola@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1490273311-9794-1-git-send-email-mika.kahola@intel.com> References: <1490273311-9794-1-git-send-email-mika.kahola@intel.com> Subject: [Intel-gfx] [PATCH i-g-t v4 2/7] tests/kms_plane_multiple: Add TEST_ONLY flag Cc: maarten.lankhorst@linux.intel.com 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. v2: Use flag to indicate to test with TEST_ONLY flag with atomic commit v3: Moved force_test_atomic flag set to 'test_plane_position()' Signed-off-by: Mika Kahola --- tests/kms_plane_multiple.c | 48 ++++++++++++++++++++++++++++++++++++---------- 1 file changed, 38 insertions(+), 10 deletions(-) diff --git a/tests/kms_plane_multiple.c b/tests/kms_plane_multiple.c index 93dce6b..84fd411 100644 --- a/tests/kms_plane_multiple.c +++ b/tests/kms_plane_multiple.c @@ -365,7 +365,8 @@ test_legacy_plane_position_with_output(data_t *data, enum pipe pipe, } static void -test_plane_position(data_t *data, enum pipe pipe, bool atomic, uint64_t tiling) +test_plane_position(data_t *data, enum pipe pipe, bool atomic, + bool force_test_atomic, uint64_t tiling) { igt_output_t *output; int connected_outs; @@ -379,6 +380,8 @@ test_plane_position(data_t *data, enum pipe pipe, bool atomic, uint64_t tiling) tiling == LOCAL_I915_FORMAT_MOD_Yf_TILED)) igt_require(AT_LEAST_GEN(devid, 9)); + data->display.force_test_atomic = force_test_atomic; + if (!opt.user_seed) opt.seed = time(NULL); @@ -421,46 +424,71 @@ run_tests_for_pipe(data_t *data, enum pipe pipe) igt_require(data->display.pipes[pipe].n_planes > 0); } - igt_subtest_f("legacy-pipe-%s-tiling-none", kmstest_pipe_name(pipe)) for_each_valid_output_on_pipe(&data->display, pipe, output) - test_plane_position(data, pipe, false, LOCAL_DRM_FORMAT_MOD_NONE); + test_plane_position(data, pipe, false, false, + LOCAL_DRM_FORMAT_MOD_NONE); igt_subtest_f("atomic-pipe-%s-tiling-none", kmstest_pipe_name(pipe)) for_each_valid_output_on_pipe(&data->display, pipe, output) - test_plane_position(data, pipe, true, LOCAL_I915_FORMAT_MOD_X_TILED); + test_plane_position(data, pipe, true, false, + LOCAL_I915_FORMAT_MOD_X_TILED); igt_subtest_f("legacy-pipe-%s-tiling-x", kmstest_pipe_name(pipe)) for_each_valid_output_on_pipe(&data->display, pipe, output) - test_plane_position(data, pipe, false, LOCAL_I915_FORMAT_MOD_X_TILED); + test_plane_position(data, pipe, false, false, + LOCAL_I915_FORMAT_MOD_X_TILED); igt_subtest_f("atomic-pipe-%s-tiling-x", kmstest_pipe_name(pipe)) for_each_valid_output_on_pipe(&data->display, pipe, output) - test_plane_position(data, pipe, true, LOCAL_I915_FORMAT_MOD_X_TILED); + test_plane_position(data, pipe, true, false, + LOCAL_I915_FORMAT_MOD_X_TILED); igt_subtest_f("legacy-pipe-%s-tiling-y", kmstest_pipe_name(pipe)) for_each_valid_output_on_pipe(&data->display, pipe, output) - test_plane_position(data, pipe, false, LOCAL_I915_FORMAT_MOD_Y_TILED); + test_plane_position(data, pipe, false, false, + LOCAL_I915_FORMAT_MOD_Y_TILED); igt_subtest_f("atomic-pipe-%s-tiling-y", kmstest_pipe_name(pipe)) for_each_valid_output_on_pipe(&data->display, pipe, output) - test_plane_position(data, pipe, true, LOCAL_I915_FORMAT_MOD_Y_TILED); + test_plane_position(data, pipe, true, false, + LOCAL_I915_FORMAT_MOD_Y_TILED); igt_subtest_f("legacy-pipe-%s-tiling-yf", kmstest_pipe_name(pipe)) for_each_valid_output_on_pipe(&data->display, pipe, output) - test_plane_position(data, pipe, false, LOCAL_I915_FORMAT_MOD_Yf_TILED); + test_plane_position(data, pipe, false, false, + LOCAL_I915_FORMAT_MOD_Yf_TILED); igt_subtest_f("atomic-pipe-%s-tiling-yf", kmstest_pipe_name(pipe)) for_each_valid_output_on_pipe(&data->display, pipe, output) - test_plane_position(data, pipe, true, LOCAL_I915_FORMAT_MOD_Yf_TILED); + test_plane_position(data, pipe, true, false, + LOCAL_I915_FORMAT_MOD_Yf_TILED); + + igt_subtest_f("atomic-pipe-%s-tiling-x-with-test", + kmstest_pipe_name(pipe)) + for_each_valid_output_on_pipe(&data->display, pipe, output) + test_plane_position(data, pipe, true, true, + LOCAL_I915_FORMAT_MOD_X_TILED); + + igt_subtest_f("atomic-pipe-%s-tiling-y-with-test", + kmstest_pipe_name(pipe)) + for_each_valid_output_on_pipe(&data->display, pipe, output) + test_plane_position(data, pipe, true, true, + LOCAL_I915_FORMAT_MOD_X_TILED); + + igt_subtest_f("atomic-pipe-%s-tiling-yf-with-test", + kmstest_pipe_name(pipe)) + for_each_valid_output_on_pipe(&data->display, pipe, output) + test_plane_position(data, pipe, true, true, + LOCAL_I915_FORMAT_MOD_X_TILED); } static data_t data;