Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp6771357rwb; Tue, 22 Nov 2022 19:20:09 -0800 (PST) X-Google-Smtp-Source: AA0mqf79fnRm7TNuOEtzMKjxt0+l/5c3lyNQM0w0F5PlVxzEaaY3OQGOl18LMhjlN7gzmPdoIIY8 X-Received: by 2002:a17:902:ccce:b0:185:4880:91cd with SMTP id z14-20020a170902ccce00b00185488091cdmr6849705ple.130.1669173608910; Tue, 22 Nov 2022 19:20:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669173608; cv=none; d=google.com; s=arc-20160816; b=f+T7us8ZIEdnG5qN/9E/hedOcsycFZqKAA8N7pHxjBorM3BhPe3fHnNWcXnLymnScO WnxinJdlHfJ5AzLZ58DxQbOzfhwLXWVb/MrGniW6iN/a+VZjirm6UfrDq6rz0t5IY438 GzqLZAoilEuVFEMG5PyARRXUk0Rm45PKz+5Nly+K57Rt6UXSYOUQYlt5sP+CHtImwsJq 8KNHVNOqYj9AQDU0Gao0uJSR0Z7W+IfE3MWj1mEzmLimiHoNItyJX8rc39gq4F7I4ROC iL0yhS0dZgvzgpHOvpm6mzSClCTdV8ggYCI8KzvSXexwZowQMtU4amwYD+FHJ8+iFBTR q8dg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=jRu0ihgGBjKemeWmCNHntd+Bg14e8zAfhszTe0TPn2g=; b=TWQ4P3TC6sRSobEcbIK0S24IBrrSRvuzW17v9R71oueUHFrsCQqrYIlCkIIDlflbI8 Vx5YW/AiwkWjvuijbnJLcnKefVbG/6bppaaAoKkCPAlm5sd6uAq4V7AtYhKtsrLTfDWd 59apyRdVe/SOxkJZEOqhoPxaiBvFioV7Fiavkjw17lxhWkdxSrNhECHmtOYUjtOqOmkd 66IDi92YypT3QagiD6JjQC2QvjI3LjsNoH+CYkJc3GTvzlU416pbSCqcZLQk26A/mGmd QkFZ5py2bUKRacwu7Fn5lMZJUun1Ud9Z7b/E60VirBZeLKJVJjEqqyDloa5+7wqhhigm IVug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=BpWBrZxM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id l22-20020a63ea56000000b00476f238d231si15335005pgk.807.2022.11.22.19.19.57; Tue, 22 Nov 2022 19:20:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=BpWBrZxM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235320AbiKWDAc (ORCPT + 89 others); Tue, 22 Nov 2022 22:00:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59170 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235178AbiKWDAS (ORCPT ); Tue, 22 Nov 2022 22:00:18 -0500 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D20528517C for ; Tue, 22 Nov 2022 19:00:17 -0800 (PST) Received: from dimapc.. (109-252-117-140.nat.spd-mgts.ru [109.252.117.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: dmitry.osipenko) by madras.collabora.co.uk (Postfix) with ESMTPSA id C3EB76602AEA; Wed, 23 Nov 2022 03:00:14 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1669172416; bh=bCtRcV3G+l88aFGcEVKaXpZkB9zlpbX6mrvZZ+14XRo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BpWBrZxMk3rCf9xcNlytosyR9+eq8jl8eoIM9x1Mg9XXZmfoxeMbFjaEMVSDo46ZU dvMiqqfVtPzC7zvk1nrpssSoTSbtZzZd6v7c0tg9g7Z445qc8pHbBK93joxTH06yhn qpRaDIkyB1wK6fQ8LjeP6q20Cg67gHNGnPeuARz4jyOBVuEVMpLz2jB831j6r9Y679 haqxoOrwbC+erNvho+ywQ+CAJwKAVKS1ttOTzP8GHU7oQB1zW07JlfKRDIBXlkArbx ZdWnTlsi/WPZoIvocMP9M5Cs3D4ZkrB7VITM23f1t00e8SOXocSwY25e7T8fDuH0Uk wDjUUOwmckGIQ== From: Dmitry Osipenko To: David Airlie , Gerd Hoffmann , Gurchetan Singh , Chia-I Wu , Daniel Vetter , Daniel Almeida , Gustavo Padovan , Daniel Stone , Tomeu Vizoso , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Clark , Sumit Semwal , =?UTF-8?q?Christian=20K=C3=B6nig?= , Qiang Yu , Steven Price , Alyssa Rosenzweig , Rob Herring , Sean Paul , Dmitry Baryshkov , Abhinav Kumar Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, kernel@collabora.com, virtualization@lists.linux-foundation.org Subject: [PATCH v9 02/11] drm/panfrost: Don't sync rpm suspension after mmu flushing Date: Wed, 23 Nov 2022 05:57:14 +0300 Message-Id: <20221123025723.695075-3-dmitry.osipenko@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221123025723.695075-1-dmitry.osipenko@collabora.com> References: <20221123025723.695075-1-dmitry.osipenko@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Lockdep warns about potential circular locking dependency of devfreq with the fs_reclaim caused by immediate device suspension when mapping is released by shrinker. Fix it by doing the suspension asynchronously. Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/panfrost/panfrost_mmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/panfrost/panfrost_mmu.c b/drivers/gpu/drm/panfrost/panfrost_mmu.c index e246d914e7f6..99a0975f6f03 100644 --- a/drivers/gpu/drm/panfrost/panfrost_mmu.c +++ b/drivers/gpu/drm/panfrost/panfrost_mmu.c @@ -273,7 +273,7 @@ static void panfrost_mmu_flush_range(struct panfrost_device *pfdev, if (pm_runtime_active(pfdev->dev)) mmu_hw_do_operation(pfdev, mmu, iova, size, AS_COMMAND_FLUSH_PT); - pm_runtime_put_sync_autosuspend(pfdev->dev); + pm_runtime_put_autosuspend(pfdev->dev); } static int mmu_map_sg(struct panfrost_device *pfdev, struct panfrost_mmu *mmu, -- 2.38.1