From patchwork Wed Mar 2 14:00:18 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomeu Vizoso X-Patchwork-Id: 8480801 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 84462C0553 for ; Wed, 2 Mar 2016 14:01:27 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9540B2038E for ; Wed, 2 Mar 2016 14:01:25 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id B63FB20386 for ; Wed, 2 Mar 2016 14:01:24 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A521A6E884; Wed, 2 Mar 2016 14:01:23 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-wm0-x244.google.com (mail-wm0-x244.google.com [IPv6:2a00:1450:400c:c09::244]) by gabe.freedesktop.org (Postfix) with ESMTPS id 504886E87F for ; Wed, 2 Mar 2016 14:01:20 +0000 (UTC) Received: by mail-wm0-x244.google.com with SMTP id 1so9785960wmg.2 for ; Wed, 02 Mar 2016 06:01:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=jY+5/fa4YY43NxNU3Rp9mUn26h9th8/A0+sOfbyq980=; b=d6PMiZdP3+tCqYzNbzUw0TY5sZW5OuiR7/VDYHKrzwXGQ0MqEfCN2aCQqMxw+Lpys5 kFkWm0RI01Iwy3lMTZqxmMNbhvPddDpuGtL1MHZ+/SIByJwa5EQsQQaQucCtX41iexlI jPKLzTuFZ9YpbrKSkSlYQiZ2MLzbDwmYGkS0V9vmYmw/zk1tqxXNOyJGmIzRoUEpZ2yV WlNFb/Bsmx+8I5SOY+XElFgzgEgv6HFsrLsOmAFbDwkPmMRZ3c+iowsuccl1Y8GXgIFv /LQGSnZ+3cx7exH+ChX7jgJLylWQd0HJh+pOcbw6GbRX9qJWW2V2Y9D4UdShsTWjyhG1 qiNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=jY+5/fa4YY43NxNU3Rp9mUn26h9th8/A0+sOfbyq980=; b=kB2m4IBNFqYsE/S1hqIteCCmtWP3fYb1xascpmfHmTlKxzh6Uaaq9prCxc/Ykzh7DM wpaN7KIWigO7vUJWu9NIJCJH/q5I5Qd5g/I1bnJwtdxzsglIlTHSJyBnq447l/cXiZqn 6+sa6S5QBA3rHEjp7PJ7X5XlYd0g1aCQgkLRJytZgX1+0quHiJYEVnfZJ5RUHxRkxAzM fSWCr4xVfTdbBWQzMu/P99oNbKtHaJGcpvoJU6HdirXHdXuunw5/RNzvkw/ovEZN7kPf scZ1Nrvk+fAx8eGzi/E4cQsBYs42TrSGwKBPRDdnH8aEcPKeN0SeZ0aJWEIC8eQ0iWsj vlUg== X-Gm-Message-State: AD7BkJJ4Nipqm3vK9bN212bO01AfbaaBWckzF3IOxEWhRZAm4bBKOGxNZKdnVPFzzV2qXw== X-Received: by 10.194.103.72 with SMTP id fu8mr28093451wjb.70.1456927278526; Wed, 02 Mar 2016 06:01:18 -0800 (PST) Received: from cizrna.lan ([109.72.12.223]) by smtp.gmail.com with ESMTPSA id e19sm4359876wmd.1.2016.03.02.06.01.17 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 02 Mar 2016 06:01:17 -0800 (PST) From: Tomeu Vizoso To: Intel GFX discussion Date: Wed, 2 Mar 2016 15:00:18 +0100 Message-Id: <1456927221-32421-12-git-send-email-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1456927221-32421-1-git-send-email-tomeu.vizoso@collabora.com> References: <1456927221-32421-1-git-send-email-tomeu.vizoso@collabora.com> Cc: Daniel Stone , Tomeu Vizoso , Micah Fedke , Gustavo Padovan , Emil Velikov Subject: [Intel-gfx] [i-g-t PATCH v1 11/14] kms_addfb_basic: move tiling functionality into each subtest 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-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Because calls to gem_set_tiling will cause the subtest to be skipped on drivers other than i915, move them to each subtest that needs them so the other subtests aren't skipped as well. Signed-off-by: Tomeu Vizoso --- tests/kms_addfb_basic.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/kms_addfb_basic.c b/tests/kms_addfb_basic.c index 473b5e9d7236..e61d2502d78b 100644 --- a/tests/kms_addfb_basic.c +++ b/tests/kms_addfb_basic.c @@ -156,17 +156,17 @@ static void pitch_tests(int fd) } } - igt_fixture - gem_set_tiling(fd, gem_bo, I915_TILING_X, 1024*4); f.pitches[0] = 1024*4; igt_subtest("basic-X-tiled") { + gem_set_tiling(fd, gem_bo, I915_TILING_X, 1024*4); igt_assert(drmIoctl(fd, DRM_IOCTL_MODE_ADDFB2, &f) == 0); igt_assert(drmIoctl(fd, DRM_IOCTL_MODE_RMFB, &f.fb_id) == 0); f.fb_id = 0; } igt_subtest("framebuffer-vs-set-tiling") { + gem_set_tiling(fd, gem_bo, I915_TILING_X, 1024*4); igt_assert(drmIoctl(fd, DRM_IOCTL_MODE_ADDFB2, &f) == 0); igt_assert(__gem_set_tiling(fd, gem_bo, I915_TILING_X, 512*4) == -EBUSY); igt_assert(__gem_set_tiling(fd, gem_bo, I915_TILING_X, 1024*4) == -EBUSY); @@ -176,14 +176,14 @@ static void pitch_tests(int fd) f.pitches[0] = 512*4; igt_subtest("tile-pitch-mismatch") { + gem_set_tiling(fd, gem_bo, I915_TILING_X, 1024*4); igt_assert(drmIoctl(fd, DRM_IOCTL_MODE_ADDFB2, &f) == -1 && errno == EINVAL); } - igt_fixture - gem_set_tiling(fd, gem_bo, I915_TILING_Y, 1024*4); f.pitches[0] = 1024*4; igt_subtest("basic-Y-tiled") { + gem_set_tiling(fd, gem_bo, I915_TILING_Y, 1024*4); igt_assert(drmIoctl(fd, DRM_IOCTL_MODE_ADDFB2, &f) == -1 && errno == EINVAL); }