From patchwork Wed Aug 3 18:37:00 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Paauwe, Bob J" X-Patchwork-Id: 9261825 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 E7E936048B for ; Wed, 3 Aug 2016 18:36:07 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DD16B28236 for ; Wed, 3 Aug 2016 18:36:07 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D1B8B282EC; Wed, 3 Aug 2016 18:36:07 +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]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 177F328236 for ; Wed, 3 Aug 2016 18:36:06 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 515956E8B0; Wed, 3 Aug 2016 18:36:02 +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 ESMTP id 376BA6E8B0 for ; Wed, 3 Aug 2016 18:35:59 +0000 (UTC) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga103.fm.intel.com with ESMTP; 03 Aug 2016 11:35:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos; i="5.28,466,1464678000"; d="scan'208"; a="1007862829" Received: from bpaauwe-desk.fm.intel.com ([10.1.134.207]) by orsmga001.jf.intel.com with ESMTP; 03 Aug 2016 11:35:59 -0700 From: Bob Paauwe To: intel-gfx Date: Wed, 3 Aug 2016 11:37:00 -0700 Message-Id: <1470249420-17442-1-git-send-email-bob.j.paauwe@intel.com> X-Mailer: git-send-email 2.7.4 Cc: Daniel Vetter Subject: [Intel-gfx] [PATCH i-g-t] kms_pipe_color: Don't assert on crc not equal. 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 In this specific case, multiple color values are compared to the reference with only one expected to have an equal crc. Asserting on the first case where the crc values aren't equal causes the various ctm-0-xx-pipex tests to fail. This reverts commit 582ce4cd19c627606047b1a8fdd987c4dc07353c Author: Daniel Vetter Date: Wed Jul 27 13:17:38 2016 +0200 lib/debugs: nuke igt_crc_equal again for this test only and makes the igt_crc_equal function a local function. Signed-off-by: Bob Paauwe --- tests/kms_pipe_color.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/tests/kms_pipe_color.c b/tests/kms_pipe_color.c index b0a2f07..8f85e99 100644 --- a/tests/kms_pipe_color.c +++ b/tests/kms_pipe_color.c @@ -652,6 +652,17 @@ static void test_pipe_legacy_gamma_reset(data_t *data, free(gamma_zero); } +static bool igt_crc_equal(igt_crc_t *a, igt_crc_t *b) +{ + int i; + + for (i = 0; i < a->n_words; i++) + if (a->crc[i] != b->crc[i]) + return false; + return true; +} + + /* * Draw 3 rectangles using before colors with the ctm matrix apply and verify * the CRC is equal to using after colors with an identify ctm matrix. @@ -724,7 +735,7 @@ static bool test_pipe_ctm(data_t *data, /* Verify that the CRC of the software computed output is * equal to the CRC of the CTM matrix transformation output. */ - igt_assert_crc_equal(&crc_software, &crc_hardware); + ret &= igt_crc_equal(&crc_software, &crc_hardware); igt_output_set_pipe(output, PIPE_ANY); }