From patchwork Thu Dec 22 20:42:04 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Zanoni, Paulo R" X-Patchwork-Id: 9485627 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 26E9660405 for ; Thu, 22 Dec 2016 20:42:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1BD9328066 for ; Thu, 22 Dec 2016 20:42:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1109E28325; Thu, 22 Dec 2016 20:42:32 +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 A073C28066 for ; Thu, 22 Dec 2016 20:42:31 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id AF9466F396; Thu, 22 Dec 2016 20:42: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 1A0C66F395 for ; Thu, 22 Dec 2016 20:42:16 +0000 (UTC) Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga103.fm.intel.com with ESMTP; 22 Dec 2016 12:42:15 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,390,1477983600"; d="scan'208";a="42582926" Received: from przanoni-mobl.amr.corp.intel.com ([10.254.184.18]) by orsmga004.jf.intel.com with ESMTP; 22 Dec 2016 12:42:14 -0800 From: Paulo Zanoni To: intel-gfx@lists.freedesktop.org Date: Thu, 22 Dec 2016 18:42:04 -0200 Message-Id: <1482439328-32197-2-git-send-email-paulo.r.zanoni@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1482439328-32197-1-git-send-email-paulo.r.zanoni@intel.com> References: <1482439328-32197-1-git-send-email-paulo.r.zanoni@intel.com> Cc: Paulo Zanoni Subject: [Intel-gfx] [PATCH igt 2/6] kms_frontbuffer_tracking: fix sink CRC assertion 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 If we already detected an error, don't try to assert the size of what we didn't read. In machines where the sink CRC is unreliable, this was failing tests where the sink CRC is not mandatory (FBC tests). With this change we won't fail anymore, we'll just print error messages saying that the sink CRC is unreliable. Signed-off-by: Paulo Zanoni --- tests/kms_frontbuffer_tracking.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) This is important. I thought I had merged this in the upstream repo a long time ago... diff --git a/tests/kms_frontbuffer_tracking.c b/tests/kms_frontbuffer_tracking.c index fd3ad53..81532dc 100644 --- a/tests/kms_frontbuffer_tracking.c +++ b/tests/kms_frontbuffer_tracking.c @@ -943,8 +943,9 @@ static void get_sink_crc(sink_crc_t *crc, bool mandatory) igt_skip("Sink CRC is unreliable on this machine. Try running this test again individually\n"); else igt_info("Sink CRC is unreliable on this machine. Try running this test again individually\n"); + } else { + igt_assert(rc == SINK_CRC_SIZE); } - igt_assert(rc == SINK_CRC_SIZE); } static bool sink_crc_equal(sink_crc_t *a, sink_crc_t *b)