From: sashiko-bot@kernel.org
To: "YuanZhe Liu" <25031212351@stu.xidian.edu.cn>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v2 2/2] fbdev: fbmem: don't fail registration when fbcon cannot take over
Date: Fri, 04 Dec 2026 16:44:31 +0000 [thread overview]
Message-ID: <sashiko-outbox-250213@kernel.org> (raw)
In-Reply-To: <20261204160835.16470-2-25031212351@stu.xidian.edu.cn>
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Low] fbdev: fbcon_fb_registered() and do_fb_registered() have unused
int return
--
commit 9a79cb5d4a64251e588b11510f76e1464adc18ad
Author: YuanZhe Liu <25031212351@stu.xidian.edu.cn>
fbdev: fbmem: don't fail registration when fbcon cannot take over
This commit ignores the return value of fbcon_fb_registered() in
do_register_framebuffer() and returns 0 instead, so a failed console takeover
no longer fails framebuffer registration.
> diff --git a/drivers/video/fbdev/core/fbmem.c b/drivers/video/fbdev/core/fbmem.c
> index c8aa163b0ecfa..2f6d6be673b47 100644
> --- a/drivers/video/fbdev/core/fbmem.c
> +++ b/drivers/video/fbdev/core/fbmem.c
> @@ -535,7 +535,13 @@ static int do_register_framebuffer(struct fb_info *fb_info)
> }
> #endif
>
> - return fbcon_fb_registered(fb_info);
> + /*
> + * The framebuffer is registered now. A failed console takeover
> + * is not a registration failure; reporting it would make drivers
> + * free a live fb_info and leave registered_fb[] dangling.
> + */
> + fbcon_fb_registered(fb_info);
> + return 0;
[Severity: Low]
Should fbcon_fb_registered() and do_fb_registered() be changed to return
void now that do_register_framebuffer() ignores the return value?
do_register_framebuffer() is the sole caller of fbcon_fb_registered(), and
the only other caller of do_fb_registered() (fbcon_register_existing_fbs())
already discards its return value. Converting both functions and the
!CONFIG_FRAMEBUFFER_CONSOLE stub in drivers/video/fbdev/core/fbcon.h to
void would remove the unused return-value plumbing and match the sibling
fbcon_fb_unregistered() and fbcon_fb_unbind() hooks.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261204093601.9900-1-25031212351@stu.xidian.edu.cn?part=2
next prev parent reply other threads:[~2026-12-04 16:44 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-04 9:35 [PATCH v2 0/2] fbdev: fix udlfb shadow buffer and framebuffer registration YuanZhe Liu
2026-12-04 16:08 ` [PATCH v2 1/2] fbdev: udlfb: fix shadow buffer handling when the framebuffer grows YuanZhe Liu
2026-12-04 16:08 ` [PATCH v2 2/2] fbdev: fbmem: don't fail registration when fbcon cannot take over YuanZhe Liu
2026-12-04 16:44 ` sashiko-bot [this message]
2026-12-04 16:28 ` [PATCH v2 1/2] fbdev: udlfb: fix shadow buffer handling when the framebuffer grows sashiko-bot
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-250213@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=25031212351@stu.xidian.edu.cn \
--cc=dri-devel@lists.freedesktop.org \
--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.