From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DAAB5606A31F for ; Sat, 5 Dec 2026 16:53:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=AnuxDkf8 Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 45D7C10E04D; Sat, 5 Dec 2026 16:53:25 +0000 (UTC) Received: from sea.source.kernel.org (sea.source.kernel.org [172.234.252.31]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6CED910E04D for ; Sat, 5 Dec 2026 16:53:19 +0000 (UTC) Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) by sea.source.kernel.org (Postfix) with ESMTP id 0CF2543264; Sat, 5 Dec 2026 16:53:19 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id D23AC1F00936; Sat, 5 Dec 2026 16:53:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796489598; bh=yfNaZWxCO+iVctk+B8zAOR01CB0iMjXv5gw/v+fWQrg=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=AnuxDkf8IcM0hlz6i6DFyzbE9WRwFPp4I6vkWN6JkBs8YJsLmh9Qs/gZjtoTlSFLt OkjqZvd2b+HZMhEuuHBhK2YTWLq4TtowSsuNFHj7bxpID4DoJGmQfZla1laOOsrUj5 JQuzkFNHHZbq9wwRsjLfcvX/c/o7BYk5JTgrM0kbBTlWc3TgtQ9wUGmauHLVecADOG sG+wNUWcm2PDCbwvaO0YU546Av2stsR9b5L6JPeiXzaq5l1LyDj98ipFem/RIP1g+2 b4yZTch65oKjJCqTTKZkPyg0Sc+2QBtT4Q3I9dsNG3kz5ZLDuekmfP0RygKN0DiqRn pl+WVRvlgL2Wg== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v2] drm/fb-helper: Keep blanked outputs off across restore and hotplug To: "Anush Veeranala" Cc: dri-devel@lists.freedesktop.org In-Reply-To: <87fqwbit6c.fsf@gnu.org> References: <87fqwbit6c.fsf@gnu.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Sat, 05 Dec 2026 16:53:18 +0000 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: sashiko-reviews@lists.linux.dev Sender: "dri-devel" X-Spam-Status: No, score=-11.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 X-Archived-By: Thank you for your contribution! Sashiko AI review found 1 potential issue to consider: - [Medium] drm/fb-helper: pan_display_atomic() ignores dpms_mode on blanked outputs -- commit 5f90cefa3fd2f544582d71f06fa0e5cdcca4f8b5 Author: Anush Veeranala drm/fb-helper: Keep blanked outputs off across restore and hotplug This commit records the last blank request's DPMS mode in struct drm_fb_helper so that unforced restores and hotplug events on atomic drivers keep blanked outputs off via drm_client_modeset_dpms(). > diff --git a/drivers/gpu/drm/clients/drm_fbdev_helper.c b/drivers/gpu/drm= /clients/drm_fbdev_helper.c > index 415764ee086a8..9b8fec3323089 100644 > --- a/drivers/gpu/drm/clients/drm_fbdev_helper.c > +++ b/drivers/gpu/drm/clients/drm_fbdev_helper.c > @@ -105,6 +105,22 @@ __drm_fb_helper_restore_fbdev_mode_unlocked(struct d= rm_fb_helper *fb_helper, > * racing here, see drm_fb_helper_set_par(). > */ > ret =3D drm_client_modeset_commit_locked(&fb_helper->client); > + /* > + * Forced restores light the outputs, blanked or not: fbcon > + * forces one when switching back to text mode and then > + * unblanks, and sysrq forces one to show the console. Later > + * restores, such as the delayed hotplug's below, keep them on. > + */ > + fb_helper->dpms_mode =3D DRM_MODE_DPMS_ON; > + } else if (fb_helper->dpms_mode !=3D DRM_MODE_DPMS_ON && > + drm_drv_uses_atomic_modeset(fb_helper->dev)) { > + /* > + * Keep blanked outputs off. Legacy DPMS doesn't commit the > + * configuration, so legacy drivers keep committing it with the > + * outputs on. > + */ > + ret =3D drm_client_modeset_dpms(&fb_helper->client, > + fb_helper->dpms_mode); > } else { > ret =3D drm_client_modeset_commit(&fb_helper->client); > } [Severity: Medium] Should pan_display_atomic() also respect fb_helper->dpms_mode? pan_display_atomic() calls drm_client_modeset_commit_locked(), which commits with active=3Dtrue on atomic drivers regardless of fb_helper->dpms_mode. F= or example, fb_set_var() calls fb_pan_display() right after drm_fb_helper_set_par(), undoing the blanking preserved here. That turns blanked outputs back on without notifying fbcon, leaving the display lit indefinitely while fb_helper->dpms_mode stays out of sync with the hardware state so a later unrelated restore or hotplug turns it off again. Committing with active set to fb_helper->dpms_mode =3D=3D DRM_MODE_DPMS_ON = in pan_display_atomic() would keep the outputs and dpms_mode consistent. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/87fqwbit6c.fsf@gnu.= org?part=3D1