From: Takashi Iwai <tiwai@suse.de>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Jiri Slaby <jslaby@suse.cz>,
Tomi Valkeinen <tomi.valkeinen@ti.com>,
linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] fbcon: Fix vc attr at deinit
Date: Tue, 03 Jan 2017 16:57:23 +0000 [thread overview]
Message-ID: <s5hy3ysqdxo.wl-tiwai@suse.de> (raw)
In-Reply-To: <20170103164905.GA24990@kroah.com>
On Tue, 03 Jan 2017 17:49:05 +0100,
Greg Kroah-Hartman wrote:
>
> On Tue, Jan 03, 2017 at 04:03:22PM +0100, Takashi Iwai wrote:
> > fbcon can deal with vc_hi_font_mask (the upper 256 chars) and adjust
> > the vc attrs dynamically when vc_hi_font_mask is changed at
> > fbcon_init(). When the vc_hi_font_mask is set, it remaps the attrs in
> > the existing console buffer with one bit shift up (for 9 bits), while
> > it remaps with one bit shift down (for 8 bits) when the value is
> > cleared. It works fine as long as the font gets updated after fbcon
> > was initialized.
> >
> > However, we hit a bizarre problem when the console is switched to
> > another fb driver (typically from vesafb or efifb to drmfb). At
> > switching to the new fb driver, we temporarily rebind the console to
> > the dummy console, then rebind to the new driver. During the
> > switching, we leave the modified attrs as is. Thus, the new fbcon
> > takes over the old buffer as if it were to contain 8 bits chars
> > (although the attrs are still shifted for 9 bits), and effectively
> > this results in the yellow color texts instead of the original white
> > color, as found in the bugzilla entry below.
> >
> > An easy fix for this is to re-adjust the attrs before leaving the
> > fbcon at con_deinit callback. Since the code to adjust the attrs is
> > already present in the current fbcon code, in this patch, we simply
> > factor out the relevant code, and call it from fbcon_deinit().
> >
> > Bugzilla: https://bugzilla.suse.com/show_bug.cgi?id\x1000619
> > Signed-off-by: Takashi Iwai <tiwai@suse.de>
> > ---
> > drivers/video/console/fbcon.c | 67 ++++++++++++++++++++++++++-----------------
> > 1 file changed, 40 insertions(+), 27 deletions(-)
>
> So this is an old bug? Should it go to stable kernels?
Yes, the bug seems to be very old, but only recently revealed
accidentally (likely) because of the changes in boot sequences with
systemd & co.
The problem itself is fairly harmless: it just appears on VT1 with a
weird color after switching to the different fb until you scroll the
full screen out. So I didn't care about stable. But feel free to put
to stable if you think it's safe.
> And am I the fbcon maintainer now?
Heh, blame scripts/get_maintainer.pl (or I'm still in a new year
frolic). Maybe I should have sent to Andrew instead :)
thanks,
Takashi
next prev parent reply other threads:[~2017-01-03 16:57 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-03 15:03 [PATCH] fbcon: Fix vc attr at deinit Takashi Iwai
2017-01-03 16:49 ` Greg Kroah-Hartman
2017-01-03 16:57 ` Takashi Iwai [this message]
2017-01-04 13:50 ` Takashi Iwai
2017-01-05 12:26 ` Tomi Valkeinen
2017-01-10 15:47 ` Takashi Iwai
2017-01-10 16:09 ` Bartlomiej Zolnierkiewicz
[not found] ` <CGME20170111145050epcas1p4b2e6b4ee2e813bbbb1dc10864bdc071c@epcas1p4.samsung.com>
2017-01-11 14:50 ` Bartlomiej Zolnierkiewicz
2017-01-11 18:48 ` Takashi Iwai
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=s5hy3ysqdxo.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=gregkh@linuxfoundation.org \
--cc=jslaby@suse.cz \
--cc=linux-fbdev@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tomi.valkeinen@ti.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).