Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp2925066rwb; Mon, 15 Aug 2022 14:10:03 -0700 (PDT) X-Google-Smtp-Source: AA6agR5tX5PHQbVqh8QbaV+sv1r8TBuAZ+uZxKMHXBkl6k9fsU7VZJiP548nKkeDTMN8C8drJGkt X-Received: by 2002:a17:907:1c0a:b0:730:9a59:3891 with SMTP id nc10-20020a1709071c0a00b007309a593891mr11436872ejc.453.1660597803040; Mon, 15 Aug 2022 14:10:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660597803; cv=none; d=google.com; s=arc-20160816; b=IiU41gyx0SZ++Vm6knUZftzh7bStoQDfxLWHgumJRV1+31ERv73PMTVQy6OcN5CyzT T9PhwOCUce/jEpOLBjScowmOLyeTPXJteoFU6YginLebutRKAekZAT54b9/gPTVeXUKN jKFcOiBZObBNtfQkNh1IcZ/DDpDFPyEW1e0gtGnw4d6Gmo6aOwWH608MnZ4IgMLWiC3T woYgkxshvs/7jBZ3Zw2I6E/rVL0XOTAt/sEl7fZGQmIUBNfL5ahExTYVmaeFo6hvji3F kFA9jz8dhVLxNzLh6rzM61Ov1RwegwOBPWNgj4A5Jf1v3aMq15BboJ/FhFNuv8IP0zo+ 1LIQ== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=SJ8BtUqfhYy1deTsAEUHvGckkIX6+ruWo+y7KxXrnvE=; b=NDDswMnZlmO4sYOxS9+IJIgZZwQqFIBIUzg/erE3D27UTYOendPt7LRT+3WXUmMr6w 60t7RBauWHoVDM2oxP+ubQUIqifZ5dc/3Equu7XzyJFaLDhYFf4xQaQdAyLfuiBSRFRG Pa/cn5CAlNBadJIh1VtHKG7k5e5w8bsq2yxAl8qrMMdZtsnEaTk5dwI47coXrp0TYMc4 9NffYG78/PrEB8QwLWf/erYPGDMSNYpR9b0msyQ1kPWOXwZ6kMzNz+kBvAzipb4J08O2 sX8AjBznBYuqWOuiBvSGUrB5FViDvHvBDZSE3AN4rmA4CZrLJEk7bca/cpcVxVbHrYrS Yq6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=J2T+G2Ri; 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=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hc13-20020a170907168d00b0072f703af475si9292554ejc.924.2022.08.15.14.09.37; Mon, 15 Aug 2022 14:10:03 -0700 (PDT) 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=@linuxfoundation.org header.s=korg header.b=J2T+G2Ri; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1347074AbiHOUQr (ORCPT + 99 others); Mon, 15 Aug 2022 16:16:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33368 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346697AbiHOUMA (ORCPT ); Mon, 15 Aug 2022 16:12:00 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BAB7285A8B; Mon, 15 Aug 2022 11:58:12 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 7434E61274; Mon, 15 Aug 2022 18:58:11 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 77768C433C1; Mon, 15 Aug 2022 18:58:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660589890; bh=V1Q9LMJoIqpGyydO3a1zid7QGNBisxqlZD0J0mhVsWY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=J2T+G2RiNpuX1vXQhg4Dz+fKIYzlyb1iFClXiXFYgpiqqrnj/ZNBUabeS8lUBXa+b q2fy9C6tjZvwEO8FpTy3Ltoe5iwJSe74bwThAu/tOFr1kyT1BPMc/mSP9pazV2+n+s PMFRE3+gA/blOsfMmi9G559pOHed9R2OAkjLYm3Q= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Lyude Paul , David Airlie , Hans de Goede Subject: [PATCH 5.18 0081/1095] drm/nouveau: Dont pm_runtime_put_sync(), only pm_runtime_put_autosuspend() Date: Mon, 15 Aug 2022 19:51:20 +0200 Message-Id: <20220815180432.872099520@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220815180429.240518113@linuxfoundation.org> References: <20220815180429.240518113@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 From: Lyude Paul commit c96cfaf8fc02d4bb70727dfa7ce7841a3cff9be2 upstream. While trying to fix another issue, it occurred to me that I don't actually think there is any situation where we want pm_runtime_put() in nouveau to be synchronous. In fact, this kind of just seems like it would cause issues where we may unexpectedly block a thread we don't expect to be blocked. So, let's only use pm_runtime_put_autosuspend(). Changes since v1: * Use pm_runtime_put_autosuspend(), not pm_runtime_put() Signed-off-by: Lyude Paul Reviewed-by: David Airlie Fixes: 3a6536c51d5d ("drm/nouveau: Intercept ACPI_VIDEO_NOTIFY_PROBE") Cc: Hans de Goede Cc: # v4.10+ Link: https://patchwork.freedesktop.org/patch/msgid/20220714174234.949259-3-lyude@redhat.com Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/nouveau/nouveau_display.c | 2 +- drivers/gpu/drm/nouveau/nouveau_fbcon.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) --- a/drivers/gpu/drm/nouveau/nouveau_display.c +++ b/drivers/gpu/drm/nouveau/nouveau_display.c @@ -515,7 +515,7 @@ nouveau_display_hpd_work(struct work_str pm_runtime_mark_last_busy(drm->dev->dev); noop: - pm_runtime_put_sync(drm->dev->dev); + pm_runtime_put_autosuspend(dev->dev); } #ifdef CONFIG_ACPI --- a/drivers/gpu/drm/nouveau/nouveau_fbcon.c +++ b/drivers/gpu/drm/nouveau/nouveau_fbcon.c @@ -466,7 +466,7 @@ nouveau_fbcon_set_suspend_work(struct wo if (state == FBINFO_STATE_RUNNING) { nouveau_fbcon_hotplug_resume(drm->fbcon); pm_runtime_mark_last_busy(drm->dev->dev); - pm_runtime_put_sync(drm->dev->dev); + pm_runtime_put_autosuspend(drm->dev->dev); } }