From mboxrd@z Thu Jan 1 00:00:00 1970 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=-10.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_2 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 41BB9C11F66 for ; Tue, 29 Jun 2021 08:58:12 +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 F263E61DC1 for ; Tue, 29 Jun 2021 08:58:11 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org F263E61DC1 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=collabora.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 63E876E82F; Tue, 29 Jun 2021 08:58:11 +0000 (UTC) Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [46.235.227.227]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1195E6E82F for ; Tue, 29 Jun 2021 08:58:10 +0000 (UTC) Received: from localhost (unknown [IPv6:2a01:e0a:2c:6930:5cf4:84a1:2763:fe0d]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: bbrezillon) by bhuna.collabora.co.uk (Postfix) with ESMTPSA id 19DBE1F42F22; Tue, 29 Jun 2021 09:58:08 +0100 (BST) Date: Tue, 29 Jun 2021 10:58:04 +0200 From: Boris Brezillon To: Daniel Vetter Subject: Re: [PATCH v5 02/16] drm/sched: Allow using a dedicated workqueue for the timeout/fault tdr Message-ID: <20210629105804.5c9504cb@collabora.com> In-Reply-To: References: <20210629073510.2764391-1-boris.brezillon@collabora.com> <20210629073510.2764391-3-boris.brezillon@collabora.com> Organization: Collabora X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-redhat-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 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: , Cc: Emma Anholt , Tomeu Vizoso , dri-devel@lists.freedesktop.org, Steven Price , Rob Herring , Alyssa Rosenzweig , Alex Deucher , Qiang Yu , Robin Murphy , Christian =?UTF-8?B?S8O2bmln?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" On Tue, 29 Jun 2021 10:50:36 +0200 Daniel Vetter wrote: > On Tue, Jun 29, 2021 at 09:34:56AM +0200, Boris Brezillon wrote: > > Mali Midgard/Bifrost GPUs have 3 hardware queues but only a global GPU > > reset. This leads to extra complexity when we need to synchronize timeo= ut > > works with the reset work. One solution to address that is to have an > > ordered workqueue at the driver level that will be used by the different > > schedulers to queue their timeout work. Thanks to the serialization > > provided by the ordered workqueue we are guaranteed that timeout > > handlers are executed sequentially, and can thus easily reset the GPU > > from the timeout handler without extra synchronization. > >=20 > > v5: > > * Add a new paragraph to the timedout_job() method > >=20 > > v3: > > * New patch > >=20 > > v4: > > * Actually use the timeout_wq to queue the timeout work > >=20 > > Signed-off-by: Boris Brezillon > > Reviewed-by: Steven Price > > Reviewed-by: Lucas Stach > > Cc: Qiang Yu > > Cc: Emma Anholt > > Cc: Alex Deucher > > Cc: "Christian K=C3=B6nig" =20 >=20 > Acked-by: Daniel Vetter >=20 > Also since I'm occasionally blinded by my own pride, add suggested-by: me? Duh, it's an oversight (I thought I had that 'Suggested-by: Daniel Vetter ...' already). > I did spend quite a bit pondering how to untangle your various lockdep > splats in the trd handler :-) And I'm grateful for your help ;-).