linux/drivers/video/console
Takashi Iwai 8aac7f3436 fbcon: Fix vc attr at deinit
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=1000619
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
2017-01-11 17:09:50 +01:00
..
bitblit.c framebuffer: fix border color 2014-09-30 13:39:16 +03:00
dummycon.c tty: vt, remove consw->con_bmove 2016-06-25 09:04:48 -07:00
fbcon_ccw.c framebuffer: fix border color 2014-09-30 13:39:16 +03:00
fbcon_cw.c framebuffer: fix border color 2014-09-30 13:39:16 +03:00
fbcon_rotate.c
fbcon_rotate.h
fbcon_ud.c framebuffer: fix border color 2014-09-30 13:39:16 +03:00
fbcon.c fbcon: Fix vc attr at deinit 2017-01-11 17:09:50 +01:00
fbcon.h fbcon: use the cursor blink interval provided by vt 2015-05-10 19:15:52 +02:00
Kconfig openrisc: prevent VGA console, fix builds 2016-12-12 23:10:29 +09:00
Makefile lib: Move fonts from drivers/video/console/ to lib/fonts/ 2013-06-28 10:28:22 +02:00
mdacon.c tty: vt, cleanup and document con_scroll 2016-10-27 16:37:43 +02:00
newport_con.c Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
softcursor.c
sticon.c tty: vt, cleanup and document con_scroll 2016-10-27 16:37:43 +02:00
sticore.c video: move fbdev to drivers/video/fbdev 2014-04-17 08:10:19 +03:00
tileblit.c
vgacon.c vgacon: remove prehistoric macros 2016-10-27 16:37:44 +02:00