From patchwork Tue Sep 14 05:55:49 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Iago Toral X-Patchwork-Id: 12491765 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 363BBC433F5 for ; Tue, 14 Sep 2021 05:56:06 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9F03D60F6D for ; Tue, 14 Sep 2021 05:56:03 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 9F03D60F6D Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=igalia.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A35376E3FE; Tue, 14 Sep 2021 05:56:02 +0000 (UTC) Received: from fanzine.igalia.com (fanzine.igalia.com [178.60.130.6]) by gabe.freedesktop.org (Postfix) with ESMTPS id 33C976E3FE for ; Tue, 14 Sep 2021 05:56:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=Content-Transfer-Encoding:MIME-Version:Message-Id:Date:Subject:Cc:To:From; bh=3O5qPh9B9CukE5UqdcdI1jL5rwSTJCLiW4ZfHGkg0qQ=; b=aG/tXfTj4uXc6FLHmVqhSsAEV0uMc87/iT1aevzAilDjjfv+2EVcxp1tW8xyyGCJE4mOgzhV2dMwM+XJAiWhZyQxsNbLTBmRh5lllClaHPca6Z1Ce3tOcXKto5Ukul2psAuOjv6QK3eM+O9a0GrCYWaMZBSB2wZhMBKF6mlyh3fB9zsXrTMTSQtBEBFJ+X8Xe7yL6wCUvzKfgeUGRS+RBc/Wf1+jb5jL7PHn9PiwbYKTY57bbdl3OaczYHBEYVFj6MukhjdTt9k0Htq/zG6oGuXENoWKTJTV7zeoDwGxu7lUlVqBmoaEPjtI6IfOi4athd7RgKCsl1+1zEfPiS/xYA==; Received: from 11.48.165.83.dynamic.reverse-mundo-r.com ([83.165.48.11] helo=zeus.mundo-R.com) by fanzine.igalia.com with esmtpsa (Cipher TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim) id 1mQ1QF-0007tb-EH; Tue, 14 Sep 2021 07:55:59 +0200 From: Iago Toral Quiroga To: dri-devel@lists.freedesktop.org Cc: mwen@igalia.com Subject: [PATCH] drm/v3d: fix wait for TMU write combiner flush Date: Tue, 14 Sep 2021 07:55:49 +0200 Message-Id: <20210914055549.4340-1-itoral@igalia.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" The hardware sets the TMUWCF bit back to 0 when the TMU write combiner flush completes so we should be checking for that instead of the L2TFLS bit. Fixes spurious Vulkan CTS failures in: dEQP-VK.binding_model.descriptorset_random.* Reviewed-by: Melissa Wen --- drivers/gpu/drm/v3d/v3d_gem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/v3d/v3d_gem.c b/drivers/gpu/drm/v3d/v3d_gem.c index a3529809d547..5159f544bc16 100644 --- a/drivers/gpu/drm/v3d/v3d_gem.c +++ b/drivers/gpu/drm/v3d/v3d_gem.c @@ -197,7 +197,7 @@ v3d_clean_caches(struct v3d_dev *v3d) V3D_CORE_WRITE(core, V3D_CTL_L2TCACTL, V3D_L2TCACTL_TMUWCF); if (wait_for(!(V3D_CORE_READ(core, V3D_CTL_L2TCACTL) & - V3D_L2TCACTL_L2TFLS), 100)) { + V3D_L2TCACTL_TMUWCF), 100)) { DRM_ERROR("Timeout waiting for L1T write combiner flush\n"); }