From nobody Fri Sep 25 11:08:08 2026 Received: from mail-oo2-f4.google.com (mail-oo2-f4.google.com [74.125.231.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 82E5A311968 for ; Mon, 14 Sep 2026 02:10:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.231.132 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789351812; cv=none; b=SiCQgCLY0zTbeiw8ZcM8+EU8LpjR6uwpKt5/5a6YmtNiUbxkknU0uY3h7GDyi2STWAZ3hpUtCED8+PM33yLqmiHgjT0/NEhoJzq6f1CldpE89pGQuTvAYn/UaNNk/n/aXFwGu4NbjXDuF+Q/SZqQb81ENRpmvJg2xm5HqGOluL4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789351812; c=relaxed/simple; bh=B0FAHrSWVXGHaqZILibkK+o++O0wPS8q+cwkcADrHJk=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=E0t6/qNjnmy0dKfZ7uk0YHP+Rd91WpVuXJTVt4+bR+wPIAYr5PFfxkRQMS9v521B79Ss4vxw58tAPNHK9xc06pID/1WCgLPrds1iJu9h7TX1d8klxZUVVgg1sUUASubvjV0wgJ9s1NNCW52KyqqBfHn8daHOsJ12OUc/We82jYo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=jMhYpaHD; arc=none smtp.client-ip=74.125.231.132 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="jMhYpaHD" Received: by mail-oo2-f4.google.com with SMTP id 46e09a7af769-7f4e9ec63a7so729486a34.1 for ; Sun, 13 Sep 2026 19:10:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1789351809; x=1789956609; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=dXWWEPWR1eTf24c4piCmTsBKFKIOYSQEhaTgS6fa4xg=; b=jMhYpaHD25glrbNFCZY7N3myS5Va4Yy1yKfh8kwtcxHm8npygF+60cH/NArCGfy+bX 7E/uk5TmNSjnrhrtvry/lRMIYLiLQpsgnOPGMrOqixKzBHy/mTY3a/w9/wVWZoCErj33 /Tum4wE7vsktKOXNciKT4BzGScbFKDUssqr6jPtP+GmXUbVtxYHHxgzFzF0oIFOqiFRa 6FegTJ5MhNLSZ6YlJzxfUpHxTDWRjFdtUbWLmIugJHnN9JB+EXHJbNGcWcE8MuksL3bC 3x4LLuv/Og9OrXhl5LCFktkue7ni0TuobRSyHNjFGVwJdKvnTJDbSgrxgkeh7nEp7D5y OOnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1789351809; x=1789956609; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=dXWWEPWR1eTf24c4piCmTsBKFKIOYSQEhaTgS6fa4xg=; b=ZsCPv8e2MXTIEhNX2LdAt2fvFwA1+miHzinLEJxmWiQ6lKxuNlfq93c/xCavCkgTdU KsQmD720TXQRmaktV8iJYPLcqpno5OPH0ouQUHMOGI/ODsDNGOsmB4n+fJ5oYjIc9oyz qCSmU1TUgWzdOp2p31dzrzE9SfKqT5BG9nhBwP0zOPu7czeDqmk/yLgh7r6DgEatTgI8 GhTBnzzljOFFRWL/CQp+gXain+EXguj/gwS8+PjPQP7LHwb8IryqJrtgwlbZ1D11LnZV q/t8XlbBjAU11mbaoEKCBZB4BiplMa1cve29dD6HwG4WbGUJqUSUKDSIZYbGT+udAeRT yo7w== X-Forwarded-Encrypted: i=1; AKwUvBxA5EfiDLOUJHxHMbFDomDk+ZgjDhb2AS6S0aai/rGVZpELmugEbCdShHkPdBTESRyOa8wlygT47LxdfgM=@vger.kernel.org X-Gm-Message-State: AFuF++mZapzJYYY1kdg9FQNugW2Kth8dQHdjWo5C9OaRvooLZ1gkPYsR D+21CcCZO/5UZUaBxMd47ypUVX0KGYPg19DcNfMTW7dviYhjzgZexkzu X-Gm-Gg: AYBFou1IocPfI1uEEunWfHZTd6V10TxZM6dIQVHTWX09B6PFcUyUpD+gRsJTVVWYL9v X/u/+0utbCM/S74nA/QQ9JksriAM2lRCWhvZR8PvN4MUHd+Gh9tNenK9EF9kMNjVgHVvE+uYs/H IvltgQy6fCXqhLsnbjQedHnKyOQYmw5YMVmHBCV/qQ+ufwzOmuwMpRnx/6xccwyy60K3wjNcY7T Xd5FXCNFN6r2qxVQQTNHRXB+YqFCG4Cj2rHD7ej3jQwiJPg0xdMjaKS87ZEOiR3z3ZHuYTQtAVl XFgSoD1WwJlQk0hk1pshMAcqkp7XCnzqShRKiovuubhyzAFggVnxoxriHjQipSDZFoqmi7kPxwY P4SCFiaOwIuH1Ev5FxnGHTdd8Uya/neUBx7dHvAalQK6pYSw4ACv2pCvkU0CVYhktLMJXpVABDF DSN1n8H7F3yaONOcr/9U94hVTNZmmd1iHHzrkTKXWBingD3tGDf+Wi24dWySaG/ScseCQ= X-Received: by 2002:a05:6830:6a95:b0:805:6a93:d9ba with SMTP id 46e09a7af769-80899266f27mr185481a34.15.1789351809265; Sun, 13 Sep 2026 19:10:09 -0700 (PDT) Received: from [192.168.18.164] ([2600:8804:5716:d800::b712]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-803f5ffd82bsm9788713a34.11.2026.09.13.19.10.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 13 Sep 2026 19:10:07 -0700 (PDT) From: Ryan Brue Date: Sun, 13 Sep 2026 21:09:52 -0500 Subject: [PATCH v3 1/4] drm/imagination: don't gate the runtime PM callbacks on drm_dev_enter() Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-1-674b907d0652@gmail.com> References: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-0-674b907d0652@gmail.com> In-Reply-To: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-0-674b907d0652@gmail.com> To: Alessio Belle , Luigi Santivetti , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter Cc: imagination@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Ryan Brue , stable@vger.kernel.org X-Mailer: b4 0.16.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1789351801; l=4009; i=ryanbrue.dev@gmail.com; s=20260906; h=from:subject:message-id; bh=B0FAHrSWVXGHaqZILibkK+o++O0wPS8q+cwkcADrHJk=; b=m0nuDmmhwVrLfYPrLL6ql7pVKv9N25E76iOoE06iKNPUoksHHY7cDxzgdfxNiEHBncqvkJPZO omdWCiOyDUoAX3gisn8eY+hxz2rX+Vqz3A726TzxwQSuwuOn3F1GHuS X-Developer-Key: i=ryanbrue.dev@gmail.com; a=ed25519; pk=KsUvVaP//v/2q+ZBuacc7cLbsyEYn+AD71Sn28oZWKo= pvr_power_device_suspend() and pvr_power_device_resume() take drm_dev_enter() for their whole body and return -EIO once the device is unplugged. The section protects nothing: the callbacks run on the platform device, which stays bound until pvr_remove() returns. It is being used as a "device lost" test, and pvr_dev->lost already is one. Used that way it causes two problems. The suspend callback waits for the watchdog worker in pvr_power_fw_disable() while holding the section, and a worker losing the device calls drm_dev_unplug(), which waits in synchronize_srcu() for that section: neither finishes. Runtime PM never lets the two overlap because the worker holds a usage-count reference, but pm_runtime_force_suspend() ignores the count, so a system-sleep implementation on top of these callbacks deadlocks. Reproduced on mt8173 with the worker delayed between taking its reference and losing the device: system suspend froze until the hardware watchdog fired. And once the device is lost the callbacks fail forever, which leaves runtime PM in runtime_error and would abort every system suspend. Test pvr_dev->lost instead and hold no section; a lost device is a no-op for both callbacks. Re-test the flag after the cancel in pvr_power_fw_disable(), since the worker just waited for may be the one that lost the device. Fixes: 727538a4bbff ("drm/imagination: Implement power management") Cc: stable@vger.kernel.org Assisted-by: LLM Signed-off-by: Ryan Brue --- drivers/gpu/drm/imagination/pvr_power.c | 44 +++++++++++++----------------= ---- 1 file changed, 17 insertions(+), 27 deletions(-) diff --git a/drivers/gpu/drm/imagination/pvr_power.c b/drivers/gpu/drm/imag= ination/pvr_power.c index eb4b6ecdf4f4..8d82b9a79daf 100644 --- a/drivers/gpu/drm/imagination/pvr_power.c +++ b/drivers/gpu/drm/imagination/pvr_power.c @@ -97,6 +97,10 @@ pvr_power_fw_disable(struct pvr_device *pvr_dev, bool ha= rd_reset, bool rpm_suspe if (!hard_reset) { cancel_delayed_work_sync(&pvr_dev->watchdog.work); =20 + /* The worker just cancelled may have lost the device. */ + if (pvr_dev->lost) + return -EIO; + err =3D pvr_power_request_idle(pvr_dev); if (err) return err; @@ -372,24 +376,19 @@ pvr_power_device_suspend(struct device *dev) struct platform_device *plat_dev =3D to_platform_device(dev); struct drm_device *drm_dev =3D platform_get_drvdata(plat_dev); struct pvr_device *pvr_dev =3D to_pvr_device(drm_dev); - int err =3D 0; - int idx; + int err; =20 - if (!drm_dev_enter(drm_dev, &idx)) - return -EIO; + /* A lost device is left as the failed reset left it. */ + if (pvr_dev->lost) + return 0; =20 if (READ_ONCE(pvr_dev->fw_dev.initialised)) { err =3D pvr_power_fw_disable(pvr_dev, false, true); if (err) - goto err_drm_dev_exit; + return pvr_dev->lost ? 0 : err; } =20 - err =3D pvr_dev->device_data->pwr_ops->power_off(pvr_dev); - -err_drm_dev_exit: - drm_dev_exit(idx); - - return err; + return pvr_dev->device_data->pwr_ops->power_off(pvr_dev); } =20 int @@ -398,33 +397,24 @@ pvr_power_device_resume(struct device *dev) struct platform_device *plat_dev =3D to_platform_device(dev); struct drm_device *drm_dev =3D platform_get_drvdata(plat_dev); struct pvr_device *pvr_dev =3D to_pvr_device(drm_dev); - int idx; int err; =20 - if (!drm_dev_enter(drm_dev, &idx)) - return -EIO; + if (pvr_dev->lost) + return 0; =20 err =3D pvr_dev->device_data->pwr_ops->power_on(pvr_dev); if (err) - goto err_drm_dev_exit; + return err; =20 if (READ_ONCE(pvr_dev->fw_dev.initialised)) { err =3D pvr_power_fw_enable(pvr_dev, true); - if (err) - goto err_power_off; + if (err) { + pvr_dev->device_data->pwr_ops->power_off(pvr_dev); + return err; + } } =20 - drm_dev_exit(idx); - return 0; - -err_power_off: - pvr_dev->device_data->pwr_ops->power_off(pvr_dev); - -err_drm_dev_exit: - drm_dev_exit(idx); - - return err; } =20 int --=20 2.55.0 From nobody Fri Sep 25 11:08:08 2026 Received: from mail-oa2-f1.google.com (mail-oa2-f1.google.com [74.125.231.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5FCCF311C1B for ; Mon, 14 Sep 2026 02:10:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.231.65 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789351814; cv=none; b=KUnJ39OieoopwO0gU5PYqNZj5sPNIQrliYx+1eZWiFukClan0G3JLD4MN6POiQDiUnJYMeOzqTZbfQ0X/sGlvyJoxILf5LGiM83TexTNwiMCX/aHBq2Q34nOntURmCY4CsCPD047EOT1Dm78/w9DAda3U6lgOGejIbAbSDFbuCU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789351814; c=relaxed/simple; bh=ZZoHyJJSUtcmG47bFptDvaygfZrn5NqsAxuHZkhft04=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=ll6dBaSEk6LR7AtCpV77dsNHCCKZkOmxEVUgCFtlcB4Q8krO/NFBlRGlcaOkurV62GHpIKJGw/bkn7AjUE1o2fLGYVLzeVfANnxKH36MMDzbLCsA4g+tDN1BOsu5xlCaNmCVa29onJuIkr5wFGXAShfkYS5SY9jEhT6/tm+1zpg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=AtSepaxe; arc=none smtp.client-ip=74.125.231.65 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="AtSepaxe" Received: by mail-oa2-f1.google.com with SMTP id 586e51a60fabf-448a12ddfb4so1329902fac.1 for ; Sun, 13 Sep 2026 19:10:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1789351812; x=1789956612; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=2bdJBddmQdN/xHd2xrtzk7IHIBI7EewXCRJ+IEzWoR4=; b=AtSepaxeRaJwCRPspNXGOvHoBgogjkh+w4MCBLcACnQdjzg3dfCjm0j6RPGLqrwanM rrQEifkXhL4iPMYZtg8YBvEu3k+Z0vC88yl4Ms+G1+zusloJwUx5ta1a8j6wMhu462/0 fP6ajmneSJ9ZTg+rukSXrz1C6nxbMy4i8wvTyPr3Jbyi6arlBfnxtWO5/ChuKZwAlT6C UTv0z0Vv47ajVoPeXT5v1aJQ126A6AY7rnNOucHGeuLMc0jJDxG2UB6Dpcj9jI28F5sE MttWQ2TidkQJeQ5gXNhrFyzIElw08HGcxDnbGzECBVruRZ5sIX13mhti9y3IIceNigC7 q7tQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1789351812; x=1789956612; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=2bdJBddmQdN/xHd2xrtzk7IHIBI7EewXCRJ+IEzWoR4=; b=FOdRJdZW3AbEwOJnSHvQJ9+zHLiMCJakwLgBCvOMDSRZgpjX1nO5YoZo1TpkCUf844 lV3A54X31qEXy15/QJn5Hczldeo76fK7EbkM8tEdR3Lm+XwRrNfWC3LIYq5lI4bZOC9h T6HbgcnZXepwYjb75C+qiGCfWfunX/G+kBBsMIESLMrP8YJqzg5Ebtr2MB8BF1VCvWKp qrA7JGNDdgRlWomPuMJimAWEMG0k+bsz3iuQ3RbX0GL3zdkpjgw931qDlHUarWc6BDWG tXuhfabbkSDnryP6BAh7X1bthteWWpAiLpgdFUFCQeGVvCe4dzkNv778rncjkS3lGK0m z9zQ== X-Forwarded-Encrypted: i=1; AKwUvBzbOGeXIrXF9r9L32jvVtQQlFP7Ak3Jh3bH6Z7lYLR8jXxeWQj1D80ecG+GqEYBZqY/kXI1fWvkJdEkuMc=@vger.kernel.org X-Gm-Message-State: AFuF++mE3zHrNZpNHeP01zDwkaYlH5mtEjOL3RRu8iK84woRy3oq84+8 R3QU0sL8iUP/mtBZhIANlRbrXVEMpc0vbIK4Icl3boE69MiRTruHcod5 X-Gm-Gg: AYBFou1QZP1pb0MTqDXK3ZqLibiq14cWHlOQ+rIwNeNnO7rjyxH/thl3qwbYK6fVkTI WStSCxPCSrgBtWcpextjxEYOVaI0Q29g1w+vTQf8qWNASlmMCkbWu373u7pWIX5ev241tSu/y8Z 6XfNyATWcVgBeTmI6f5dOlFhL9SaX+M/EoQ2uU1XmDD7TEno+yHZSCdPV0Wq1voRkbVwxraWoj0 HyPPr17K5FLB3lsnoMgTaV5H1uLV4iKiTmyp+psBvkPsSvGTWA+tNR82nUwC9ZKgaBMTnLg3nmx ea6OQNhdvz1mq5FcJwuA7QPtWt2qwDzo7u6vNahvAKzjRc6Rh1R5pq54Rr0EracE67tYHyRmkfn 5oQjOsWS43lpWyeKQr92O+pn13ZdR0U3279N72pFm6bmzXH50BvbmsZCIKaObHfXFdOU3gFtGZ2 q1mVR+XjxRMmZl/Ue4EC+YEAuhm+rPEfe6AsJgKJXn4f17dAiblGgjUZMJmVsybm7E0Vw= X-Received: by 2002:a05:6830:82d2:b0:806:fca6:f3d with SMTP id 46e09a7af769-80899c5ce25mr398715a34.15.1789351812288; Sun, 13 Sep 2026 19:10:12 -0700 (PDT) Received: from [192.168.18.164] ([2600:8804:5716:d800::b712]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-803f5ffd82bsm9788713a34.11.2026.09.13.19.10.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 13 Sep 2026 19:10:10 -0700 (PDT) From: Ryan Brue Date: Sun, 13 Sep 2026 21:09:53 -0500 Subject: [PATCH v3 2/4] drm/imagination: unplug the device before tearing it down in pvr_remove() Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-2-674b907d0652@gmail.com> References: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-0-674b907d0652@gmail.com> In-Reply-To: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-0-674b907d0652@gmail.com> To: Alessio Belle , Luigi Santivetti , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter Cc: imagination@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Ryan Brue , stable@vger.kernel.org X-Mailer: b4 0.16.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1789351801; l=2461; i=ryanbrue.dev@gmail.com; s=20260906; h=from:subject:message-id; bh=ZZoHyJJSUtcmG47bFptDvaygfZrn5NqsAxuHZkhft04=; b=ZTV8BCDF9afG8SPH8QIz/AAfq1jv9qP3OiHDYb8FI//s7x0Reg8Ej14pcfX2MNfYVOuUMH8ic KIpi1YWdHnOCoempRnPbcHdJciKlLmnJraoXqE3+v/SfuEL6GuFVBgB X-Developer-Key: i=ryanbrue.dev@gmail.com; a=ed25519; pk=KsUvVaP//v/2q+ZBuacc7cLbsyEYn+AD71Sn28oZWKo= pvr_remove() destroys the job and free list xarrays, powers the GPU down and runs pvr_device_fini() before calling drm_dev_unplug(), so an ioctl that entered its drm_dev_enter() section before the unbind can still be walking structures that have already been freed. Call drm_dev_unplug() first. It makes every later drm_dev_enter() fail and waits for the sections already in flight. The runtime suspend that follows works on an unplugged device now that the callbacks no longer gate on drm_dev_enter(). Skip the unplug if pvr_device_lost() has already done it: drm_dev_unplug() is not idempotent, and the second call oopses in drm_client_sysrq_unregister() on a node the first one removed. Unbinding a GPU that a failed reset marked lost hits that deterministically. Holding an ioctl in its section for 4s on mt8173 while unbinding shows the change: before, pvr_device_fini() completed 3.1s before the ioctl left its section; after, drm_dev_unplug() blocks for those 3.1s and the teardown follows. Fixes: 1f88f017e649 ("drm/imagination: Get GPU resources") Fixes: 727538a4bbff ("drm/imagination: Implement power management") Cc: stable@vger.kernel.org Assisted-by: LLM Signed-off-by: Ryan Brue --- drivers/gpu/drm/imagination/pvr_drv.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/imagination/pvr_drv.c b/drivers/gpu/drm/imagin= ation/pvr_drv.c index 5c965ef0274f..fc92a82a7208 100644 --- a/drivers/gpu/drm/imagination/pvr_drv.c +++ b/drivers/gpu/drm/imagination/pvr_drv.c @@ -1469,15 +1469,23 @@ static void pvr_remove(struct platform_device *plat= _dev) struct drm_device *drm_dev =3D platform_get_drvdata(plat_dev); struct pvr_device *pvr_dev =3D to_pvr_device(drm_dev); =20 + /* + * Unplug before freeing anything, so no ioctl is still inside + * drm_dev_enter(). pvr_device_lost() may already have done it, and + * drm_dev_unplug() is not idempotent. + */ + if (!pvr_dev->lost) + drm_dev_unplug(drm_dev); + WARN_ON(!xa_empty(&pvr_dev->job_ids)); WARN_ON(!xa_empty(&pvr_dev->free_list_ids)); =20 + pm_runtime_suspend(drm_dev->dev); + xa_destroy(&pvr_dev->job_ids); xa_destroy(&pvr_dev->free_list_ids); =20 - pm_runtime_suspend(drm_dev->dev); pvr_device_fini(pvr_dev); - drm_dev_unplug(drm_dev); pvr_watchdog_fini(pvr_dev); pvr_queue_device_fini(pvr_dev); pvr_context_device_fini(pvr_dev); --=20 2.55.0 From nobody Fri Sep 25 11:08:08 2026 Received: from mail-oa2-f1.google.com (mail-oa2-f1.google.com [74.125.231.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AD1C2311C32 for ; Mon, 14 Sep 2026 02:10:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.231.65 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789351819; cv=none; b=iV/5XbULVzAcOTNIB3DvqNA31I1LMA52tlU/OiUjEfVOIZIN8L/Wp48yPj57T3M6LGqTxE4N/X+04qg6pN1TCNVpZ+uKfiJigx59sZXhfRl4Lr5z2iVVTTJqyWAaRhKUgB18hPwRXKqKadStFSO+4chwdYAuVdpb3bZjS5ahxEA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789351819; c=relaxed/simple; bh=9Yo6q3xRbzehVoYANIYWHpMZD6dLjaFxkE9BuO/bq+o=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Jqj63KsE9UJMjJLkjsCYMovjM1yZmk8zyYsiEMw1ZLvEpZALmQIeI0ssdK3yYSnFxiEbV0TDVqFqIdUS/8nHo8smhjI6zYFFle054qmIzXHR93pW8vzuJU66pEvIa8VByfhe5KMjjBecuzFLBAbfSkPToqzfIsib9R10hTALahk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=IizFMY7H; arc=none smtp.client-ip=74.125.231.65 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="IizFMY7H" Received: by mail-oa2-f1.google.com with SMTP id 586e51a60fabf-448a12ddfb4so1329945fac.1 for ; Sun, 13 Sep 2026 19:10:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1789351816; x=1789956616; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=5ens4tvOvZUZ2shdZ+y3dfNiHm8kjjJbg0o+rL2d/6o=; b=IizFMY7HDN0B/1QgLywToSaQHiZJO2JaS4TjhwMgygCbXEKUJJYxElpAQPh+M7gJiS hJjqvhS8hh6PUDBK8eUQXNv0XAcwA2df1/UmFCUAOAdZ8ZuAxdn+Z9MQEd7cjHuKxP9B /0+pVtJH127m0SIWyQ0Qxt1/NI7CsaVMUysRzenqndHjPoYMnZ1QckeeCqp7tm8xuhRS aycoChCdY9yloEa12prCaebfua+sRUH52I+q6J6NJB5yRBm32LqLFu3LawdkNPHmA8p7 XmNDr3MQCLlW30uW6VQkJJIGJbg19/HXMkrGriv1jFtCg0ZgCb+97aHN0X2wf6GAQ5Jj iKDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1789351816; x=1789956616; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=5ens4tvOvZUZ2shdZ+y3dfNiHm8kjjJbg0o+rL2d/6o=; b=byEE/3pXrDIoAM5kbMeZEqBHJKUQBZ9G7XDvO8zb3S4/mFfBv/TXhc11kNqf/f7l0E /6sDvYaBoQeFXmq+w9GGSvzM/88pxucxdCnwiBnPTawZ7rlPR33vabdj93zXWpLjvcCr rVYILpo2sODNM/hw6BFS2GuUx96+SGJnAU5FyBUVrU2fv6fomsydejoPilpA8t0TQrRy +jYSo9ImtS9hD4A0YF3pDhujeUCrTOvwDPs3MGwt5etn9vOoMNtNpDiz3VVTMCVW14NT foS63+iRcS/hFgJEENC4cUx6qAV3F0h7XA5txeeQeUv6VJbd7xJH1BbcQNiWWEsPinAv zKVQ== X-Forwarded-Encrypted: i=1; AKwUvByVWsVr+jjoDI41vkTI+Ufbbq3ZoGF1v/cZsfLMVXo9zkerqsJAV8qLtHu7IMVd1S1LOg7R5VFtgscMY04=@vger.kernel.org X-Gm-Message-State: AFuF++nVXYQn7wna7ZbCUplmySqTMRDnVDdP4h+CGdRi+XYtBsb4wjGp 0lYCdDZPpxby0TKsAHMPGV4ks9buc7zq0nL17yZCq94C5Ddej7ZXmPUb X-Gm-Gg: AYBFou2+eVRuqDOefBUM9RLeHMlAXdlYIM8aCx54h8b9x+JC3RYDQjyA0jIUbnyL/xP cEP2gC2WxGR0VL/YPBmbm9JDot3xzZei3GdgeloPs7Oktu4qTaLzcpx4ga/WpDifFOvS7U0Vyba Ke5Z4ngujTMKiaHvLTabAExNgBU06CTzz8gfDwMNFDH/04QbXe8DiO7MViHZIpOp2I86UuffFvN 24mlvQLc/TwnHRB9TCVXPvPxTQMzGbLCb5rpLOvLzNRyiIcMtOYaxzZeHvKpa+rjUpw/1idMTgp dkhRWnkrj59KPQX/PxwYc0x12SvB7PZzvvErloxrAszoJCBF5NhAVFjWTwIXb7Cli9Z7JfnjEv+ FdD/j0sitiCfE6LCvVm7D08bf97T2MzyxMazk55TwYxvumGhH1Vv9b3gGyTsFFBy3KLed5uGMrt U/eF+Egwy/m3/S57S7CBfXAJk605Nh/X8FlLHeQPQ4sHdKhlNzxSn5vUtVKOu5Ar2yDng= X-Received: by 2002:a05:6830:2a86:b0:7f8:4ebe:2854 with SMTP id 46e09a7af769-8089759c582mr369256a34.4.1789351816652; Sun, 13 Sep 2026 19:10:16 -0700 (PDT) Received: from [192.168.18.164] ([2600:8804:5716:d800::b712]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-803f5ffd82bsm9788713a34.11.2026.09.13.19.10.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 13 Sep 2026 19:10:14 -0700 (PDT) From: Ryan Brue Date: Sun, 13 Sep 2026 21:09:54 -0500 Subject: [PATCH v3 3/4] drm/imagination: stop the watchdog before tearing the device down Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-3-674b907d0652@gmail.com> References: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-0-674b907d0652@gmail.com> In-Reply-To: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-0-674b907d0652@gmail.com> To: Alessio Belle , Luigi Santivetti , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter Cc: imagination@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Ryan Brue , stable@vger.kernel.org X-Mailer: b4 0.16.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1789351801; l=2128; i=ryanbrue.dev@gmail.com; s=20260906; h=from:subject:message-id; bh=9Yo6q3xRbzehVoYANIYWHpMZD6dLjaFxkE9BuO/bq+o=; b=rNNUnHpmGFQsgkJLLWq00R5uggWAjk/JjRny6l6FmNcxSrvItWpKCt0tt45OW+Nttk7zpXs9V CL+mYayaXpQCG8DD49sK5/ANbS97EdXH8RzYP1gZE0ybzlmJMLQpnO0 X-Developer-Key: i=ryanbrue.dev@gmail.com; a=ed25519; pk=KsUvVaP//v/2q+ZBuacc7cLbsyEYn+AD71Sn28oZWKo= pvr_remove() runs pvr_watchdog_fini() after pvr_device_fini(), so the watchdog work can still be queued while pvr_fw_fini() unmaps the fwif_osdata it reads. The pm_runtime_suspend() earlier in remove normally cancels the work on its way through pvr_power_fw_disable(), but it returns -EAGAIN without calling the callback when the usage count is raised, and -EINVAL when the device is in runtime_error, and then nothing has cancelled the watchdog since the last pvr_power_fw_enable(): echo on > /sys/devices/platform/soc/13000000.gpu/power/control echo 13000000.gpu > /sys/bus/platform/drivers/powervr/unbind The worker fires within 500ms of the free and reads freed memory. Cancel it first, before the unplug: the worker is one of the callers of pvr_device_lost(), so waiting for it here also means the pvr_dev->lost test that guards the unplug cannot race it. Fixes: 727538a4bbff ("drm/imagination: Implement power management") Cc: stable@vger.kernel.org Assisted-by: LLM Signed-off-by: Ryan Brue --- drivers/gpu/drm/imagination/pvr_drv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/imagination/pvr_drv.c b/drivers/gpu/drm/imagin= ation/pvr_drv.c index fc92a82a7208..20b27a468327 100644 --- a/drivers/gpu/drm/imagination/pvr_drv.c +++ b/drivers/gpu/drm/imagination/pvr_drv.c @@ -1469,6 +1469,9 @@ static void pvr_remove(struct platform_device *plat_d= ev) struct drm_device *drm_dev =3D platform_get_drvdata(plat_dev); struct pvr_device *pvr_dev =3D to_pvr_device(drm_dev); =20 + /* Stop the watchdog before anything it reads is freed. */ + pvr_watchdog_fini(pvr_dev); + /* * Unplug before freeing anything, so no ioctl is still inside * drm_dev_enter(). pvr_device_lost() may already have done it, and @@ -1486,7 +1489,6 @@ static void pvr_remove(struct platform_device *plat_d= ev) xa_destroy(&pvr_dev->free_list_ids); =20 pvr_device_fini(pvr_dev); - pvr_watchdog_fini(pvr_dev); pvr_queue_device_fini(pvr_dev); pvr_context_device_fini(pvr_dev); pvr_power_domains_fini(pvr_dev); --=20 2.55.0 From nobody Fri Sep 25 11:08:08 2026 Received: from mail-oa2-f11.google.com (mail-oa2-f11.google.com [74.125.231.75]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6C283313E2C for ; Mon, 14 Sep 2026 02:10:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.231.75 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789351822; cv=none; b=iTn3bxqA25sbHddwxZx1kCldkfD6Y5F4xWJGPxg4KSDgZPpJV0NVO8ZFU5jxnIsibJYCywkUyU98eDqUXBiwuE9KD/eaAYvNtKgbSj1pm2/8lYvmujrPYnGQmgDhtbmlzSERo039bDHzxtjGONUr8eAsRQff0Lwws92eGghQ0UU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789351822; c=relaxed/simple; bh=bPg7ibmMjA3YZEMkxh8P9EgsDt2Ehcjuozj55lALu8k=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Ldgvj/Vu88uxfhfjRDGzZ5OaSu8fbvwk8gCGw5uNHBceLlhi6atL8ihKyeQ3d3Y25BU+A1+sNddT2L7KPzdgWzqlMstgh4AAUF6TN4IwMaGRoao3ksokGC7Lcn7yPu7GeMpKz3OrCTBArbCOxrZlrBhTGVy2Ck4R1UJG8MQOnW8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=b3D7XFKf; arc=none smtp.client-ip=74.125.231.75 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="b3D7XFKf" Received: by mail-oa2-f11.google.com with SMTP id 586e51a60fabf-457e289483bso396103fac.1 for ; Sun, 13 Sep 2026 19:10:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1789351819; x=1789956619; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=LwLjeaGopLfJY+d0f6yY+haKMKBWMqU5CkDwCqQQGFw=; b=b3D7XFKfHqsLVfQKG2TiPW+iYSKzigASyTdAkcdaMF3XMANEb9JnI46WHKcdKmz3MG LSUOcGfj8n2omjKwEesuQS4f6VGSfFs4ISrrHxUDh4iGXWR8q0zocORJvM3tvgtZs8Fq YNRaaoC1w0yN2QxVGHSWCfLynhRhyIGe3n5lmswRR7YYlErSHETPxhRFkHe3/oHqC7Ke ZyhcD15nC4ickp3eWKrE3g+xPkcDeHGCzRpU2fk+R0sYt3tEI6UpOldlGNv7rKGzMT/e tMI+C15lDe1mbL9NXJJfZrXQjC0q5ZyHIpfXFwcSZKFqsgfC3hICYYoZLNfkIt5FKZ8v Qieg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1789351819; x=1789956619; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=LwLjeaGopLfJY+d0f6yY+haKMKBWMqU5CkDwCqQQGFw=; b=pL2JeltUvqDhpxM7bP8GPLvZBP8fXbtz7n/vvyTp0G3nSvbrby1VHzQPvJbxvwo5Nm xC7vDrCWtS2d4LurRCdp5rrZRtTtAgOS9TPLYdMTdSxtON8kSyGrMOcKWJ+vOUP0sC80 z51YPtVlGQPXiZS6pHbqi2PofElfm453HatEtg0XZyY4mZjVKhAaf97DZ/zhKe2I4GtC qIWVGr4iBteIbjeE7aGru4WqjqjmqMgTSCtetEhXfyTCpexXlwVxfKOu/en9t3eGnR7A oGtGo+9xOoQbH32ZUVBPJkd0PO3Kdzq7HwMKT8CGF6R3zsYRf/nROVhHb64Sy/CVKtEp 2WKw== X-Forwarded-Encrypted: i=1; AKwUvBwKtbtg93vRLIVeAy2z3HU6CIFUeqz05UxZl3mSOmjCW3g1qqJfIJnBwGovexTHwp1pN5flmTVbnqc3gAM=@vger.kernel.org X-Gm-Message-State: AFuF++lsiaCu0ghQPsBIr7yVjGkObh/PCmQ5AYRw0goWN49EmlYxrNYu Sae3nXs2XZKjWxQnkeXAG58nGp0pwweyuaDWC1on46wbewDl+3xpAHKG X-Gm-Gg: AYBFou0FOiVZhAGRBY4/hf9ruBkufBxgPIWtju7ODmSoa1BOrChZSSrleyHpV3DriZj 9slqrAbssvxvI7tqCi8jiXLc0sswL2AKBG/gLx5h1hmeQYpiT+AyBeHHgoMFTb/63mGBKaKMATk hEbuShmzfOeaqJ+5HMd5jjUhY/4yfNFHNgLyY8eYS5vbyblZkUlYw8ir1bspyt2YfPoDmekyJNS U1Mfpzj5ck1qojHirbLDxFVnC+kIoQSc5Rc+QKREEvPOsx2j39XIjAqxIFNjFh1RmTJWGmOQFmk MtV4d1P8NPyb08w6AkxjdueVnHjsijtOmousK0+zwh4UHW95DCk4tPubXg8mC5w26N9mv5Tc6R8 R9nlPUuGurKQom52/Bk01LdiMDJNJjDcJwmGwugmBK4EMB3zxc7xYoyWSqyI4icMwQTpExXQGQr z9AklLlMHy8PZa6s6WDM/ncCm8sSaCIAHMK0OJ2kOJUTNXJvmyf+xqsbXPZpvC80yGKxg= X-Received: by 2002:a05:6830:6f81:b0:7dc:e78b:158 with SMTP id 46e09a7af769-808846c49d6mr223406a34.4.1789351819296; Sun, 13 Sep 2026 19:10:19 -0700 (PDT) Received: from [192.168.18.164] ([2600:8804:5716:d800::b712]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-803f5ffd82bsm9788713a34.11.2026.09.13.19.10.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 13 Sep 2026 19:10:18 -0700 (PDT) From: Ryan Brue Date: Sun, 13 Sep 2026 21:09:55 -0500 Subject: [PATCH v3 4/4] drm/imagination: suspend the GPU for system sleep, not just runtime PM Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-4-674b907d0652@gmail.com> References: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-0-674b907d0652@gmail.com> In-Reply-To: <20260913-rbrue-suez-upstreaming-pvr-suspend-gpu-system-sleep-v3-0-674b907d0652@gmail.com> To: Alessio Belle , Luigi Santivetti , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter Cc: imagination@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Ryan Brue , stable@vger.kernel.org X-Mailer: b4 0.16.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1789351801; l=2092; i=ryanbrue.dev@gmail.com; s=20260906; h=from:subject:message-id; bh=bPg7ibmMjA3YZEMkxh8P9EgsDt2Ehcjuozj55lALu8k=; b=sogxAc49G5Crj4suR69BUpnafPaK3iEZJ21gP+/t5/X1rHiNPL/wGtJylh4kP0QilF0ofUwbs zFmkUpjGYCjBpyiOvH7tdGZx1THU442gXZOr+oZFMppu9B+n33ZMqen X-Developer-Key: i=ryanbrue.dev@gmail.com; a=ed25519; pk=KsUvVaP//v/2q+ZBuacc7cLbsyEYn+AD71Sn28oZWKo= pvr_pm_ops has only RUNTIME_PM_OPS, so the GPU gets no callback for system suspend. That works only while it happens to be runtime-suspended when the system goes down. If it is runtime-active, genpd counts it as suspended anyway and turns the power domain off. After resume the driver still believes its firmware is running, the first firmware operation times out, and pvr_power_reset() is entered from inside an ioctl's drm_dev_enter() section, where its drm_dev_unplug() waits for that very section: the caller is left in an unkillable D state and the GPU is dead until reboot. On mt8173 it is deterministic: echo on > /sys/devices/platform/soc/13000000.gpu/power/control echo mem > /sys/power/state # wakes on an RTC alarm vulkaninfo --summary # hangs in D state, every time With the default 50ms autosuspend delay the same bug is intermittent in ordinary use, depending only on whether the GPU was idle at the instant of suspend. pvr_power_device_suspend() already disables the firmware and powers the GPU off and pvr_power_device_resume() is its inverse, so drive both for system sleep with the force helpers. The reset-path deadlock is a separate bug; this only stops the system-sleep path from reaching it. Fixes: 727538a4bbff ("drm/imagination: Implement power management") Cc: stable@vger.kernel.org Assisted-by: LLM Signed-off-by: Ryan Brue --- drivers/gpu/drm/imagination/pvr_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/imagination/pvr_drv.c b/drivers/gpu/drm/imagin= ation/pvr_drv.c index 20b27a468327..b7931f75832f 100644 --- a/drivers/gpu/drm/imagination/pvr_drv.c +++ b/drivers/gpu/drm/imagination/pvr_drv.c @@ -1527,6 +1527,7 @@ MODULE_DEVICE_TABLE(of, dt_match); =20 static const struct dev_pm_ops pvr_pm_ops =3D { RUNTIME_PM_OPS(pvr_power_device_suspend, pvr_power_device_resume, pvr_pow= er_device_idle) + SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, pm_runtime_force_resume) }; =20 static struct platform_driver pvr_driver =3D { --=20 2.55.0