From: sashiko-bot@kernel.org
To: "Kylie C" <kyliepc@proton.me>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm/fbdev-client: Don't restore while fbcon isn't bound
Date: Wed, 25 Nov 2026 12:54:09 +0000 [thread overview]
Message-ID: <sashiko-outbox-233403@kernel.org> (raw)
In-Reply-To: <20261125-fbdev-no-early-restore-v1-1-f81dc7acf3ad@proton.me>
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Medium] drm/fbdev-client: drm_fbdev_client_restore() breaks non-fbcon
fbdev restore
--
commit 54a83d65f9ba427c2f43d8c3969eff6a330480ba
Author: Kylie C <kyliepc@proton.me>
drm/fbdev-client: Don't restore while fbcon isn't bound
This commit skips non-forced fbdev mode restoration in
drm_fbdev_client_restore() when fb_helper->info->fbcon_par is NULL so
that deferred console takeover does not restore an unbound fbcon
framebuffer on lastclose.
> diff --git a/drivers/gpu/drm/clients/drm_fbdev_client.c b/drivers/gpu/drm/clients/drm_fbdev_client.c
> index eec463d199433..7981d613e652e 100644
> --- a/drivers/gpu/drm/clients/drm_fbdev_client.c
> +++ b/drivers/gpu/drm/clients/drm_fbdev_client.c
> @@ -50,6 +50,9 @@ static int drm_fbdev_client_restore(struct drm_client_dev *client, bool force)
> if (!fb_helper->info || !fb_helper->fb)
> return 0;
>
> + if (!force && !fb_helper->info->fbcon_par)
> + return 0;
> +
> drm_fb_helper_restore_fbdev_mode_unlocked(fb_helper, force);
>
> return 0;
[Severity: Medium]
Does checking fb_helper->info->fbcon_par break fbdev restoration when
userspace drives /dev/fb* without fbcon?
DRM_FBDEV_EMULATION does not depend on CONFIG_FRAMEBUFFER_CONSOLE, and
userspace can also unbind fbcon at runtime to use /dev/fb0 directly.
Because info->fbcon_par is only set in fbcon_open(), it remains NULL in
those setups, so drm_lastclose() -> drm_client_dev_restore(dev, false)
will permanently skip drm_fb_helper_restore_fbdev_mode_unlocked() and
any pending delayed_hotplug handling when the last DRM client exits.
In addition, struct fb_info documents fbcon_par as an fbcon-only private
field ("/* fbcon use-only private area */" in include/linux/fb.h).
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261125-fbdev-no-early-restore-v1-1-f81dc7acf3ad@proton.me?part=1
prev parent reply other threads:[~2026-11-25 12:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-25 12:38 [PATCH] drm/fbdev-client: Don't restore while fbcon isn't bound Kylie C
2026-11-25 12:38 ` Kylie C via B4 Relay
2026-11-25 12:54 ` sashiko-bot [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=sashiko-outbox-233403@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=kyliepc@proton.me \
--cc=sashiko-reviews@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.